Skip to main content
Glama

get_credit_offer

Generate a credit top-up offer as an x402 payment request, supplying a USDC transfer invoice to pay with any asset and credit your account.

Instructions

Create a credit top-up and get the x402 offer (HTTP 402 IS the payment instruction, not an error). accepts[0] is a plain USDC transfer invoice — feed it straight into pay_x402_invoice (keep the note!) to pay with any asset. Credits land ~1 block after the payment confirms.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
api_keyNohsk_ API key override; omit to use the HOGSWAP_API_KEY env config
usdc_microYestop-up size in µUSDC (1 USDC = 1,000,000)
Behavior5/5

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

With no annotations provided, the description fully carries the transparency burden. It discloses the non-obvious HTTP 402 behavior, describes that accepts[0] is an invoice, instructs to keep the note, and explains credit settlement timing (~1 block after payment). This is rich, useful behavioral context.

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?

Three concise sentences front-load the main action, then provide critical behavioral details. Every sentence adds value with no fluff or repetition.

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?

Even without an output schema, the description explains the key response elements (accepts[0], the note), the unusual HTTP 402 semantics, and the post-payment timeline. It gives the agent enough to successfully invoke the tool and understand what to do with the result.

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

Parameters3/5

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

Schema coverage is 100%, so both parameters (api_key and usdc_micro) are already described in the schema. The description does not add additional parameter-level detail beyond what the schema provides, so the baseline score of 3 is appropriate.

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?

The description states a specific verb+resource: 'Create a credit top-up and get the x402 offer'. It clearly distinguishes this tool from siblings like get_quote or build_swap by focusing on the credit top-up and offer process.

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?

Clearly indicates the tool is used to create a top-up and obtain an offer, then directs the agent to feed the result into pay_x402_invoice. It gives clear context, though it does not explicitly mention alternatives or exclusions compared to sibling tools.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/LiquiHog/hogswap-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server