{
  "openapi": "3.0.1",
  "info": {
    "title": "Instagram Competitor Content Monitor",
    "description": "Turn Instagram profile or post records into ranked, evidence-backed Instagram intelligence signals.",
    "version": "1.0",
    "x-build-id": "IfAdgk9mDml7SbaM3"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/night111~instagram-competitor-content-monitor/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-night111-instagram-competitor-content-monitor",
        "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/night111~instagram-competitor-content-monitor/runs": {
      "post": {
        "operationId": "runs-sync-night111-instagram-competitor-content-monitor",
        "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/night111~instagram-competitor-content-monitor/run-sync": {
      "post": {
        "operationId": "run-sync-night111-instagram-competitor-content-monitor",
        "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": {
          "sourceMode": {
            "title": "Input source",
            "enum": [
              "inline",
              "dataset",
              "upstream-actor",
              "official-api"
            ],
            "type": "string",
            "description": "Choose exactly one source. Inline is ideal for testing and integrations; dataset is safest for production pipelines.",
            "default": "inline"
          },
          "records": {
            "title": "Current Instagram profile or post records",
            "maxItems": 5000,
            "type": "array",
            "description": "Raw current records. Typical identity fields: id, pk, shortCode, shortcode, url, username.",
            "items": {
              "type": "object"
            }
          },
          "datasetId": {
            "title": "Current Apify dataset",
            "type": "string",
            "description": "Dataset ID or name containing current records. Tokens in URLs are rejected."
          },
          "upstreamActorId": {
            "title": "Upstream Actor ID",
            "type": "string",
            "description": "Optional Actor ID/name to call. The caller pays upstream costs; use only an Actor you trust and are authorized to run."
          },
          "upstreamActorInput": {
            "title": "Upstream Actor input",
            "type": "object",
            "description": "JSON passed to the selected upstream Actor. Never paste credentials unless its schema marks them secret.",
            "default": {}
          },
          "officialApiUrl": {
            "title": "Authorized HTTPS JSON API URL",
            "pattern": "^https://",
            "type": "string",
            "description": "Optional first-party or licensed JSON endpoint. HTTPS only. Query-string tokens are rejected; use secret headers."
          },
          "officialApiHeaders": {
            "title": "Secret API headers",
            "type": "object",
            "description": "Optional request headers such as Authorization. Stored encrypted by Apify."
          },
          "officialApiItemsPath": {
            "title": "JSON items path",
            "type": "string",
            "description": "Dot path to the result array, for example data.items. Leave blank when the response itself is an array.",
            "default": ""
          },
          "previousRecords": {
            "title": "Previous Instagram profile or post records",
            "maxItems": 5000,
            "type": "array",
            "description": "Optional prior snapshot used for state comparison. Omit for a first-seen baseline.",
            "items": {
              "type": "object"
            }
          },
          "previousDatasetId": {
            "title": "Previous Apify dataset",
            "type": "string",
            "description": "Optional dataset ID/name containing the previous snapshot."
          },
          "minimumScore": {
            "title": "Minimum priority score",
            "minimum": 0,
            "maximum": 100,
            "type": "integer",
            "description": "Only deliver actionable records at or above this deterministic 0–100 score.",
            "default": 35
          },
          "maxEvents": {
            "title": "Maximum delivered insights",
            "minimum": 1,
            "maximum": 5000,
            "type": "integer",
            "description": "Hard output cap in addition to Apify maxTotalChargeUsd. Highest-priority records are delivered first.",
            "default": 100
          },
          "includeNew": {
            "title": "Include newly seen entities",
            "type": "boolean",
            "description": "Emit entities missing from the previous snapshot.",
            "default": true
          },
          "includeChanged": {
            "title": "Include changed entities",
            "type": "boolean",
            "description": "Emit entities with meaningful configured field changes.",
            "default": true
          },
          "includeRemoved": {
            "title": "Include removed entities",
            "type": "boolean",
            "description": "Emit entities present previously but absent now.",
            "default": false
          },
          "includeUnchanged": {
            "title": "Include unchanged entities",
            "type": "boolean",
            "description": "Usually off to avoid paying for non-actionable records.",
            "default": false
          },
          "customIdFields": {
            "title": "Custom identity fields",
            "type": "array",
            "description": "Optional override. Defaults: id, pk, shortCode, shortcode, url, username.",
            "items": {
              "type": "string"
            }
          },
          "customCompareFields": {
            "title": "Custom comparison fields",
            "type": "array",
            "description": "Optional override. Defaults: username, fullName, followersCount, followingCount, postsCount, likesCount, commentsCount, videoViewCount, engagementRate, isVerified, biography.",
            "items": {
              "type": "string"
            }
          },
          "fuzzyEntityResolution": {
            "title": "Fuzzy entity resolution",
            "type": "boolean",
            "description": "Best-effort normalized-name matching when no strong identifier exists. Exact IDs always win.",
            "default": true
          },
          "debug": {
            "title": "Debug diagnostics",
            "type": "boolean",
            "description": "Store non-billable diagnostics in the OUTPUT record and verbose logs.",
            "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
                  }
                }
              },
              "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}