> For the complete documentation index, see [llms.txt](https://titan-exchange.gitbook.io/titan/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://titan-exchange.gitbook.io/titan/developer-doc/swap-api/reference/types.md).

# Types Reference

All type definitions live inline on the page where they're used. This page is an index for quick navigation.

**Field names are `camelCase` on the wire (MessagePack) unless otherwise specified.** Rust SDK types use `snake_case` with serde renaming.

***

## Wire protocol & common types

Defined on [Wire Protocol](/titan/developer-doc/swap-api/reference/wire-protocol.md):

* **`Pubkey`** — 32-byte Solana public key
* **`AccountMeta`** — compact account descriptor (`p`, `s`, `w`)
* **`Instruction`** — on-chain instruction (`p`, `a`, `d`)
* **`SwapMode`** — `ExactIn` or `ExactOut`
* **`ClientRequest`** — request envelope with `id` and `data`
* **`ServerMessage`** — `Response`, `Error`, `StreamData`, or `StreamEnd`
* **`ResponseSuccess`** / **`ResponseError`** — success and error response types
* **`StreamData`** / **`StreamEnd`** / **`StreamStart`** — stream lifecycle types

***

## Server info types

Defined on [GetInfo](/titan/developer-doc/swap-api/reference/direct/get-info.md):

* **`ServerInfo`** — protocol version and server settings
* **`VersionInfo`** — `major`, `minor`, `patch`
* **`ServerSettings`** — quote update, swap, transaction, and connection settings
* **`BoundedValueWithDefault<T>`** — `min`, `max`, `default`
* **`QuoteUpdateSettings`** / **`SwapSettings`** / **`TransactionSettings`** / **`ConnectionSettings`**

***

## Request types

Defined on [NewSwapQuoteStream](/titan/developer-doc/swap-api/reference/direct/new-swap-quote-stream.md):

* **`SwapQuoteRequest`** — `swap` + `transaction` + `update`
* **`SwapParams`** — input/output mints, amount, slippage, routing filters
* **`TransactionParams`** — wallet key, fee config, token account options
* **`QuoteUpdateParams`** — stream interval and quote count

***

## Quote & stream data types

Defined on [NewSwapQuoteStream](/titan/developer-doc/swap-api/reference/direct/new-swap-quote-stream.md#stream-updates):

* **`SwapQuotes`** — quote batch with provider-keyed `quotes` map
* **`SwapRoute`** — single route with instructions, ALTs, expiry, compute budget
* **`RoutePlanStep`** — one hop in a multi-step route
* **`PlatformFee`** — `amount` and `fee_bps`

***

## Discovery types

Defined on [GetVenues / ListProviders](/titan/developer-doc/swap-api/reference/direct/venues-providers.md):

* **`VenueInfo`** — venue labels and optional program IDs
* **`ProviderInfo`** — provider id, name, kind, optional icon
* **`ProviderKind`** — `"DexAggregator"` or `"RFQ"`

***

## Stop stream types

Defined on [StopStream](/titan/developer-doc/swap-api/reference/direct/stop-stream.md):

* **`StopStreamRequest`** — stream ID to stop
* **`StopStreamResponse`** — confirmed stream ID

***

## Related pages

* [Wire Protocol](/titan/developer-doc/swap-api/reference/wire-protocol.md) — encoding rules, common types, and message envelope types
* [Connection & Negotiation](/titan/developer-doc/swap-api/reference/direct/connection.md) — WebSocket setup and authentication
* [NewSwapQuoteStream](/titan/developer-doc/swap-api/reference/direct/new-swap-quote-stream.md) — request, response, and stream data types
* [GetInfo](/titan/developer-doc/swap-api/reference/direct/get-info.md) — server info and settings types
* [GetVenues / ListProviders](/titan/developer-doc/swap-api/reference/direct/venues-providers.md) — discovery types
* [StopStream](/titan/developer-doc/swap-api/reference/direct/stop-stream.md) — stop stream types
