# brc_create_sales_invoice_gen_ref

Creates a BRC sales invoice with an auto-generated reference using a raw BRC payload. Use when the company is configured for auto-generated sales references. Previews before posting include a Missing or not provided section for blank customer phone or email only — warnings only, do not invent values. Nothing is written to Big Red Cloud until you confirm. In the raw payload, the BRC "Note" field (JSON note) defaults to the customer name (BRC customer "Name" / JSON name) when omitted and must never be set to the product name; the BRC "Delivery To" address (JSON deliveryTo) is only included when explicitly provided. Raw BRC payloads for multi-line sales invoices must use productTrans[] (one object per product line). Each product line must include its own nested acEntries[] for Sales analysis posting — do not send a top-level acEntries array on the invoice. Required header fields include customerId, acCode, entryDate, procDate, saleRepId, saleRepCode, bookTranTypeId, totalNet, totalVAT, total, and unpaid. Red validates line amounts, nested analysis values, qty × unit price (using useTaxInclusiveUnitPrice), and header totals before posting, and returns all validation issues together when the payload does not reconcile. Preview-before-posting still shows what Red will post and waits for confirmation before anything is written to Big Red Cloud. Optional. BRC "Note" field on the sales document (JSON field note). Leave blank to default it to the customer name (BRC customer "Name" / JSON name). Do not use the product name as the note. Only set this when the user explicitly provides a note. Optional. BRC "Delivery To" address (JSON field deliveryTo). Leave blank unless the user explicitly provides a delivery address. Do not invent or default a delivery address (for example "MCP Test"). Requires saleRepId and saleRepCode. Do not use default or demo sales rep values. If missing, list sales reps or ask the user to choose one before creating. Requires analysisCategoryId and accountCode from a Sales Analysis category on each product line. Do not default to CR01/Customer or the first listed category. Set confirmCrAnalysisCategory=true only after the user confirms a CR account code is intentional. When Gross Price Entry is enabled for sales invoicing, this tool requires priceBasis. Use priceBasis "gross" when unit prices are VAT-inclusive/gross, or priceBasis "net" when unit prices are VAT-exclusive/net. Do not tell the user to disable Gross Price Entry if they have provided priceBasis. Do not invent productId values and do not use productId 0 or 1 as placeholders. productId 0 and 1 are treated as placeholders and are blocked at runtime before preview-before-posting and before posting. If a product line is needed, first call brc_list_products and use a real product from the connected company. If no suitable product exists, ask the user whether to create/select a product, or use a service/non-product line only if the endpoint supports it. Sales invoices must use Sales VAT rates. Purchase/non-Sales VAT rates are blocked before preview-before-posting and before posting, even if the VAT percentage matches. Requires routeToken from brc_route_request for the matching action workflow. Call brc_route_request first with the user's complete original action request. Retain the returned routeToken through lookup, preview, and confirmation, and pass the same token on the final permitted transactional tool call. Never invent a placeholder token. A routeToken is not permission to post — preview-before-posting and confirmWrite/confirmDelete still apply. Also requires confirmCounterpartyExplicit: true once the user has explicitly named or confirmed the customer/supplier in the current conversation. Do not reuse a counterparty from an earlier preview without that confirmation.

Agent View of the PolicyLayer registry record for `brc_create_sales_invoice_gen_ref`. HTML page: https://policylayer.com/tools/io-github-bigredcloud-red-mcp-server/brc-create-sales-invoice-gen-ref

## Facts

- Tool: `brc_create_sales_invoice_gen_ref`
- Server: Red by Big Red Cloud (`https://red.bigredcloud.com/mcp`) — https://policylayer.com/tools/io-github-bigredcloud-red-mcp-server.md
- Homepage: https://github.com/BigRedCloud/red-mcp-server
- Risk category: Write (Medium risk)
- Registry record: grade F, identity unverified
- Server auth posture: open
- Server CORS policy: *
- Server rate-limited: no
- Parameters: 8 (3 required)
- Recommended policy verdict: Rate-limited

## Parameters

