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

# svm venue: mswap

> 9 exports of the mswap venue integration in @eco-incorp/sauce/svm, including MSWAP_PROGRAM_ID, SWAP_GLOBAL_ID, M_MINT, M_TOKEN_PROGRAM, SWAP_M_ACCOUNT, mswap.

Solana venue integration `mswap` under `svm/venues/mswap`.

<Note>
  Generated from the type declarations shipped in `@eco-incorp/sauce` 0.99.4. Each entry shows the package authors' JSDoc and declaration for this SDK version. For runtime compatibility and deployed addresses, see [architecture and deployments](/programmable-transactions/sauce/architecture-and-deployments).
</Note>

### `MSWAP_PROGRAM_ID`

*Variable* · `sdk/dist/svm/venues/mswap/index.d.ts`

m0-foundation's ext\_swap router - `SVM_VENUE_PROGRAM_IDS['mswap']`.

```typescript theme={null}
MSWAP_PROGRAM_ID: Address<"MSwapi3WhNKMUGm9YrxGhypgUEt7wYQH3ZgG32XoWzH">
```

### `SWAP_GLOBAL_ID`

*Variable* · `sdk/dist/svm/venues/mswap/index.d.ts`

`ext_swap`'s own global (PDA seed `b"global"` under `MSWAP_PROGRAM_ID`, bump 253 - derived offline, cross-checked live 2026-07-31).

```typescript theme={null}
SWAP_GLOBAL_ID: Address<"6U4ZZZkftbuHxjRDHUfh83M9zG66aAAXDV3xTRX7yePr">
```

### `M_MINT`

*Variable* · `sdk/dist/svm/venues/mswap/index.d.ts`

The one `$M` mint every whitelisted extension wraps/unwraps against.

```typescript theme={null}
M_MINT: Address<"mzerojk9tg56ebsrEAhfkyc9VgKjTW2zDqp6C5mhjzH">
```

### `M_TOKEN_PROGRAM`

*Variable* · `sdk/dist/svm/venues/mswap/index.d.ts`

`$M` is always Token2022 (`m_ext`'s `Wrap`/`Unwrap` hard-type `m_token_program: Program<Token2022>`).

```typescript theme={null}
M_TOKEN_PROGRAM: Address<"TokenzQdBNbLqP5VEhdkAS6EPFLC1PHnBqCXEpPxuEb">
```

### `SWAP_M_ACCOUNT`

*Variable* · `sdk/dist/svm/venues/mswap/index.d.ts`

`SwapGlobal`'s own ATA of `$M` (owner = `SWAP_GLOBAL_ID`) - the transient per-trade holding account (see module doc).

```typescript theme={null}
SWAP_M_ACCOUNT: Address<"7dM9YCAbN9XGixnaP7wnyQDVZH6BVy6HPFeZr1SWVNka">
```

### `mswap`

*Variable* · `sdk/dist/svm/venues/mswap/index.d.ts`

Family facade for the recipe orchestrator.

```typescript theme={null}
mswap: {
    slug: string;
    programId: Address<"MSwapi3WhNKMUGm9YrxGhypgUEt7wYQH3ZgG32XoWzH">;
    fetchPoolConfig: typeof fetchMSwapPoolConfig;
}
```

### `mswapPoolKey`

*Function* · `sdk/dist/svm/venues/mswap/index.d.ts`

Mint synthetic per-directed-pair discovery key (mirrors `sanctumInfinityPoolKey`).

```typescript theme={null}
export declare function mswapPoolKey(inMint: Address, outMint: Address): Address;
```

### `fetchMSwapPoolConfig`

*Function* · `sdk/dist/svm/venues/mswap/index.d.ts`

Off-chain, once per requested (inMint, outMint): read the LIVE
`SwapGlobal` whitelist, resolve both legs' own `ExtGlobalV2` (gating
`yield_variant`/`wrap_authorities` per the module doc), and derive every
PDA the swap CPI needs. Self-drops (throws) on ANY of: either mint not
whitelisted, either leg a "ScaledUi" deploy, either leg missing
`SWAP_GLOBAL_ID` from its own `wrap_authorities` - all LIVE checks, never
a hardcoded mint exclusion.

```typescript theme={null}
export declare function fetchMSwapPoolConfig(load: AccountLoader, pool: Address): Promise<MSwapPoolConfig>;
```

### `MSwapPoolConfig`

*Interface* · `sdk/dist/svm/venues/mswap/index.d.ts`

```typescript theme={null}
export interface MSwapPoolConfig extends PoolConfig {
    venue: typeof SLUG;
    fromMint: Address;
    toMint: Address;
    fromProgramId: Address;
    toProgramId: Address;
    fromTokenProgram: Address;
    toTokenProgram: Address;
    fromGlobal: Address;
    toGlobal: Address;
    fromMVaultAuth: Address;
    toMVaultAuth: Address;
    fromMintAuthority: Address;
    toMintAuthority: Address;
    fromMVault: Address;
    toMVault: Address;
}
```
