Using Barfinex with MCP (AI tools)
Connect AI assistants to authenticated Barfinex Provider operations without exposing private runtime configuration in public content.
What is Provider MCP?
Provider MCP exposes authenticated Barfinex Provider REST operations as structured tools for AI assistants in a private runtime environment. Public website content should treat account, order, replay, EventSink, and operator tools as private capabilities, not as public web APIs.
Provider OpenAPI is the source for dynamic tool discovery. When Provider exposes new documented private operations, the MCP server can refresh its tool list.
Tool model
Static tools are always available:
provider_health- check Provider availability;provider_openapi- fetch the current OpenAPI document;provider_refresh_openapi_tools- rebuild dynamic tools;provider_request- generic fallback for documented Provider requests.
Dynamic tools are generated from OpenAPI operations. Tool names, inputs, and methods depend on the current Provider API.
Configuration
Configure three things in your MCP client or local runtime:
- Provider API base URL.
- Provider-issued bearer token, stored in the client's secret configuration.
- Optional request timeout and local TLS settings for development.
Do not publish tokens, local secret names, or private workspace configuration in public docs, screenshots, or shared prompts.
Authentication
Authenticated Provider routes require a Provider-issued token. Pass it through your MCP client's secret mechanism or through the per-call credential field supported by your local MCP setup. Do not place private runtime credentials or operator endpoint examples in public website pages.
Example client entry
Paths and scripts depend on your local Barfinex workspace:
{
"mcpServers": {
"barfinex-provider": {
"command": "npm",
"args": ["run", "start:mcp:provider:dev"],
"cwd": "/path/to/trading.apps"
}
}
}
Limitations
- Only documented authenticated REST operations are exposed as MCP tools.
- WebSocket events are not MCP tools.
- If Provider is unavailable at startup, refresh OpenAPI tools after Provider is reachable.
- The public website only uses sanitized read-only market-intelligence projections; MCP remains an authenticated operator/developer integration.
For the REST surface, see Provider API reference. For the platform overview, see Barfinex architecture.