Statistics Poland (GUS) Territorial data API

The Territorial data API from Statistics Poland (GUS) — 2 operation(s) for territorial data.

GitHub OpenAPI

Operations 2

GET /api/territorial-data Gets the list of territorial units from the portrait jt #
GET /api/territorial-data/{territory_code} Gets territory data #

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/stat-gov-pl:stat-gov-pl-territorial-data-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

stat-gov-pl-territorial-data-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: Stat Gov Pl Territorial data API
  version: OAS3
  license:
    name: Creative Commons Attribution 4.0 International Public License
    url: https://creativecommons.org/licenses/by/4.0/legalcode
  x-refined-note:
  - x-source differs across the merged source definitions and was not carried
  description: 'Operations tagged Territorial data across 2 of this provider''s published API definitions: stat-gov-pl-strateg-openapi.json, stat-gov-pl-strateg-openapi.yml. Each path carries the servers of the definition it was published in.'
servers:
- url: https://strateg.stat.gov.pl
security:
- ApiKeyAuth: []
tags:
- name: Territorial data
paths:
  /api/territorial-data:
    get:
      operationId: getTerritorialDataSummary
      parameters:
      - in: query
        name: lang
        required: false
        schema:
          default: en
          enum:
          - pl
          - en
          type: string
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/TerritorialDataSummary'
          description: territorial summary data
        '401':
          $ref: '#/components/responses/Unauthorized'
        '404':
          $ref: '#/components/responses/NotFound'
      security:
      - ApiKeyAuth: []
      summary: Gets the list of territorial units from the portrait jt
      tags:
      - Territorial data
  /api/territorial-data/{territory_code}:
    get:
      operationId: getTerritorialData
      parameters:
      - in: path
        name: territory_code
        required: true
        schema:
          pattern: ^[0-9]{12}$
          type: string
      - in: query
        name: lang
        required: false
        schema:
          default: en
          enum:
          - pl
          - en
          type: string
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/TerritorialData'
          description: territorial data
          links:
            /api/indicators/{indicator_id}/dimensions/{dimension_id}?territory_code={territory_code}&lang=en:
              operationId: realValues
              parameters:
                dimension_id: $response.body#/dimension_id
                indicator_id: $response.body#/indicator_id
                territory_code: $request.path.territory_code
        '401':
          $ref: '#/components/responses/Unauthorized'
        '404':
          $ref: '#/components/responses/NotFound'
        '422':
          $ref: '#/components/responses/UnprocessableEntity'
      security:
      - ApiKeyAuth: []
      summary: Gets territory data
      tags:
      - Territorial data
components:
  schemas:
    TerritorialDataSummary:
      properties:
        territory_code:
          properties:
            countries:
              properties:
                territory_code:
                  properties:
                    name:
                      type: string
                    type:
                      properties:
                        territory_code:
                          properties:
                            name:
                              type: string
                          type: object
                      type: object
                  type: object
              type: object
          type: object
      type: object
    TerritorialData:
      properties:
        dimension_id:
          type: integer
        indicator_id:
          type: integer
        name:
          type: string
        territory_name:
          type: string
        unit:
          type: string
      type: object
  responses:
    Unauthorized:
      description: API KEY is missing or invalid.
    UnprocessableEntity:
      description: Incorrect request. A parameter outside the range is given.
    NotFound:
      description: The desired resource was not found.
  securitySchemes:
    ApiKeyAuth:
      in: header
      name: X-API-KEY
      type: apiKey
x-refined-from:
- stat-gov-pl-strateg-openapi.json
- stat-gov-pl-strateg-openapi.yml