Metadata-Version: 2.4
Name: xrpl-x402-client
Version: 0.2.0
Summary: Buyer-side Python SDK for XRPL exact x402 payments
Project-URL: Homepage, https://github.com/lgcarrier/xrpl-x402-stack
Project-URL: Documentation, https://lgcarrier.github.io/xrpl-x402-stack/packages/client/
Project-URL: Repository, https://github.com/lgcarrier/xrpl-x402-stack
Project-URL: Issues, https://github.com/lgcarrier/xrpl-x402-stack/issues
Project-URL: Changelog, https://github.com/lgcarrier/xrpl-x402-stack/blob/main/CHANGELOG.md
Author-email: Louis-Guillaume Carrier-Bedard <lgcarrier@gmail.com>
License-Expression: MIT
Keywords: client,httpx,payments,x402,xrpl
Classifier: Intended Audience :: Developers
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.12
Classifier: Programming Language :: Python :: Implementation :: CPython
Classifier: Topic :: Internet :: WWW/HTTP
Classifier: Typing :: Typed
Requires-Python: >=3.12
Requires-Dist: httpx==0.28.1
Requires-Dist: pydantic<3,>=2
Requires-Dist: x402[extensions]==2.21.0
Requires-Dist: xrpl-py==4.5.0
Requires-Dist: xrpl-x402-core==0.2.0
Description-Content-Type: text/markdown

# xrpl-x402-client

Client mechanism for x402 v2 exact XRPL payments.

```python
from x402 import x402Client
from xrpl_x402_client import register_exact_xrpl_client

client = register_exact_xrpl_client(x402Client(), signer)
client.set_spend_controls({"max_amount_per_payment": "$1"})
```

`ExactXRPLClientScheme` constructs and signs sequence or ticket payments,
derives `LastLedgerSequence` from the timeout, binds custom networks through
`NetworkID`, hashes advertised invoice IDs, and emits only
`{"signedTxBlob": "..."}` as the scheme payload.

Use `XRPLAssetSpendLimit` for XRP, USDC, or custom IOUs. These assets are not
silently authorized by the default pegged-asset policy.

The `XRPLPaymentTransport` and `wrap_httpx_with_xrpl_payment` helpers use the
official `x402AsyncTransport`, which retries a replayable protected request at
most once.
Custom async streaming bodies are sent exactly once and a `402` is returned to
the caller without buffering, signing, or automatic retry.
