latestOpenAPI 3.1.0raw.githubusercontent.com2026-08-14129143297.4 KB

0e52fe5f8d33

admin

Update User Plan

Change a user's plan and re-cap their active month's quota row.

Without the quota-row update, a mid-month flip would not take effect until the next calendar reset because UsageQuota captures limits at row creation. messages_used / tokens_used carry over so a user partway through their old cap does not get a free reset.

put/api/admin/users/{user_id}/plan

Path parameters

user_idstring required

Request body

planstring required

Response

Successful Response

user_idstring required
planstring required
messages_limitinteger required
tokens_limitinteger required