{
  "openapi": "3.0.1",
  "info": {
    "title": "Reverse Geocoder – Lat/Long to Country, State, City & Time Zone",
    "description": "Bulk offline reverse geocoding: turn latitude/longitude into country (ISO codes), state/province, nearest city or town, IANA time zone and UTC offset. Lists, CSV/JSON files or Apify datasets (e.g. Google Maps results). No API key. City level, no street addresses. $0.20 per 1,000.",
    "version": "0.1",
    "x-build-id": "ZgqCyCBTmwN628XdE"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/gazidev~reverse-geocoder/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-gazidev-reverse-geocoder",
        "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/gazidev~reverse-geocoder/runs": {
      "post": {
        "operationId": "runs-sync-gazidev-reverse-geocoder",
        "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/gazidev~reverse-geocoder/run-sync": {
      "post": {
        "operationId": "run-sync-gazidev-reverse-geocoder",
        "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": {
          "coordinates": {
            "title": "Coordinates",
            "type": "array",
            "description": "One point per line as `latitude, longitude` (e.g. `48.8584, 2.2945`). Also accepted: `48.8584 N, 2.2945 E`, degrees-minutes-seconds (`48°51'30\"N 2°17'40\"E`), `lat;lon`, and Google Maps links (`.../@48.85,2.29,15z`). Invalid lines get a free error row. The example list is ignored when you also pick a dataset or file.",
            "items": {
              "type": "string"
            }
          },
          "datasetId": {
            "title": "Apify dataset with coordinates",
            "type": "string",
            "description": "Pick a dataset from an earlier run (for example a Google Maps scraper run). Latitude/longitude are found automatically in `location.lat`/`location.lng`, `lat`/`lng`/`lon`, `latitude`/`longitude`, GeoJSON points or a `coordinates` text field. Set the field names below if yours differ."
          },
          "fileUrl": {
            "title": "CSV / JSON file URL",
            "type": "string",
            "description": "Public URL of a CSV (comma, semicolon, tab or pipe separated, with a header row), JSON array or JSON Lines file. Columns are detected like dataset fields. Max 500 MB. Private-network addresses are refused."
          },
          "latitudeField": {
            "title": "Latitude field",
            "type": "string",
            "description": "Optional. Column or field path for latitude in the dataset/file, e.g. `lat` or `location.lat` (dots for nested fields). Set together with 'Longitude field'."
          },
          "longitudeField": {
            "title": "Longitude field",
            "type": "string",
            "description": "Optional. Column or field path for longitude, e.g. `lng` or `location.lng`."
          },
          "coordinatesField": {
            "title": "Combined coordinates field",
            "type": "string",
            "description": "Optional. A single field holding both values, e.g. `gps` with text `48.85, 2.29`, a `{lat, lng}` object or a Google Maps link. Overrides the two fields above."
          },
          "keepFields": {
            "title": "Fields to copy into the output",
            "type": "array",
            "description": "Fields of each dataset/file item copied into `source` in the output, so you can join the result back (dots for nested fields). Missing fields are ignored.",
            "default": [
              "title",
              "name",
              "id",
              "placeId",
              "url"
            ],
            "items": {
              "type": "string"
            }
          },
          "skipDuplicates": {
            "title": "Skip duplicate coordinates",
            "type": "boolean",
            "description": "Identical points (to 6 decimals) are resolved and charged once; later copies get no row. Turn off to get one row per input row (each one charged).",
            "default": true
          },
          "zeroIsMissing": {
            "title": "Treat 0,0 as missing",
            "type": "boolean",
            "description": "`0, 0` (\"Null Island\", in the Atlantic) is nearly always a placeholder for a missing location. When on, it gets a free 'invalid' row.",
            "default": true
          },
          "maxPlaceDistanceKm": {
            "title": "Max distance to nearest place (km)",
            "minimum": 1,
            "maximum": 20000,
            "type": "integer",
            "description": "The nearest populated place is only reported if it is within this distance. Places are towns with 15,000+ inhabitants, so remote points can be far from one.",
            "default": 150
          },
          "coastToleranceKm": {
            "title": "Coast tolerance (km)",
            "minimum": 0,
            "maximum": 50,
            "type": "integer",
            "description": "Points just off the (simplified) coastline, e.g. on a beach, pier or harbour, are matched to the nearest country/state within this distance (`countryMatch: coastal`). 0 = strict polygons only.",
            "default": 3
          },
          "onlyResolved": {
            "title": "Only output resolved points",
            "type": "boolean",
            "description": "Leave out the free rows for invalid inputs and open-ocean points with no match.",
            "default": false
          },
          "maxItems": {
            "title": "Max inputs",
            "minimum": 1,
            "type": "integer",
            "description": "Optional cap on how many input rows are read (all sources together)."
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}