ମୁଖ୍ୟ ବିଷୟବସ୍ତୁକୁ ଛାଡ଼ନ୍ତୁ
ଶବ୍ଦକୋଷ

x402 କଣ।

ପରିଭାଷା

x402 ହେଉଛି HTTP-native payments ପାଇଁ ଗୋଟିଏ open protocol, ଯାହା Coinbase ଦ୍ୱାରା 2024 ର ଶେଷ ଭାଗରେ ପ୍ରକାଶିତ। ଏହା server କିପରି 402 Payment Required କୁ ଗୋଟିଏ structured JSON body ସହିତ ଫେରାଏ - acceptable payment requirements (scheme, network, chain id, recipient address, USDC base units ରେ amount, ଏବଂ ଗୋଟିଏ payment-request id) ର ତାଲିକା - ସେଥିର ରୂପରେଖା ଦେଏ, ଯାହାଦ୍ୱାରା machine client response କୁ parse କରିପାରେ, on-chain pay କରିପାରେ, ଏବଂ X-Payment header ସହିତ original call କୁ retry କରିପାରେ, ସବୁ programmatically।

କାହିଁକି ଏହା ଗୁରୁତ୍ୱପୂର୍ଣ୍ଣ

HTTP 402 ବିଶ୍ୱରେ ତିନି ଦଶକ ଧରି ବ୍ୟବହାର ହୋଇନଥିଲା। x402 ଏହାକୁ କାମ କରାଇଛି।

The 402 Payment Required status code was reserved in the original HTTP spec for "future use" and never received a standardized implementation. For three decades, every actual payment flow on the web was built on top of 200 / 401 / 403: a server returns 401 when authentication is missing, the client signs up via a separate UI flow, gets credentials, and re-authenticates. The signup happens out of band. None of this works for AI agents, which cannot complete signup forms.

x402 fixes this by giving 402 a usable specification. A server can return 402 with structured machine-readable payment instructions; a client can parse those instructions, pay, and retry, all without ever touching a signup form. The protocol is the missing piece between "AI agents can call APIs" and "AI agents can pay for the APIs they call". Before x402, the only practical agent payment paths were pre-paid balance accounts (with manual top-up) or proprietary integrations per API. Both broke at scale.

x402 ର strategic importance ହେଉଛି ଏହା ଏକ standard set କରେ ଯାହା ଉପରେ ecosystem ର ଅନ୍ୟାନ୍ୟ ଅଂଶ build କରିପାରେ। Wallet ଗୁଡ଼ିକ ଗୋଟିଏଥର x402 handler implement କରନ୍ତି, ଏବଂ ପ୍ରତ୍ୟେକ x402-compliant API ସେହି wallet ସହିତ କାମ କରେ। Server framework ଗୁଡ଼ିକ ଗୋଟିଏଥର x402 middleware implement କରନ୍ତି, ଏବଂ ପ୍ରତ୍ୟେକ x402-aware client ସେମାନଙ୍କୁ ଦେୟ କରିପାରେ। Facilitator (underlying payment settle କରୁଥିବା service) lock-in ପରିବର୍ତ୍ତେ quality of service ଉପରେ ପ୍ରତିସ୍ପର୍ଧା କରନ୍ତି।

କେମିତି ଏହା କାମ କରେ

ଏକ ପ୍ରତିକ୍ରିୟା, ଏକ ପୁନର୍ପ୍ରୟାସ, ଏକ ପେମେଣ୍ଟ।

Lifecycle ରେ ତିନୋଟି state ଅଛି: unpaid call, payment, retried call। ତଳେ unpaid-call response wire ଉପରେ ପ୍ରକୃତରେ କିପରି ଦେଖାଯାଏ ସେଥି ଦିଆଯାଇଛି।

ଅଦେୟ କଲ୍ ଉତ୍ତର
HTTP/1.1 402 Payment Required
Content-Type: application/json

