{
  "openapi": "3.0.1",
  "info": {
    "title": "SiteVerdict — OpenStreetMap Geocoder (address ↔ lat/lon, bulk)",
    "description": "Bulk forward and reverse geocoding on OpenStreetMap data: addresses or postcodes to lat/lon and back, with parsed address parts, bounding box, confidence, cache and CSV/GeoJSON export. Use your own OpenCage, LocationIQ, Geoapify key or Photon/Nominatim server.",
    "version": "1.1",
    "x-build-id": "Zv99VOWcNTJVLT4nE"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/siteverdict~siteverdict-geocoder-osm/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-siteverdict-siteverdict-geocoder-osm",
        "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/siteverdict~siteverdict-geocoder-osm/runs": {
      "post": {
        "operationId": "runs-sync-siteverdict-siteverdict-geocoder-osm",
        "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/siteverdict~siteverdict-geocoder-osm/run-sync": {
      "post": {
        "operationId": "run-sync-siteverdict-siteverdict-geocoder-osm",
        "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": {
          "addresses": {
            "title": "Addresses / places (forward geocoding)",
            "type": "array",
            "description": "Free-text addresses, postcodes or place names, one per line.",
            "items": {
              "type": "string"
            }
          },
          "structuredAddresses": {
            "title": "Structured addresses (JSON)",
            "type": "array",
            "description": "Optional objects with street, city, county, state, postcode, country and an optional label echoed back, e.g. {\"street\": \"1 Royal Parade\", \"city\": \"Plymouth\", \"postcode\": \"PL1 1DS\", \"country\": \"GB\", \"label\": \"store-12\"}."
          },
          "coordinates": {
            "title": "Coordinates (reverse geocoding)",
            "type": "array",
            "description": "\"lat,lon\" pairs such as 50.3714,-4.1422 to turn into addresses.",
            "items": {
              "type": "string"
            }
          },
          "provider": {
            "title": "Geocoding provider",
            "enum": [
              "photon-public",
              "opencage",
              "locationiq",
              "geoapify",
              "photon-custom",
              "nominatim-custom"
            ],
            "type": "string",
            "description": "photon-public = free trial on komoot's public Photon server, max 25 lookups per run at 1 req/s, never charged. For real volumes use your own key (OpenCage, LocationIQ, Geoapify) or your own Photon/Nominatim server. The public OSMF Nominatim server is NOT offered because its policy forbids resellers such as Apify Actors.",
            "default": "photon-public"
          },
          "apiKey": {
            "title": "Provider API key",
            "type": "string",
            "description": "Your own OpenCage / LocationIQ / Geoapify key. Sent only to that provider, never logged or output."
          },
          "instanceUrl": {
            "title": "Your own server URL",
            "type": "string",
            "description": "Base URL of your own Photon (e.g. https://photon.example.com) or Nominatim server. Private/internal addresses are blocked."
          },
          "locationIqRegion": {
            "title": "LocationIQ region",
            "enum": [
              "us",
              "eu"
            ],
            "type": "string",
            "description": "Which LocationIQ endpoint to use.",
            "default": "us"
          },
          "requestsPerSecond": {
            "title": "Requests per second",
            "minimum": 0.1,
            "maximum": 20,
            "type": "number",
            "description": "Your plan's rate limit. Defaults to the provider's free tier (OpenCage 1, LocationIQ 2, Geoapify 5). The public Photon trial is fixed at 1."
          },
          "countryCodes": {
            "title": "Limit to countries",
            "type": "string",
            "description": "Comma-separated ISO codes, e.g. gb,ie. Leave empty for worldwide."
          },
          "language": {
            "title": "Result language",
            "type": "string",
            "description": "Preferred language for place names (e.g. en, de, fr).",
            "default": "en"
          },
          "resultsPerQuery": {
            "title": "Results per query",
            "minimum": 1,
            "maximum": 5,
            "type": "integer",
            "description": "1 = best match only. Up to 5; extra matches go into 'alternatives' (charged once per query).",
            "default": 1
          },
          "useCache": {
            "title": "Cache results across runs",
            "type": "boolean",
            "description": "Store results in a named key-value store in your account and reuse them (cheaper cached-result event; required good practice for OSM services).",
            "default": true
          },
          "cacheStoreName": {
            "title": "Cache store name",
            "type": "string",
            "description": "Named key-value store used as the cache.",
            "default": "siteverdict-geocoder-cache"
          },
          "cacheTtlDays": {
            "title": "Cache lifetime (days)",
            "minimum": 0,
            "maximum": 365,
            "type": "integer",
            "description": "Cached answers older than this are fetched again.",
            "default": 30
          },
          "maxQueries": {
            "title": "Max queries",
            "minimum": 1,
            "maximum": 50000,
            "type": "integer",
            "description": "Safety cap per run (max 50,000; the public Photon trial is always capped at 25).",
            "default": 1000
          },
          "writeCsv": {
            "title": "Save CSV",
            "type": "boolean",
            "description": "Save RESULTS.csv (with attribution line) to the key-value store.",
            "default": true
          },
          "writeGeoJson": {
            "title": "Save GeoJSON",
            "type": "boolean",
            "description": "Save RESULTS.geojson for GIS tools and web maps.",
            "default": true
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}