Skip to main content
Glama

@hashlock-tech/mcp

Hashlock Markets — the settlement layer for the agent economy, as MCP tools. Non-custodial cross-chain OTC: sealed RFQ + price negotiation + HTLC atomic settlement — both legs settle or both refund; no bridge, no custodian, no counterparty risk. BTC ↔ EVM / TRON.

⚠️ Testnets only for now (Ethereum Sepolia · TRON Nile · Bitcoin signet). Mainnet comes after the security-hardening gate — do not send real funds.

npm License: MIT

What is this?

The canonical Model Context Protocol server for Hashlock Markets. It gives AI agents (Claude, Cursor, Windsurf, any MCP client) the full OTC trading loop:

  1. Browse the asset registry and the public RFQ board

  2. Post a public RFQ or a private fixed-price order (shareable link)

  3. Respond to requests with a price; negotiate (counter / accept / decline) in the deal thread

  4. Agree — both parties accept → an HTLC swap is created

  5. Track settlement — who funded, timelocks, tx hashes — and manage receive/refund addresses

Settlement signing (funding and claiming the HTLCs) stays with your own wallet — the server never holds keys or funds. The swap secret is generated locally on your machine and only its sha256 hashlock is sent; retrieve it with get_deal_secret when it's time to claim.

Related MCP server: hashlock-mcp-server

