The Pullbay Instagram API provides programmatic access to public Instagram profile, post, reel, story, and comment data. Resolve handles to user IDs, pull a profile, list a user's posts/tagged posts/reels, read active stories, fetch a single post by shortcode, or pull comments on a post — all without scraping or owning an Instagram account of your own.
Base URL: https://api.pullbay.com
Overview
The Instagram service lets you:
Resolve a handle (
@username) to Instagram's internal numeric user IDLook up a full user profile by handle or by numeric ID
List a user's posts, posts they're tagged in, and reels (cursor-paginated)
Fetch a user's currently-active stories
Fetch a single post by its shortcode (the code in an
instagram.com/p/{code}/URL)Fetch comments on a post by the post's internal ID (cursor-paginated)
All endpoints are read-only GET requests against public Instagram data — no account of your own is required. This service uses three distinct identifier types that are not interchangeable: handle (the @username, passed without the @), id (Instagram's internal numeric ID for a user, post, or comment), and code (a post's shortcode, the segment after /p/ in a post URL). Always check which one a given endpoint expects.
Common Use Cases
Influencer Vetting — Pull a creator's profile (follower count, post count, verification status) before negotiating a sponsorship, and check their recent posts for content fit and engagement levels.
Engagement Tracking — Poll a brand or creator account's posts and reels on a schedule to track likeCount and commentCount trends over time.
Campaign Monitoring — Fetch posts a brand account is tagged in to see how a hashtag or partnership campaign is performing across other accounts.
Comment Sentiment Analysis — Pull comments on a post and feed the message field into your own sentiment or moderation pipeline.
Story Archiving — Capture a user's active stories before they expire (24 hours after posting) for compliance, reporting, or content-repurposing workflows.
Endpoints
GET /instagram/userid/{handle}
Resolve a handle to a numeric user ID
—
GET /instagram/user/handle/{handle}
Get a user profile by handle
—
GET /instagram/user/{id}
Get a user profile by numeric ID
—
GET /instagram/user/{id}/posts
Get posts published by a user
Cursor / maxItems
GET /instagram/user/{id}/posts/tagged
Get posts a user is tagged in
Cursor / maxItems
GET /instagram/user/{id}/reels
Get reels published by a user
Cursor / maxItems
GET /instagram/user/{id}/stories
Get a user's currently-active stories
—
GET /instagram/post/code/{code}
Get a single post by shortcode
—
GET /instagram/post/{id}/comments
Get comments on a post
Cursor / maxItems
Resolve User ID
Returns whether a handle is available and, if it exists, the resolved Instagram user ID.
Request
Parameters
handle
string (path)
Yes
—
Instagram handle, without @, 1–100 characters (e.g. instagram)
Example
Response
Response Schema
pricing.creditsCharged
number
Credits charged for this request
Credit cost: charged dynamically per request; the exact amount is always returned in pricing.creditsCharged. No published flat rate — read the figure from the response.
Get User By Handle
Returns an Instagram user profile by handle (without @).
Request
Parameters
handle
string (path)
Yes
—
Instagram handle, without @, 1–100 characters (e.g. instagram)
Example
Response
Response Schema
pricing.creditsCharged
number
Credits charged for this request
Credit cost: dynamic, returned in pricing.creditsCharged. No published flat rate.
Get User By ID
Returns an Instagram user profile by numeric user ID.
Request
Parameters
id
string (path)
Yes
—
Numeric Instagram user ID, 1–100 characters (e.g. 25025320)
Example
Response
Response Schema
pricing.creditsCharged
number
Credits charged for this request
Credit cost: dynamic, returned in pricing.creditsCharged. No published flat rate.
Get User Posts
Returns posts published by an Instagram user. Use cursor to paginate or maxItems for a one-shot bulk pull (mutually exclusive).
Request
Parameters
id
string (path)
Yes
—
Numeric Instagram user ID, 1–100 characters
maxItems
integer (query)
No
—
One-shot bulk pull, 1–200 results. Mutually exclusive with cursor
cursor
string (query)
No
—
Pagination cursor from a previous response. Mutually exclusive with maxItems
Example
Response
Response Schema
pagination.hasNextPage
boolean, nullable
Whether another page is available
pagination.cursor
string, nullable
Cursor to pass as cursor on the next request
pagination.page / pagination.offset
nullable
Unused by this endpoint — always null here
pricing.creditsCharged
number
Credits charged for this request
Credit cost: dynamic, returned in pricing.creditsCharged. No published flat rate — read the figure from each response.
Get User Tagged Posts
Returns posts where the Instagram user is tagged. Use cursor to paginate or maxItems for a one-shot bulk pull (mutually exclusive).
Request
Parameters
id
string (path)
Yes
—
Numeric Instagram user ID, 1–100 characters
maxItems
integer (query)
No
—
One-shot bulk pull, 1–200 results. Mutually exclusive with cursor
cursor
string (query)
No
—
Pagination cursor from a previous response. Mutually exclusive with maxItems
Example
Response
Response Schema
pagination.hasNextPage
boolean, nullable
Whether another page is available
pagination.cursor
string, nullable
Cursor to pass as cursor on the next request
pagination.page / pagination.offset
nullable
Unused by this endpoint — always null here
pricing.creditsCharged
number
Credits charged for this request
Credit cost: dynamic, returned in pricing.creditsCharged. No published flat rate.
Get User Reels
Returns reels published by an Instagram user. Use cursor to paginate or maxItems for a one-shot bulk pull (mutually exclusive). Reels are returned using the same Post object schema as the posts endpoints — there is no separate "reel" schema.
Request
Parameters
id
string (path)
Yes
—
Numeric Instagram user ID, 1–100 characters
maxItems
integer (query)
No
—
One-shot bulk pull, 1–200 results. Mutually exclusive with cursor
cursor
string (query)
No
—
Pagination cursor from a previous response. Mutually exclusive with maxItems
Example
Response
Response Schema
pagination.hasNextPage
boolean, nullable
Whether another page is available
pagination.cursor
string, nullable
Cursor to pass as cursor on the next request
pagination.page / pagination.offset
nullable
Unused by this endpoint — always null here
pricing.creditsCharged
number
Credits charged for this request
Credit cost: dynamic, returned in pricing.creditsCharged. No published flat rate.
Get User Stories
Returns the user's currently-active Instagram stories. Not paginated — stories expire 24 hours after posting, so the full active set is always returned in one call.
Request
Parameters
id
string (path)
Yes
—
Numeric Instagram user ID, 1–100 characters
Example
Response
Response Schema
pricing.creditsCharged
number
Credits charged for this request
Credit cost: dynamic, returned in pricing.creditsCharged. No published flat rate.
Get Post By Shortcode
Returns a single Instagram post by its shortcode (the segment after /p/ in the post's URL).
Request
Parameters
code
string (path)
Yes
—
Post shortcode, 1–100 characters (e.g. CzABCdef123, the code in instagram.com/p/CzABCdef123/)
Example
Response
Response Schema
pricing.creditsCharged
number
Credits charged for this request
Credit cost: dynamic, returned in pricing.creditsCharged. No published flat rate.
Get Post Comments
Returns comments on an Instagram post. Use cursor to paginate or maxItems for a one-shot bulk pull (mutually exclusive). Takes the post's internal numeric id, not its shortcode.
Request
Parameters
id
string (path)
Yes
—
Numeric Instagram post ID, 1–100 characters (not the post's shortcode)
maxItems
integer (query)
No
—
One-shot bulk pull, 1–500 results. Mutually exclusive with cursor
cursor
string (query)
No
—
Pagination cursor from a previous response. Mutually exclusive with maxItems
Example
Response
Response Schema
pagination.hasNextPage
boolean, nullable
Whether another page is available
pagination.cursor
string, nullable
Cursor to pass as cursor on the next request
pagination.page / pagination.offset
nullable
Unused by this endpoint — always null here
pricing.creditsCharged
number
Credits charged for this request
Credit cost: dynamic, returned in pricing.creditsCharged. No published flat rate.
Errors
All non-2xx responses share the same envelope:
400
Bad request — missing/invalid parameters
402
Insufficient credits
404
User, post, or story not found
Object Schema
User ID lookup object
isAvailable
boolean
Whether the handle exists/is in use
handle
string
The handle that was looked up
id
string
Numeric Instagram user ID. Present only when isAvailable is true
User object
type
string
Always user
isAvailable
boolean
Whether the profile is available
id
string
Numeric Instagram user ID
username
string
Handle, without @
fullName
string
Display name
biography
string
Bio text
profilePicUrl
string
Profile picture URL
website
string
Link in bio
category
string
Business/category label (e.g. App page)
cityName
string, nullable
City shown on profile
isPrivate
boolean
Whether the account is private
isVerified
boolean
Whether the account has a verified badge
isBusiness
boolean
Whether the account is a business account
hasVideos
boolean
Whether the account has published videos
hasGuides
boolean
Whether the account has published guides
postCount
integer
Total post count
followerCount
integer
Follower count
followingCount
integer
Following count
totalReelsCount
integer
Total reel count
bioLinks
array
Links shown in the bio
Post owner object
Lightweight user reference embedded in posts and stories.
id
string
Numeric Instagram user ID
username
string
Handle, without @
fullName
string
Display name
profilePicUrl
string
Profile picture URL
isVerified
boolean
Whether the account has a verified badge
isPrivate
boolean
Whether the account is private
Post object
Used for posts, tagged posts, and reels — reels are returned with type: "reel" but share this same schema; there is no separate reel object.
type
string
photo / video / carousel / reel
id
string
Numeric post ID
code
string
Shortcode (the segment after /p/ in the URL)
url
string
Permalink to the post
caption
string
Caption text
createdAt
integer
Unix timestamp (seconds) the post was published
likeCount
integer
Like count
commentCount
integer
Comment count
isAvailable
boolean
Whether the post is still available
isCarousel
boolean
Whether the post is a multi-media carousel
isVideo
boolean
Whether the post is a video
isPinned
boolean
Whether the post is pinned to the profile
isPaidPartnership
boolean
Whether the post is a paid partnership
isLikeAndViewCountsDisabled
boolean
Whether like/view counts are hidden
location
object, nullable
Tagged location
image
object, nullable
Image media data
video
object, nullable
Video media data
audio
object, nullable
Audio track data
carouselMedia
array
Per-slide media for carousel posts
Comment object
type
string
Always comment
id
string
Comment ID
userId
string
Numeric ID of the commenter
message
string
Comment text
createdAt
string (date-time)
When the comment was posted
likeCount
integer
Like count
replyCount
integer
Reply count
isRanked
boolean
Whether the comment is algorithmically ranked/pinned
user
object
Commenter reference (id, username, fullName, profilePicUrl, isPrivate, isVerified)
Story object
type
string
photo / video
id
string
Story ID
code
string
Shortcode
createdAt
integer
Unix timestamp (seconds) the story was posted
expiringAt
integer
Unix timestamp (seconds) the story expires
duration
number
Duration in seconds
hasAudio
boolean
Whether the story has audio
hasTranslation
boolean
Whether translated text is available
canReshare
boolean
Whether the story can be reshared
canReply
boolean
Whether replies are allowed
isVideo
boolean
Whether the story is a video
image
object, nullable
Image media data
video
object, nullable
Video media data
audio
object, nullable
Audio track data
link
object, nullable
Attached link sticker data
comments
array
Comments left on the story
mentions
array
Mentioned accounts
hashtags
array
Tagged hashtags
Finding User IDs and Handles
This service uses three distinct identifiers — keep them separate:
handle: the@usernameshown on a profile, passed without the@(e.g.instagramfor@instagram). Used only byGET /instagram/userid/{handle}andGET /instagram/user/handle/{handle}.id: Instagram's internal numeric ID for a user, post, or comment. Required by every other endpoint in this service (posts, tagged posts, reels, stories, and post comments all key off a numericid, not a handle or shortcode).code: a post's shortcode — the segment after/p/in a post's URL (e.g.CzABCdef123inhttps://www.instagram.com/p/CzABCdef123/). Used only byGET /instagram/post/code/{code}.
If you need the full profile anyway, GET /instagram/user/handle/{handle} returns both the profile and the numeric id in a single call, saving a round trip.
A post's id (needed for the comments endpoint) is not the same as its code (shortcode). If you only have a post's shortcode, call GET /instagram/post/code/{code} first — the response's id field is the numeric post ID to use with GET /instagram/post/{id}/comments.
Python Example
This example resolves a handle to a user ID, then paginates through that user's posts using cursor:
Each request is billed independently, with the charged amount reported in that response's pricing.creditsCharged — there's no separate "fetch everything in one call" endpoint, so a multi-page pull like this makes one request per page.
FAQ
Next Steps
API Integration Guide — integrate the Pullbay API into your backend application.
n8n Integration Guide — set up automated workflows using n8n with no coding required.
Services Overview — explore all available Pullbay services.
Last updated