Set and manage cost control budgets

Define monthly and annual budgets, and a threshold for cost warnings. This helps you keep track of your expenses and avoid unexpected costs. The endpoint returns an ID that may be needed for follow-up calls related to cost management.

Headers

Accept Example
Content-Type Example

Body

required
application/json
monthly_budget integer required
annual_budget any required
alert_threshold integer required

Responses

200
success boolean
timestamp string
requestId string
data object
POST https://cloud.hostup.se/api/cost-management/budget
For AI assistants
cURL
curl -X POST "https://cloud.hostup.se/api/cost-management/budget" \
  -H "X-API-Key: YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "monthly_budget": 0,
    "annual_budget": null,
    "alert_threshold": 0
  }'
Response
{
  "success": true,
  "timestamp": "string",
  "requestId": "string",
  "data": {
    "success": true,
    "budget": {
      "id": 0,
      "client_id": "string",
      "monthly_budget": "string",
      "annual_budget": "string",
      "alert_threshold": 0,
      "email": "string",
      "active": true,
      "last_alerted": "string",
      "created_at": "string",
      "updated_at": "string"
    }
  }
}
Request Body
{
  "monthly_budget": 0,
  "annual_budget": null,
  "alert_threshold": 0
}