pay-with-any-token

Compare original and translation side by side

🇺🇸

Original

English
🇨🇳

Translation

Chinese

Pay With Tokens

使用代币付费

Use the Tempo CLI to call paid APIs and handle 402 challenges automatically. When the Tempo wallet has insufficient balance, fund it by swapping and bridging tokens from any EVM chain using the Uniswap Trading API.
使用Tempo CLI调用付费API并自动处理402验证请求。当Tempo钱包余额不足时,可通过Uniswap Trading API从任意EVM链兑换并跨链转移代币来为钱包充值。

Tempo CLI Setup

Tempo CLI 安装配置

Run these commands in order. Do not skip steps.
Step 1 — Install:
bash
mkdir -p "$HOME/.local/bin" \
  && curl -fsSL https://tempo.xyz/install -o /tmp/tempo_install.sh \
  && TEMPO_BIN_DIR="$HOME/.local/bin" bash /tmp/tempo_install.sh
Step 2 — Login (requires browser/passkey — prompt user, wait for confirmation):
bash
"$HOME/.local/bin/tempo" wallet login
When run by agents, use a long command timeout (at least 16 minutes).
Step 3 — Confirm readiness:
bash
"$HOME/.local/bin/tempo" wallet -t whoami
Rules: Do not use
sudo
. Use full absolute paths (
$HOME/.local/bin/tempo
) — do not rely on
export PATH
. If
$HOME
does not expand, use the literal absolute path.
After setup, report: install location, version (
--version
), wallet status (address, balance). If balance is 0, direct user to
tempo wallet fund
.
按顺序运行以下命令,请勿跳过步骤。
步骤1 — 安装:
bash
mkdir -p "$HOME/.local/bin" \
  && curl -fsSL https://tempo.xyz/install -o /tmp/tempo_install.sh \
  && TEMPO_BIN_DIR="$HOME/.local/bin" bash /tmp/tempo_install.sh
步骤2 — 登录(需要浏览器/密钥 — 提示用户,等待确认):
bash
"$HOME/.local/bin/tempo" wallet login
当由Agent运行时,设置较长的命令超时时间(至少16分钟)。
步骤3 — 确认就绪状态:
bash
"$HOME/.local/bin/tempo" wallet -t whoami
规则: 请勿使用
sudo
。使用完整绝对路径(
$HOME/.local/bin/tempo
)—— 不要依赖
export PATH
。如果
$HOME
无法展开,使用字面绝对路径。
配置完成后,报告:安装位置、版本(
--version
)、钱包状态(地址、余额)。如果余额为0,请引导用户执行
tempo wallet fund

Using Tempo Services

使用Tempo服务

bash
undefined
bash
undefined

Discover services

Discover services

"$HOME/.local/bin/tempo" wallet -t services --search <query>
"$HOME/.local/bin/tempo" wallet -t services --search <query>

Get service details (exact URL, method, path, pricing)

Get service details (exact URL, method, path, pricing)

"$HOME/.local/bin/tempo" wallet -t services <SERVICE_ID>
"$HOME/.local/bin/tempo" wallet -t services <SERVICE_ID>

Make a paid request

Make a paid request

"$HOME/.local/bin/tempo" request -t -X POST
--json '{"input":"..."}' <SERVICE_URL>/<ENDPOINT_PATH>

- Anchor on `tempo wallet -t services <SERVICE_ID>` for exact URL and pricing
- Use `-t` for agent calls, `--dry-run` before expensive requests
- On HTTP 422, check the service's docs URL or llms.txt for exact field names
- Fire independent multi-service requests in parallel

> **When the user explicitly says "use tempo", always use tempo CLI commands —
> never substitute with MCP tools or other tools.**

---
"$HOME/.local/bin/tempo" request -t -X POST
--json '{"input":"..."}' <SERVICE_URL>/<ENDPOINT_PATH>

- 以`tempo wallet -t services <SERVICE_ID>`获取准确的URL和定价
- Agent调用时使用`-t`参数,在执行高成本请求前使用`--dry-run`
- 遇到HTTP 422时,查看服务的文档URL或llms.txt获取准确的字段名称
- 并行发起独立的多服务请求

