Skip to main content
Glama

Grant model to project

grant_models_add

Grants a configured model to a project for agent configs and returns the new grant, with optional overrides to narrow limits and set per-request defaults.

Instructions

Lets a project's agent configs use a configured model and returns the new grant. Optional overrides can narrow the model for that project (lower token limits, tools or reasoning turned off, fewer reasoning efforts or modalities) and set its per-request defaults within those limits.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "configured_model_id": "<configured_model_id>",
      "orgID": "<orgID>",
      "projectID": "<projectID>"
    },
    "name": "grant_models_add"
  }
}

Input Schema

NameRequiredDescriptionDefault
orgIDYesOrganization ID (org_...).
projectIDYesProject ID (proj_...).
supports_toolsNoOptional project-level tool-use gate. Can disable tools, but cannot enable tools when the configured model does not support them.
input_modalitiesNoOptional project subset of configured-model input types (text, image, or file). Empty or omitted means inherit.
max_output_tokensNoOptional project output-token ceiling. Cannot exceed the configured model's ceiling.
output_modalitiesNoOptional project subset of configured-model output types. Empty or omitted means inherit.
supports_reasoningNoOptional project-level reasoning gate. Can disable reasoning, but cannot enable reasoning when the configured model does not support it.
configured_model_idYesConfigured model the project can use.
context_window_tokensNoOptional 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.
default_cache_retentionNoPrompt-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.
default_reasoning_effortNoReasoning effort this project uses by default, such as low or high. Omit to inherit the configured model's.
default_max_output_tokensNoDefault output allowance per request for this project; agents can raise it up to max_output_tokens. Omit to inherit the configured model's.
supported_reasoning_effortsNoReasoning efforts this project may use, limited to the configured model's. If this excludes the inherited default_reasoning_effort, set default_reasoning_effort too.

Output Schema

