{
  "openapi": "3.0.1",
  "info": {
    "title": "Alternative Social Media Trend Monitor & OSINT",
    "description": "Monitor public 4chan, Gab, GETTR, Telegram, and Pastebin data. Get evidence-linked narratives, trend scores, source coverage, and fresh OSINT datasets.",
    "version": "0.1",
    "x-build-id": "ublQyhX9ZnIxEmsHv"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/thescrapelab~alt-social-narrative-trend-intelligence/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-thescrapelab-alt-social-narrative-trend-intelligence",
        "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/thescrapelab~alt-social-narrative-trend-intelligence/runs": {
      "post": {
        "operationId": "runs-sync-thescrapelab-alt-social-narrative-trend-intelligence",
        "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/thescrapelab~alt-social-narrative-trend-intelligence/run-sync": {
      "post": {
        "operationId": "run-sync-thescrapelab-alt-social-narrative-trend-intelligence",
        "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": [
          "mode",
          "sources",
          "searchDepth"
        ],
        "properties": {
          "mode": {
            "title": "Analysis mode",
            "enum": [
              "discover",
              "watchlist"
            ],
            "type": "string",
            "description": "Discover clusters the bounded fresh sample; watchlist keeps evidence matching your queries.",
            "default": "discover"
          },
          "queries": {
            "title": "Watchlist queries",
            "maxItems": 10,
            "type": "array",
            "description": "Required in watchlist mode. Use one to ten phrases, hashtags, or domains.",
            "items": {
              "type": "string",
              "minLength": 2,
              "maxLength": 120
            },
            "default": []
          },
          "sources": {
            "title": "Public sources",
            "minItems": 1,
            "maxItems": 5,
            "uniqueItems": true,
            "type": "array",
            "description": "Only selected sources launch child runs. The low-cost default runs five fresh 4chan threads only.",
            "items": {
              "type": "string",
              "enum": [
                "4chan",
                "gab",
                "gettr",
                "telegram",
                "pastebin"
              ],
              "enumTitles": [
                "4chan",
                "Gab",
                "GETTR",
                "Telegram",
                "Pastebin"
              ]
            },
            "default": [
              "4chan"
            ]
          },
          "fourchanBoards": {
            "title": "4chan boards",
            "maxItems": 10,
            "type": "array",
            "description": "Public 4chan board names without slashes. Quick runs inspect at most five threads in total.",
            "items": {
              "type": "string",
              "pattern": "^/?[A-Za-z0-9]+/?$"
            },
            "default": [
              "g"
            ]
          },
          "gabTargets": {
            "title": "Gab usernames or public URLs",
            "maxItems": 20,
            "type": "array",
            "description": "Optional public Gab usernames, profile URLs, or direct post URLs.",
            "items": {
              "type": "string",
              "minLength": 1,
              "maxLength": 500
            },
            "default": []
          },
          "gettrUsernames": {
            "title": "GETTR usernames",
            "maxItems": 20,
            "type": "array",
            "description": "Optional public GETTR usernames; the @ prefix is not required.",
            "items": {
              "type": "string",
              "minLength": 1,
              "maxLength": 100
            },
            "default": []
          },
          "telegramChannels": {
            "title": "Telegram public channels",
            "maxItems": 20,
            "type": "array",
            "description": "Public Telegram channel handles or t.me URLs. Private channels are not supported.",
            "items": {
              "type": "string",
              "minLength": 1,
              "maxLength": 200
            },
            "default": []
          },
          "lookbackHours": {
            "title": "Lookback window",
            "minimum": 1,
            "maximum": 168,
            "type": "integer",
            "description": "Filter normalized evidence to this many hours when source timestamps are available.",
            "default": 24
          },
          "searchDepth": {
            "title": "Search depth",
            "enum": [
              "quick",
              "balanced",
              "deep"
            ],
            "type": "string",
            "description": "Cap normalized collection at 10, 50, or 200 records per source; quick 4chan runs use five threads.",
            "default": "quick"
          },
          "includeEvidenceRows": {
            "title": "Save evidence rows",
            "type": "boolean",
            "description": "Narrative rows always cite evidence IDs. Enable this to also write normalized evidence as separate dataset rows.",
            "default": false
          },
          "includeAiSummaries": {
            "title": "Use optional AI labels and summaries",
            "type": "boolean",
            "description": "Requires the Actor's encrypted OPENROUTER_API_KEY secret. AI cannot change cluster membership and falls back safely if unavailable.",
            "default": false
          },
          "strictMode": {
            "title": "Fail if a source fails",
            "type": "boolean",
            "description": "Advanced API control. The safe default returns useful partial results when one source fails or times out.",
            "default": false
          },
          "maxUpstreamChargeUsd": {
            "title": "Source collection spending limit",
            "minimum": 0.01,
            "maximum": 0.5,
            "type": "number",
            "description": "Advanced API control. The default allows up to $0.05 across source collection runs and remains subject to the operator ceiling.",
            "default": 0.05
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}