{
  "resource": "POST /api/research-query",
  "accepts": [
    {
      "scheme": "exact-usdc",
      "network": "mainnet",
      "chainId": "eip155:8453",
      "payToAddress": "0xAgent...",
      "amountWeiUsdc": "50000",
      "paymentRequestId": "pr_01J9...",
      "maxAgeSeconds": 60
    }
  ]
}
  • Status code 402. Distinct from 401 (auth missing) and 403 (auth refused). The presence of 402 signals "payment is the missing input."
  • resource + accepts[]. body ରେ protected resource ର ନାମ ଥାଏ ଏବଂ ଗୋଟିଏ କିମ୍ବା ଅଧିକ ଗ୍ରହଣଯୋଗ୍ୟ payment requirement ତାଲିକାଭୁକ୍ତ ହୁଏ। ଏକ migration ଦୁଇଟି requirement (ଯଥା mainnet ଏବଂ testnet) quote କରି client କୁ ବାଛିବାକୁ ଦେଇପାରେ।
  • scheme / network / chainId. payment scheme (exact-usdc), chain (mainnet ହେଉଛି Base), ଏବଂ ଏହାର CAIP-2 id। ପେ କରିବା ପୂର୍ବରୁ client ଏଗୁଡ଼ିକ ସହିତ match କରେ।
  • payToAddress / amountWeiUsdc. recipient wallet ଏବଂ USDC base units ରେ ସଠିକ୍ amount (50000 = 0.05 USDC, 6 decimals)। ପେ କରିବା ପୂର୍ବରୁ client ଉଭୟକୁ verify କରେ।
  • paymentRequestId + maxAgeSeconds. id ଟି ପେମେଣ୍ଟକୁ ଏହି quote ସହିତ ଯୋଡ଼େ; maxAgeSeconds ହେଉଛି ପେମେଣ୍ଟ କେତେ ନୂତନ ହେବା ଦରକାର। ଭିନ୍ନ id କୁ ସନ୍ଦର୍ଭ କରୁଥିବା କିମ୍ବା window ଠାରୁ ପୁରୁଣା ପେମେଣ୍ଟ ଅସ୍ୱୀକୃତ ହୁଏ।
  • retry ରେ X-Payment header ଥାଏ। କ୍ଲାଏଣ୍ଟ on-chain ରେ ପେମେଣ୍ଟ କରେ, ତାପରେ ପେମେଣ୍ଟ ପ୍ରମାଣ କରୁଥିବା X-Payment header ସହିତ ମୂଳ request ପୁଣିଥରେ ପଠାଏ। ସର୍ଭର ଏହାକୁ verify କରି ପ୍ରକୃତ result ଫେରାଏ। response headers କିମ୍ବା hosted page x402 wire ର ଅଂଶ ନୁହେଁ।
ଉଦାହରଣଗୁଡିକ

x402 ବନ୍ୟାରେ।

ତିନି କଠିନ ନିଯୁକ୍ତି, ପ୍ରତିଟି ଲେୟରରେ ଗ୍ରହଣ କିପରି ପକ୍କା ହେଉଛି ତାହା ଅନୁସାରେ କ୍ରମବଦ୍ଧ।

ଉଦାହରଣ 1

MCP server unpaid tool call କୁ 402 challenge ଫେରାଉଛି

ଏକ paid MCP tool Claude Desktop ଠାରୁ ଏକ invocation ପାଏ ଏବଂ caller ଏପର୍ଯ୍ୟନ୍ତ paid ଭାବେ marked ହୋଇନାହିଁ। server ଏକ requirePayment challenge ତିଆରି କରେ - price ଏବଂ hostedUrl ଧାରଣ କରୁଥିବା 402 - ଏବଂ ଏହାକୁ tool error ଭାବରେ ଫେରାଏ। Claude Desktop chat ରେ link ଦେଖାଏ; user $0.05 USDC ପେ କରେ; ସେହି ଏକେ tool କୁ ପରବର୍ତ୍ତୀ call ସଫଳ ହୁଏ।

