Skip to main content

Class: KandelConfiguration

Title

Provides recommended configuration for deploying Kandel instances.

Constructors​

constructor​

β€’ new KandelConfiguration(configurationOverride?): KandelConfiguration

Constructor to provide specific configuration.

Parameters​

NameTypeDescription
configurationOverride?PartialKandelConfigurationOptional configuration overrides that replace the values from the current configuration in configuration.

Returns​

KandelConfiguration

Defined in​

@mangrovedao/mangrove.js/src/kandel/kandelConfiguration.ts:19

Properties​

rawConfiguration​

β€’ rawConfiguration: PartialKandelConfiguration

Defined in​

@mangrovedao/mangrove.js/src/kandel/kandelConfiguration.ts:14

Methods​

getMostSpecificConfig​

β–Έ getMostSpecificConfig(networkName, baseId, quoteId, tickSpacing): KandelNetworkConfiguration & Partial<KandelMarketConfiguration>

Gets the most specific available config for the network and the base/quote pair.

Parameters​

NameTypeDescription
networkNamestringThe name of the network.
baseIdstringThe ID of the base token.
quoteIdstringThe ID of the quote token.
tickSpacingnumberThe tick spacing of the market.

Returns​

KandelNetworkConfiguration & Partial<KandelMarketConfiguration>

The most specific configuration available for the network and the base/quote pair.

Defined in​

@mangrovedao/mangrove.js/src/kandel/kandelConfiguration.ts:36


getConfigForBaseQuoteTickSpacing​

β–Έ getConfigForBaseQuoteTickSpacing(networkName, baseId, quoteId, tickSpacing): KandelNetworkConfiguration & KandelMarketConfiguration

Gets the config for the network and the base/quote/tickSpacing set.

Parameters​

NameTypeDescription
networkNamestringThe name of the network.
baseIdstringThe ID of the base token.
quoteIdstringThe ID of the quote token.
tickSpacingnumberThe tick spacing of the market.

Returns​

KandelNetworkConfiguration & KandelMarketConfiguration

The configuration for the network and the base/quote/tickSpacing set.

Throws

If the full config is not available for the network and the base/quote/tickSpacing set.

Defined in​

@mangrovedao/mangrove.js/src/kandel/kandelConfiguration.ts:82


getConfig​

β–Έ getConfig(market): KandelNetworkConfiguration & KandelMarketConfiguration

Gets the config for the market.

Parameters​

NameTypeDescription
marketMarketThe market.

Returns​

KandelNetworkConfiguration & KandelMarketConfiguration

The configuration for the market.

Throws

If the full config is not available for the market.

Defined in​

@mangrovedao/mangrove.js/src/kandel/kandelConfiguration.ts:127


getConfiguredMarkets​

β–Έ getConfiguredMarkets(mgv): { base: string ; quote: string ; tickSpacing: number }[]

Gets the list of markets that are configured for the network for the given Mangrove instance.

Parameters​

NameTypeDescription
mgvMangroveThe Mangrove instance.

Returns​

{ base: string ; quote: string ; tickSpacing: number }[]

The list of markets that are configured for the network for the given Mangrove instance.

Defined in​

@mangrovedao/mangrove.js/src/kandel/kandelConfiguration.ts:142


getConfiguredMarketsForNetwork​

β–Έ getConfiguredMarketsForNetwork(networkName): { base: string ; quote: string ; tickSpacing: number }[]

Gets the list of markets that are configured for the network.

Parameters​

NameTypeDescription
networkNamestringThe name of the network.

Returns​

{ base: string ; quote: string ; tickSpacing: number }[]

The list of markets that are configured for the network.

Defined in​

@mangrovedao/mangrove.js/src/kandel/kandelConfiguration.ts:150


getNetworks​

β–Έ getNetworks(): string[]

Gets the networks with some configuration.

Returns​

string[]

Defined in​

@mangrovedao/mangrove.js/src/kandel/kandelConfiguration.ts:171

  • Constructors
    • constructor
  • Properties
    • rawConfiguration
  • Methods
    • getMostSpecificConfig
    • getConfigForBaseQuoteTickSpacing
    • getConfig
    • getConfiguredMarkets
    • getConfiguredMarketsForNetwork
    • getNetworks