RAZIEL.docs
API Explorer

Budget

Monthly spend limits

Get monthly budget status

Returns the current month's spend vs. configured limit.

GET
/api/budget
AuthorizationBearer <token>

Clerk session token. Automatically set as a cookie in the browser; pass as Authorization: Bearer for server-side calls.

In: header

Response Body

curl -X GET "https://app.raziel.fun/api/budget"
{
  "budgetUsd": 50,
  "spentThisMonth": 12.34,
  "percentUsed": 24,
  "isOverBudget": false
}
{
  "error": "Unauthorized"
}

Update monthly budget limit

Set budgetUsd to null to remove the limit entirely.

PATCH
/api/budget
AuthorizationBearer <token>

Clerk session token. Automatically set as a cookie in the browser; pass as Authorization: Bearer for server-side calls.

In: header

budgetUsdnumber
Range0 <= value

Response Body

curl -X PATCH "https://app.raziel.fun/api/budget" \
  -H "Content-Type: application/json" \
  -d '{
    "budgetUsd": 50
  }'
{
  "budgetUsd": 0
}
{
  "error": "Not found"
}
{
  "error": "Unauthorized"
}