Reference API
Kampaně
Kampaně účtu a s klíčem pro zápis jejich zakládání: koncept, rezervace ploch, nahrání kreativ a odeslání ke schválení. Odeslání kontroluje totéž co portál – termín, plochy, kreativy, volné sloty a kredit.
curl -X POST https://admin.doohub.online/api/v1/campaigns -H "Authorization: Bearer dh_…" -H "Content-Type: application/json" \
-d '{"name":"Podzimní akce","starts_on":"2026-11-02","ends_on":"2026-11-15","spot_seconds":15}'
curl -X PUT https://admin.doohub.online/api/v1/campaigns/{id}/screens/{screenId} … -d '{"pricing_model":"cpm","plays":5000}'
curl -X POST https://admin.doohub.online/api/v1/campaigns/{id}/creatives/uploads … -d '{"mime":"image/jpeg","size":482113}'
curl -X PUT "{upload_url}" -H "Content-Type: image/jpeg" --data-binary @spot.jpg
curl -X POST https://admin.doohub.online/api/v1/campaigns/{id}/creatives … -d '{"path":"{path}","width":1920,"height":1080}'
curl -X POST https://admin.doohub.online/api/v1/campaigns/{id}/submit -H "Authorization: Bearer dh_…"Každý endpoint přijímá i hlavičku DOOHUB-Account (agentury: id klientského účtu).
Parametry
| Název | Typ | Popis |
|---|---|---|
| statusv dotazu | draft | pending_review | approved | rejected | cancelled | |
| limitv dotazu | integer | |
| offsetv dotazu | integer |
Chyby
401Missing, invalid or revoked API key.403The account's plan doesn't include the API (Business, Network, Pro or Agency), DOOHUB-Account is not a client of the agency (client_forbidden), or the endpoint needs DOOHUB Network (module_required).429More than 120 requests a minute; see Retry-After.
curl "https://admin.doohub.online/api/v1/campaigns" \
-H "Authorization: Bearer dh_…"{
"data": [
{
"id": "3f2b8c1e-5d4a-4c7e-9b61-2a8e0f6d1c47",
"name": "string",
"status": "draft",
"objective": "string",
"category": "string",
"starts_on": "2026-11-02",
"ends_on": "2026-11-02",
"spot_seconds": 0,
"total": {
"currency": "CZK",
"amount_minor": 0
},
"submitted_at": "2026-11-02T09:30:00Z",
"reviewed_at": "2026-11-02T09:30:00Z",
"rejection_reason": "string",
"created_at": "2026-11-02T09:30:00Z"
}
],
"meta": {
"total": 0,
"limit": 0,
"offset": 0
}
}Tělo požadavku
| Pole | Typ | Popis |
|---|---|---|
| namepovinný | string | |
| objective | string | null | |
| category | retail | food | automotive | finance | health | beauty | travel | entertainment | real_estate | education | services | public | alcohol | gambling | politics | other | null | |
| starts_on | string (date) | null | |
| ends_on | string (date) | null | |
| spot_seconds | 5 | 10 | 15 | 20 | 30 | 45 | 60 |
Chyby
401Missing, invalid or revoked API key.403The plan doesn't include the API, the key can only read (write_required) or the client's role doesn't allow it (client_role).404Not found in this account.409The campaign is no longer a draft or rejected (not_editable).422Invalid input or a rule of the platform (code and message say which).429More than 120 requests a minute; see Retry-After.
curl -X POST "https://admin.doohub.online/api/v1/campaigns" \
-H "Authorization: Bearer dh_…" \
-H "Content-Type: application/json" \
-d '{"name":"string","objective":"string","category":"retail","starts_on":"2026-11-02","ends_on":"2026-11-02","spot_seconds":15}'{
"name": "string",
"objective": "string",
"category": "retail",
"starts_on": "2026-11-02",
"ends_on": "2026-11-02",
"spot_seconds": 15
}{
"data": {
"id": "3f2b8c1e-5d4a-4c7e-9b61-2a8e0f6d1c47",
"name": "string",
"status": "draft",
"objective": "string",
"category": "string",
"starts_on": "2026-11-02",
"ends_on": "2026-11-02",
"spot_seconds": 0,
"total": {
"currency": "CZK",
"amount_minor": 0
},
"submitted_at": "2026-11-02T09:30:00Z",
"reviewed_at": "2026-11-02T09:30:00Z",
"rejection_reason": "string",
"created_at": "2026-11-02T09:30:00Z",
"screens": [
{
"screen_id": "3f2b8c1e-5d4a-4c7e-9b61-2a8e0f6d1c47",
"screen_name": "string",
"pricing_model": "cpm",
"plays": 0,
"max_plays_per_day": 0,
"slots": 0,
"price_minor": 0,
"owner_status": "string"
}
],
"creatives": [
{
"id": "3f2b8c1e-5d4a-4c7e-9b61-2a8e0f6d1c47",
"kind": "image",
"mime": "string",
"size_bytes": 0,
"width": 0,
"height": 0,
"duration_seconds": 0,
"file_name": "string",
"created_at": "2026-11-02T09:30:00Z"
}
]
}
}Parametry
| Název | Typ | Popis |
|---|---|---|
| idv cestě · povinný | string (uuid) |
Chyby
401Missing, invalid or revoked API key.403The account's plan doesn't include the API (Business, Network, Pro or Agency), DOOHUB-Account is not a client of the agency (client_forbidden), or the endpoint needs DOOHUB Network (module_required).404Not found in this account.429More than 120 requests a minute; see Retry-After.
curl "https://admin.doohub.online/api/v1/campaigns/{id}" \
-H "Authorization: Bearer dh_…"{
"data": {
"id": "3f2b8c1e-5d4a-4c7e-9b61-2a8e0f6d1c47",
"name": "string",
"status": "draft",
"objective": "string",
"category": "string",
"starts_on": "2026-11-02",
"ends_on": "2026-11-02",
"spot_seconds": 0,
"total": {
"currency": "CZK",
"amount_minor": 0
},
"submitted_at": "2026-11-02T09:30:00Z",
"reviewed_at": "2026-11-02T09:30:00Z",
"rejection_reason": "string",
"created_at": "2026-11-02T09:30:00Z",
"screens": [
{
"screen_id": "3f2b8c1e-5d4a-4c7e-9b61-2a8e0f6d1c47",
"screen_name": "string",
"pricing_model": "cpm",
"plays": 0,
"max_plays_per_day": 0,
"slots": 0,
"price_minor": 0,
"owner_status": "string"
}
],
"creatives": [
{
"id": "3f2b8c1e-5d4a-4c7e-9b61-2a8e0f6d1c47",
"kind": "image",
"mime": "string",
"size_bytes": 0,
"width": 0,
"height": 0,
"duration_seconds": 0,
"file_name": "string",
"created_at": "2026-11-02T09:30:00Z"
}
]
}
}/campaigns/{id}Change a draft or rejected campaign
Write key. Only the fields sent change.
Klíč pro zápis
Parametry
| Název | Typ | Popis |
|---|---|---|
| idv cestě · povinný | string (uuid) |
Tělo požadavku
| Pole | Typ | Popis |
|---|---|---|
| namepovinný | string | |
| objective | string | null | |
| category | retail | food | automotive | finance | health | beauty | travel | entertainment | real_estate | education | services | public | alcohol | gambling | politics | other | null | |
| starts_on | string (date) | null | |
| ends_on | string (date) | null | |
| spot_seconds | 5 | 10 | 15 | 20 | 30 | 45 | 60 |
Chyby
401Missing, invalid or revoked API key.403The plan doesn't include the API, the key can only read (write_required) or the client's role doesn't allow it (client_role).404Not found in this account.409The campaign is no longer a draft or rejected (not_editable).422Invalid input or a rule of the platform (code and message say which).429More than 120 requests a minute; see Retry-After.
curl -X PATCH "https://admin.doohub.online/api/v1/campaigns/{id}" \
-H "Authorization: Bearer dh_…" \
-H "Content-Type: application/json" \
-d '{"name":"string","objective":"string","category":"retail","starts_on":"2026-11-02","ends_on":"2026-11-02","spot_seconds":15}'{
"name": "string",
"objective": "string",
"category": "retail",
"starts_on": "2026-11-02",
"ends_on": "2026-11-02",
"spot_seconds": 15
}{
"data": {
"id": "3f2b8c1e-5d4a-4c7e-9b61-2a8e0f6d1c47",
"name": "string",
"status": "draft",
"objective": "string",
"category": "string",
"starts_on": "2026-11-02",
"ends_on": "2026-11-02",
"spot_seconds": 0,
"total": {
"currency": "CZK",
"amount_minor": 0
},
"submitted_at": "2026-11-02T09:30:00Z",
"reviewed_at": "2026-11-02T09:30:00Z",
"rejection_reason": "string",
"created_at": "2026-11-02T09:30:00Z",
"screens": [
{
"screen_id": "3f2b8c1e-5d4a-4c7e-9b61-2a8e0f6d1c47",
"screen_name": "string",
"pricing_model": "cpm",
"plays": 0,
"max_plays_per_day": 0,
"slots": 0,
"price_minor": 0,
"owner_status": "string"
}
],
"creatives": [
{
"id": "3f2b8c1e-5d4a-4c7e-9b61-2a8e0f6d1c47",
"kind": "image",
"mime": "string",
"size_bytes": 0,
"width": 0,
"height": 0,
"duration_seconds": 0,
"file_name": "string",
"created_at": "2026-11-02T09:30:00Z"
}
]
}
}/campaigns/{id}/screens/{screenId}Book a screen or change its plan
Write key. Screens from GET /marketplace/screens. Per play (cpm) or slots per day (slot), as the screen offers.
Klíč pro zápis
Parametry
| Název | Typ | Popis |
|---|---|---|
| idv cestě · povinný | string (uuid) | |
| screenIdv cestě · povinný | string (uuid) |
Tělo požadavku
| Pole | Typ | Popis |
|---|---|---|
| pricing_modelpovinný | cpm | slot | |
| plays | integer | |
| max_plays_per_day | integer | null | |
| slots | integer |
Chyby
401Missing, invalid or revoked API key.403The plan doesn't include the API, the key can only read (write_required) or the client's role doesn't allow it (client_role).404Not found in this account.409The campaign is no longer a draft or rejected (not_editable).422Invalid input or a rule of the platform (code and message say which).429More than 120 requests a minute; see Retry-After.
curl -X PUT "https://admin.doohub.online/api/v1/campaigns/{id}/screens/{screenId}" \
-H "Authorization: Bearer dh_…" \
-H "Content-Type: application/json" \
-d '{"pricing_model":"cpm","plays":100,"max_plays_per_day":1}'{
"pricing_model": "cpm",
"plays": 100,
"max_plays_per_day": 1
}{
"data": {
"id": "3f2b8c1e-5d4a-4c7e-9b61-2a8e0f6d1c47",
"name": "string",
"status": "draft",
"objective": "string",
"category": "string",
"starts_on": "2026-11-02",
"ends_on": "2026-11-02",
"spot_seconds": 0,
"total": {
"currency": "CZK",
"amount_minor": 0
},
"submitted_at": "2026-11-02T09:30:00Z",
"reviewed_at": "2026-11-02T09:30:00Z",
"rejection_reason": "string",
"created_at": "2026-11-02T09:30:00Z",
"screens": [
{
"screen_id": "3f2b8c1e-5d4a-4c7e-9b61-2a8e0f6d1c47",
"screen_name": "string",
"pricing_model": "cpm",
"plays": 0,
"max_plays_per_day": 0,
"slots": 0,
"price_minor": 0,
"owner_status": "string"
}
],
"creatives": [
{
"id": "3f2b8c1e-5d4a-4c7e-9b61-2a8e0f6d1c47",
"kind": "image",
"mime": "string",
"size_bytes": 0,
"width": 0,
"height": 0,
"duration_seconds": 0,
"file_name": "string",
"created_at": "2026-11-02T09:30:00Z"
}
]
}
}Parametry
| Název | Typ | Popis |
|---|---|---|
| idv cestě · povinný | string (uuid) | |
| screenIdv cestě · povinný | string (uuid) |
Chyby
401Missing, invalid or revoked API key.403The plan doesn't include the API, the key can only read (write_required) or the client's role doesn't allow it (client_role).404Not found in this account.409The campaign is no longer a draft or rejected (not_editable).422Invalid input or a rule of the platform (code and message say which).429More than 120 requests a minute; see Retry-After.
curl -X DELETE "https://admin.doohub.online/api/v1/campaigns/{id}/screens/{screenId}" \
-H "Authorization: Bearer dh_…"(bez obsahu)/campaigns/{id}/creatives/uploadsGet an upload URL for a creative
Write key. Then PUT the file to upload_url with the returned headers (within 2 hours) and add it with POST /campaigns/{id}/creatives. JPEG, PNG, WebP up to 10 MB, MP4 up to 200 MB.
Klíč pro zápis
Parametry
| Název | Typ | Popis |
|---|---|---|
| idv cestě · povinný | string (uuid) |
Tělo požadavku
| Pole | Typ | Popis |
|---|---|---|
| mimepovinný | image/jpeg | image/png | image/webp | video/mp4 | |
| sizepovinný | integer | Bytes. |
| file_name | string |
Chyby
401Missing, invalid or revoked API key.403The plan doesn't include the API, the key can only read (write_required) or the client's role doesn't allow it (client_role).404Not found in this account.409The campaign is no longer a draft or rejected (not_editable).422Invalid input or a rule of the platform (code and message say which).429More than 120 requests a minute; see Retry-After.
curl -X POST "https://admin.doohub.online/api/v1/campaigns/{id}/creatives/uploads" \
-H "Authorization: Bearer dh_…" \
-H "Content-Type: application/json" \
-d '{"mime":"image/jpeg","size":0,"file_name":"string"}'{
"mime": "image/jpeg",
"size": 0,
"file_name": "string"
}{
"data": {
"path": "string",
"upload_url": "https://example.com/doohub",
"method": "PUT",
"headers": {},
"expires_in": 0
}
}/campaigns/{id}/creativesAdd an uploaded creative
Write key. Type and size are read from the uploaded file; videos need duration_seconds.
Klíč pro zápis
Parametry
| Název | Typ | Popis |
|---|---|---|
| idv cestě · povinný | string (uuid) |
Tělo požadavku
| Pole | Typ | Popis |
|---|---|---|
| pathpovinný | string | From the upload. |
| width | integer | null | |
| height | integer | null | |
| duration_seconds | number | null | Required for videos; at most spot_seconds. |
| file_name | string | null |
Chyby
401Missing, invalid or revoked API key.403The plan doesn't include the API, the key can only read (write_required) or the client's role doesn't allow it (client_role).404Not found in this account.409The campaign is no longer a draft or rejected (not_editable).422Invalid input or a rule of the platform (code and message say which).429More than 120 requests a minute; see Retry-After.
curl -X POST "https://admin.doohub.online/api/v1/campaigns/{id}/creatives" \
-H "Authorization: Bearer dh_…" \
-H "Content-Type: application/json" \
-d '{"path":"string","width":0,"height":0,"duration_seconds":0,"file_name":"string"}'{
"path": "string",
"width": 0,
"height": 0,
"duration_seconds": 0,
"file_name": "string"
}{
"data": {
"id": "3f2b8c1e-5d4a-4c7e-9b61-2a8e0f6d1c47",
"kind": "image",
"mime": "string",
"size_bytes": 0,
"width": 0,
"height": 0,
"duration_seconds": 0,
"file_name": "string",
"created_at": "2026-11-02T09:30:00Z"
}
}Parametry
| Název | Typ | Popis |
|---|---|---|
| idv cestě · povinný | string (uuid) | |
| creativeIdv cestě · povinný | string (uuid) |
Chyby
401Missing, invalid or revoked API key.403The plan doesn't include the API, the key can only read (write_required) or the client's role doesn't allow it (client_role).404Not found in this account.409The campaign is no longer a draft or rejected (not_editable).422Invalid input or a rule of the platform (code and message say which).429More than 120 requests a minute; see Retry-After.
curl -X DELETE "https://admin.doohub.online/api/v1/campaigns/{id}/creatives/{creativeId}" \
-H "Authorization: Bearer dh_…"(bez obsahu)/campaigns/{id}/submitSubmit the campaign for review
Write key. Checks dates, screens, creatives, capacity and credit like the portal, fixes the prices and reserves the credit; then the platform reviews the campaign and the screen owners confirm it.
Klíč pro zápis
Parametry
| Název | Typ | Popis |
|---|---|---|
| idv cestě · povinný | string (uuid) |
Chyby
401Missing, invalid or revoked API key.403The plan doesn't include the API, the key can only read (write_required) or the client's role doesn't allow it (client_role).404Not found in this account.409The campaign is no longer a draft or rejected (not_editable).422Invalid input or a rule of the platform (code and message say which).429More than 120 requests a minute; see Retry-After.
curl -X POST "https://admin.doohub.online/api/v1/campaigns/{id}/submit" \
-H "Authorization: Bearer dh_…"{
"data": {
"id": "3f2b8c1e-5d4a-4c7e-9b61-2a8e0f6d1c47",
"name": "string",
"status": "draft",
"objective": "string",
"category": "string",
"starts_on": "2026-11-02",
"ends_on": "2026-11-02",
"spot_seconds": 0,
"total": {
"currency": "CZK",
"amount_minor": 0
},
"submitted_at": "2026-11-02T09:30:00Z",
"reviewed_at": "2026-11-02T09:30:00Z",
"rejection_reason": "string",
"created_at": "2026-11-02T09:30:00Z",
"screens": [
{
"screen_id": "3f2b8c1e-5d4a-4c7e-9b61-2a8e0f6d1c47",
"screen_name": "string",
"pricing_model": "cpm",
"plays": 0,
"max_plays_per_day": 0,
"slots": 0,
"price_minor": 0,
"owner_status": "string"
}
],
"creatives": [
{
"id": "3f2b8c1e-5d4a-4c7e-9b61-2a8e0f6d1c47",
"kind": "image",
"mime": "string",
"size_bytes": 0,
"width": 0,
"height": 0,
"duration_seconds": 0,
"file_name": "string",
"created_at": "2026-11-02T09:30:00Z"
}
]
}
}/creativesCreatives of the account's campaigns
With the campaign, its review state (a creative is reviewed with its campaign) and, for Studio designs, whether it plays as a live scene. Upload under /campaigns/{id}/creatives.
Jakýkoli klíč
Parametry
| Název | Typ | Popis |
|---|---|---|
| campaign_idv dotazu | string (uuid) | |
| kindv dotazu | image | video | html | |
| limitv dotazu | integer | |
| offsetv dotazu | integer |
Chyby
401Missing, invalid or revoked API key.403The account's plan doesn't include the API (Business, Network, Pro or Agency), DOOHUB-Account is not a client of the agency (client_forbidden), or the endpoint needs DOOHUB Network (module_required).429More than 120 requests a minute; see Retry-After.
curl "https://admin.doohub.online/api/v1/creatives" \
-H "Authorization: Bearer dh_…"{
"data": [
{
"id": "3f2b8c1e-5d4a-4c7e-9b61-2a8e0f6d1c47",
"campaign_id": "3f2b8c1e-5d4a-4c7e-9b61-2a8e0f6d1c47",
"campaign": {
"name": "string",
"status": "string"
},
"review": "not_submitted",
"kind": "image",
"mime": "string",
"size_bytes": 0,
"resolution": {
"width": 0,
"height": 0
},
"duration_seconds": 0,
"file_name": "string",
"studio": {
"design_id": "string",
"live_scene": false
},
"created_at": "2026-11-02T09:30:00Z"
}
],
"meta": {
"total": 0,
"limit": 0,
"offset": 0
}
}