{
  "openapi": "3.0.1",
  "info": {
    "title": "AI Lead Enricher & Personalizer",
    "description": "Lead enrichment with email verification and AI-written outreach. Cleans your lead list, verifies each email, and generates a send-ready personalized message per lead, each grounded in a real fact with a send-readiness score. Stop guessing which leads are worth contacting.",
    "version": "0.1",
    "x-build-id": "gOFgDOzWbW8UhU1DJ"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/enezli~ai-lead-enricher-personalizer/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-enezli-ai-lead-enricher-personalizer",
        "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/enezli~ai-lead-enricher-personalizer/runs": {
      "post": {
        "operationId": "runs-sync-enezli-ai-lead-enricher-personalizer",
        "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/enezli~ai-lead-enricher-personalizer/run-sync": {
      "post": {
        "operationId": "run-sync-enezli-ai-lead-enricher-personalizer",
        "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"
        ],
        "properties": {
          "leads": {
            "title": "Lead list",
            "type": "array",
            "description": "The companies/people to enrich. Any of {company, website, name, title, email, industry, size, country} is enough. A Maps/Leads Finder scraper's dataset output can be connected DIRECTLY."
          },
          "enrichFields": {
            "title": "Fields to enrich",
            "type": "array",
            "description": "Firmographic fields to fill when missing. (email is NEVER fabricated by the LLM — it only comes from the input and is verified; bounce/reputation protection.)",
            "items": {
              "type": "string",
              "enum": [
                "email",
                "industry",
                "size",
                "country"
              ],
              "enumTitles": [
                "Email (verify only)",
                "Industry",
                "Company size",
                "Country/region"
              ]
            },
            "default": [
              "email",
              "industry",
              "size",
              "country"
            ]
          },
          "outreachTone": {
            "title": "Outreach tone",
            "enum": [
              "samimi-profesyonel",
              "resmi",
              "doğrudan-net",
              "danışman",
              "sıcak-arkadaşça"
            ],
            "type": "string",
            "description": "Tone of the generated message.",
            "default": "samimi-profesyonel"
          },
          "outreachTouches": {
            "title": "Number of touches (follow-up sequence)",
            "minimum": 1,
            "maximum": 4,
            "type": "integer",
            "description": "1 = a single cold email (default). 2-4 = a multi-touch follow-up sequence (first email + polite follow-ups) — most replies come from follow-ups. Generated in a single LLM call (cost ~the same, value higher).",
            "default": 1
          },
          "senderOffer": {
            "title": "Your offer / value proposition",
            "type": "string",
            "description": "A short value proposition to include in the message (what you sell / what you provide). If empty, the message stays generic.",
            "default": ""
          },
          "language": {
            "title": "Output language",
            "enum": [
              "auto",
              "Türkçe",
              "English",
              "Deutsch",
              "Español",
              "Français"
            ],
            "type": "string",
            "description": "Language of the enrichment and message output. If 'Auto' is selected, the language is chosen per lead from the domain's country suffix (e.g. .com.tr -> Turkish, .de -> German); an unknown suffix (.com/.io) falls back to English.",
            "default": "English"
          },
          "icpSectors": {
            "title": "ICP — Target industries (optional)",
            "type": "array",
            "description": "Ideal-customer industries. If filled, leads whose industry does not match are FILTERED OUT and never enter the paid step. e.g. ['software', 'logistics'].",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "icpCountries": {
            "title": "ICP — Target countries/regions (optional)",
            "type": "array",
            "description": "Ideal-customer countries/regions. e.g. ['Turkey', 'Germany'].",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "icpKeywords": {
            "title": "ICP — Keywords (optional)",
            "type": "array",
            "description": "Signals searched in the company name / website / industry / title text. e.g. ['e-commerce', 'SaaS', 'export'].",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "icpMinScore": {
            "title": "ICP threshold (0 = off)",
            "minimum": 0,
            "maximum": 100,
            "type": "integer",
            "description": "Leads with a fit score BELOW this threshold are FILTERED OUT and never enter the paid enrichment/message step (no payment for junk leads). 0 = ICP gate off (all leads processed, backward compatible). Suggested: 50.",
            "default": 0
          },
          "model": {
            "title": "Model (advanced)",
            "enum": [
              "claude-haiku-4-5-20251001",
              "claude-sonnet-4-6"
            ],
            "type": "string",
            "description": "LLM model. The default is cheap and fast; pick a stronger model for deeper messaging.",
            "default": "claude-haiku-4-5-20251001"
          },
          "onayliLeadSayisi": {
            "title": "Approved lead count (cost approval)",
            "minimum": 0,
            "type": "integer",
            "description": "0 = PREVIEW: the actor only reports how many leads there are and the estimated events/cost, WITHOUT processing (no charge). After reviewing and approving, set this number (e.g. the number of leads found) and run again -> the first N leads are processed. User approval against unexpected bills.",
            "default": 0
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}