{
  "openapi": "3.0.1",
  "info": {
    "title": "Local B2B Lead Audit, Email & Cold-Pitch Finder",
    "description": "Audit Google Maps leads, company URLs, or US Chamber directories for 8 website weaknesses, owner emails, and custom cold-email openers ($4.50/1K; $0 filtered).",
    "version": "0.1",
    "x-build-id": "leMquyLdJVSDeb3tw"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/maitreya_buddha~local-b2b-website-audit-email-pitch-finder/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-maitreya_buddha-local-b2b-website-audit-email-pitch-finder",
        "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/maitreya_buddha~local-b2b-website-audit-email-pitch-finder/runs": {
      "post": {
        "operationId": "runs-sync-maitreya_buddha-local-b2b-website-audit-email-pitch-finder",
        "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/maitreya_buddha~local-b2b-website-audit-email-pitch-finder/run-sync": {
      "post": {
        "operationId": "run-sync-maitreya_buddha-local-b2b-website-audit-email-pitch-finder",
        "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": {
          "websiteUrls": {
            "title": "Company Website URLs (Direct Mode)",
            "type": "array",
            "description": "Paste up to 2,000 local business or B2B company website URLs (e.g. from Google Maps, Apollo, or a CSV) to run the 8-point website weakness X-ray, owner email recovery, and custom cold-pitch generator.",
            "items": {
              "type": "string"
            }
          },
          "datasetId": {
            "title": "Upstream Apify Dataset ID (Google Maps / Scraper Chaining)",
            "type": "string",
            "description": "Optional Apify Dataset ID from Google Maps Scraper or any upstream directory scraper. Automatically detects website/url, title/companyName, phone, city, categoryName, and preserves businesses with no website as 100-score web design VIP leads."
          },
          "datasetField": {
            "title": "Custom Website Field Name (Optional)",
            "type": "string",
            "description": "Optional explicit field name for the website URL when chaining from datasetId (auto-detected if left blank)."
          },
          "presetChambers": {
            "title": "Built-In Verified US Chamber of Commerce Presets",
            "type": "array",
            "description": "Optional live-verified US ChamberMaster directories of paying local businesses. Select one or more cities to auto-collect businesses without needing your own URL list.",
            "items": {
              "type": "string",
              "enum": [
                "phoenix_az",
                "scottsdale_az",
                "chandler_az",
                "gilbert_az",
                "fort_worth_tx",
                "denton_tx",
                "lubbock_tx",
                "beverly_hills_ca",
                "anaheim_ca",
                "fresno_ca",
                "tacoma_wa",
                "salem_or",
                "anchorage_ak"
              ]
            }
          },
          "chamberDirectoryUrls": {
            "title": "Custom ChamberMaster / GrowthZone Directory URLs",
            "type": "array",
            "description": "Optional custom US Chamber of Commerce ChamberMaster / GrowthZone directory URLs (e.g. https://business.phoenixchamber.com/list or a specific /list/ql/... category page).",
            "items": {
              "type": "string"
            }
          },
          "chamberCategoryKeyword": {
            "title": "Chamber Category Filter Keyword (Optional)",
            "type": "string",
            "description": "Optional keyword to filter Chamber directory categories (e.g. \"dental\", \"plumbing\", \"restaurant\", \"roofing\", \"legal\", \"medical\", \"auto\"). Leave empty to sample across top categories."
          },
          "agencyPreset": {
            "title": "Your Agency Pitch Preset",
            "enum": [
              "all",
              "web_design",
              "local_seo",
              "paid_ads",
              "ai_chatbot_booking"
            ],
            "type": "string",
            "description": "Tailors pitchPriorityScore (0-100), recommendedService, coldEmailSubject, and coldEmailIcebreaker to what your agency sells.",
            "default": "all"
          },
          "enableContactPageFollow": {
            "title": "Deep 1-Hop /contact & /about Email Follow",
            "type": "boolean",
            "description": "When no email is found on the homepage, follow up to 1 internal /contact or /about page (SSRF-safe, Cloudflare email decoding included).",
            "default": true
          },
          "onlyWithEmail": {
            "title": "Only Bill Leads With Email ($0 Otherwise)",
            "type": "boolean",
            "description": "Optional $0 filter: when enabled, save and bill ONLY leads where at least 1 verified email is found. Leave OFF (default) to keep all leads including high-value 'no_website' prospects.",
            "default": false
          },
          "onlyWithWeakness": {
            "title": "Only Bill Leads With >=1 Detected Weakness ($0 Otherwise)",
            "type": "boolean",
            "description": "Optional $0 filter: when enabled, skip polished websites with 0 detected weaknesses at $0.",
            "default": false
          },
          "minPitchScore": {
            "title": "Minimum Pitch Priority Score (0-100, $0 Below)",
            "minimum": 0,
            "maximum": 100,
            "type": "integer",
            "description": "Optional $0 filter: skip leads whose pitchPriorityScore falls below this threshold (default 0 saves all leads).",
            "default": 0
          },
          "maxItems": {
            "title": "Max Leads to Audit & Save",
            "minimum": 1,
            "maximum": 2000,
            "type": "integer",
            "description": "Maximum total business leads to audit (1-2,000).",
            "default": 100
          },
          "maxConcurrency": {
            "title": "Max Concurrency (Auto-capped <=3 on 128-256MB)",
            "minimum": 1,
            "maximum": 10,
            "type": "integer",
            "description": "Concurrent website audits (1-10; automatically capped at 3 on 128-256 MB containers to prevent OOM).",
            "default": 5
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}