| Parameter | Type | Required | Description |
| --- | --- | --- | --- |
| `payload` | object | yes | Raw BRC payloads for multi-line sales invoices must use `productTrans[]` (one object per product line). Each product line must include its own nested `acEntries |
| `priceBasis` | string | no | Required when Gross Price Entry is enabled. Use `gross` when unit prices are VAT-inclusive/gross. Use `net` when unit prices are VAT-exclusive/net. |
| `routeToken` | string | yes | Opaque routeToken from brc_route_request for this action workflow. Required for transactional tools. Routing permission only — does not replace preview-before-p |
| `companyName` | string | yes | Company context name, for example YOUR-COMPANY-NAME. |
| `confirmWrite` | boolean | no | Must be true only after a plain-English preview before posting has been shown in the current conversation and the user explicitly confirmed posting (for example |
| `connectionRef` | string | no | Opaque Red connection reference returned by brc_confirm_company_connection. Pass this exact value on every later tool call when the MCP client rotates session i |
| `confirmCrAnalysisCategory` | boolean | no | Set true only after the user confirms a CR sales analysis account code is intentional for this product line. |
| `confirmCounterpartyExplicit` | boolean | no | Must be true only after the user explicitly named or confirmed the customer, supplier, or other counterparty in the current conversation. Never set true because |

Parameters from the server's own tool schema.

## Example call (MCP tools/call, JSON-RPC 2.0)

```json
{
  "jsonrpc": "2.0",
  "id": 1,
  "method": "tools/call",
  "params": {
    "name": "brc_create_sales_invoice_gen_ref",
    "arguments": {
      "payload": {},
      "routeToken": "<routeToken>",
      "companyName": "<companyName>"
    }
  }
}
```

## Why brc_create_sales_invoice_gen_ref is rated Medium

An AI agent can call brc_create_sales_invoice_gen_ref faster than any human can review: one bad instruction and it creates or modifies resources in Red by Big Red Cloud by the hundred, each call as confident as the last.

Risk signals: Accepts raw HTML/template content (payload) · High parameter count (48 properties)

## Use case

AI agents use brc_create_sales_invoice_gen_ref to create or update resources in Red by Big Red Cloud, usually the action step of a workflow, after the agent has gathered context. Every call changes real data in your Red by Big Red Cloud environment.

## Recommended policy (PolicyLayer)

Verdict: **Rate-limited**. Enforced by the PolicyLayer MCP gateway (https://policylayer.com/mcp-gateway) before a call reaches Red by Big Red Cloud:

```json
{
  "version": "1",
  "default": "deny",
  "tools": {
    "brc_create_sales_invoice_gen_ref": {
      "limits": [
        {
          "counter": "brc_create_sales_invoice_gen_ref_rate",
          "window": "minute",
          "max": 30,
          "scope": "grant"
        }
      ]
    }
  }
}
```

## Other tools on Red by Big Red Cloud (158)

- `brc_clear_all_company_api_keys` — Destructive — https://policylayer.com/tools/io-github-bigredcloud-red-mcp-server/brc-clear-all-company-api-keys.md
- `brc_clear_audit_log` — Destructive — https://policylayer.com/tools/io-github-bigredcloud-red-mcp-server/brc-clear-audit-log.md
- `brc_clear_company_api_key` — Destructive — https://policylayer.com/tools/io-github-bigredcloud-red-mcp-server/brc-clear-company-api-key.md
- `brc_delete_accrual` — Destructive — https://policylayer.com/tools/io-github-bigredcloud-red-mcp-server/brc-delete-accrual.md
- `brc_delete_allocation_resolver` — Destructive — https://policylayer.com/tools/io-github-bigredcloud-red-mcp-server/brc-delete-allocation-resolver.md
- `brc_delete_bank_account` — Destructive — https://policylayer.com/tools/io-github-bigredcloud-red-mcp-server/brc-delete-bank-account.md
- `brc_delete_cash_payment` — Destructive — https://policylayer.com/tools/io-github-bigredcloud-red-mcp-server/brc-delete-cash-payment.md
- `brc_delete_cash_receipt` — Destructive — https://policylayer.com/tools/io-github-bigredcloud-red-mcp-server/brc-delete-cash-receipt.md
- `brc_delete_customer` — Destructive — https://policylayer.com/tools/io-github-bigredcloud-red-mcp-server/brc-delete-customer.md
- `brc_delete_nominal_journal_batch` — Destructive — https://policylayer.com/tools/io-github-bigredcloud-red-mcp-server/brc-delete-nominal-journal-batch.md
- `brc_delete_payment` — Destructive — https://policylayer.com/tools/io-github-bigredcloud-red-mcp-server/brc-delete-payment.md
- `brc_delete_prepayment` — Destructive — https://policylayer.com/tools/io-github-bigredcloud-red-mcp-server/brc-delete-prepayment.md
- `brc_delete_product` — Destructive — https://policylayer.com/tools/io-github-bigredcloud-red-mcp-server/brc-delete-product.md
- `brc_delete_purchase` — Destructive — https://policylayer.com/tools/io-github-bigredcloud-red-mcp-server/brc-delete-purchase.md
- `brc_delete_quote` — Destructive — https://policylayer.com/tools/io-github-bigredcloud-red-mcp-server/brc-delete-quote.md
- `brc_delete_sales_credit_note` — Destructive — https://policylayer.com/tools/io-github-bigredcloud-red-mcp-server/brc-delete-sales-credit-note.md
- `brc_delete_sales_entry` — Destructive — https://policylayer.com/tools/io-github-bigredcloud-red-mcp-server/brc-delete-sales-entry.md
- `brc_delete_sales_invoice` — Destructive — https://policylayer.com/tools/io-github-bigredcloud-red-mcp-server/brc-delete-sales-invoice.md
- `brc_delete_sales_rep` — Destructive — https://policylayer.com/tools/io-github-bigredcloud-red-mcp-server/brc-delete-sales-rep.md
- `brc_delete_supplier` — Destructive — https://policylayer.com/tools/io-github-bigredcloud-red-mcp-server/brc-delete-supplier.md
- `brc_red_help` — Destructive — https://policylayer.com/tools/io-github-bigredcloud-red-mcp-server/brc-red-help.md
- `brc_route_request` — Destructive — https://policylayer.com/tools/io-github-bigredcloud-red-mcp-server/brc-route-request.md
- `brc_getting_started` — Execute — https://policylayer.com/tools/io-github-bigredcloud-red-mcp-server/brc-getting-started.md
- `brc_start_company_connection` — Execute — https://policylayer.com/tools/io-github-bigredcloud-red-mcp-server/brc-start-company-connection.md
- `brc_create_payment` — Financial — https://policylayer.com/tools/io-github-bigredcloud-red-mcp-server/brc-create-payment.md
- `brc_batch_cash_payments` — Read — https://policylayer.com/tools/io-github-bigredcloud-red-mcp-server/brc-batch-cash-payments.md
- `brc_batch_cash_receipts` — Read — https://policylayer.com/tools/io-github-bigredcloud-red-mcp-server/brc-batch-cash-receipts.md
- `brc_batch_customers` — Read — https://policylayer.com/tools/io-github-bigredcloud-red-mcp-server/brc-batch-customers.md
- `brc_batch_payments` — Read — https://policylayer.com/tools/io-github-bigredcloud-red-mcp-server/brc-batch-payments.md
- `brc_batch_products` — Read — https://policylayer.com/tools/io-github-bigredcloud-red-mcp-server/brc-batch-products.md
- …and 128 more: https://policylayer.com/tools/io-github-bigredcloud-red-mcp-server.md

## For agents

This record is a snapshot. Live verdicts and the full registry:

- Check every server in your MCP config at once: `npx -y policylayer stack`
- Vet a server before you add it: install the mcp-precheck skill — `npx skills add https://policylayer.com` (skill text: https://policylayer.com/skill.md)
- Query the registry over MCP: endpoint `https://api.policylayer.com/mcp` — tools `check_mcp_server`, `check_mcp_stack`, `check_tool`, `search_registry`, `get_change_events`

---

Source: the PolicyLayer MCP registry — one continuously verified record per MCP server. Full record: https://policylayer.com/registry?q=io-github-bigredcloud-red-mcp-server · API: https://policylayer.com/registry/api · Policy library: https://policylayer.com/policies/io-github-bigredcloud-red-mcp-server