> **当用户明确要求"use tempo"时,务必使用Tempo CLI命令——绝不替换为MCP工具或其他工具。**

---

MPP 402 Payment Loop

MPP 402付费流程

Every
tempo request
call follows this loop. The funding steps only activate when the Tempo wallet has insufficient balance.
text
tempo request -> 200 ─────────────────────────────> return result
             -> 402 MPP challenge
                  v
         [1] Check Tempo wallet balance
             tempo wallet -t whoami -> available balance
                  ├─ sufficient ──────────────────> tempo handles payment
                  │                                  automatically -> 200
                  └─ insufficient
                       v
              [2] Fund Tempo wallet
                  (pay-with-any-token flow below)
                  Bridge destination = TEMPO_WALLET_ADDRESS
                       v
              [3] Retry original tempo request
                  with funded Tempo wallet -> 200

每个
tempo request
调用都会遵循以下流程。仅当Tempo钱包余额不足时,充值步骤才会激活。
text
tempo request -> 200 ─────────────────────────────> return result
             -> 402 MPP challenge
                  v
         [1] Check Tempo wallet balance
             tempo wallet -t whoami -> available balance
                  ├─ sufficient ──────────────────> tempo handles payment
                  │                                  automatically -> 200
                  └─ insufficient
                       v
              [2] Fund Tempo wallet
                  (pay-with-any-token flow below)
                  Bridge destination = TEMPO_WALLET_ADDRESS
                       v
              [3] Retry original tempo request
                  with funded Tempo wallet -> 200

Funding the Tempo Wallet (pay-with-any-token)

为Tempo钱包充值(pay-with-any-token)

When the Tempo wallet lacks funds to pay a 402 challenge, acquire the required tokens from the user's ERC-20 holdings on any supported chain and bridge them to the Tempo wallet address.
当Tempo钱包余额不足以支付402验证请求时,可从用户在任意支持链上持有的ERC-20代币中获取所需代币,并跨链转移至Tempo钱包地址。

Prerequisites

