Instagram API

Instagram Hashtag search API

Recent posts under a hashtag with cursor pagination: shortcode, type, caption and media URL.

$1.20/1k req, pay per request, no subscription.

What the API returnedposts[0]
{
"id": "3714950709444987377",
"shortcode": "DOOJ_zSjcnx",
"type": "XDTGraphVideo",
"url": "https://www.instagram.com/reel/DOOJ_zSjcnx/",
"caption": "Launch day! 🚀 #spacex",
"displayUrl": "https://instagram.com/reel/DOOJ_zSjcnx/media.jpg",
"avatarUrl": string,
"comments": integer,
... 18 more fields
}
Uptime
99.83%
30d · 26,513 calls
Requests
26,513
30d · weekly, last 12 wks
Response
10.8s
median · 30d

Pricing

Instagram Hashtag search API pricing

You pay
$12.00
$1.20/1k req, only for what you use. No monthly plan.
Your first 83 requests are free with the $0.10 starting balance.

Try it

Get Instagram hashtag search in one request

Open in
Get a free key
Sample response
Free runs return only the first 3 results. Fund a key to get the full response.

This sample shows 9 of 31 fields. See every field

{
  "found": true,
  "data": {
    "posts": [
      {
        "id": "3714950709444987377",
        "shortcode": "DOOJ_zSjcnx",
        "type": "XDTGraphVideo",
        "url": "https://www.instagram.com/reel/DOOJ_zSjcnx/",
        "caption": "Launch day! 🚀 #spacex",
        "displayUrl": "https://instagram.com/reel/DOOJ_zSjcnx/media.jpg"
      }
    ]
  }
}

Full parameter and response reference - every field, type, and example for this endpoint.

Reference

One request, one response shape.

Every field you send and every field you get back, each with a real example.

Last verified 2026-11-05 · uptime and latency measured over 30d

Request body

JSON, posted to this endpoint.

  • hashtagstring

    spacex

    Hashtag to search, without the leading #.

  • cursorstring

    Pagination cursor from a previous response.

  • datePostedenum

    Restrict results to posts published within this window.

  • mediaTypeenum

    Filter by media type. One of all, reel.

You send. A small JSON body. The values shown are examples to replace with your own.

Response

JSON, one example value per field.

datadata
  • nextCursorstring

    Opaque cursor for the next page of posts, or null when this lane has no more. Pass it back as cursor to continue.

each postdata.posts[]

Populated whenever the provider has data for the entity.

  • avatarUrlstring

    Profile picture URL of the posting account.

  • captionstring

    Launch day! 🚀 #spacex

    Post caption text, including its hashtags.

  • commentsinteger

    Comment count.

  • createdUtcnumber

    UTC epoch timestamp in seconds (Unix time). Multiply by 1000 for a JS Date in milliseconds.

  • displayNamestring

    Display name of the posting account.

  • displayUrlstring

    https://instagram.com/reel/DOOJ_zSjcnx/media.jpg

    Poster image URL. For a video this is the cover frame. Populated whenever the provider has data for the entity.

  • durationSecondsnumber

    Video duration in seconds. Absent on photo posts.

  • hasAudioboolean

    True when the media carries an audio track.

  • hashtagsstring[]

    Hashtags carried in the caption, each including its leading #. Populated whenever the provider has data for the entity.

  • idstring

    3714950709444987377

    Instagram media id. Populated whenever the provider has data for the entity.

  • isAdboolean

    True when the post is a paid advertisement.

  • likesinteger

    Like count. Absent when the account hides it.

  • locationIdstring

    Instagram location id the post is tagged at.

  • locationLatnumber

    Latitude of the tagged location, in decimal degrees.

  • locationLngnumber

    Longitude of the tagged location, in decimal degrees.

  • locationNamestring

    Name of the location the post is tagged at.

  • mentionsstring[]

    Accounts @mentioned in the caption, each including its leading @. Populated whenever the provider has data for the entity.

  • paidPartnershipboolean

    True when the post is tagged as a paid partnership.

  • productTypestring

    Instagram product type of the media, for example feed, clips or igtv.

  • shortcodestring

    DOOJ_zSjcnx

    Short code in the post permalink. Populated whenever the provider has data for the entity.

  • typestring

    XDTGraphVideo

    Instagram media typename, for example XDTGraphVideo or XDTGraphImage.

  • urlstring

    https://www.instagram.com/reel/DOOJ_zSjcnx/

    Canonical permalink to the post. Populated whenever the provider has data for the entity.

  • userIdstring

    Instagram user id of the posting account.

  • usernamestring

    Username of the account that posted. Populated whenever the provider has data for the entity.

  • verifiedboolean

    True when the posting account is verified.

  • videoUrlstring

    Playable video file URL. Present only on video posts.

top level
  • foundboolean

    true

  • reason"not_found"

    Present only when `found` is false, and says why there is no result. `not_found`: the source states the target does not exist, or returned nothing for it. A `found: false` answer is a successful call, not an error, and `costUsd` is what it actually cost.

You get back. Named, typed fields in the same shape whichever source answers.

FAQ

About the Instagram Hashtag search API

The AnyAPI Instagram Hashtag search API returns Instagram hashtag search data as normalized JSON from one POST call to /v1/run/instagram.search_hashtag. Recent posts under a hashtag with cursor pagination: shortcode, type, caption and media URL. AnyAPI returns one normalized schema whichever source serves it. It costs from $1.20 per 1,000 requests, in US dollars with no subscription and no monthly minimum. Over the last 30 days, 99.8% of Instagram hashtag search calls through AnyAPI succeeded, with a median response time of 10.8 seconds across 26,513 measured calls.

It costs from $1.20 per 1,000 requests, in US dollars with no subscription and no monthly minimum. You fund one USD wallet and each call draws it down. Some failed wallet-funded requests incur processing charges that we pass through at cost, with no markup; the error response shows the amount charged.

Recent posts under a hashtag with cursor pagination: shortcode, type, caption and media URL. The response is normalized JSON with the same envelope every AnyAPI endpoint returns, so parsing a second endpoint is a change of URL and nothing else.

Over the last 30 days, 99.8% of Instagram hashtag search calls through AnyAPI succeeded, with a median response time of 10.8 seconds across 26,513 measured calls. These are AnyAPI's own measurements of traffic through the gateway, recomputed continuously, not a published service-level target.

Yes. A new AnyAPI account starts with $0.10 of free balance and no card required, which covers 83 Instagram Hashtag search calls at $0.0012 each.

Send a POST request to https://api.getanyapi.com/v1/run/instagram.search_hashtag with your AnyAPI key in an "Authorization: Bearer" header and the input as a JSON body. The same key and the same wallet work on every AnyAPI endpoint.

No. You add US dollars to one prepaid AnyAPI balance and each request draws it down. There is no monthly plan and no minimum, and the same balance pays for every AnyAPI endpoint.

Yes. Install @getanyapi/sdk from npm for TypeScript or getanyapi from pip for Python. Both call every AnyAPI endpoint with the same key, and any HTTP client works too.

Yes. An agent can connect to the AnyAPI MCP server at https://api.getanyapi.com/mcp, or create its own free-trial key with one unauthenticated POST to https://api.getanyapi.com/agent/signup and call this endpoint over HTTP.