Skip to content
cosenary edited this page Nov 19, 2011 · 8 revisions

Media info

public access

getMedia($id)

Example response:

{
  "data": {
    "id": "1574083",
    "username": "snoopdogg",
    "first_name": "Snoop",
    "last_name": "Dogg",
    "profile_picture": "http://distillery.s3.amazonaws.com/profiles/profile_1574083_75sq_1295469061.jpg",
    "bio": "This is my bio",
    "website": "http://snoopdogg.com",
    "counts": {
      "media": 1320,
      "follows": 420,
      "followed_by": 3410 
    }
  }
}

Popular Media

public access

getPopularMedia()

Example response:

{
  "data": {
    "type": "image",
    "filter": "Walden",
    "tags": [],
    "comments": {
      "data": [{
        "created_time": "1279332030",
        "text": "Love the sign here",
        "from": {
          "username": "mikeyk",
          "full_name": "Mikey Krieger",
          "id": "4",
          "profile_picture": "http://distillery.s3.amazonaws.com/profiles/profile_1242695_75sq_1293915800.jpg"
        },
        "id": "8"
      }],
      "count": 1
    },
    "caption": null,
    "likes": {
      "count": 1,
      "data": [{
        "username": "mikeyk",
        "full_name": "Mikeyk",
        "id": "4",
        "profile_picture": "..."
      }]
    },
    "link": "http://instagr.am/p/D/",
    "user": {
      "username": "kevin",
      "full_name": "Kevin S",
      "profile_picture": "...",
      "bio": "...",
      "website": "...",
      "id": "3"
    },
    "created_time": "1279340983",
    "images": {
      "low_resolution": {
        "url": "http://distillery.s3.amazonaws.com/media/2010/07/16/4de37e03aa4b4372843a7eb33fa41cad_6.jpg",
        "width": 306,
        "height": 306
      },
      "thumbnail": {
        "url": "http://distillery.s3.amazonaws.com/media/2010/07/16/4de37e03aa4b4372843a7eb33fa41cad_5.jpg",
        "width": 150,
        "height": 150
      },
      "standard_resolution": {
        "url": "http://distillery.s3.amazonaws.com/media/2010/07/16/4de37e03aa4b4372843a7eb33fa41cad_7.jpg",
        "width": 612,
        "height": 612
      }
    },
    "id": "3",
    "location": null
  }
}

Search Media

searchMedia($lat, $lng, $params)

Example response:

coming soon ...

Public user methods

These methods require only a client_id, so you can setup the class with: new Instagram('YOUR_APP_KEY')

Restricted user methods

Methods with this label require an authenticated user with an access_token. For more informations have a look at the Get started guide, especially the Authenticate user (OAuth2) chapter.

Clone this wiki locally