{
  "openapi": "3.0.1",
  "info": {
    "title": "US Local Business Opportunity Finder",
    "description": "Find local businesses by niche and city, then score sales opportunities for agencies, SEO consultants, web designers, reputation managers, and B2B sales teams.",
    "version": "0.2",
    "x-build-id": "JY3WOH18yd7f0anvq"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/mobba~us-local-business-opportunity-finder/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-mobba-us-local-business-opportunity-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/mobba~us-local-business-opportunity-finder/runs": {
      "post": {
        "operationId": "runs-sync-mobba-us-local-business-opportunity-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/mobba~us-local-business-opportunity-finder/run-sync": {
      "post": {
        "operationId": "run-sync-mobba-us-local-business-opportunity-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",
        "required": [
          "niche",
          "location",
          "maxResults"
        ],
        "properties": {
          "niche": {
            "title": "Business niche",
            "type": "string",
            "description": "Business type, service, or keyword to search for. Examples: med spa, dentist, HVAC, roofing company, law firm, restaurant."
          },
          "location": {
            "title": "City or market",
            "type": "string",
            "description": "City, state, address, or local market to search in. Examples: Miami, FL; Dallas, TX; Phoenix, AZ."
          },
          "maxResults": {
            "title": "Maximum results",
            "minimum": 1,
            "maximum": 240,
            "type": "integer",
            "description": "Maximum number of businesses to return. Start with 25-50 for testing. This MVP caps runs at 240 results.",
            "default": 25
          },
          "lowReviewThreshold": {
            "title": "Low review threshold",
            "minimum": 0,
            "maximum": 1000,
            "type": "integer",
            "description": "Businesses below this review count receive a review-growth opportunity signal.",
            "default": 25
          },
          "lowRatingThreshold": {
            "title": "Low rating threshold",
            "minimum": 1,
            "maximum": 5,
            "type": "number",
            "description": "Businesses below this Yelp rating receive a reputation-management opportunity signal.",
            "default": 4
          },
          "sortResultsByScore": {
            "title": "Sort by opportunity score",
            "type": "boolean",
            "description": "Sort results from highest to lowest opportunity score before saving to the dataset.",
            "default": true
          },
          "checkWebsite": {
            "title": "Check supplied business websites",
            "type": "boolean",
            "description": "When enabled, the Actor checks business-owned website URLs supplied through Website URL overrides. Yelp usually returns Yelp profile URLs, not business-owned website URLs.",
            "default": true
          },
          "websiteOverrides": {
            "title": "Website URL overrides",
            "type": "object",
            "description": "Optional JSON object mapping Yelp business IDs, aliases, or business names to website URLs. Example: {\"Example Med Spa\": \"https://examplemedspa.com\"}.",
            "default": {}
          },
          "opportunityCriteria": {
            "title": "Opportunity criteria",
            "type": "array",
            "description": "Signals used for scoring. Keep all selected for the broadest sales-opportunity scan.",
            "items": {
              "type": "string",
              "enum": [
                "missing_website",
                "site_unreachable",
                "no_https",
                "no_booking_signal",
                "no_contact_form_signal",
                "weak_cta_signal",
                "low_review_count",
                "low_rating",
                "missing_phone"
              ],
              "enumTitles": [
                "No website URL available",
                "Website unreachable",
                "No HTTPS",
                "No booking signal",
                "No contact form signal",
                "Weak CTA signal",
                "Low review count",
                "Low rating",
                "Missing phone"
              ]
            },
            "default": [
              "missing_website",
              "site_unreachable",
              "no_https",
              "no_booking_signal",
              "no_contact_form_signal",
              "weak_cta_signal",
              "low_review_count",
              "low_rating",
              "missing_phone"
            ]
          },
          "radiusMeters": {
            "title": "Search radius in meters",
            "minimum": 1,
            "maximum": 40000,
            "type": "integer",
            "description": "Optional Yelp radius from the location, from 1 to 40000 meters. Leave empty to let Yelp decide."
          },
          "sortBy": {
            "title": "Yelp sort mode",
            "enum": [
              "best_match",
              "rating",
              "review_count",
              "distance"
            ],
            "type": "string",
            "description": "Yelp search sort suggestion. Best match is recommended for broad lead discovery.",
            "default": "best_match"
          },
          "yelpCategories": {
            "title": "Yelp category aliases",
            "type": "string",
            "description": "Optional comma-separated Yelp category aliases, such as dentists, hvac, medspas, roofing. Leave empty to search by keyword only."
          },
          "yelpAttributes": {
            "title": "Yelp attributes",
            "type": "array",
            "description": "Optional Yelp attribute filters, such as request_a_quote or reservation. Leave empty for broader discovery.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "includeTechnicalFields": {
            "title": "Include technical/debug fields",
            "type": "boolean",
            "description": "Adds IDs, coordinates, image URLs, redirect URLs, and website error details. Keep off for clean sales spreadsheets.",
            "default": false
          },
          "websiteTimeoutSeconds": {
            "title": "Website timeout seconds",
            "minimum": 3,
            "maximum": 60,
            "type": "integer",
            "description": "Timeout for each supplied website homepage check.",
            "default": 12
          },
          "maxConcurrency": {
            "title": "Maximum website concurrency",
            "minimum": 1,
            "maximum": 30,
            "type": "integer",
            "description": "Maximum number of website checks running at the same time.",
            "default": 8
          },
          "locale": {
            "title": "Yelp locale",
            "type": "string",
            "description": "Yelp locale code used for API responses.",
            "default": "en_US"
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}