{
  "openapi": "3.0.1",
  "info": {
    "title": "Instagram Hashtag Posts Scraper",
    "description": "Scrape public Instagram posts and Reels for one or more hashtags. Exports captions, engagement counts, author metadata, media URLs, comments when available, cursor metadata, and run summaries. No Instagram cookies required. MCP/API-ready.",
    "version": "1.4",
    "x-build-id": "iHZsdw1TX05RRC3t7"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/khadinakbar~instagram-hashtag-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-khadinakbar-instagram-hashtag-scraper",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor, waits for its completion, and returns Actor's dataset items in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    },
    "/acts/khadinakbar~instagram-hashtag-scraper/runs": {
      "post": {
        "operationId": "runs-sync-khadinakbar-instagram-hashtag-scraper",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor and returns information about the initiated run in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/runsResponseSchema"
                }
              }
            }
          }
        }
      }
    },
    "/acts/khadinakbar~instagram-hashtag-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-khadinakbar-instagram-hashtag-scraper",
        "x-openai-isConsequential": false,
        "summary": "Executes an Actor, waits for completion, and returns the OUTPUT from Key-value store in response.",
        "tags": [
          "Run Actor"
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/inputSchema"
              }
            }
          }
        },
        "parameters": [
          {
            "name": "token",
            "in": "query",
            "required": true,
            "schema": {
              "type": "string"
            },
            "description": "Enter your Apify token here"
          }
        ],
        "responses": {
          "200": {
            "description": "OK"
          }
        }
      }
    }
  },
  "components": {
    "schemas": {
      "inputSchema": {
        "type": "object",
        "properties": {
          "hashtags": {
            "title": "Hashtags",
            "type": "array",
            "description": "Use this when you know the public Instagram hashtags whose posts you need. Enter tags with or without #, for example fitness, streetphotography, or #skincare. The actor deduplicates tags and defaults to the prefilled fitness example. This is not an Instagram profile URL; use Instagram hashtag URLs in the next field.",
            "items": {
              "type": "string"
            }
          },
          "startUrls": {
            "title": "Instagram hashtag URLs",
            "type": "array",
            "description": "Use this when you already have Instagram hashtag landing-page URLs. Enter a full URL such as https://www.instagram.com/explore/tags/fitness/ and the actor extracts the tag. You may combine these URLs with the Hashtags field. This does not accept post, Reel, profile, or arbitrary Instagram URLs.",
            "items": {
              "type": "object",
              "properties": {
                "url": {
                  "type": "string",
                  "title": "URL",
                  "description": "Instagram hashtag URL."
                }
              }
            }
          },
          "datePosted": {
            "title": "Date posted",
            "enum": [
              "any",
              "last-hour",
              "last-day",
              "last-week",
              "last-month",
              "last-year"
            ],
            "type": "string",
            "description": "Use this when freshness matters more than the widest public result set. Choose a listed window such as last-week; the default is last-week. Recent windows can be sparse because results come from Google-indexed public posts. This is not an exact Instagram-native publish-date query.",
            "default": "last-week"
          },
          "mediaType": {
            "title": "Media type",
            "enum": [
              "all",
              "reels"
            ],
            "type": "string",
            "description": "Use this when you need all public post formats or only short-form Reels. Choose all for mixed results or reels for video-only research. The default is all. This filter does not include Stories, private posts, or follower lists.",
            "default": "all"
          },
          "maxPostsPerHashtag": {
            "title": "Maximum posts per hashtag",
            "minimum": 1,
            "maximum": 500,
            "type": "integer",
            "description": "Use this when you need to cap saved posts and billable default-dataset events for each hashtag. Enter an integer from 1 to 500; the default is 50. The actor stops saving once this limit is reached for a tag. This is a per-hashtag limit, not a total limit across all hashtags.",
            "default": 50
          },
          "maxProviderPages": {
            "title": "Maximum provider pages",
            "minimum": 1,
            "maximum": 60,
            "type": "integer",
            "description": "Use this advanced control when you need to restrict provider page requests. Enter an integer from 1 to 60; the default is 60. Lower values are useful for low-cost canaries and controlled tests. This limits provider pages, not the number of posts saved directly.",
            "default": 60
          },
          "startCursor": {
            "title": "Start cursor",
            "maxLength": 200,
            "type": "string",
            "description": "Use this when continuing one hashtag from a cursor in a previous RUN_SUMMARY. Paste the cursor exactly, for example 2, and keep the same hashtag and filters. Leave it blank to start from the first provider page. This is one shared continuation cursor, not a post URL or a separate cursor per hashtag."
          },
          "minimumLikes": {
            "title": "Minimum likes",
            "minimum": 0,
            "type": "integer",
            "description": "Use this when only posts with a minimum public like count are relevant. Enter a whole number such as 100; the default is 0 and keeps all returned posts. Posts below this value are filtered before any dataset event is charged. This is not a minimum engagement-rate filter.",
            "default": 0
          },
          "includeComments": {
            "title": "Include sample comments",
            "type": "boolean",
            "description": "Use this when your workflow needs the public sample comments returned with a post. Enable it for richer research records or leave it off for smaller output. The default is off. This does not fetch every comment or provide private or login-only discussions.",
            "default": false
          },
          "outputMode": {
            "title": "Output mode",
            "enum": [
              "full",
              "compact"
            ],
            "type": "string",
            "description": "Use this when choosing between concise agent-friendly rows and richer research rows. Choose compact for common post and engagement fields, or full for media, author, cursor, and optional comment fields. The default is full. This changes returned field breadth, not what Instagram content the provider can discover.",
            "default": "full"
          }
        }
      },
      "runsResponseSchema": {
        "type": "object",
        "properties": {
          "data": {
            "type": "object",
            "properties": {
              "id": {
                "type": "string"
              },
              "actId": {
                "type": "string"
              },
              "userId": {
                "type": "string"
              },
              "startedAt": {
                "type": "string",
                "format": "date-time",
                "example": "2025-01-08T00:00:00.000Z"
              },
              "finishedAt": {
                "type": "string",
                "format": "date-time",
                "example": "2025-01-08T00:00:00.000Z"
              },
              "status": {
                "type": "string",
                "example": "READY"
              },
              "meta": {
                "type": "object",
                "properties": {
                  "origin": {
                    "type": "string",
                    "example": "API"
                  },
                  "userAgent": {
                    "type": "string"
                  }
                }
              },
              "stats": {
                "type": "object",
                "properties": {
                  "inputBodyLen": {
                    "type": "integer",
                    "example": 2000
                  },
                  "rebootCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "restartCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "resurrectCount": {
                    "type": "integer",
                    "example": 0
                  },
                  "computeUnits": {
                    "type": "integer",
                    "example": 0
                  }
                }
              },
              "options": {
                "type": "object",
                "properties": {
                  "build": {
                    "type": "string",
                    "example": "latest"
                  },
                  "timeoutSecs": {
                    "type": "integer",
                    "example": 300
                  },
                  "memoryMbytes": {
                    "type": "integer",
                    "example": 1024
                  },
                  "diskMbytes": {
                    "type": "integer",
                    "example": 2048
                  }
                }
              },
              "buildId": {
                "type": "string"
              },
              "defaultKeyValueStoreId": {
                "type": "string"
              },
              "defaultDatasetId": {
                "type": "string"
              },
              "defaultRequestQueueId": {
                "type": "string"
              },
              "buildNumber": {
                "type": "string",
                "example": "1.0.0"
              },
              "containerUrl": {
                "type": "string"
              },
              "usage": {
                "type": "object",
                "properties": {
                  "ACTOR_COMPUTE_UNITS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_WRITES": {
                    "type": "integer",
                    "example": 1
                  },
                  "KEY_VALUE_STORE_LISTS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_INTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_EXTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_SERPS": {
                    "type": "integer",
                    "example": 0
                  }
                }
              },
              "usageTotalUsd": {
                "type": "number",
                "example": 0.00005
              },
              "usageUsd": {
                "type": "object",
                "properties": {
                  "ACTOR_COMPUTE_UNITS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATASET_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "KEY_VALUE_STORE_WRITES": {
                    "type": "number",
                    "example": 0.00005
                  },
                  "KEY_VALUE_STORE_LISTS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_READS": {
                    "type": "integer",
                    "example": 0
                  },
                  "REQUEST_QUEUE_WRITES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_INTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "DATA_TRANSFER_EXTERNAL_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                    "type": "integer",
                    "example": 0
                  },
                  "PROXY_SERPS": {
                    "type": "integer",
                    "example": 0
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}