@barfinex/config
v1.0.8
Published
Configuration management module for the Barfinex ecosystem. Provides typed configuration interfaces, file-based loading, environment variable interpolation, and NestJS service integration.
Maintainers
Readme
@barfinex/config
Centralized configuration and environment management for the Barfinex ecosystem — the open platform for algorithmic trading where data, signals, and decisions flow in one controllable system.
This library provides a unified, type-safe way to load and validate configuration across Barfinex services (Provider, Detector, connectors, and apps). One source of truth for env vars and settings means fewer surprises in production and faster onboarding.
What it does
- Typed configuration —
ConfigInterfaceandConfigServicefor consistent contracts across services. - Environment & files — load from environment variables and optional config files with validation.
- NestJS integration —
ConfigModuleplugs into your Nest app so any service can inject config. - Startup safety — validate required keys before the app starts; fail fast with clear errors.
Use it in Provider, Detector, or any Barfinex microservice so they all speak the same configuration language.
Installation
npm install @barfinex/configor
yarn add @barfinex/configWhat's included
| Export | Purpose |
|--------|--------|
| ConfigModule | NestJS module for DI and config loading. |
| ConfigService | Service to read and validate env/config values. |
| ConfigInterface | TypeScript interfaces for configuration contracts. |
Documentation
- Barfinex overview — First Steps, Architecture, Glossary.
- Provider & deployment — Installation provider, Docker Compose for Provider, Understanding Provider Logs.
- Detector — Installation detector.
- Studio — Terminal Configuration, Registering Provider in Studio.
- APIs & troubleshooting — Building with the API, Provider API reference, Typical problems and solutions.
Contributing
Ideas and PRs are welcome: open an issue or submit a pull request. Join the community: Telegram · GitHub.
License
Licensed under the Apache License 2.0 with additional terms. Attribution to Barfin Network Limited and a link to https://barfinex.com are required. Commercial use requires explicit permission. See LICENSE and the Barfinex site for details.