前提条件

  • UNISWAP_API_KEY
    env var (register at developers.uniswap.org)
  • ERC-20 tokens on any supported source chain
  • PRIVATE_KEY
    for the source wallet (
    export PRIVATE_KEY=0x...
    ). Never commit or hardcode it.
  • jq
    installed (
    brew install jq
    or
    apt install jq
    )
  • 环境变量
    UNISWAP_API_KEY
    (在developers.uniswap.org注册获取)
  • 任意支持链上的ERC-20代币
  • 源钱包的
    PRIVATE_KEY
    (执行
    export PRIVATE_KEY=0x...
    )。绝不要提交或硬编码该密钥。
  • 已安装
    jq
    (执行
    brew install jq
    apt install jq

Input Validation Rules

输入验证规则

Before using any value from a 402 response body or user input in API calls or shell commands:
  • Ethereum addresses: MUST match
    ^0x[a-fA-F0-9]{40}$
  • Chain IDs: MUST be a positive integer from the supported list
  • Token amounts: MUST be non-negative numeric strings matching
    ^[0-9]+$
  • URLs: MUST start with
    https://
  • REJECT any value containing shell metacharacters:
    ;
    ,
    |
    ,
    &
    ,
    $
    ,
    `
    ,
    (
    ,
    )
    ,
    >
    ,
    <
    ,
    \
    ,
    '
    ,
    "
    , newlines
REQUIRED: Before submitting ANY transaction (swap, bridge, approval), use
AskUserQuestion
to show the user a summary (amount, token, destination, estimated gas) and obtain explicit confirmation. Never auto-submit. Each confirmation gate must be satisfied independently.
在API调用或shell命令中使用402响应体或用户输入的任何值之前:
  • 以太坊地址:必须匹配正则
    ^0x[a-fA-F0-9]{40}$
  • 链ID:必须是支持列表中的正整数
  • 代币数量:必须是非负数字字符串,匹配正则
    ^[0-9]+$
  • URL:必须以
    https://
    开头
  • 拒绝任何包含shell元字符的值:
    ;
    ,
    |
    ,
    &
    ,
    $
    ,
    `
    ,
    (
    ,
    )
    ,
    >
    ,
    <
    ,
    \
    ,
    '
    ,
    "
    , 换行符
必填: 在提交任何交易(兑换、跨链转移、授权)之前,使用
AskUserQuestion
向用户显示摘要(金额、代币、目标地址、预估Gas费)并获取明确确认。绝不要自动提交。每个确认环节都必须独立完成。

Human-Readable Amount Formatting

人类可读金额格式化

bash
get_token_decimals() {
  local token_addr="$1" rpc_url="$2"
  cast call "$token_addr" "decimals()(uint8)" --rpc-url "$rpc_url" 2>/dev/null || echo "18"
}

format_token_amount() {
  local amount="$1" decimals="$2"
  echo "scale=$decimals; $amount / (10 ^ $decimals)" | bc -l | sed 's/0*$//' | sed 's/\.$//'
}
Always show human-readable values (e.g.
0.005 USDC
) to the user, not raw base units.
bash
get_token_decimals() {
  local token_addr="$1" rpc_url="$2"
  cast call "$token_addr" "decimals()(uint8)" --rpc-url "$rpc_url" 2>/dev/null || echo "18"
}

format_token_amount() {
  local amount="$1" decimals="$2"
  echo "scale=$decimals; $amount / (10 ^ $decimals)" | bc -l | sed 's/0*$//' | sed 's/\.$//'
}
始终向用户显示人类可读的值(例如
0.005 USDC
),而非原始基础单位。

Step 1 — Parse the 402 Challenge

步骤1 — 解析402验证请求

Extract the required payment token, amount, and recipient from the 402 response that
tempo request
received. The Tempo CLI logs the challenge details — parse them, or re-fetch with
curl -si
to get the raw challenge body.
For MPP header-based challenges (
WWW-Authenticate: Payment
):
bash
REQUEST_B64=$(echo "$WWW_AUTHENTICATE" | grep -oE 'request="[^"]+"' | sed 's/request="//;s/"$//')
REQUEST_JSON=$(echo "${REQUEST_B64}==" | base64 --decode 2>/dev/null)
REQUIRED_AMOUNT=$(echo "$REQUEST_JSON" | jq -r '.amount')
PAYMENT_TOKEN=$(echo "$REQUEST_JSON" | jq -r '.currency')
RECIPIENT=$(echo "$REQUEST_JSON" | jq -r '.recipient')
TEMPO_CHAIN_ID=$(echo "$REQUEST_JSON" | jq -r '.methodDetails.chainId')
For JSON body challenges (
payment_methods
array):
bash
NUM_METHODS=$(echo "$CHALLENGE_BODY" | jq '.payment_methods | length')
PAYMENT_METHODS=$(echo "$CHALLENGE_BODY" | jq -c '.payment_methods')
RECIPIENT=$(echo "$CHALLENGE_BODY" | jq -r '.payment_methods[0].recipient')
TEMPO_CHAIN_ID=$(echo "$CHALLENGE_BODY" | jq -r '.payment_methods[0].chain_id')
If multiple payment methods are accepted, select the cheapest in Step 2.
The Tempo mainnet chain ID is
4217
. Use as fallback if not in the challenge.
tempo request
收到的402响应中提取所需的支付代币、金额和收款方。Tempo CLI会记录验证请求详情——可解析这些日志,或使用
curl -si
重新获取原始验证请求体。
对于基于MPP头部的验证请求
WWW-Authenticate: Payment
):
bash
REQUEST_B64=$(echo "$WWW_AUTHENTICATE" | grep -oE 'request="[^"]+"' | sed 's/request="//;s/"$//')
REQUEST_JSON=$(echo "${REQUEST_B64}==" | base64 --decode 2>/dev/null)
REQUIRED_AMOUNT=$(echo "$REQUEST_JSON" | jq -r '.amount')
PAYMENT_TOKEN=$(echo "$REQUEST_JSON" | jq -r '.currency')
RECIPIENT=$(echo "$REQUEST_JSON" | jq -r '.recipient')
TEMPO_CHAIN_ID=$(echo "$REQUEST_JSON" | jq -r '.methodDetails.chainId')
对于基于JSON体的验证请求
payment_methods
数组):
bash
NUM_METHODS=$(echo "$CHALLENGE_BODY" | jq '.payment_methods | length')
PAYMENT_METHODS=$(echo "$CHALLENGE_BODY" | jq -c '.payment_methods')
RECIPIENT=$(echo "$CHALLENGE_BODY" | jq -r '.payment_methods[0].recipient')
TEMPO_CHAIN_ID=$(echo "$CHALLENGE_BODY" | jq -r '.payment_methods[0].chain_id')
如果支持多种支付方式,在步骤2中选择成本最低的一种。
Tempo主网链ID为
4217
。如果验证请求中未提供,可作为 fallback 值使用。

