Reference API
Účet a agentury
Účet, ke kterému klíč patří, a u agentur klientské účty, ve kterých může klíč pracovat (hlavička DOOHUB-Account).
Každý endpoint přijímá i hlavičku DOOHUB-Account (agentury: id klientského účtu).
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.
Požadavek
curl "https://admin.doohub.online/api/v1/account" \
-H "Authorization: Bearer dh_…"Odpověď 200
{
"data": {
"id": "3f2b8c1e-5d4a-4c7e-9b61-2a8e0f6d1c47",
"name": "string",
"type": "person",
"currency": "CZK",
"status": "string",
"verification_level": 0,
"tariff": "string",
"created_at": "2026-11-02T09:30:00Z"
}
}get
/organizationsAccounts the key can work in
The key's own account (relation: own) and, for an agency, its client accounts (relation: client, with the role the client gave). Send a client's id as DOOHUB-Account.
Jakýkoli klíč
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.
Požadavek
curl "https://admin.doohub.online/api/v1/organizations" \
-H "Authorization: Bearer dh_…"Odpověď 200
{
"data": [
{
"id": "3f2b8c1e-5d4a-4c7e-9b61-2a8e0f6d1c47",
"name": "string",
"type": "person",
"currency": "CZK",
"status": "string",
"relation": "own",
"role": "string",
"since": "2026-11-02T09:30:00Z"
}
],
"meta": {
"total": 0
}
}get
/clientsClient accounts of the agency
Accounts that gave the key's agency access (Agency tariff); send one's id as DOOHUB-Account to work in it. Empty without the Agency tariff.
Jakýkoli klíč
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.
Požadavek
curl "https://admin.doohub.online/api/v1/clients" \
-H "Authorization: Bearer dh_…"Odpověď 200
{
"data": [
{
"id": "3f2b8c1e-5d4a-4c7e-9b61-2a8e0f6d1c47",
"name": "string",
"type": "person",
"currency": "CZK",
"role": "campaign_manager",
"since": "2026-11-02T09:30:00Z"
}
],
"meta": {
"total": 0
}
}