{
  "name": "brainerce",
  "description": "Brainerce is a headless commerce platform (checkout, payments, discounts, inventory and orders) for storefronts that a coding agent builds and connects over an SDK or a REST API. This card describes the capabilities Brainerce exposes to other agents. Brainerce does not run an A2A JSON-RPC task endpoint; the machine interfaces are the public MCP server listed in interfaces below (read-only documentation and store introspection, the skills on this card) and the REST API described by the OpenAPI document, which is where catalog, cart, checkout, payment and order operations live.",
  "url": "https://brainerce.com",
  "version": "3.0.0",
  "documentationUrl": "https://brainerce.com/docs",
  "provider": {
    "name": "Brainerce",
    "url": "https://brainerce.com",
    "contactEmail": "support@brainerce.com"
  },
  "interfaces": [
    {
      "type": "mcp",
      "transport": "streamable-http",
      "url": "https://mcp-docs.brainerce.com/mcp",
      "description": "Public, unauthenticated MCP server carrying the skills on this card. Its full server card is at https://brainerce.com/.well-known/mcp/server-card.json."
    },
    {
      "type": "openapi",
      "url": "https://brainerce.com/openapi.json",
      "description": "OpenAPI 3.0 description of the Brainerce REST API. Also listed in the RFC 9727 API catalog at https://brainerce.com/.well-known/api-catalog."
    },
    {
      "type": "agent-skills",
      "url": "https://brainerce.com/.well-known/agent-skills/index.json",
      "description": "Index of the instruction documents a coding agent should read before building against Brainerce. Start at https://brainerce.com/skill.md."
    }
  ],
  "skills": [
    {
      "name": "get-sdk-docs",
      "description": "Get Brainerce SDK documentation for a specific topic. Returns setup instructions, API usage, code examples, and best practices. Start with \"setup\" or \"critical-rules\", then request specific topics as needed.",
      "input": {
        "topic": "Required. The SDK documentation topic to retrieve",
        "salesChannelId": "Optional. Sales channel ID (starts with vc_). Used to personalize setup code.",
        "connectionId": "Optional. Deprecated alias of salesChannelId — kept for backwards compat",
        "currency": "Optional. Store currency code (e.g., USD, ILS, EUR). Used in price formatting examples."
      }
    },
    {
      "name": "get-type-definitions",
      "description": "Get TypeScript type definitions from the Brainerce SDK, segmented by domain. Use this when you need to understand the exact shape of objects like Product, Cart, Checkout, Order, etc.",
      "input": {
        "domain": "Required. The domain of types to retrieve. Use \"helpers\" for helper function signatures and common types like StoreInfo, PaginatedResponse. Use \"content\" for FAQ / Footer / Header / Announcement / RichText / Page. Use \"regions\" for Region / TaxClass admin types."
      }
    },
    {
      "name": "get-code-example",
      "description": "Get a short, focused TypeScript snippet for a specific Brainerce SDK operation. Framework-neutral — no Next.js file paths, no Tailwind, no framework-specific imports. Use this when you need the exact shape of a tricky SDK call (payment confirmation, reservation countdown, OAuth redirect, variant selection, etc.). For full SDK reference by topic, use get-sdk-docs instead.",
      "input": {
        "operation": "Required. The SDK operation to get a snippet for."
      }
    },
    {
      "name": "get-store-info",
      "description": "Fetch live store information from the Brainerce API using a sales channel ID. Returns the channel display name (what the user sees in their dashboard), parent store name, currency, and language. Use this to personalize the store being built — prefer the channel name for user-facing text since a single Brainerce store can have multiple sales channels.",
      "input": {
        "salesChannelId": "Optional. Sales channel ID (starts with vc_)",
        "connectionId": "Optional. Deprecated alias of salesChannelId — kept for backwards compat"
      }
    },
    {
      "name": "get-store-capabilities",
      "description": "Get live store capabilities and configured features for a sales channel. Returns what payment providers, OAuth, shipping, discounts, and other features are set up. Use this to discover what your store supports and what pages/components to build.",
      "input": {
        "salesChannelId": "Optional. Sales channel ID (starts with vc_)",
        "connectionId": "Optional. Deprecated alias of salesChannelId — kept for backwards compat"
      }
    },
    {
      "name": "get-integration-guide",
      "description": "Get the Brainerce integration guide for connecting any website to Brainerce. Returns step-by-step instructions with full API endpoints, request/response examples, and code snippets. Use \"core\" for the main guide (products, cart, checkout, payment, orders), \"optional\" for extra features (accounts, OAuth, promotions), or \"rules\" for validation, error codes, and edge cases.",
      "input": {
        "part": "Required. Which part of the integration guide to retrieve. \"core\" = products, cart, checkout, payment, orders (start here). \"optional\" = customer accounts, OAuth, discounts, bundles, downloads. \"rules\" = validation, error codes, edge cases, decision trees, common mistakes."
      }
    },
    {
      "name": "get-critical-rules",
      "description": "Get the do's and don'ts for building a Brainerce store. Returns framework-neutral rules that cause production incidents if violated — SDK usage, state management, auth token handling, checkout invariants, i18n, and type safety. Call this before writing SDK code.",
      "input": {
        "topics": "Optional. Topics to include. Defaults to all."
      }
    },
    {
      "name": "get-business-flows",
      "description": "Get the non-negotiable business flows for a Brainerce store. Returns ordered SDK call sequences for checkout, auth, password reset, OAuth, order confirmation, cart persistence, and inventory reservation. Framework-neutral — no file paths, no framework-specific code. Call this before implementing any of these flows.",
      "input": {
        "flow": "Required. Which flow to retrieve. Use \"all\" to get every flow."
      }
    },
    {
      "name": "get-required-features",
      "description": "Get the functional coverage checklist for a Brainerce store. Returns user-capability-level features (what users must be able to do) rather than pages or file paths. Every feature marked mandatory must exist in the finished build, even when the underlying capability is currently disabled — those features auto-hide and store owners enable them later. Pass a salesChannelId to tune the checklist to the live store; without it, returns the generic complete-store checklist.",
      "input": {
        "salesChannelId": "Optional. Sales channel ID (starts with vc_). Optional — without it, returns the generic checklist.",
        "connectionId": "Optional. Deprecated alias of salesChannelId — kept for backwards compat"
      }
    },
    {
      "name": "get-store-config",
      "description": "Get how a specific storefront feature is actually CONFIGURED for this store — not just whether it's enabled (use get-store-capabilities for that). Returns real shipping destinations, payment provider details, OAuth provider list, tax classes, categories/brands/tags, and active discount banners. Call this before building a feature's UI once get-store-capabilities said it's enabled. Only works reliably against a TEST-mode sales channel — a LIVE channel rejects this server's request (no browser Origin header) and the affected fields come back marked unavailable.",
      "input": {
        "salesChannelId": "Optional. Sales channel ID (starts with vc_)",
        "connectionId": "Optional. Deprecated alias of salesChannelId — kept for backwards compat",
        "section": "Required. Which part of the store to introspect. catalog = categories/brands/tags/metafield definitions. checkout = payment providers, shipping destinations, pickup locations, tax classes, regions. customers = OAuth providers. merchandising = active discount banners. There is deliberately no \"all\" value — request only the section you need; each call costs real tokens."
      }
    },
    {
      "name": "get-product-shape",
      "description": "Get a real product's SHAPE — its option/variant structure and modifier groups (add-ons) — so a generated product page actually renders what this store sells instead of guessing. Call this before building a product-detail page; a product with modifier groups needs an add-on picker, a variable product needs an option selector, and get-store-capabilities alone cannot tell you that. Returns structure, not content: variant/option counts and a small sample, not every row.",
      "input": {
        "salesChannelId": "Optional. Sales channel ID (starts with vc_)",
        "connectionId": "Optional. Deprecated alias of salesChannelId — kept for backwards compat",
        "productId": "Optional. Product ID — provide this OR slug",
        "slug": "Optional. Product slug — provide this OR productId"
      }
    },
    {
      "name": "list-store-products",
      "description": "Orientation: list a store's real products (id, name, slug, and whether each has variants or modifier groups) so you know WHICH product to inspect with get-product-shape before generating its page. Minimal fields on purpose — this is a lookup, not a catalog dump.",
      "input": {
        "salesChannelId": "Optional. Sales channel ID (starts with vc_)",
        "connectionId": "Optional. Deprecated alias of salesChannelId — kept for backwards compat",
        "search": "Optional. Filter by product name or SKU",
        "limit": "Optional. Max products to return (default 20, hard cap 50 — this feeds a context window)"
      }
    }
  ]
}
