Skip to main content

Get Media by username

Retrieve user media by username.

Params

NameTypeDefaultDescription
username (required)strUsername
countint12Number of media to retrieve (max: 12)
max_idstringNoneUse for pagination

You can use the max_id parameter to paginate through the media (take from the next_max_id field of the response).

Usage

from rocketapi import InstagramAPI


instagram_api = InstagramAPI(token="your-api-key")
print(instagram_api.get_user_media_by_username("kyliejenner", count=12))

Response example

Loading...