Skip to main content
POST

Authorizations

Authorization
string
header
required

Timbal API key. Obtain your API key from the Timbal platform settings. See Authentication for more information.

Path Parameters

org_id
string
required

Body

application/json

Request body for POST /orgs/{org_id}/models/policies.

provider
string
required

Model provider slug, e.g. byteplus, openai.

effect
null | enum<string>

Rule effect. Defaults to deny.

Available options:
allow,
deny
model_id
string | null

Model to target. Omit to target every model of the provider.

Response

Policy rule created

An organization policy rule restricting LLM provider or model usage.

created_at
string<date-time>
required
effect
enum<string>
required

Whether a policy rule allows or denies its target. A model-level rule beats a provider-level rule; deny beats allow at the same specificity.

Available options:
allow,
deny
id
string
required
provider
string
required

Model provider slug, e.g. byteplus, openai.

created_by_user_id
string | null

User who created the rule.

model_id
string | null

Model targeted by the rule. Omitted when the rule covers the whole provider.