keys

Put an end user of a service key on a budget from the key's list, creating it if it does not exist yet.

Answers 201 when the end user was created, so one can be placed on a budget before its first request. An end user already on the budget keeps its current period, so repeating the call changes nothing. A budget that is not on the key's end_user_budget_ids is refused with 403 and end_user_budget_not_allowed.

put/api/v1/keys/{key_id}/end-users/{external_id}

Request

  • The document declares no server URL.
  • Auth: one of:
    • API key in header Otari-Key
    • API key in header x-api-key

Path parameters

key_idstring required
external_idstring required

The id the service names the end user by in a request's user field

Request body

budget_idstring required

A budget on the key's end_user_budget_ids

Response

Successful Response

blockedboolean required
budget_idstring nullable required
budget_started_atstring nullable required
created_atstring required
current_requestsinteger required
current_tokensinteger required
external_idstring required
next_budget_reset_atstring nullable required
owner_user_idstring required
reservednumber required
spendnumber required
user_idstring required

Changes