Two ways to run

  • Local (stdio) — the npm package below. You run it on your machine with your own keys; it can settle autonomously (SIWE login + on-chain signing with HASHLOCK_*_KEY). Full trust in yourself.

  • Remote (hosted, Streamable HTTP) — a public URL (https://dev.hashlock.markets/mcp) anyone can add from Claude / ChatGPT / any MCP client; one-click OAuth, no install. Multi-tenant, so it is strictly non-custodial: settlement returns unsigned transactions you sign with your own wallet, and the server never holds keys or your swap preimage. See Remote (hosted) below.

Install

Local stdio via npx (Claude Desktop / Cursor / Windsurf mcpServers config):

{
  "mcpServers": {
    "hashlock": {
      "command": "npx",
      "args": ["-y", "@hashlock-tech/mcp"],
      "env": {
        "HASHLOCK_EVM_KEY": "0x<agent EVM key (TESTNET!)>",
        "HASHLOCK_TRON_KEY": "<agent TRON key, 64-hex (optional)>",
        "HASHLOCK_BTC_KEY": "<agent BTC WIF, signet (optional)>"
      }
    }
  }
}

Auth — autonomous, per chain

The agent owns its key(s); the server does the login itself (nonce → sign → JWT, refreshed on expiry). The first configured key (EVM → TRON → BTC) mints the session; each key also signs settlement on its chain.

Env var

Chain

Login

HASHLOCK_EVM_KEY

EVM

SIWE personal_sign

HASHLOCK_TRON_KEY

TRON

signMessageV2

HASHLOCK_BTC_KEY

Bitcoin

BIP-322

HASHLOCK_TOKEN

a ready JWT (alternative to a key)

With none set, read-only tools (list_assets, list_open_rfqs, get_rfq) still work. Use dedicated testnet keys.

Other env: HASHLOCK_API_URL (default https://dev.hashlock.markets/api), HASHLOCK_APP_URL (share links; default derived), HASHLOCK_EVM_RPC (default a public Sepolia RPC), HASHLOCK_TRON_HOST (default Nile), HASHLOCK_SECRETS_PATH (default ~/.hashlock/mcp-secrets.json, mode 0600).

Remote (hosted)

The same server also runs as a remote MCP over Streamable HTTP so anyone can connect by URL — no install. This is the multi-tenant, non-custodial surface: browse, RFQ, negotiate, and get unsigned fund/claim/refund transactions you sign with your own wallet (there is no autonomous key-in-env signing and no server-side secret storage here — you supply your own hashlock and keep your own preimage).

Connect from a client: add the server URL. Nothing else — the client discovers that it needs authorization, sends you to Hashlock to sign in and approve, and receives its own key:

URL: https://dev.hashlock.markets/mcp

The grant then appears under Developers as an ordinary API key and can be revoked there at any time. Clients that do not speak OAuth can still send a key they created themselves as Authorization: Bearer hk_….

Standard OAuth 2.1, so any compliant MCP client drives it unattended:

Step

Endpoint

Unauthorized call names its metadata

401 + WWW-Authenticate: … resource_metadata=… (RFC 9728)

Client reads the resource + server metadata

/.well-known/oauth-protected-resource, /.well-known/oauth-authorization-server (RFC 8414)

Client registers itself

POST /oauth/register (RFC 7591)

You sign in and approve, in the browser

/oauth/authorize

Client redeems the code for a key

POST /oauth/token — PKCE S256 required (RFC 7636)

Codes are single-use and expire in 60 seconds; redirect URIs are allowlisted, with loopback permitted per RFC 8252. The issued token IS the API key, so a grant is revocable from the same list as every other key.

Testnets only until the hardening gate.

Run the hosted service yourself:

docker build -t hashlock-mcp-http .
docker run -p 8080:8080 -e HASHLOCK_V1_URL=https://api-dev.hashlock.markets/v1 hashlock-mcp-http
# or, from source:
pnpm build && HASHLOCK_V1_URL=https://api-dev.hashlock.markets/v1 PORT=8080 pnpm start:http

Env: HASHLOCK_V1_URL (developer-API base, default https://api.hashlock.markets/v1) · PORT (default 8080). Put it behind your reverse proxy at /mcp; GET /health is a liveness probe.

Tools (16)

Tool

What it does

list_assets

Asset registry (SYMBOL@chain refs, decimals)

list_open_rfqs

Public RFQ board, filterable

get_rfq

One RFQ / private order

create_rfq

Post a public RFQ or private fixed-price order

cancel_rfq

Cancel your own request

respond_to_rfq

Respond with a price → opens a deal thread

negotiate

message / propose / accept_proposal / accept / reject

my_rfqs, my_deals

Your requests and deal threads

deal_status

Thread + negotiation history + HTLC swap state

set_settlement_address

Your receive/refund address per chain

get_deal_secret

The locally-stored swap preimage (gated on both legs funded)

reveal_claim

Report an out-of-band claim (secret + tx) so the other leg settles

whoami

The account you're authenticated as

fund_leg

Autonomous: fund your side of a swap on-chain with the agent's own key (EVM/TRON/BTC)

claim_leg

Autonomous: claim your receive leg with the preimage (reveals the secret on-chain)

Amounts are human decimal strings ("0.5"); prices are the total quote-asset amount, not per-unit. Errors return a structured envelope { error: { code, is_retryable, recovery_hint } } agents can branch on.

Fully autonomous loop

With a key set for each chain a swap touches, an agent can run end to end with no human: create_rfq/respond_to_rfqnegotiate (accept) → set_settlement_address (both chains) → fund_legclaim_leg. Funding/claiming is signed locally with the agent's keys; the swap secret is generated + stored locally and only its hashlock leaves the machine. Use dedicated testnet keys.

How atomic settlement works

Both parties lock funds in HTLCs bound to the same sha256(secret) hashlock — BTC as a P2WSH script, EVM/TRON as contracts. The initiator funds the long-timelock leg first (asymmetric timelocks, so nobody gets a free option). Claiming one leg reveals the secret on-chain, which unlocks the other leg. Either both legs settle, or both refund after their timelocks. The recipient of each leg is fixed at funding time — revealing the secret cannot redirect funds.

Development

pnpm install
pnpm run build    # tsup → dist/
pnpm run lint     # tsc --noEmit
pnpm test         # vitest

Node ≥ 20. MIT.

Available Tools

13 tools
create_htlcA

Trustless atomic settlement — delivery vs payment (DVP) guarantee. Both sides receive their asset OR both get refunded; zero counterparty risk, zero slippage, no custodian. Records the on-chain HTLC lock tx hash to advance the settlement state machine.

USE WHEN: a trade is accepted and the user has just broadcast the lock transaction on-chain (EVM, Bitcoin, or Sui). DO NOT USE WHEN: the trade is not yet accepted, or the lock tx has not been broadcast yet — submit the on-chain tx first, then call this tool.

PARAM NOTES: role must be INITIATOR (you locked first) or COUNTERPARTY (you locked in response). txHash must be 0x-prefixed. chainType defaults to evm — set "bitcoin" or "sui" for non-EVM legs.

ParametersJSON Schema
NameRequiredDescriptionDefault
tradeIdYesTrade ID from an accepted trade
txHashYesOn-chain transaction hash of the HTLC lock (0x-prefixed)
roleYesYour role in the trade
timelockNoHTLC expiry as Unix timestamp
hashlockNoSHA-256 hashlock (0x-prefixed hex)
chainTypeNoChain type: evm, bitcoin, or sui
preimageNoSecret preimage (only for initiator)
client_request_idNoIdempotency key. Retrying the SAME write with the SAME id within this MCP session returns the first result instead of triggering a second on-chain/backend side effect. Best-effort: not durable across MCP restarts.

TDQS

A4.3/5.0
Behavior3/5

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

No annotations provided. Description mentions idempotency via client_request_id but does not detail side effects, error states, or what happens on failure. The tool's impact on state machine is implied but not fully explained.

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?

Concise and well-structured: main purpose, usage guidance, then parameter notes. No redundant information, each sentence adds value.

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

Completeness3/5

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

No output schema. Description explains purpose and param notes but lacks details on return value, error handling, or how this tool fits into the overall trade lifecycle. Could be more complete for a complex settlement tool.

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%, baseline 3. Description adds value with notes on role requirements, txHash format, and chainType defaults, clarifying usage beyond schema definitions.

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?

Description clearly states the tool's purpose: recording the on-chain HTLC lock tx hash to advance settlement, with DVP guarantee. Differentiates from siblings like refund_htlc and withdraw_htlc by focusing on the lock step.

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

Usage Guidelines5/5

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

Explicit USE WHEN and DO NOT USE WHEN conditions, specifying the prerequisite (trade accepted, lock tx broadcast). Provides clear context for correct invocation.

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

create_rfqA

Trustless price discovery for OTC trades — sealed-bid auction with zero information leakage, no front-running, no MEV. Non-custodial, cross-chain (ETH/BTC/SUI). Agent-friendly: works with any MCP runtime.

Create a Request for Quote (RFQ) for an OTC swap — broadcast to market makers for sealed-bid quotes.

USE WHEN: user wants competitive quotes (not AMM curve fill) for size ≥ $10k, cross-chain swaps, privacy-sensitive orders, or expressed a "negotiate" / "best execution" / "large block" / "institutional" intent. DO NOT USE WHEN: sub-second execution is required, or pair is a long-tail memecoin with no market-maker coverage (prefer DEX aggregator).

═══ SUPPORTED CHAIN-QUALIFIED PAIRS ═══ ETH/sepolia, ETH/ethereum, BTC/bitcoin-signet, BTC/bitcoin, USDC/sepolia, USDC/ethereum, USDT/ethereum, WBTC/ethereum, WETH/ethereum, SUI/sui, SUI/sui-testnet. Cross-chain RFQs (e.g. SUI/sui ↔ ETH/sepolia) are first-class — set baseChain and quoteChain explicitly so the backend can disambiguate same-symbol-different-chain pairs.

═══ INTENT → PARAMS MAPPING ═══ Translate the user free-text intent into params using these rules. The user will rarely give a structured form; you are the compiler.

side: • "sell X / swap X for Y / exchange X to Y / liquidate X / convert X to Y / cash out X" → side=SELL, baseToken=X, quoteToken=Y • "buy X with Y / acquire X / pay Y for X / get X using Y" → side=BUY, baseToken=X, quoteToken=Y • Turkish: "sat / çıkar / boşalt" → SELL, "al / topla" → BUY, "X karşılığı Y" → SELL with X=base.

baseChain / quoteChain (CHAIN INFERENCE): • If the user names the chain explicitly ("Sepolia", "mainnet", "Sui testnet", "signet"), use it. • Otherwise apply per-token mainnet defaults: ETH/USDC/USDT/WBTC/WETH → "ethereum"; BTC → "bitcoin"; SUI → "sui". • If the user says "test" / "testnet" / "demo" / "test mode" / "sınama" globally, switch every leg to its testnet variant: ETH→sepolia, BTC→bitcoin-signet, SUI→sui-testnet, USDC→sepolia. • Cross-environment is allowed and common — if only ONE leg is qualified with a testnet hint (e.g. "sell SUI for Sepolia ETH"), keep the other leg on its mainnet default. Do NOT silently testnet-ify the unqualified leg. • If the chain is genuinely ambiguous after all rules (e.g. "sell ETH for USDC" — both could be mainnet or both Sepolia depending on user intent), ASK before calling. Do not gamble on real funds.

amount: • Pass the raw decimal string the user typed ("0.1", "1.5", "10"). Do NOT pre-convert to wei / satoshis / smallest unit — the backend handles decimals via the token registry. • If the user gives a USD-denominated value ("worth $10k of SUI"), do NOT call the tool — ask for the base-token amount or compute and confirm before submitting.

expiresIn (seconds): • Default 300 (5 min) when unspecified. • "Quick / urgent / hızlı / acele" → 60–120. • "Leave open / take your time / uzun süre" → 600–1800. • Hard cap 86400 (24 h).

isBlind (Ghost Auction mode): • Default false. Zero slippage: quote equals fill, regardless of mode. • Set true on intent words: "ghost", "blind", "anonymous", "hide identity", "private auction", "gizli", "kimliğimi gizle".

═══ REQUIRED BEFORE CALLING ═══

  1. RESTATE the resolved deal in plain language back to the user, naming the chain on every leg ("SELL 0.1 SUI on Sui mainnet for ETH on Sepolia, public auction, expires in 5 min — confirm?"). Real funds. Do NOT submit on first inference unless the user has already explicitly accepted the structured form.

  2. If you cannot resolve a leg's chain confidently, ASK ("Ethereum mainnet ETH or Sepolia testnet ETH?"). Never silently default when the user phrasing is ambiguous on chain.

  3. If the user names a token outside the supported list, do NOT call this tool — explain and offer the closest supported pair.

═══ EXAMPLES ═══ User: "Hashlock'ta 0.1 SUI'mi Sepolia ETH'e karşı sat, 5 dakika" → { side: "SELL", baseToken: "SUI", baseChain: "sui", quoteToken: "ETH", quoteChain: "sepolia", amount: "0.1", expiresIn: 300, isBlind: false }

User: "sell 2 ETH for USDC, ghost auction" → { side: "SELL", baseToken: "ETH", baseChain: "ethereum", quoteToken: "USDC", quoteChain: "ethereum", amount: "2", isBlind: true }

User: "buy 0.05 BTC with USDT, take your time" → { side: "BUY", baseToken: "BTC", baseChain: "bitcoin", quoteToken: "USDT", quoteChain: "ethereum", amount: "0.05", expiresIn: 1200 }

User: "test mode — swap 1 SUI to ETH" → { side: "SELL", baseToken: "SUI", baseChain: "sui-testnet", quoteToken: "ETH", quoteChain: "sepolia", amount: "1" }

ParametersJSON Schema
NameRequiredDescriptionDefault
baseTokenYesBase asset symbol from the supported list (ETH, BTC, SUI, USDC, USDT, WBTC, WETH). Case-insensitive but uppercase preferred.
baseChainNoChain the base token settles on. Inference defaults: ETH/USDC/USDT/WBTC/WETH→"ethereum", BTC→"bitcoin", SUI→"sui". Override to testnet ONLY on explicit user mention ("sepolia", "signet", "testnet", "test", "sınama"). Required for SUI legs (no legacy fallback).
quoteTokenYesQuote asset symbol from the supported list. Same rules as baseToken.
quoteChainNoChain the quote token settles on. Same inference rules as baseChain. Cross-environment pairs are allowed (e.g. baseChain="sui" + quoteChain="sepolia").
sideYesBUY = user wants to acquire baseToken; SELL = user wants to dispose of baseToken. Map "sell/swap/exchange/liquidate/convert/sat" → SELL, "buy/acquire/al" → BUY.
amountYesAmount of base token as a raw decimal string ("0.1", "1.5", "10"). Do NOT convert to wei/satoshis. Reject USD-denominated values — ask user for base-token amount instead.
expiresInNoRFQ expiration in seconds. Default 300 (5 min). "Urgent" → 60-120. "Take your time" → 600-1800. Hard cap 86400 (24 h).
isBlindNoGhost Auction mode — hides requester identity from bidders and losing counterparties. Default false. Set true on intent words: "ghost", "blind", "anonymous", "hide identity", "gizli". External brand: "Ghost Auction"; internal name retained for API/DB schema stability.
client_request_idNoIdempotency key. Retrying the SAME write with the SAME id within this MCP session returns the first result instead of triggering a second on-chain/backend side effect. Best-effort: not durable across MCP restarts.

TDQS

A4.8/5.0
Behavior5/5

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

With no annotations provided, the description fully discloses behavioral aspects: sealed-bid auction, non-custodial nature, cross-chain support, zero slippage, and pre-call steps. It also covers idempotency and the requirement to confirm before calling, ensuring the agent understands the tool's behavior comprehensively.

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 well-structured with clear headings, examples, and logical flow. It is detailed but every section adds essential information for proper tool usage. The front-loading of the core purpose and the use of tables and examples make it efficient for an AI agent to parse.

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

Completeness3/5

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

Despite the detailed description, it lacks an explanation of the tool's return value. There is no output schema, and the description does not mention what the response contains (e.g., RFQ ID, status). For a complex tool with no output schema, this omission creates a completeness gap, though the rest of the context is thorough.

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

Parameters5/5

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

The description adds immense value beyond the input schema, with detailed intent mapping, chain inference, language-specific instructions, handling of edge cases like USD amounts, and explanations for each parameter. This helps the agent correctly populate parameters even from ambiguous user input.

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 clearly states the tool's purpose: creating an RFQ for OTC swaps. It specifies the type of auction (sealed-bid), distinguishes from siblings like swap_execute, and provides explicit use and non-use cases, making the purpose unambiguous.

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

Usage Guidelines5/5

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

The description provides comprehensive usage guidelines, including explicit 'USE WHEN' and 'DO NOT USE WHEN' sections, alternatives like DEX aggregator, and detailed intent-to-parameter mapping with language support and chain inference rules. It also instructs when to ask for clarification, ensuring proper tool selection.

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

get_htlcA

Real-time trade observability — per-leg HTLC settlement state for a trade: which legs are locked, on which chain, with what timelock, and whether the preimage has been revealed. Read-only, safe to call at any time.

Returns an ARRAY of HTLC legs (one entry per locked leg, typically the initiator leg and the counterparty leg). An empty array means no HTLC has been recorded for this tradeId yet (or the tradeId does not exist) — treat empty as "nothing locked", not an error.

USE WHEN: showing trade/settlement status to the user, deciding the next settlement action (lock / claim / refund), polling for the counterparty leg, or rebuilding state after losing context. DO NOT USE WHEN: you need RFQ/quote status (this is settlement-leg state only) — use list_my_trades or list_open_rfqs instead.

INTERPRETING THE RESULT (per leg): role = INITIATOR | COUNTERPARTY; status = leg lifecycle; chainType = evm | bitcoin | sui; timelock = unix expiry of that leg; preimage non-null on a claimed initiator leg. Both legs ACTIVE = swap can complete (claim path). Initiator leg past timelock with counterparty leg absent = refund path.

ParametersJSON Schema
NameRequiredDescriptionDefault
tradeIdYesTrade ID to query HTLC legs for. An unknown ID returns an empty array, not an error.

TDQS

A4.6/5.0
Behavior5/5

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

Discloses read-only nature and safety to call anytime. Explains empty array behavior for unknown tradeId (not an error), and details the structure and interpretation of the result array. Since no annotations exist, the description carries the full burden and excels.

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?

Well-structured into sections (purpose, returns, usage, interpretation). Some verbosity in the interpretation section, but every sentence adds value. Front-loaded key info effectively.

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?

Highly complete: covers purpose, return format, edge cases, interpretation per leg, and usage guidance. Despite no output schema, the description compensates thoroughly for a one-parameter query tool.

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% with a clear description for tradeId. The description repeats the empty-array behavior already in the schema, adding no new parameter-level meaning. Thus baseline 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?

Clearly specifies 'Real-time trade observability — per-leg HTLC settlement state for a trade' with specific details on what is returned. Distinguishes from sibling tools like list_my_trades and list_open_rfqs by stating it covers settlement-leg state only.

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

Usage Guidelines5/5

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

Provides explicit 'USE WHEN' scenarios (showing trade status, deciding next action, polling) and a 'DO NOT USE WHEN' section naming alternative tools, guiding appropriate invocation.

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

list_my_tradesA

List the caller's trades (active + historical). Read-only. Primary tool for rebuilding state after losing conversation context.

USE WHEN: an agent restarted/lost context and must resync in-flight settlements, or showing the user their trade history. DO NOT USE WHEN: you need open market demand (use list_open_rfqs) or per-leg HTLC detail for one trade (use get_htlc).

Optional status filter narrows the page. For settlement-leg detail on a specific trade, follow up with get_htlc(tradeId).

ParametersJSON Schema
NameRequiredDescriptionDefault
statusNoOptional trade-status filter (e.g. ACTIVE, COMPLETED). Omit for all.
pageNo1-based page number. Default 1.
pageSizeNoPage size, 1-100. Default 20.

TDQS

A4/5.0
Behavior3/5

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

Annotations are absent, so the description must cover behavioral traits. It only states 'Read-only' and 'list the caller's trades.' No mention of output ordering, pagination behavior beyond schema, rate limits, or authorization needs. For a list operation, more detail on what to expect would be helpful.

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?

The description is concise and front-loaded with the core purpose in the first sentence. It then provides use-case guidance, exclusions, and a follow-up hint. Could be slightly more structured, but every sentence serves a clear purpose.

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

Completeness3/5

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

Given no output schema, the description could explain what fields the returned trades contain or default sorting. It mentions a follow-up tool (get_htlc) but lacks details on output format or behavior when no trades exist. Still, it covers usage context and alternatives well.

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?

Input schema has full description coverage (100%), so baseline is 3. The description adds 'Optional status filter narrows the page,' which restates what the schema already says about the status parameter. No additional meaning is provided for page or pageSize beyond schema descriptions.

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 clearly states 'List the caller's trades (active + historical). Read-only.' It identifies the specific resource (caller's trades) and scope (active+historical). It explicitly distinguishes from sibling tools like list_open_rfqs and get_htlc.

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

Usage Guidelines5/5

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

Provides explicit when-to-use scenarios: 'when an agent restarted/lost context and must resync in-flight settlements, or showing the user their trade history.' Also gives clear when-not-to-use: 'DO NOT USE WHEN: you need open market demand (use list_open_rfqs) or per-leg HTLC detail for one trade (use get_htlc).' Includes follow-up guidance.

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

list_open_rfqsA

List currently open (ACTIVE) RFQs awaiting market-maker quotes. Read-only.

USE WHEN: acting as a market-maker agent deciding what to quote on, or showing the user live demand. DO NOT USE WHEN: you want your own trade history (use list_my_trades).

Returns a page of RFQs (id, baseToken, quoteToken, side, amount, isBlind, status, expiresAt). To quote, call respond_rfq with the rfqId.

ParametersJSON Schema
NameRequiredDescriptionDefault
pageNo1-based page number. Default 1.
pageSizeNoPage size, 1-100. Default 20.

TDQS

A4.5/5.0
Behavior4/5

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

No annotations exist, so description carries full burden. Declares 'Read-only', describes return fields, and mentions pagination. Does not detail rate limits or authentication, but is sufficient for typical use.

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?

Description is only 3 sentences, front-loaded with the core purpose. Every sentence provides value without redundancy.

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 names the return fields and links to the next logical action (respond_rfq). Pagination is explained, and the tool's role in the workflow is clear.

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% with well-described parameters (page and pageSize). Description does not add additional meaning beyond the schema, so 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?

Clearly states 'List currently open (ACTIVE) RFQs' with specific verb and resource. Distinguishes from siblings like list_my_trades and respond_rfq by mentioning when each should be used.

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

Usage Guidelines5/5

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

Explicitly provides use cases: 'USE WHEN: acting as a market-maker agent deciding what to quote on... DO NOT USE WHEN: you want your own trade history (use list_my_trades).' Also directs to respond_rfq for quoting.

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

list_supported_pairsA

List the chain-qualified token pairs Hashlock supports for RFQ/swap. Read-only, no auth side effects.

USE WHEN: before create_rfq if unsure a token/chain is supported, or to show the user available markets instead of guessing. DO NOT USE WHEN: you already know the pair is supported — this is discovery, not a precondition.

Each entry is SYMBOL/chain. Same symbol on different chains (e.g. SUI/sui vs SUI/sui-testnet) are distinct markets — pass baseChain/quoteChain explicitly to create_rfq.

ParametersJSON Schema
NameRequiredDescriptionDefault

No parameters

TDQS

A4.6/5.0
Behavior4/5

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

Discloses read-only nature and no auth side effects. Explains that same symbol on different chains are distinct markets, which is a behavioral trait beyond basic description. No rate limits or pagination mentioned, but acceptable for a simple list with no parameters.

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 paragraphs with clear front-loaded first sentence. Each sentence adds value, though could be slightly more concise by merging some lines. Overall well-structured.

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?

Complete context for a parameterless list tool: explains entry format (SYMBOL/chain), usage hints, and distinctions between chains. No output schema needed as purpose is clear.

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?

No parameters in schema, so description does not need to add parameter info. Schema coverage is 100% (no params). Baseline 4 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?

Description clearly states the tool lists chain-qualified token pairs supported for RFQ/swap. The use of specific verb 'list' and resource 'token pairs' sets a precise scope, distinguishing it from siblings like create_rfq or swap_quote.

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

Usage Guidelines5/5

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

Explicitly provides when to use ('before create_rfq if unsure a token/chain is supported', 'to show available markets') and when not to use ('if already know the pair is supported'), including the rationale that this is for discovery, not a precondition.

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

refund_htlcA

Trustless unwind — recover locked funds after the HTLC timelock expires. Non-custodial refund guarantee: if the swap does not complete, the original sender reclaims their asset with zero counterparty risk.

USE WHEN: the timelock deadline has passed AND the counterparty never locked their side (or the swap otherwise failed to complete). DO NOT USE WHEN: counterparty HAS locked and the swap can still complete — use withdraw_htlc instead. Only the original lock sender can call refund, and only after the deadline.

PARAM NOTES: txHash is the on-chain refund tx hash (0x-prefixed). No preimage needed — expiry alone unlocks the refund path. Set chainType to "bitcoin" or "sui" for non-EVM legs.

ParametersJSON Schema
NameRequiredDescriptionDefault
tradeIdYesTrade ID
txHashYesOn-chain refund transaction hash (0x-prefixed)
chainTypeNoChain type: evm, bitcoin, or sui
client_request_idNoIdempotency key. Retrying the SAME write with the SAME id within this MCP session returns the first result instead of triggering a second on-chain/backend side effect. Best-effort: not durable across MCP restarts.

TDQS

A4.6/5.0
Behavior4/5

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

Without annotations, the description carries full behavioral burden. It explains the refund mechanism (non-custodial, trustless, no preimage needed) and conditions. However, it omits details on idempotency or success/failure behavior beyond the parameter note for client_request_id.

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?

Description is well-structured into a title, usage conditions, parameter notes. Every sentence adds value, no redundancy. Appropriate length for the tool's complexity.

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?

Given no output schema and moderate parameter count, the description covers usage context, parameter semantics, and behavioral intent. It lacks error scenarios or return value details, but is sufficient for an agent to invoke correctly in the stated conditions.

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% (baseline 3). Description adds value by clarifying that 'txHash' is on-chain 0x-prefixed and that 'chainType' should be 'bitcoin' or 'sui' for non-EVM legs, which is not obvious from the schema alone. Also explains 'client_request_id' as an idempotency key.

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 clearly states the tool's purpose: 'Trustless unwind — recover locked funds after the HTLC timelock expires.' It distinguishes from sibling 'withdraw_htlc' by specifying when NOT to use it, providing a specific verb-resource pair and scope.

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

Usage Guidelines5/5

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

Explicit 'USE WHEN' and 'DO NOT USE WHEN' sections with concrete conditions (timelock deadline passed, counterparty didn't lock) and an alternative tool named (withdraw_htlc). Also notes that only the original lock sender can call refund, and only after deadline.

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

respond_rfqA

Market-maker tool — submit a sealed-bid price quote to compete on an open RFQ. Quotes are private: other makers cannot see your price, and losing bids are never revealed. No funds are locked until the requester accepts a quote.

USE WHEN: the MCP client is acting as a market maker and has decided to quote on a specific open RFQ (obtained via list_open_rfqs). DO NOT USE WHEN: acting as an end-user buyer or seller who wants to receive quotes — use create_rfq instead. This is the market-maker side only; sealed bids, not open negotiation.

PARAM NOTES: price is per unit of base token in quote-token terms (e.g. "3450.00" for ETH priced in USDT). amount is base-token amount offered. No funds are locked at quote time — settlement only begins when the requester accepts.

ParametersJSON Schema
NameRequiredDescriptionDefault
rfqIdYesID of the RFQ to respond to
priceYesPrice per unit of base token in quote token terms (e.g., "3450.00")
amountYesAmount of base token to offer
expiresInNoQuote expiration in seconds
client_request_idNoIdempotency key. Retrying the SAME write with the SAME id within this MCP session returns the first result instead of triggering a second on-chain/backend side effect. Best-effort: not durable across MCP restarts.

TDQS

A4.9/5.0
Behavior5/5

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

Discloses sealed-bid privacy, no funds locked until acceptance, losing bids not revealed, and idempotency key behavior. No annotations provided, so description fully covers safety and behavior.

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?

Concise, well-organized with USE WHEN, DO NOT USE, PARAM NOTES sections. No redundant information, every sentence adds value.

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?

For a tool with 5 parameters and no output schema, the description covers purpose, usage, parameter details, and behavioral notes comprehensively. No obvious gaps.

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%, baseline 3. Description adds clarifying context: price format with example, amount as base token, and funds-lock semantics for idempotency key. Exceeds baseline.

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?

Clearly states it is a market-maker tool for submitting sealed-bid price quotes on open RFQs. Differentiates from sibling tools like create_rfq and list_open_rfqs.

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

Usage Guidelines5/5

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

Explicit USE WHEN and DO NOT USE conditions, including specific alternatives (create_rfq). Guides agent on correct invocation context.

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

swap_cancelA

Abort an open swap before it executes (cancels the underlying RFQ). No funds were locked. Use when the limit never meets, the user changed their mind, or to clean up a stale swap_handle.

USE WHEN: backing out of a swap_quote that has not been executed. DO NOT USE WHEN: the swap already executed (a trade exists) — settlement is governed by the HTLC timelock, not this tool.

PARAM NOTES: idempotent within a session via client_request_id.

ParametersJSON Schema
NameRequiredDescriptionDefault
swap_handleYesThe swap_handle (RFQ id) to cancel.
client_request_idNoIdempotency key. Best-effort within this session.

TDQS

A4.9/5.0
Behavior5/5

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

Despite no annotations, the description discloses key behaviors: no funds locked, idempotency via client_request_id, and that settlement for executed swaps is governed by HTLC timelock. No contradictory information.

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 concise, front-loaded with the main action, and uses bullet-style headers ('USE WHEN', 'DO NOT USE WHEN', 'PARAM NOTES') for clarity. Every sentence adds value with no redundancy.

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 simplicity and lack of output schema, the description covers all necessary aspects: purpose, usage conditions, parameter notes, and idempotency. No gaps are apparent.

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 description adds only incremental value by explaining swap_handle as 'RFQ id' and client_request_id as 'Idempotency key. Best-effort within this session.' This is helpful but not essential.

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 uses a specific verb ('Abort') and resource ('open swap'), clearly distinguishing from sibling tools like swap_execute or swap_quote. It also clarifies no funds are locked.

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

Usage Guidelines5/5

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

Explicitly states when to use (backing out of unexecuted swap_quote) and when not to use (swap already executed), with examples like limit not met or user changed mind. Provides clear exclusion criteria.

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

swap_executeA

Accept the winning sealed bid for a swap and create the trade. Real funds. Provide EITHER limit_price (auto-takes the best bid only if it meets your bound) OR quote_id (the exact bid you saw via swap_status). With neither, this refuses (CONFIRMATION_REQUIRED) rather than guess — restate the price to the user first.

USE WHEN: a swap has an acceptable bid and the user confirmed. DO NOT USE WHEN: you have not surfaced the price to the user, or you want maker-side quoting (use respond_rfq).

PARAM NOTES: limit_price is the sealed reservation (SELL=floor, BUY=ceiling) and must be re-supplied here — it is deliberately never stored. WARNING: accepted_amount may EXCEED your requested amount if a maker quoted a larger size (full-fill v1 accepts a bid whose amount covers the request) — always reconcile accepted_amount against what you asked before settling on-chain. On success returns trade_id; settle on-chain next via create_htlc. This does NOT lock funds itself (non-custodial).

ParametersJSON Schema
NameRequiredDescriptionDefault
swap_handleYesThe swap_handle (RFQ id) from swap_quote.
limit_priceNoSealed reservation. SELL=floor, BUY=ceiling. Re-supply it here; never persisted.
quote_idNoExact bid id from swap_status best_bid.quote_id (explicit-confirm path).
client_request_idNoIdempotency key. Same id within this session returns the first result instead of accepting twice. Best-effort.

TDQS

A4.9/5.0
Behavior5/5

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

With no annotations, the description fully discloses behavioral traits: real funds, non-custodial (doesn't lock funds), acceptance behavior with missing parameters (CONFIRMATION_REQUIRED), warning about accepted_amount exceeding requested amount, and fact that limit_price is re-supplied and not stored.

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?

Description is well-structured with sections (description, use when, param notes, warnings) and front-loaded with the core action. Though slightly long, each sentence adds necessary value for a real-funds tool.

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?

Despite no output schema, the description covers return value (trade_id) and next step (create_htlc). It also addresses edge cases (missing parameters, size exceeding request) and constraints (non-custodial). Fully sufficient for an agent to use correctly.

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

Parameters5/5

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

Schema has 100% coverage with descriptions. The description adds significant meaning: limit_price is sealed reservation and must be re-supplied, quote_id is exact bid from swap_status, client_request_id is idempotency key. This goes beyond the schema's basic descriptions.

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?

Clearly states it accepts the winning sealed bid and creates a trade, differentiating from sibling tools like respond_rfq. The verb 'accept' and resource 'swap' are specific, and the description distinguishes from maker-side quoting.

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

Usage Guidelines5/5

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

Explicitly provides USE WHEN (swap has acceptable bid and user confirmed) and DO NOT USE WHEN (price not surfaced or want maker-side quoting), with alternative tool named (respond_rfq). This gives clear decision criteria.

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

swap_quoteA

One-call OTC swap intake for agents — opens a sealed-bid Ghost Auction under the hood and waits briefly for the first private market-maker bids, then hands back a swap_handle + the best bid so far. Async by design: there is NO public synchronous price (that is the privacy guarantee). Zero slippage: the bid you execute is the fill.

USE WHEN: an agent/user wants to "just swap X for Y" and have the facade manage quote collection + best-bid selection + a price guard. Privacy-sensitive or large flow. DO NOT USE WHEN: the caller wants explicit market-maker-aware RFQ control and will pick/accept quotes itself — use create_rfq. Sub-second DEX fills — use a DEX aggregator.

PARAM NOTES: limit_price is your sealed reservation — for SELL it is a FLOOR (min you will accept), for BUY a CEILING (max you will pay), per unit of base in quote-token terms. It is NEVER sent to makers. private defaults true (Ghost Auction ON — hides your identity from bidders); set false for an open auction. After this returns, call swap_execute (with the same limit_price, or best_bid.quote_id) to take it, swap_status to let competition build, or swap_cancel to abort. Real funds: restate the resolved deal to the user before executing.

ParametersJSON Schema
NameRequiredDescriptionDefault
sideYesSELL = dispose of baseToken; BUY = acquire baseToken.
baseTokenYesBase asset symbol (see list_supported_pairs).
baseChainNoChain the base token settles on.
quoteTokenYesQuote asset symbol.
quoteChainNoChain the quote token settles on.
amountYesBase-token amount as a raw decimal string ("0.1", "2"). Do NOT convert to wei/satoshis.
limit_priceNoSealed reservation. SELL=floor, BUY=ceiling, per unit of base in quote terms. Never sent to makers.
privateNoGhost Auction (hide requester identity). Default true. Set false for an open auction.
expiresInNoRFQ lifetime seconds. Default 300. Hard cap 86400.
max_wait_secondsNoHow long swap_quote waits for first bids. Default 20, capped 25.
client_request_idNoIdempotency key. Same id within this MCP session returns the first result instead of opening a second RFQ. Best-effort: not durable across restarts.

TDQS

A4.8/5.0
Behavior5/5

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

Describes async nature, no synchronous price, zero slippage, ghost auction mechanism, limit_price secrecy, parameter defaults, and idempotency. No annotations provided, so description carries full burden and does so comprehensively.

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?

Well-structured with front-loaded summary, usage guidelines, parameter notes, and follow-up calls. Slightly lengthy but every sentence adds value; could be tightened slightly but overall effective.

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?

For a complex tool with 11 parameters, no output schema, and no annotations, the description covers return value, async behavior, privacy, parameter details, and post-call actions. Complete enough for proper use.

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%, but description adds extra context in PARAM NOTES: limit_price as floor/ceiling, private default meaning, client_request_id best-effort idempotency, max_wait_seconds and expiresIn caps. This adds value beyond schema.

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 clearly states the tool as a one-call OTC swap intake that opens a sealed-bid Ghost Auction, returning a swap_handle and best bid. It distinguishes from sibling tools like create_rfq and DEX aggregators, providing specific verb and resource.

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

Usage Guidelines5/5

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

Explicitly provides USE WHEN and DO NOT USE conditions, naming alternatives (create_rfq, DEX aggregator) and contexts (privacy-sensitive, large flow). Also maps follow-up tools (swap_execute, swap_status, swap_cancel).

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

swap_statusA

Re-poll an open swap by its swap_handle — returns the current best sealed bid + how many bids are in. Read-only, stateless: the primary way to resume a swap after losing context (only the swap_handle is needed).

USE WHEN: letting maker competition build before executing, or rebuilding an in-flight swap after a context reset. DO NOT USE WHEN: you need settlement-leg detail (use get_htlc) or your trade history (use list_my_trades).

PARAM NOTES: returns best_bid (or null), bids_seen, still_open and rfq_status. When best_bid is present, swap_execute with the same limit_price (or best_bid.quote_id) to take it.

ParametersJSON Schema
NameRequiredDescriptionDefault
swap_handleYesThe swap_handle returned by swap_quote (the RFQ id).
max_wait_secondsNoBounded wait for new bids this call. Default 15, capped 25.

TDQS

A4.8/5.0
Behavior5/5

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

Despite no annotations, the description explicitly states read-only and stateless, describes output fields (best_bid, bids_seen, still_open, rfq_status), and explains the follow-up action with swap_execute, providing comprehensive 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?

Well-organized with distinct sections; each sentence adds necessary information without redundancy. The description is compact and front-loaded.

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?

Given no output schema, the description covers purpose, usage, parameters, output, and follow-up actions adequately. It could mention error handling but is complete for its complexity.

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% with descriptions for both parameters. The description adds value by explaining response fields and how to use them with swap_execute, enhancing semantics beyond the schema.

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 clearly states the tool re-polls an open swap using swap_handle, returning the current best sealed bid and bid count. It distinguishes from siblings by referencing get_htlc and list_my_trades for different needs, making the purpose unambiguous.

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

Usage Guidelines5/5

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

Explicit 'USE WHEN' and 'DO NOT USE WHEN' sections provide specific scenarios and alternative tool names (get_htlc, list_my_trades), offering clear decision guidance.

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

withdraw_htlcA

Atomic claim — reveals the 32-byte preimage to unlock both legs of the swap simultaneously. Trustless cross-chain finality: no intermediary holds funds at any point.

USE WHEN: counterparty has confirmed their lock on-chain and the user wants to claim their side of the swap. DO NOT USE WHEN: counterparty lock is not yet confirmed on-chain, OR the timelock has already expired — use refund_htlc instead.

PARAM NOTES: preimage must be 0x-prefixed 32-byte hex. Revealing the preimage is what makes the swap atomic — it simultaneously unlocks the counterparty leg. Set chainType to "bitcoin" or "sui" for non-EVM legs.

ParametersJSON Schema
NameRequiredDescriptionDefault
tradeIdYesTrade ID
txHashYesOn-chain claim transaction hash (0x-prefixed)
preimageYesThe 32-byte secret preimage (0x-prefixed hex)
chainTypeNoChain type: evm, bitcoin, or sui
client_request_idNoIdempotency key. Retrying the SAME write with the SAME id within this MCP session returns the first result instead of triggering a second on-chain/backend side effect. Best-effort: not durable across MCP restarts.

TDQS

A4.6/5.0
Behavior4/5

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

Reveals that revealing the preimage makes the swap atomic and simultaneously unlocks the counterparty leg. Lacks mention of irrevocability or on-chain txHash requirement, but sufficient for the operation.

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?

Compact description with clear structure: one-line summary, use/don't-use section, and param notes. Every sentence provides necessary information.

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?

Covers purpose, usage, and key parameters adequately. No output schema, but for a claim operation, missing return value info is acceptable given the straightforward nature.

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. Adds value by specifying preimage format (0x-prefixed 32-byte hex) and chainType for non-EVM legs beyond schema descriptions.

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?

Clearly describes the tool as an atomic claim that reveals the preimage to unlock both legs. Distinguishes from sibling 'refund_htlc' by mentioning timelock expiry.

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

Usage Guidelines5/5

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

Explicitly states when to use and when not to use, including a specific alternative tool (refund_htlc) for expired timelocks.

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

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections. Dates show when Glama detected each change.

  1. 13 tool updatesv0.4.0
    • First observedcreate_htlc
    • First observedcreate_rfq
    • First observedget_htlc
    • First observedlist_my_trades
    • First observedlist_open_rfqs
    • First observedlist_supported_pairs
    • First observedrefund_htlc
    • First observedrespond_rfq
    • First observedswap_cancel
    • First observedswap_execute
    • First observedswap_quote
    • First observedswap_status
    • First observedwithdraw_htlc

TDQS

A4.4/5.0
Disambiguation4/5

Tools are generally distinct across settlement (HTLC) and RFQ/swap domains. However, create_rfq and swap_quote have overlapping functionality, with swap_quote acting as a higher-level wrapper, which could cause confusion about which to use. Otherwise, well-separated.

Naming Consistency3/5

Most tools follow verb_noun (create_htlc, list_my_trades) but swap tools use noun_verb (swap_cancel, swap_execute), creating inconsistency. The pattern is mostly predictable, but the mix reduces coherence.

Tool Count5/5

13 tools cover the full lifecycle of atomic swaps and OTC trading without being excessive. Each tool has a clear role, and the count is well-scoped for the server's purpose.

Completeness5/5

The tool surface covers the complete workflow: RFQ creation, quoting, execution, cancellation, HTLC locking, status polling, refund, and withdrawal. No obvious gaps for the core domain.

Maintenance

ActivityMaintained
ResponsivenessUnresponsive

Resources

Unclaimed servers have limited discoverability.

Looking for Admin?

If you are the server author, to access and configure the admin panel.

Related MCP Connectors

Related MCP Servers

  • A
    license
    A
    quality
    D
    maintenance
    Hashlock Markets (hashlock.markets) — sealed-bid intent-based crypto trading protocol with HTLC atomic settlement. AI agents can create, commit, and validate trading intents on Ethereum, Bitcoin, and Sui. Canonical npm package: @hashlock-tech/mcp. Not the cryptographic hashlock primitive, not Hashlock Pty Ltd (hashlock.com).
    5
    21
    MIT
  • A
    license
    A
    quality
    F
    maintenance
    MCP server for DeFi execution — lets AI agents swap, provide liquidity, lend, bridge, and run yield strategies across 22 chains in a single transaction. 7 tools for token discovery, portfolio analysis, quoting, and execution via the Haiku API.
    7
    83
    2
    MIT
  • F
    license
    Not graded
    quality
    B
    maintenance
    Settlement rails for AI labor — USDC escrow on Base Mainnet, 1% protocol fee, designed for autonomous agents. 10 MCP tools covering the full escrow lifecycle: * Quoting calldata for create-intent, submit-proof, release-funds (broadcast gated) * Single-call x402 payment binding (replaces the 5-step x402 dance with one HMAC-signed POST) * Server-side reputation from on-chain event scan * Li
    -

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/Hashlock-Tech/hashlock-mcp'

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