List the delivery certificates of the organisation
GET /api/v1/delivery/certificates
https://app.tanba-ooh.kz/api/v1/delivery/certificates
Анықтамалықтың техникалық мәтіні ағылшын тілінде жазылған.
Scope read:delivery. The newest 200 certificates issued by the organisation, with where each stands in the public ledger.
Аутентификация
Authorization тақырыбындағы API кілті немесе консоль сеансы.
Рұқсат: read:delivery
Жауаптар
200 The certificates, newest first.
application/json
| Атауы | Түрі | Міндетті | Сипаттама | Мысал |
|---|---|---|---|---|
items | array of DeliveryCertificate | иә | The certificates of the organisation. | |
items[].id | string (uuid) | иә | Id of the certificate. | "9b2c3d4e-6f70-4812-a3b4-c5d6e7f80912" |
items[].digest | string | иә | Hex SHA-256 of the canonical document; it is what the public ledger records. | "3f6c1b2a9d4e8f0a1b2c3d4e5f60718293a4b5c6d7e8f9012345678901234567" |
items[].scope | object | иә | What the certificate covers. | |
items[].scope.kind | string | иә | Whether the report covers one approval or a campaign. approval, campaign | |
items[].scope.ref | string | иә | The approval number, or the id of the campaign. | "7a1f0c2e-5b6d-4e8f-9a0b-1c2d3e4f5a6b" |
items[].scope.name | string | Name of the campaign. | "Autumn campaign" | |
items[].scope.external_ref | string | The organisation's own reference of the campaign. | "PO-2026-17" | |
items[].period_from | string (date) | иә | First day covered. | "2026-10-01" |
items[].period_to | string (date) | иә | Last day covered. | "2026-10-31" |
items[].lang | string | иә | Language of the PDF issued. kk, ru, en | |
items[].signed | boolean | иә | Whether the certificate carries a signature of its own. Today none does; the ledger entry is its proof. | false |
items[].issued_at | string | иә | When it was issued, Almaty time. | "2026-11-01T09:30:00+05:00" |
items[].pdf_sha256 | string | иә | Hex SHA-256 of the PDF issued. | "5b1d2e3f4a5b6c7d8e9f0a1b2c3d4e5f60718293a4b5c6d7e8f901234567890a" |
items[].verify_url | string | иә | Address of the public check of this certificate. | "https://verify.tanba-ooh.kz/r/3f6c1b2a9d4e8f0a1b2c3d4e5f60718293a4b5c6d7e8f9012345678901234567" |
items[].ledger | object | иә | Where the digest stands in the public ledger. | |
items[].ledger.status | string | иә | pending until the ledger day that holds the digest exists. pending, pending_check, anchored | |
items[].ledger.day | string (date) | The ledger day that holds the digest; present once it exists. | "2026-11-02" | |
items[].ledger.block_height | integer | Bitcoin block of the attestation; present only when anchored. | 905432 |
Мысал
{
"items": [
{
"id": "9b2c3d4e-6f70-4812-a3b4-c5d6e7f80912",
"digest": "3f6c1b2a9d4e8f0a1b2c3d4e5f60718293a4b5c6d7e8f9012345678901234567",
"scope": {
"kind": "campaign",
"ref": "7a1f0c2e-5b6d-4e8f-9a0b-1c2d3e4f5a6b",
"name": "Autumn campaign",
"external_ref": "PO-2026-17"
},
"period_from": "2026-10-01",
"period_to": "2026-10-31",
"lang": "ru",
"signed": false,
"issued_at": "2026-11-01T09:30:00+05:00",
"pdf_sha256": "5b1d2e3f4a5b6c7d8e9f0a1b2c3d4e5f60718293a4b5c6d7e8f901234567890a",
"verify_url": "https://verify.tanba-ooh.kz/r/3f6c1b2a9d4e8f0a1b2c3d4e5f60718293a4b5c6d7e8f9012345678901234567",
"ledger": {
"status": "pending",
"day": "2026-11-02",
"block_height": 905432
}
}
]
}
Қателер
Қателер problem құжаты (application/problem+json) түрінде, тұрақты code өрісімен келеді.
| Мәртебесі | Мағынасы |
|---|---|
| 401 | No valid session or API key (unauthenticated, session_expired, invalid_api_key). |
| 403 | The role or the key's scope does not allow this (forbidden, key_scope_denied, key_route_denied). |
| default | An error as a problem document. |
Код мысалдары
curl
curl 'https://app.tanba-ooh.kz/api/v1/delivery/certificates' \
-H 'Authorization: Bearer YOUR_API_KEY'
Python
import requests
response = requests.get(
"https://app.tanba-ooh.kz/api/v1/delivery/certificates",
headers={
"Authorization": "Bearer YOUR_API_KEY",
},
)
print(response.status_code, response.text)
Go
package main
import (
"fmt"
"io"
"net/http"
)
func main() {
req, err := http.NewRequest("GET", "https://app.tanba-ooh.kz/api/v1/delivery/certificates", nil)
if err != nil {
panic(err)
}
req.Header.Set("Authorization", "Bearer YOUR_API_KEY")
resp, err := http.DefaultClient.Do(req)
if err != nil {
panic(err)
}
defer resp.Body.Close()
data, _ := io.ReadAll(resp.Body)
fmt.Println(resp.Status, string(data))
}