---
title: "x402 如何為請求計價"
description: "在 x402.erpc.global 上，一次標準 RPC 呼叫的價格為 $0.001。較耗資源的方法依其權重收取較高費用，批次請求以一個請求計價。"
canonical: "https://erpc.global/zh-tw/doc/x402/pricing/"
locale: "zh-tw"
---

# x402 如何為請求計價

標準呼叫（例如 `getSlot` 或 `eth_blockNumber`）的價格為 \$0.001，這是單一請求的最低收費。較耗資源的方法（例如 `getProgramAccounts` 或 `eth_getLogs`）會依方法的權重收取較高費用。批次請求以一個請求計價，因此整個批次請求只需支付一次最低收費。每個方法的價格都可在 [x402.erpc.global/pricing](https://x402.erpc.global/pricing) 查看，其資料與實際為您的請求計價的價格表相同。

## 價格的計算方式

1. 每個方法都有一個以 token 計的權重。這裡的 token 是價格單位，不是代幣：一個 token 為 \$0.000001，因此 1,000 token 為 \$0.001，以 0.001 USDC 支付。
2. 將請求中所有呼叫的權重相加。
3. 合計未滿 1,000 token 時，以 1,000 token（\$0.001）收費：這是 x402.erpc.global 結算的最低付款額。

由 `getSlot` 與 `getBlockHeight` 組成的批次請求權重為 42 + 42 = 84 token，價格為 \$0.001。由 `eth_blockNumber`、`eth_getLogs` 與 `eth_call` 組成的批次請求權重為 42 + 2,400 + 420 = 2,862 token，價格為 \$0.002862。

## Solana

| 方法 | token 數 | 單次呼叫的價格 |
| --- | --- | --- |
| 標準方法，例如 `getBalance`、`getSlot` 與 `sendTransaction` | 42 | \$0.001 |
| DAS 方法，例如 `getAsset` | 640 | \$0.001 |
| `getMultipleAccounts` | 呼叫中每個帳戶 420 | 1 或 2 個帳戶為 \$0.001，最多 100 個帳戶時為 \$0.042 |
| `getTokenLargestAccounts` | 2,400 | \$0.0024 |
| `getProgramAccounts`、`getProgramAccountsV2` | 4,200 | \$0.0042 |

/pricing 中的其他方法權重都低於 1,000 token，因此單次呼叫的價格為 \$0.001；例如 `getSignaturesForAddress` 的權重為 420。與其他鏈不同，Solana 也接受 /pricing 中未列出的方法，以 42 token 計。例外是 x402.erpc.global 不販售的方法（例如 `getLeaderSlots`），呼叫這些方法會收到錯誤回應，且不收費。

## Ethereum 與 Base

Base 套用 Ethereum 的價格表。

| 方法 | token 數 | 單次呼叫的價格 |
| --- | --- | --- |
| 標準方法，例如 `eth_blockNumber`、`eth_getBalance` 與 `eth_sendRawTransaction` | 42 | \$0.001 |
| 執行程式碼或產生證明的呼叫，例如 `eth_call`、`eth_estimateGas` 與 `eth_getProof` | 420 | \$0.001 |
| 回傳大量資料的呼叫，例如 `eth_getLogs`、`eth_getBlockReceipts`，以及回傳完整交易的 `eth_getBlockByNumber` | 2,400 | \$0.0024 |
| `eth_simulateV1`、`eth_callMany` | 4,200 | \$0.0042 |

不在價格表中的方法（例如 `debug_*` 或 `trace_*` 方法）會在付款之前收到錯誤回應。

## Avalanche

`eth_*` 方法使用 Ethereum 的權重。其他命名空間中的方法（例如 `avax.*`、`avm.*`、`platform.*` 與 `info.*`）權重為 42 token，因此單次呼叫的價格為 \$0.001。

## 其他 12 條鏈

在 Arbitrum、Bitcoin、Hyperliquid、Kaia、Monad、NEAR、Optimism、Polygon、Robinhood Chain、Soneium、Sui 與 TRON 上，所有方法的權重都低於 1,000 token，因此單次呼叫的價格為 \$0.001。不在該鏈價格表中的方法會在付款之前收到錯誤回應。

## 以 EURC 付款

價格以美元計。EURC 與 USDC 等額收取：單位數量相同，不套用匯率。\$0.001 的請求以 0.001 USDC 或 0.001 EURC 支付。

## 查看價格

`GET https://x402.erpc.global/pricing` 回傳每個路徑的價格表，列出每個方法的 token 數與價格。此端點免費。
