Skip to main content
Glama

add_credits

Idempotent

Compatibility credit grant (1-10000); beta customer operations are already free.

    When VHGENGINE_ADMIN_KEY is configured on the deployment this requires a
    matching admin_key argument; otherwise it stays self-serve (unless
    VHGENGINE_FREE_CREDITS is off). Idempotent on idempotency_key (replay does NOT
    grant twice). Returns {credits (new balance), granted}. Errors: unauthorized
    (missing/wrong admin key or self-serve disabled), invalid_request (amount range
    / balance ceiling), idempotency_conflict, rate_limited.
    

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
amountYesCompatibility credits to add, 1-10000. Customer operations are free during beta, so this is not required for access. The grant has a per-account balance ceiling.
api_keyNoAPI key for this call. Omit to fall back to the Authorization: Bearer / X-API-Key request header (streamable-HTTP only), then the VHGENGINE_API_KEY env var (the stdio default). No key resolvable -> unauthorized.
admin_keyNoThe deployment's VHGENGINE_ADMIN_KEY. Required ONLY when the operator configured one; omit on a self-serve deployment. A wrong or missing value where one is configured is unauthorized.
idempotency_keyNoCaller-chosen replay key (any string, unique per intended effect). A repeat call with the SAME key returns the stored result and is NEVER charged twice; the same key with different arguments is an idempotency_conflict. Omit and every call is a fresh, separately charged operation.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
creditsNoBalance AFTER the grant.
grantedNoCredits added by this call; 0 on an idempotent replay.
replayedNotrue when an earlier call with the same idempotency_key already granted.

TDQS

A4.4/5.0
Behavior5/5

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

Beyond the idempotentHint annotation, the description details idempotency semantics (replay does NOT grant twice, idempotency_conflict), enumerates specific error types (unauthorized, invalid_request, rate_limited), and specifies the return shape ({credits, granted}). This is substantial behavioral disclosure exceeding what annotations provide.

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

Conciseness5/5

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

The description is compact and well-structured: purpose and range in the first sentence, followed by deployment-dependent auth behavior, idempotency, return value, and error cases. Every sentence adds unique information with no redundancy or fluff.

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

Completeness5/5

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

Given the tool's complexity (conditional auth, idempotency, error handling, return output), the description covers all essential aspects: admin key conditions, idempotency mechanics, error categories, and response format. The detailed parameter schema and output schema fill any remaining gaps, making it contextually complete.

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?

The input schema already covers all four parameters with descriptions (100% coverage), meeting the baseline. The description enriches the semantics of idempotency_key (replay behavior) and admin_key (conditional requirement), adding value beyond the schema.

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?

The description clearly states a 'Compatibility credit grant' with a 1-10000 range, identifying the action and resource. It also adds context about beta operations being free. However, it does not explicitly differentiate from sibling billing/usage tools, so it lacks explicit sibling comparison.

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?

The description provides clear usage context: admin_key is required when the deployment has VHGENGINE_ADMIN_KEY configured, and the tool stays self-serve otherwise unless free credits are disabled. It also implies limited use during beta since operations are already free. No explicit alternatives are named, but the conditions are well specified.

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.

TDQS

A4.1/5.0
Disambiguation5/5

Each tool targets a distinct resource and action, e.g., signup vs. delete_account, create_key vs. revoke_key, generate_hooks vs. score_hook. Even similar tools like generate_hooks and generate_hooks_batch are clearly differentiated by single vs. batch operation.

Naming Consistency5/5

All 32 tools use a consistent verb_noun snake_case pattern (e.g., add_credits, create_checkout, revoke_key, list_outcomes) with no mixing of camelCase or other conventions.

Tool Count4/5

32 tools is slightly above the typical 15-tool range, but the domain is broad (account, keys, webhooks, generation, scoring, jobs, outcomes), and each tool has a specific purpose. No tools seem redundant.

Completeness4/5

The tool surface covers most lifecycle operations: CRUD for accounts/keys/webhooks, generation/scoring with batch and async variants, outcomes reporting, and auxiliary tools. Missing explicit delete for hooks (expire automatically) and some update operations, but no critical gaps.

Resources