brapi

brapi is a skill for Claude Code, Codex from brapi-dev/brapi-skills. It costs 53 tokens per session (1,750 once invoked), scanned A, original, MIT.

An integration guide for brapi.dev, a service that provides current and past Brazilian financial-market data, including B3 stocks, funds, currencies, crypto, and economic indicators.

In plain words
What is it for?
Use it to build market-data requests, dashboards, data pipelines, typed REST clients, or compatible AI workflows. It does not cover investment advice, trading orders, or guaranteed future prices.
Why use it?
It helps developers choose the right brapi interface and understand its available fields, requests, and limits instead of guessing how the service works.

Skill for Claude CodeCodex

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add skills/brapi-dev/brapi-skills/brapi
Any agent
npx skills add brapi-dev/brapi-skills --skill brapi
Clone the repo
git clone --depth 1 https://github.com/brapi-dev/brapi-skills

Made for: Claude Code, Codex.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for brapi

README.md
[![agentmods](https://agentmods.dev/badge/skills/brapi-dev/brapi-skills/brapi.svg)](https://agentmods.dev/skills/brapi-dev/brapi-skills/brapi)
Your own site
<a href="https://agentmods.dev/skills/brapi-dev/brapi-skills/brapi"><img src="https://agentmods.dev/badge/skills/brapi-dev/brapi-skills/brapi.svg" alt="Measured on agentmods" height="20"></a>
Per session 53 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,750 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00053 $0.01750
Opus 5 $0.00026 $0.00875
Sonnet 5 $0.00011 $0.00350
Haiku 4.5 $0.00005 $0.00175

Measured 5d ago against content hash 3e8407fc4f13, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-05, from the pricing page.

Security

Grade A, and why

brapi scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 5d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

skills/brapi/SKILL.md · 98 lines

How it starts

The opening of the file, as written. The whole thing — 98 lines — stays where its author put it; the contents beside it link to each section on GitHub.

brapi integration

brapi.dev provides current and historical Brazilian financial market data. Use this skill when a task needs B3 stocks, FIIs, dividends, fundamentals, currencies, crypto, or Brazilian economic indicators.

When to use brapi

  • Use REST for deterministic requests, data pipelines, dashboards, research, and typed application clients.
  • Use MCP Streamable HTTP for conversational market-data lookups in a compatible AI client.
  • Use the GPT Action schema for a Custom GPT that needs a focused read-only REST surface.
  • Use another source when the task needs investment advice, order execution, brokerage actions, or a guarantee of future prices.

Request workflow

  1. Read llms.txt and select the narrowest resource.
  2. Read OpenAPI for the operation ID, parameters, and response schema.
  3. Use the endpoint map to narrow the data group.
  4. Use /api/v2/dictionary when a field, unit, formula, or null value is unclear.
  5. Use /api/v2 endpoints for new REST integrations.
  6. Use symbols query parameters when an endpoint supports multiple tickers.
  7. Test with PETR4, VALE3, MGLU3, or ITUB4 before using other symbols.
  8. Read RateLimit-Limit, RateLimit-Remaining, and RateLimit-Reset.
  9. Wait for Retry-After after HTTP 429.
  10. Read Deprecation, Sunset, and the deprecation link before changing a legacy integration.

Interfaces

REST

Use the REST API at https://brapi.dev. Send Authorization: Bearer YOUR_TOKEN to protected endpoints. Public sandbox requests can use the four sandbox tickers without a token.

Response fields

Use GET /api/v2/dictionary?search=patrimônio to find a field by name or label. Use GET /api/v2/dictionary?category=fii to list fields for one data group. Keep requestedAt, market-data timestamps, units, and null values in the result. Do not guess a field meaning or replace null with zero.

MCP

Use the MCP Streamable HTTP endpoint at https://brapi.dev/api/mcp/mcp. Read the server card first. Use OAuth with the mcp:read scope when the MCP client cannot store an API token safely. After the MCP connection is ready, start with PETR4, VALE3, MGLU3, or ITUB4. MCP can access these sandbox tickers. The sandbox allowlist is separate from production coverage. Use get_dictionary when a tool response contains an unfamiliar field or unit.

Read the full file on GitHub · 98 lines

Files

What ships with it

6 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 5d ago First seen · 98 lines · 53 tokens per session scan A 3e8407fc4f13

Subscribe to this mod's changes

brapi is a skill published in the GitHub repository brapi-dev/brapi-skills (3 stars, last pushed 13d ago), licensed MIT. It adds 53 tokens to every session and 1,750 once invoked, about $0.0003 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.

Related

Other skills, from other repositories

hithink-finance-data

用于 Agent 通过 hithink-finance CLI 管理本地 DuckDB:初始化、同步、状态、校验、迁移、修复、清理、删除、只读 SQL、导出;远端实时数据转对应业务 skill。.

HiThink-Tech/Financial-API · 60 tokens

hithink-finance-special-data

用于 Agent 通过 hithink-finance CLI 查询特色数据:涨停池、跌停池、炸板池、连板天梯、个股异动、异动原因、飙升榜、热股榜、热度历史/趋势、龙虎榜、游资和机构榜;普通行情转 hithink-finance-market。.

HiThink-Tech/Financial-API · 82 tokens

hithink-finance-index

用于 Agent 通过 hithink-finance CLI 查询同花顺指数/概念/行业/地域/特色指数目录、指数成分股、指数快照和指数历史;个股行情转 hithink-finance-market,股票代码搜索转 hithink-finance-symbol。.

HiThink-Tech/Financial-API · 68 tokens

hithink-finance-symbol

用于 Agent 通过 hithink-finance CLI 处理标的目录、股票/指数代码搜索、名称或 ticker 到 thscode 的消歧、A 股或指数代码表分页导出;行情价格转 hithink-finance-market,指数成分转 hithink-finance-index。.

HiThink-Tech/Financial-API · 71 tokens

hithink-finance-valuation

用于 Agent 通过 hithink-finance CLI 查询 A 股当前估值快照,包括市盈率、市净率、市销率和市现率;历史估值、ROE 和投资建议不在本 skill 范围。.

HiThink-Tech/Financial-API · 58 tokens

hithink-finance

当用户或 Agent 需要通过同花顺金融数据服务获取、查询、同步、分析或导出 A 股行情、财报、估值、指数、板块、公募基金、特色数据或本地 DuckDB 数据,或需要选择、安装、配置、诊断 REST API、MCP、hithink-finance CLI、Python SDK/marketdb 时使用。.

HiThink-Tech/Financial-API · 87 tokens