NameRequiredDescriptionDefault
grantYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed5 schema fields changedv0.1.10
    • addedInput schema / properties / configured_model_id / description
      Added value: +"Configured model the project can use."
    • changedInput schema / properties / default_max_output_tokens / description
      Previous value: -"Optional project default per-request output-token cap."New value: +"Default output allowance per request for this project; agents can raise it up to max_output_tokens. Omit to inherit the configured model's."
    • changedInput schema / properties / default_reasoning_effort / description
      Previous value: -"Optional project default reasoning effort."New value: +"Reasoning effort this project uses by default, such as low or high. Omit to inherit the configured model's."
    • changedInput schema / properties / supported_reasoning_efforts / description
      Previous value: -"Optional project subset of configured-model reasoning efforts. If this excludes the inherited default_reasoning_effort, set default_reasoning_effort on the grant too."New value: +"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."
    • changedOutput schema / (root)
      Previous value: -nullNew value: +{
      +  "$defs": {
      +    "ConfiguredModelID": {
      +      "pattern": "^mdl_[a-z2-7]{26}$",
      +      "type": "string"
      +    },
      +    "ModelCacheRetention": {
      +      "description": "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.",
      +      "enum": [
      +        "none",
      +        "short",
      +        "long"
      +      ],
      +      "type": "string"
      +    },
      +    "OrganizationID": {
      +      "pattern": "^org_[a-z2-7]{26}$",
      +      "type": "string"
      +    },
      +    "ProjectID": {
      +      "description": "Project ID (proj_...).",
      +      "pattern": "^proj_[a-z2-7]{26}$",
      +      "type": "string"
      +    },
      +    "ProjectModelGrant": {
      +      "properties": {
      +        "configured_model_id": {
      +          "$ref": "#/$defs/ConfiguredModelID"
      +        },
      +        "context_window_tokens": {
      +          "description": "Project context budget for input and output tokens, or omitted/null to inherit from the configured model. Triggers compaction when estimated input exceeds the remaining budget after output and safety reserves. The turn fails if compaction cannot make it fit.",
      +          "type": [
      +            "integer",
      +            "null"
      +          ]
      +        },
      +        "created_at": {
      +          "$ref": "#/$defs/Timestamp"
      +        },
      +        "default_cache_retention": {
      +          "$ref": "#/$defs/ModelCacheRetention"
      +        },
      +        "default_max_output_tokens": {
      +          "description": "Project default per-request output-token cap, or omitted/null to inherit from the configured model.",
      +          "type": [
      +            "integer",
      +            "null"
      +          ]
      +        },
      +        "default_reasoning_effort": {
      +          "description": "Project default reasoning effort, or omitted/empty to inherit from the configured model.",
      +          "type": "string"
      +        },
      +        "id": {
      +          "$ref": "#/$defs/ProjectModelGrantID"
      +        },
      +        "input_modalities": {
      +          "description": "Project subset of configured-model input types (text, image, or file). Empty means inherit.",
      +          "items": {
      +            "type": "string"
      +          },
      +          "type": "array"
      +        },
      +        "max_output_tokens": {
      +          "description": "Project output-token ceiling, or omitted/null to inherit from the configured model.",
      +          "type": [
      +            "integer",
      +            "null"
      +          ]
      +        },
      +        "org_id": {
      +          "$ref": "#/$defs/OrganizationID"
      +        },
      +        "output_modalities": {
      +          "description": "Project subset of configured-model output types. Empty means inherit.",
      +          "items": {
      +            "type": "string"
      +          },
      +          "type": "array"
      +        },
      +        "project_id": {
      +          "$ref": "#/$defs/ProjectID"
      +        },
      +        "supported_reasoning_efforts": {
      +          "description": "Project subset of configured-model reasoning efforts. Empty means inherit. When non-empty, default_reasoning_effort must resolve to one of these values.",
      +          "items": {
      +            "type": "string"
      +          },
      +          "type": "array"
      +        },
      +        "supports_reasoning": {
      +          "description": "Project-level reasoning override, or omitted/null to inherit from the configured model.",
      +          "type": [
      +            "boolean",
      +            "null"
      +          ]
      +        },
      +        "supports_tools": {
      +          "description": "Project-level tool-use override, or omitted/null to inherit from the configured model.",
      +          "type": [
      +            "boolean",
      +            "null"
      +          ]
      +        },
      +        "updated_at": {
      +          "$ref": "#/$defs/Timestamp"
      +        }
      +      },
      +      "required": [
      +        "id",
      +        "org_id",
      +        "project_id",
      +        "configured_model_id",
      +        "supported_reasoning_efforts",
      +        "input_modalities",
      +        "output_modalities",
      +        "created_at",
      +        "updated_at"
      +      ],
      +      "type": "object"
      +    },
      +    "ProjectModelGrantID": {
      +      "pattern": "^pmog_[a-z2-7]{26}$",
      +      "type": "string"
      +    },
      +    "Timestamp": {
      +      "format": "date-time",
      +      "type": "string"
      +    }
      +  },
      +  "properties": {
      +    "grant": {
      +      "$ref": "#/$defs/ProjectModelGrant"
      +    }
      +  },
      +  "required": [
      +    "grant"
      +  ],
      +  "type": "object"
      +}
  2. Changed2 schema fields changedv0.1.1
    • addedInput schema / properties / orgID / description
      Added value: +"Organization ID (org_...)."
    • addedInput schema / properties / projectID / description
      Added value: +"Project ID (proj_...)."
  3. First observed

TDQS

A3.6/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations supply the safety profile (readOnly=false, destructive=false, idempotent=false), so the bar is lower. The description adds two useful facts beyond them: a grant object is returned, and overrides can only narrow the model, never widen it. It does not address what happens on a duplicate grant for the same project or on invalid overrides — notable given idempotentHint=false.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Two sentences, front-loaded with the effect and the return value, then the override semantics. Dense but every clause corresponds to real parameter behavior; nothing is filler padding.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a 13-parameter mutation with an output schema, full schema descriptions, and annotations, the description supplies the effect, the return, and the narrowing model. Only prerequisite/error conditions (model must be configured, duplicate-grant behavior) are absent, which is a modest gap rather than a blocking one.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so the baseline is 3, but the description adds a conceptual frame the schema lacks: one group of parameters narrows the model (token limits, tools/reasoning off, fewer efforts or modalities) while another sets per-request defaults inside those limits. That mental model helps an agent reason about the 13 parameters as two coherent sets rather than individually.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb and resource: enables a project's agent configs to use a configured model, and notes the return value ('returns the new grant'). That cleanly separates it from grant_models_delete/edit/list siblings without naming them, but it never explicitly routes an agent among those alternatives.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Usage is only implied by the verb 'lets ... use' — an agent can infer this is the creation step in the grant lifecycle. There is no explicit when-to-use vs. grant_models_edit/grant_models_list, and no stated prerequisites such as the configured model needing to already exist in the org.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.