> ## Documentation Index
> Fetch the complete documentation index at: https://docs.stateset.com/llms.txt
> Use this file to discover all available pages before exploring further.

# EDI API

> EDI 0.10.2 source reference: 202 operations for partners, orders, documents, connections, mappings, callbacks, and recovery.

Configure a relationship, process approved documents, review outbound fulfillment, and
inspect transport and business evidence through the EDI API.

| Setting | Value |
| - | - |
| Public API base | `https://api.edi.stateset.com` |
| Versioned routes | `/v1` |
| Customer authentication | `Authorization: Bearer <tenant or partner API key>` |
| Example environment variable | `EDI_API_TOKEN`, containing your scoped key |
| Console | `https://edi.stateset.com` |
| Served contract | `/api-docs/openapi.json`; Swagger at `/docs` |

> [!NOTE]
>
> Reviewed October 20, 2026. The [checked-in spec](https://docs.stateset.com/spec/edi.json) contains **202 operations**,
> version **0.10.2**, copied from source and matched byte-for-byte to its offline exporter
> before adding provenance metadata. Generated pages also apply
> [handler-backed corrections](https://github.com/stateset/api-docs/blob/main/spec/overlays/edi.json).
> The [deployment record](https://docs.stateset.com/stateset-edi/deployment-and-qualification.md) has a dated, narrower
> verification scope; the contract does not establish every hosted integration.

## Choose the workflow

| Need | Entry point |
| - | - |
| Inspect current production blockers | [Partner readiness](https://docs.stateset.com/api-reference/edi/partners/v1-partners-by-readiness-get.md) |
| Validate without processing | [Partner validation](https://docs.stateset.com/api-reference/edi/inbound/v1-edi-validate-by-create.md) |
| Process approved wire | [Partner inbound](https://docs.stateset.com/api-reference/edi/inbound/v1-edi-inbound-by-create.md) |
| Review connected order evidence | [Order workspace](https://docs.stateset.com/api-reference/edi/operations/v1-operations-orders-by-by-get.md) |
| Prepare an 855, 856, or 810 | [Preview](https://docs.stateset.com/api-reference/edi/orders/v1-operations-orders-by-by-preview-by-create.md) |
| Submit the reviewed operation | [Order send](https://docs.stateset.com/api-reference/edi/outbound/v1-orders-by-by-by-create.md) |
| Generate a complete shipment payload | [Outbound 856](https://docs.stateset.com/api-reference/edi/outbound/v1-edi-outbound-856-by-create.md) |
| Inspect a transport result | [Delivery evidence](https://docs.stateset.com/api-reference/edi/operations/v1-deliveries-by-evidence-get.md) |

## Credentials and contracts

Tenant keys imply their workspace; partner keys further restrict access. `x-tenant-id`
cannot widen either. Read-only and document-processing scopes differ. Key management needs
organization-administrator authority; platform provisioning, global outbox flush, and
metrics need platform authority. The server's `EDI_API_TOKEN` configuration holds its
platform token; that is not a customer credential.

Most JSON results use `{success,data}`. Inspect each endpoint's business verdict: inbound
HTTP 200 can contain rejected documents. Outbound generation returns EDI wire, not JSON.
Public health/liveness and transport-authenticated AS2 have distinct authentication rules.

Retain a stable `Idempotency-Key` and exact payload before outbound dispatch. Reviewed
order sends additionally preserve the preview's `If-Order-Revision` and frozen overrides.
PostgreSQL is required for durable retry receipts. After uncertainty, reuse the original
request; a new key can create another document. See [orders and recovery](https://docs.stateset.com/stateset-edi/orders-and-recovery.md).

The [MCP server](https://docs.stateset.com/stateset-edi/mcp-server.md) and [CLI/SDK](https://docs.stateset.com/stateset-edi/cli-and-sdk.md) expose
subsets with different client checks. Use REST for source routes outside their coverage.


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.