{
  "openapi": "3.0.1",
  "info": {
    "title": "TheirStack Signal Orchestrator - Lead Intelligence",
    "description": "Theirstack Signal Orchestrator helps teams get quick, high-signal results with reliable output, clear fields, and fast setup.",
    "version": "0.1",
    "x-build-id": "cWvYzLWvkTdXZ4Hsh"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/apricot_blackberry~theirstack-signal-orchestrator/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-apricot_blackberry-theirstack-signal-orchestrator",
        "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/apricot_blackberry~theirstack-signal-orchestrator/runs": {
      "post": {
        "operationId": "runs-sync-apricot_blackberry-theirstack-signal-orchestrator",
        "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/apricot_blackberry~theirstack-signal-orchestrator/run-sync": {
      "post": {
        "operationId": "run-sync-apricot_blackberry-theirstack-signal-orchestrator",
        "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": [
          "searchMode",
          "theirstackApiKey"
        ],
        "properties": {
          "searchMode": {
            "title": "Search mode",
            "enum": [
              "companySearch",
              "jobSearch",
              "domainEnrichment",
              "monitoring"
            ],
            "type": "string",
            "description": "How the Actor should query data.",
            "default": "companySearch"
          },
          "theirstackApiKey": {
            "title": "TheirStack API key",
            "type": "string",
            "description": "Your TheirStack API key. Store as an Apify secret for security."
          },
          "queryName": {
            "title": "Query name",
            "type": "string",
            "description": "Human-readable name used in summaries and exports.",
            "default": ""
          },
          "domains": {
            "title": "Domains",
            "type": "array",
            "description": "Domains to enrich directly. Required for domainEnrichment mode.",
            "items": {
              "type": "string"
            }
          },
          "technologiesInclude": {
            "title": "Include technologies",
            "type": "array",
            "description": "Technologies the company should use.",
            "items": {
              "type": "string"
            }
          },
          "technologiesExclude": {
            "title": "Exclude technologies",
            "type": "array",
            "description": "Technologies the company should not use.",
            "items": {
              "type": "string"
            }
          },
          "jobKeywordsAny": {
            "title": "Job keywords (any)",
            "type": "array",
            "description": "At least one keyword should appear in job evidence.",
            "items": {
              "type": "string"
            }
          },
          "jobKeywordsAll": {
            "title": "Job keywords (all)",
            "type": "array",
            "description": "All keywords must appear in job evidence.",
            "items": {
              "type": "string"
            }
          },
          "jobKeywordsNot": {
            "title": "Job keywords (exclude)",
            "type": "array",
            "description": "Keywords to exclude from job evidence.",
            "items": {
              "type": "string"
            }
          },
          "companyLocations": {
            "title": "Company locations",
            "type": "array",
            "description": "Filter companies by headquarters location.",
            "items": {
              "type": "string"
            }
          },
          "jobLocations": {
            "title": "Job locations",
            "type": "array",
            "description": "Filter job evidence by job location.",
            "items": {
              "type": "string"
            }
          },
          "industries": {
            "title": "Industries",
            "type": "array",
            "description": "Filter companies by industry classification.",
            "items": {
              "type": "string"
            }
          },
          "companySizeMin": {
            "title": "Minimum company size",
            "minimum": 1,
            "type": "integer",
            "description": "Minimum number of employees.",
            "default": 1
          },
          "companySizeMax": {
            "title": "Maximum company size",
            "minimum": 1,
            "type": "integer",
            "description": "Maximum number of employees.",
            "default": 10000
          },
          "postedAfter": {
            "title": "Posted after",
            "type": "string",
            "description": "Only consider job evidence posted after this date (YYYY-MM-DD).",
            "default": ""
          },
          "maxCompanies": {
            "title": "Maximum companies",
            "minimum": 1,
            "maximum": 10000,
            "type": "integer",
            "description": "Maximum number of companies to return.",
            "default": 250
          },
          "maxJobsPerCompany": {
            "title": "Max jobs per company",
            "minimum": 0,
            "maximum": 50,
            "type": "integer",
            "description": "Maximum number of job postings to include per company.",
            "default": 3
          },
          "includeTechnologies": {
            "title": "Include technologies",
            "type": "boolean",
            "description": "Include matched technologies in output.",
            "default": true
          },
          "includeJobs": {
            "title": "Include job evidence",
            "type": "boolean",
            "description": "Include matched job postings in output.",
            "default": true
          },
          "includeSignals": {
            "title": "Include derived signals",
            "type": "boolean",
            "description": "Include derived signal booleans (technologyFit, hiringIntent, etc.).",
            "default": true
          },
          "dedupeBy": {
            "title": "Dedupe by",
            "enum": [
              "companyDomain",
              "companyName",
              "none"
            ],
            "type": "string",
            "description": "Strategy for deduplicating results.",
            "default": "companyDomain"
          },
          "scoring": {
            "title": "Scoring weights",
            "type": "object",
            "description": "Weights for the lead scoring components. Should sum to 1.0.",
            "properties": {
              "technologyMatchWeight": {
                "title": "Technology match weight",
                "description": "Weight for technology match scoring (0-1).",
                "type": "number",
                "minimum": 0,
                "maximum": 1,
                "default": 0.4
              },
              "jobIntentWeight": {
                "title": "Job intent weight",
                "description": "Weight for hiring intent scoring (0-1).",
                "type": "number",
                "minimum": 0,
                "maximum": 1,
                "default": 0.35
              },
              "recencyWeight": {
                "title": "Recency weight",
                "description": "Weight for evidence recency scoring (0-1).",
                "type": "number",
                "minimum": 0,
                "maximum": 1,
                "default": 0.15
              },
              "companyFitWeight": {
                "title": "Company fit weight",
                "description": "Weight for company fit scoring (0-1).",
                "type": "number",
                "minimum": 0,
                "maximum": 1,
                "default": 0.1
              }
            },
            "default": {
              "technologyMatchWeight": 0.4,
              "jobIntentWeight": 0.35,
              "recencyWeight": 0.15,
              "companyFitWeight": 0.1
            }
          },
          "outputMode": {
            "title": "Output mode",
            "enum": [
              "companiesOnly",
              "jobsOnly",
              "companyWithEvidence",
              "companyWithTech"
            ],
            "type": "string",
            "description": "What data to include in each output record.",
            "default": "companyWithEvidence"
          },
          "monitoringMode": {
            "title": "Monitoring mode",
            "type": "boolean",
            "description": "Compare results to a baseline dataset and flag new companies.",
            "default": false
          },
          "baselineDatasetId": {
            "title": "Baseline dataset ID",
            "type": "string",
            "description": "Dataset used for change detection in monitoring mode.",
            "default": ""
          },
          "webhookMetadata": {
            "title": "Webhook metadata",
            "type": "object",
            "description": "Pass-through metadata copied to summary output.",
            "default": {}
          },
          "debug": {
            "title": "Debug mode",
            "type": "boolean",
            "description": "Enable verbose logging for troubleshooting.",
            "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}