{
  "openapi": "3.0.1",
  "info": {
    "title": "Instagram Scraper · Posts, Reels, Profiles & More",
    "description": "Scrape anything public on Instagram in one run: profiles, posts, reels, comments, hashtags, places and sounds — mixed links or usernames, or a search. Saves and shares on reels; each row at the price of its kind. Works with the input of Apify's Instagram Scraper. No login.",
    "version": "1.0",
    "x-build-id": "iATbhxn0n5Ic2pu0B"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/instagram-data-api~instagram-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-instagram-data-api-instagram-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/instagram-data-api~instagram-scraper/runs": {
      "post": {
        "operationId": "runs-sync-instagram-data-api-instagram-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/instagram-data-api~instagram-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-instagram-data-api-instagram-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": {
          "directUrls": {
            "title": "Instagram links or usernames",
            "type": "array",
            "description": "Anything, one per line: a profile (<code>natgeo</code> or its link), a post or reel link, a hashtag (<code>#skincare</code> or its link), a place link or a sound link. Each line becomes rows of its own kind.",
            "items": {
              "type": "string"
            }
          },
          "resultsType": {
            "title": "What to get",
            "enum": [
              "posts",
              "reels",
              "details",
              "comments",
              "mentions",
              "stories"
            ],
            "type": "string",
            "description": "The same choice as in Apify's Instagram Scraper. Post and reel links always return the post itself unless you choose Comments.",
            "default": "posts"
          },
          "resultsLimit": {
            "title": "Results per link",
            "minimum": 1,
            "maximum": 5000,
            "type": "integer",
            "description": "How many posts, reels or comments to take per link. Empty — each kind's own default (24 posts, 500 comments…)."
          },
          "onlyPostsNewerThan": {
            "title": "Only posts newer than",
            "type": "string",
            "description": "A date (<code>2026-10-01</code>) or a period (<code>7 days</code>, <code>2 weeks</code>). Empty — no date limit. Older pinned items are left out too."
          },
          "onlyPostsOlderThan": {
            "title": "Only posts older than",
            "type": "string",
            "description": "A date (<code>2026-09-01</code>) or a period (<code>30 days</code>). With “Only items newer than” — a date range. Newer items are skipped and aren't charged."
          },
          "skipPinnedPosts": {
            "title": "Skip pinned items",
            "type": "boolean",
            "description": "Leave out the items the creator pinned to the top of the profile.",
            "default": false
          },
          "search": {
            "title": "Or: search",
            "type": "string",
            "description": "A keyword, a #hashtag or a place name; several — separated by commas."
          },
          "searchType": {
            "title": "Search for",
            "enum": [
              "hashtag",
              "profile",
              "place",
              "user",
              "reel"
            ],
            "type": "string",
            "description": "Hashtag returns the posts under it; Profiles and Places return what the search finds (with Details — full profile cards).",
            "default": "hashtag"
          },
          "searchLimit": {
            "title": "Search results limit",
            "minimum": 1,
            "maximum": 1000,
            "type": "integer",
            "description": "How many profiles, places or hashtags to find per keyword.",
            "default": 10
          },
          "onlyNew": {
            "title": "Only new since the last run",
            "type": "boolean",
            "description": "For scheduled monitoring: rows you already received in earlier runs with the same input are skipped and <b>not charged</b>.",
            "default": false
          },
          "datasetId": {
            "title": "Or: dataset from another run",
            "type": "string",
            "description": "Pick the dataset of an earlier run (or paste its ID). We take links and usernames from <code>url</code>, <code>inputUrl</code>, <code>profileUrl</code> or <code>username</code> — rows of any Instagram Actor."
          },
          "returnWithinSecs": {
            "title": "Return what's ready after (seconds)",
            "minimum": 10,
            "maximum": 3600,
            "type": "integer",
            "description": "Stop after this many seconds and return the results collected so far — you pay only for them. Handy for AI agents with a short tool timeout. Empty — run until everything is collected."
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}