Documentation Index
Fetch the complete documentation index at: https://docs.brew.new/llms.txt
Use this file to discover all available pages before exploring further.
Overview
The Brew SDK uses the same API keys as the raw REST API. Every request is authenticated with your Brew API key. The SDK sends it asAuthorization: Bearer brew_your_api_key for you. The server
also accepts the alternate X-API-Key: brew_your_api_key header for
raw HTTP callers, but the SDK standardizes on Bearer to keep one
canonical wire format.
Each API key is bound to exactly one brand at creation time, so
the SDK never asks you to pass a brandId for any endpoint. The Brew
API does not accept brandId anywhere in a request body or query —
sending one returns 400 INVALID_REQUEST. To act on a different
brand, switch brands in the dashboard and create a new key. See the
API introduction
for the full breakdown of brand-scoped vs. organization-wide endpoints
and the permission scopes (contacts, emails, all) each route
requires.
Get Your API Key
Open the API settings page
Go to brew.new/settings/api.
Pick the brand
Make sure the brand active in the dashboard is the one you want
this key to act on. Each key is permanently bound to one brand at
creation; you cannot retarget it later.
Recommended Setup
Use an environment variable in your own app code:Validate The Key
Use a simple read call to make sure the key works:Security Notes
- Keep API keys on the server only.
- Use different keys for development and production.
- Rotate keys if you think one was exposed.
- Log the
x-request-idfrom failed calls when debugging.
Next Steps
TypeScript Installation
Install and configure
@brew.new/sdk.API Introduction
See the raw public API contract.
Need Help?
Our team is ready to support you at every step of your journey with Brew. Choose the option that works best for you:- Self-Service Tools
- Talk to Our Team
Search Documentation
Type in the “Ask any question” search bar at the top left to instantly find relevant documentation pages.
ChatGPT/Claude Integration
Click “Open in ChatGPT” at the top right of any page to analyze documentation with ChatGPT or Claude for deeper insights.