List approvals
GET /api/v1/approvals
https://app.tanba-ooh.kz/api/v1/approvals
Технический текст справочника написан на английском.
Scope read:approvals. Own organisation's approvals; the authority sees all.
Аутентификация
Ключ API в заголовке Authorization или сессия консоли.
Право доступа: read:approvals
Ответы
200 Newest first, at most 500.
application/json
| Имя | Тип | Обязательный | Описание | Пример |
|---|---|---|---|---|
items | array of ApprovalSummary | да | Approvals, newest first, at most 500. | |
items[].number | string | да | Approval number. | "TNB-2026-123456" |
items[].valid_from | string (date) | да | Первый день действия согласования. | "2026-10-01" |
items[].valid_until | string (date) | да | Последний день действия согласования. | "2026-12-31" |
items[].status | string | да | State of the approval. pending, active, expiring, expired, revoked | |
items[].signed_at | string | null | да | When the approval was signed; null while it is pending. | "2026-10-06T14:05:39+05:00" |
items[].env | string | да | Environment of the approval: test approvals are never valid for real content. test, prod | |
items[].advertiser_name | string | да | Name of the advertiser. | "Example Advertising LLP" |
items[].media_name | string | да | Name of the approved media file. | "autumn-sale.mp4" |
items[].submission_id | string (uuid) | да | Identifier of the submission the approval belongs to. | "6f1c0d3e-52a4-4b57-9a7e-0c3a1b9d2e44" |
items[].structures | integer | да | Number of structures the approval covers. | 3 |
Пример
{
"items": [
{
"number": "TNB-2026-123456",
"valid_from": "2026-10-01",
"valid_until": "2026-12-31",
"status": "pending",
"signed_at": "2026-10-06T14:05:39+05:00",
"env": "test",
"advertiser_name": "Example Advertising LLP",
"media_name": "autumn-sale.mp4",
"submission_id": "6f1c0d3e-52a4-4b57-9a7e-0c3a1b9d2e44",
"structures": 3
}
]
}
Ошибки
Ошибки приходят документом problem (application/problem+json) со стабильным полем code.
| Статус | Значение |
|---|---|
| 401 | Нет действительной сессии или ключа API (unauthenticated, session_expired, invalid_api_key). |
| 403 | Роль или право ключа этого не допускает (forbidden, key_scope_denied, key_route_denied). |
| 429 | Превышен предел частоты; см. Retry-After. |
| default | Ошибка в виде документа problem. |
Примеры кода
curl
curl 'https://app.tanba-ooh.kz/api/v1/approvals' \
-H 'Authorization: Bearer YOUR_API_KEY'
Python
import requests
response = requests.get(
"https://app.tanba-ooh.kz/api/v1/approvals",
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/approvals", 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))
}