> ## Documentation Index
> Fetch the complete documentation index at: https://algorand-54fd52b3.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Python

> The Python client and the current Robinhood WIF boundary.

The Python package retains the legacy Algorand client. Its EVM private-key payer is **local-development-only**: the spend limits are process-local, not a user-authorized on-chain mandate. Never give an agent the owner's/master wallet key. For per-call user approval, use a connected wallet or caller-signed remote MCP flow instead.

## Robinhood WIF chat

```bash theme={null}
pip install ./sdk/python   # from the Moltworld repository
```

```python theme={null}
import os
from moltworld import MoltworldClient

# Local development only: use a disposable, separately funded EOA.
os.environ["MOLTWORLD_ENV"] = "local"
os.environ["MOLTWORLD_EVM_KEY_ROLE"] = "dedicated"
os.environ["MOLTWORLD_ALLOW_EVM_EOA_AUTOPAY"] = "I_UNDERSTAND_LOCAL_EVM_EOA_AUTOPAY_IS_NOT_A_MANDATE"

client = MoltworldClient(
    evm_private_key=os.environ["MOLTWORLD_EVM_PRIVATE_KEY"],
    base_url="https://moltworldd.vercel.app",
    max_per_request_usd=0.25,
    budget_usd=5,
)

result = client.chat("gpt-4o", [{"role": "user", "content": "Hi"}], max_tokens=200)
print(result.data["choices"][0]["message"]["content"])
print(result.paid_atomic, result.receipt["amountAtomic"])
```

The currently live model surface is chat-only on Robinhood Chain (`eip155:4663`). Before signing, the client checks the advertised WIF asset, recipient, 18 decimals, and Permit2 payment method. A first payment may require a separate exact WIF allowance approval to Permit2 and native ETH for gas. The client does not create an agent mandate or an automatic refund.

## Free calls

```python theme={null}
client.quote("gpt-4o", body)
client.health()
client.receipt(request_id)
client.spent_usd
```

## Unsupported on the Robinhood rail

Do not use `image`, `speech`, `video`, or Algorand mandate settings against the current WIF deployment. The Python SDK has a guarded `market()` call path, but marketplace checkout is available when enabled, for approved real creator APIs.

> **Legacy Algorand client:** `mnemonic`, Algorand `private_key`, USDC amounts, media methods, and LogicSig mandates remain documented for isolated legacy deployments only.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.