Step 2 — Check Source Wallet Balances and Select Payment Method

步骤2 — 检查源钱包余额并选择支付方式

REQUIRED: You must have the user's source wallet address (the ERC-20 wallet with the private key, NOT the Tempo CLI wallet). Use
AskUserQuestion
if not provided. Store as
WALLET_ADDRESS
.
Also capture the Tempo wallet address (the funding destination):
bash
TEMPO_WALLET_ADDRESS=$("$HOME/.local/bin/tempo" wallet -t whoami | grep -oE '0x[a-fA-F0-9]{40}' | head -1)
Check ERC-20 balances on source chains:
bash
undefined
必填: 必须获取用户的源钱包地址(持有私钥的ERC-20钱包,而非Tempo CLI钱包)。如果未提供,使用
AskUserQuestion
获取。将其存储为
WALLET_ADDRESS
同时获取Tempo钱包地址(充值目标地址):
bash
TEMPO_WALLET_ADDRESS=$("$HOME/.local/bin/tempo" wallet -t whoami | grep -oE '0x[a-fA-F0-9]{40}' | head -1)
检查源链上的ERC-20余额:
bash
undefined

USDC on Base

USDC on Base

cast call 0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913
"balanceOf(address)(uint256)" "$WALLET_ADDRESS"
--rpc-url https://mainnet.base.org

**Select the cheapest payment method** if multiple are accepted. Priority:

1. Wallet holds USDC on Base (bridge only, minimal path)
2. Wallet holds ETH on Base or Ethereum (swap to USDC + bridge)
3. Any other liquid ERC-20 (swap + bridge)

```bash
REQUIRED_AMOUNT=$(echo "$PAYMENT_METHODS" | jq -r ".[$SELECTED_INDEX].amount")
PAYMENT_TOKEN=$(echo "$PAYMENT_METHODS" | jq -r ".[$SELECTED_INDEX].token")
cast call 0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913
"balanceOf(address)(uint256)" "$WALLET_ADDRESS"
--rpc-url https://mainnet.base.org

**如果支持多种支付方式,选择成本最低的一种**。优先级:

1. 钱包在Base链上持有USDC(仅跨链转移,路径最短)
2. 钱包在Base或以太坊链上持有ETH(兑换为USDC + 跨链转移)
3. 其他任何流动性ERC-20代币(兑换 + 跨链转移)

```bash
REQUIRED_AMOUNT=$(echo "$PAYMENT_METHODS" | jq -r ".[$SELECTED_INDEX].amount")
PAYMENT_TOKEN=$(echo "$PAYMENT_METHODS" | jq -r ".[$SELECTED_INDEX].token")

Step 3 — Plan the Payment Path

步骤3 — 规划支付路径

text
Source token (Base/Ethereum)
  -> [Phase 4A: Uniswap Trading API swap] -> native USDC (bridge asset)
  -> [Phase 4B: bridge via Trading API]   -> USDC.e on Tempo (to TEMPO_WALLET_ADDRESS)
  -> tempo request retries automatically with funded wallet
Skip Phase 4A if the source token is already USDC on the bridge chain.
text
Source token (Base/Ethereum)
  -> [Phase 4A: Uniswap Trading API swap] -> native USDC (bridge asset)
  -> [Phase 4B: bridge via Trading API]   -> USDC.e on Tempo (to TEMPO_WALLET_ADDRESS)
  -> tempo request retries automatically with funded wallet
跳过Phase 4A如果源代币已经是跨链链上的USDC。

