mcpField
G
grimoire-across

grimoire-across

github.com/franalgabaOther662 installsUpdated 25w ago
Repository

About grimoire-across

grimoire-across is a skill for querying Across Protocol bridge data as input to cross-chain strategies. Its CLI covers quotes, routes, and deposit status, with guidance for quote metrics and Spell constraints.

Key features

  1. 01List supported chains and bridge routes
  2. 02Get quotes, fees, and limits
  3. 03Check deposit status by transaction hash
  4. 04Expose a quote output metric
  5. 05Document Spell bridge constraints

Use cases

  1. 01Compare bridge quotes across chains
  2. 02Check the progress of a cross-chain deposit
  3. 03Set constraints for a Spell bridge action

Install

Copy the command and run it in a terminal.

$npx skills add https://github.com/franalgaba/grimoire --skill grimoire-across

After installing, type/grimoire-acrossin Claude Code to confirm it loaded.

Details

From the project README

Grimoire Across Skill

Use this skill to query Across Protocol bridge data for cross-chain strategy inputs.

Preferred invocations:

  • grimoire venue across ...
  • npx -y @grimoirelabs/cli venue across ... (no-install)
  • bun run packages/cli/src/index.ts venue across ... (repo-local)
  • grimoire-across ... (direct binary from @grimoirelabs/venues)

Recommended preflight:

  • grimoire venue doctor --adapter across --chain 1 --rpc-url <rpc> --json

Commands

  • grimoire venue across info — adapter metadata and supported chains
  • grimoire venue across chains — list supported bridge chains
  • grimoire venue across quote --asset <symbol|address> --from <chainId> --to <chainId> --amount <wei> [--recipient <address>] — get a bridge quote with fees and limits
  • grimoire venue across status --tx-hash <hash> [--api-url <url>] — check deposit status by origin tx hash
  • grimoire venue across routes --asset <symbol> — list available bridge routes for an asset

Examples

grimoire venue across info
grimoire venue across chains
grimoire venue across quote --asset USDC --from 1 --to 8453 --amount 1000000000
grimoire venue across quote --asset WETH --from 42161 --to 1 --amount 500000000000000000
grimoire venue across status --tx-hash 0xabc123...
grimoire venue across routes --asset USDC
grimoire venue across routes --asset WETH

Supported Chains

ChainID
Ethereum1
Optimism10
Polygon137
Base8453
Arbitrum42161

Quote Response

The quote command returns:

  • inputAmount / outputAmount — amounts in smallest unit (wei)
  • estimatedFillTimeSec — expected bridge time
  • isAmountTooLow — whether the amount is below minimum
  • limits.minDeposit / limits.maxDeposit / limits.maxDepositInstant
  • fees.lpFee / fees.relayerGasFee / fees.relayerCapitalFee / fees.totalRelayFee
  • route.spokePoolAddress — spoke pool contract used

Metric Surface (Spell Comparisons)

Across exposes quote_out for bridge output comparisons:

across_out = metric("quote_out", across, USDC, "to_chain=8453,amount=1000000")

Selector fields:

  • required: to_chain
  • optional: amount (defaults to 1 unit of input asset), asset_out (defaults to input asset)

Spell Constraints

When writing bridge actions in .spell files targeting Across, use with clauses:

across.bridge(USDC, params.amount, 8453) with (
  max_slippage=50,
  require_quote=true,
)
ConstraintTypeDescription
max_slippageinteger (bps)Maximum slippage in basis points (converted to min_output)
min_outputinteger (wei)Explicit minimum output amount floor
require_quotebooleanFail if quote fetch fails
require_simulationbooleanFail if simulation unavailable
max_gasinteger (wei)Validate gas estimate against cap

Notes

  • Amounts are always in the token's smallest unit (wei). For USDC (6 decimals): 1000 USDC = 1000000000.
  • The status command queries the Across public API (https://app.across.to/api/deposits/status).
  • Routes are computed from the built-in token registry; use raw addresses for unlisted tokens.
  • Prefer --format json in automation; the CLI defaults to toon format for interactive use.

Comments

Markdown supported