# edi_build

Compiles structured JSON into standards-valid X12. The parts that get documents rejected are exactly the parts a language model cannot hold in its head: the 856 hierarchy needs sequential HL IDs where every level names its parent's ID, and on a multi-carton, multi-SKU shipment that bookkeeping goes wrong silently. The ISA header is fixed-width — 106 characters exactly, every element space-padded to size — and one character out crashes the receiver's translator. Segment counts in SE01, CTT01, GE01 and IEA01 must agree with what was actually emitted. All of that is computed here rather than written by hand.

Agent View of the PolicyLayer registry record for `edi_build`. HTML page: https://policylayer.com/tools/com-fluentedi-tools/edi-build

## Facts

- Tool: `edi_build`
- Server: Tools (`https://fluentedi.com/mcp`) — https://policylayer.com/tools/com-fluentedi-tools.md
- Homepage: https://github.com/https://fluentedi.com/mcp
- Risk category: Execute (High risk)
- Registry record: grade F, identity unverified
- Server auth posture: open
- Server CORS policy: *
- Server rate-limited: no
- Parameters: 10 (1 required)
- Recommended policy verdict: Rate-limited

## Parameters

| Parameter | Type | Required | Description |
| --- | --- | --- | --- |
| `data` | object | yes | Document content. For 856: {shipment_id, ship_date, orders:[{po_number, packs:[{sscc, items:[{upc, quantity, unit}]}]}], parties:[{role,name,id}]}. For 850: {po |
| `document` | string | no | Transaction set to build. |
| `sender_id` | string | no | ISA06 sender identifier. |
| `timestamp` | string | no | ISO instant for the envelope date/time. Defaults to now. |
| `receiver_id` | string | no | ISA08 receiver identifier. |
| `control_number` | integer | no | Interchange control number (ISA13). Also seeds GS06 and ST02. |
| `test_indicator` | boolean | no | Mark the interchange as test (ISA15 = T) rather than production (P). |
| `include_envelope` | boolean | no | Wrap the transaction set in ISA/GS ... GE/IEA. |
| `sender_qualifier` | string | no | ISA05 qualifier, e.g. ZZ, 01 (DUNS), 12 (phone). |
| `receiver_qualifier` | string | no | ISA07 qualifier. |

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": "edi_build",
    "arguments": {
      "data": {}
    }
  }
}
```

## Why edi_build is rated High

edi_build triggers real processes with real consequences. An agent gone sideways doesn't fire it once. It starts dozens of builds, sends mass notifications, or burns through compute before anyone looks up.

Risk signals: High parameter count (10 properties) · Bulk/mass operation — affects multiple targets

## Use case

AI agents invoke edi_build to trigger actions in Tools. What it does depends on the arguments the agent supplies, and its effects often reach beyond the immediate call: builds kicked off, notifications sent, workflows started.

## Recommended policy (PolicyLayer)

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

```json
{
  "version": "1",
  "default": "deny",
  "tools": {
    "edi_build": {
      "limits": [
        {
          "counter": "edi_build_rate",
          "window": "minute",
          "max": 10,
          "scope": "grant"
        }
      ]
    }
  }
}
```

## Other tools on Tools (16)

- `cron_next` — Execute — https://policylayer.com/tools/com-fluentedi-tools/cron-next.md
- `edi_parse` — Execute — https://policylayer.com/tools/com-fluentedi-tools/edi-parse.md
- `edi_validate` — Read — https://policylayer.com/tools/com-fluentedi-tools/edi-validate.md
- `hash` — Read — https://policylayer.com/tools/com-fluentedi-tools/hash.md
- `http_assert` — Read — https://policylayer.com/tools/com-fluentedi-tools/http-assert.md
- `http_check` — Read — https://policylayer.com/tools/com-fluentedi-tools/http-check.md
- `json_query` — Read — https://policylayer.com/tools/com-fluentedi-tools/json-query.md
- `json_repair` — Read — https://policylayer.com/tools/com-fluentedi-tools/json-repair.md
- `math_eval` — Read — https://policylayer.com/tools/com-fluentedi-tools/math-eval.md
- `time_diff` — Read — https://policylayer.com/tools/com-fluentedi-tools/time-diff.md
- `time_now` — Read — https://policylayer.com/tools/com-fluentedi-tools/time-now.md
- `time_window` — Read — https://policylayer.com/tools/com-fluentedi-tools/time-window.md
- `tool_describe` — Read — https://policylayer.com/tools/com-fluentedi-tools/tool-describe.md
- `tool_search` — Read — https://policylayer.com/tools/com-fluentedi-tools/tool-search.md
- `time_convert` — Write — https://policylayer.com/tools/com-fluentedi-tools/time-convert.md
- `tool_call` — Write — https://policylayer.com/tools/com-fluentedi-tools/tool-call.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=com-fluentedi-tools · API: https://policylayer.com/registry/api · Policy library: https://policylayer.com/policies/com-fluentedi-tools