Phase 4A — Swap to USDC on Source Chain (if needed)

Phase 4A — 在源链上兑换为USDC(如需要)

Swap the source token to USDC via the Uniswap Trading API (
EXACT_OUTPUT
).
Detailed steps: Read references/trading-api-flows.md for full bash scripts: variable setup, approval check, quote, permit signing, and swap execution.
Key points:
  • Base URL:
    https://trade-api.gateway.uniswap.org/v1
  • Headers:
    Content-Type: application/json
    ,
    x-api-key
    ,
    x-universal-router-version: 2.0
  • Flow:
    check_approval
    -> quote (
    EXACT_OUTPUT
    ) -> sign
    permitData
    ->
    /swap
    -> broadcast
  • Confirmation gates required before approval tx and before swap broadcast
  • For native ETH: use WETH address as
    TOKEN_IN
    ;
    SWAP_VALUE
    will be non-zero
  • After swap, verify USDC balance before proceeding to Phase 4B
通过Uniswap Trading API(
EXACT_OUTPUT
模式)将源代币兑换为USDC。
详细步骤: 阅读references/trading-api-flows.md获取完整bash脚本:变量配置、授权检查、报价、许可签名和兑换执行。
关键点:
  • 基础URL:
    https://trade-api.gateway.uniswap.org/v1
  • 请求头:
    Content-Type: application/json
    ,
    x-api-key
    ,
    x-universal-router-version: 2.0
  • 流程:
    check_approval
    -> 报价(
    EXACT_OUTPUT
    ) -> 签署
    permitData
    ->
    /swap
    -> 广播交易
  • 在授权交易和兑换广播前需要确认环节
  • 对于原生ETH:使用WETH地址作为
    TOKEN_IN
    SWAP_VALUE
    将非零
  • 兑换完成后,在进入Phase 4B前验证USDC余额

Phase 4B — Bridge to Tempo Wallet

Phase 4B — 跨链转移至Tempo钱包

Bridge USDC from Base to the Tempo CLI wallet address using the Uniswap Trading API (powered by Across Protocol).
CRITICAL: The bridge recipient must be
TEMPO_WALLET_ADDRESS
(from
tempo wallet -t whoami
), NOT
WALLET_ADDRESS
(your source ERC-20 wallet). This funds the Tempo CLI wallet so
tempo request
can retry the payment.
Detailed steps: Read references/trading-api-flows.md for full bash scripts: approval, bridge quote, execution, and arrival polling.
Key points:
  • Route: USDC on Base -> USDC.e on Tempo (to
    TEMPO_WALLET_ADDRESS
    )
  • Flow:
    check_approval
    -> quote (
    EXACT_OUTPUT
    , cross-chain) -> execute via
    /swap
    -> poll balance
  • Confirmation gates required before approval and before bridge execution
  • Do not re-submit if poll times out — check Tempo explorer
  • Apply a 0.5% buffer to account for bridge fees
After the bridge confirms, retry the original
tempo request
— the Tempo CLI will automatically use the newly funded wallet to pay the 402.
Balance buffer: On Tempo,
balanceOf
may report more than is spendable. Apply a 2x buffer when comparing to
REQUIRED_AMOUNT
. If short, swap additional tokens to top up.

