{s}omniamarkets

@somnia-chain/markets-sdk


@somnia-chain/markets-sdk / index / TraderConfig

Interface: TraderConfig

Defined in: trade.ts:69

Properties

walletClient?

optional walletClient?: object

Defined in: trade.ts:74

A pre-built signer (e.g. a browser/wagmi wallet over an injected provider). Only needed when the SDK can't sign locally — with privateKey / a local account, the SDK signs itself and sends over the client's WebSocket via realtime_sendRawTransaction (send + confirm in one round-trip).


account?

optional account?: `0x${string}` | Account

Defined in: trade.ts:76

A local signing account (e.g. from viem's privateKeyToAccount).


privateKey?

optional privateKey?: `0x${string}`

Defined in: trade.ts:78

Private key — the SDK derives the account.


publicClient?

optional publicClient?: object

Defined in: trade.ts:80

Read client for allowance/receipts. Defaults to the client's WebSocket client.


decimals?

optional decimals?: number

Defined in: trade.ts:82

Outcome/collateral decimals (default 6).


gas?

optional gas?: bigint

Defined in: trade.ts:84

Default gas ceiling per tx.