# Public procurement statistics (SBX-IHALE)

Public procurement statistics from EKAP records: competition, direct procurement, local-supplier share, concentration, province and sector volumes, and the top-10 authorities and contractors.

Version: v1.0

## Authentication

Send your API key on every request, either as a Bearer token or as the `apikey` query parameter:

```
Authorization: Bearer <YOUR_API_KEY>
https://api.servicebox.io/v1/public-procurement/...?apikey=<YOUR_API_KEY>
```

Get a key: sign up at https://servicebox.io/en/signup and create one on the dashboard. An agent can sign up itself with `POST https://api.servicebox.io/v1/accounts` and `{"email": "...", "apis": ["public-procurement"]}`: the owner of the mailbox approves by email and the agent collects a short-lived key by polling the returned `poll_url`.

## Base URL

`https://api.servicebox.io`

## Endpoints

### GET /v1/public-procurement/authority-types

**List authority types**

The kinds of buying authority (ministries, municipalities, universities, state-owned enterprises…). Free.

**Credits:** free (0 credits per call)

No parameters.

**Example**

```bash
curl "https://api.servicebox.io/v1/public-procurement/authority-types" \
  -H "Authorization: Bearer $SBX_API_KEY"
```

### GET /v1/public-procurement/competition-indices

**Competition**

Tender competition per year: the number of tenders, the share won with a single bid (overall and for single-lot tenders), average lots and the average discount against the estimated cost — for the whole country or per province, sector, tender procedure or authority type. Robust for 2019–2024; the source's 2025–2026 result details are partial.

**Credits:** 1 per call

**Parameters**

| Name | In | Type | Required | Description |
|---|---|---|---|---|
| `dimension` | query | string (`overall`, `province`, `sector`, `procedure`, `authority-type`) | no | What to break down by. Default: `overall` (the whole country). |
| `subject` | query | string | no | One subject of the dimension: a province's plate code or name (34, İstanbul), a sector id or name, an authority-type id, or a procedure id. Default: every subject. |
| `period` | query | string | no | A year (2019–) or `all` (every year pooled). Default: every year and `all`. |
| `limit` | query | integer | no | Items per page, 1–200. |
| `cursor` | query | string | no | The `next_cursor` of the previous page, with the same filters. |

**Example**

```bash
curl "https://api.servicebox.io/v1/public-procurement/competition-indices" \
  -H "Authorization: Bearer $SBX_API_KEY"
```

### GET /v1/public-procurement/concentration-indices

**Market concentration**

How concentrated contract winners are, per year: contract and firm counts, the largest 1, 4 and 10 contractors' share of value and the Herfindahl–Hirschman index — for the whole country or per province or sector.

**Credits:** 1 per call

**Parameters**

| Name | In | Type | Required | Description |
|---|---|---|---|---|
| `dimension` | query | string (`overall`, `province`, `sector`) | no | What to break down by. Default: `overall` (the whole country). |
| `subject` | query | string | no | One subject of the dimension: a province's plate code or name (34, İstanbul), a sector id or name, an authority-type id, or a procedure id. Default: every subject. |
| `period` | query | string | no | A year (2019–) or `all` (every year pooled). Default: every year and `all`. |
| `limit` | query | integer | no | Items per page, 1–200. |
| `cursor` | query | string | no | The `next_cursor` of the previous page, with the same filters. |

**Example**

```bash
curl "https://api.servicebox.io/v1/public-procurement/concentration-indices" \
  -H "Authorization: Bearer $SBX_API_KEY"
```

### GET /v1/public-procurement/datasets

**Source datasets and release**

The weekly release served, when it was loaded, and each source dataset with its row count and the citation its publisher asks for. Free.

**Credits:** free (0 credits per call)

No parameters.

**Example**

```bash
curl "https://api.servicebox.io/v1/public-procurement/datasets" \
  -H "Authorization: Bearer $SBX_API_KEY"
```

### GET /v1/public-procurement/direct-procurement-indices

**Direct procurement**

Direct procurement (doğrudan temin) per year: purchase count and the amount distribution (median, mean, total, 95th and 99th percentile, largest and its share), nominal TRY — for the whole country or per province, sector or authority type. 2025 is the reference year; earlier years are incomplete in the source.

**Credits:** 1 per call

**Parameters**

| Name | In | Type | Required | Description |
|---|---|---|---|---|
| `dimension` | query | string (`overall`, `province`, `sector`, `authority-type`) | no | What to break down by. Default: `overall` (the whole country). |
| `subject` | query | string | no | One subject of the dimension: a province's plate code or name (34, İstanbul), a sector id or name, an authority-type id, or a procedure id. Default: every subject. |
| `period` | query | string | no | A year (2019–) or `all` (every year pooled). Default: every year and `all`. |
| `limit` | query | integer | no | Items per page, 1–200. |
| `cursor` | query | string | no | The `next_cursor` of the previous page, with the same filters. |

**Example**

```bash
curl "https://api.servicebox.io/v1/public-procurement/direct-procurement-indices" \
  -H "Authorization: Bearer $SBX_API_KEY"
```

### GET /v1/public-procurement/localization-indices

**Local suppliers**

The share of contracts, by count and by value, won by suppliers from the buying authority's own province, per year — for the whole country or per province or sector.

**Credits:** 1 per call

**Parameters**

