> ## Documentation Index
> Fetch the complete documentation index at: /llms.txt
> Use this file to discover all available pages before exploring further.

# Introduction

> SohoPay gives a borrower a USDC credit line that an authorized agent can spend at x402 merchants on Base.

SohoPay is a credit rail for AI agents. A person (the borrower) holds a revolving facility. An agent they authorize spends that credit at merchants over [x402](/protocol/x402.md). Merchants are paid in USDC on Base from a batched on-chain settlement. SohoPay never holds the borrower's wallet key or the agent's workload key.

> [!NOTE]
>
> Staging is the supported integration environment (Base Sepolia). Hosts and contracts are in [Environment setup](/environment-setup.md).

> [card] [Quickstart](/quickstart.md)
>
> Connect an agent over MCP, or accept your first x402 payment as a merchant.

> [card] [Integration paths](/integration-paths.md)
>
> Agent, merchant, or both — pick the surface you actually call.

> [card] [Pay with an agent](/guides/payment-flow.md)
>
> From HTTP 402 to a signed voucher and a confirmed settlement.

> [card] [Accept a payment](/guides/merchant-integration.md)
>
> Verify, capture, and poll until the batch is confirmed.

## How a payment moves

![SohoPay system architecture showing the borrower, agent, hosted MCP, control plane, merchant, facilitator, and Base settlement contracts](/images/architecture-light.png)

| Role | What they do | What they hold |
| - | - | - |
| **Borrower** | Opens the facility, proves a wallet, signs the agent grant, repays | An EOA. Signatures happen in their wallet, off the agent. |
| **Agent** | Spends inside the grant at x402 merchants | An Ed25519 workload key on the host. One terminal per MCP client. |
| **Merchant** | Returns 402 and captures the signed voucher | A merchant account and an `sk_live_` API key or user JWT. |
| **Protocol** | Checks policy, reserves credit, and settles USDC | A hardware-backed batch attestation key. Not the borrower or agent key. |

## What this is not

Agents do not get a custodial wallet, and you do not co-sign payments with a threshold scheme. The [ERC-4626 vault](/protocol/erc-4626-vault.md) is lender liquidity behind settlement. It is not a balance you deposit in order to give an agent a credit limit. Credit is a facility on the borrower, drawn down when a batch settles and restored when the borrower [repays](/guides/repayment.md).

## Next steps

> [card] [Quickstart](/quickstart.md)
>
> Start on staging.

> [card] [Authentication](/authentication.md)
>
> OAuth for agents, API keys for merchants.
