X (Twitter) Profile Media API
Page through the photos or videos an X account has posted, as tweet rows with their media, in the shared Social Fetch envelope.
GET /v1/twitter/profiles/{handle}/media1 credit Failed requests are free
About this endpoint
GET /v1/twitter/profiles/{handle}/media reads the Photos or Videos tab of an X profile: pass type=photos or type=videos. X keeps them as separate tabs, so read each one you need. Rows are the same as on GET /v1/twitter/profiles/{handle}/tweets: data.tweets with text, metrics, author and media, and data.page for the next page.
Branch on data.lookupStatus: found, private for a protected account, or not_found. A short page is not the end; keep passing data.page.nextCursor while data.page.hasMore is true, with the same type.
Price
From $1.35 per 1,000 requests
1 credit per request. Failed requests are free.
- Scale pack
- $1.64 / 1,000
- Growth pack
- $2.36 / 1,000
The lowest rate is on annual plans; packs are pay as you go.
Example request
Send your API key in the x-api-key header. New accounts get 100 free credits, no card needed.
Example response
A 200 response. Live responses have the same shape with current data.
X (Twitter) Profile Media API FAQ
How do I get the photos or videos an X account posted?
Call GET /v1/twitter/profiles/{handle}/media?type=photos (or type=videos) with your Social Fetch API key. Read data.tweets; each row carries its media.
Can I get photos and videos in one call?
No. X shows them as two tabs, so call once with type=photos and once with type=videos.
How does pagination work?
When data.page.hasMore is true, pass data.page.nextCursor as cursor with the same handle and type. Pages can be shorter than limit.
How much does the profile media endpoint cost?
Pricing is documented on the operation in the API registry (shown on this page). Confirm on every response with meta.creditsCharged: that field is the billing source of truth. Each paginated page is a separate billed request.
Other X (Twitter) endpoints
- ProfileGET /v1/twitter/profiles/{handle}
- ProfilesGET /v1/twitter/profiles
- About accountGET /v1/twitter/profiles/{handle}/about
- Profile followersGET /v1/twitter/profiles/{handle}/followers
- Verified followersGET /v1/twitter/profiles/{handle}/followers/verified
- Follower idsGET /v1/twitter/profiles/{handle}/followers/ids
- Profile followingGET /v1/twitter/profiles/{handle}/following
- Following idsGET /v1/twitter/profiles/{handle}/following/ids