{
  "openapi": "3.0.1",
  "info": {
    "title": "Evidence-Based B2B Lead Qualification & Outreach",
    "description": "Turn a company list into evidence-backed ICP scores, buying-signal explanations, and ready-to-review LinkedIn and email outreach. Bring your own AI and research keys.",
    "version": "0.3",
    "x-build-id": "HrklSddbSJdlLWblC"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/nextlabs~ai-lead-qualifier-outreach/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-nextlabs-ai-lead-qualifier-outreach",
        "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/nextlabs~ai-lead-qualifier-outreach/runs": {
      "post": {
        "operationId": "runs-sync-nextlabs-ai-lead-qualifier-outreach",
        "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/nextlabs~ai-lead-qualifier-outreach/run-sync": {
      "post": {
        "operationId": "run-sync-nextlabs-ai-lead-qualifier-outreach",
        "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": [
          "leads",
          "offerDescription",
          "idealCustomerProfile",
          "qualificationCriteria",
          "aiProvider"
        ],
        "properties": {
          "leads": {
            "title": "Leads",
            "minItems": 1,
            "maxItems": 200,
            "type": "array",
            "description": "1-200 B2B leads. Each lead needs a company name or public company website. LinkedIn URLs are context only and are not scraped.",
            "items": {
              "type": "object",
              "additionalProperties": false,
              "properties": {
                "fullName": {
                  "type": "string",
                  "title": "Full name",
                  "description": "Lead full name, if known.",
                  "maxLength": 200
                },
                "jobTitle": {
                  "type": "string",
                  "title": "Job title",
                  "description": "Lead role or job title, if known.",
                  "maxLength": 300
                },
                "companyName": {
                  "type": "string",
                  "title": "Company name",
                  "description": "Company name. Required if companyUrl is not provided.",
                  "maxLength": 300
                },
                "companyUrl": {
                  "type": "string",
                  "title": "Company website",
                  "description": "Public HTTP/HTTPS website. Required if companyName is not provided. Private, local, and cloud-metadata addresses are blocked.",
                  "maxLength": 2048
                },
                "linkedinUrl": {
                  "type": "string",
                  "title": "LinkedIn URL",
                  "description": "Optional reference only; this Actor does not scrape LinkedIn.",
                  "maxLength": 2048
                },
                "notes": {
                  "type": "string",
                  "title": "Factual lead notes",
                  "description": "Optional facts you already know. Do not use this field to prescribe the desired score.",
                  "maxLength": 3000
                }
              }
            }
          },
          "offerDescription": {
            "title": "What you sell",
            "minLength": 20,
            "maxLength": 3000,
            "type": "string",
            "description": "Describe the offer being sold, the problem it solves, and the value delivered. This anchors qualification and outreach."
          },
          "idealCustomerProfile": {
            "title": "Ideal customer profile",
            "minLength": 20,
            "maxLength": 3000,
            "type": "string",
            "description": "Describe the ideal company: size, sector, geography, operating model, maturity, and buying situation."
          },
          "qualificationCriteria": {
            "title": "Qualification criteria",
            "minItems": 1,
            "maxItems": 12,
            "type": "array",
            "description": "1-12 concrete, observable conditions. Scores are calculated only from these criteria.",
            "items": {
              "type": "string",
              "minLength": 2,
              "maxLength": 300
            }
          },
          "disqualifiers": {
            "title": "Disqualifiers",
            "maxItems": 12,
            "type": "array",
            "description": "Optional hard exclusions. A supported match caps the lead readiness score.",
            "items": {
              "type": "string",
              "minLength": 2,
              "maxLength": 300
            }
          },
          "targetRoles": {
            "title": "Target roles",
            "maxItems": 20,
            "type": "array",
            "description": "Roles that are relevant to the buying process, used for the contact relevance score.",
            "items": {
              "type": "string",
              "minLength": 2,
              "maxLength": 200
            }
          },
          "targetIndustries": {
            "title": "Target industries",
            "maxItems": 20,
            "type": "array",
            "description": "Optional industry focus used to guide research, not to fabricate a match.",
            "items": {
              "type": "string",
              "minLength": 2,
              "maxLength": 200
            }
          },
          "targetCountries": {
            "title": "Target countries",
            "maxItems": 20,
            "type": "array",
            "description": "Optional target geographies.",
            "items": {
              "type": "string",
              "minLength": 2,
              "maxLength": 100
            }
          },
          "outreachGoal": {
            "title": "Outreach goal",
            "minLength": 10,
            "maxLength": 500,
            "type": "string",
            "description": "The next step the message should seek.",
            "default": "Start a short discovery conversation."
          },
          "aiProvider": {
            "title": "AI provider",
            "enum": [
              "openrouter",
              "openai",
              "anthropic",
              "gemini",
              "deepseek",
              "mistral",
              "groq",
              "zenmux",
              "xai",
              "qwen",
              "nvidia"
            ],
            "type": "string",
            "description": "Bring your own API key. OpenRouter provides access to hundreds of model/provider combinations through one account; the direct options use each provider API.",
            "default": "openrouter"
          },
          "aiApiKey": {
            "title": "AI API key",
            "type": "string",
            "description": "Optional override. Leave blank to use the provider-specific secret environment variable configured on the Actor (for example OPENAI_API_KEY)."
          },
          "model": {
            "title": "Model override",
            "maxLength": 300,
            "type": "string",
            "description": "Optional exact model identifier. Leave blank to use the provider default. Examples: OpenRouter openrouter/free, Gemini gemini-3.5-flash, DeepSeek deepseek-v4-flash, Qwen qwen-flash, Groq openai/gpt-oss-120b, NVIDIA NIM meta/llama-3.1-70b-instruct. Model IDs are passed through unchanged."
          },
          "researchProvider": {
            "title": "Research provider",
            "enum": [
              "website-only",
              "tavily"
            ],
            "type": "string",
            "description": "Website-only crawls useful pages on the supplied company domain. Tavily also searches the public web.",
            "default": "website-only"
          },
          "researchApiKey": {
            "title": "Tavily API key",
            "type": "string",
            "description": "Optional override. Leave blank to use the secret TAVILY_API_KEY environment variable when Tavily is selected."
          },
          "researchDepth": {
            "title": "Research depth",
            "enum": [
              "homepage",
              "standard",
              "deep"
            ],
            "type": "string",
            "description": "Homepage fetches one page; Standard crawls up to 4 useful pages; Deep crawls up to 6.",
            "default": "standard"
          },
          "verificationMode": {
            "title": "Evidence verification",
            "enum": [
              "standard",
              "deep"
            ],
            "type": "string",
            "description": "Standard uses deterministic citation guardrails and one LLM call. Deep adds a second LLM evidence-checking pass.",
            "default": "deep"
          },
          "language": {
            "title": "Output language",
            "enum": [
              "it",
              "en"
            ],
            "type": "string",
            "description": "Language used for the analysis and outreach copy.",
            "default": "it"
          },
          "messageStyle": {
            "title": "Outreach style",
            "enum": [
              "soft-consultative",
              "direct",
              "friendly",
              "formal"
            ],
            "type": "string",
            "description": "Tone used for the generated outreach.",
            "default": "soft-consultative"
          },
          "maxMessageChars": {
            "title": "Maximum LinkedIn DM characters",
            "minimum": 120,
            "maximum": 1000,
            "type": "integer",
            "description": "The generated message is trimmed to this limit.",
            "default": 300
          },
          "includeEmail": {
            "title": "Generate email too",
            "type": "boolean",
            "description": "Generate an email subject and body in addition to the LinkedIn DM.",
            "default": true
          },
          "maxConcurrency": {
            "title": "Maximum concurrent leads",
            "minimum": 1,
            "maximum": 10,
            "type": "integer",
            "description": "Controls speed and provider rate-limit pressure.",
            "default": 4
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}