AI Agent Access (MCP)
FlareBuilder exposes a Model Context Protocol (MCP) server so AI agents — Claude, or any MCP-compatible client — can read and draft content in your organization directly, using your template schemas as their guide.
Enabling MCP Access
Two switches must both be on before the /mcp endpoint accepts requests for your organization:
- A tenant admin enables it tenant-wide: Settings → AI Agent Access → Enable MCP Server.
- Each individual user who wants to connect an agent creates their own personal agent token from their Agent Tokens page (editors and above only — contributors can’t issue tokens).
Agent Tokens
A token belongs to a single user and is shown once, at creation — format fb_agt_.... Store it like a password; FlareBuilder only ever stores its hash.
- Up to 5 active tokens per user
- Every token is scoped to a subset of the creating user’s own privileges — today the only grantable scope is create draft content, regardless of how much the issuing user can otherwise do
- Revoking a token (or demoting its owner below editor) invalidates it immediately
Connecting an Agent
The server is a single stateless HTTP endpoint per organization:
POST https://your-org.flarebuilder.com/mcpAuthorization: Bearer fb_agt_...claude mcp add --transport http flarebuilder \ https://your-org.flarebuilder.com/mcp \ --header "Authorization: Bearer fb_agt_..."Claude Desktop doesn’t yet speak streamable HTTP directly — bridge it with mcp-remote in your MCP config:
{ "mcpServers": { "flarebuilder": { "command": "npx", "args": [ "mcp-remote", "https://your-org.flarebuilder.com/mcp", "--header", "Authorization: Bearer fb_agt_..." ] } }}Any MCP client that supports the streamable HTTP transport can connect directly — point it at the URL above with the Authorization header set. No session negotiation is required; each request is authenticated independently.
Available Tools
| Tool | Purpose | Requires draft-create scope? |
|---|---|---|
list_templates | List enabled templates for the organization — call this first | No |
get_template_schema | Get a template’s full field schema (sections, fields, types, validation) | No |
list_tags | List existing tags, to reuse instead of inventing new ones | No |
list_channels | List feed channels, for create_content_draft’s channel_id | No |
create_content_draft | Create a new content item as a draft | Yes |
upload_media | Upload a base64-encoded image/file, returns a URL for use in a draft’s fields | Yes |
list_content | List content items, filterable by template, tags, or status | No |
get_content | Get a single content item by ID, including all field values | No |
search_content | Full-text relevance search over content (title and body) | No |
Typical Flow
list_templates— discover validtemplate_idvalues.get_template_schema— read the field schema for the template you’re targeting, so field values match the expected sections/types.list_tags/list_channels(optional) — reuse existing tag names and pick achannel_idinstead of guessing.upload_media(optional) — upload any images first, and use the returned URLs in the next step.create_content_draft— create the item withtemplate_id,title, andmetadatashaped as{ section_id: { field_id: value } }, matching the schema from step 2.
// create_content_draft input{ "template_id": "tmpl_abc123", "title": "Q3 Product Update", "metadata": { "content": { "description": "A summary of what shipped this quarter.", "body": "<p>...</p>" } }, "tags": ["news", "product"], "channel_id": null}The response never includes a date_published — drafts are always unpublished until a human reviews and publishes them from the FlareBuilder editor.
Errors
| Error | Meaning |
|---|---|
Missing bearer token (401) | No Authorization: Bearer ... header was sent |
Invalid or unauthorized token (401) | Token is malformed, revoked, expired, or belongs to a different organization |
MCP agent access disabled (403) | The tenant admin has not enabled Settings → AI Agent Access |
AI agent access (MCP) is not included in your current plan (403) | Your plan doesn’t include the mcp_agent feature — upgrade to enable it |
This agent token is not scoped for {privilege} | The tool called requires a privilege this token wasn’t granted |