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

# Python sandbox quickstart

> Verify an agent connection and complete a simulated payment using Python and the standard library.

Use Python 3.10+ with Conto's HTTP API. This starter requires no Python dependencies.
It checks setup by default and executes only when you explicitly pass `--execute` in a CLI-created
simulated sandbox.

## Create a sandbox

Use Node.js 20.19+ for the setup CLI, then run the Python example from the same directory:

```bash theme={null}
mkdir conto-python
cd conto-python
npx @conto_finance/create-conto-agent --sandbox --json
curl -fsS https://conto.finance/examples/conto-sandbox.py -o conto-sandbox.py
python3 conto-sandbox.py
```

The CLI stores your agent key in `.env.local`. The Python script reads it without printing credentials.
Your first run prints the agent name and scopes; it creates no payment.

## Execute a simulated payment

```bash theme={null}
python3 conto-sandbox.py --execute
```

The script creates one payment intent for `0.01`, prints its request ID, and executes only if the
policy decision is `APPROVED`. Success means `Status: completed` and `Settlement mode: test`.
The test receipt records the workflow without transferring funds.

Each invocation with `--execute` creates a new intent. After a timeout, inspect the original request
instead of executing again:

```bash theme={null}
python3 conto-sandbox.py --status REQUEST_ID
```

Keep the request ID in your application's durable job record before production execution. The example
does not automatically retry writes or submit transactions with an external signer.

## Next steps

* [Payment recovery](/docs/guides/payment-lifecycle): review, timeouts, and settlement.
* [API conventions](/docs/reference/api-conventions): authentication and response contracts.
* [Payment support](/docs/reference/payment-support): networks and signer requirements.
* [Webhooks](/docs/guides/webhooks): receive and verify payment updates.
