{
  "openapi": "3.0.1",
  "info": {
    "title": "Yellow Pages US Scraper - Phones, Emails, Coordinates, Reviews",
    "description": "Scrape Yellow Pages (yellowpages.com) and SuperPages by trade + city/ZIP or URL: name, phone, address, coordinates, website, categories, rating, years in business. Optional profile details (email, hours, services, payment, socials, extra phones) and reviews. Sort, ad filter, monitor mode. No login.",
    "version": "0.1",
    "x-build-id": "5rLvPMIcq9xo4rPOK"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/scrapersdelight~yellowpages-us-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-scrapersdelight-yellowpages-us-scraper",
        "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/scrapersdelight~yellowpages-us-scraper/runs": {
      "post": {
        "operationId": "runs-sync-scrapersdelight-yellowpages-us-scraper",
        "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/scrapersdelight~yellowpages-us-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-scrapersdelight-yellowpages-us-scraper",
        "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": {
          "searchTerms": {
            "title": "🔍 Search terms",
            "type": "array",
            "description": "What you would type into the Yellow Pages search box: a trade, category or business name, e.g. \"plumber\", \"dentist\", \"pizza\". Every term is searched in every location below.",
            "items": {
              "type": "string"
            }
          },
          "locations": {
            "title": "📍 Locations",
            "type": "array",
            "description": "US places as \"City, ST\" (e.g. \"Austin, TX\") or a 5-digit ZIP code (e.g. \"90210\"). Required with search terms.",
            "items": {
              "type": "string"
            }
          },
          "startUrls": {
            "title": "🔗 Yellow Pages / SuperPages URLs",
            "type": "array",
            "description": "Paste search URLs (yellowpages.com/search?search_terms=plumber&geo_location_terms=Austin%2C+TX), city-category pages (/austin-tx/plumbers) or business pages (/austin-tx/mip/clarke-kent-plumbing-10674347). superpages.com URLs work too.",
            "items": {
              "type": "string"
            }
          },
          "source": {
            "title": "Directory",
            "enum": [
              "yellowpages",
              "superpages"
            ],
            "type": "string",
            "description": "Which site to search. Both are Thryv's and list the same businesses under the same id; SuperPages orders results differently and shows its own reviews. Pasted URLs always use their own site.",
            "default": "yellowpages"
          },
          "sortBy": {
            "title": "Sort by",
            "enum": [
              "default",
              "distance",
              "rating",
              "name"
            ],
            "type": "string",
            "description": "How the directory orders the results before they are collected (its own sort menu).",
            "default": "default"
          },
          "includeAds": {
            "title": "Include sponsored listings",
            "type": "boolean",
            "description": "Also return the paid placements shown above the results (marked isAd: true). Off: only the directory's own results.",
            "default": false
          },
          "requirePhone": {
            "title": "Only businesses with a phone",
            "type": "boolean",
            "description": "Skip businesses without a phone number. Skipped businesses are not charged.",
            "default": false
          },
          "requireWebsite": {
            "title": "Only businesses with a website",
            "type": "boolean",
            "description": "Skip businesses that list no website of their own.",
            "default": false
          },
          "requireEmail": {
            "title": "Only businesses with an email",
            "type": "boolean",
            "description": "Skip businesses whose profile shows no email. The email is only on the profile page, so this turns on profile details.",
            "default": false
          },
          "minRating": {
            "title": "Minimum rating",
            "minimum": 0,
            "maximum": 5,
            "type": "number",
            "description": "Skip businesses rated below this (1-5). Businesses without a rating are skipped too. Empty = no limit."
          },
          "minReviews": {
            "title": "Minimum number of reviews",
            "minimum": 0,
            "maximum": 100000,
            "type": "integer",
            "description": "Skip businesses with fewer reviews than this. Empty = no limit."
          },
          "includeCoordinates": {
            "title": "📌 Coordinates on every row",
            "type": "boolean",
            "description": "Latitude and longitude from the directory's map view of each results page (businesses that publish an address). Turn off for the fastest list-only run.",
            "default": true
          },
          "includeDetails": {
            "title": "📇 Profile details",
            "type": "boolean",
            "description": "Open each business's profile page: email, opening hours by day, description, slogan, services, payment methods, languages, brands, AKA names, extra phones, social links, photos, year established.",
            "default": false
          },
          "includeReviews": {
            "title": "⭐ Reviews",
            "type": "boolean",
            "description": "Add the business's reviews to its row: author, date, stars (+ YP's Expertise / Professionalism / Promptness), title, text, owner response, source. Turns on profile details.",
            "default": false
          },
          "maxReviewsPerBusiness": {
            "title": "Reviews per business",
            "minimum": 0,
            "maximum": 2000,
            "type": "integer",
            "description": "Reviews kept per business, in the order the directory lists them. 10 = YP's first review page. 0 = every review (up to 2,000).",
            "default": 10
          },
          "monitorMode": {
            "title": "Only new businesses",
            "type": "boolean",
            "description": "Deliver only businesses no earlier run with this search (and monitor key) delivered. Pairs with a daily or weekly schedule.",
            "default": false
          },
          "monitorKey": {
            "title": "Monitor key",
            "type": "string",
            "description": "Optional name that keeps separate memories for the same search (e.g. one per client)."
          },
          "maxResults": {
            "title": "Max businesses",
            "minimum": 0,
            "maximum": 100000,
            "type": "integer",
            "description": "Total rows across all searches and URLs. Yellow Pages lists up to 3,000 businesses per search (100 pages of 30). 0 = no limit.",
            "default": 100
          },
          "maxResultsPerSearch": {
            "title": "Max businesses per search",
            "minimum": 0,
            "maximum": 3000,
            "type": "integer",
            "description": "Cap for each search term × location, so one big city cannot use the whole run. 0 = no per-search cap.",
            "default": 0
          },
          "maxPagesPerSearch": {
            "title": "Max pages per search",
            "minimum": 1,
            "maximum": 100,
            "type": "integer",
            "description": "Results pages read per search (30 businesses each). The directory stops at 100.",
            "default": 100
          },
          "compact": {
            "title": "Compact rows",
            "type": "boolean",
            "description": "Core contact fields only (name, phone, email, website, address, coordinates, category, rating) - smaller rows for spreadsheets, CRMs and AI agents.",
            "default": false
          },
          "proxyConfiguration": {
            "title": "Proxy",
            "type": "object",
            "description": "Optional. By default the run uses its own route: direct requests first, residential proxies only when the directory refuses them. Add your own proxy URLs to route through them instead."
          },
          "maxConcurrency": {
            "title": "Parallel requests",
            "minimum": 1,
            "maximum": 10,
            "type": "integer",
            "description": "Profile pages read at the same time when details are on.",
            "default": 4
          },
          "webhookUrl": {
            "title": "Webhook URL",
            "type": "string",
            "description": "Optional. One JSON POST when the run ends: counts per search and the dataset id."
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}