Get a service's traffic
/services/{serviceId}/usageUse this to read traffic used in the current traffic period against the allowance. The traffic period is the server's own monthly traffic cycle, which can differ from its billing period.
- Token
- Bearer API token: cxk_live_ followed by 46 letters and digits
- Scope
services:read- Header
Authorization: Bearer $CLOUDUXE_API_KEY
How tokens and scopes work: Authentication and scopes.
serviceIdstring (uuid)RequiredThe service's id.
Clouduxe-VersionstringOptionalThe API version to use, such as 2026-12-01. Omit it to use your token's version.
pattern ^[0-9]{4}-[0-9]{2}-[0-9]{2}$
200OK The usage.
objectstringRequiredThe object's type. Always "usage".
serviceIdstring (uuid)RequiredThe service's id.
periodStartstring (date)RequiredThe period's first day (UTC).
periodEndstring (date)RequiredThe period's last day (UTC).
inboundBytesinteger or nullRequiredBytes received this period, or null when not known.
outboundBytesinteger or nullRequiredBytes sent this period, or null.
allowanceBytesinteger or nullRequiredThe period's traffic allowance in bytes, or null for unmetered or unknown.
updatedAtstring (date-time) or nullRequiredWhen these figures were read.
Every response
- 200OKThe usage.
- 400Bad requestThe request is not valid. Codes: version_invalid.
- 401UnauthorizedAuthentication failed. Codes: token_missing, token_invalid, token_expired, token_revoked.
- 403ForbiddenThe token is not allowed to do this. Codes: ip_not_allowed, api_access_disabled, scope_missing.
- 404Not foundNot found. Codes: not_found.
- 409ConflictThe request conflicts with the object's current state. Codes: service_not_ready.
- 429Too many requestsA rate limit was reached. Codes: rate_limited.
- 500Server errorUnexpected error. Codes: internal_error.
- 503UnavailableTemporarily unavailable. Codes: unavailable.