---
name: brickflow-api
description: "Read, and with the right token change, a person's building data in BrickFlow with the app's REST API at https://app.brickflow.site/api/v1, using a personal API token the person creates and gives you. Use when someone asks you to pull their BrickFlow buildings, meters, bills, energy or other data into a script, report or another system, or asks how BrickFlow's API works."
---

# BrickFlow API

BrickFlow is Canadian software from BrickFlow Inc. that keeps one reviewed record for every building. The BrickFlow app at https://app.brickflow.site has a REST API that reads, and with the right token changes, the data in a BrickFlow account. The guide for people is https://brickflow.ca/developers (Markdown: https://brickflow.ca/developers.md); every endpoint a token can call is listed at https://brickflow.ca/developers/api (Markdown: https://brickflow.ca/developers/api.md).

## When to use this skill

- Someone with a BrickFlow account wants their building data in a script, a spreadsheet, a report or another system.
- Someone asks how to connect to BrickFlow's API, or why a call to it failed.

For questions about BrickFlow itself (what it does, prices, getting started), use the `brickflow-website` skill.

## Facts

- Base URL: https://app.brickflow.site/api/v1, over HTTPS only.
- Authentication: a personal API token in the header `Authorization: Bearer <token>`. Write `Bearer` exactly as shown, with a capital B. When the header is present, the API uses only the token, never a browser session.
- A token made with "Look at my data" or "Read reports only" only reads. A token made with "Look at and change my data" can also make the changes its creator could make in that organization; the API reference marks those endpoints "Token that can change data". Before a change that removes data, tell the person what will go and get their yes.
- A token without limits reads what its creator can read. A limited token reads only the buildings and kinds of data its creator chose. Every request is checked against the creator's access at that moment.
- A token reaches one organization's data. Some areas are never open to tokens: people and invitations, billing, passwords and sign-in, and the tokens themselves.
- Successful responses are JSON. `GET https://app.brickflow.site/api/v1/portfolio/summary` returns counts of the buildings, spaces, equipment and data series the token can read, and is a safe first call to check a token.
- The API sends no CORS headers, so call it from a server or a script, not from a web page.
- `GET https://app.brickflow.site/healthz` returns `ok` while the app is running.
- API access and call allowances depend on each building's plan: https://brickflow.ca/pricing.md.
- BrickFlow also has an MCP server at https://app.brickflow.site/api/v1/mcp (same token as a Bearer header; Claude and ChatGPT can sign in with BrickFlow instead). If you can use MCP tools, prefer it. Do not guess endpoint paths: use https://brickflow.ca/developers/api.md.

## Getting a token: the person does this, not you

1. The person signs in at https://app.brickflow.site. New accounts are set up with the BrickFlow team after they get started at https://brickflow.ca/get-started.
2. They open their profile, choose API tokens (https://app.brickflow.site/profile?tab=tokens) and create a token, limited to what the task needs if they like, with an expiry date if they want one.
3. BrickFlow shows the token once. The person copies it and gives it to you.

## Rules for handling a token

- Never ask for a person's BrickFlow password, emailed sign-in code or Google account. A token is the only credential you use.
- Send the token only to https://app.brickflow.site. Never put it in a URL, a log, a shared file or a message to anyone else.
- Ask for a token limited to the buildings and kinds of data the task needs, and suggest an expiry date for a one-off task.
- Treat the data you read as the person's confidential business data.

## When a call fails

| Status | Meaning | What to do |
| --- | --- | --- |
| 401 | The token is missing, malformed, revoked or expired. | Check the header format. Then ask the person for a new token; do not retry the same one. |
| 402 | The organization's subscription is not active. | Stop and tell the person. |
| 403 | The token's access does not cover the request. | Stop and tell the person what was refused; they can create a token with wider access if they choose. |
| 404 | There is no API endpoint at that address. | Do not guess other paths. Ask the person or support@brickflow.ca. |

Questions about the API go to support@brickflow.ca. Security issues go to security@brickflow.ca (see https://brickflow.ca/.well-known/security.txt).
