> For the complete documentation index, see [llms.txt](https://docs.intentsprotocol.xyz/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.intentsprotocol.xyz/readme.md).

# BCH Intents SDK

**BCH Intents SDK** is a powerful, modular TypeScript toolkit designed to bring intent-based trading and Just-In-Time (JIT) liquidity to the Bitcoin Cash (BCH) network.

## What are Intents?

In traditional DeFi (like AMMs), users construct and sign explicit *transactions* containing exactly how a trade should be routed. This forces the user to accept high slippage, pay network fees for failed transactions, and exposes them to Miner Extractable Value (MEV) like front-running and sandwich attacks.

With an **intent-based architecture**, users do not sign transactions. Instead, they cryptographically sign an **intent** — a message expressing what they have, what they want, and the constraints of the trade (e.g. minimum price, expiry time).

1. **User signs an Intent:** "I have 5,000 sats of BCH and I want at least 4,500 sats of Token X."
2. **Solvers compete:** Professional market makers ("solvers") monitor the network and compete to fill this intent.
3. **Best price wins:** Solvers construct the actual transaction, paying the network fee and sourcing the liquidity from their own wallets (Just-In-Time liquidity). The solver who can give the user the best price wins the trade.

## Key Features

* **Dutch Auctions on UTXOs**: A breakthrough implementation of decaying-price market orders natively on BCH using recursive covenants.
* **MEV Protection**: Since users don't submit swap transactions to the public mempool, they cannot be front-run.
* **No Slippage Surprises**: Users are mathematically guaranteed to receive at least their specified minimum return.
* **Just-In-Time (JIT) Liquidity**: No need for fragmented liquidity pools. Solvers can use their own inventory or bridge liquidity from centralized exchanges.
* **Native CashTokens**: Built from the ground up for the Bitcoin Cash ecosystem, fully supporting standard BCH and CashTokens (e.g. MUSD, PUSD).
* **Frontend Monetization**: Built-in covenant-enforced fee system allows DEXs and wallets to collect guaranteed revenue on every swap without backend infrastructure.
* **Wallet Agnostic**: Connect any BCH wallet using `WalletConnectAdapter` (v0.2.0, industry-standard WC v2 protocol), `WizardConnectAdapter` (NIP-44 Nostr), or server-side headless wallets via `MainnetJSAdapter`.

## Why Use the SDK?

The BCH Intents SDK abstracts away the extreme complexity of compiling CashScript covenants, managing introspection opcodes, and communicating with solver networks.

Whether you are building a decentralized exchange aggregator, a Telegram trading bot, or writing your own solver algorithms, the SDK provides strongly-typed, production-ready primitives.

***

**Next:** Check out the [Quickstart Guide](/quickstart.md) to build your first Intent.