| Name | In | Type | Required | Description |
|---|---|---|---|---|
| `dimension` | query | string (`overall`, `province`, `sector`) | no | What to break down by. Default: `overall` (the whole country). |
| `subject` | query | string | no | One subject of the dimension: a province's plate code or name (34, İstanbul), a sector id or name, an authority-type id, or a procedure id. Default: every subject. |
| `period` | query | string | no | A year (2019–) or `all` (every year pooled). Default: every year and `all`. |
| `limit` | query | integer | no | Items per page, 1–200. |
| `cursor` | query | string | no | The `next_cursor` of the previous page, with the same filters. |

**Example**

```bash
curl "https://api.servicebox.io/v1/public-procurement/localization-indices" \
  -H "Authorization: Bearer $SBX_API_KEY"
```

### GET /v1/public-procurement/province-sectors

**Volume by province and sector**

Tender volume (count and value, nominal TRY) for each province and sector, with the value won by suppliers from the same province and from elsewhere. Largest first.

**Credits:** 1 per call

**Parameters**

| Name | In | Type | Required | Description |
|---|---|---|---|---|
| `province` | query | string | no | A province's plate code or name. |
| `sector` | query | string | no | A sector id from /public-procurement/sectors, or its Turkish or English name. |
| `sort` | query | string (`amount`, `tenders`) | no | `amount` (default) or `tenders`, both descending. |
| `limit` | query | integer | no | Items per page, 1–200. |
| `cursor` | query | string | no | The `next_cursor` of the previous page, with the same filters. |

**Example**

```bash
curl "https://api.servicebox.io/v1/public-procurement/province-sectors" \
  -H "Authorization: Bearer $SBX_API_KEY"
```

### GET /v1/public-procurement/sectors

**List sectors**

The 43 sectors tenders are classified into, with ids and English names. Free.

**Credits:** free (0 credits per call)

No parameters.

**Example**

```bash
curl "https://api.servicebox.io/v1/public-procurement/sectors" \
  -H "Authorization: Bearer $SBX_API_KEY"
```

### GET /v1/public-procurement/supply-flows

**Supply flows between provinces**

Contracts (count and value, nominal TRY) from authorities in one province to suppliers based in another or the same province. Largest first.

**Credits:** 1 per call

**Parameters**

| Name | In | Type | Required | Description |
|---|---|---|---|---|
| `buyerProvince` | query | string | no | The buying authorities' province: plate code or name. |
| `supplierProvince` | query | string | no | The suppliers' province: plate code or name. |
| `limit` | query | integer | no | Items per page, 1–200. |
| `cursor` | query | string | no | The `next_cursor` of the previous page, with the same filters. |

**Example**

```bash
curl "https://api.servicebox.io/v1/public-procurement/supply-flows" \
  -H "Authorization: Bearer $SBX_API_KEY"
```

### GET /v1/public-procurement/top-authorities

**Top-10 buying authorities**

The ten public authorities that awarded the most in one province (tenders or direct procurement) or one sector (tenders), by value.

**Credits:** 1 per call

**Parameters**

| Name | In | Type | Required | Description |
|---|---|---|---|---|
| `province` | query | string | no | A province's plate code or name. Give this or `sector`. |
| `sector` | query | string | no | A sector id or name. Give this or `province`. |
| `method` | query | string (`tender`, `direct`) | no | `tender` (default) or, for a province, `direct` (direct procurement). |
| `limit` | query | integer | no | Items per page, 1–200. |
| `cursor` | query | string | no | The `next_cursor` of the previous page, with the same filters. |

**Example**

```bash
curl "https://api.servicebox.io/v1/public-procurement/top-authorities" \
  -H "Authorization: Bearer $SBX_API_KEY"
```

### GET /v1/public-procurement/top-contractors

**Top-10 contractors**

The ten contractors that won the most in one province or sector (tenders), in one province by direct procurement (`direct`), or the ten firms based in a province with the most public-contract revenue anywhere (`headquartered`). Legal names as recorded in EKAP; no tax numbers.

**Credits:** 1 per call

**Parameters**

| Name | In | Type | Required | Description |
|---|---|---|---|---|
| `province` | query | string | no | A province's plate code or name. Give this or `sector`. |
| `sector` | query | string | no | A sector id or name. Give this or `province`. |
| `method` | query | string (`tender`, `direct`, `headquartered`) | no | `tender` (default); for a province also `direct` or `headquartered`. |
| `limit` | query | integer | no | Items per page, 1–200. |
| `cursor` | query | string | no | The `next_cursor` of the previous page, with the same filters. |

**Example**

```bash
curl "https://api.servicebox.io/v1/public-procurement/top-contractors" \
  -H "Authorization: Bearer $SBX_API_KEY"
```

## Errors

Errors are RFC 9457 `application/problem+json` bodies with a machine-readable `type`.

- `401` — the key is missing, unknown, expired or revoked.
- `402` — not enough credits: the body carries `credits_required` and `upgrade_url` (https://servicebox.io/en/pricing).
- `403` — the key is not allowed to call this API.
- `429` — rate limited: wait `retry_after` seconds (also sent as the `Retry-After` header); `upgrade_url` points to a larger plan.

## Links

- OpenAPI document: https://api.servicebox.io/v1/public-procurement/openapi.json
- Pricing: https://servicebox.io/en/pricing?api=SBX-IHALE
- API page: https://servicebox.io/en/apis/public-procurement
