Interface PremiaConfig

Hierarchy

Properties

apiBaseUri?: string

The base URL to use for fetching data from the Premia API.

Default Value

apiBaseUri

See

https://docs.premia.finance/api

apiKey?: string

The API key to use for fetching data from the Premia API.

Default Value

apiKey

See

https://docs.premia.finance/api/authentication

apiWsUri?: string

The base websocket URL to use for streaming data from the Premia API.

Default Value

apiWsUri

See

https://docs.premia.finance/api

chainId?: number

The chain ID to use for interacting with main exchange contracts.

Default Value

chainId

coingeckoBaseUri?: string

The base URL to use for fetching data from the Coingecko API.

Default Value

coingeckoBaseUri

See

https://www.coingecko.com/api/documentations/v3

coingeckoProApiKey?: string

The API Key to use for fetching data from the Coingecko Pro API.

See

https://www.coingecko.com/api/documentations/v3

disableCache?: boolean

A flag to disable usage of the default cache.

Default Value

disableCache

novaPhrase?: string

A string representing a wallet's secret phrase for use with the novaProvider, to instantiate the novaSigner. Ignored if novaPrivateKey or novaSigner is provided.

novaPrivateKey?: string

A string representing a wallet's private key for use with the novaProvider, to instantiate the novaSigner. Ignored if novaSigner is provided.

novaProvider?: string | Provider

An ethers.js provider instance or a string representing a JSON-RPC URL. This provider is used for interacting with the orderbook contract. If not provided, a default connection string will be used.

Default Value

novaProvider

novaSigner?: Signer

An ethers.js signer instance for transacting with the orderbook contract. If no novaSigner, novaPrivateKey, or novaPhrase is provided, the novaProvider's default signer will be used.

Default Value

Premia.novaProvider.getSigner

orderbookAddress?: string

The address of the OrderbookStreamer contract (on Arbitrum Nova).

Default Value

Premia.orderbookAddress

See

https://docs.premia.finance/contracts/orderbook

phrase?: string

A string representing a wallet's secret phrase for use with the provider, to instantiate the signer. Ignored if privateKey or signer is provided.

poolFactoryAddress?: string

The address of the PoolFactory contract (on Arbitrum).

Default Value

Premia.poolFactoryAddress

See

https://docs.premia.finance/contracts/pools

privateKey?: string

A string representing a wallet's private key for use with the provider, to instantiate the signer. Ignored if signer is provided.

provider?: string | Provider

An ethers.js provider instance or a string representing a JSON-RPC URL. This provider is used for interacting with the main exchange contracts. If not provided, a default connection string will be used.

Default Value

provider

signer?: Signer

An ethers.js signer instance for transacting with the main exchange contracts. If no signer, privateKey, or phrase is provided, the provider's default signer will be used.

Default Value

Premia.provider.getSigner

skipSubgraph?: boolean

A flag to disable usage of the subgraph, and instead use smart contract data where available.

subgraphUri?: string

The subgraph URL to use for fetching indexed contract data.

Default Value

Premia.subgraph.uri

See

https://docs.premia.finance/api/subgraph

useTestnet?: boolean

The chain ID to use for interacting with main exchange contracts.

Default Value

useTestnet

userSettingsAddress?: string

The address of the UserSettings contract (on Arbitrum).

Default Value

Premia.userSettingsAddress

See

https://docs.premia.finance/contracts/pools

vaultRegistryAddress?: string

The address of the VaultRegistry contract (on Arbitrum).

Default Value

Premia.vaultRegistryAddress

See

https://docs.premia.finance/contracts/vaults

vxPremiaAddress?: string

The address of the VxPremia contract (on Arbitrum).

Default Value

Premia.vxPremiaAddress

Generated using TypeDoc