{
  "openapi": "3.0.1",
  "info": {
    "title": "Instagram Posts Scraper With Tagged Accounts [🔥Cheapest🔥]",
    "description": "Instagram Post Scraper lets you extract captions, images, likes, comments, and URLs from Instagram posts by hashtag, user, or location. This Instagram Post Scraper exports data to JSON, CSV, or Excel, making it perfect for research, insights, and social media trend tracking.",
    "version": "0.1",
    "x-build-id": "RuaN4MKK1q4zMuAip"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/scraper-engine~instagram-posts-scraper-cheapest/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-scraper-engine-instagram-posts-scraper-cheapest",
        "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/scraper-engine~instagram-posts-scraper-cheapest/runs": {
      "post": {
        "operationId": "runs-sync-scraper-engine-instagram-posts-scraper-cheapest",
        "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/scraper-engine~instagram-posts-scraper-cheapest/run-sync": {
      "post": {
        "operationId": "run-sync-scraper-engine-instagram-posts-scraper-cheapest",
        "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",
        "required": [
          "username"
        ],
        "properties": {
          "username": {
            "title": "👤 Profiles or post links to scrape",
            "type": "array",
            "description": "One target per row. Mix freely: handle (nike), profile URL (https://www.instagram.com/nike/), post URL (https://www.instagram.com/p/SHORTCODE/), reel or tv URL. Duplicates are collapsed. Story / explore / share links are rejected instead of becoming a fake profile named @stories.",
            "items": {
              "type": "string"
            }
          },
          "resultsLimit": {
            "title": "🔢 Posts to save per profile",
            "minimum": 1,
            "maximum": 100000,
            "type": "integer",
            "description": "How many post rows to keep per profile. Ignored for single post URLs. Instagram serves 12 posts per feed request. Default is 10.",
            "default": 10
          },
          "onlyPostsNewerThan": {
            "title": "🗓️ Only posts published after",
            "type": "string",
            "description": "UTC cutoff. Absolute tab: YYYY-MM-DD. Relative tab: '6 hours', '3 days', '1 week', '2 months'. Unreadable values stop the run instead of silently disabling the filter. Leave empty for no cutoff.",
            "default": null
          },
          "skipPinnedPosts": {
            "title": "📌 Drop posts pinned to this grid",
            "type": "boolean",
            "description": "Skip posts pinned on the profile you are scraping. A collab pinned on someone else's grid is kept.",
            "default": false
          },
          "dataDetailLevel": {
            "title": "🔬 How much post data per row",
            "enum": [
              "detailedData",
              "basicData"
            ],
            "type": "string",
            "description": "Detailed opens each post page for alt text, latest comments, carousel short codes and music. Basic is faster (about 2.8s vs 6.2s per 12 posts). Both bill one result row. People/tag columns are filled on both levels from the feed.",
            "default": "detailedData"
          },
          "peopleFilter": {
            "title": "👥 Which posts to keep",
            "enum": [
              "all",
              "photoTagged",
              "collabs",
              "captionMention"
            ],
            "type": "string",
            "description": "all = every post (default, identical to a plain post scrape). photoTagged = only posts with in-photo usertags. collabs = only posts with official coauthor_producers. captionMention = only posts whose caption @mentions someone. Default stays all so a first run never returns zero rows on a low-tag account.",
            "default": "all"
          },
          "taggedUsernames": {
            "title": "🎯 Only posts that include these handles",
            "type": "array",
            "description": "Allow-list. A post is kept if the handle is a photo tag, a coauthor, or a caption @mention. Case-insensitive, @ optional. Empty = no allow-list. Example: ['jbalvin', 'travisscott'].",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "maxPostsToScan": {
            "title": "🔭 Scan ceiling per profile",
            "minimum": 1,
            "maximum": 100000,
            "type": "integer",
            "description": "Upper bound on posts read while hunting for rows that pass a people filter. Ignored when the filter is 'all' and the allow-list is empty (then the scan equals Posts to save). 300 posts is about 25 feed requests. Default 300.",
            "default": 300
          },
          "emitPeopleDataset": {
            "title": "📊 Also write a one-row-per-person table",
            "type": "boolean",
            "description": "Writes an extra dataset named ig-people-<runId> with one uncharged row per photo tag, coauthor and caption mention (type / isChild / parentId). The main post dataset is unchanged. Default on.",
            "default": true
          },
          "proxyConfiguration": {
            "title": "🌐 Proxy",
            "type": "object",
            "description": "The Instagram feed was reachable on residential, datacenter and direct exits in 2026-07-25 measurements. Residential is the default reliability choice.",
            "default": {
              "useApifyProxy": true,
              "apifyProxyGroups": [
                "RESIDENTIAL"
              ]
            }
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}