{
  "openapi": "3.0.1",
  "info": {
    "title": "Instagram Hashtag Scraper — Posts, Reels & Creator Discovery",
    "description": "Find recent and top Instagram posts and reels by hashtag. Discover creators, explore hashtag analytics and export captions, available engagement metrics and the first 20 comments per post.",
    "version": "0.2",
    "x-build-id": "MyJGzzUJAq7u9PAua"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/monkey.d.scraping~instagram-hashtag-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-monkey.d.scraping-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/monkey.d.scraping~instagram-hashtag-scraper/runs": {
      "post": {
        "operationId": "runs-sync-monkey.d.scraping-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/monkey.d.scraping~instagram-hashtag-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-monkey.d.scraping-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 or search terms",
            "type": "array",
            "description": "One per line: a hashtag (coffee or #coffee), a search term of several words (milano fashion week) or a hashtag link. Each one returns recent posts and reels with that hashtag or naming the term, and the top reels Instagram lists for it, from any public account, plus an analytics row.",
            "items": {
              "type": "string"
            }
          },
          "resultsType": {
            "title": "Which results",
            "enum": [
              "all",
              "recent",
              "top"
            ],
            "type": "string",
            "description": "Recent results are photos, carousels and reels published in the chosen period that carry the hashtag. Top results are the reels Instagram ranks first; for hashtags Instagram does not rank, the most liked posts and reels of any date.",
            "default": "all"
          },
          "recentPeriod": {
            "title": "Recent means the last",
            "enum": [
              "day",
              "week",
              "month",
              "year"
            ],
            "type": "string",
            "description": "Period for recent results.",
            "default": "week"
          },
          "maxResultsPerHashtag": {
            "title": "Max results per hashtag",
            "minimum": 0,
            "type": "integer",
            "description": "Posts and reels kept for each hashtag. 0 = everything found.",
            "default": 50
          },
          "postUrls": {
            "title": "Post or reel links",
            "type": "array",
            "description": "Links to single posts, reels or videos (instagram.com/p/…, /reel/…). Each link returns that post with its details.",
            "items": {
              "type": "string"
            }
          },
          "contentType": {
            "title": "Content type",
            "enum": [
              "all",
              "posts",
              "reels"
            ],
            "type": "string",
            "description": "Photos and carousels, reels, or both.",
            "default": "all"
          },
          "exactHashtagOnly": {
            "title": "Only results that carry the hashtag",
            "type": "boolean",
            "description": "Keep only posts and reels with the exact hashtag in the caption (for a search term of several words, every word). When off, recent results also include posts that name the term without the #, such as a brand in plain text. Results filtered out are not charged.",
            "default": false
          },
          "includeRelatedSearches": {
            "title": "Also read related searches",
            "type": "boolean",
            "description": "Also read close wordings and related searches of the hashtag (for example \"iced coffee\" and \"coffee tips\" for \"coffee\"): many more top reels per hashtag, up to the maximum above.",
            "default": false
          },
          "includeDetails": {
            "title": "Likes, comments, date and audio of each reel",
            "type": "boolean",
            "description": "Likes, comment count, publication date, audio, tags and collaborations of every result, plus like rate and views per day. Turn off for the fastest list of top reels with views, caption, author and video link.",
            "default": true
          },
          "commentsPerPost": {
            "title": "Comments per reel",
            "minimum": 0,
            "type": "integer",
            "description": "Latest comments of each post. The first 20 are included in the post row at no extra cost; further ones are saved as comment rows.",
            "default": 0
          },
          "postedAfter": {
            "title": "Only reels published since",
            "pattern": "^$|^\\d{4}-\\d{2}-\\d{2}",
            "type": "string",
            "description": "Keep only results published on or after this day (00:00 UTC). Leave empty for all dates."
          },
          "minViews": {
            "title": "Minimum views",
            "minimum": 0,
            "type": "integer",
            "description": "Keep only results with at least this many views. 0 = no filter. Reels filtered out are not charged.",
            "default": 0
          },
          "minLikes": {
            "title": "Minimum likes",
            "minimum": 0,
            "type": "integer",
            "description": "Keep only results with at least this many likes. 0 = no filter. Reels filtered out are not charged.",
            "default": 0
          },
          "onlyNewReels": {
            "title": "Only results not returned before",
            "type": "boolean",
            "description": "For scheduled tasks: each run returns only the posts and reels that earlier runs of the same task did not return for that hashtag. The first run returns everything.",
            "default": false
          }
        }
      },
      "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
                  },
                  "PROXY_UNBLOCKER_UNITS": {
                    "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
                  },
                  "PROXY_UNBLOCKER_UNITS": {
                    "type": "integer",
                    "example": 0
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}