GeoCzech logo GeoCzech Docs

GeoCzech API

Quickstart

Convert your first file with the API in about five minutes — no own data needed.

In this guide you will create an API key, convert a sample Shapefile into GeoJSON and download the result. Every step has a ready-made example; pick your language in the switcher (cURL works in any terminal).

1. Get an API key

  1. Sign in to the GeoCzech Console.
  2. Open Developers → API keys and click Create API key.
  3. Give the key a name (for example My first script) and copy it. It looks like gcz_live_….

In every example, replace YOUR_API_KEY with your key.

API access

API keys are available in the Standard and Premium plans. Geodata and Coordinates calls are free; Converter jobs use a few credits — see Credits & pricing.

2. Choose how to run the examples

  • cURL — already installed on macOS, Linux and Windows 10/11. On Windows use Git Bash or WSL, because the examples use Unix-style line breaks (\) and quotes.
  • Python 3 — install the requests package: pip install requests.
  • JavaScript — Node.js 20 or newer; save the code as example.mjs and run node example.mjs.
  • PHP — PHP 8 with the curl extension; run php example.php.
  • C# — .NET 7 or newer; paste the code into Program.cs of a console app (dotnet new console) and run dotnet run.

3. Convert a sample file

The request on the right sends a link to our sample Shapefile with places on the island of Saint Helena and asks for GeoJSON.

  • file_urls — where the API downloads the input from. You can also upload a file from your computer instead — see Requests & tasks.
  • params — the settings of the tool, as JSON. Here: the output format.
  • wait=true — keep the connection open until the result is ready (up to 60 s).

The conversion takes about two seconds. Because the source data is in a projected system (UTM zone 30S, coordinates in metres) and GeoJSON always uses WGS 84, the Converter recalculated the coordinates automatically — it tells you so in decisions.

Shapefile → GeoJSON
curl -X POST "https://api.geoczech.dev/v2/tool/converter" \
  -H "X-API-Key: YOUR_API_KEY" \
  -F "file_urls=https://cdn.geoczech.dev/docs-samples/v1/st-helena-places-utm.zip" \
  --form-string 'params={"output": {"format": "geojson"}}' \
  -F "wait=true"
Response
{
  "task_id": "0dd2eebc-163d-41e5-870e-20fb9c15980e",
  "status": "SUCCESS",
  "message": "Success",
  "duration_sec": 1.535,
  "output_files": [
    "https://…/output/result.json?…",
    "https://…/output/st-helena-places-utm.geojson?…"
  ],
  "json_data": {
    "status": "ok",
    "outputs": [{
      "format": "geojson",
      "crs": "EPSG:4326",
      "layers": [{"name": "st-helena-places-utm", "featureCount": 58}],
      "files": [{"name": "st-helena-places-utm.geojson", "sizeBytes": 12279, "role": "data"}]
    }],
    "decisions": [{
      "code": "crs_forced_by_format",
      "message": "Format 'geojson' mandates EPSG:4326; output is reprojected automatically."
    }]
  }
}

4. Download the result

output_files contains download links:

  • result.json — the full report (the same as json_data).
  • st-helena-places-utm.geojson — your converted file.

Open the link in a browser, or download it in code. The links are valid for 1 hour; ask for the task status to get fresh links. Files are kept for 7 days by default.

Download a file from output_files
# Paste the link from output_files (keep the quotes — the link contains & characters)
curl -L -o st-helena-places-utm.geojson "PASTE_THE_DOWNLOAD_LINK_HERE"

Next steps

  • Learn how tasks, inputs and webhooks work in Requests & tasks.
  • See everything the Converter can do — reprojection, filters, clipping, 100+ formats.
  • Inspect unknown files with Geodata, or work with coordinates in Coordinates.
  • Show your data as a map layer with MapServer.

Last updated 2026-11-17