LLM Access to Documentation
This documentation is designed to be consumed programmatically by Large Language Models (LLMs) and AI agents. Raw markdown versions of all pages are available through dedicated endpoints.
Endpoints
| Endpoint | Description |
|---|---|
GET /docs/md/sitemap | Index of all documentation pages |
GET /docs/md/{path} | Raw markdown for a specific page |
Both endpoints return text/markdown content type.
Getting Started
Step 1: Fetch the Sitemap
Start by fetching the documentation sitemap to discover all available pages:
curl https://statements.finopsbricks.com/docs/md/sitemap
This returns a markdown-formatted index organized by section:
- Overview - Introduction and getting started
- Product Guide - User-facing feature documentation
- API Reference - Authentication, pagination, error codes
- Endpoints - CRUD operations for each resource
- Object Reference - Data structure documentation
Step 2: Fetch Individual Pages
Use the path from the sitemap to fetch specific documentation:
# Get authentication docs
curl https://statements.finopsbricks.com/docs/md/api/authentication
# Get transaction list endpoint docs
curl https://statements.finopsbricks.com/docs/md/api/endpoints/transactions/list
# Get the Transaction object reference
curl https://statements.finopsbricks.com/docs/md/objects/transaction
URL Pattern
Documentation paths follow this pattern:
/docs/md/{section}/{subsection}/{page}
Examples:
| URL Path | Content |
|---|---|
/docs/md/index | Overview page |
/docs/md/guide/quick-start | Quick start guide |
/docs/md/api/authentication | API authentication |
/docs/md/api/endpoints/transactions/list | List transactions endpoint |
/docs/md/objects/transaction | Transaction object reference |
Available Documentation
API Reference
Core API concepts and patterns:
/docs/md/api/authentication- API key authentication/docs/md/api/pagination- Pagination and filtering/docs/md/api/errors- Error codes and handling
Endpoint Documentation
Each resource has CRUD endpoint documentation:
Transactions
/docs/md/api/endpoints/transactions/index- Overview/docs/md/api/endpoints/transactions/list- List (GET)/docs/md/api/endpoints/transactions/get- Get (GET :id)/docs/md/api/endpoints/transactions/create- Create (POST)/docs/md/api/endpoints/transactions/update- Update (PATCH :id)/docs/md/api/endpoints/transactions/delete- Delete (DELETE :id)/docs/md/api/endpoints/transactions/search- Search (POST)
Accounts
/docs/md/api/endpoints/accounts/index- Overview/docs/md/api/endpoints/accounts/list- List/docs/md/api/endpoints/accounts/get- Get/docs/md/api/endpoints/accounts/create- Create/docs/md/api/endpoints/accounts/update- Update/docs/md/api/endpoints/accounts/delete- Delete/docs/md/api/endpoints/accounts/balance- Computed balance as of a date
Rules
/docs/md/api/endpoints/rules/index- Overview/docs/md/api/endpoints/rules/list- List/docs/md/api/endpoints/rules/get- Get/docs/md/api/endpoints/rules/create- Create/docs/md/api/endpoints/rules/update- Update/docs/md/api/endpoints/rules/delete- Delete
Statements
/docs/md/api/endpoints/statements/index- Overview/docs/md/api/endpoints/statements/list- List/docs/md/api/endpoints/statements/get- Get/docs/md/api/endpoints/statements/update- Update/docs/md/api/endpoints/statements/delete- Delete/docs/md/api/endpoints/statements/archive- Archive (soft-delete, reversible)/docs/md/api/endpoints/statements/unarchive- Restore archived/docs/md/api/endpoints/statements/download- Download original file/docs/md/api/endpoints/statements/retry- Re-run processing pipeline/docs/md/api/endpoints/statements/delete-transactions- Drop linked transactions
Reports
/docs/md/api/endpoints/reports/index- Overview/docs/md/api/endpoints/reports/overview- Top-level snapshot/docs/md/api/endpoints/reports/cashflow- Cashflow/docs/md/api/endpoints/reports/income- Income/docs/md/api/endpoints/reports/expense- Expense/docs/md/api/endpoints/reports/asset- Asset/docs/md/api/endpoints/reports/liability- Liability/docs/md/api/endpoints/reports/transfer- Transfer/docs/md/api/endpoints/reports/balance- Balance/docs/md/api/endpoints/reports/inflow-outflow- Inflow/outflow/docs/md/api/endpoints/reports/data-coverage- Data coverage
Object Reference
Data structure documentation for each resource:
/docs/md/objects/transaction- Transaction fields and types/docs/md/objects/account- Account fields and types/docs/md/objects/rule- Rule structure with conditions and actions/docs/md/objects/statement- Statement fields and processing states
CLI Reference
CLI commands that wrap the same API:
/docs/md/cli/index- Overview offobs stm/docs/md/cli/setup- Install, add an org, store credentials/docs/md/cli/common- Common flags, env vars, exit codes/docs/md/cli/accounts-fobs stm accounts list / show / balance/docs/md/cli/transactions-fobs stm transactions list / show/docs/md/cli/statements-fobs stm statements list / show / download / extracted / rename / update / archive / unarchive / retry / delete-transactions / delete/docs/md/cli/rules-fobs stm rules list / show/docs/md/cli/reports-fobs stm reports show <name>
Integration Patterns
MCP Server Integration
If building an MCP server that provides Statements API context, fetch and cache the relevant documentation:
async function loadStatementsDocs() {
const base = 'https://statements.finopsbricks.com/docs/md';
// Fetch core API docs
const auth = await fetch(`${base}/api/authentication`).then(r => r.text());
const errors = await fetch(`${base}/api/errors`).then(r => r.text());
// Fetch endpoint docs for the resources you need
const transactions = await fetch(`${base}/api/endpoints/transactions/index`).then(r => r.text());
return { auth, errors, transactions };
}
Agent System Prompts
Include documentation URLs in your system prompt so the agent can fetch docs on demand:
When working with the Statements API:
1. Fetch /docs/md/api/authentication for auth patterns
2. Fetch /docs/md/api/endpoints/{resource}/index for resource overview
3. Fetch /docs/md/objects/{resource} for field reference
RAG Integration
Index the documentation for retrieval-augmented generation:
async function indexDocs() {
// Fetch sitemap
const sitemap = await fetch('https://statements.finopsbricks.com/docs/md/sitemap').then(r => r.text());
// Parse URLs from sitemap
const urls = sitemap.match(/\(\/docs\/md\/[^)]+\)/g)
.map(m => m.slice(1, -1));
// Fetch and index each page
for (const url of urls) {
const content = await fetch(`https://statements.finopsbricks.com${url}`).then(r => r.text());
await indexDocument(url, content);
}
}
Response Format
All markdown responses include:
- Frontmatter - YAML metadata (title, description)
- Headers - H1-H4 for document structure
- Tables - Query parameters, field definitions, error codes
- Code blocks - curl examples, JSON responses
- Links - Cross-references to related pages
Example response structure:
---
title: List Transactions
description: Get a paginated list of all transactions
---
# List Transactions
GET /api/v1/transactions
Returns a paginated list of transactions.
## Query Parameters
| Parameter | Type | Default | Description |
|-----------|------|---------|-------------|
| page | number | 1 | Page number |
...
Caching
The markdown endpoints support standard HTTP caching. Consider caching responses to reduce load:
- Documentation changes infrequently
- Cache for at least 1 hour in production
- Invalidate cache on deployment or when debugging
Related
- Authentication - API authentication
- Error Codes - Error handling reference