ଉଦାହରଣ 2

API ଏଣ୍ଡପଏଣ୍ଟ ଗେଟିଂ ପର-କଲ୍ ବିଲିଂ

x402 server adapter ର ପଛରେ ଥିବା ଏକ research API ପ୍ରତି call $0.50 ନେଉଛି। ଏକ AI agent endpoint କୁ call କରେ, amount ଏବଂ recipient ତାଲିକାଭୁକ୍ତ 402 ପାଏ, ନିଜ wallet ରୁ Base ଉପରେ ପେ କରେ, ଏବଂ X-Payment header ସହିତ request କୁ ପୁଣି issue କରେ। adapter header କୁ verify କରି paid response ଫେରାଏ। ସମ୍ପୂର୍ଣ୍ଣ loop 60 seconds ଠାରୁ କମ୍ ସମୟରେ ସମାପ୍ତ ହୁଏ।

ଉଦାହରଣ 3

x402-ଜାଣିଥିବା ୱାଲେଟ୍ ଦ୍ୱାରା କାର୍ଯ୍ୟକ୍ରମ ଭାବେ ଦେୟ କରୁଥିବା ଏଜେଣ୍ଟ

ଏକ agent ର runtime x402-aware ଅଟେ (ଏହା spec କୁ implement କରେ)। ଯେତେବେଳେ ଏହା 402 ସମ୍ମୁଖୀନ ହୁଏ, ଏହା accepts[] ରୁ payToAddress ଏବଂ amount ପଢ଼େ, ତାହାର pre-authorized wallet ରୁ (ତାହାର spend permission ଭିତରେ) transfer sign କରେ, Base ଉପରେ broadcast କରେ, ଏବଂ X-Payment header ସହିତ original call କୁ retry କରେ। କୌଣସି ମାନବ ଜଡ଼ା ନାହିଁ; loop 5-10 seconds ରେ ସମାପ୍ତ ହୁଏ।

ସମ୍ବନ୍ଧିତ ଶବ୍ଦଗୁଡିକ

ଷ୍ଟ୍ୟାକ୍‌ରେ x402 କୁ କଣ ଘେରାଇଛି।

x402 ହେଉଛି ପ୍ରୋଟୋକଲ୍। ଏହି ତିନି ଶବ୍ଦ ସେହି ଧାରଣାଗୁଡିକୁ ଆବରଣ କରେ ଯାହା ଏହା ଉପରେ ବସିଥାଏ ଏବଂ ଯେଉଁ ଉପଯୋଗକ୍ଷମତାଗୁଡିକୁ ଏହା ସକ୍ଷମ କରେ।

ସାଧାରଣ ପ୍ରଶ୍ନୋତ୍ତର

ତିନି ସାଧାରଣ ପ୍ରଶ୍ନ।

କି x402 ଏକ Coinbase ଉତ୍ପାଦ କିମ୍ବା ଏକ ଖୋଲା ପ୍ରୋଟୋକଲ?

Coinbase ଦ୍ୱାରା ପ୍ରକାଶିତ ଏକ open protocol। spec GitHub ରେ ଅଛି ଏବଂ permissively licensed; Coinbase ର ଜଡ଼ାଯୋଗ ନାଥାଏ, କେହି ମଧ୍ୟ ଏହା implement କରିପାରେ। Coinbase ଏକ reference implementation ଦେଇଥାଏ ଏବଂ ଏକ facilitator service ଚଳାଏ, କିନ୍ତୁ protocol Coinbase company ରୁ ସ୍ୱାଧୀନ। ଅନେକ facilitators (Blockchain0x, Coinbase, ecosystem ବୃଦ୍ଧି ପାଇବା ସହିତ ଅନ୍ୟମାନେ) x402 payments settle କରିପାରନ୍ତି; server adapter wire up କରିବାବେଳେ facilitator ଆପଣ ବାଛନ୍ତି, caller ନୁହେଁ।

AI ଏଜେଣ୍ଟମାନେ 402-ଫେରାଇଥିବା API ବ୍ୟବହାର କରିବାକୁ x402-ଜାଣିବା ଆବଶ୍ୟକ କି?

ଏହା 402 variant ଉପରେ ନିର୍ଭର କରେ। x402 server adapter ଏକ x402-aware client ଆଶା କରେ: ଯେଉଁ client x402 କଥା କହେ ନାହିଁ ସେ 402 ପାଏ ଏବଂ ସରଳଭାବେ କୌଣସି result ପାଏ ନାହିଁ (ସଠିକ୍ outcome - call paid ହୋଇନି)। ଯେଉଁ ମାମଲାରେ ଏକ human pay କରିପାରିବା ଉଚିତ, Blockchain0x hosted-checkout variant ପ୍ରଦାନ କରେ ଯାହାର 402 body ଭିତରେ pay URL ଥାଏ (MCP requirePayment challenge ଏହାକୁ ବ୍ୟବହାର କରେ), ସେଥିପାଇଁ chat client clickable link ଦେଖାଇପାରେ। ସମୟ ସହିତ, ଅଧିକ client x402-aware ହେବେ ଏବଂ human ବିନା programmatically pay କରିବେ।

x402 ସହିତ କେଉଁଠି ଅନ୍ୟ ପ୍ରୋଟୋକଲ୍‌ଗୁଡିକ ପ୍ରତିଦ୍ୱନ୍ଦ୍ୱା କରନ୍ତି?

ଗୁଗୁଲ୍ର AP2 (ଏଜେଣ୍ଟ ପେମେଣ୍ଟ ପ୍ରୋଟୋକଲ୍) ଏକ ଭିନ୍ନ ଡିଜାଇନ୍ (ମାଣ୍ଡେଟ୍-ଆଧାରିତ ବଜାୟ 402-ଆଧାରିତ) ସହିତ ସମାନ ମାଇଦାନକୁ ଆବରଣ କରେ। Stripe ଏକ ଏଜେଣ୍ଟ ପେମେଣ୍ଟସ୍ ଲେୟର୍ ସଙ୍କେତ ଦେଇଛି କିନ୍ତୁ ଏପର୍ଯ୍ୟନ୍ତ ଏକ ସାଧାରଣ ବିବରଣୀ ପ୍ରକାଶ କରିନାହିଁ। କିଛି ଛୋଟ ପ୍ରକଳ୍ପ (Bitcoin Lightning ପରିବେଶରେ L402) x402 କୁ ସମାନ ଧାରଣା ସହିତ ପୂର୍ବରୁ ଥିଲେ। x402 ଆଜି EVM/stablecoin ଏଜେଣ୍ଟ ପରିବେଶରେ ସର୍ବାଧିକ ନିର୍ମିତ ପ୍ରୋଟୋକଲ୍; AP2 ଗୁଗୁଲ୍ ପରିବେଶରେ ନେତୃତ୍ୱ କରେ। ସେମାନେ ଏକ ଜିତିବାରୁ ଅଧିକ ସହଯୋଗ କରିବାକୁ ସମ୍ଭାବନା ରହିଛି, କାରଣ ସେମାନେ ଅଲ୍ପ ପ୍ରଭେଶ କନ୍ଟେକ୍ସକୁ ଲକ୍ଷ୍ୟ କରନ୍ତି।
ଶେଷ ସମୀକ୍ଷା: 2026-05-15. CC BY 4.0 ଅନୁସାରେ ପ୍ରକାଶିତ।

ଆପଣଙ୍କର ଏଜେଣ୍ଟ ସହିତ x402 କଥା ହେବେ।

Blockchain0x ଏକ x402 facilitator। ଆରମ୍ଭ କରିବାକୁ Free। ଆପଣଙ୍କ ପ୍ରଥମ agent wallet ପାଇଁ ପାଞ୍ଚ ମିନିଟ୍।