Doramagic Project Pack · Human Manual
OpenBB
The OpenBB Platform is an open-source data integration foundation for financial data, designed to provide unified access to various financial data sources through a standardized Python int...
Introduction to OpenBB Platform
Related topics: Installation Guide, System Architecture
Continue reading this section for the full explanation and source context.
Continue reading this section for the full explanation and source context.
Continue reading this section for the full explanation and source context.
Continue reading this section for the full explanation and source context.
Related Pages
Related topics: Installation Guide, System Architecture
Introduction to OpenBB Platform
Overview
The OpenBB Platform is an open-source data integration foundation for financial data, designed to provide unified access to various financial data sources through a standardized Python interface. It enables developers and analysts to access market data, economic indicators, company fundamentals, and more through a consistent API. Sources: README.md
The platform follows a "connect once, consume everywhere" architecture, allowing seamless integration between different components and enabling data to be consumed across multiple interfaces including Python SDK, REST API, and the OpenBB Workspace enterprise UI. Sources: README.md
Architecture
The OpenBB Platform consists of several interconnected layers that work together to deliver financial data to end users.
System Architecture Diagram
graph TD
A[OpenBB Workspace] <--> B[OpenBB Platform REST API]
B <--> C[Core Engine]
C <--> D[Extensions]
C <--> E[Data Providers]
D --> F[Technical Analysis]
D --> G[Economy]
D --> H[News]
D --> I[Commodity]
D --> J[Derivatives]
D --> K[Regulators]
D --> L[MCP Server]
E --> M[FMP]
E --> N[IMF]
E --> O[US Government]Key Components
| Component | Description | Type |
|---|---|---|
| Core Engine | Central processing unit handling requests and data normalization | Core |
| Extensions | Domain-specific functionality modules | Plugin |
| Providers | Data source integrations (FMP, IMF, Government US, etc.) | Plugin |
| REST API | FastAPI-based HTTP interface for programmatic access | Interface |
| Python SDK | Native Python interface via obb object | Interface |
| MCP Server | Model Context Protocol server for AI agent integration | Extension |
Installation
Python Package Installation
The primary method to install OpenBB Platform is via pip:
pip install openbb
After installation, you can immediately start using the platform:
from openbb import obb
output = obb.equity.price.historical("AAPL")
df = output.to_dataframe()
Sources: README.md
Local Development Setup
For local development with source code access, the following requirements must be met:
- Git
- Python 3.10 - 3.13
- Virtual Environment with
poetryinstalled - Local copy of the GitHub repository
To install for local development:
- Activate your virtual environment
- Navigate to the
openbb_platformfolder - Run
python dev_install.py -eto install all packages in editable mode
Sources: openbb_platform/README.md
Python SDK Usage
Basic Usage
The OpenBB Platform provides a unified obb object for all operations:
from openbb import obb
# Fetch equity historical data
result = obb.equity.price.historical("AAPL", start_date="2023-01-01")
df = result.to_dataframe()
Setting API Keys
Many data providers require API keys for authentication:
from openbb import obb
obb.user.credentials.fred_api_key = "REPLACE_ME"
obb.user.credentials.polygon_api_key = "REPLACE_ME"
Sources: openbb_platform/README.md
REST API
The OpenBB Platform includes a ready-to-use REST API built with FastAPI. To start the API server:
uvicorn openbb_core.api.rest_api:app --host 0.0.0.0 --port 8000 --reload
API documentation is available under /docs endpoint. Sources: openbb_platform/README.md
API Configuration
Runtime settings and configurations for the REST API can be adjusted through system settings. See the official documentation for detailed configuration options.
Extensions Ecosystem
Extensions provide domain-specific functionality and can be installed independently. Each extension follows the same installation pattern via pip.
Available Extensions
| Extension | Package Name | Description |
|---|---|---|
| Technical Analysis | openbb-technical | Technical analysis tools, indicators, and oscillators |
| Economy | openbb-economy | Global macroeconomic data access |
| News | openbb-news | News data integration |
| Commodity | openbb-commodity | Commodity-related data and commands |
| Derivatives | openbb-derivatives | Derivatives market data |
| Regulators | openbb-regulators | Data from global market regulators |
| MCP Server | openbb-mcp-server | Model Context Protocol server for AI agents |
Extension Installation
Install any extension using pip:
pip install openbb-technical
pip install openbb-economy
pip install openbb-news
Sources: openbb_platform/extensions/technical/README.md, openbb_platform/extensions/economy/README.md, openbb_platform/extensions/news/README.md
MCP Server Extension
The MCP (Model Context Protocol) Server extension allows OpenBB Platform routes to be exposed as tools for AI agents. It supports inline MCP configuration for granular control:
from openbb_mcp_server.models.mcp_config import MCPConfigModel
Configuration properties include:
expose(Optional[bool]): Hide/show routes from MCP servermcp_type(Optional[MCPType]): Classify as"tool","resource", or"resource_template"methods(Optional[list[HTTPMethod]]): Specify HTTP methods to expose
Sources: openbb_platform/extensions/mcp_server/README.md
Data Providers
Providers are integrations that connect to external data sources. They can be installed as separate packages.
Provider Installation
Providers are installed via pip and then registered with the platform:
pip install openbb-fmp
pip install openbb-imf
pip install openbb-us-government
After installation, rebuild Python static assets:
openbb-build
Sources: openbb_platform/providers/fmp/README.md, openbb_platform/providers/imf/README.md
Official Providers
| Provider | Package | Description |
|---|---|---|
| Financial Modeling Prep | openbb-fmp | Company fundamentals, stock data, financial statements |
| IMF | openbb-imf | International Monetary Fund data via SDMX API |
| US Government | openbb-us-government | US Government data from data.gov |
US Government Provider Coverage
The US Government provider covers:
obb.commodity.psd_reportobb.commodity.psd_dataobb.commodity.weather_bulletinsobb.fixed_income.government.treasury_auctionsobb.fixed_income.government.treasury_prices
All covered services require no registration. Sources: openbb_platform/providers/government_us/README.md
IMF Provider Implementation
The IMF provider uses SDMX API to access dataflows. Key implementation details:
- User input validation via constraints API for each dimension
- Cached metadata contains all potential parameter values
- Network requests made when code lists are not included in cache
Sources: openbb_platform/providers/imf/README.md
Integration with OpenBB Workspace
OpenBB Workspace is an enterprise UI that complements the open-source data platform. The platform's architecture enables seamless integration between the two components.
Data Flow
graph LR
A[OpenBB Platform] -->|Custom Backend| B[OpenBB Workspace]
B -->|Visualization| C[Analyst Dashboard]
A -->|REST API| D[Third-party Applications]Connecting Platform to Workspace
- Start the API server with
openbb-api(starts FastAPI on localhost port 6900) - Add the server to OpenBB Workspace
- Access widgets and data exploration tools through the dashboard
Sources: openbb_platform/providers/imf/README.md
CLI Integration
The OpenBB Platform can be accessed via the command-line interface:
pip install openbb-cli
openbb
Sources: cli/README.md
Development with Cookiecutter
For developers creating new extensions or providers, the OpenBB Cookiecutter template provides a standardized project structure:
pip install openbb-cookiecutter
openbb-cookiecutter
Development workflow:
- Generate project from template
- Create Python environment for the project
- Install with
pip install -e . - Trigger static file generation with
openbb-build - Import package or start API
Sources: cookiecutter/README.md
Getting Help and Contributing
Documentation
Complete documentation is available at https://docs.openbb.co:
Community and Support
| Channel | Link |
|---|---|
| Discord | openbb.co/discord |
| GitHub Issues | GitHub Issues |
| Social Media | openbb.co/links |
Issue Templates
License and Disclaimer
The OpenBB Platform is distributed under the AGPLv3 License.
Disclaimer: Trading in financial instruments involves high risks including the risk of losing some, or all, of your investment amount. The data contained in the Open Data Platform is not necessarily accurate. OpenBB and any provider of data will not accept liability for any loss or damage as a result of trading or reliance on the information displayed.
Sources: README.md
Sources: README.md
Installation Guide
Related topics: Introduction to OpenBB Platform, Command Line Interface
Continue reading this section for the full explanation and source context.
Continue reading this section for the full explanation and source context.
Continue reading this section for the full explanation and source context.
Continue reading this section for the full explanation and source context.
Related Pages
Related topics: Introduction to OpenBB Platform, Command Line Interface
Installation Guide
This guide provides comprehensive instructions for installing and configuring the OpenBB Platform ecosystem. The installation process supports multiple deployment methods including the Python Package (ODP), CLI interface, Platform extensions, and provider integrations.
Overview
The OpenBB Platform consists of several interconnected components that can be installed independently or together. The architecture supports modular installation, allowing users to install only the components they need for their specific use case.
graph TD
A[OpenBB Platform Core] --> B[CLI Interface]
A --> C[Python API]
A --> D[Extensions]
A --> E[Providers]
D --> D1[News Extension]
D --> D2[Commodity Extension]
D --> D3[MCP Server]
E --> E1[CFTC Provider]
E --> E2[Multpl Provider]
E --> E3[Congress Gov Provider]Python Package Installation
The OpenBB Platform Python Package (ODP) serves as the core installation method for all components.
Standard Installation via PyPI
The recommended method for installing the OpenBB Platform is through PyPI using pip:
pip install openbb
Sources: README.md
Platform Installation
The Platform package includes the core libraries and dependencies required for data analysis and financial computations. After installation, the Platform can be accessed programmatically:
from openbb import obb
# Example: Fetch S&P 500 multiples data
data = obb.index.sp500_multiples()
Sources: openbb_platform/providers/multpl/README.md
CLI Installation
The OpenBB CLI provides a command-line interface for interacting with the Platform.
Installation via PyPI
pip install openbb-cli
Sources: cli/README.md
Deployment
After installation, deploy the OpenBB Platform CLI by running:
openbb
Sources: cli/README.md
Installation Verification
A successful installation produces the following output:
Extension Installation
Extensions extend the core Platform functionality with specialized features. Each extension is distributed as a separate Python package installable via pip.
News Extension
The News Extension provides news aggregation capabilities for the OpenBB Platform.
pip install openbb-news
Sources: openbb_platform/extensions/news/README.md
Commodity Extension
The Commodity Extension provides commands for commodity-related financial data.
pip install openbb-commodity
Sources: openbb_platform/extensions/commodity/README.md
MCP Server Extension
The MCP Server Extension exposes OpenBB Platform endpoints as Model Context Protocol (MCP) tools, enabling AI assistant integration.
pip install openbb-mcp-server
Sources: openbb_platform/extensions/mcp_server/README.md
Extension Configuration via MCP
The MCP Server extension supports inline configuration using the MCPConfigModel:
from openbb_mcp_server.models.mcp_config import MCPConfigModel
The configuration supports the following properties:
| Property | Type | Description |
|---|---|---|
expose | Optional[bool] | Set to False to hide a route from the MCP server |
mcp_type | Optional[MCPType] | Classify as "tool", "resource", or "resource_template" |
methods | Optional[list[HTTPMethod]] | Specify HTTP methods to expose |
Sources: openbb_platform/extensions/mcp_server/README.md
Provider Installation
Providers are data source integrations that supply financial and economic data to the Platform.
Available Providers
| Provider | Package | Command |
|---|---|---|
| CFTC | openbb-cftc | pip install openbb-cftc |
| Multpl | openbb-multpl | pip install openbb-multpl |
| Congress Gov | openbb-congress-gov | Included in Platform core |
Sources: openbb_platform/providers/cftc/README.md
CFTC Provider Usage
The CFTC provider provides Commitments of Traders (COT) data:
from openbb import obb
# Search for commodities
search_results = obb.cftc.cot_search(query="gold")
print(search_results.to_df())
# Fetch specific report
report = obb.cftc.cot(code="CFTC_088695", measure="percent_of_oi", limit=4)
print(report.to_df().T)
Sources: openbb_platform/providers/cftc/README.md
Multpl Provider Usage
The Multpl provider provides S&P 500 data:
from openbb import obb
data = obb.index.sp500_multiples()
Sources: openbb_platform/providers/multpl/README.md
Congress Gov Provider Usage
The Congress Gov provider provides US Congressional data:
from openbb import obb
# Get recent bills
bills = obb.uscongress.bills(limit=10)
# Get bill details
bill_info = obb.uscongress.bill_info(bill_url="119/hr/1")
Sources: openbb_platform/providers/congress_gov/README.md
REST API Deployment
The Platform can be deployed as a REST API for remote access and integration with other applications.
Starting the API Server
openbb-api
This starts the server over localhost, making the Platform accessible via HTTP endpoints.
Sources: openbb_platform/providers/cftc/README.md
Platform Connection
To connect to the Platform from external applications:
- Navigate to the "Apps" tab
- Click on "Connect backend"
- Fill in the connection form:
- Name: Open Data Platform
- URL:
http://127.0.0.1:6900
- Click "Test" to verify connectivity
- Click "Add" to complete the connection
Sources: README.md
Development Environment Setup
For developers contributing to the OpenBB Platform, a cookiecutter template is available to scaffold new extensions and providers.
Cookiecutter Template
- Install the cookiecutter template:
pip install openbb-cookiecutter
- Navigate to the desired output location and run:
openbb-cookiecutter
- Create a new Python environment for the project.
- Install the generated package:
pip install -e .
- Generate Python static files:
openbb-build
- Import the package or start the API.
Sources: cookiecutter/README.md
Installation Workflow
graph TD
A[Start Installation] --> B{Select Installation Type}
B -->|Python Package| C[pip install openbb]
B -->|CLI| D[pip install openbb-cli]
B -->|Extensions| E[Select Required Extensions]
B -->|Providers| F[Select Required Providers]
E --> G[pip install openbb-{extension}]
F --> H[pip install openbb-{provider}]
C --> I{Additional Components?}
D --> I
G --> J[Verify Installation]
H --> J
I -->|Yes| E
I -->|No| J
J --> K[Configure Environment]
K --> L[Start Using OpenBB]Installation Sources Reference
| Component | Installation Source | Documentation |
|---|---|---|
| Core Platform | PyPI (pip install openbb) | docs.openbb.co |
| CLI | PyPI (pip install openbb-cli) | docs.openbb.co/cli |
| Platform Extensions | Individual PyPI packages | docs.openbb.co/platform |
| Cookiecutter | PyPI (pip install openbb-cookiecutter) | docs.openbb.co/python/developer |
Troubleshooting
Common Installation Issues
- Dependency Conflicts: Ensure Python 3.8+ is installed and consider using a virtual environment
- Permission Errors: Use
--userflag or virtual environments to avoid system-wide installations - Network Issues: Verify PyPI connectivity and consider using mirrors if necessary
Verification Steps
After installation, verify the setup by importing the core module:
python -c "from openbb import obb; print(obb)"
For CLI verification:
openbb --version
Additional Resources
- User Documentation: docs.openbb.co
- Developer Documentation: docs.openbb.co/python/developer
- Platform Developer Guide: docs.openbb.co/platform/developer_guide/contributing
- Support: [email protected]
- General Inquiries: [email protected]
Sources: README.md
System Architecture
Related topics: Core Concepts, OBBject System
Continue reading this section for the full explanation and source context.
Continue reading this section for the full explanation and source context.
Continue reading this section for the full explanation and source context.
Continue reading this section for the full explanation and source context.
Related Pages
Related topics: Core Concepts, OBBject System
System Architecture
Overview
The OpenBB Platform is a modular, extensible investment research platform designed to provide financial data and analytics through multiple interfaces. The system architecture follows a plugin-based design pattern that separates core functionality from data providers and interface implementations.
Sources: openbb_platform/README.md
High-Level Architecture
The OpenBB Platform consists of three primary deployment targets:
| Layer | Component | Description |
|---|---|---|
| Core | Platform Core | Shared libraries, data models, provider registry, and query execution engine |
| Interface | CLI | Terminal-based interactive interface |
| Interface | Desktop | Cross-platform desktop application (Tauri-based) |
| Interface | REST API | FastAPI-based HTTP API server |
| Extension | MCP Server | Model Context Protocol integration for AI tooling |
| Extension | Platform API | Widgets and workspace applications |
Sources: cli/README.md, openbb_platform/README.md
Architecture Diagram
graph TD
subgraph "Interface Layer"
CLI[CLI<br>openbb command]
DESKTOP[Desktop App<br>Tauri + React]
API[REST API<br>FastAPI]
end
subgraph "Extension Layer"
MCP[MCP Server<br>Model Context Protocol]
PLATFORM_API[Platform API<br>Widgets & Apps]
end
subgraph "Core Layer"
APP[App Module<br>openbb_core.app]
REGISTRY[Provider Registry]
EXECUTOR[Query Executor]
end
subgraph "Provider Layer"
GOV_US[Government US Provider]
CFTC[CFTC Provider]
MULTPL[Multpl Provider]
NEWS[News Extension]
COMMODITY[Commodity Extension]
CUSTOM[Custom Providers]
end
CLI --> APP
DESKTOP --> APP
API --> APP
MCP --> APP
PLATFORM_API --> APP
APP --> REGISTRY
APP --> EXECUTOR
REGISTRY --> GOV_US
REGISTRY --> CFTC
REGISTRY --> MULTPL
REGISTRY --> NEWS
REGISTRY --> COMMODITY
REGISTRY --> CUSTOM
EXECUTOR --> REGISTRYComponent Details
Platform Core
The core module (openbb_core) contains the fundamental infrastructure for the entire platform:
- Data Models: Standardized schemas for financial data
- Provider Registry: Dynamic registration and discovery of data providers
- Query Executor: Handles request routing and execution across providers
- Authentication: API key management and credential handling
Sources: openbb_platform/README.md, openbb_platform/providers/README.md
Provider System
The provider architecture allows data sources to be implemented as pluggable extensions. Each provider follows a standardized structure:
openbb_platform/providers/<provider_name>/
├── README.md
├── pyproject.toml
├── poetry.lock
├── tests/
└── openbb_<provider_name>/
├── __init__.py
├── models/
│ └── <model>.py
└── utils/
└── <helper>.py
Sources: openbb_platform/providers/README.md
#### Supported Provider Categories
| Category | Examples | Functionality |
|---|---|---|
| Government Data | obb.fixed_income.government.treasury_auctions | US Treasury and regulatory data |
| Commodity | obb.commodity.psd_report, obb.commodity.weather_bulletins | Commodity market data |
| Futures/COT | obb.cftc.cot, obb.cftc.cot_search | CFTC Commitments of Traders |
| Market Indices | obb.index.sp500_multiples | Index and market multiples |
| News | News Extension | Financial news aggregation |
| Regulatory | Regulators Extension | Global market regulator data |
Sources: openbb_platform/providers/government_us/README.md, openbb_platform/providers/cftc/README.md, openbb_platform/providers/multpl/README.md
REST API Architecture
The FastAPI-based REST API provides programmatic access to all platform functionality:
app = FastAPI(
title=system.api_settings.title,
description=system.api_settings.description,
version=system.api_settings.version,
servers=[
{"url": s.url, "description": s.description}
for s in system.api_settings.servers
],
)
app.add_middleware(
CORSMiddleware,
allow_origins=system.api_settings.cors.allow_origins,
allow_methods=system.api_settings.cors.allow_methods,
allow_headers=system.api_settings.cors.allow_headers,
)
Sources: openbb_platform/core/openbb_core/api/rest_api.py:38-70
#### API Configuration Options
The REST API supports configurable settings including:
title: API titledescription: API descriptionversion: API versionterms_of_service: Terms of service URLcontact: Contact information (name, URL, email)license_info: License details (name, URL)servers: Server configurations with URLs and descriptionscors: Cross-Origin Resource Sharing settings
Start the API server with:
uvicorn openbb_core.api.rest_api:app --host 0.0.0.0 --port 8000 --reload
Sources: openbb_platform/core/openbb_core/api/rest_api.py, openbb_platform/README.md
MCP Server Extension
The Model Context Protocol (MCP) server integration exposes OpenBB functionality as tools for AI assistants:
{
"description": "Generate a brief summary of GDP for a country.",
"messages": [
{
"role": "user",
"content": {
"type": "text",
"text": "Use the tool, economy_gdp, to perform the following task.\n\nProvide a concise summary of the GDP for Japan over the last 10 years."
}
}
]
}
#### MCP Configuration Options
| Property | Type | Description |
|---|---|---|
expose | Optional[bool] | Set to False to hide a route from MCP server |
mcp_type | Optional[MCPType] | Classify as "tool", "resource", or "resource_template" |
methods | Optional[list[HTTPMethod]] | Specify HTTP methods to expose |
Sources: openbb_platform/extensions/mcp_server/README.md
Desktop Application Architecture
The desktop application uses Tauri (Rust backend) with React frontend:
graph LR
subgraph "Desktop Frontend"
UI[React Components]
ROUTES[Routes: installation-progress, backends, api-keys, environments]
end
subgraph "Tauri Backend"
HANDLERS[Tauri Handlers]
CREDENTIALS[Credentials Handler]
end
UI --> HANDLERS
HANDLERS --> CREDENTIALS#### Desktop Installation Flow
The desktop application manages installation through phases:
- Miniforge Setup: Python environment manager installation
- Core Libraries: OpenBB environment with dependencies
- Extensions: User-selected extensions and PyPI packages
Sources: desktop/src/routes/installation-progress.tsx, desktop/src/routes/backends.tsx
#### Credential Management
The desktop application handles credential storage through platform-specific editors:
| Platform | Editor | Configuration |
|---|---|---|
| Windows | Notepad | .env, .condarc, etc. |
| macOS | TextEdit | Basic text editing |
| Linux | gedit/kate/leafpad/mousepad/xed | Multiple fallback editors |
Sources: desktop/src-tauri/src/tauri_handlers/credentials.rs
Platform API Extension
The Platform API extension provides widget management and workspace functionality:
| File | Default Location | Purpose |
|---|---|---|
widgets.json | ~/OpenBBUserData/widgets.json | Widget configuration |
workspace_apps.json | ~/OpenBBUserData/workspace_apps.json | Custom workspace apps |
Configuration options:
--editable: Enable live editing without rebuild--no-build: Serve file directly without build process--widgets-json: Custom widgets file path--apps-json: Custom apps file path
Sources: openbb_platform/extensions/platform_api/README.md
Deployment Workflow
graph TD
A[User Installation] --> B{M Installation Target}
B -->|CLI| C[pip install openbb-cli]
B -->|Desktop| D[Download Desktop App]
B -->|Platform| E[pip install openbb-platform]
B -->|Extension| F[pip install openbb-<extension>]
C --> G[openbb command]
D --> H[Tauri Desktop App]
E --> I[REST API Server]
F --> J[Add-on Functionality]
G --> K[Python Runtime + Providers]
H --> K
I --> K
J --> K
K --> L[Data Providers]Sources: cli/README.md, openbb_platform/README.md, openbb_platform/extensions/news/README.md, openbb_platform/extensions/commodity/README.md
Local Development Setup
For local development, the platform uses Poetry for dependency management:
# 1. Clone repository
git clone https://github.com/OpenBB-finance/OpenBB.git
# 2. Navigate to platform directory
cd openbb_platform
# 3. Install in editable mode
python dev_install.py -e
Requirements:
- Git
- Python 3.10 - 3.13
- Virtual Environment with Poetry installed
Sources: openbb_platform/README.md
Security Architecture
API Key Management
API keys are managed through the obb.user.credentials interface:
from openbb import obb
obb.user.credentials.fred_api_key = "REPLACE_ME"
obb.user.credentials.polygon_api_key = "REPLACE_ME"
File-Based Credential Storage
| File | Format | Purpose |
|---|---|---|
.env | Environment variables | API keys and secrets |
.condarc | YAML | Conda configuration |
config.py | Python | User preferences |
The desktop application provides UI for importing/exporting credentials as JSON or .env files.
Sources: openbb_platform/README.md, desktop/src/routes/api-keys.tsx
Extension Discovery
The OpenBB Hub provides a centralized location for discovering extensions:
# Browse available extensions
# https://my.openbb.co/app/platform/extensions
Available extension types:
- Data Providers (e.g.,
openbb-us-government,openbb-multpl) - Data Services (e.g.,
openbb-news,openbb-commodity) - Integration Adapters (e.g.,
openbb-mcp-server,openbb-regulators)
Sources: cli/README.md, openbb_platform/providers/government_us/README.md, openbb_platform/providers/multpl/README.md
Conclusion
The OpenBB Platform architecture emphasizes modularity, extensibility, and multi-interface support. The core layer handles data abstraction and provider management, while the interface layer provides diverse ways to interact with the platform. The extension system enables third-party contributions while maintaining consistency across the ecosystem.
Sources: openbb_platform/README.md
Core Concepts
Related topics: System Architecture, OBBject System, Provider Interface
Continue reading this section for the full explanation and source context.
Related Pages
Related topics: System Architecture, OBBject System, Provider Interface
Core Concepts
The OpenBB Platform is a modular financial data infrastructure designed to provide unified access to diverse financial data sources. Built on Python with a FastAPI REST API layer, the platform abstracts data provider complexity behind a consistent interface, enabling developers and analysts to access market data, economic indicators, and financial analytics through a standardized workflow.
This page documents the fundamental architectural concepts that underpin the OpenBB Platform, including the OBBject data model, the provider abstraction system, the fetcher pattern, and the extension mechanism.
Source: https://github.com/OpenBB-finance/OpenBB / Human Manual
OBBject System
Related topics: Core Concepts, Charting and Visualization
Continue reading this section for the full explanation and source context.
Continue reading this section for the full explanation and source context.
Continue reading this section for the full explanation and source context.
Related Pages
Related topics: Core Concepts, Charting and Visualization
OBBject System
Note: This wiki page is based on available documentation and README files in the repository. The core implementation files for the OBBject system (openbb_platform/core/openbb_core/app/model/obbject.py,openbb_platform/core/openbb_core/app/model/abstract/results.py, andopenbb_platform/core/integration/test_obbject.py) were not available in the provided context for detailed analysis. The information below reflects the system's role and usage as observed across the platform.
Overview
The OBBject system is the core data structure framework within the OpenBB Platform that handles standardized return types from all data provider queries. Every function endpoint in the platform returns an OBBject, ensuring consistent response handling across the entire system.
Architecture
The OBBject serves as the universal wrapper for all platform outputs, providing:
- Standardized data formats across all providers
- Metadata attachment for query context
- Flexible conversion methods between different data representations
- Results abstraction through inheritance from
AbstractResults
Data Flow
graph TD
A[User Query via obb] --> B[OpenBB Core]
B --> C[Provider Function Call]
C --> D[Data Provider API]
D --> E[Provider Response Parser]
E --> F[OBBject Construction]
F --> G[Results with Metadata]
G --> H[User: .to_df, .to_dict, .to_chart]Usage Patterns
Basic Return Type
All platform endpoints return OBBject instances:
from openbb import obb
# Returns OBBject
result = obb.cftc.cot_search(query="gold")
print(result.to_df())
Data Conversion Methods
| Method | Description |
|---|---|
to_df() | Convert results to pandas DataFrame |
to_dict() | Convert results to dictionary format |
to_chart() | Generate chart-ready data structure |
Integration Points
The OBBject system integrates with:
- Provider System: All data providers return standardized OBBject instances
- REST API: Responses are automatically serialized from OBBject format
- CLI Interface: Tabular display powered by OBBject conversion
- Workspace Widgets: Data binding through OBBject metadata
Test Coverage
The openbb_platform/core/integration/test_obbject.py file contains integration tests verifying OBBject behavior across different provider scenarios and edge cases.
Platform-Wide Consistency
The OpenBB Platform enforces OBBject returns through the core framework, ensuring that whether accessing:
obb.cftc.cotobb.cftc.cot_searchobb.equity.screener(provider="finviz")obb.economy.indicators
All responses follow the same structure and interface conventions.
Source: https://github.com/OpenBB-finance/OpenBB / Human Manual
Provider Interface
Related topics: Core Concepts, Data Providers Overview, Developing Custom Providers
Continue reading this section for the full explanation and source context.
Continue reading this section for the full explanation and source context.
Continue reading this section for the full explanation and source context.
Continue reading this section for the full explanation and source context.
Related Pages
Related topics: Core Concepts, Data Providers Overview, Developing Custom Providers
Provider Interface
Overview
The Provider Interface is a core architectural component of the OpenBB Platform that abstracts data acquisition from various financial data sources. It provides a unified API for querying external data providers while maintaining provider-specific implementations behind a common interface.
The Provider system enables OpenBB to integrate multiple data sources (FMP, Alpha Vantage, US Government data, CFTC, IMF, etc.) through a standardized abstraction layer, allowing users to query different providers using a consistent interface.
Architecture
graph TD
A[OpenBB User/Application] --> B[Provider Interface]
B --> C[Registry Map]
C --> D[Provider: FMP]
C --> E[Provider: Government US]
C --> F[Provider: CFTC]
C --> G[Provider: IMF]
C --> H[Provider: Custom]
D --> I[Models]
E --> I
F --> I
G --> I
I --> J[Query Params]
I --> K[Response Models]
J --> L[Fetchers]
L --> M[External API]
M --> N[Data Normalization]
N --> O[Standardized Output]Core Components
1. Provider Abstract Class
The base Provider class defines the interface that all providers must implement. Each provider declares its available endpoints, authentication requirements, and routing information.
| Property | Type | Description |
|---|---|---|
| name | str | Unique identifier for the provider |
| website | str | Provider's official website |
| description | str | Brief description of the provider |
| credentials | dict | Required API credentials/keys |
| available_endpoints | list | Endpoints provided by this source |
| url | str | Base URL for API requests |
Sources: openbb_platform/core/openbb_core/provider/abstract/provider.py
2. Query Params
Query parameters define the input schema for each endpoint. They validate and serialize user requests before passing them to the fetcher.
| Parameter | Type | Description |
|---|---|---|
| provider | Optional[str] | Override default provider for this query |
| use_cache | bool | Enable/disable response caching |
| chunk | bool | Split large responses into chunks |
| date | Optional[date] | Filter data by specific date |
| start_date | Optional[date] | Filter data from this date |
| end_date | Optional[date] | Filter data until this date |
| limit | Optional[int] | Maximum number of results |
Sources: openbb_platform/core/openbb_core/provider/abstract/query_params.py
3. Fetcher
The Fetcher class handles the actual data retrieval from external APIs. It processes query parameters, makes HTTP requests, and normalizes responses.
| Component | Description |
|---|---|
| transform | Method to normalize raw API response |
| extract | Method to extract relevant fields from response |
| validate | Method to validate response data |
Sources: openbb_platform/core/openbb_core/provider/abstract/fetcher.py
4. Registry Map
The Registry Map maintains a centralized catalog of all registered providers and their endpoints, enabling dynamic discovery and routing.
classDiagram
class RegistryMap {
+dict providers
+dict routers
+register_provider()
+get_provider()
+list_providers()
+get_endpoint()
}
class Provider {
+str name
+list endpoints
+register()
}
class Router {
+str name
+add_route()
+get_routes()
}
RegistryMap --> Provider
RegistryMap --> RouterSources: openbb_platform/core/openbb_core/provider/registry_map.py
Provider Structure
Providers in OpenBB follow a standardized directory structure:
openbb_platform/providers/<provider_name>/
├── README.md
├── pyproject.toml
├── poetry.lock
├── tests/
│ └── ...
└── openbb_<provider_name>/
├── __init__.py
├── models/
│ ├── __init__.py
│ └── <model_files>.py
└── utils/
├── __init__.py
└── <helper_files>.py
Sources: openbb_platform/providers/README.md
Creating a Custom Provider
Step 1: Create Provider Directory
Create a new directory under openbb_platform/providers/ with your provider name.
Step 2: Define Models
Models define data structures for querying endpoints and storing responses:
from pydantic import BaseModel, Field
from openbb_core.provider.abstract.query_params import QueryParams
class CustomQuoteQueryParams(QueryParams):
symbol: str = Field(description="Stock symbol to query")
provider: Optional[str] = None
Step 3: Implement Fetcher
from openbb_core.provider.abstract.fetcher import Fetcher
class CustomQuoteFetcher(Fetcher):
@staticmethod
def transform(params: dict, response: httpx.Response) -> BaseModel:
# Transform and normalize response data
return NormalizedQuote(**transformed_data)
Step 4: Register Provider
from openbb_core.provider.abstract.provider import Provider
class CustomProvider(Provider):
name = "custom_provider"
website = "https://custom-api.example.com"
@property
def router(self):
return CustomRouter()
Provider Examples
Financial Modeling Prep (FMP)
from openbb import obb
# Search for companies
search_results = obb.company.search(query="Apple")
print(search_results.to_df())
# Get financial statements
balance_sheet = obb.company.balance(symbol="AAPL", provider="fmp")
print(balance_sheet.to_df())
Sources: openbb_platform/providers/fmp/README.md
US Government Data
from openbb import obb
# Treasury auctions
auctions = obb.fixed_income.government.treasury_auctions()
print(auctions.to_df())
# Treasury prices
prices = obb.fixed_income.government.treasury_prices()
print(prices.to_df())
Sources: openbb_platform/providers/government_us/README.md
CFTC Commitments of Traders
from openbb import obb
# Search CFTC codes
search_results = obb.cftc.cot_search(query="gold")
print(search_results.to_df())
# Get report
report = obb.cftc.cot(code="CFTC_088695", measure="percent_of_oi")
print(report.to_df().T)
Sources: openbb_platform/providers/cftc/README.md
Integration with REST API
The Provider system integrates seamlessly with the OpenBB Platform REST API:
uvicorn openbb_core.api.rest_api:app --host 0.0.0.0 --port 8000 --reload
API documentation is available at /docs endpoint.
Sources: openbb_platform/core/openbb_core/api/rest_api.py
Configuration
API Keys
Providers requiring authentication use the credentials system:
from openbb import obb
obb.user.credentials.fmp_api_key = "YOUR_API_KEY"
obb.user.credentials.polygon_api_key = "YOUR_API_KEY"
Provider Selection
When multiple providers support an endpoint, specify the provider explicitly:
# Use specific provider
result = obb.equity.quote(symbol="AAPL", provider="fmp")
# Use default provider
result = obb.equity.quote(symbol="AAPL")
Best Practices
| Practice | Description |
|---|---|
| Error Handling | Always wrap provider calls in try-except blocks |
| Caching | Enable caching for frequently accessed data |
| Rate Limiting | Respect provider rate limits |
| Validation | Use query parameter validation |
| Documentation | Document custom providers in README.md |
Supported Providers
| Provider | Category | Registration Required |
|---|---|---|
| FMP | Financial Data | Yes |
| Alpha Vantage | Financial Data | Yes |
| US Government | Government Data | No |
| CFTC | Commodities | No |
| IMF | Economic Indicators | No |
Sources: openbb_platform/providers/README.md
Conclusion
The Provider Interface is fundamental to OpenBB's extensibility. By adhering to the abstract interfaces defined in the core module, developers can integrate new data sources while maintaining a consistent API experience for end users. The registry-based architecture enables dynamic provider discovery and seamless switching between data sources.
Sources: openbb_platform/core/openbb_core/provider/abstract/provider.py
Data Providers Overview
Related topics: Provider Interface, Developing Custom Providers
Continue reading this section for the full explanation and source context.
Continue reading this section for the full explanation and source context.
Continue reading this section for the full explanation and source context.
Continue reading this section for the full explanation and source context.
Related Pages
Related topics: Provider Interface, Developing Custom Providers
Data Providers Overview
Data Providers in the OpenBB Platform serve as extension modules that integrate external financial data sources into the unified OpenBB ecosystem. These providers enable users to access a wide variety of financial data including equity prices, economic indicators, commodity data, government reports, and more through a consistent API interface.
Architecture Overview
The OpenBB Platform uses a modular provider architecture where each data source is implemented as a separate Python package extension. Providers communicate with their respective external APIs, transform the responses into standardized data models, and expose endpoints through the unified OpenBB interface.
graph TD
A[OpenBB Platform Core] --> B[Provider Extensions]
B --> C[Data Provider 1]
B --> D[Data Provider 2]
B --> N[Data Provider N]
C --> E[External API 1]
D --> F[External API 2]
N --> G[External API N]
E --> H[Standardized Data Models]
F --> H
G --> HProviders follow a consistent structure that ensures maintainability and enables the platform to automatically discover and load endpoints. Sources: openbb_platform/providers/README.md
Provider Directory Structure
Every provider follows a standardized directory layout to ensure consistency across the codebase. This structure separates concerns between data models, utilities, and tests.
openbb_platform
└───providers
└───<provider_name>
│ README.md
│ pyproject.toml
│ poetry.lock
├───tests
└───openbb_<provider_name>
│ __init__.py
├───models
│ ├───<some model>.py
│ └───...
└───utils
├───<some helper>.py
└───...
The models directory contains data structures that define both the request parameters for querying provider endpoints and the response data structures. The utils directory houses helper functions used internally by the provider. Sources: openbb_platform/providers/README.md
Available Data Providers
The OpenBB Platform supports numerous data providers across various financial domains. Below is a comprehensive table of documented providers.
| Provider | Package Name | Data Domain | Registration Required |
|---|---|---|---|
| Financial Modeling Prep | openbb-fmp | Equity, Fundamentals, Estimates | Yes |
| US Government | openbb-us-government | Treasury, Commodity Reports | No |
| TMX | openbb-tmx | Canadian Markets, Derivatives | Varies |
| Multpl | openbb-multpl | S&P 500 Multiples, Index Data | No |
| IMF | openbb-imf | Economic Indicators, CPI, Shipping | No |
| FINRA | openbb-finra | Market Regulatory Data | Varies |
| Fama-French | openbb-famafrench | Research Factors, Portfolios | No |
| News | openbb-news | Financial News | Varies |
| Regulators | openbb-regulators | Global Market Regulators | Varies |
| Commodity | openbb-commodity | Commodity Data | Varies |
Provider Installation
Each provider is distributed as a separate Python package installable via pip. The general installation pattern follows a consistent command structure.
pip install openbb-<provider_name>
Installation Examples
Financial Modeling Prep:
pip install openbb-fmp
Sources: openbb_platform/providers/fmp/README.md
US Government:
pip install openbb-us-government
Sources: openbb_platform/providers/government_us/README.md
TMX (Community Provider):
pip install openbb-tmx
Alternatively, install from local directory for development:
pip install -e .
Sources: openbb_platform/providers/tmx/README.md
Endpoint Coverage Examples
Different providers offer varying levels of endpoint coverage. Below are examples of what each provider exposes.
US Government Provider
The US Government provider covers endpoints with no registration requirement, making it ideal for accessing public data.
| Endpoint | Description |
|---|---|
obb.commodity.psd_report | PSD Commodity Reports |
obb.commodity.psd_data | PSD Data Sets |
obb.commodity.weather_bulletins | Weather Bulletins |
obb.commodity.weather_bulletins_download | Download Bulletins |
obb.fixed_income.government.treasury_auctions | Treasury Auctions |
obb.fixed_income.government.treasury_prices | Treasury Prices |
Sources: openbb_platform/providers/government_us/README.md
TMX Provider
The TMX provider offers Canadian market data including derivatives and equity information.
| Endpoint Category | Coverage |
|---|---|
.derivatives.options.chains | Historical EOD chains from 2009 |
.equity.calendar.earnings | Earnings Calendars |
.equity.estimates.consensus | Consensus Estimates |
.equity.discovery.gainers | Best Performers |
.equity.fundamental.dividends | Dividend History |
.equity.fundamental.filings | SEC Filings |
.equity.ownership.insider_trading | Insider Trading (3/6/12 months) |
.equity.price.quote | Real-time Quotes |
.equity.price.historical | Daily/Weekly/Monthly/Intraday |
.equity.search | Symbol Search |
Sources: openbb_platform/providers/tmx/README.md
IMF Provider
The IMF provider provides extensive economic data including indicators and shipping information.
Primary Endpoints:
obb.economy.available_indicatorsobb.economy.indicatorsobb.economy.cpiobb.economy.direction_of_tradeobb.economy.spi(Shipping)
Utility Endpoints (for UI integrations):
obb.imf_utils.get_dataflow_dimensionsobb.imf_utils.list_dataflow_choicesobb.imf_utils.list_dataflowsobb.imf_utils.list_indicators_by_dataflowobb.imf_utils.list_port_id_choicesobb.imf_utils.list_table_choicesobb.imf_utils.list_tablesobb.imf_utils.presentation_table
The "Choices" endpoints are specifically utilized by OpenBB Workspace to populate widget dropdown menus. Sources: openbb_platform/providers/imf/README.md
Multpl Provider
The Multpl provider offers simple integration for S&P 500 related data.
Available Endpoints:
obb.index.sp500_multiples
Sources: openbb_platform/providers/multpl/README.md
Fama-French Provider
The Fama-French provider integrates academic research factor data. It includes metadata about the data source and formation methodology.
Metadata Structure:
factors.extra["results_metadata"]
Example metadata output:
{
'description': 'This file was created using the 202504 CRSP database...',
'frequency': 'monthly',
'formations': ['Mkt-RF', 'SMB', 'HML', 'RF']
}
The frequency and formations metadata fields indicate whether data is monthly, daily, or another frequency, and the specific factor formations available. Sources: openbb_platform/providers/famafrench/README.md
Provider Data Flow
graph LR
A[User Query] --> B[OpenBB Core API]
B --> C[Provider Router]
C --> D[Provider Models]
D --> E[External API Request]
E --> F[Response Parser]
F --> G[Standard Model]
G --> H[Platform Output]Creating New Providers
To create a new provider for the OpenBB Platform, follow these steps:
- Create a new directory under
openbb_platform/providers/<provider_name>/ - Implement the required directory structure (models, utils, tests)
- Define data models for requests and responses
- Implement the provider logic to communicate with external APIs
- Add a
pyproject.tomlfor package configuration - Create a
README.mdwith installation and usage documentation - Publish to PyPI for distribution via
pip install openbb-<provider_name>
For detailed contribution guidelines, refer to the main CONTRIBUTING file in the repository. Sources: openbb_platform/providers/README.md
Extension Types
Beyond standard data providers, the OpenBB Platform supports additional extension types that enhance functionality:
| Extension Type | Purpose |
|---|---|
| Data Providers | Fetch and transform external financial data |
| News Extension | openbb-news - Provides news aggregation |
| Regulators Extension | openbb-regulators - Global market regulator data |
| Commodity Extension | openbb-commodity - Commodity-specific commands |
| MCP Server | Model Context Protocol integration for AI tools |
These extensions can be installed using pip install openbb-<extension_name> and are documented in the openbb_platform/extensions/ directory.
Developing Custom Providers
Related topics: Provider Interface, Data Providers Overview, Extensions System
Continue reading this section for the full explanation and source context.
Continue reading this section for the full explanation and source context.
Continue reading this section for the full explanation and source context.
Continue reading this section for the full explanation and source context.
Related Pages
Related topics: Provider Interface, Data Providers Overview, Extensions System
Developing Custom Providers
Overview
Custom providers extend the OpenBB Platform by integrating new data sources for financial information. The platform uses a standardized architecture that allows developers to create providers following established patterns, enabling seamless integration with the existing OpenBB ecosystem including the REST API, MCP server, and desktop interface.
The provider system is designed around modularity—each provider consists of data models, authentication handlers, and utility functions that work together to fetch, transform, and expose financial data through a unified interface.
Architecture Overview
graph TD
A[Custom Provider] --> B[Data Models]
A --> C[Authentication]
A --> D[Utility Helpers]
B --> E[REST API Router]
C --> E
D --> E
E --> F[OpenBB Platform API]
F --> G[MCP Server]
F --> H[Desktop Interface]
F --> I[Direct SDK Access]Provider Structure
Each custom provider follows a consistent directory structure:
{{cookiecutter.package_name}}/
└── providers/
└── {{cookiecutter.provider_name}}/
├── models/
│ └── example.py # Data models
├── utils/
│ └── helpers.py # Utility functions
└── __init__.py # Provider initialization
Data Models
Data models define the schema for the financial data your provider will return. The OpenBB Platform uses standardized model classes that inherit from base types:
# cookiecutter template structure
class ExampleModel:
"""Example data model for custom provider."""
symbol: str
name: str
price: float
timestamp: datetime
@field_validator('price')
@classmethod
def validate_price(cls, v):
if v < 0:
raise ValueError("Price must be non-negative")
return v
Sources: cookiecutter/.../models/example.py
Utility Helpers
Helper functions handle common operations like API requests, data transformation, and authentication:
import requests
from typing import Optional, Dict, Any
def get_data(
url: str,
params: Optional[Dict[str, Any]] = None,
headers: Optional[Dict[str, str]] = None,
timeout: int = 30
) -> Dict[str, Any]:
"""Fetch data from the provider's API endpoint."""
response = requests.get(url, params=params, headers=headers, timeout=timeout)
response.raise_for_status()
return response.json()
def transform_response(data: Dict[str, Any]) -> Dict[str, Any]:
"""Transform provider-specific response format to OpenBB standard format."""
return {
"symbol": data.get("symbol", ""),
"name": data.get("companyName", ""),
"price": float(data.get("price", 0)),
"timestamp": data.get("timestamp")
}
Sources: cookiecutter/.../utils/helpers.py Sources: openbb_platform/providers/fmp/openbb_fmp/utils/helpers.py
Provider Configuration
MCP Server Integration
Custom providers can be exposed through the Model Context Protocol (MCP) server, allowing AI assistants to interact with your data:
from openbb_mcp_server.models.mcp_config import MCPConfigModel
# In your route definition
openapi_extra = {
"mcp_config": MCPConfigModel(
expose=True,
mcp_type="tool",
methods=["GET"]
)
}
MCP Configuration Properties:
| Property | Type | Description |
|---|---|---|
expose | Optional[bool] | Set to False to hide from MCP server |
mcp_type | Optional[MCPType] | Type: "tool", "resource", or "resource_template" |
methods | Optional[list[HTTPMethod]] | HTTP methods to expose |
Sources: openbb_platform/extensions/mcp_server/README.md
REST API Registration
The OpenBB Platform uses FastAPI for its REST API. Providers register through the AppLoader:
from fastapi import FastAPI
from openbb_core.api.rest_api import AppLoader
# Providers are automatically loaded via the extension system
# The router is added through the provider's __init__.py
The API server is configured with CORS middleware:
app.add_middleware(
CORSMiddleware,
allow_origins=system.api_settings.cors.allow_origins,
allow_methods=system.api_settings.cors.allow_methods,
allow_headers=system.api_settings.cors.allow_headers,
)
Sources: openbb_platform/core/openbb_core/api/rest_api.py
Creating a Provider from Template
The OpenBB Cookiecutter template provides a starting point for new providers:
cookiecutter gh:OpenBB-finance/OpenBB --directory cookiecutter
The generated template includes:
- Pre-configured directory structure
- Example model implementations
- Utility function templates
- Authentication patterns
- Test scaffolding
Extension Installation System
The desktop interface provides a mechanism for users to discover and install provider extensions:
// Extensions are fetched from GitHub configuration
const [providersRes, routersRes, obbjectsRes] = await Promise.all([
fetch("https://raw.githubusercontent.com/OpenBB-finance/OpenBB/main/assets/extensions/provider.json"),
fetch("https://raw.githubusercontent.com/OpenBB-finance/OpenBB/main/assets/extensions/router.json"),
fetch("https://raw.githubusercontent.com/OpenBB-finance/OpenBB/main/assets/extensions/obbject.json"),
]);
Sources: desktop/src/components/InstallComponents.tsx
Extension Categories
| Category ID | Description |
|---|---|
providers | Data source integrations |
routers | Custom API endpoints |
obbjects | Custom data object types |
extras | Additional PyPI packages |
Workflow Diagram
graph LR
A[Create Provider] --> B[Define Models]
B --> C[Implement Helpers]
C --> D[Register Routes]
D --> E[Add MCP Config]
E --> F[Test Provider]
F --> G[Publish Extension]
G --> H[User Installs]
H --> I[Available in Platform]Best Practices
Authentication Handling
- Store API keys securely using environment variables
- Implement token refresh logic for OAuth flows
- Provide clear error messages for authentication failures
Data Validation
- Validate all incoming data against expected schemas
- Use field validators for type checking and constraints
- Handle missing or null values gracefully
Error Handling
- Implement retry logic for transient failures
- Log errors with sufficient context for debugging
- Return standardized error responses
Performance Considerations
- Cache frequently accessed data when appropriate
- Use connection pooling for API requests
- Implement request batching where the API supports it
See Also
Sources: cookiecutter/.../models/example.py
Extensions System
Related topics: Core Concepts, Charting and Visualization
Continue reading this section for the full explanation and source context.
Continue reading this section for the full explanation and source context.
Continue reading this section for the full explanation and source context.
Continue reading this section for the full explanation and source context.
Related Pages
Related topics: Core Concepts, Charting and Visualization
Extensions System
Overview
The OpenBB Extensions System is a modular architecture that allows users to extend the core platform functionality through optional packages called "extensions." These extensions provide specialized data sources, additional features, and domain-specific tools for various financial market segments.
Extensions in OpenBB serve as the primary mechanism for feature expansion, enabling users to install only the components they need while keeping the core platform lightweight. The system supports both official OpenBB extensions and third-party community extensions.
Architecture
Core Components
The Extensions System consists of several interconnected components:
| Component | Purpose | Location |
|---|---|---|
| Extension Loader | Discovers and loads extensions at runtime | openbb_platform/core/openbb_core/app/extension_loader.py |
| Extension Package | Python package with specialized functionality | openbb_platform/extensions/<name>/ |
| Environment Manager | Manages extension installation in isolated environments | desktop/src-tauri/src/tauri_handlers/environments.rs |
| UI Integration | Frontend component for extension management | desktop/src/routes/environments.tsx |
Extension Types
OpenBB extensions are categorized into several types based on their functionality:
graph TD
A[OpenBB Platform] --> B[Core Extensions]
A --> C[Data Provider Extensions]
A --> D[Feature Extensions]
B --> B1[Equity]
B --> B2[Economy]
B --> B3[Crypto]
B --> B4[Fixed Income]
C --> C1[Government US]
C --> C2[IMF]
C --> C3[CFTC]
C --> C4[Multpl]
D --> D1[News]
D --> D2[MCP Server]
D --> D3[Regulators]Extension Discovery and Loading
Extension Loader Mechanism
The extension loader (extension_loader.py) handles the discovery and loading of extensions. It performs the following operations:
- Package Discovery: Scans installed Python packages for OpenBB extension markers
- Dependency Resolution: Ensures all extension dependencies are available
- Router Registration: Registers extension routers with the main application
- Initialization: Calls extension
__init__.pyto set up routes and handlers
graph LR
A[Scan Packages] --> B[Identify Extensions]
B --> C{Check Dependencies}
C -->|Missing| D[Log Warning]
C -->|Satisfied| E[Load Extension]
E --> F[Register Router]
F --> G[Ready for Use]Loading Process Flow
Extensions follow a specific loading sequence to ensure proper initialization order:
- Core platform initializes first
- Extension loader scans for available extensions
- Each extension's dependencies are verified
- Extensions are loaded in dependency order
- Extension routers are registered with FastAPI
- Extensions become available via
obb.<extension>.<method>
Extension Package Structure
Standard Layout
Each OpenBB extension follows a consistent directory structure:
openbb_platform/extensions/<extension_name>/
├── README.md # Documentation
├── pyproject.toml # Package configuration
├── poetry.lock # Dependency lock file
├── openbb_<extension_name>/
│ ├── __init__.py # Router registration
│ └── ...
└── tests/
└── ...
Required Components
| File | Purpose |
|---|---|
__init__.py | Contains router definition and extension metadata |
pyproject.toml | Package metadata, dependencies, and build configuration |
README.md | Installation instructions and feature documentation |
Extension Categories
1. Core Extensions
Core extensions provide essential market data functionality:
#### Equity Extension
The Equity extension (openbb_equity) provides equity market data tools including:
- Historical price data
- Fundamental analysis
- Analyst estimates
- Options data
- Ownership information
- Short interest data
Installation:
pip install openbb-equity
#### Fixed Income Extension
The Fixed Income extension (openbb_fixedincome) offers fixed income market tools:
- Government bond data
- Treasury auctions
- Treasury prices
- Credit spreads
#### Economy Extension
Provides global macroeconomic data access including:
- GDP indicators
- CPI data
- Trade statistics
- Economic indicators
#### Crypto Extension
Cryptocurrency market data including:
- Price data
- Trading volumes
- Market capitalization
- Exchange data
2. Data Provider Extensions
Data providers extend the platform's data sources:
#### Government US (openbb-us-government)
Provides US Government data from data.gov:
| Endpoint | Function |
|---|---|
obb.commodity.psd_report | PSD reports |
obb.commodity.psd_data | PSD data |
obb.commodity.weather_bulletins | Weather bulletins |
obb.fixed_income.government.treasury_auctions | Treasury auctions |
obb.fixed_income.government.treasury_prices | Treasury prices |
Installation:
pip install openbb-us-government
#### CFTC Provider
Commitments of Traders (COT) data including:
obb.cftc.cot- COT reportsobb.cftc.cot_search- Search COT data
#### IMF Provider
International Monetary Fund data with endpoints:
obb.economy.indicatorsobb.economy.cpiobb.economy.direction_of_tradeobb.economy.shipping.*
#### Multpl Provider
S&P 500 valuation metrics:
obb.index.sp500_multiples
3. Feature Extensions
#### News Extension
Aggregates financial news from multiple sources.
Installation:
pip install openbb-news
#### MCP Server Extension
Model Context Protocol server for AI integrations. Provides:
- Tool exposure as MCP resources
- FastAPI route exposure
- Custom prompt definitions
Configuration via openapi_extra.mcp_config:
| Property | Type | Description |
|---|---|---|
expose | Optional[bool] | Hide/show route from MCP server |
mcp_type | Optional[MCPType] | Classification: "tool", "resource", or "resource_template" |
methods | Optional[list[HTTPMethod]] | HTTP methods to expose |
#### Regulators Extension
Provides structure for data from global market regulators.
Installation:
pip install openbb-regulators
Environment-Based Extension Management
Concept
Extensions can be installed within isolated Python environments, allowing users to:
- Maintain separate extension sets for different use cases
- Avoid dependency conflicts between extensions
- Enable/disable extension groups easily
Environment Handler Architecture
The desktop application uses a Rust-based backend for environment management:
graph TD
A[Frontend Environment UI] --> B[Tauri Command]
B --> C[environments.rs Handler]
C --> D{Conda Environment?}
D -->|base| E[System Conda Install]
D -->|custom| F[Named Environment Install]
E --> G[Install Extensions]
F --> G
G --> H[Refresh Extensions List]Extension Installation in Environments
The environment handler processes extensions with special prefixes:
# Prefix handling logic from environments.rs
if extension.startswith("conda:"):
# Add to conda package list
conda_packages.push(extension.strip_prefix("conda:"))
else:
# Add to pip packages
pip_packages.push(extension)
Caching Strategy
The environment extensions list is cached locally:
// Cache structure in environments.tsx
const cache = cachedData ? JSON.parse(cachedData) : {};
cache[env.name] = result.extensions;
localStorage.setItem(ENV_EXTENSIONS_CACHE_KEY, JSON.stringify(cache));
Installation and Setup
Installation Phases
The desktop installation process consists of three phases:
graph TD
A[Phase 1: Miniforge] --> B[Phase 2: Core Setup]
B --> C[Phase 3: Extension Select]
A --> |Miniforge + Conda| D[Python Environment]
B --> |Core Libraries| D
C --> |Optional Packages| DInitial Installation Components
When setting up a new environment, the following components are installed:
| Component | Purpose |
|---|---|
| Miniforge | Python environment manager |
| Core libraries | OpenBB platform dependencies |
| iPython | Interactive Python shell |
| Jupyter Lab | Web-based development environment |
Extension Selection UI
The extension selection phase allows users to:
- Select which extensions to install
- Add additional PyPI packages
- Configure environment-specific settings
Error Handling
Extension Loading Errors
| Error Type | Cause | Resolution |
|---|---|---|
| Missing Dependency | Extension requires unavailable package | Install missing package |
| Import Failure | Extension module has errors | Check extension installation |
| Router Conflict | Duplicate endpoint definitions | Review extension configuration |
Installation Errors
The system handles installation errors gracefully:
// Error display with retry option
{createEnvironmentError && (
<div className="p-3 bg-theme-secondary border border-red-500">
<p>{extractStderr(createEnvironmentError)}</p>
<Button onClick={() => createEnvironment([])}>Retry</Button>
</div>
)}
API Reference
Extension Loading API
Extensions are accessed through the main obb object:
from openbb import obb
# Access equity data
result = obb.equity.price_history(symbol="AAPL")
# Access fixed income data
result = obb.fixed_income.government.treasury_auctions()
# Access CFTC data
result = obb.cftc.cot(code="CFTC_088695", measure="percent_of_oi")
Extension Router Pattern
Extensions define routers for API endpoints:
# Example from extension __init__.py
from openbb_core.provider.standard_routes import router
@router.command()
async def endpoint(params: Model):
# Implementation
pass
Best Practices
Extension Development
- Follow the standard directory structure
- Define clear router endpoints
- Use Pydantic models for request/response validation
- Document all endpoints in README.md
- Include comprehensive test coverage
Extension Installation
- Verify Python environment compatibility
- Check dependency requirements
- Use virtual environments for testing
- Review extension permissions and data access
See Also
Source: https://github.com/OpenBB-finance/OpenBB / Human Manual
Charting and Visualization
Related topics: OBBject System, Extensions System
Continue reading this section for the full explanation and source context.
Continue reading this section for the full explanation and source context.
Continue reading this section for the full explanation and source context.
Continue reading this section for the full explanation and source context.
Related Pages
Related topics: OBBject System, Extensions System
Charting and Visualization
The OpenBB charting and visualization system provides an interactive charting library built on top of Plotly. It functions as an OBBject extension, meaning charting capabilities are automatically available on every command result returned by the OpenBB Platform.
Overview
The charting extension transforms raw financial data into interactive visualizations with support for:
- Technical Analysis Indicators - SMA, EMA, MACD, RSI, Bollinger Bands, Stochastic Oscillator, ADX, and more
- Prebuilt Charts - Dedicated visualizations for specific endpoints
- Custom Charts - User-defined charts from DataFrames without Plotly knowledge
- OHLCV Time Series - Specialized handling for candlestick and financial time series data
Sources: openbb_platform/obbject_extensions/charting/README.md:1-10
Architecture
graph TD
A["OBBject<br/>(Command Result)"] --> B["charting accessor"]
B --> C["OpenBBFigure"]
B --> D["Charting Methods"]
B --> E["Technical Analysis"]
C --> F["Plotly Figure"]
C --> G["Raw Data Dict"]
D --> H["create_3d_surface()"]
D --> I["create_bar_chart()"]
D --> J["create_line_chart()"]
D --> K["create_correlation_matrix()"]
D --> L["to_chart()"]
E --> M["PlotlyTA Class"]
M --> N["sma, ema, macd"]
M --> O["rsi, adx, bbands"]
M --> P["stoch, and more"]Core Components
| Component | File Path | Purpose |
|---|---|---|
Charting | openbb_charting/charting.py | Main extension class with indicators() and functions() methods |
OpenBBFigure | openbb_charting/core/openbb_figure.py | Wrapper for Plotly figures with data extraction |
PlotlyTA | openbb_charting/core/plotly_ta/ta_class.py | Technical analysis indicator engine |
Sources: openbb_platform/obbject_extensions/charting/README.md:50-60
Installation
# Base installation
pip install openbb-charting
# With native OS window support
pip install "openbb-charting[pywry]"
Linux Dependencies
| Distribution | Command |
|---|---|
| Debian/Ubuntu/Mint | sudo apt install libwebkit2gtk-4.1-dev libgtk-3-dev |
| Arch Linux/Manjaro | sudo pacman -S webkit2gtk |
| Fedora | sudo dnf install gtk3-devel webkit2gtk3-devel |
Sources: openbb_platform/obbject_extensions/charting/README.md:15-35
Basic Usage
Enabling Charts on Command Results
from openbb import obb
# Method 1: Set chart=True argument
equity_data = obb.equity.price.historical(symbol="TSLA", chart=True)
# Method 2: Access charting on existing result
res = obb.equity.price.historical("AAPL")
res.charting.show()
Both methods produce identical results. The chart=True parameter returns an OBBject with a chart attribute containing Plotly JSON data.
Sources: openbb_platform/obbject_extensions/charting/README.md:50-75
Displaying Charts
# Get chart data
equity_data = obb.equity.price.historical(symbol="TSLA", chart=True)
# Display in native window
equity_data.show()
Custom Charts from DataFrames
Create visualizations directly from Pandas DataFrames without Plotly knowledge:
res = obb.equity.price.historical("AAPL", chart=True)
# Available charting methods
surface_3d = res.charting.create_3d_surface
bar_chart = res.charting.create_bar_chart
line_chart = res.charting.create_line_chart
correlation_matrix = res.charting.create_correlation_matrix
The data parameter accepts either OBBject.results as a list or any Pandas DataFrame instance.
Sources: openbb_platform/obbject_extensions/charting/README.md:95-110
Technical Analysis Integration
Available Indicators
from openbb_charting import Charting
# List all available indicators
Charting.indicators()
| Indicator | Parameters | Description |
|---|---|---|
sma | length | Simple Moving Average |
ema | length (list supported) | Exponential Moving Average |
macd | fast, slow, signal | Moving Average Convergence Divergence |
rsi | length | Relative Strength Index |
adx | length | Average Directional Index |
bbands | length, std | Bollinger Bands |
stoch | length | Stochastic Oscillator |
Sources: openbb_platform/obbject_extensions/charting/README.md:30-45
Using the `to_chart()` Method
The to_chart() method is an advanced feature that passes **kwargs to the PlotlyTA class for custom visualizations with technical indicators.
from openbb import obb
res = obb.equity.price.historical("AAPL")
indicators = dict(
sma=dict(length=[20, 30, 50]),
adx=dict(length=14),
rsi=dict(length=14),
macd=dict(fast=12, slow=26, signal=9),
bbands=dict(length=20, std=2),
stoch=dict(length=14),
)
res.charting.to_chart(**{"indicators": indicators})
Note: This method only works with standardized data and is designed for OHLCV time series.
Sources: openbb_platform/obbject_extensions/charting/README.md:55-80
Discovering Supported Endpoints
Not all endpoints have dedicated charts. To discover supported endpoints:
from openbb_charting import Charting
Charting.functions()
This returns a list of endpoints that have prebuilt charting support.
Sources: openbb_platform/obbject_extensions/charting/README.md:95-100
OpenBBFigure Class
The OpenBBFigure class wraps Plotly figures with additional functionality:
from openbb_charting.core.openbb_figure import OpenBBFigure
Return Value Structure
When using charting methods, the return type is:
Tuple[OpenBBFigure, Dict[str, Any]]
| Return Element | Type | Description |
|---|---|---|
| First | OpenBBFigure | Interactive Plotly figure |
| Second | Dict[str, Any] | Raw data used by the API |
Creating Custom Chart Extensions
Poetry Plugin Configuration
Add visualization to an existing Platform command via pyproject.toml:
[tool.poetry.plugins."openbb_charting_extension"]
my_extension = "openbb_my_extension.my_extension_views:MyExtensionViews"
The openbb_charting_extension entry point is mandatory for discovery.
Sources: openbb_platform/obbject_extensions/charting/README.md:100-115
Extension Views Module
"""Views for MyExtension."""
from typing import Any, Dict, Tuple
from openbb_charting.charts.price_historical import price_historical
from openbb_charting.core.openbb_figure import OpenBBFigure
class MyExtensionViews:
"""MyExtension Views."""
@staticmethod
def my_extension_price_historical(
**kwargs,
) -> Tuple[OpenBBFigure, Dict[str, Any]]:
"""MyExtension Price Historical Chart."""
return price_historical(**kwargs)
After implementation, charts are accessible via:
- Python interface:
obb.equity.price.historical("SYMBOL", chart=True) - Direct access:
result.charting.show()
Sources: openbb_platform/obbject_extensions/charting/README.md:115-135
Workflow Summary
graph LR
A["obb.equity.price.historical()"] --> B{chart=True?}
B -->|Yes| C["Returns OBBject<br/>with chart data"]
B -->|No| D["Returns OBBject<br/>without chart data"]
C --> E["result.charting.show()"]
C --> F["result.charting.create_bar_chart()"]
C --> G["result.charting.to_chart()"]
D --> H["result.charting.to_chart()"]
H --> I["Must have OHLCV data"]
E --> J["Display visualization"]
F --> K["Custom chart from data"]
G --> L["TA indicators overlay"]Summary Table: Charting Methods
| Method | Input | Use Case |
|---|---|---|
show() | None | Display current chart in native window |
to_chart(indicators={}) | Dict of indicator configs | Add TA indicators to time series |
create_3d_surface(data=...) | DataFrame or list | 3D surface visualization |
create_bar_chart(data=...) | DataFrame or list | Bar chart from any data |
create_line_chart(data=...) | DataFrame or list | Line chart from any data |
create_correlation_matrix(data=...) | DataFrame or list | Correlation heatmap |
indicators() | None | List available TA indicators |
functions() | None | List supported endpoint charts |
Sources: openbb_platform/obbject_extensions/charting/README.md:1-10
Command Line Interface
Related topics: Installation Guide
Continue reading this section for the full explanation and source context.
Related Pages
Related topics: Installation Guide
The provided context does not include the CLI source files mentioned in the query (cli/openbb_cli/cli.py, cli/openbb_cli/controllers/cli_controller.py, cli/openbb_cli/argparse_translator/argparse_translator.py, cli/README.md). The context only contains files related to the desktop application UI, backend handlers, and platform extensions.
To create an accurate technical wiki page about the Command Line Interface based on actual source code, I would need access to the CLI implementation files. Without these files, I cannot provide verified technical details about:
- The CLI entry point and main command structure
- The controller architecture and command handlers
- The argparse translation system
- Available commands and their parameters
- The CLI's interaction with the OpenBB Platform
Could you please provide the CLI source files from the repository so I can generate an accurate and well-sourced technical wiki page?
Source: https://github.com/OpenBB-finance/OpenBB / Human Manual
Desktop Application
Related topics: Installation Guide
Continue reading this section for the full explanation and source context.
Continue reading this section for the full explanation and source context.
Continue reading this section for the full explanation and source context.
Continue reading this section for the full explanation and source context.
Related Pages
Related topics: Installation Guide
Desktop Application
The OpenBB Desktop Application provides a comprehensive graphical interface for managing financial data workflows, Python environments, API keys, and backend services. Built with React and TypeScript for the frontend, the desktop app offers users a visual approach to configuring and operating the OpenBB platform without requiring command-line interaction.
Architecture Overview
The desktop application follows a client-side rendering architecture using React Router for navigation and Tauri as the desktop runtime. The frontend communicates with backend services through IPC (Inter-Process Communication) mechanisms provided by Tauri.
graph TD
subgraph Desktop["Desktop Application"]
subgraph UI["React Frontend"]
Routes["Routes/Pages"]
Components["UI Components"]
State["State Management"]
end
subgraph Tauri["Tauri Backend"]
TauriHandlers["Tauri Handlers"]
IPC["IPC Commands"]
end
end
subgraph Services["External Services"]
Python["Python Environments"]
OpenBB["OpenBB Platform"]
APIs["Third-party APIs"]
end
UI --> Tauri
Tauri --> IPC
IPC --> ServicesKey Technologies
| Component | Technology | Purpose |
|---|---|---|
| Frontend Framework | React 18+ | UI rendering and component management |
| Routing | React Router (createFileRoute) | Page navigation and URL handling |
| Desktop Runtime | Tauri | Native desktop functionality |
| Styling | Tailwind CSS + Theme System | Visual design and theming |
| State | React Hooks | Local and shared state management |
Route Structure
The desktop application defines several key routes for managing different aspects of the OpenBB platform.
Route Hierarchy
| Route Path | Component | Purpose |
|---|---|---|
/backends | BackendsPage | Manage backend services and configurations |
/environments | EnvironmentsPage | Create and manage Python environments |
/installation-progress | InstallationProgressPage | Track installation workflow progress |
/api-keys | APIKeysPage | Manage third-party API credentials |
Sources: desktop/src/routes/environments.tsx (route definition)
Backend Management
The /backends route provides functionality for managing OpenBB backend services, including starting, stopping, and configuring backend processes.
Backend Configuration Panel
graph LR
A[User Action] --> B{Backend Running?}
B -->|Yes| C[Show Process ID]
B -->|No| D[Start Backend]
D --> E[Wait for Initialization]
E --> F[Confirm Service URL]
F --> G[Display Backend Panel]Key Features
- Process Management: Monitor and control backend process lifecycle
- Working Directory Selection: Configure the directory from which the backend executable runs (defaults to
{installation_directory}/backends) - Command Configuration: Customize the backend startup command (default:
openbb-api) - Service Initialization: Display loading state while waiting for service to initialize
- Process ID Tracking: Show the PID of running backend processes
Sources: desktop/src/routes/backends.tsx
Backend Configuration Parameters
| Parameter | Type | Description | Default |
|---|---|---|---|
command | string | Backend startup command | openbb-api |
workingDir | string | Execution directory | {install_dir}/backends |
extractedPid | number | Process identifier | - |
urlConfirmed | boolean | Service URL verified | false |
Environment Management
The /environments route enables users to create, manage, and configure Python virtual environments using Miniforge.
Environment Creation Workflow
graph TD
A[Start Create Environment] --> B[Step 1: Name]
B --> C{Valid Name?}
C -->|No| B
C -->|Yes| D[Step 2: Python Version]
D --> E[Select Python]
E --> F[Step 3: Extensions]
F --> G[Select Extensions]
G --> H[Create Environment]
H --> I{Success?}
I -->|No| J[Show Error + Retry]
I -->|Yes| K[Environment Ready]Environment Name Validation
Environment names must follow specific conventions for compatibility with Conda:
Pattern: /^[a-z0-9-]+$/
Allowed: lowercase letters, numbers, hyphens
Forbidden: uppercase, spaces, special characters
Sources: desktop/src/routes/environments.tsx
Environment States
| State | Description | UI Treatment |
|---|---|---|
loading | Fetching environment list | Spinner + loading text |
creating | Environment creation in progress | Progress indicator |
error | Operation failed | Red error panel with retry option |
complete | Operation successful | Success message |
Installation Progress
The installation workflow guides users through the complete setup process in sequential phases.
Installation Phases
graph LR
A[phase: version_select] --> B[phase: extension_select]
B --> C[phase: installing]
C --> D{Result}
D -->|Success| E[Complete]
D -->|Failure| F[Error State]
D -->|Cancelled| G[phase: cancelled]Phase Breakdown
| Phase | Step Indicator | Description |
|---|---|---|
version_select | STEP 1 OF 3 | Select Python version via Miniforge |
extension_select | STEP 3 OF 3 | Choose OpenBB extensions and additional packages |
installing | N/A | Installation in progress |
cancelled | N/A | User cancelled installation |
error | N/A | Installation failed |
Initial Installation Components
The base installation includes:
- Miniforge: Python environment manager
- OpenBB Environment: Core libraries and dependencies
- iPython & Jupyter Lab: Interactive computing tools
Sources: desktop/src/routes/installation-progress.tsx
Extension Management
Extensions extend the functionality of the OpenBB platform by providing additional data sources, analytical tools, and integrations.
Extension Selector Component
The AddExtensionSelector component provides a user interface for browsing and selecting extensions.
graph TD
A[AddExtensionSelector] --> B[Extension List]
A --> C[Conda Packages]
A --> D[Custom PyPI Packages]
A --> E[OpenBB Extensions]
B --> F[Search/Filter]
C --> G[Package Counter]
D --> G
E --> G
G --> H[Install Button]Extension Selection States
| Selection Type | Counter Display | Example |
|---|---|---|
| Conda packages | {n} Conda | 2 Conda |
| PyPI packages | {n} PyPI | 3 PyPI |
| OpenBB extensions | {n} OpenBB extensions | 5 OpenBB extensions |
Sources: desktop/src/components/AddExtensionSelector.tsx
Extension Display Features
Extensions are displayed with setup instructions rendered via ReactMarkdown:
- Images: Max height 300px, lazy loading
- Links: Open in new tab with
rel="noreferrer noopener" - Code blocks: Themed with
bg-theme-tertiary - Paragraphs: Styled with
text-theme-secondary
Sources: desktop/src/components/InstallComponents.tsx
API Key Management
The /api-keys route provides secure storage and management for third-party API credentials.
API Key Operations
| Operation | Description | UI Element |
|---|---|---|
| Add | Add new API key via modal | "Add API Key" button |
| Edit | Modify existing key | Edit icon button |
| Delete | Remove key from storage | Delete action |
| Copy | Copy key value to clipboard | Copy icon button |
| Import | Import keys from JSON/ENV file | "Import Keys" button |
Modal Modes
The API key modal operates in two modes:
| Mode | Header Text | Purpose |
|---|---|---|
add | Add API Key | Create new credential entry |
edit | Edit API Key | Modify existing credential |
File Import Support
The import functionality accepts:
.jsonformat.envformat
Sources: desktop/src/routes/api-keys.tsx
UI Components Library
Icon System
The application uses a centralized icon system defined in Icon.tsx.
// OpenBB Logo Component
export const FileIcon = (props: React.ComponentProps<"svg">) => (
<svg viewBox="0 0 16 16" fill="none" stroke="currentColor" {...props}>
{/* SVG path data */}
</svg>
);
Icons are integrated using the CustomIcon component with named identifiers.
Button Variants
| Variant | Class | Usage |
|---|---|---|
primary | button-primary | Main actions |
secondary | button-secondary | Secondary actions |
outline | button-outline | Alternative actions |
ghost | button-ghost | Subtle actions |
danger | button-danger | Destructive actions |
Tooltip System
Tooltips provide contextual help using the Tooltip component:
<Tooltip content="Descriptive text" className="tooltip-theme">
<Button>Action</Button>
</Tooltip>
Theme System
The desktop application implements a comprehensive theme system with CSS custom properties.
Theme Color Classes
| Class | Usage | Example |
|---|---|---|
bg-theme-primary | Main background | Cards, panels |
bg-theme-secondary | Secondary background | Modals, dialogs |
bg-theme-tertiary | Tertiary background | Input fields, wells |
text-theme-primary | Primary text | Headings, labels |
text-theme-secondary | Secondary text | Body content |
text-theme-muted | Muted text | Hints, placeholders |
border-theme | Border color | Input borders |
border-theme-accent | Accent borders | Focus states |
Status Colors
| Status | Color | Usage |
|---|---|---|
| Success | green-500 | Completed actions |
| Error | red-500 | Failed operations |
| Warning | yellow-500 | Warnings |
| Info | accent-color | Loading, progress |
State Management Patterns
Form State Handling
Input validation follows a consistent pattern:
// Name validation regex
const isValidName = (name: string): boolean => {
return /^[a-z0-9-]+$/.test(name);
};
Loading States
| State Variable | Component | Indicator |
|---|---|---|
creationLoading | Environment creation | Spinner + "This may take several minutes" |
extensionsLoading | Extension list | Loading indicator |
isInstalling | Extension installation | "Installing..." button text |
Error Handling
Errors are displayed in styled containers:
{error && (
<div className="p-3 bg-theme-secondary border border-red-500/50 rounded text-red-500">
<p>{error}</p>
</div>
)}
MCP Server Integration
The desktop application can expose backend functionality through the Model Context Protocol (MCP), allowing integration with AI assistants and external tools.
MCP Configuration Options
| Property | Type | Description |
|---|---|---|
expose | Optional[bool] | Hide/show route from MCP |
mcp_type | Optional[MCPType] | Classification: tool, resource, resource_template |
methods | Optional[list[HTTPMethod]] | HTTP methods to expose |
Sources: openbb_platform/extensions/mcp_server/README.md
Navigation and Route Validation
Routes use search parameter validation:
export const Route = createFileRoute("/environments")({
component: EnvironmentsPage,
validateSearch: (search: Record<string, unknown>) => {
return {
directory: search.directory as string | undefined,
userDataDir: search.userDataDir as string | undefined,
};
},
});
Route Search Parameters
| Parameter | Type | Source | |
|---|---|---|---|
directory | `string \ | undefined` | Installation directory path |
userDataDir | `string \ | undefined` | User data directory path |
Sources: desktop/src/routes/environments.tsx (route definition)
Doramagic Pitfall Log
Source-linked risks stay visible on the manual page so the preview does not read like a recommendation.
The project may affect permissions, credentials, data exposure, or host boundaries.
The project may affect permissions, credentials, data exposure, or host boundaries.
The project may affect permissions, credentials, data exposure, or host boundaries.
The project may affect permissions, credentials, data exposure, or host boundaries.
Doramagic Pitfall Log
Doramagic extracted 16 source-linked risk signals. Review them before installing or handing real data to the project.
1. Security or permission risk: [FR] Add Bank of Canada Valet API as a new provider extension
- Severity: high
- Finding: Security or permission risk is backed by a source signal: [FR] Add Bank of Canada Valet API as a new provider extension. Treat it as a review item until the current version is checked.
- User impact: The project may affect permissions, credentials, data exposure, or host boundaries.
- Recommended check: Open the linked source, confirm whether it still applies to the current version, and keep the first run isolated.
- Evidence: Source-linked evidence: https://github.com/OpenBB-finance/OpenBB/issues/7490
2. Security or permission risk: [FR] Add Real-time Cryptocurrency Data Provider Integration
- Severity: high
- Finding: Security or permission risk is backed by a source signal: [FR] Add Real-time Cryptocurrency Data Provider Integration. Treat it as a review item until the current version is checked.
- User impact: The project may affect permissions, credentials, data exposure, or host boundaries.
- Recommended check: Open the linked source, confirm whether it still applies to the current version, and keep the first run isolated.
- Evidence: Source-linked evidence: https://github.com/OpenBB-finance/OpenBB/issues/7177
3. Security or permission risk: [FR] Signed audit receipts for MCP server tool calls (regulatory compliance)
- Severity: high
- Finding: Security or permission risk is backed by a source signal: [FR] Signed audit receipts for MCP server tool calls (regulatory compliance). Treat it as a review item until the current version is checked.
- User impact: The project may affect permissions, credentials, data exposure, or host boundaries.
- Recommended check: Open the linked source, confirm whether it still applies to the current version, and keep the first run isolated.
- Evidence: Source-linked evidence: https://github.com/OpenBB-finance/OpenBB/issues/7455
4. Security or permission risk: Security or permission risk needs validation
- Severity: high
- Finding: Security or permission risk is backed by a source signal: Security or permission risk needs validation. Treat it as a review item until the current version is checked.
- User impact: The project may affect permissions, credentials, data exposure, or host boundaries.
- Recommended check: Open the linked source, confirm whether it still applies to the current version, and keep the first run isolated.
- Evidence: packet_text.keyword_scan | github_repo:323048702 | https://github.com/OpenBB-finance/OpenBB | matched secret / private key / privacy / trading / finance keyword
5. Installation risk: Developers should check this installation risk before relying on the project: OpenBB Platform v4.5.0
- Severity: medium
- Finding: Developers should check this installation risk before relying on the project: OpenBB Platform v4.5.0
- User impact: Upgrade or migration may change expected behavior: OpenBB Platform v4.5.0
- Recommended check: Before packaging this project, run the relevant install/config/quickstart check for: OpenBB Platform v4.5.0. Context: Observed when using python
- Evidence: failure_mode_cluster:github_release | fmev_3acb4d0463ffb0d96b55088fc42477e1 | https://github.com/OpenBB-finance/OpenBB/releases/tag/v4.5.0 | OpenBB Platform v4.5.0
6. Installation risk: Developers should check this installation risk before relying on the project: OpenBB Platform v4.6.0
- Severity: medium
- Finding: Developers should check this installation risk before relying on the project: OpenBB Platform v4.6.0
- User impact: Upgrade or migration may change expected behavior: OpenBB Platform v4.6.0
- Recommended check: Before packaging this project, run the relevant install/config/quickstart check for: OpenBB Platform v4.6.0. Context: Observed when using python
- Evidence: failure_mode_cluster:github_release | fmev_c32f0b655c075b88a71f35f893ae1f90 | https://github.com/OpenBB-finance/OpenBB/releases/tag/v4.6.0 | OpenBB Platform v4.6.0
7. Installation risk: Developers should check this installation risk before relying on the project: [Bug] Openbb 4.5.0 cannot import name 'OBBject_EquityInfo' from 'openbb_core.app.provider_interface'
- Severity: medium
- Finding: Developers should check this installation risk before relying on the project: [Bug] Openbb 4.5.0 cannot import name 'OBBject_EquityInfo' from 'openbb_core.app.provider_interface'
- User impact: Developers may fail before the first successful local run: [Bug] Openbb 4.5.0 cannot import name 'OBBject_EquityInfo' from 'openbb_core.app.provider_interface'
- Recommended check: Before packaging this project, run the relevant install/config/quickstart check for: [Bug] Openbb 4.5.0 cannot import name 'OBBject_EquityInfo' from 'openbb_core.app.provider_interface'. Context: Observed when using python, docker
- Evidence: failure_mode_cluster:github_issue | fmev_a7115ea0142ee2b52fad8606fc7d47ec | https://github.com/OpenBB-finance/OpenBB/issues/7279 | [Bug] Openbb 4.5.0 cannot import name 'OBBject_EquityInfo' from 'openbb_core.app.provider_interface'
8. Installation risk: Developers should check this installation risk before relying on the project: [Bug] PyWry WebView Fails to Launch on Ubuntu 24.04
- Severity: medium
- Finding: Developers should check this installation risk before relying on the project: [Bug] PyWry WebView Fails to Launch on Ubuntu 24.04
- User impact: Developers may fail before the first successful local run: [Bug] PyWry WebView Fails to Launch on Ubuntu 24.04
- Recommended check: Before packaging this project, run the relevant install/config/quickstart check for: [Bug] PyWry WebView Fails to Launch on Ubuntu 24.04. Context: Observed when using python, linux
- Evidence: failure_mode_cluster:github_issue | fmev_c48a7161974013fd9895ea98894b35bd | https://github.com/OpenBB-finance/OpenBB/issues/7148 | [Bug] PyWry WebView Fails to Launch on Ubuntu 24.04
9. Installation risk: Developers should check this installation risk before relying on the project: [FR] Add Bank of Canada Valet API as a new provider extension
- Severity: medium
- Finding: Developers should check this installation risk before relying on the project: [FR] Add Bank of Canada Valet API as a new provider extension
- User impact: Developers may fail before the first successful local run: [FR] Add Bank of Canada Valet API as a new provider extension
- Recommended check: Before packaging this project, run the relevant install/config/quickstart check for: [FR] Add Bank of Canada Valet API as a new provider extension. Context: Observed when using python
- Evidence: failure_mode_cluster:github_issue | fmev_3ee0b5efd611f4c6c49174e1a6ba1006 | https://github.com/OpenBB-finance/OpenBB/issues/7490 | [FR] Add Bank of Canada Valet API as a new provider extension
10. Installation risk: [Bug] PyWry WebView Fails to Launch on Ubuntu 24.04
- Severity: medium
- Finding: Installation risk is backed by a source signal: [Bug] PyWry WebView Fails to Launch on Ubuntu 24.04. Treat it as a review item until the current version is checked.
- User impact: First-time setup may fail or require extra isolation and rollback planning.
- Recommended check: Open the linked source, confirm whether it still applies to the current version, and keep the first run isolated.
- Evidence: Source-linked evidence: https://github.com/OpenBB-finance/OpenBB/issues/7148
11. Installation risk: [Bug] Widgets not saving their position and size after refresh
- Severity: medium
- Finding: Installation risk is backed by a source signal: [Bug] Widgets not saving their position and size after refresh. Treat it as a review item until the current version is checked.
- User impact: First-time setup may fail or require extra isolation and rollback planning.
- Recommended check: Open the linked source, confirm whether it still applies to the current version, and keep the first run isolated.
- Evidence: Source-linked evidence: https://github.com/OpenBB-finance/OpenBB/issues/7479
12. Configuration risk: Developers should check this configuration risk before relying on the project: [FR] Add Real-time Cryptocurrency Data Provider Integration
- Severity: medium
- Finding: Developers should check this configuration risk before relying on the project: [FR] Add Real-time Cryptocurrency Data Provider Integration
- User impact: Developers may misconfigure credentials, environment, or host setup: [FR] Add Real-time Cryptocurrency Data Provider Integration
- Recommended check: Before packaging this project, run the relevant install/config/quickstart check for: [FR] Add Real-time Cryptocurrency Data Provider Integration. Context: Source discussion did not expose a precise runtime context.
- Evidence: failure_mode_cluster:github_issue | fmev_45a17b16742dbd042ef1b9e8d373939d | https://github.com/OpenBB-finance/OpenBB/issues/7177 | [FR] Add Real-time Cryptocurrency Data Provider Integration
Source: Doramagic discovery, validation, and Project Pack records
Community Discussion Evidence
These external discussion links are review inputs, not standalone proof that the project is production-ready.
Count of project-level external discussion links exposed on this manual page.
Open the linked issues or discussions before treating the pack as ready for your environment.
Community Discussion Evidence
Doramagic exposes project-level community discussion separately from official documentation. Review these links before using OpenBB with real data or production workflows.
- [[FR] Signed audit receipts for MCP server tool calls (regulatory complia](https://github.com/OpenBB-finance/OpenBB/issues/7455) - github / github_issue
- [[FR] Add Bank of Canada Valet API as a new provider extension](https://github.com/OpenBB-finance/OpenBB/issues/7490) - github / github_issue
- [[Bug] Widgets not saving their position and size after refresh](https://github.com/OpenBB-finance/OpenBB/issues/7479) - github / github_issue
- [[FR] Add Real-time Cryptocurrency Data Provider Integration](https://github.com/OpenBB-finance/OpenBB/issues/7177) - github / github_issue
- [[Bug] Openbb 4.5.0 cannot import name 'OBBject_EquityInfo' from 'openbb_](https://github.com/OpenBB-finance/OpenBB/issues/7279) - github / github_issue
- [[Bug] PyWry WebView Fails to Launch on Ubuntu 24.04](https://github.com/OpenBB-finance/OpenBB/issues/7148) - github / github_issue
- ODP Desktop v1.0.2 - github / github_release
- OpenBB V4.7.0 - github / github_release
- ODP Desktop v1.0.1 - github / github_release
- OpenBB Platform v4.6.0 - github / github_release
- OpenBB Platform v4.5.0 - github / github_release
- Security or permission risk needs validation - GitHub / issue
Source: Project Pack community evidence and pitfall evidence