add coinpaprika config
This commit is contained in:
@@ -4,7 +4,7 @@ import {
|
||||
EncryptionConfig,
|
||||
InvoiceConfig,
|
||||
JwtConfig,
|
||||
KrakenConfig,
|
||||
CoinPaprikaConfig,
|
||||
MulterConfig,
|
||||
OrderConfig,
|
||||
PostgresConfig,
|
||||
@@ -163,10 +163,10 @@ export const getCoingeckoConfig = (): CoingeckoConfig => {
|
||||
};
|
||||
};
|
||||
|
||||
export const getKrakenConfig = (): KrakenConfig => {
|
||||
export const getCoinPaprikaConfig = (): CoinPaprikaConfig => {
|
||||
return {
|
||||
apiBaseUrl: env('KRAKEN_API_BASE_URL'),
|
||||
rateFetchTimeoutMs: envInt('KRAKEN_RATE_FETCH_TIMEOUT_MS')
|
||||
apiBaseUrl: env('COINPAPRIKA_API_BASE_URL'),
|
||||
rateFetchTimeoutMs: envInt('COINPAPRIKA_RATE_FETCH_TIMEOUT_MS')
|
||||
};
|
||||
};
|
||||
|
||||
@@ -214,7 +214,7 @@ export default () => ({
|
||||
app: getAppConfig(),
|
||||
jwt: getJwtConfig(),
|
||||
coingecko: getCoingeckoConfig(),
|
||||
kraken: getKrakenConfig(),
|
||||
coinPaprika: getCoinPaprikaConfig(),
|
||||
encryption: getEncryptionConfig(),
|
||||
shopSettings: getShopSettingsConfig(),
|
||||
order: getOrderConfig(),
|
||||
|
||||
@@ -246,12 +246,12 @@ class EnvironmentVariables {
|
||||
|
||||
@IsNotEmpty()
|
||||
@IsString()
|
||||
KRAKEN_API_BASE_URL: string;
|
||||
COINPAPRIKA_API_BASE_URL: string;
|
||||
|
||||
@IsNotEmpty()
|
||||
@IsNumber()
|
||||
@Min(1)
|
||||
KRAKEN_RATE_FETCH_TIMEOUT_MS: number;
|
||||
COINPAPRIKA_RATE_FETCH_TIMEOUT_MS: number;
|
||||
|
||||
@IsNotEmpty()
|
||||
@IsNumber()
|
||||
|
||||
@@ -87,7 +87,7 @@ export interface CoingeckoConfig {
|
||||
rateFetchTimeoutMs: number;
|
||||
}
|
||||
|
||||
export interface KrakenConfig {
|
||||
export interface CoinPaprikaConfig {
|
||||
apiBaseUrl: string;
|
||||
rateFetchTimeoutMs: number;
|
||||
}
|
||||
@@ -112,7 +112,7 @@ export interface Config {
|
||||
postgres: PostgresConfig;
|
||||
jwt: JwtConfig;
|
||||
coingecko: CoingeckoConfig;
|
||||
kraken: KrakenConfig;
|
||||
coinPaprika: CoinPaprikaConfig;
|
||||
encryption: EncryptionConfig;
|
||||
shopSettings: ShopSettingsConfig;
|
||||
order: OrderConfig;
|
||||
|
||||
Reference in New Issue
Block a user