Skip to content

Middleware Verified Records

Headless verified-record resources for billing middleware integrations.

Billing middleware can use PacSpace verified-record resources without sending users into the PacSpace dashboard. The middleware keeps its own customer experience while PacSpace supplies the recorded evidence.

These resources are available only to tenants configured as billing middleware. Direct inference vendors use the standard Balance API and cannot call /api/v1/middleware/*.

Base URL: https://app.pacspace.io

http
GET https://app.pacspace.io/api/v1/middleware/vendors/:vendorId/customers/:externalCustomerId/record

Required header: X-Api-Key: pk_live_PUBLIC.SECRET.

Core Resources

ResourceMethodPurpose
/api/v1/middleware/readinessGETInvoice readiness rows and blockers
/api/v1/middleware/customers/:customerId/liveGETCurrent Shared Record state
/api/v1/middleware/customers/:customerId/periodsGETClosed periods
/api/v1/middleware/customers/:customerId/periods/:checkpointIdGETPeriod detail
/api/v1/middleware/customers/:customerId/close-packageGETFinance Close Package
/api/v1/middleware/customers/:customerId/access-linkGETLink, host, policy, and access-code readiness
/api/v1/middleware/customers/:customerId/comparePOSTCompare two periods/checkpoints
/api/v1/middleware/customers/:customerId/exportGETJSON, CSV, PDF, or bundle export

Vendor Accounts

Middleware tenants must create vendor accounts in Setup before producing records. The vendorAccountId is required on Balance API emits and checkpoint commits for middleware tenants, forbidden for direct-inference tenants, and scoped to one vendor account per submission group or checkpoint.

Customer-facing receipt and Shared Record identity resolves to the vendor account:

json
{
    "tenant": {
        "name": "Acme Inference"
    },
    "recordedBy": {
        "type": "middleware_vendor_account",
        "id": "cmw_vendor_123",
        "displayName": "Acme Inference"
    }
}

The middleware parent tenant name is not serialized in buyer-facing record payloads for middleware-produced records.

Webhooks

Relevant webhook events include:

  • customer.shared_record_viewed
  • customer.export_downloaded
  • customer.compare_run

See Webhook Event Types for delivery and retry behavior.