Models

Update project model grant

Changed on

Updates the project's overrides for the configured model. Omitted fields keep their current values; null, or [] for supported_reasoning_efforts, input_modalities, and output_modalities, clears an override so the project inherits from the configured model. Agents already using the model apply the updated overrides on their next model call. Updates are validated against the configured model's current revision but not against agent configs, so narrowing below a config's model settings, such as its context_window_tokens or reasoning effort, makes that agent's next model call fail.

patch/orgs/{orgID}/projects/{projectID}/model-grants/{modelGrantID}

Request

  • Base URL
    https://api.omnara.com/v1
  • Auth
    • HTTP bearer
    • or API key in cookie __Host-omnara_session and API key in header X-Omnara-Csrf

Path parameters

orgID, string required

Organization ID (org_...).

projectID, string required

Project ID (proj_...).

modelGrantID, string required

Project model grant ID (pmog_...).

Request body

UpdateProjectModelGrantRequest required

Update a project model grant's overrides. Omitted fields keep their current values. Null clears an override so the project inherits from the configured model; for arrays, an empty array clears the override.

context_window_tokens, integer nullable

Project context budget for input and output tokens. Cannot exceed the configured model's budget. Triggers compaction when estimated input exceeds the remaining budget after output and safety reserves. The turn fails if compaction cannot make it fit.

max_output_tokens, integer nullable

Project output-token ceiling. Cannot exceed the configured model's ceiling.

default_max_output_tokens, integer nullable

Default output allowance per request for this project; agents can raise it up to max_output_tokens. Null inherits the configured model's.

default_cache_retention, 'none' | 'short' | 'long' nullable

Prompt-cache preference for model requests; short when omitted. short applies the route's default caching (explicit cache breakpoints where the provider requires them) and, where the route accepts one, a stable conversation key for cache-aware routing. long prefers the route's extended cache lifetime where one exists (currently Anthropic's one-hour cache, which on Bedrock requires Claude 4.5 or newer) and behaves like short elsewhere. none sends no Omnara-managed cache controls or conversation key; providers may still cache prefixes on their own.

supports_tools, boolean nullable

Project-level tool-use gate. Can disable tools, but cannot enable tools when the configured model does not support them.

supports_reasoning, boolean nullable

Project-level reasoning gate. Can disable reasoning, but cannot enable reasoning when the configured model does not support it.

default_reasoning_effort, string nullable

Reasoning effort this project uses by default. Null inherits the configured model's.

supported_reasoning_efforts, string[]

Reasoning efforts this project may use, limited to the configured model's. If this excludes the inherited default_reasoning_effort, set default_reasoning_effort too.

input_modalities, string[]

Input types this project may send, such as text, image, or file; limited to the configured model's.

output_modalities, string[]

Output types this project may receive, limited to the configured model's.

Response

Route response.

ProjectModelGrantEnvelope required
grant, ProjectModelGrant required

Changes

    • breaking

      the context_window_tokens request property's min was increased to 2.00

    • warning

      the context_window_tokens request property's max was set to 2147483647.00

    • info

      added the optional property current_digest to the response with the status

    158 more changes in this revision