使用Uniswap Trading API(由Across Protocol提供支持)将USDC从Base链跨链转移至Tempo CLI钱包地址
关键提示: 跨链转移的收款方必须是
TEMPO_WALLET_ADDRESS
(来自
tempo wallet -t whoami
),而非
WALLET_ADDRESS
(用户的源ERC-20钱包)。这会为Tempo CLI钱包充值,以便
tempo request
可以重试付费。
详细步骤: 阅读references/trading-api-flows.md获取完整bash脚本:授权、跨链报价、执行和到账轮询。
关键点:
  • 路径:Base链上的USDC -> Tempo链上的USDC.e(转至
    TEMPO_WALLET_ADDRESS
  • 流程:
    check_approval
    -> 报价(
    EXACT_OUTPUT
    ,跨链) -> 通过
    /swap
    执行 -> 轮询余额
  • 在授权和跨链执行前需要确认环节
  • 如果轮询超时,不要重新提交——检查Tempo区块浏览器
  • 预留0.5%的缓冲以覆盖跨链费用
跨链转移确认后,重试原始的
tempo request
——Tempo CLI会自动使用新充值的钱包支付402验证请求。
余额缓冲: 在Tempo链上,
balanceOf
返回的余额可能大于可花费的金额。与
REQUIRED_AMOUNT
比较时,应用2倍缓冲。如果余额不足,兑换额外代币进行补充。

x402 Payment Flow

x402付费流程

The x402 protocol uses a different mechanism than MPP — it is not handled by the Tempo CLI. When
PROTOCOL
is
"x402"
(detected by checking
has("x402Version")
in the 402 body), use this flow instead.
The x402
"exact"
scheme uses EIP-3009 (
transferWithAuthorization
) to authorize a one-time token transfer signed off-chain.
Detailed steps: Read references/credential-construction.md for full code: prerequisite checks, nonce generation, EIP-3009 signing, X-PAYMENT payload construction, and retry.
Key points:
  • Detect x402: check
    has("x402Version")
    in 402 body before using Tempo CLI
  • Maps
    X402_NETWORK
    to chain ID and RPC URL (base, ethereum, tempo supported)
  • Checks wallet balance on target chain; runs Phase 4A/4B if insufficient
  • Signs
    TransferWithAuthorization
    typed data using token's own domain
  • value
    in payload must be a string (
    --arg
    , not
    --argjson
    ) for uint256
  • Confirmation gate required before signing
ProtocolVersionHandler
MPPv1Tempo CLI
x402v1Manual (above)

x402协议使用与MPP不同的机制——无法通过Tempo CLI处理。当
PROTOCOL
"x402"
(通过检查402体中是否存在
has("x402Version")
检测)时,使用以下流程替代。
x402的
"exact"
方案使用EIP-3009(
transferWithAuthorization
)来授权一次链下签名的代币转账。
详细步骤: 阅读references/credential-construction.md获取完整代码:前提检查、随机数生成、EIP-3009签名、X-PAYMENT负载构建和重试。
关键点:
  • 检测x402:在使用Tempo CLI前,检查402体中是否存在
    has("x402Version")
  • X402_NETWORK
    映射到链ID和RPC URL(支持Base、Ethereum、Tempo)
  • 检查目标链上的钱包余额;如果不足,执行Phase 4A/4B
  • 使用代币自身的域名签署
    TransferWithAuthorization
    类型数据
  • 负载中的
    value
    必须是字符串(使用
    --arg
    而非
    --argjson
    )以适配uint256类型
  • 签署前需要确认环节
ProtocolVersionHandler
MPPv1Tempo CLI
x402v1Manual (above)

Error Handling

错误处理

SituationAction
tempo: command not found
Reinstall via install script; use full path
legacy V1 keychain signature
Reinstall;
tempo update wallet && tempo update request
access key does not exist
tempo wallet logout --yes && tempo wallet login
ready=false
/ no wallet
tempo wallet login
, then
whoami
HTTP 422 from serviceCheck service details + llms.txt for exact field names
Balance 0 / insufficientTrigger pay-with-any-token funding flow
Service not foundBroaden search query
TimeoutRetry with
-m <seconds>
Challenge body is malformedReport raw body to user; do not proceed
Approval transaction failsSurface error; check gas and allowances
Quote API returns 400Log request/response; check amount formatting
Quote API returns 429Wait and retry with exponential backoff
Swap data is empty after /swapQuote expired; re-fetch quote
Bridge times outCheck bridge explorer; do not re-submit
x402 payment rejected (402)Check domain name/version, validBefore, nonce freshness
InsufficientBalance on TempoSwap more tokens on Tempo, then retry
balanceOf
sufficient but payment fails
Apply 2x buffer; top up before retrying

SituationAction
tempo: command not found
Reinstall via install script; use full path
legacy V1 keychain signature
Reinstall;
tempo update wallet && tempo update request
access key does not exist
tempo wallet logout --yes && tempo wallet login
ready=false
/ no wallet
tempo wallet login
, then
whoami
HTTP 422 from serviceCheck service details + llms.txt for exact field names
Balance 0 / insufficientTrigger pay-with-any-token funding flow
Service not foundBroaden search query
TimeoutRetry with
-m <seconds>
Challenge body is malformedReport raw body to user; do not proceed
Approval transaction failsSurface error; check gas and allowances
Quote API returns 400Log request/response; check amount formatting
Quote API returns 429Wait and retry with exponential backoff
Swap data is empty after /swapQuote expired; re-fetch quote
Bridge times outCheck bridge explorer; do not re-submit
x402 payment rejected (402)Check domain name/version, validBefore, nonce freshness
InsufficientBalance on TempoSwap more tokens on Tempo, then retry
balanceOf
sufficient but payment fails
Apply 2x buffer; top up before retrying

Key Addresses and References

关键地址与参考链接

  • Tempo CLI:
    https://tempo.xyz
    (install script:
    https://tempo.xyz/install
    )
  • Trading API:
    https://trade-api.gateway.uniswap.org/v1
  • MPP docs:
    https://mpp.dev
  • MPP services catalog:
    https://mpp.dev/api/services
  • Tempo documentation:
    https://mainnet.docs.tempo.xyz
  • Tempo chain ID:
    4217
    (Tempo mainnet)
  • Tempo RPC:
    https://rpc.presto.tempo.xyz
  • Tempo Block Explorer:
    https://explore.mainnet.tempo.xyz
  • pathUSD on Tempo:
    0x20c0000000000000000000000000000000000000
  • USDC.e on Tempo:
    0x20C000000000000000000000b9537d11c60E8b50
  • Stablecoin DEX on Tempo:
    0xdec0000000000000000000000000000000000000
  • Permit2 on Tempo:
    0x000000000022d473030f116ddee9f6b43ac78ba3
  • Tempo payment SDK:
    mppx
    (
    npm install mppx viem
    )
  • USDC on Base (8453):
    0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913
  • USDbC on Base (8453):
    0xd9aAEc86B65D86f6A7B5B1b0c42FFA531710b6CA
  • USDC on Ethereum (1):
    0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48
  • USDC-e on Arbitrum (42161):
    0xFF970A61A04b1cA14834A43f5dE4533eBDDB5CC8
  • Supported chains for Trading API: 1, 8453, 42161, 10, 137, 130
  • x402 spec:
    https://github.com/coinbase/x402
  • Tempo CLI
    https://tempo.xyz
    (安装脚本:
    https://tempo.xyz/install
  • Trading API
    https://trade-api.gateway.uniswap.org/v1
  • MPP文档
    https://mpp.dev
  • MPP服务目录
    https://mpp.dev/api/services
  • Tempo文档
    https://mainnet.docs.tempo.xyz
  • Tempo链ID
    4217
    (Tempo主网)
  • Tempo RPC
    https://rpc.presto.tempo.xyz
  • Tempo区块浏览器
    https://explore.mainnet.tempo.xyz
  • Tempo上的pathUSD
    0x20c0000000000000000000000000000000000000
  • Tempo上的USDC.e
    0x20C000000000000000000000b9537d11c60E8b50
  • Tempo上的稳定币DEX
    0xdec0000000000000000000000000000000000000
  • Tempo上的Permit2
    0x000000000022d473030f116ddee9f6b43ac78ba3
  • Tempo支付SDK
    mppx
    npm install mppx viem
  • Base链(8453)上的USDC
    0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913
  • Base链(8453)上的USDbC
    0xd9aAEc86B65D86f6A7B5B1b0c42FFA531710b6CA
  • 以太坊链(1)上的USDC
    0xA0b86991c6218b36c1d19D4a2e9Eb0cE3606eB48
  • Arbitrum链(42161)上的USDC-e
    0xFF970A61A04b1cA14834A43f5dE4533eBDDB5CC8
  • Trading API支持的链:1, 8453, 42161, 10, 137, 130
  • x402规范
    https://github.com/coinbase/x402

Related Skills

相关技能

  • swap-integration — Full Uniswap swap integration reference (Trading API, Universal Router, Permit2)
  • swap-integration — 完整的Uniswap兑换集成参考(Trading API、Universal Router、Permit2)