Skip to main content
PATCH
Batch upsert models metadata (Admin only)

Authorizations

Authorization
string
header
required

JWT access token for user authentication (Authorization: Bearer <jwt_token>). Create via POST /users/me/access_tokens.

Body

application/json
{key}
object

Request to update model pricing (admin endpoint)

Response

Models upserted successfully

costPerImage
object
required

Decimal price for API responses

The system uses a fixed scale of 9 (nano-dollars = 1 billionth of a dollar). The scale field is included in responses for client convenience.

inputCostPerToken
object
required

Decimal price for API responses

The system uses a fixed scale of 9 (nano-dollars = 1 billionth of a dollar). The scale field is included in responses for client convenience.

metadata
object
required

Model metadata

modelId
string
required
outputCostPerToken
object
required

Decimal price for API responses

The system uses a fixed scale of 9 (nano-dollars = 1 billionth of a dollar). The scale field is included in responses for client convenience.

cacheReadCostPerToken
null | object

Cost per cached input token. Omitted when cache pricing is disabled; an amount of 0 means cached tokens are genuinely free.