OtherAPI ReferenceOrganization

Get the organization's usage for a month

Cost of one calendar month for the organization and each of its projects, with the budget it is measured against.

GET
https://api.soniox.com/v1/organization/usage/monthly

Cost of one calendar month for the organization and each of its projects, with the budget it is measured against.

Headers

AuthorizationRequiredBearer <SONIOX_API_KEY>

Query parameters

monthstring

Calendar month as YYYY-MM, UTC. Defaults to the current month.

Response

200

OK

monthRequiredstring

The month, as YYYY-MM.

usage_usdRequiredstring

Cost of the month across every project.

free_usage_usdRequiredstring

Part of the usage covered by granted balance.

invoiced_usage_usdRequiredstring

Part of the usage that is invoiced.

api_usage_usdRequiredstring

Part of the usage made through the API.

playground_usage_usdRequiredstring

Part of the usage made in the Soniox Console playground.

monthly_budget_usdRequiredstring

Organization budget in effect. Null for a month other than the current one: only today's budget is stored, so it says nothing about a month that has closed.

monthly_budget_notification_usdRequiredstring

Usage at which the organization is emailed. Null when unset, and for a month other than the current one.

remaining_budget_usdRequiredstring

Budget minus usage, never below zero. Null for a month other than the current one.

budget_exhaustedRequiredboolean

Usage reached the budget and requests are refused. Null for a month other than the current one.

projectsRequiredarray<object>

Projects with usage this month, highest cost first. Projects deleted since are included, so the per-project costs add up to usage_usd.

Errors

OK

{
  "month": "string",
  "usage_usd": "string",
  "free_usage_usd": "string",
  "invoiced_usage_usd": "string",
  "api_usage_usd": "string",
  "playground_usage_usd": "string",
  "monthly_budget_usd": "string",
  "monthly_budget_notification_usd": "string",
  "remaining_budget_usd": "string",
  "budget_exhausted": true,
  "projects": [
    {
      "id": "497f6eca-6276-4993-bfeb-53cbbbba6f08",
      "name": "string",
      "usage_usd": "string",
      "free_usage_usd": "string",
      "invoiced_usage_usd": "string",
      "api_usage_usd": "string",
      "playground_usage_usd": "string",
      "monthly_budget_usd": "string"
    }
  ]
}

Bad Request

{
  "status_code": 0,
  "error_type": "string",
  "message": "string",
  "validation_errors": [
    {
      "error_type": "string",
      "location": "string",
      "message": "string"
    }
  ],
  "request_id": "string",
  "more_info": "string"
}

Unauthorized

{
  "status_code": 0,
  "error_type": "string",
  "message": "string",
  "validation_errors": [
    {
      "error_type": "string",
      "location": "string",
      "message": "string"
    }
  ],
  "request_id": "string",
  "more_info": "string"
}

Forbidden

{
  "status_code": 0,
  "error_type": "string",
  "message": "string",
  "validation_errors": [
    {
      "error_type": "string",
      "location": "string",
      "message": "string"
    }
  ],
  "request_id": "string",
  "more_info": "string"
}

Not Found

{
  "status_code": 0,
  "error_type": "string",
  "message": "string",
  "validation_errors": [
    {
      "error_type": "string",
      "location": "string",
      "message": "string"
    }
  ],
  "request_id": "string",
  "more_info": "string"
}

Too Many Requests

{
  "status_code": 0,
  "error_type": "string",
  "message": "string",
  "validation_errors": [
    {
      "error_type": "string",
      "location": "string",
      "message": "string"
    }
  ],
  "request_id": "string",
  "more_info": "string"
}

Internal Server Error

{
  "status_code": 0,
  "error_type": "string",
  "message": "string",
  "validation_errors": [
    {
      "error_type": "string",
      "location": "string",
      "message": "string"
    }
  ],
  "request_id": "string",
  "more_info": "string"
}