Skip to main content
Glama

set_spending_policy

Set organization and current-credential daily spending ceilings in USD cents. Requires billing scope. Set funding_policy=null to keep automatic replenishment off; enabling it requires an explicit amount, threshold, daily maximum, future expiry and mandate reference. Returns applied limits and automatic_funding state; does not itself purchase credits.

Input Schema

NameRequiredDescriptionDefault
bodyYesDaily organization and credential ceilings plus funding_policy (null by default, or an explicit bounded replenishment mandate).

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed4 schema fields changed
    • changedInput schema / properties / body / additionalProperties
      Previous value: -trueNew value: +false
    • addedInput schema / properties / body / description
      Added value: +"Daily organization and credential ceilings plus funding_policy (null by default, or an explicit bounded replenishment mandate)."
    • addedInput schema / properties / body / properties
      Added value: +{
      +  "credential_limit_cents": {
      +    "maximum": 100000,
      +    "minimum": 0,
      +    "type": "integer"
      +  },
      +  "daily_limit_cents": {
      +    "maximum": 100000,
      +    "minimum": 0,
      +    "type": "integer"
      +  },
      +  "funding_policy": {
      +    "oneOf": [
      +      {
      +        "type": "null"
      +      },
      +      {
      +        "additionalProperties": false,
      +        "properties": {
      +          "amountCents": {
      +            "maximum": 100000,
      +            "minimum": 50,
      +            "type": "integer"
      +          },
      +          "dailyMaximumCents": {
      +            "maximum": 100000,
      +            "minimum": 0,
      +            "type": "integer"
      +          },
      +          "expiresAt": {
      +            "format": "date-time",
      +            "type": "string"
      +          },
      +          "mandateReference": {
      +            "minLength": 1,
      +            "type": "string"
      +          },
      +          "thresholdCents": {
      +            "maximum": 100000,
      +            "minimum": 0,
      +            "type": "integer"
      +          }
      +        },
      +        "required": [
      +          "amountCents",
      +          "thresholdCents",
      +          "dailyMaximumCents",
      +          "expiresAt",
      +          "mandateReference"
      +        ],
      +        "type": "object"
      +      }
      +    ]
      +  }
      +}
    • addedInput schema / properties / body / required
      Added value: +[
      +  "daily_limit_cents",
      +  "credential_limit_cents",
      +  "funding_policy"
      +]
  2. First observed

TDQS

A4.3/5.0
Behavior4/5

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

Annotations already declare it a non-read-only, non-idempotent, non-destructive open-world write. The description adds meaningful context beyond them: the auth prerequisite (billing scope), the full set of required fields for enabling replenishment, the returned state (applied limits and automatic_funding), and the scope-limiting note that it does not purchase credits.

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?

Three dense sentences, front-loaded with the core action and scope, then transition rules, then return/side-effect clarification. Each clause earns its place, though the second sentence is packed with a long field enumeration that could be trimmed.

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 single nested-body mutation tool with no output schema, the description covers the auth requirement, the conditional funding_policy branch, the returned state, and the non-purchase boundary. Annotations carry the remaining side-effect profile, leaving little an agent needs that is missing.

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 baseline is 3, but the description adds genuine semantics the schema does not: the USD-cents unit, the behavioral meaning of funding_policy=null (replenishment stays off), and the fact that the nested object requires all five fields as an explicit mandate. It interprets the structure rather than restating it.

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

Purpose5/5

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

States a specific verb and resource (set organization and current-credential daily spending ceilings, in USD cents) and explicitly disambiguates from the sibling purchase_credits by noting it "does not itself purchase credits." An agent can distinguish this policy-setting tool from credit-purchasing and credential tools without opening a schema.

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

Usage Guidelines4/5

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

Gives clear triggering conditions: "Requires billing scope" and the conditional branch rule "Set funding_policy=null to keep automatic replenishment off; enabling it requires an explicit amount, threshold, daily maximum, future expiry and mandate reference." It clarifies what the tool is not (a purchase mechanism) but does not name an explicit alternative sibling by name for the wrong-scope case.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources