x402 Help and Documentation
Learn how Zahlen helps merchants observe and control payments made by software agents. This guide explains the x402 payment path, dashboard, CSV import, policy checks, replay protection, settlement and delivery tracking, reconciliation, and audit evidence.
What x402 Does
x402 is a way for a website or online service to ask for payment through the same web request that asks for a protected resource. A software agent may request data, a report, an API result, or another paid service. The merchant can answer with an HTTP 402 payment challenge that explains what must be paid before the resource is released.
Zahlen adds payment intelligence and control around that exchange. It checks the payment request, applies merchant rules, records what happened, watches for risky behavior, and connects the payment to the final delivery result.
How an x402 Payment Moves Through Zahlen
- A software agent asks a merchant for a protected resource.
- The merchant returns an HTTP 402 challenge with the price and payment instructions.
- The agent submits a payment authorization or proof.
- Zahlen checks the merchant, endpoint, agent, wallet, amount, asset, network, and facilitator.
- Zahlen checks spending limits, recent activity, unusual behavior, and possible replay attempts.
- The verification adapter confirms whether the proof is valid.
- The payment is settled through the selected provider when settlement is required.
- The merchant releases or denies the requested resource.
- Zahlen connects the request, payment, settlement, and delivery into one history.
Each lifecycle uses a correlation ID. This ID helps Zahlen follow one request from its first payment challenge through the final delivery and reconciliation result.
Open the x402 Merchant Dashboard
Open the x402 Merchant Dashboard from the Zahlen Workspace or from the link at the top of this guide. You may be asked to sign in before the dashboard opens.
Runtime Status Badges
The badges at the top of the dashboard explain how the x402 service is operating.
Merchant and Activity Window
Merchant
Select the merchant whose x402 activity you want to review. Changing the merchant also updates the CSV template link so imported records use the correct merchant scope.
Activity Window
Choose the last 24 hours, 7 days, or 30 days. The dashboard cards and tables update to match that time window.
Refresh
Select to load the newest recorded activity. A loading message appears while the dashboard is being updated.
Upload x402 Events CSV
The CSV feature lets a merchant load x402 lifecycle observations without building an API connection first. Files must use UTF-8 text, be no larger than 2 MB, and contain no more than 1,000 rows.
Download the correct example
- No merchant selected: select . The ZIP contains a merchant example and a 1,000-row test file with a useful mix of successful and unsuccessful outcomes.
- Merchant selected: select . The CSV is prepared for the selected merchant.
Preview before import
- Select a CSV file from your computer.
- Select .
- Review each row's status, source event, correlation ID, record count, and reason codes.
- Correct invalid rows in the source file when needed, then preview the file again.
- Select when the preview is acceptable.
The Import valid rows button shows a spinner only while Zahlen is ingesting the file. Valid rows are appended. Invalid or duplicate rows are reported and do not overwrite earlier evidence.
Activity Summary Cards
Use these cards as a quick starting point. Open the tables below them to understand the specific transactions behind each total.
Transaction Activity
This table provides one joined view of each x402 lifecycle. It shows the time, agent, wallet, resource, amount, policy result, settlement result, delivery result, and reconciliation state.
Select Download in the Audit evidence column to save the evidence bundle for one correlation ID.
Agent and Wallet History
Zahlen treats an agent ID and wallet address as identities. The history table shows how often each identity appears, how many payment attempts it made, how many replays were detected, and when it was last seen.
Policy Decisions
The policy engine gives each evaluated request an Allow, Deny, or Review result. The decision includes clear reason codes, supporting evidence, the policy version, and an anomaly score.
Duplicate and Replay Protection
A replay happens when the same payment proof or request is submitted again. This may be an accident, a delayed retry, or an attempt to receive the same paid service more than once.
Zahlen records replay evidence instead of replacing the original event. The Anomalies and Replay Attempts table shows the agent, wallet, anomaly score, replay count, and reason codes connected to the activity.
Settlement, Delivery, and Reconciliation
Settlement answers whether the payment completed. Delivery answers whether the merchant released the protected resource. Reconciliation compares every stage and reports whether the full story makes sense.
Use the Reconciliation Exceptions table as a work queue. Review the exception code and correlation ID, then use the audit bundle to inspect the complete lifecycle.
Spend and Velocity Trends
Trend rows group activity into time buckets. They show attempts, attempts per hour, settled payments, delivered resources, anomalies, and replay attempts.
Look for changes such as:
- A sudden increase in attempts per hour.
- More settled payments without matching deliveries.
- A growing number of anomalies or replay attempts.
- A sharp difference from the agent's or wallet's normal behavior.
Downloadable Audit Evidence
Each transaction can provide a ZIP evidence bundle tied to its correlation ID. The bundle is designed to show the recorded request, challenge, proof, verification, policy decision, settlement, delivery, replay evidence, and reconciliation result that exist for that lifecycle.
- Find the transaction in Transaction Activity.
- Confirm that the merchant, agent, amount, and resource match the issue you are reviewing.
- Select Download in the Audit evidence column.
- Keep the original ZIP unchanged when it will be used for an investigation or formal review.
- Record any correction as a new event rather than editing the earlier evidence.
Security and Privacy
- Zahlen never stores private keys.
- Wallet addresses and agent identifiers are treated as identities, not credentials.
- Original x402 events remain append-only and are not overwritten by corrections.
- Merchant and tenant boundaries are checked before data or evidence is returned.
- Live payments are disabled by default until the production-hardening gate is approved.
- Provider adapters keep Zahlen's records independent of one facilitator, processor, or network.
Troubleshooting
The dashboard has no merchant options
Confirm that your signed-in account is connected to an active merchant. If you are using the example bundle, import its valid rows to create the isolated example merchant activity.
Import valid rows is disabled
Select a file and run Preview CSV first. The import button becomes available only after a successful preview finds rows that can be imported.
A row is marked invalid
Read the row's reason codes. Check required values, date and amount formats, lifecycle order, merchant scope, and allowed status values. Correct the source file and preview it again.
A row is marked duplicate
The event may already exist or may reuse proof evidence. Zahlen reports the duplicate and keeps the first record unchanged. Confirm the source event and correlation ID before retrying.
Dashboard totals did not change
Confirm that the import finished, select the correct merchant and activity window, and then select Refresh. Records outside the selected time window will not appear in the totals.
Audit evidence will not download
Confirm that you are signed in to the same merchant that owns the correlation ID. Also check that the transaction exists and that your session has not expired.
Recommended x402 Review Workflow
- Confirm the gateway and live-payment status badges.
- Select the correct merchant and activity window.
- Review Transactions, Payment Attempts, Settled, Delivered, Replays, and Exceptions.
- Open Transaction Activity and find the lifecycle you need to review.
- Check the agent and wallet history for earlier behavior.
- Read the policy decision, reason codes, and anomaly score.
- Review anomalies and repeated proofs.
- Compare settlement with delivery and check reconciliation exceptions.
- Review spend and velocity trends for broader context.
- Download the audit evidence bundle when a detailed review is needed.