# Carrier invoice audit Source: https://docs.upwell.com/accounts-payable/carrier-invoice-audit Learn how to manage and process carrier invoices using the payables screen ## Overview The carrier payables screen is your central hub for managing carrier invoices and payments. ![The Needs Review tab of the carrier docs screen, showing invoices held by an open exception](https://mintcdn.com/upwell/-Pwd7QcUk6Cnh82_/images/payables-needs-review.png?fit=max\&auto=format\&n=-Pwd7QcUk6Cnh82_\&q=85\&s=9444ddc4ac77c0a95eb74ba7a52b7d93) The Needs Review tab: carrier documents held by an open exception, each row naming the exception that stopped it. ## Key Features > [accordion] Invoice List View > > The main grid displays all carrier invoices with key information: > > * Invoice number and date > * Carrier name > * Total amount > * Status — see [Carrier invoice statuses](/api-reference/vocabulary#carrier-invoice-statuses) for the full set of values and what each one means > * Match status with TMS shipments > [accordion] Filtering and Search > > Quickly find specific invoices using: > > * Date range filters > * Carrier filters > * Status filters — the status picker offers the full [carrier invoice status](/api-reference/vocabulary#carrier-invoice-statuses) set > * Search by invoice number, BOL, or PRO number > * Advanced filtering options > [accordion] Invoice Processing > > Process invoices efficiently with these actions: > > * View invoice details and attached documents > * Match invoices to shipments > * Review and approve exceptions > * Bulk approve validated invoices > * Export data for payment processing ## Common Tasks ### Reviewing newly received invoices 1. Filter the list by status to focus on invoices still in review — most carrier invoices start in [`RECEIVED`](/api-reference/vocabulary#carrier-invoice-statuses), though one created ahead of its document or its bill starts in `AWAITING_INVOICE` or `AWAITING_BILL` and promotes to `RECEIVED` on its own 2. Review automatically matched shipments 3. Verify rates and accessorials 4. Approve or flag for exception handling ### Handling Exceptions **1. Open the Needs Review tab** **Needs Review** is the queue of invoices held back by an open exception. **2. Select an invoice to review** Pick an invoice from the list to open its detail view. **3. Compare invoice details against TMS data** Check the invoice against the shipment and bill your TMS sent, so you can see exactly where the two disagree. **4. Add notes or supporting documentation** Record what you found and attach any documents that back up the decision. **5. Resolve or escalate the exception** Clear the exception if the invoice is good to pay, or escalate it for further handling. ## What each tab filters on The tabs are not status filters. Each one is a composite condition, so you cannot reproduce a tab through the API by matching a single [carrier invoice status](/api-reference/vocabulary#carrier-invoice-statuses) — you have to reproduce the whole predicate. **Needs Review** and **Ready for Approval** both exclude **terminal** statuses, meaning invoices that need no further action: `APPROVED`, `PAID`, `PART_PAID`, `CANCELLED`, `REJECTED`, `REFUNDED`, and `DISPUTED`. | Tab | What it actually selects | | - | - | | **All Docs** | No **status** filter, but not quite everything: soft-deleted invoices are hidden unless "show deleted" is toggled on, and a tenant-configured terminal-status filter (when that feature is enabled) may narrow the set further. | | **Needs Review** | Not deleted, status not terminal, no carrier document request in `PENDING` or `RESPONDED` status (a request whose send **failed** does not hide the invoice), and the invoice has an **open** exception. Two tenant settings then adjust the set: with the No Matching Bill rule enabled, invoices with no bill also appear if they have a shipment or automatic matching was turned off; and with **Verify approvable shipment status** active (without "show in Needs Review"), invoices whose matched shipment is not in an approvable status are hidden — the tab's footer counts them, and invoices with no matched shipment are unaffected. | | **Ready for Approval** | Not deleted, status not terminal, a bill **is** linked, and **no** open exception. Invoices sourced from Revenova must additionally have a non-blank invoice number, a positive total, and a bill that is not already approved, excluded, or posted/paid on the Revenova side. Invoices whose customer approves carrier bills outside Upwell are excluded; they stay in **All Docs**, where the **Approve** action shows why it's unavailable. See [Customers that approve carrier bills outside Upwell](/concepts/approvals#customers-that-approve-carrier-bills-outside-upwell). | | **Outreach** | Lists carrier document requests, not invoices: every request that is not resolved, cancelled, or expired and has had at least one outreach email sent. | **Needs Review** and **Ready for Approval** never show the same invoice at once — the exception path requires an open exception where Ready for Approval requires none, and the no-bill path requires a missing bill where Ready for Approval requires one. ## Best Practices > [card] Daily Review > > Check new invoices daily to maintain consistent cash flow > [card] Exception Management > > Address exceptions promptly to prevent payment delays > [card] Documentation > > Always add notes for non-standard approvals > [card] Regular Exports > > Export approved invoices on a set schedule # Online Payments Source: https://docs.upwell.com/accounts-receivable/online-payments Let customers pay invoices electronically through secure hosted payment links — and have those payments land in your AR workflow automatically. ## Overview Online payments close the loop on collections: instead of waiting on checks, customers pay an invoice electronically through a secure, Upwell-hosted payment page. Payment links ride along wherever the invoice goes — invoice delivery emails and [payment reminder](/accounts-receivable/reminders) emails — so paying is one click from the message the customer is already reading. ## What it does ### Hosted payment collection * Each invoice can carry a secure **payment link** to an Upwell-hosted checkout page * Customers pay the invoice electronically without an account or portal login * Card data is handled by Upwell's PCI-compliant payment processing — it never touches your systems ### Built into delivery and reminders * Payment links are included in invoice delivery emails and reminder emails automatically * The hosted page reflects the invoice's current balance ### Lands in your AR workflow * A completed online payment is recorded as a **customer payment** and applied to the invoice it was collected against — the same objects the rest of cash application uses (see [Remittances](/accounts-receivable/remittances)) ## For developers There is no separate payments-processing API — you don't create charges or tokens. Online payments surface to integrations as ordinary AR objects: > [card] [Customer payments](/api-guides/customer-payments) > > Completed payments appear as `customer_payments` with line items applying to invoices — read them like any other payment. > [card] [Webhook events](/api-guides/webhook-events) > > Subscribe to `create.customer_payment` / `update.customer_payment` to react when a customer pays online. > [!NOTE] > > To enable online payments for your organization, or to ask about supported payment methods and > fees, contact [support@upwell.com](mailto:support@upwell.com) — enablement is per organization > and involves payment-provider onboarding. # Accounts Receivable Management Source: https://docs.upwell.com/accounts-receivable/receivables How Upwell generates, delivers, and tracks customer invoices — and where the money-in workflow is automated. ## Overview Upwell's receivables management gets your customer invoices out fast and paid faster. It sits on top of the shipment data your TMS provides: invoices are generated from shipments, delivered with their supporting documents, tracked through payment, and chased automatically when they age. This page describes the product workflow. If you're building against the API, jump to [For developers](#for-developers) below. ![The All Receivables tab listing customer invoices with issue and due dates, delivery portal, and status](https://mintcdn.com/upwell/-Pwd7QcUk6Cnh82_/images/receivables-all.png?fit=max\&auto=format\&n=-Pwd7QcUk6Cnh82_\&q=85\&s=df8032e982cbc6f815034a1bc4f5b7a0) Customer invoices on the All Receivables tab, each showing its status and how it was delivered. ## What it does ### Invoice generation * Build customer invoices from shipment data — rates, accessorials, and references * Attach supporting documents (BOL, POD, rate confirmation) automatically * Issue invoices under the correct legal entity when you operate multiple brands (see [Companies](/api-guides/syncing-foundation-entities)) ### Invoice delivery * Deliver by **email**, **EDI**, or the **customer portal**, per each customer's configuration * Supporting documents travel with the invoice (see [How documents flow through Upwell](/concepts/document-lifecycle)) * Track invoice status through delivery and payment on the invoice lifecycle ### Collections * Aging visibility across your receivables portfolio * Automated email follow-ups on open invoices — see [Payment Reminders](/accounts-receivable/reminders) * Account **statements** summarizing a customer's open invoices, generated and sent on a schedule ### Cash application * Record customer payments and apply them to invoices via payment line items — see [Remittances](/accounts-receivable/remittances) * Resolve short-pays and unapplied cash from the dashboard ## For developers The receivables workflow is built on the public REST API — these are the real surfaces: > [card] [Customer invoices (AR)](/api-guides/customer-invoices) > > Create and manage invoices and line items: `POST /api/rest/invoices`, nested `invoiceLineItems`, shipment links. > [card] [Customer payments](/api-guides/customer-payments) > > Record remittances and apply them: `POST /api/rest/customer_payments` and `customer_payment_line_items`. > [card] [Webhook events](/api-guides/webhook-events) > > Subscribe to `update.invoice.status.SENT`, portal exceptions, and payment triggers. > [card] [Syncing foundation entities](/api-guides/syncing-foundation-entities) > > The customers and shipments that invoices are built from. > [!NOTE] > > There is no separate "receivables API" — the module is operated through the endpoints above. > For the exact request and response shapes, see the [API Reference](/api-reference/introduction). # Payment Reminders Source: https://docs.upwell.com/accounts-receivable/reminders Automated email follow-ups on open invoices — how Upwell chases receivables so your team doesn't have to. ## Overview Payment reminders automate the follow-up cycle on open invoices: instead of your team manually emailing customers about aging balances, Upwell sends scheduled, templated follow-up emails that reflect each customer's current open invoices. ## What it does ### Scheduled email follow-ups * Reminder cadence is configured per your workflow under **Workflow Settings → Reminder Schedule** in the dashboard * Reminders are sent by **email**, using configurable follow-up templates * Timing keys off invoice age and the customer's payment terms (see `paymentDiscountTerms` in [Syncing foundation entities](/api-guides/syncing-foundation-entities)) * By default, reminders go out on weekdays only. A reminder scheduled for a Saturday or Sunday is sent the following Monday. To send reminders on their scheduled day, including weekends, set **Send Reminders On** to **All 7 days** * Each step in a reminder sequence has an **Enabled** switch. Turn it off to stop that step from sending without deleting it; the step stays in the sequence marked **Disabled** * Use **Preview** on a step to see the email it would send. Upwell renders the preview with sample customer and invoice data, or with a customer's open invoices when you preview from that customer. Nothing is sent ### Reminder content * Templated messaging that reflects the customer's current open balance — a payment recorded today is reflected in what tomorrow's reminder chases * Include secure **payment links** so customers can pay directly from the email (see [Online Payments](/accounts-receivable/online-payments)) * Account **statements** summarizing all open invoices complement per-invoice reminders (see [Accounts Receivable Management](/accounts-receivable/receivables)) ## For developers **There is no public reminders API today** — no endpoints exist for reminder templates, schedules, or logs. Reminders are configured in the dashboard. What you *can* do over the API: > [card] [Feed the inputs](/api-guides/syncing-foundation-entities) > > Reminders are driven by invoice and payment state — keep invoices, payments, and customer payment terms synced accurately. > [card] [Observe the outcomes](/api-guides/webhook-events) > > Watch `create.customer_payment` and invoice status triggers to see collections progress in your own system. # Remittances Management Source: https://docs.upwell.com/accounts-receivable/remittances How customer payments get recorded, matched to invoices, and reconciled — cash application in Upwell. ## Overview Remittances management is the money-in half of receivables: recording what customers paid and applying it to the right invoices. Payments arrive from several directions — pushed over the API by your TMS or accounting system, recorded in the dashboard, collected through [online payments](/accounts-receivable/online-payments), or ingested from supported banking integrations — and land in one place for application and reconciliation. ## What it does ### Payment recording * Capture customer payments with their reference details (check number, transaction date, payer) * Ingest transactions from supported **banking integrations** for reconciliation * Handle **partial payments** — a payment's line items can apply across multiple invoices, and an invoice can be paid down by multiple payments ### Cash application * Apply payments to invoices through **payment line items** — each line item targets one invoice with an amount * Work **short-pays and unapplied cash** from the dashboard: unmatched payments are surfaced for a person to resolve * Keep an audit trail of how each payment was applied ### Reconciliation visibility * See incoming payments and their application status across the portfolio * Identify unapplied or partially applied cash before it ages > [!NOTE] > > Scope note: invoice *generation and delivery* live in > [Accounts Receivable Management](/accounts-receivable/receivables); *collecting* payment > electronically lives in [Online Payments](/accounts-receivable/online-payments). This page is > about what happens once money shows up. ## For developers > [card] [Customer payments guide](/api-guides/customer-payments) > > The real endpoints: `POST /api/rest/customer_payments`, `customer_payment_line_items`, and the `bulk-customer-payments` batch path. > [card] [Webhook events](/api-guides/webhook-events) > > `create.customer_payment` and the remittance trigger family notify you of payments recorded on the Upwell side. > [!WARNING] > > Three things integrators regularly get wrong: > > * The payment endpoints use **underscores**: `/api/rest/customer_payments`, not > `/customer-payments`. > * A payment header does not reduce an invoice. The amount must be on a payment line item linked > to that invoice; Upwell then recalculates its `balance` and payment status. > * Changing only a payment or line-item `status` does not unapply cash in the standard model. > Correct or delete the original line item so Upwell can recalculate the invoice. # Shipper Profiles Source: https://docs.upwell.com/accounts-receivable/shipper-profiles Customer records in Upwell — the shipper master data that invoicing, delivery, and collections are built on. ## Overview A shipper profile is Upwell's **customer** record: the party you bill and collect from. Every receivables feature keys off it — invoice delivery reads the customer's billing address and email, aging and reminders read its payment terms, and payments apply against its invoices. > [!NOTE] > > In the data model and the API this object is simply the **customer** (`cus_…`). "Shipper" is > the freight-side word for the same party — see the > [data model](/concepts/data-model) for how customers relate to shipments and invoices. ## What it holds ### Identity and contact * Name, email address for invoice delivery, and phone * The **billing address** — a separate, typed address record (`CUSTOMER_BILLING`), at most one per customer, which the invoice bill-to block and delivery routing read * Your external key (`sourceSystem` + `sourceSystemId`) tying the record back to your TMS ### Billing configuration * **Payment terms** (`paymentDiscountTerms`, e.g. `"Net 30"`) — drives aging and reminder timing * **Bill-to hierarchy** (`billToCustomerId`) — point child accounts at the corporate parent they bill through, for enterprises with many shipping locations and one payer * **Custom data** — the customer record carries a `metadata` field for integration-specific attributes ### History * Shipments, invoices, and payments all reference the customer, giving a per-account view of activity and payment behavior in the dashboard ## For developers > [card] [Sync customers](/api-guides/syncing-foundation-entities) > > `POST /api/rest/customers`, updates by id or by external key, and the bill-to hierarchy fields. > [card] [Billing addresses](/conventions/addresses) > > The address playbook: the one-`CUSTOMER_BILLING`-per-customer rule and the match-by-type update pattern. > [!WARNING] > > Contacts, locations, and customer documents are **not** separate API resources — there are no > `/customer-contacts`, `/customer-locations`, or `/customer-documents` endpoints. Locations are > modeled as typed **addresses**, and shipper-facing documents attach to shipments and invoices > (see [How documents flow through Upwell](/concepts/document-lifecycle)). # Responding to a carrier-invoice approval request Source: https://docs.upwell.com/api-guides/carrier-invoice-approval Resolve a pending carrier-invoice approval request from your integration by setting its status to SUCCEEDED or FAILED. # Responding to a carrier-invoice approval request When a carrier invoice needs sign-off from an external system before Upwell proceeds, Upwell opens a **carrier-invoice approval request** and waits for your integration to resolve it. This page shows how to read a pending request and resolve it with the callback. > [!NOTE] > > An approval request is a small state record (`carrier_invoice_approval_request`) tracking one pending decision on a carrier invoice — the invoice it belongs to, the payloads exchanged, retry state, and its `status`. While a request is unresolved, the corresponding **Approve** action in Upwell stays in progress; resolving the request (below) is what completes it. Upwell doesn't open new approval requests for carrier invoices whose customer is set to approve carrier bills outside Upwell (`carrierApprovalBlocked` on the customer). Requests that were already open when the setting was turned on are not cancelled. See [Customers that approve carrier bills outside Upwell](/concepts/approvals#customers-that-approve-carrier-bills-outside-upwell). In a workspace connected to Turvo, Upwell also doesn't open an approval request when the invoice's linked Turvo bill already records the carrier invoice as `Approved`. **Approve** then completes immediately: Upwell moves the invoice to `APPROVED`, or to `PAID` / `PART_PAID` when the bill already records payment. No approval webhook is sent, so Turvo isn't asked to approve the invoice again. ## The resource `GET /api/rest/carrier_invoice_approval_requests/{id}` returns a single request: ```bash theme={null} curl https://api.upwell.com/api/rest/carrier_invoice_approval_requests/APPROVAL_REQUEST_ID \ -H "Authorization: YOUR_API_KEY" # -> { "carrierInvoiceApprovalRequest": { # "id": "...", "carrierInvoiceId": "cari_...", "status": "...", # "retryCount": 0, "createdAt": "...", "updatedAt": "...", # "carrierInvoice": { "invoiceNumber": "...", "totalAmount": 125000, # "carrier": { "id": "car_...", "name": "Acme Trucking" } } } } ``` | Field | Meaning | | - | - | | `id` | Approval-request ID — use this in the callback below. | | `carrierInvoiceId` | The carrier invoice awaiting a decision. | | `carrierInvoice` | Nested summary: `carrier` (`id`, `name`), `invoiceNumber`, `totalAmount` (in **cents**). | | `status` | Current state (see below). | | `retryCount` | How many times Upwell has re-sent the request. | | [`createdAt`](/conventions/dates-and-times#created-at) / [`updatedAt`](/conventions/dates-and-times#updated-at) | Timestamps. | You can list open requests with `GET /api/rest/carrier_invoice_approval_requests` (supports `limit` / `offset`), or — preferably — be notified via [outbound webhooks](/api-guides/webhooks) instead of polling. ### Resolution statuses `status` is a `CarrierInvoiceApprovalRequestStatusEnum`. When you **resolve** a request, set it to one of: | Status | Meaning | | - | - | | `SUCCEEDED` | The invoice was approved by your system. | | `FAILED` | The invoice was rejected or could not be approved. | > [!NOTE] > > Resolve a request with `SUCCEEDED` or `FAILED` — those are the only two values Upwell acts on, and only `SUCCEEDED` advances the carrier invoice to `APPROVED`. The endpoint does not currently reject the other values, so writing one leaves the request in a state nothing will progress; treat that as a bug in your integration rather than a supported option. A `GET` may also return the lifecycle states Upwell manages itself — `INITIATED`, `IN_PROGRESS`, `RETRYING`, and `ABANDONED` — all defined in the [Vocabulary](/api-reference/vocabulary#approval-request-statuses). ## Resolve a request — the callback `PATCH /api/rest/carrier_invoice_approval_requests/{id}` sets the request's status. This is the call that clears the pending state on the Upwell side. The request `id` comes from the **URL path**; the body just carries an `input` object with the new `status`: ```bash theme={null} curl -X PATCH https://api.upwell.com/api/rest/carrier_invoice_approval_requests/APPROVAL_REQUEST_ID \ -H "Authorization: YOUR_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "input": { "status": "SUCCEEDED" } }' # -> { "updatedCarrierInvoiceApprovalRequest": { "id": "APPROVAL_REQUEST_ID", "status": "SUCCEEDED" } } ``` To reject instead, send `"status": "FAILED"`. > [!WARNING] > > The approval-request `id` is taken from the **URL path** — the body only needs `input`. A top-level `id` in the body is optional and, if included, must match the path. The response echoes only `id` and `status`; read the full record with `GET /carrier_invoice_approval_requests/{id}` if you need the rest. > [!NOTE] > > The `input` object accepts more than `status` (for example, a payload capturing your system's response). For the complete request schema, see the **`carrier_invoice_approval_requests`** entry in the [API Reference](/api-reference/introduction) — it is generated from the API schema. ## Recommended flow **1. Discover the request** Receive it via a webhook, or poll `GET /api/rest/carrier_invoice_approval_requests`. **2. Decide** Use the nested `carrierInvoice` details (carrier, invoice number, amount) to make your decision. **3. Resolve it** `PATCH` the request with `status` `SUCCEEDED` or `FAILED`. This clears the pending **Approve** state in Upwell. > [!NOTE] > > For the carrier-invoice lifecycle itself — statuses, exceptions, and how to know when processing is done — see [Knowing when a carrier invoice is processed](/api-guides/carrier-invoice-status). To submit carrier invoices in the first place, see [Submitting carrier invoices via API](/api-guides/carrier-invoice-submission). # Knowing when a carrier invoice is processed Source: https://docs.upwell.com/api-guides/carrier-invoice-status Determine processing state with the existing GET endpoints (polling) or outbound webhooks. No special status field required. # Knowing when a carrier invoice is processed After you [submit a carrier invoice](/api-guides/carrier-invoice-submission), Upwell works on it asynchronously. This page explains how to learn when that work is done. > [!NOTE] > > There's no single "processed" flag. You read the existing fields on the invoice — its `status`, its `exceptions`, and the matched `shipmentId` — plus the `type` on each attached document. You can read them by **polling** the GET endpoints or by receiving **webhooks**. Most production integrations use webhooks for timeliness and polling as a reconciliation backstop. ## Two phases of processing It helps to separate two things: 1. **Ingestion** (automatic, seconds after create). Upwell stamps provenance (`source_system = "API"`), matches the invoice to a shipment/carrier/bill from your references, and runs the exception audit. **The `status` usually stays `RECEIVED` through this phase** — ingestion populates `shipmentId`/`billId`/`carrierId` and updates `exceptions`, it doesn't move the status. 2. **Review & approval** (later; may involve your rules or a human). The invoice moves toward `APPROVED` or an exception state. This is where `status` changes. So "is it done?" has two answers depending on what you're waiting for. Both are observable from the same endpoints. ## The signals | Signal | Where | Meaning | | - | - | - | | `shipmentId` populated | `GET /carrier_invoices/{id}` | Ingestion matched the invoice to a shipment. | | [`updatedAt`](/conventions/dates-and-times#updated-at) > [`createdAt`](/conventions/dates-and-times#created-at) | `GET /carrier_invoices/{id}` | Ingestion has run (Upwell touched the row after you created it). | | `exceptions` (string) | `GET /carrier_invoices/{id}` | Comma-joined open audit findings, e.g. `"INVOICE AMOUNT MISMATCH"`. Empty = clean. | | `status` | `GET /carrier_invoices/{id}` | The review/approval lifecycle (see table below). | | document `type` | `GET /carrier_invoices/{id}/documents` | A document is parsed once `type` is no longer `"UNKNOWN"`. | ### Status values The generated [Vocabulary](/api-reference/vocabulary) page lists every enum value the API can produce, including the ones not defined below. | Phase | Statuses | Meaning | | - | - | - | | In-flight | `RECEIVED`, `PROCESSING`, `UNDER_REVIEW`, `AWAITING_INVOICE`, `AWAITING_CARRIER_RESPONSE`, `CARRIER_RESPONDED` | Submitted / under review. | | Done — clear | `APPROVED`, `PART_PAID`, `PAID` | Approved and progressing to / through payment. | | Needs attention | `EXCEPTION`, `CARRIER_EXCEPTION`, `DISPUTED`, `REJECTED` | A carrier/audit issue needs resolving. | > [!WARNING] > > `exceptions` is a **comma-joined string**, not an array. Treat a non-empty string as "needs attention" even while `status` is still `RECEIVED`. And don't judge `exceptions` until **ingestion has run** — a brand-new row always lists "no carrier / no matching shipment" findings that disappear once matching completes. ## When a linked bill moves the status Once a carrier invoice is linked to a bill, the bill's `status` can move the invoice. The mapping depends on the bill's `source_system`. Strings are exact, including case. Fully paid and partially paid bill statuses apply for **every** source: | Bill `status` | Carrier invoice `status` | | - | - | | `PAID`, `Fully Paid`, `Paid` | `PAID` | | `Partial Paid`, `Paid Partial` | `PART_PAID` | These bill statuses are removed for **every** source, and the carrier invoice goes to `AWAITING_BILL`: `DELETED`, `VOID`, `Canceled`. Approval that is not itself a payment is per source. A bill synced by one of Upwell's TMS integrations moves the invoice to `APPROVED` only on that TMS's own approval statuses. For example: | Bill `source_system` | Bill `status` values that approve | | - | - | | `TAI` | `Unpaid` (`Fully Paid` and `Partial Paid` are the payment rows above) | | `REVENOVA` | `APPROVED` | | `Turvo`, `TURVO_TMS` | `Approved` (`Paid` is the paid row above) | | `THREE_GTMS` | `Billed` (`Paid` and `Paid Partial` are the payment rows above) | | `MCLEOD`, `mcleod` | `Transferred to Settlement`, `Unpaid` (settled in McLeod but not paid, for example after a voided payment) | | `TRANSPORT_PRO`, `transport-pro` | `APPROVED` | `TRANSPORT_PRO` and `transport-pro` use the literal `APPROVED` on purpose. That is the same text Revenova stores; it is listed for Transport Pro rather than borrowed from Revenova. A status that only another TMS uses for approval does not approve: a Turvo bill whose status is `APPROVED`, or a Revenova bill whose status is `Approved`, leaves the invoice where it is (an invoice in `AWAITING_BILL` moves to `RECEIVED`, because it now has a bill). Bills you submit through the API (`source_system = "API"`) use the combined list, because partner-authored bills keep bill status as the source of truth. So does a bill with no `source_system`, or one whose `source_system` has no list of its own. The combined list approves on `AGING`, `SELECTED`, `Unpaid`, `APPROVED`, `Approved`, `Billed`, and `Transferred to Settlement`; the paid and partially paid rows above apply as usual. A carrier invoice in `AWAITING_INVOICE` does not move because of the bill. The invoice document has to arrive first. ## Approach 1 — Polling Read the invoice and its documents on an interval. Wait for ingestion (the row's [`updatedAt`](/conventions/dates-and-times#updated-at) advances past [`createdAt`](/conventions/dates-and-times#created-at)), then read the outcome. ```bash theme={null} curl https://api.upwell.com/api/rest/carrier_invoices/cari_a1b2c3d4e5 \ -H "Authorization: YOUR_API_KEY" # -> { "carrierInvoice": { "id": "cari_a1b2c3d4e5", "status": "RECEIVED", # "shipmentId": "shi_...", "billId": "bil_...", "carrierId": "car_...", # "exceptions": "INVOICE AMOUNT MISMATCH", "createdAt": "...", "updatedAt": "...", ... } } curl https://api.upwell.com/api/rest/carrier_invoices/cari_a1b2c3d4e5/documents \ -H "Authorization: YOUR_API_KEY" # -> { "carrierInvoiceDocumentsByCarrierInvoiceId": # [ { "id": "...", "documentId": "doc_...", "type": "CARRIER_INVOICE", "url": "https://...", ... } ] } ``` A minimal poller with backoff: ```javascript theme={null} async function waitForIngestion(id, { timeoutMs = 60_000 } = {}) { let delay = 1_500; const deadline = Date.now() + timeoutMs; while (true) { const { carrierInvoice: inv } = await get(`/api/rest/carrier_invoices/${id}`); const { carrierInvoiceDocumentsByCarrierInvoiceId: docs = [] } = await get(`/api/rest/carrier_invoices/${id}/documents`); const ingested = inv.updatedAt !== inv.createdAt; // Upwell has processed it const hasExceptions = !!(inv.exceptions || '').trim(); const unclassified = docs.filter((d) => !d.type || d.type === 'UNKNOWN'); if (ingested) { if (hasExceptions) return { outcome: 'NEEDS_ATTENTION', inv, docs }; if (unclassified.length === 0) return { outcome: 'PROCESSED', inv, docs }; } if (Date.now() + delay >= deadline) // Give up gracefully. A doc still UNKNOWN here is in manual review, not "failed". return { outcome: 'TIMEOUT', inv, docs, unclassified }; await new Promise((r) => setTimeout(r, delay)); delay = Math.min(delay * 2, 12_000); // exponential backoff } } ``` > [!TIP] > > Start around a 1–2 s interval and back off exponentially. Ingestion usually settles within seconds; document classification can take longer for large multi-page PDFs. > [!WARNING] > > The documents endpoint exposes the document's **`type`**, not its internal classification status. A document still `UNKNOWN` past your timeout is ambiguous between "still classifying" and "couldn't be classified" — treat it as **needs manual review** rather than a hard failure, and don't block your pipeline on it. ## Approach 2 — Webhooks Subscribe once and let Upwell push the changes to you. Configure subscriptions in the Upwell dashboard (see [Outbound webhooks](/api-guides/webhooks) for the model, payload shape, and auth). | Trigger | Fires when | | - | - | | `create.carrier_invoice` | The invoice is created. | | `update.carrier_invoice` | A change that is neither a tracked status transition nor a named sub-event — fires when ingestion enriches the row. | | `create.carrier_invoice.shipment_updated` / `update.carrier_invoice.shipment_updated` | Creation with a shipment_id column, or a change to its value. Check the shipment ID before treating it as a match. | | `update.carrier_invoice.status.APPROVED` | Read the invoice at dispatch from `payload.carrierInvoice`. A first payment can also record approval. When an outbound approval request completes, its follow-through status write suppresses this notification. Also not sent when Upwell records an approval Turvo already has. | | `update.carrier_invoice.status.EXCEPTION` | The invoice entered `EXCEPTION`. Compare `payload.old` with `payload.new`. | | `create.carrier_document` / `update.carrier_document` | A document was attached or (re)classified. **Support-enabled only** — not self-service in the dashboard; contact support. | The [webhook event catalog](/api-guides/webhook-events) is the source of truth for trigger strings and dispatch rules (each change fires at most one trigger — the most specific that applies). > [!WARNING] > > The only per-status webhooks are **`APPROVED`** and **`EXCEPTION`** — and those reflect the **review lifecycle**, not ingestion. To know that *ingestion* completed (matched + audited), listen to `update.carrier_invoice` / `update.carrier_invoice.shipment_updated`, or poll. Other status transitions (`UNDER_REVIEW`, `PAID`, …) don't each get their own trigger. ```javascript theme={null} // Express-style receiver — see /api-guides/webhooks for auth + the full envelope. app.post('/webhooks/upwell', (req, res) => { const event = req.body; // { trigger, resourceId, payload, ... } switch (event.trigger) { case 'update.carrier_invoice.shipment_updated': if (event.payload.new?.shipment_id || event.payload.carrierInvoice?.shipment) onMatched(event.resourceId, event.payload); break; case 'update.carrier_invoice.status.APPROVED': onApproved(event.resourceId, event.payload.carrierInvoice); break; case 'update.carrier_invoice.status.EXCEPTION': onException(event.resourceId, event.payload.new, event.payload.old); break; } res.json({ ok: true }); }); ``` ## Which should I use? > [card] Webhooks > > Best when you can host an HTTPS endpoint. Near-real-time, no polling load. > [card] Polling > > Best when you can't receive inbound requests, or as a backstop. Read `GET /carrier_invoices/{id}` (+ `/documents`) with backoff. > [!NOTE] > > Webhook delivery retries on `5xx` and can be delayed under load. A robust integration uses webhooks for timeliness **and** reconciles with a periodic poll so a missed delivery never leaves an invoice stuck in your system. Both approaches are shown above, and [Outbound webhooks](/api-guides/webhooks) covers the delivery and retry behavior in full. # Submitting carrier invoices via API Source: https://docs.upwell.com/api-guides/carrier-invoice-submission Create a carrier invoice, attach its documents, and let Upwell process it — the same way the email pipeline does. # Submitting carrier invoices via API If you're an API-integrated TMS, you can push carrier invoices to Upwell programmatically instead of forwarding them by email. An invoice submitted this way gets **identical processing** to one received over email: shipment/carrier/bill (What your TMS says you expect to owe a carrier for a shipment — the expected payable.) matching, the exception (A flagged audit finding on an invoice — a mismatch, missing document, or failed match. Open exceptions gate approval.) audit, and AI classification of any documents you attach. This guide walks the end-to-end flow. For the full request/response schema of each endpoint, see the auto-generated [API Reference](/api-reference/introduction) — this page focuses on the workflow and the things that aren't obvious from the schema alone. > [!NOTE] > > This flow reuses existing endpoints — there's no separate "carrier invoice API" to learn. The same `POST /api/rest/carrier_invoices` and `POST /api/rest/generate-upload-presigned-url` endpoints power the structured submission and its document uploads. ## Prerequisites * An **API key** included on every request (`Authorization: YOUR_API_KEY` — a `Bearer` prefix also works). See [Authentication](/authentication). * Optionally, the Upwell **`carrierId`** / **`shipmentId`** if you already know the match. You don't need them — Upwell matches the invoice to a shipment, carrier, and bill from the references you send (`carrierProNumber`, `billOfLadingNumber`, `customerPoNumber`, `customerReferenceNumber`). > [!NOTE] > > Your API key is bound to an **integration**. Upwell uses that binding to stamp every invoice you submit as API-sourced — you don't (and can't) set the source yourself. See the warning under Step 1. ## The flow **1. Create the carrier invoice** `POST /api/rest/carrier_invoices` with the invoice's structured data wrapped in `input`. Store the `id` from the response. **2. Attach documents (optional)** For each PDF (the invoice scan, BOL, POD, …) request a presigned URL, then `PUT` the bytes to it. **3. Let it process — then read the outcome** Upwell matches the invoice and runs the exception audit asynchronously (seconds). You learn the outcome by polling or by webhook — see [Knowing when a carrier invoice is processed](/api-guides/carrier-invoice-status). ## Step 1 — Create the carrier invoice You send a **bare invoice**: the header fields plus whatever references help Upwell match it. Upwell fills in the matched shipment/carrier/bill and the provenance during processing. > [!WARNING] > > * **Don't send `sourceSystem`** — Upwell always stamps `source_system = "API"` (and your integration) server-side. > * **Do send `sourceSystemId`** — set it to *your* stable external id for this invoice (e.g. your TMS's invoice id). It's how Upwell de-duplicates re-posts, though not synchronously — see [Re-submitting](#re-submitting) for the actual mechanics before you rely on it. Omit it only if you have no external id to key on. > * **`balance` and `status` are the only required fields.** Send `invoiceNumber` and `totalAmount` when you have them (your values are authoritative), but they're optional — anything you leave blank is filled from the documents you attach in Step 2. For a new invoice, `balance` equals the invoice total; use `status: "RECEIVED"` when you're sending the invoice data, or `"AWAITING_INVOICE"` if the invoice document will follow (it auto-promotes to `RECEIVED` once that document arrives and parses). > * **Money is integer cents.** `$2,847.50` → `284750`. > * The create response does **not** echo a client id — **store the returned `id`** as your handle. ```bash cURL theme={null} curl -X POST https://api.upwell.com/api/rest/carrier_invoices \ -H "Authorization: YOUR_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "input": { "invoiceNumber": "INV-99821", "carrierName": "Acme Freight", "totalAmount": 284750, "balance": 284750, "status": "RECEIVED", "currency": "USD", "issueDate": "2026-06-20", "dueDate": "2026-07-20", "billOfLadingNumber": "BOL-77123", "carrierProNumber": "PRO-44120" } }' ``` ```javascript JavaScript theme={null} const res = await fetch('https://api.upwell.com/api/rest/carrier_invoices', { method: 'POST', headers: { Authorization: 'YOUR_API_KEY', 'Content-Type': 'application/json' }, body: JSON.stringify({ input: { invoiceNumber: 'INV-99821', carrierName: 'Acme Freight', totalAmount: 284750, // integer cents — $2,847.50 balance: 284750, // required; equals totalAmount for a new invoice status: 'RECEIVED', // required currency: 'USD', issueDate: '2026-06-20', dueDate: '2026-07-20', billOfLadingNumber: 'BOL-77123', carrierProNumber: 'PRO-44120', sourceSystemId: 'YOUR_TMS-CI-99821', // your external invoice id — enables idempotent re-posts // NOTE: do not send sourceSystem — always server-stamped to "API". }, }), }); const { createCarrierInvoice } = await res.json(); const carrierInvoiceId = createCarrierInvoice.id; // store this ``` ### Response ```json theme={null} { "createCarrierInvoice": { "id": "cari_a1b2c3d4e5", "invoiceNumber": "INV-99821", "status": "RECEIVED", "balance": 284750, "currency": "USD", "shipmentId": null, "billId": null, "carrierId": null, "exceptions": "NO MATCHING SHIPMENT, INVOICE AMOUNT MISMATCH", "carrierInvoiceLineItems": [] } } ``` The matched `shipmentId` / `billId` / `carrierId` are `null` at this instant — matching runs a moment later (see Step 3). Note that **`exceptions` is a comma-joined string** (not an array); on a brand-new row it reflects the un-matched state and settles after processing. ### Fields Send these inside `input`: | Field | Notes | | - | - | | `invoiceNumber` | Recommended. The carrier's invoice number. If omitted, it's parsed from the attached `CARRIER_INVOICE` document. When the **Verify invoice number** audit rule is on for your workspace and the invoice still has no number, Upwell opens a **Missing invoice number** exception (`CARRIER_INVOICE_MISSING_INVOICE_NUMBER`), which keeps the invoice out of auto-approval until a number is set. | | `totalAmount` | Recommended. Integer cents — if omitted, it's parsed from the attached invoice document. | | `balance` | **Required.** Outstanding amount in cents (equal to the invoice total for a new invoice). | | `status` | **Required.** `"RECEIVED"` when you're sending the invoice data; `"AWAITING_INVOICE"` if the invoice document follows (auto-promotes to `RECEIVED` when it parses). | | `currency` | ISO code, e.g. `"USD"`. | | `carrierName` | Carrier name as printed — helps matching and avoids a spurious "no carrier name" finding. | | `carrierProNumber`, `billOfLadingNumber`, `customerPoNumber`, `customerReferenceNumber` | Matching references. `carrierProNumber` is the strongest. | | `shipmentId`, `carrierId` | Pin the match yourself if you already know it. | | `sourceSystemId` | Your external invoice id. Powers idempotent re-posts — see [Re-submitting](#re-submitting). | | `loadNumber`, [`issueDate`](/conventions/dates-and-times#issue-date), [`dueDate`](/conventions/dates-and-times#due-date), `totalTaxAmount`, `metadata`, `referenceNumbers` | Optional. | > [!NOTE] > > **Document content populates the invoice.** Any header field you leave blank — invoice number, amounts, currency, dates, references — and the **line items**, **remit-to / factor**, and **carrier** are filled from the documents you attach in Step 2, after they're classified and parsed. Consumer-supplied values are authoritative: a field you set is never overwritten, and a genuine disagreement (e.g. a different total) is raised as an exception rather than silently changed. Line items aren't settable directly on create — they come from the documents. > > This also holds for **late-arriving documents**: fields fill in whenever a document finishes parsing, even if it's attached after creation — or after the invoice has been approved. On an already-approved invoice, blanks are still filled in place, but the status and any resolved exceptions are left untouched. > [!TIP] > > See [Integration patterns](/integration-patterns) for the cross-cutting rules: integer-cents money, the `input` wrapper, and the presigned-upload header gotcha. ### Re-submitting `POST /api/rest/carrier_invoices` is a plain insert — it does not check for an existing `sourceSystemId` before creating the row, and it **always returns a new id**, even on a re-post. De-duplication happens **afterward**, asynchronously, once the background enrichment pass runs on the new row: if it finds another live invoice already holding the same `sourceSystemId` for your tenant, it soft-deletes the **newer** row (the one you just posted) and leaves the original untouched. The end state is one live invoice, but getting there is not synchronous, and it's not scoped the way you might expect: > [!WARNING] > > * **The key is `(tenant, sourceSystemId)` — not `(your integration, sourceSystemId)`.** Two different integrations on the same tenant that happen to submit the same external id string will collide with each other's invoices, not just their own. > * **There's a real window (typically seconds) where the duplicate is live** under its own `id` before the background pass soft-deletes it. If a request times out on your end and you retry, both the original and the retry may briefly exist as separate live rows — and it's the **newer** one that gets soft-deleted, which may or may not be the `id` your client actually has in hand. **Don't treat the `id` from a retried `POST` as automatically correct.** If you're not certain whether an earlier submit with the same `sourceSystemId` already succeeded, look up the surviving row instead of trusting the response you just got: ```bash theme={null} curl -g "https://api.upwell.com/api/rest/carrier_invoices?where={\"sourceSystemId\":{\"_eq\":\"YOUR_TMS-CI-99821\"},\"deletedAt\":{\"_isNull\":true}}" \ -H "Authorization: YOUR_API_KEY" ``` The `-g` matters: it turns off curl's URL globbing, which otherwise reads the JSON braces in the query string as a glob pattern and rejects the command with `nested brace in URL` before any request is sent. The [`deletedAt`](/conventions/dates-and-times#deleted-at) filter matters just as much: the list endpoint does **not** exclude soft-deleted rows on its own, and its response doesn't include [`deletedAt`](/conventions/dates-and-times#deleted-at) — so a lookup without the filter can return the surviving invoice and the soft-deleted retry as two indistinguishable rows. One timing caveat even with the filter: de-duplication is asynchronous, and the timed-out original may itself still be in flight. That produces two transient states. A lookup can return **both** rows live — dedup simply hasn't run yet. More subtly, it can return exactly one live row that is about to lose: if your retry's row became visible before the original insert landed, the dedup pass will still soft-delete the **newer** row once both exist, which may be the very row your poll just returned. So don't persist the first single-row response. Reconcile only after your last submit attempt has completed or conclusively failed, then poll until the lookup returns the **same single live row** a few seconds apart — that stable row is the survivor. If you omit `sourceSystemId`, there's no key to de-duplicate on, so a re-post **does** create a permanent duplicate. Either way, store the returned `id` on first submit and use `PUT /api/rest/carrier_invoices/{id}` for later corrections — just be prepared to reconcile via the lookup above if you're re-submitting after an uncertain prior attempt. ### Bulk create `POST /api/rest/bulk-carrier-invoices` accepts `{ "inputs": [...] }` — an array of the same objects you'd send individually to `/api/rest/carrier_invoices`. Every row goes through the same asynchronous enrichment and `sourceSystemId` de-duplication described above, independently per row — there's no batch-level atomicity guarantee beyond what a single row gets. ## Step 2 — Attach documents Documents go through the standard two-step presigned-upload flow. Use it for every carrier document — the invoice scan, BOLs, PODs, and so on. **1. Request a presigned URL** `POST /api/rest/generate-upload-presigned-url` with `associationType: "CARRIER_INVOICE"` and `associationId` set to the invoice `id` from Step 1. The response contains **only** `uploadUrl` and `documentId`. **2. PUT the bytes** Upload the raw file to `uploadUrl`. Send `Content-Type`; don't add other headers (see the tip below). ```javascript JavaScript theme={null} // 1) ask Upwell for a presigned URL for a CARRIER_INVOICE document const presign = await fetch( 'https://api.upwell.com/api/rest/generate-upload-presigned-url', { method: 'POST', headers: { Authorization: 'YOUR_API_KEY', 'Content-Type': 'application/json' }, body: JSON.stringify({ input: { associationType: 'CARRIER_INVOICE', associationId: carrierInvoiceId, // the id from Step 1 documentType: 'CARRIER_INVOICE', // or NOTICE_OF_ASSIGNMENT, BILL_OF_LADING, PROOF_OF_DELIVERY, UNKNOWN, … fileName: 'invoice-99821.pdf', mimeType: 'application/pdf', // On DOCUMENTS, sourceSystem + sourceSystemId ARE yours to set (both or neither): sourceSystem: 'YOUR_TMS', sourceSystemId: 'YOUR_TMS-CI-99821-DOC1', }, }), }, ).then((r) => r.json()); // the result is wrapped under `generateUploadPresignedUrl`; only these two fields are returned const { uploadUrl, documentId } = presign.generateUploadPresignedUrl; // 2) PUT the raw bytes (an ArrayBuffer, not a typed Blob) await fetch(uploadUrl, { method: 'PUT', headers: { 'Content-Type': 'application/pdf' }, body: fileArrayBuffer, }); ``` ```bash cURL theme={null} # 1) presigned URL curl -X POST https://api.upwell.com/api/rest/generate-upload-presigned-url \ -H "Authorization: YOUR_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "input": { "associationType": "CARRIER_INVOICE", "associationId": "cari_a1b2c3d4e5", "documentType": "CARRIER_INVOICE", "fileName": "invoice-99821.pdf", "mimeType": "application/pdf", "sourceSystem": "YOUR_TMS", "sourceSystemId": "YOUR_TMS-CI-99821-DOC1" } }' # -> { "generateUploadPresignedUrl": { "uploadUrl": "https://...s3...", "documentId": "doc_..." } } # 2) upload the bytes curl -X PUT "https://...s3..." \ -H "Content-Type: application/pdf" \ --data-binary @invoice-99821.pdf ``` > [!TIP] > > The presigned URL is signed for `host`-only headers. You can send `Content-Type` on the `PUT`, > but avoid adding headers that aren't in `X-Amz-SignedHeaders`. Wrapping the body in a `Blob` > with an explicit type can cause some Node `fetch` implementations to add headers that break the > signature — passing an `ArrayBuffer` is the safe path. Full upload mechanics: > [Document conventions](/conventions/documents#document-upload-two-step-presigned-url). > [!NOTE] > > The `(sourceSystem, sourceSystemId)` pair on a document must be **both set or both null** — see > [Document conventions](/conventions/documents). ### Document types and AI classification If you know the document's type, pass it (`CARRIER_INVOICE`, `NOTICE_OF_ASSIGNMENT`, `BILL_OF_LADING`, `PROOF_OF_DELIVERY`, …) and it's used as-is. If you don't — or you're uploading a combined PDF — pass `documentType: "UNKNOWN"`; when AI classification is enabled for your tenant, Upwell splits and classifies the upload, assigning each resulting document a real type. The document stays `UNKNOWN` until classification completes. See [Knowing when a carrier invoice is processed](/api-guides/carrier-invoice-status). > [!NOTE] > > If the carrier factors their receivables, attach the **`NOTICE_OF_ASSIGNMENT`** (the factoring notice). The invoice's **remit-to / factor** is populated only from parsed documents — the `NOTICE_OF_ASSIGNMENT`, or factoring details printed on the invoice document itself. If neither carries a factoring signal, remit-to stays empty and remit-to checks can't run. ## Step 3 — Let it process Once the invoice exists, Upwell processes it asynchronously (typically within seconds): it stamps `source_system = "API"`, matches the invoice to a shipment/carrier/bill from your references, and runs the exception audit. You don't call anything for this — you observe the result. > [card] [Next: Knowing when it's processed](/api-guides/carrier-invoice-status) > > Poll the invoice, or subscribe to webhooks, to learn when matching, the exception audit, and document classification are done. ## Recording carrier payments Once a carrier invoice is approved, a **carrier payment line item** records that a payment was made against it — the AP counterpart to a customer payment's line items on the AR side. `POST /api/rest/carrier_payment_line_items` (bulk variant: `POST /api/rest/bulk-carrier-payment-line-items`, same `{ "inputs": [...] }` shape as elsewhere) creates one. ```bash theme={null} curl -X POST https://api.upwell.com/api/rest/carrier_payment_line_items \ -H "Authorization: YOUR_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "input": { "carrierId": "car_def456", "billId": "bil_a1b2c3", "amount": 350000, "status": "PAID", "checkOrAchNumber": "ACH-88213", "transactionDate": "2026-07-25", "sourceSystemId": "YOUR_TMS-PMT-771" } }' ``` | Field | Notes | | - | - | | `carrierId`, `billId` | The carrier being paid and the bill this payment amount applies to. | | `amount` | Integer cents. | | `status` | Payment status string, e.g. `"PAID"`. | | `checkOrAchNumber`, [`transactionDate`](/conventions/dates-and-times#transaction-date) | Payment reference details. | | `sourceSystem` / `sourceSystemId` | External key pair — same idempotent-upsert pattern as other resources (see [Idempotency & retries](/conventions/idempotency-and-retries)). | | `billingAccountNumber`, `billingName`, `referenceNumber`, `notes` | Optional. | > [!NOTE] > > A carrier payment line item's real parent is technically a **bill payment** (`blp_`) via `billPaymentId`, not `billId`. `billPaymentId` **is** accepted on create/update, but it is **not** included in the response body, and it is rarely populated in practice — `billId` is the link that carrier payment line items are reliably keyed on. Treat `billId` as the field to build against; don't assume `billPaymentId` will be populated or plan a workflow around reading it back. # Managing customer invoices (AR) via API Source: https://docs.upwell.com/api-guides/customer-invoices Create, update, and send customer invoices — the accounts-receivable counterpart to the carrier-invoice submission flow. # Managing customer invoices A **customer invoice** (`inv_…`) is what you bill your customer (shipper) for a shipment — the accounts-receivable side. This page covers creating invoices, adding line items and documents, and reading them back. > [!NOTE] > > This is the **AR** (money in) side. For submitting **carrier invoices** (money out, AP), see [Submitting carrier invoices via API](/api-guides/carrier-invoice-submission). For the relationship between these objects, see [Core concepts & data model](/concepts/data-model). ## Prerequisites * An **API key** — see [Authentication](/authentication). * A **customer** (`cus_…`) to bill. A shipment can already exist, or you can [create it with the invoice](#create-a-shipment-with-the-invoice). See [Syncing foundation entities](/api-guides/syncing-foundation-entities). * A chosen balance model and cutover plan — see [Accounts receivable integration requirements](/api-reference/ar-overview). ## Create an invoice `POST /api/rest/invoices` creates a customer invoice. The invoice is tied to a shipment and a customer: ```bash cURL theme={null} curl -X POST https://api.upwell.com/api/rest/invoices \ -H "Authorization: YOUR_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "input": { "customerId": "cus_def456", "invoiceShipments": { "data": [{ "shipmentId": "shi_abc123" }] }, "number": "INV-2026-0815", "totalAmount": 450000, "balance": 450000, "currency": "USD", "issueDate": "2026-07-10", "dueDate": "2026-08-09", "sourceSystem": "YOUR_TMS", "sourceSystemId": "INV-0815" } }' ``` ```javascript JavaScript theme={null} const res = await fetch('https://api.upwell.com/api/rest/invoices', { method: 'POST', headers: { Authorization: 'YOUR_API_KEY', 'Content-Type': 'application/json' }, body: JSON.stringify({ input: { customerId: 'cus_def456', invoiceShipments: { data: [{ shipmentId: 'shi_abc123' }] }, number: 'INV-2026-0815', totalAmount: 450000, // integer cents — $4,500.00 balance: 450000, // required; equals totalAmount for a new invoice currency: 'USD', issueDate: '2026-07-10', dueDate: '2026-08-09', sourceSystem: 'YOUR_TMS', sourceSystemId: 'INV-0815', }, }), }); const { createInvoice } = await res.json(); const invoiceId = createInvoice.id; // store this — e.g. "inv_xYz789" ``` ### Fields | Field | Required | Notes | | - | - | - | | `balance` | **Yes** | Outstanding balance in **integer cents**. For a new invoice, equals `totalAmount`. `NOT NULL` with no server default — omitting it is a `400`. | | `customerId` | Recommended | Links the invoice to a customer (`cus_…`). | | `invoiceShipments` | Recommended | Links existing shipments using `{ "data": [{ "shipmentId": "shi_…" }] }`, or [creates a new shipment in the same call](#create-a-shipment-with-the-invoice). | | `number` | Recommended | Your invoice number. | | `totalAmount` | Recommended | Invoice total in **integer cents**. `$4,500.00` → `450000`. | | `currency` | No | ISO code, defaults to `USD`. | | [`issueDate`](/conventions/dates-and-times#issue-date) | Recommended | The [date on the invoice](/conventions/dates-and-times#issue-date), in `YYYY-MM-DD` format. This API calls it [`issueDate`](/conventions/dates-and-times#issue-date), not [`invoiceDate`](/conventions/dates-and-times#invoice-date). | | [`dueDate`](/conventions/dates-and-times#due-date) | Recommended | [Payment due date](/conventions/dates-and-times#due-date), in `YYYY-MM-DD` format. Drives aging and reminder scheduling. | | [`shipDate`](/conventions/dates-and-times#ship-date) / [`deliveryDate`](/conventions/dates-and-times#delivery-date) | No | [Shipping date](/conventions/dates-and-times#ship-date) and [freight delivery date](/conventions/dates-and-times#delivery-date) recorded on the invoice. These are separate from invoice issuance. | | `referenceNumbers` | No | [Reference-number object](/conventions/field-shapes#reference-numbers), such as `{ "customerPoNumber": "PO-123" }`. Send JSON directly. | | `sourceSystem` / `sourceSystemId` | Recommended | External key pair — unique per tenant. See [Idempotency & retries](/conventions/idempotency-and-retries). | | `customerPoNumber`, `billOfLadingNumber` | No | Reference numbers. | | `status` | No | See [Invoice lifecycle](#invoice-lifecycle) for the full list. Defaults to `CREATED` for new invoices. | > [!WARNING] > > `POST` is **not** retry-safe for invoices — re-posting an existing `(sourceSystem, sourceSystemId)` pair returns a `400 Uniqueness violation`. Use `POST` for first sync, `PUT` for updates. See [Idempotency & retries](/conventions/idempotency-and-retries). ## Create a shipment with the invoice You do not need a separate shipment-create call. Nest `shipment.data` inside an `invoiceShipments.data` entry: ```json theme={null} { "input": { "customerId": "cus_def456", "number": "INV-123", "balance": 450000, "totalAmount": 450000, "issueDate": "2026-10-16", "sourceSystem": "YOUR_TMS", "sourceSystemId": "INV-123", "invoiceShipments": { "data": [ { "shipment": { "data": { "shipmentId": "LOAD-123", "customerId": "cus_def456", "sourceSystem": "YOUR_TMS", "sourceSystemId": "LOAD-123", "readyDate": "2026-10-15" } } } ] } } } ``` Send this body to `POST /api/rest/invoices`. The invoice, new shipment, and their link are inserted in one database transaction. If any insert fails, the transaction rolls back. Background document/workflow processing happens separately after the insert. The two meanings of `shipmentId` matter: * Inside `shipment.data`, `shipmentId` is your **load/shipment number**, such as `LOAD-123`. * Directly on the `invoiceShipments.data` entry, `shipmentId` is an **existing Upwell shipment ID**, such as `shi_abc123`. Use one of those forms per link. When embedding `shipment.data`, omit the link's `shipmentId` and `invoiceId`; the nested insert supplies them. Set shipment fields such as `customerId` explicitly when wanted; they are not copied automatically from the invoice. Read the new shipment's Upwell ID from `createInvoice.invoiceShipments[].shipment.id` and store it. For an existing shipment, use the linking form from the first example. Nested creation is not an upsert: a duplicate external key can fail the entire request. After a timeout, search/read the invoice by its external key before retrying. The shipment's [readyDate](/conventions/dates-and-times#ready-date) describes planned readiness. The invoice's [issueDate](/conventions/dates-and-times#issue-date) describes invoice issuance; they need not match. This nested form is for creation. To attach a shipment to an existing invoice, use the [link endpoint](#adding-or-removing-a-shipment); invoice `PUT` inputs do not accept nested shipment inserts. ## Add line items `POST /api/rest/invoice_line_items` adds a line item to an existing invoice: ```bash theme={null} curl -X POST https://api.upwell.com/api/rest/invoice_line_items \ -H "Authorization: YOUR_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "input": { "invoiceId": "inv_xYz789", "lineNumber": "1", "item": "Line haul — Chicago to Dallas", "description": "Full truckload, 42,000 lbs", "quantity": 1, "unitPrice": 400000, "totalAmount": 400000, "sourceSystem": "YOUR_TMS", "sourceSystemId": "INV-0815-LI-1" } }' ``` | Field | Notes | | - | - | | `invoiceId` | **Required.** The invoice this line item belongs to (`inv_…`). | | `lineNumber` | Line sequence (string). | | `item` | Short description (e.g. charge type). | | `description` | Longer description. | | `quantity` | Quantity (numeric). | | `unitPrice` | Per-unit price in **integer cents**. | | `totalAmount` | Line total in **integer cents**. | | `sourceSystem` / `sourceSystemId` | Your external key for this line item. | Update with `PATCH /api/rest/invoice_line_items/{id}`. Delete with `DELETE /api/rest/invoice_line_items/{id}`. ## Attach documents to an invoice Attach supporting documents (the invoice PDF, BOLs, PODs) to a customer invoice using the same presigned-upload flow as carrier invoices: **1. Request a presigned URL** `POST /api/rest/generate-upload-presigned-url` with `associationType: "INVOICE"` and `associationId` set to the invoice ID. **2. PUT the bytes** Upload the raw file to `uploadUrl`. ```bash theme={null} curl -X POST https://api.upwell.com/api/rest/generate-upload-presigned-url \ -H "Authorization: YOUR_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "input": { "associationType": "INVOICE", "associationId": "inv_xYz789", "documentType": "CUSTOMER_INVOICE", "fileName": "invoice-2026-0815.pdf", "mimeType": "application/pdf", "sourceSystem": "YOUR_TMS", "sourceSystemId": "INV-0815-DOC" } }' ``` You can also attach documents from the shipment — documents on a shipment are automatically visible on invoices linked to that shipment, so you often don't need to re-upload. See [Working with shipment documents](/api-guides/shipment-documents). > [!NOTE] > > Alternatively, `POST /api/rest/invoices/{invoiceId}/documents` accepts base64-encoded documents directly — convenient for smaller files. For large documents, the presigned-URL flow avoids payload size limits. ## Read invoices back ```bash theme={null} # List invoices curl "https://api.upwell.com/api/rest/invoices?limit=50" \ -H "Authorization: YOUR_API_KEY" # Get one invoice curl https://api.upwell.com/api/rest/invoices/inv_xYz789 \ -H "Authorization: YOUR_API_KEY" ``` ### Search by source system `POST /api/rest/invoices/search` finds invoices by their external key: ```bash theme={null} curl -X POST https://api.upwell.com/api/rest/invoices/search \ -H "Authorization: YOUR_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "where": { "sourceSystem": { "_eq": "YOUR_TMS" }, "sourceSystemId": { "_eq": "INV-0815" } }, "limit": 10, "offset": 0 }' ``` The endpoint accepts a Hasura-style `where` filter (plus `orderBy`, `limit`, `offset`). The response includes nested `invoiceLineItems` so you can read the full invoice in one call. ### List an invoice's documents ```bash theme={null} curl https://api.upwell.com/api/rest/invoices/inv_xYz789/documents \ -H "Authorization: YOUR_API_KEY" ``` ## Update an invoice `PUT /api/rest/invoices/{id}` updates by Upwell ID. `PUT /api/rest/invoices` (without an ID) updates by `sourceSystem` + `sourceSystemId` in the body. ```bash theme={null} curl -X PUT https://api.upwell.com/api/rest/invoices/inv_xYz789 \ -H "Authorization: YOUR_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "input": { "status": "SENT", "dueDate": "2026-08-15" } }' ``` For the standard payment-ledger model, do not write `balance` or a paid status when recording cash. Create or correct the invoice-linked [customer payment line item](/api-guides/customer-payments#how-applications-update-invoices), and Upwell recalculates both fields together. ### Reference numbers corrected in the app When a user adds or corrects a reference on the invoice in the Upwell app, Upwell pins that value, and the reference shows a **Manually set** badge in the invoice's **Reference numbers** section. A pin covers one slot: a standard field (`billOfLadingNumber`, `carrierProNumber`, `customerPoNumber` or `customerReferenceNumber`, together with the same-named key in `referenceNumbers`), another flat key in `referenceNumbers`, or a named entry in `referenceNumbers.additionalReferenceNumbers`. A later `PUT` that writes a different value to a pinned slot still succeeds, but Upwell keeps the pinned value in that slot. When the value you send is non-blank, it is recorded as the value the system reported, and the badge changes to **Manually set · system reported another value**. Clearing a pinned slot (sending `null` or an empty string, or leaving the key out of a replacement `referenceNumbers` object) also leaves the pinned value in place, but records nothing and does not change the badge. Slots without a pin update normally. To change a pinned reference, a user edits it on the invoice in the app. Pins apply only while you send `referenceNumbers` as an object. A `PUT` that sends a top-level array replaces the references, pinned ones included. A `PUT` that sends a JSON-encoded string is rebuilt as an object that holds only the pinned references, so the string's other references are lost. On an invoice that has pinned references, send `referenceNumbers` as an object. ## Adding or removing a shipment `invoiceShipments` at create time (shown above) only covers the shipments you know about when the invoice is first created. To link or unlink a shipment from an **existing** invoice, use the standalone endpoints instead of trying to re-send `invoiceShipments` on a `PUT`: ```bash theme={null} # Link a shipment to an existing invoice curl -X POST https://api.upwell.com/api/rest/invoice_shipments \ -H "Authorization: YOUR_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "input": { "invoiceId": "inv_xYz789", "shipmentId": "shi_def456" } }' # Unlink a shipment from an invoice curl -X DELETE https://api.upwell.com/api/rest/invoice_shipments/inv_xYz789/shi_def456 \ -H "Authorization: YOUR_API_KEY" ``` > [!NOTE] > > Linking or unlinking a shipment triggers a background re-sync of that shipment's documents onto (or off of) the invoice — the same "documents on a shipment are automatically visible on invoices linked to that shipment" behavior described above, kept in sync as the shipment list changes. ## Invoice lifecycle Invoices move through these statuses: | Status | Meaning | | - | - | | `CREATED` | Invoice record exists but hasn't been finalized. | | `OPEN` | Invoice is finalized and ready for delivery. | | `APPROVED` | Invoice has been approved for sending. | | `PROCESSING` | Invoice is being processed for delivery. | | `SENT` | Invoice has been delivered to the customer. | | `DELIVERED` | Invoice delivery has been confirmed. | | `VIEWED` | Customer has viewed the invoice (online portal). | | `OVERDUE` | Past due date with an outstanding balance. | | `PART_PAID` | Partially paid — balance is between `0` and `totalAmount`. | | `PAID` | Fully paid — balance is `0` or less. | | `DISPUTED` | Customer has raised a dispute. | | `PORTAL_EXCEPTION` | The invoice hit an exception during portal delivery. | | `PORTAL_RESOLVED` | A portal exception has been resolved. | | `REJECTED` | Invoice was rejected. | | `CANCELLED` | Invoice was cancelled. | | `WRITE_OFF` | Written off as uncollectible. | | `REFUNDED` | A refund was issued. | | `SEND_ERROR` | Invoice delivery failed. | > [!TIP] > > When a [customer payment](/api-guides/customer-payments) is applied through a linked line item, Upwell updates the invoice's `balance`, payment status, and paid date automatically. If your source system cannot send complete payment applications, coordinate an [authoritative-balance model](/api-reference/ar-overview#authoritative-balance-model) with Upwell before sending balance snapshots. For statements, the default **All outstanding** filter excludes `CREATED`, `PAID`, and `CANCELLED`. Use an open or delivery lifecycle status when an invoice is ready to appear, or intentionally select **All outstanding including created** for a workflow where draft invoices are statement-ready. ### Invoices that automatic delivery skips Upwell's automatic email and portal delivery skips a customer invoice in either of these cases: * **The total is \$0.** `totalAmount` is exactly `0`. Negative totals, such as credit memos, are still delivered. * **A linked load was canceled before delivery.** A linked shipment's `status` is `canceled`, `cancelled`, or `voided` (case-insensitive, surrounding whitespace ignored), and that shipment has no `deliveredAt`. A load your TMS marks canceled after delivery is still billed. A canceled load does not block an invoice that carries a nonzero TONU (truck ordered, not used) or cancellation fee line item. Upwell recognizes these fees by accessorial code or line item description. An exact \$0 total still blocks, even with a TONU line item. The invoice keeps its `CREATED` status, and approval alone does not release it. It stays in `GET /api/rest/invoices/queues/ready-to-send`, which has no field for the block reason. In the app, the invoice table and its CSV export show `$0 total` or `Load canceled` in the **Auto-send block** column. An operator can still send the invoice explicitly from the app. To let automatic delivery pick it up, correct the cause: update the invoice total or line items, or set the shipment's `status` and `deliveredAt` with `PUT /api/rest/shipments`. ## Webhook events Subscribe to invoice events in the Upwell dashboard to get notified of status changes: | Trigger | Fires when | | - | - | | `create.invoice` | An invoice is created. | | `update.invoice` | A change that is neither a tracked status transition nor a named sub-event. | | `update.invoice.status.SENT` | The invoice was sent to the customer. | | `update.invoice.status.PORTAL_EXCEPTION` | The invoice hit an exception. | An `update.invoice.status.APPROVED` trigger also exists but is **support-enabled only**. The [webhook event catalog](/api-guides/webhook-events) is the source of truth for trigger strings and dispatch rules; see [Outbound webhooks](/api-guides/webhooks) for the delivery model, retries, and payload format. ## What's next > [card] [Customer payments](/api-guides/customer-payments) > > Record remittances applied to these invoices. > [card] [Statements & reminders](/accounts-receivable/reminders) > > Automated follow-up on outstanding invoices. > [card] [Receivables management](/accounts-receivable/receivables) > > The AR dashboard and reconciliation workflow. > [card] [Shipment documents](/api-guides/shipment-documents) > > Attach supporting docs to shipments (shared with linked invoices). # Recording customer payments (remittances) via the API Source: https://docs.upwell.com/api-guides/customer-payments Create, read, and reconcile customer payments (remittances) and their line items — how a remittance applies to your receivable invoices. # Recording customer payments A **customer payment** is an incoming remittance from a shipper/customer applied against their receivable invoices. It has two levels: * The **payment** (`pym_…`) — the money that arrived: an amount, a currency, a transaction date, and the check/ACH reference it came in on. * Its **line items** (`pli_…`) — how that money is split across your invoices. Each line item applies an amount to a specific invoice (`inv_…`) for a specific customer (`cus_…`). This page covers creating a payment with its line items, reading it back, and reconciling it against receivables. For the complete data contract that keeps statements and customer balances accurate, see [Accounts receivable integration requirements](/api-reference/ar-overview). > [!NOTE] > > This is the **accounts-receivable** (money in) side. For paying *carriers* (money out) the resource is `bill-payments`, which is a separate endpoint family. For the AR concepts behind these records — reconciliation, short-pays, and the like — see [Remittances Management](/accounts-receivable/remittances) and [Accounts Receivable Management](/accounts-receivable/receivables). > [!WARNING] > > **All amounts are integer cents.** `totalAmount: 1120000` is **\$11,200.00**, not eleven million dollars. This matches every monetary field in the Upwell API. ## Create a payment with its line items The primary flow is a single `POST /api/rest/customer_payments` that inserts the payment **and** its line items together, using a nested `paymentLineItems.data` array: ```bash theme={null} curl -X POST https://api.upwell.com/api/rest/customer_payments \ -H "Authorization: YOUR_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "input": { "totalAmount": 1120000, "transactionDate": "2026-07-07", "currency": "USD", "checkOrAchNumber": "CHK004321", "checkDate": "2026-07-07", "sourceSystem": "YOUR_TMS", "sourceSystemId": "REMIT-88123", "paymentLineItems": { "data": [ { "invoiceId": "inv_jkMtQfYE", "customerId": "cus_kCRVpEUv", "totalAmount": 1120000, "status": "applied", "transactionDate": "2026-07-07" } ] } } }' # -> { "createCustomerPayment": { # "id": "pym_LQ-3Nnmq", "totalAmount": 1120000, "currency": "USD", # "checkOrAchNumber": "CHK004321", "transactionDate": "...", "createdAt": "...", "updatedAt": "...", # "paymentLineItems": [ # { "id": "pli_qi9RW1Pd", "invoiceId": "inv_jkMtQfYE", "customerId": "cus_kCRVpEUv", # "totalAmount": 1120000, "status": "applied", "createdAt": "...", "updatedAt": "..." } ] } } ``` > [!NOTE] > > When line items are **nested** under the payment like this, omit `paymentId` on each line item — the parent payment supplies the link. Fields you don't set come back `null`. ## Required fields | Level | Required | Notes | | - | - | - | | Payment | `totalAmount`, [`transactionDate`](/conventions/dates-and-times#transaction-date) | `currency` defaults to `USD` if omitted. `id`, timestamps, and tenant are set for you. | | Line item | `totalAmount`, [`transactionDate`](/conventions/dates-and-times#transaction-date), `status` | Add `invoiceId` (+ `customerId`) to apply the amount and recalculate that invoice. | ## Field reference **Payment (`pym_…`)** | Field | Meaning | | - | - | | `totalAmount` | Amount received, in **cents**. | | `currency` | ISO-4217 code (`CurrencyCodeEnum`, e.g. `USD`). Defaults to `USD`. | | [`transactionDate`](/conventions/dates-and-times#transaction-date) | Date the payment was transacted (`YYYY-MM-DD`). | | `checkOrAchNumber` / [`checkDate`](/conventions/dates-and-times#check-date) | The check or ACH reference and its date. | | `status` | Optional payment-level status — see below. | | `sourceSystem` / `sourceSystemId` | Your system's identifier for this remittance — see [idempotency](#idempotency-and-deduplication). | | `paymentLineItems` | Nested `{ "data": [ … ] }` array of line items. | **Line item (`pli_…`)** | Field | Meaning | | - | - | | `totalAmount` | Amount applied to the invoice, in **cents**. | | `totalAmountWithFees` | Optional applied amount that takes precedence over `totalAmount` in invoice balance calculations. Send only when it represents principal applied to the invoice. | | `fees` | Fees withheld, in **cents** (defaults to `0`). | | `invoiceId` | The receivable invoice (`inv_…`) this amount is applied to. | | `customerId` | The customer (`cus_…`) the payment is from. | | `status` | Free-form line-item state — see below. | | [`transactionDate`](/conventions/dates-and-times#transaction-date) | Date the line item was transacted (`YYYY-MM-DD`). | > [!NOTE] > > The line-item amounts don't have to sum to the payment's `totalAmount` — a remittance can be partially applied and reconciled later. For the complete column list, see the `customer_payments` and `customer_payment_line_items` entries in the [API Reference](/api-reference/introduction). ### Two different `status` fields These are **not** the same field, and the difference matters: * **Payment `status`** is optional and drawn from `PaymentStatusesEnum`: `PENDING`, `SUCCEEDED`, `FAILED`, `DISPUTED`, `REFUNDED`, `PAYMENT_REVERSED` — each defined in the [Vocabulary](/api-reference/vocabulary#payment-statuses). Most imported payments leave it unset; read an unset value as `SUCCEEDED` for display and reconciliation. * **Line-item `status`** is a **required free-form string**, not a fixed enum. In practice it carries reconciliation states like `applied`, `paid`, or `completed`. Don't assume a closed set of values or a fixed casing. > [!WARNING] > > In the standard API-managed balance model, neither status field decides whether a line-item amount counts against the invoice. Linking the line item to an invoice applies its amount. Do not create a pending or failed application with a nonzero amount and expect its status to keep the invoice unchanged. ## Read payments back ```bash theme={null} # List (newest-first not guaranteed — use search for ordering) curl "https://api.upwell.com/api/rest/customer_payments?limit=50" \ -H "Authorization: YOUR_API_KEY" # -> { "customerPayments": [ { "id": "pym_…", … } ] } # One payment curl https://api.upwell.com/api/rest/customer_payments/pym_LQ-3Nnmq \ -H "Authorization: YOUR_API_KEY" # -> { "customerPayment": { "id": "pym_LQ-3Nnmq", … } } ``` To filter or sort, use `POST /api/rest/customer_payments/search` with a Hasura-style `where`: ```bash theme={null} curl -X POST https://api.upwell.com/api/rest/customer_payments/search \ -H "Authorization: YOUR_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "where": { "sourceSystemId": { "_eq": "REMIT-88123" } }, "orderBy": { "createdAt": "DESC" }, "limit": 10, "offset": 0 }' # -> { "customerPayments": [ … ] } ``` ## Create many at once `POST /api/rest/bulk-customer-payments` inserts an array of payments in one call. The response is a Hasura mutation envelope — read the created rows from `returning`: ```bash theme={null} curl -X POST https://api.upwell.com/api/rest/bulk-customer-payments \ -H "Authorization: YOUR_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "inputs": [ { "totalAmount": 3300, "transactionDate": "2026-07-08" }, { "totalAmount": 23880, "transactionDate": "2026-07-08" } ] }' # -> { "createCustomerPayments": { "returning": [ { "id": "pym_…", … } ] } } ``` ## Update and delete ```bash theme={null} # Update — body carries an input object; id comes from the path curl -X PUT https://api.upwell.com/api/rest/customer_payments/pym_LQ-3Nnmq \ -H "Authorization: YOUR_API_KEY" -H "Content-Type: application/json" \ -d '{ "input": { "checkOrAchNumber": "1234567890" } }' # -> { "updateCustomerPayment": { "id": "pym_LQ-3Nnmq", "checkOrAchNumber": "1234567890", … } } # Delete curl -X DELETE https://api.upwell.com/api/rest/customer_payments/pym_LQ-3Nnmq \ -H "Authorization: YOUR_API_KEY" # -> { "deleteCustomerPayment": { "id": "pym_LQ-3Nnmq" } } ``` ## Line items on their own If you'd rather attach line items to an existing payment (or manage them independently), use the line-item endpoints directly — `GET`/`POST /api/rest/customer_payment_line_items` and `.../customer_payment_line_items/{id}`. Here, set `paymentId` explicitly to link the line item to its payment: ```bash theme={null} curl -X POST https://api.upwell.com/api/rest/customer_payment_line_items \ -H "Authorization: YOUR_API_KEY" -H "Content-Type: application/json" \ -d '{ "input": { "paymentId": "pym_LQ-3Nnmq", "invoiceId": "inv_jkMtQfYE", "customerId": "cus_kCRVpEUv", "totalAmount": 1120000, "status": "applied", "transactionDate": "2026-07-07" } }' # -> { "createCustomerPaymentLineItem": { "id": "pli_qi9RW1Pd", … } } ``` `POST /api/rest/bulk-customer-payment-line-items` bulk-creates several at once, the same `{ "inputs": [...] }` shape as `bulk-customer-payments`: ```bash theme={null} curl -X POST https://api.upwell.com/api/rest/bulk-customer-payment-line-items \ -H "Authorization: YOUR_API_KEY" -H "Content-Type: application/json" \ -d '{ "inputs": [ { "paymentId": "pym_LQ-3Nnmq", "invoiceId": "inv_jkMtQfYE", "customerId": "cus_kCRVpEUv", "totalAmount": 500000, "status": "applied", "transactionDate": "2026-07-07" }, { "paymentId": "pym_LQ-3Nnmq", "invoiceId": "inv_other1", "customerId": "cus_kCRVpEUv", "totalAmount": 620000, "status": "applied", "transactionDate": "2026-07-07" } ] }' # -> { "createCustomerPaymentLineItems": { "returning": [ { "id": "pli_…", … } ] } } ``` ## How applications update invoices Creating, changing, or deleting a linked payment line item automatically recalculates the target invoice in the standard API-managed model: ```text theme={null} balance = totalAmount - applied payment line items - credits + debits ``` A remaining balance between zero and the invoice total produces `PART_PAID`; zero or less produces `PAID`. Removing the application reopens a previously paid or partially paid invoice when its full balance is due again. A payment header without an invoice-linked line item does not change any invoice. > [!WARNING] > > If `totalAmountWithFees` is present, Upwell uses it instead of `totalAmount` for the application. Do not use it for a gross amount that includes processing fees; that would overstate the cash applied to the invoice. ### Correct or reverse an application Update the original line item's amount when the allocation was wrong. Delete it when the application should no longer exist: ```bash theme={null} # Correct the amount applied; the invoice is recalculated automatically curl -X PUT https://api.upwell.com/api/rest/customer_payment_line_items/pli_qi9RW1Pd \ -H "Authorization: YOUR_API_KEY" -H "Content-Type: application/json" \ -d '{ "input": { "totalAmount": 620000 } }' # Unapply it; the invoice is recalculated and may reopen curl -X DELETE https://api.upwell.com/api/rest/customer_payment_line_items/pli_qi9RW1Pd \ -H "Authorization: YOUR_API_KEY" ``` Changing only `status` does not reverse the amount. Preserve the line-item ID or its stable source key so corrections and returns update the original application instead of creating a second one. ## Idempotency and deduplication If you set `sourceSystem` **and** `sourceSystemId`, the pair is **unique per tenant** — within your organization no two payments can share it, and no two line items can either. Use your own remittance/transaction reference as `sourceSystemId` so re-posting the same remittance conflicts instead of creating a duplicate — a simple idempotency key for retried imports. For payment line items, use a key that identifies the individual application, not only the parent remittance. One payment can be split across several invoices, and each application must be independently correctable. > [!TIP] > > Testing against staging? Use the staging base URL `https://staging.api.upwell.com` with your > staging API key — the paths are identical, and keys are environment-specific. See > [Environments](/authentication#environments) for how staging access is provisioned. > [!NOTE] > > For the complete request and response schemas, see the `customer_payments` and `customer_payment_line_items` entries in the [API Reference](/api-reference/introduction). To submit carrier invoices (the payables side) instead, see [Submitting carrier invoices via API](/api-guides/carrier-invoice-submission). # Purchase orders and vendor invoices via API Source: https://docs.upwell.com/api-guides/purchase-orders-and-vendor-invoices Upload a purchase order or vendor invoice PDF, let Upwell parse it, then list, search, and update the resulting records. # Purchase orders and vendor invoices via API **Purchase orders** and **vendor invoices** are standalone supporting documents — inbound POs from your customers and generic (non-freight) vendor AP invoices. You upload a PDF through the same presigned-URL flow as other documents; Upwell parses it asynchronously and creates the structured record you can then list, search, and patch. This page covers the end-to-end workflow. For the complete request and response schemas, see the [API Reference](/api-reference/introduction) entries under **Purchase Orders** and **Vendor Invoices**. > [!NOTE] > > These are **not** freight carrier invoices (`carrier_invoices`) and **not** customer AR invoices (`invoices`). For those flows see [Submitting carrier invoices via API](/api-guides/carrier-invoice-submission) and [Managing customer invoices (AR)](/api-guides/customer-invoices). ## Prerequisites * An **API key** on every request (`Authorization: YOUR_API_KEY` — a `Bearer` prefix also works). See [Authentication](/authentication). * A **PDF** of the purchase order or vendor invoice. Standalone supporting-doc uploads are PDF-only, but a single upload **can** hold more than one document of the same type stacked together — Upwell detects the boundaries and splits it into separate records (see [Combined-PDF uploads](#combined-pdf-uploads) below). ## The flow **1. Request a presigned upload URL** `POST /api/rest/generate-upload-presigned-url` with `associationType` of `PURCHASE_ORDER` or `VENDOR_INVOICE`. Omit `associationId` — the parsed record is created from the upload, not attached to an existing entity. **2. PUT the PDF bytes** Upload the raw file to `uploadUrl`. `Content-Type` must match the `mimeType` you declared (`application/pdf`). **3. Poll until the parsed record appears** `GET /api/rest/documents/{documentId}/purchase-orders` or `.../vendor-invoices` returns an empty list until parsing finishes (typically within a couple of minutes). Bound the poll — see Step 3. **4. Read, search, or update** Use the list / get / search / patch endpoints below once the record exists. ## Step 1 — Request a presigned URL Standalone supporting-doc ingestion uses a dedicated `associationType` and **no** `associationId`: | Document | `associationType` | `documentType` | | - | - | - | | Purchase order | `PURCHASE_ORDER` | `PURCHASE_ORDER` | | Vendor invoice | `VENDOR_INVOICE` | `VENDOR_INVOICE` | Pass `sourceSystem` + `sourceSystemId` so retries are safe: re-requesting an already-uploaded document returns `400 DOCUMENT_ALREADY_UPLOADED`; re-requesting one whose upload never completed returns a fresh `uploadUrl` for the same document. ```bash theme={null} curl -X POST https://api.upwell.com/api/rest/generate-upload-presigned-url \ -H "Authorization: YOUR_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "input": { "associationType": "PURCHASE_ORDER", "documentType": "PURCHASE_ORDER", "fileName": "po-88123.pdf", "mimeType": "application/pdf", "sourceSystem": "YOUR_TMS", "sourceSystemId": "PO-DOC-88123" } }' # -> { "generateUploadPresignedUrl": { # "documentId": "doc_...", "uploadUrl": "https://..." } } ``` For a vendor invoice, swap both types inside `input` to `VENDOR_INVOICE`. Read `uploadUrl` and `documentId` from `generateUploadPresignedUrl` — not from the response root. > [!TIP] > > The presigned URL is signed for `host`-only headers. You can send `Content-Type` on the `PUT`, > but avoid adding headers that aren't in `X-Amz-SignedHeaders`. Wrapping the body in a `Blob` > with an explicit type can cause some Node `fetch` implementations to add headers that break the > signature — passing an `ArrayBuffer` is the safe path. Full upload mechanics: > [Document conventions](/conventions/documents#document-upload-two-step-presigned-url). ## Step 2 — Upload the PDF ```bash theme={null} curl -X PUT "$UPLOAD_URL" \ -H "Content-Type: application/pdf" \ --data-binary @po-88123.pdf ``` Uploaded bytes are verified server-side. Non-PDF content parks the document with status `UPLOAD_CONTENT_REJECTED` and is never parsed — check `GET /api/rest/documents/{documentId}`. Rejection is terminal for that `sourceSystem` + `sourceSystemId`; re-upload with a new `sourceSystemId`. ## Step 3 — Poll for the parsed record ```bash theme={null} # Purchase orders created from this document curl https://api.upwell.com/api/rest/documents/doc_abc123/purchase-orders \ -H "Authorization: YOUR_API_KEY" # Vendor invoices created from this document curl https://api.upwell.com/api/rest/documents/doc_abc123/vendor-invoices \ -H "Authorization: YOUR_API_KEY" ``` An empty list usually means parsing is still in progress — unless `GET /api/rest/documents/{documentId}` shows `status: "UPLOAD_CONTENT_REJECTED"` (invalid PDF; terminal for that `sourceSystem` + `sourceSystemId`). > [!WARNING] > > **Bound your poll.** If the list is still empty after a few minutes and the document is not `UPLOAD_CONTENT_REJECTED`, stop and treat the upload as a failed parse. A valid PDF that is not recognized as a purchase order / vendor invoice can finish without creating a supporting record and without setting a rejection status — there is no separate mismatch flag on the document today. Re-upload with the correct document (or a new `sourceSystemId`) rather than polling forever. ### Combined-PDF uploads If your upload actually contains several purchase orders or vendor invoices stacked into one PDF, Upwell detects the boundaries and splits it into one child document per document found, rather than trying to parse the whole stack as a single record. The **container** document (the one you uploaded) moves through its own status sequence while this happens, which `GET /api/rest/documents/{documentId}` on the original `documentId` will show: | Status | Meaning | | - | - | | `UPLOAD_CONTENT_ACCEPTED` | Upload received; boundary detection hasn't run yet. | | `SPLIT_FOR_PROCESSING` | The container was split; each child document is parsing independently. Still in progress — keep polling. | | `PROCESSING_COMPLETED` | Every split child finished parsing into its own purchase-order/vendor-invoice record. | | `PROCESSING_FAILED` | At least one split child failed permanently. | You don't need to look up the individual child documents yourself: `GET /api/rest/documents/{documentId}/purchase-orders` and `.../vendor-invoices` — the same polling endpoint from Step 3 — already match records from split children of that container as well as the container itself, so keep polling the **original** `documentId` you got from the presigned-URL response. Expect to see more than one record in the list once splitting has produced multiple documents; a `PROCESSING_FAILED` container may still have some purchase-order/vendor-invoice records from the children that succeeded before one of their siblings failed permanently. ### Find by your source ids If you stored `sourceSystem` + `sourceSystemId` at presign time, you can look up the parsed record without the document id: ```bash theme={null} curl -X POST https://api.upwell.com/api/rest/purchase-orders/search \ -H "Authorization: YOUR_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "sourceSystem": "YOUR_TMS", "sourceSystemId": "PO-DOC-88123" }' ``` Use `POST /api/rest/vendor-invoices/search` for vendor invoices — same body shape. ## Step 4 — List, get, and update | Action | Purchase orders | Vendor invoices | | - | - | - | | List recent | `GET /api/rest/purchase-orders` | `GET /api/rest/vendor-invoices` | | Get one | `GET /api/rest/purchase-orders/{id}` | `GET /api/rest/vendor-invoices/{id}` | | Update header | `PATCH /api/rest/purchase-orders/{id}` | `PATCH /api/rest/vendor-invoices/{id}` | | Update line item | `PATCH /api/rest/purchase-order-line-items/{id}` | `PATCH /api/rest/vendor-invoice-line-items/{id}` | List endpoints accept an optional `limit` query parameter. Get-one responses include line items and party addresses; vendor invoices also include the matched purchase order when one exists. ### Patch body shape Updates use `{ "input": { ...fields to set... } }` with the record's camelCase field names. Amounts are **integer cents**. System-managed columns (ids, tenant/document linkage, party references, match state) are not updatable and are rejected. ```bash theme={null} curl -X PATCH https://api.upwell.com/api/rest/purchase-orders/po_abc123 \ -H "Authorization: YOUR_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "input": { "poNumber": "PO-88123-R1" } }' ``` > [!WARNING] > > **Money is integer cents.** `$1,250.00` → `125000`. See [Integration patterns](/integration-patterns). ## Related * [Integration patterns](/integration-patterns) — presigned upload, integer cents, `sourceSystem` pairs * [How documents flow through Upwell](/concepts/document-lifecycle) * API Reference: [Purchase Orders](/api-reference/purchase-orders/list-purchase-orders), [Vendor Invoices](/api-reference/vendor-invoices/list-vendor-invoices) # Retrieving and managing shipment documents Source: https://docs.upwell.com/api-guides/shipment-documents List, add, and remove the documents attached to a shipment (load) via the API — and how that differs from carrier-invoice documents. # Working with shipment documents Documents — PODs, bills of lading, rate confirmations, and so on — attach to a **shipment** (the load), not only to a carrier invoice. This page covers listing, adding, and removing a shipment's documents. > [!NOTE] > > There are two document surfaces — pick the endpoint by what you're keyed on: > > * **By shipment (load):** `GET /api/rest/shipments/{shipmentId}/documents` — this page. > * **By carrier invoice (AP):** `GET /api/rest/carrier_invoices/{id}/documents` — see [Knowing when a carrier invoice is processed](/api-guides/carrier-invoice-status). ## List a shipment's documents `GET /api/rest/shipments/{shipmentId}/documents` returns the shipment's documents, keyed by `shipmentDocumentsByShipmentId`: ```bash theme={null} curl https://api.upwell.com/api/rest/shipments/shi_abc123/documents \ -H "Authorization: YOUR_API_KEY" # -> { "shipmentDocumentsByShipmentId": [ # { "id": "file_...", "documentId": "doc_...", # "createdAt": "...", "updatedAt": "...", # "shipment": { "id": "shi_abc123", "number": "LD-100245" }, # "file": { "id": "file_...", "filename": "pod.pdf", # "url": "https://...signed..." }, # "documents": [ { "id": "doc_...", "type": "PROOF_OF_DELIVERY", # "visibleToCarrier": true, "visibleToCustomer": false } ] } ] } ``` | Field | Meaning | | - | - | | `id` | File id (`file_…`). Pass this as `{id}` when deleting the document. It is not the documents row id. | | `documentId` | Documents row id (`doc_…`). | | `file.url` | Short-lived signed URL for the file bytes. Fetch it when you need the content; do not store it as a permanent link. | | `file.filename` | File name, including the extension. | | `shipment.id` / `shipment.number` | Upwell shipment id (`shi_…`) and the source load number. | | `documents` | Array of the underlying document record(s). | | `documents[].type` | Document type code, such as `PROOF_OF_DELIVERY`. `POD` is a display label, not a write value. | | `documents[].visibleToCarrier` / `visibleToCustomer` | Sharing flags. | | `documents[].sourceSystem` / `sourceSystemId` | Provenance from your system, when set. | | [`createdAt`](/conventions/dates-and-times#created-at) / [`updatedAt`](/conventions/dates-and-times#updated-at) | Timestamps. | > [!TIP] > > Testing against staging? Use the staging base URL `https://staging.api.upwell.com` with your > staging API key — the paths are identical, and keys are environment-specific. See > [Environments](/authentication#environments) for how staging access is provisioned. ## Add a document to a shipment `POST /api/rest/shipments/{shipmentId}/documents` attaches a document from base64-encoded bytes: ```bash theme={null} curl -X POST https://api.upwell.com/api/rest/shipments/shi_abc123/documents \ -H "Authorization: YOUR_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "shipmentId": "shi_abc123", "input": { "base64": "JVBERi0xLjQ...", "mimeType": "application/pdf", "type": "PROOF_OF_DELIVERY", "filename": "pod.pdf", "visibleToCarrier": true } }' # -> { "createShipmentDocument": { "id": "file_...", "documentId": "doc_..." } } ``` The create response is only those two fields. `id` is the file id (`file_…`) — use it as `{id}` on delete. `documentId` is the documents row id (`doc_…`). Call the list endpoint for `file.url` and the rest of the document. Required: `base64` (the file bytes, without a `data:` prefix), `mimeType`, and `type` (a `DocumentTypeEnum` value such as `PROOF_OF_DELIVERY`). Optional: `filename`, `visibleToCarrier`, `visibleToCustomer`, and a `sourceSystem` + `sourceSystemId` pair. > [!NOTE] > > The base64 path is convenient for smaller files. For large documents, prefer the two-step presigned-URL upload — see [Document conventions](/conventions/documents#document-upload-two-step-presigned-url). > [!WARNING] > > `sourceSystem` and `sourceSystemId` are all-or-nothing — provide both or neither. See [Integration patterns](/integration-patterns). > [!NOTE] > > Documents on the load count toward a customer's required documents for carrier invoices. Adding, removing, or reclassifying a shipment document makes Upwell re-evaluate the load's carrier invoices that aren't yet approved or paid, which can clear or reopen a **Missing required document** exception. See [Customer-required documents](/concepts/exceptions#customer-required-documents). ## Remove a document from a shipment `DELETE /api/rest/shipments/{shipmentId}/documents/{id}` removes the document's association with the shipment. `{id}` is the file id from create or list (`file_…`), not `documentId`: ```bash theme={null} curl -X DELETE https://api.upwell.com/api/rest/shipments/shi_abc123/documents/file_abc \ -H "Authorization: YOUR_API_KEY" # -> { "deleteFileAssociations": { "affectedRows": 1, # "returning": [ { "id": "fias_...", "fileId": "file_...", # "associationId": "shi_..." } ] } } ``` > [!NOTE] > > For the complete request and response schemas, see the `shipments/{shipmentId}/documents` entries in the [API Reference](/api-reference/introduction). To attach documents to a carrier invoice instead, see [Submitting carrier invoices via API](/api-guides/carrier-invoice-submission). # Syncing foundation entities Source: https://docs.upwell.com/api-guides/syncing-foundation-entities Push customers, carriers, shipments, and bills from your TMS to Upwell — the prerequisite data that makes AP and AR work. # Syncing foundation entities Before carrier invoices can match or customer invoices can bill, Upwell needs the data they reference: **customers**, **carriers**, **shipments**, **companies**, and (for AP) **bills**. This page covers how to push those records from your TMS. > [!NOTE] > > If you haven't read it yet, start with [Core concepts & data model](/concepts/data-model) — it defines every object mentioned here and how they connect. For patterns that apply to every endpoint (integer-cents money, the `input` wrapper, the presigned upload), see [Integration patterns](/integration-patterns). ## Sync order Entities reference each other, so push them in dependency order: **1. Companies (only if you invoice under more than one identity)** Your own legal entities. Most tenants already have the one they need and can skip this entirely — see [Companies](#companies). **2. Customers and carriers** These two are independent — sync them in any order (or in parallel). Everything downstream needs at least one of them. **3. Shipments** A shipment references **one** customer and one carrier by their Upwell IDs (`customerId`, `carrierId`). Sync those first, store the returned IDs, then sync shipments. **4. Bills (AP only)** A bill references a shipment and a carrier. Optional for AR-only integrations. **5. Invoices, carrier invoices, payments** These are the transactional records — each guide has its own page: [Customer invoices (AR)](/api-guides/customer-invoices), [Carrier invoice submission (AP)](/api-guides/carrier-invoice-submission), [Customer payments](/api-guides/customer-payments). ## Customers `POST /api/rest/customers` creates a customer (shipper). Store the returned `id` — you'll need it on shipments and invoices. ```bash theme={null} curl -X POST https://api.upwell.com/api/rest/customers \ -H "Authorization: YOUR_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "input": { "name": "Acme Manufacturing", "sourceSystem": "YOUR_TMS", "sourceSystemId": "CUST-10042", "emailAddress": "ap@acme-mfg.com", "paymentDiscountTerms": "Net 30" } }' ``` | Field | Required | Notes | | - | - | - | | `name` | Yes | Customer display name. | | `sourceSystem` | Recommended | Your TMS identifier constant — enables upsert-by-source-system-id. | | `sourceSystemId` | Recommended | Your TMS's primary key for this customer. Together with `sourceSystem`, this is the unique external handle. | | `emailAddress` | Recommended | Used for invoice delivery if sending invoices from Upwell. | | `paymentDiscountTerms` | No | Payment terms string (e.g. `"Net 30"`). Drives AR aging and reminder timing. | To update an existing customer, use `PUT /api/rest/customers/{id}` (by Upwell ID) or `PUT /api/rest/customers` with `sourceSystem` + `sourceSystemId` in the body to update by your external key. > [!NOTE] > > **The customer's billing address is a separate record.** It isn't a field on the customer — it's > an address row with `type: "CUSTOMER_BILLING"`, and it's what the invoice bill-to block and > delivery routing read. You can nest it in this `POST`, but never in a `PUT`. A customer may > hold at most one. See [Working with addresses](/conventions/addresses). > [!WARNING] > > `POST` is **not** idempotent for customers — re-posting an existing `(sourceSystem, sourceSystemId)` pair returns HTTP 400. Use `POST` for first sync and `PUT` for updates. See [Idempotency & retries](/conventions/idempotency-and-retries). ### Billing email recipients Customer create and update accept these optional fields inside `input`. Customer GET, list and search responses return the current values from the saved delivery settings. | Field | Saved setting | Omitted / empty input | | - | - | - | | `customer_invoice_emails` | Index-0 email delivery method; the existing writer also synchronizes its default routing target when routing is enabled. | Omit to preserve. Clearing an existing method requires `[]` and `forceClearRecipients: true`; routing targets remain configured. | | `customer_statement_emails` | One existing statement schedule. | Omit to preserve. `[]` rejects, matching the existing requirement for at least one statement recipient. No schedule means rejection, including on customer creation. | | `customer_reminder_emails` | `reminderSettings.emailAddresses`. | Omit to preserve. `[]` clears the reminder list; enablement, delivery mode and sibling settings survive. | Each field accepts an array of email strings. Addresses are validated, normalized and deduplicated using the existing invoice-recipient validation, with at most 100 recipients. Do not combine a convenience array with its native `deliveryMethods`, `statementSchedules` or `reminderSettings` representation in the same request. For statements, set `statementScheduleId` inside `input` when the customer has multiple schedules. If there is exactly one saved schedule, it is selected automatically. An invalid target or multiple schedules without a target reject before customer fields or customer rules are written. The API never creates or enables a schedule or changes its recurrence or invoice filters. ```json theme={null} { "input": { "customer_invoice_emails": ["ap@example.com"], "customer_statement_emails": ["statements@example.com"], "statementScheduleId": "EXISTING_STATEMENT_SCHEDULE_ID", "customer_reminder_emails": ["collections@example.com"] } } ``` The statement array returned by reads is the distinct union across all saved schedules, including disabled schedules. A targeted write replaces one schedule's list. The Cash Application role (`ORGCASHAPP`) receives `null` for this field because that role cannot read statement schedules. Existing recipient-write and customer-field role permissions still apply. > [!WARNING] > > Validation failures return HTTP 400. These operations can have multiple mutation > stages. A runtime database or > transport failure can follow committed changes; an error does not promise rollback. > Read the customer before retrying and use `PUT` for remaining changes. If invoice > recipient setup fails after customer creation, the error identifies the stored customer > ID for recovery. Never retry `POST` blindly after such a failure. ### Bill-to hierarchy and merging A customer record carries a few fields beyond the basics above that model billing hierarchies and account cleanup: | Field | Notes | | - | - | | `billToCustomerId` | Points at another customer that this one bills *through* — model a bill-to parent/child hierarchy here if your TMS has one (e.g. several shipping locations that all bill back to one corporate account). Settable on create/update; leave unset for a customer that bills directly. | | `billToCode`, `billToSource` | Supporting fields for the bill-to relationship above. | | `mergedIntoCustomerId`, `mergedIntoCustomer` | **Read, don't set.** A merge consolidates one customer into another (an internal Upwell operation, not something available over the public API) and then deletes the merged-away record, so the API stops returning it. You won't normally see these fields populated. Instead, creating an invoice or shipment with the old ID, or changing one to it, is rejected with `invalid_reference: customer_id "…" was merged into customer "…"`, which names the customer to use going forward ([error codes](/api-reference/error-codes)). | > [!WARNING] > > There is no public endpoint for merging customers yourself — `mergedIntoCustomerId` is set by Upwell, not a field your integration should populate. Setting it yourself would incorrectly mark your own record as merged away. ## Carriers `POST /api/rest/carriers` creates a carrier. > [!WARNING] > > Carriers do **not** follow the same duplicate-handling pattern as customers. Re-posting an existing `(sourceSystem, sourceSystemId)` pair for a **customer** hard-fails with `400 Uniqueness violation`. Re-posting the same pair for a **carrier** silently succeeds instead — it's a no-op upsert that only re-writes `sourceSystem` to itself, it does **not** update `name`, `email`, `phone`, or any other field you send. If you need to change an existing carrier's details, use `PUT`, not a repeated `POST`. ```bash theme={null} curl -X POST https://api.upwell.com/api/rest/carriers \ -H "Authorization: YOUR_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "input": { "name": "Fast Freight LLC", "sourceSystem": "YOUR_TMS", "sourceSystemId": "CAR-2088", "mcNumber": "MC-123456", "dotNumber": "1234567", "scacNumber": "FFRT", "email": "billing@fastfreight.com", "phone": "555-0200", "currency": "USD", "terms": 30 } }' ``` | Field | Required | Notes | | - | - | - | | `name` | Yes | Carrier display name. | | `sourceSystem` / `sourceSystemId` | Recommended | External key pair — same shape as customers, but see the upsert-behavior warning above. | | `mcNumber` | No | Motor carrier number. | | `dotNumber` | No | DOT number. | | `scacNumber` | No | Standard carrier alpha code. Helps Upwell match carrier invoices that reference a SCAC instead of a name. | | `email`, `phone` | No | Contact info. | | `terms` | No | Carrier payment terms, as an **integer Net-N day count** — `30` means Net 30, `45` means Net 45. `0` means Due on Receipt, and omitting the field (or `null`) leaves the terms unset. This is a plain number, not a string: send `30`, not `"30"` or `"Net 30"`. | | `isQuickpay` | No | Boolean. `true` marks the carrier as quickpay. Independent of `terms` — set both if the carrier is on quickpay with a defined day count. | | `shipmentId` | No | Pins this carrier record to one specific shipment; this field cascades — deleting that shipment deletes this carrier record too. **Not part of the normal sync path, and lightly exercised — validate the behavior before you rely on it.** A normal, shared carrier record should leave it unset. | Updates: `PUT /api/rest/carriers/{id}` (by Upwell ID) or `PUT /api/rest/carriers` (by `sourceSystem` + `sourceSystemId` in the request body). > [!NOTE] > > **Carriers are the one entity that holds its own address link.** Unlike customers and > companies — where the address points at the parent — a carrier carries `addressId` and > `billingAddressId`, and both are settable on update. See > [Which direction the link runs](/conventions/addresses#which-direction-the-link-runs). ## Shipments `POST /api/rest/shipments` creates a shipment (load). A shipment ties together a customer and a carrier and is the hub that invoices, bills, and documents hang off. ```bash theme={null} curl -X POST https://api.upwell.com/api/rest/shipments \ -H "Authorization: YOUR_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "input": { "shipmentId": "YOUR_TMS-SH-50012", "sourceSystem": "YOUR_TMS", "sourceSystemId": "SH-50012", "customerId": "cus_abc123", "carrierId": "car_def456", "customerTotalRate": 450000, "carrierTotalRate": 350000, "pickupAt": "2026-07-15T08:00:00", "deliveredAt": "2026-07-18T14:00:00", "carrierProNumber": "PRO-44120", "customerPoNumber": "PO-88001", "billOfLadingNumber": "BOL-77123", "referenceNumbers": { "otherReferenceNumbers": [ { "name": "Booking", "value": "REF-001" }, { "name": "Order", "value": "REF-002" } ] }, "status": "DELIVERED", "mode": "TL" } }' ``` | Field | Required | Notes | | - | - | - | | `shipmentId` | **Yes** | A unique string identifier — `NOT NULL`, no server default. Generate from your own key, e.g. `"YOUR_TMS-SH-50012"`. | | `sourceSystem` / `sourceSystemId` | Recommended | External key pair. | | `customerId` | Recommended | Upwell customer ID (`cus_…`). Links the shipment to AR. | | `carrierId` | Recommended | Upwell carrier ID (`car_…`). Links the shipment to AP. | | `customerTotalRate` | Recommended | What you charge the customer, in **integer cents**. `$4,500.00` → `450000`. | | `carrierTotalRate` | Recommended | What you owe the carrier, in **integer cents**. | | `carrierProNumber` | Recommended | Carrier PRO number — the strongest match key Upwell uses to match inbound carrier invoices to shipments. | | `customerPoNumber` | No | Customer purchase order number. | | `billOfLadingNumber` | No | Bill of lading number. | | `referenceNumbers` | No | [Reference-number object](/conventions/field-shapes#reference-numbers), with named additional references when needed. | | [`readyDate`](/conventions/dates-and-times#ready-date) | No | [Planned readiness date](/conventions/dates-and-times#ready-date), in `YYYY-MM-DD` format. | | [`pickupAt`](/conventions/dates-and-times#pickup-at), [`deliveredAt`](/conventions/dates-and-times#delivered-at) | No | Recorded [pickup](/conventions/dates-and-times#pickup-at) and [delivery](/conventions/dates-and-times#delivered-at) timestamps. These use timezone-free `timestamp` storage; see [formats and timezones](/conventions/dates-and-times#formats-and-timezones). | | `status` | No | Shipment status, as a **free-form string** (e.g. `DELIVERED`, `IN_TRANSIT`). Unlike invoice statuses there is no enum here — Upwell stores your TMS's own status label verbatim, and nothing validates it. If your TMS stores status as a numeric code, **map it to a readable label before sending** rather than sending the code: see [Sending a numeric status code](#sending-a-numeric-status-code). | | `mode` | No | Freight mode (`TL`, `LTL`, `INTERMODAL`, etc.). | | `onHold` / `holdReason` | No | Mirror a hold placed on the load in your TMS. See [Holding a shipment](#holding-a-shipment). | > [!WARNING] > > `shipmentId` is **required** and has no server default — omitting it returns a `400 constraint-violation`. This is different from the `id` Upwell assigns (like `shi_abc123`); `shipmentId` is your own human-readable identifier. ### Sending a numeric status code Many TMSs store load status as an integer. Upwell's `status` is typed `String`, so send the **label, not the code** — translate on your side before the call: ```json theme={null} { "input": { "shipmentId": "YOUR_TMS-SH-50012", "status": "DELIVERED" } } ``` If your codes are `1 = Available, 2 = Dispatched, 3 = In Transit, 4 = Delivered`, keep that map in your integration layer and send `"DELIVERED"` for `4`. Sending `"4"` is accepted — the column is unvalidated text — but it is strongly discouraged, for a concrete reason: the status is not just display data. It gates carrier-invoice approval. Upwell's **TMS Status Mismatch** exception lets an operator nominate which statuses mean "this load is far enough along that its carrier invoice can be approved." In Payables Settings those statuses come from two places: a dropdown listing the statuses **registered for your integration**, plus a free-text field for anything not registered. Registration is a step on our side — statuses are not discovered automatically from the loads you send, so a value we have not registered will never appear in that dropdown and has to be typed in by hand, matching exactly. That is the practical reason to send labels rather than codes. An operator choosing between `AVAILABLE / DISPATCHED / IN_TRANSIT / DELIVERED` can configure the rule correctly; one typing `1 / 2 / 3 / 4` from memory cannot, and a wrong pick either blocks valid invoices or approves loads that never delivered. Two practical notes: * **Matching is case-insensitive and whitespace-trimmed**, but otherwise exact — `"Delivered"`, `"DELIVERED"`, and `"delivered "` are the same status; `"Delivered to consignee"` is a different one. Pick one spelling per status and stay consistent, or the exception rule will silently stop matching. * **A shipment with no status at all** trips the same exception once the rule is enabled, so populate `status` on create and keep it current with `PUT /api/rest/shipments`. Status also affects customer invoice delivery. When a shipment's `status` is `canceled`, `cancelled`, or `voided` and it has no `deliveredAt`, Upwell's automatic delivery skips the customer invoices linked to it. See [Invoices that automatic delivery skips](/api-guides/customer-invoices#invoices-that-automatic-delivery-skips) for the TONU fee exception. Send `deliveredAt` for delivered loads so a later cancellation in your TMS does not hold their invoices. Send us the finished list of status strings your integration emits and we'll register them against your integration, so they appear in that dropdown ready to select rather than having to be typed in by hand. Send it once the list is stable, ideally before go-live. ### One customer per shipment This is the modeling question that trips up most TMS integrations, so it's worth stating flatly: * **A shipment has exactly one customer.** `customerId` is a single field, not a list. It is the party you will invoice — the bill-to. There is no "customers" collection on a shipment. * **The shipper and the consignee are addresses, not customers.** They go in the shipment's own slots: `pickupAddress` / `pickupAddressId` (origin) and `consigneeAddress` / `consigneeAddressId` (destination), typed `SHIPMENT_PICKUP` and `SHIPMENT_CONSIGNEE`. * **Additional stops go in `stops`**, each with its own address. A stop has two type fields and they behave differently: **`stopType` is free text** — nothing validates it, so a typo is accepted silently — while **`type` is constrained** by an enum (`ORIGIN`, `PICKUP`, `DELIVERY`, `DROP_OFF`, `TRANSFER`, `CROSS_DOCK`, `TERMINAL`, `CUSTOMS`, `LAYOVER`, `RETURN`, `STORAGE`, `FUEL_STOP`, `CONSOLIDATION`, `DECONSOLIDATION`, `OTHER`). Both are read, by different surfaces — proof-of-delivery exception evaluation and the carrier-invoice shipments view read the constrained `type`, while some outbound EDI and partner payloads read `stopType` — so populate both, drawing the same value from the enum. One caveat: this endpoint (`POST /api/rest/shipments`) accepts only `stopType`, so a stop created here cannot carry the constrained `type` until it is set through another path. The [Vocabulary](/api-reference/vocabulary#stop-types) page defines every value. So a load that picks up at one facility and delivers to another is **one** shipment, with one `customerId` and two address records — not two customer records. Only create a customer for a party you actually invoice. > [!NOTE] > > Because shipper/consignee is a **per-shipment role** rather than a property of a business, the > same warehouse being the consignee on one load and the pickup on another is completely normal. > That's two address records with two types, and no deduplication will merge them. See > [Addresses](/concepts/data-model#addresses). Updates: `PUT /api/rest/shipments/{id}` (or `PUT /api/rest/shipments?sourceSystem=…&sourceSystemId=…`) for the shipment's own scalar fields — rates (`customerTotalRate`, `carrierTotalRate`) and `declaredValue` (all integer cents), miles, `freightClass`, `lengthInFeet`, `mode`, [`readyDate`](/conventions/dates-and-times#ready-date), `referenceNumbers`, `specialInstructions`, and so on. The update input takes no nested records, so correct related data through its own endpoint: | To correct | Use | | - | - | | A pickup, consignee, or stop address | `PUT /api/rest/addresses/{id}` | | A stop | `PUT /api/rest/stops/{id}` | | A shipment line item | `PATCH /api/rest/shipment_line_items/{id}` | | Notes | `POST /api/rest/shipments/{shipmentId}/notes` (appends a note) | The pickup and consignee **links** themselves are fixed at creation — see [Working with addresses](/conventions/addresses). ### Holding a shipment When a load is held in your TMS (a red flag, a credit hold, a billing dispute), send the hold to Upwell on the shipment so invoices for that load wait until it is resolved: | Field | Type | Notes | | - | - | - | | `onHold` | Boolean | `true` while the load is held, `false` once it is released. Defaults to `false` on create; on an update, omitting it keeps the current value, so send `false` explicitly to release. Must be a JSON boolean, not the string `"true"`. | | `holdReason` | String or `null` | Why the load is held, as free text from your TMS. Shown on the exception the hold raises. | Place the hold with an update when it happens in your TMS: ```bash theme={null} curl -X PUT "https://api.upwell.com/api/rest/shipments?sourceSystem=YOUR_TMS&sourceSystemId=SH-50012" \ -H "Authorization: YOUR_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "input": { "onHold": true, "holdReason": "Credit hold" } }' ``` Release it by sending `onHold: false`, and clear the reason at the same time so a stale one is not left on the shipment: ```json theme={null} { "input": { "onHold": false, "holdReason": null } } ``` You can also send both fields on `POST /api/rest/shipments` if the load is already held when you create it. The shipment read endpoints return both fields, so you can confirm what Upwell has stored. What a hold does depends on two settings, both off by default: * **Receivables → Hold invoices while the shipment is on hold.** A customer invoice linked to a held shipment gets a **Shipment On Hold in TMS** exception that names the shipment and the `holdReason`. While the exception is open, scheduled sends, auto-send and portal delivery skip the invoice, and a manual send goes through only if a user overrides the exception with a reason. * **Payables → Check shipment on-hold status.** A carrier invoice for a held shipment gets a **Shipment on hold** exception, which keeps it out of auto-approval. You don't need to do anything else to release the invoices. When you send `onHold: false`, Upwell re-checks the linked invoices and resolves those exceptions automatically. If neither setting is on, the hold is stored on the shipment but holds nothing. ## Bills (AP only) A **bill** is the expected payable — what your TMS says you should owe a carrier for a shipment. When a carrier invoice arrives, Upwell audits it against the bill and flags mismatches as exceptions. `POST /api/rest/bills` creates a bill: ```bash theme={null} curl -X POST https://api.upwell.com/api/rest/bills \ -H "Authorization: YOUR_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "input": { "sourceSystem": "YOUR_TMS", "sourceSystemId": "BILL-30044", "carrierId": "car_def456", "proNumber": "YOUR_TMS-SH-50012", "referenceNumber": "REF-30044", "totalAmount": 350000, "currency": "USD", "issueDate": "2026-07-10", "dueDate": "2026-08-09", "status": "OPEN" } }' ``` | Field | Required | Notes | | - | - | - | | `sourceSystem` / `sourceSystemId` | Recommended | External key pair. | | `carrierId` | Recommended | Links the bill to a carrier. A bill is owed to *either* a carrier *or* a [vendor](#vendors) — set `carrierId` or `vendorId`, not both. | | `vendorId` | Recommended (non-carrier bills) | Links the bill to a vendor instead — use for a payable that isn't a hauling carrier (a lumper service, a factor, a non-freight supplier). | | `proNumber` | Recommended | The shipment/load identifier — must match the target shipment's `shipmentId` value so Upwell can link the bill to the shipment for audit comparison. This is **not** the carrier's PRO number (that goes on the shipment as `carrierProNumber`). | | `referenceNumber` | No | Your internal reference number for this bill. | | `totalAmount` | Recommended | Expected payable in **integer cents**. This is the amount Upwell compares against the carrier invoice during audit. | | [`issueDate`](/conventions/dates-and-times#issue-date) | No | Bill issue date (`YYYY-MM-DD`). | | [`dueDate`](/conventions/dates-and-times#due-date) | No | Payment due date (`YYYY-MM-DD`). | | `currency` | No | Defaults to `USD`. | | `status` | No | Bill status. | Updates: `PUT /api/rest/bills/{id}`. > [!TIP] > > Bills are optional for carrier-invoice processing — Upwell can still receive and classify carrier invoices without a matching bill. But without a bill, the exception audit can't compare expected vs. actual amounts, so you won't get amount-mismatch exceptions. If your TMS tracks expected carrier costs, push them as bills. ## Companies A **company** is one of **your own** legal entities or divisions — not an external business. It carries the identity that appears on the invoices you issue: name, logo, terms of service, MC and DUNS numbers, primary contact details. Your tenant is seeded with one from your account settings, and most integrations never need to create another. > [!WARNING] > > **Your customers are not companies.** This is the most common mis-mapping. If your TMS calls > the businesses you bill "companies", they map to Upwell **customers** — see > [Customers](#customers) above. Reach for a company only when *you* operate under more than one > brand or legal entity and an invoice needs to go out under a specific one. > > A useful test: if you'd ever send it an invoice, it's a customer. If it's the name *on* the > invoice, it's a company. You need more than one company when you invoice under multiple identities — separate subsidiaries, acquired brokerages still billing under their own name, or divisions with distinct remit-to branding. If you invoice everything under one name, one company is correct. ```bash theme={null} curl -X POST https://api.upwell.com/api/rest/companies \ -H "Authorization: YOUR_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "input": { "name": "Acme Logistics — West", "sourceSystem": "YOUR_TMS", "sourceSystemId": "DIV-WEST", "mcNumber": "MC-654321", "primaryEmailAddress": "billing@acme-west.com", "primaryPhone": "555-0300", "addresses": { "data": [ { "type": "COMPANY_ADDRESS", "streetLine1": "500 Industrial Pkwy", "city": "Reno", "stateOrProvince": "NV", "zipOrPostalCode": "89501", "country": "US" } ] } } }' ``` | Field | Required | Notes | | - | - | - | | `name` | **Yes** | Unique per tenant, **case-insensitively** — `Acme` and `ACME` collide. | | `sourceSystem` / `sourceSystemId` | No | External key, if your TMS tracks divisions. | | `mcNumber`, `dunsNumber` | No | Identifiers for this entity. | | `primaryEmailAddress`, `primaryPhone` | No | Contact details shown on the company record. **The company's phone lives here** — not on its address. | | `website`, `logoUrl`, `termsOfService` | No | Branding applied to invoices issued under this company. | | `addresses` | No | Nested address rows, **create only**. Type them `COMPANY_ADDRESS` or they won't render — see below. | > [!WARNING] > > **A company address must be typed `COMPANY_ADDRESS`.** The company pages query that value > exactly; an address of any other type is saved and linked but never displayed. The list view > shows only the oldest one. See > [Where an address shows up in the app](/conventions/addresses#where-an-address-shows-up-in-the-app). Updates: `PUT /api/rest/companies/{id}`. As with customers, the update body takes **no** nested `addresses` — write the address with `POST`/`PUT /api/rest/addresses` and its `companyId`. > [!NOTE] > > **`DELETE /api/rest/companies/{id}` is a soft delete**, unlike customers and carriers. The > record is retained with [`deletedAt`](/conventions/dates-and-times#deleted-at) set and disappears from the app, which frees its name for > reuse. Its addresses are *not* removed. See > [Deleting and archiving](/conventions/deletes-and-archiving). Reading them back is limited, and it's worth understanding before you pick a create path. `GET /api/rest/companies` and `GET /api/rest/companies/{id}` return the company's own fields but **not** its addresses, and neither accepts a filter. > [!WARNING] > > **`POST /api/rest/companies` does not return the ids of nested addresses** — its response > carries the company's scalar fields only. So the convenient nested form above hands you a > company id and nothing else, and because a company has no address read path and addresses > carry no `sourceSystem`/`sourceSystemId`, the only way back to that `addr_` id is paging the > unfiltered `GET /api/rest/addresses` list. > > **Prefer creating a company address standalone**: `POST /api/rest/addresses` with `companyId` > and `type: "COMPANY_ADDRESS"` returns the `addr_` id in its response. Store it — you need it > to update the address later. (Customers and shipments don't have this problem; their create > responses do include nested address ids.) ## Vendors A **vendor** is a payable party that isn't a hauling carrier — a lumper service, a factor, a utility, a non-freight supplier. `POST /api/rest/vendors` creates one: ```bash theme={null} curl -X POST https://api.upwell.com/api/rest/vendors \ -H "Authorization: YOUR_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "input": { "name": "Acme Lumper Services", "sourceSystem": "YOUR_TMS", "sourceSystemId": "VEND-2003" } }' ``` | Field | Required | Notes | | - | - | - | | `name` | Yes | Vendor display name. | | `sourceSystem` / `sourceSystemId` | **Yes** | Both are `NOT NULL` on this table (unlike customers/carriers, where the pair is only recommended). | Updates: `PUT /api/rest/vendors/{id}`. > [!WARNING] > > `DELETE /api/rest/vendors/{id}` is a **permanent hard delete** — vendors have no soft-delete column, unlike most other Upwell resources. It will also **fail outright** if any bill still references the vendor (`bills.vendor_id` is a restrict-on-delete foreign key) — reassign or remove those bills first. ## Keeping records in sync Most TMS integrations run a two-phase sync: 1. **Initial load** — push all active customers, carriers, and shipments via `POST`. Store the returned Upwell IDs in your system. 2. **Ongoing sync** — when a record changes in your TMS, push the update via `PUT`. You can update by Upwell ID (`PUT /api/rest//{id}`) or by source-system key (`PUT /api/rest/` with `sourceSystem` + `sourceSystemId` in the body). > [accordion] Webhook-push (real-time) > > Your TMS fires a webhook on every create/update, and your integration pushes the change to Upwell immediately. This is the lowest-latency option — records are usually in Upwell within seconds. Best for TMS platforms with outbound webhook support. > [accordion] Scheduled batch (periodic) > > A cron job queries your TMS for records changed since the last run and pushes them to Upwell in bulk. Simpler to build; latency depends on your schedule (typically 5–15 minutes). Best for TMS platforms with a "changed since" query API. > [accordion] API-pull (Upwell-initiated) > > Upwell calls your TMS's API on a schedule to pull new/changed records. Requires your TMS to expose a query API. Contact Upwell to set this up. ### Bulk create For the initial load, `bulk-customers`, `bulk-carriers`, and `bulk-bills` let you create many records in one request instead of looping individual `POST` calls. Each accepts `{ "inputs": [...] }` (plural — see [Wrapping POST payloads](/conventions/money-and-payloads#wrapping-post-payloads)): ```bash theme={null} curl -X POST https://api.upwell.com/api/rest/bulk-customers \ -H "Authorization: YOUR_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "inputs": [ { "name": "Acme Manufacturing", "sourceSystem": "YOUR_TMS", "sourceSystemId": "CUST-10042" }, { "name": "Beta Logistics", "sourceSystem": "YOUR_TMS", "sourceSystemId": "CUST-10043" } ] }' ``` > [!WARNING] > > Bulk endpoints don't all share the same duplicate-handling behavior as their singular counterparts: > > * **`bulk-carriers`** has **no upsert at all** — unlike the singular `POST /api/rest/carriers` (which silently no-ops on a duplicate key), a duplicate `(sourceSystem, sourceSystemId)` anywhere in a `bulk-carriers` batch fails the **entire batch**. > * **`bulk-bills`** does upsert on the same key as the singular endpoint, matching its behavior. > * Neither bulk endpoint reports partial success — a batch either fully succeeds or fully fails. ## What's next Once foundation entities are in Upwell, you can build on top of them: > [card] [Customer invoices (AR)](/api-guides/customer-invoices) > > Create customer invoices tied to shipments. > [card] [Carrier invoice submission (AP)](/api-guides/carrier-invoice-submission) > > Submit carrier invoices for audit and matching. > [card] [Shipment documents](/api-guides/shipment-documents) > > Attach BOLs, PODs, and other documents to shipments. > [card] [Customer payments](/api-guides/customer-payments) > > Record remittances from customers. # Webhook event catalog Source: https://docs.upwell.com/api-guides/webhook-events Every webhook trigger you can subscribe to in the Upwell dashboard, grouped by resource — the companion reference to the outbound webhooks guide. # Webhook event catalog This is the reference list of the webhook triggers you can **subscribe to in the Upwell dashboard**. For **how** webhooks work — subscribing, the delivery envelope, auth, retries, and a receiver example — see [Outbound webhooks](/api-guides/webhooks). ## Trigger naming Triggers are dot-delimited strings. Most take one of these shapes: ``` {action}.{resource} {action}.{resource}.status.{STATUS} {action}.{resource}.{event} ``` * `action` is `create`, `update`, or `delete`. * `.status.{STATUS}` fires only on a specific status transition. * `.{event}` is a named sub-event rather than a status — e.g. `update.carrier_invoice.shipment_updated`, which fires when the invoice is matched to a shipment. Each change produces **at most one** trigger — the most specific one that applies — and a subscription receives an event **only if it subscribed to that exact trigger string**. A generic `update.{resource}` is *not* also delivered alongside a `.status.{STATUS}` or `.{event}` trigger; `update.{resource}` fires for a change that is neither a tracked status transition nor a named sub-event. So to catch more than one case, subscribe to each trigger you care about. Match the string verbatim, including case — most status suffixes are upper-case (`APPROVED`, `SENT`), but the remittance ones are lower-case. The tables also identify dashboard choices that currently produce no delivery. ## Invoice (customer invoice) triggers See the [invoice row example](/api-reference/webhooks/handles-invoice-events), [sent example](/api-reference/webhooks/handle-invoice-status-sent-events), and [portal exception example](/api-reference/webhooks/handle-invoice-status-portal-exception-events). | Trigger | Fires when | | - | - | | `create.invoice` | A new invoice record is created. | | `update.invoice` | An invoice record is updated (a change that is neither a tracked status transition nor a named sub-event). | | `delete.invoice` | An invoice record is deleted. | | `update.invoice.status.SENT` | A customer invoice is sent. | | `update.invoice.status.PORTAL_EXCEPTION` | A customer invoice has a portal exception. | | `update.invoice.status.APPROVED` † | A customer invoice is approved. Read the invoice directly from `payload`, including `payload.id` and `payload.status`. **Support-enabled only** — not in the dashboard form. | ## Carrier invoice triggers See the [row example](/api-reference/webhooks/handle-carrier-invoice-events), [approval example](/api-reference/webhooks/handle-carrier-invoice-status-approved-events), and [exception example](/api-reference/webhooks/handle-carrier-invoice-exceptions). Shipment-link examples cover [creation](/api-reference/webhooks/handle-carrier-invoice-creation-with-shipment-information) and [updates](/api-reference/webhooks/handle-a-changed-carrier-invoice-shipment-link). | Trigger | Fires when | | - | - | | `create.carrier_invoice` | Generic creation. Inserts carrying the `shipment_id` column select `create.carrier_invoice.shipment_updated`, including when its value is null. | | `update.carrier_invoice` | A carrier invoice record is updated (a change that is neither a tracked status transition nor a named sub-event). | | `delete.carrier_invoice` | Selectable. Hard deletion removes the invoice needed for shipment enrichment, so a hard-deleted row does not produce a POST. | | `create.carrier_invoice.shipment_updated` / `update.carrier_invoice.shipment_updated` | On insert, `shipment_id` can be null. On update, the shipment link changed or was cleared. Read `payload.new.shipment_id` to check the link. An update that also enters `APPROVED` sends `payload.carrierInvoice`. | | `update.carrier_invoice.status.APPROVED` | Read the current invoice from `payload.carrierInvoice`. A first payment can also record approval. Not sent when the approval completes an outbound approval request; that approval is announced once, by `create.carrier_invoice_approval_request`. Also not sent when Upwell records an approval that Turvo already has (see [Responding to an approval request](/api-guides/carrier-invoice-approval)). | | `update.carrier_invoice.status.EXCEPTION` | The invoice entered `EXCEPTION`. Read the row snapshots in `payload.old` and `payload.new`. | > [!NOTE] > > To distinguish *ingestion done* from the later *review lifecycle*, see the guidance in [Knowing when a carrier invoice is processed](/api-guides/carrier-invoice-status). ## Carrier document triggers | Trigger | Fires when | | - | - | | `create.carrier_document` † | A document is attached to a carrier invoice with a shipment number. Read `payload.new.carrier_invoice`. **Support-enabled only.** | | `update.carrier_document` † | A carrier-invoice document is updated or reclassified and has a shipment number. Compare the old and new association rows. **Support-enabled only.** | | `delete.carrier_document` † | A hard delete supplies no new row for the shipment-number check, so the dispatcher skips it. **Support-enabled only.** | ## Carrier-invoice approval request triggers | Trigger | Fires when | | - | - | | `create.carrier_invoice_approval_request` | An approval request is opened for a carrier invoice. See [Responding to an approval request](/api-guides/carrier-invoice-approval). | ## Shipment document triggers See the [shipment document examples](/api-reference/webhooks/handle-shipment-documents-events). | Trigger | Fires when | | - | - | | `create.shipment_document` | A shipment file association is created. Read the shipment, signed file URL and documents in `payload.new`. | | `update.shipment_document` | A shipment file association is updated. Each populated snapshot includes the shipment, signed file URL and documents. | | `delete.shipment_document` | Selectable. When the association is gone at dispatch, the shipment document lookup finds no row and skips the POST. | ## Customer payment triggers See the [payment row example](/api-reference/webhooks/handle-customer-payment-events). | Trigger | Fires when | | - | - | | `create.customer_payment` | A new customer payment record is created. | | `update.customer_payment` | A customer payment record is updated. | | `delete.customer_payment` | A customer payment record is deleted. | ## Breakthrough Fuel triggers | Trigger | Fires when | | - | - | | `create.btf_batch` | A batch is created without processing errors. The payload is an array of surcharge records and can be empty. | ## Exception triggers | Trigger | Fires when | | - | - | | `create.exception` | A new exception is raised. Read the dispatch-time lookup at `payload.exception`. | | `update.exception.status.RESOLVED` | An exception is resolved. Read `payload.exception` for the current record. | ## Remittance triggers See the [remittance examples](/api-reference/webhooks/handles-remittance-events). | Trigger | Fires when | | - | - | | `create.remittance` | A new remittance is created. These remittance deliveries include the dispatch-time lookup at `payload.remittance`, with its line items. | | `update.remittance` | A remittance is updated. | | `delete.remittance` | Selectable. A hard delete supplies only the old row. The remittance mapper requires the new row and cannot deliver that deletion. | | `update.remittance.status.pending` | A remittance moved to `pending`. | | `update.remittance.status.succeeded` | A remittance moved to `succeeded`. | | `update.remittance.status.sync_error` | A remittance hit a sync error. | | `create.remittance_line_item` | Selectable in the dashboard. The dispatcher currently emits no line-item event. | | `update.remittance_line_item` | Selectable in the dashboard. The dispatcher currently emits no line-item event. | | `delete.remittance_line_item` | Selectable in the dashboard. The dispatcher currently emits no line-item event. | ## There are no foundation-entity triggers Webhooks fire on **transactional** records — invoices, carrier invoices, payments, documents, exceptions, remittances, approval requests, and BTF batches. They do **not** fire on the foundation entities you sync in: | Resource | Change events? | | - | - | | Customer | **None** — no `create.customer` / `update.customer` / `delete.customer` | | Carrier | **None** | | Company | **None** | | Address | **None** | | Shipment | **None** for the shipment record itself. `create.shipment_document` covers its documents, and `update.carrier_invoice.shipment_updated` fires when a carrier invoice is matched to a shipment. | This matters when you're planning a two-way sync: Upwell will not call you back when one of these records changes. Your TMS remains the system of record for them, and the flow is one-way — you push with `POST`/`PUT`, and you poll (`GET`, or `POST /…/search` where it exists) if you need to read state back. Subscribe to the transactional triggers above for the events Upwell *does* originate. > [!NOTE] > > Triggers marked **†** exist in the dispatcher but are **not** exposed in the dashboard > subscription form for self-service — `create/update/delete.carrier_document` and > `update.invoice.status.APPROVED`. If you need one of those, contact > [support@upwell.com](mailto:support@upwell.com). Everything else in the tables above is > self-service. For payload shapes and delivery details, see > [Outbound webhooks](/api-guides/webhooks). # Outbound webhooks Source: https://docs.upwell.com/api-guides/webhooks Subscribe to Upwell events, authenticate the deliveries, and read the payload envelope. # Outbound webhooks Upwell can POST a JSON event to a URL you host whenever something changes — a carrier invoice is created, matched to a shipment, approved, and so on. Webhooks are the push counterpart to [polling](/api-guides/carrier-invoice-status). ## Subscribing Webhook subscriptions are configured in the **Upwell dashboard** (there's no public REST endpoint to create one). A subscription has: * **`url`** — your HTTPS receiver. * **`triggers`** — the list of event types you want delivered. * **`authSettings`** — how Upwell proves the delivery came from Upwell (see [Authenticating deliveries](#authenticating-deliveries)). * **`retryAttempts`** — how many times Upwell retries a failed delivery (0–10). ## What you can subscribe to The **[webhook event catalog](/api-guides/webhook-events)** is the single source of truth for every trigger string, across all resources — invoices, carrier invoices, documents, payments, exceptions, remittances, and approval requests. Two rules to internalize before subscribing: * **Each change fires at most one trigger — the most specific that applies.** A tracked status transition fires only its `.status.{STATUS}` trigger, *not* also the generic `update.{resource}`; the generic trigger fires for changes that are neither a tracked status nor a named sub-event. Subscribe to every trigger you care about. * A few triggers exist in the dispatcher but are **not self-service** in the dashboard subscription form (they're marked in the catalog) — contact support to enable those. > [!NOTE] > > For carrier invoices specifically: "ingestion done" (matched + audited) is best observed via > `*.shipment_updated` or the generic `update.carrier_invoice`; the `*.status.APPROVED` / > `*.status.EXCEPTION` triggers reflect the later **review lifecycle**. See > [Knowing when a carrier invoice is processed](/api-guides/carrier-invoice-status). ## The delivery envelope Every delivery is a single JSON object. The deprecated `table` field is included for compatibility with existing receivers. Use `trigger` to select the payload format and handler when building or updating an integration. No removal date is scheduled. A future sunset date will be published here and communicated to API consumers before the field is removed. | Field | Description | | - | - | | `trigger` | The trigger string, e.g. `update.carrier_invoice.status.APPROVED`. **Branch on this.** | | `table` | Deprecated source name, e.g. `carrier_invoices`. Still included for existing receivers. Migrate payload parsing and routing to `trigger` before the future announced sunset. | | `operation` | `INSERT`, `UPDATE`, or `DELETE`. | | `resourceId` | The id of the affected resource. **Use it to correlate** (and to fetch a canonical representation via `GET /api/rest/carrier_invoices/{resourceId}`). | | `payload` | The event body — **its shape depends on the trigger** (see below). | | `status` | The **delivery-pipeline** status of this event row, **not** the resource's status. At delivery time it reflects the pre-delivery state (e.g. `PENDING`) — don't branch on it. | | `id` | The delivery's own id. Use it to dedupe retries. | Plus delivery bookkeeping: `tenantId`, `webhookSubscriptionId`, [`createdAt`](/conventions/dates-and-times#created-at), [`updatedAt`](/conventions/dates-and-times#updated-at), [`scheduledAt`](/conventions/dates-and-times#scheduled-at), [`processedAt`](/conventions/dates-and-times#processed-at), `retryOfId` (points to the **original event**, never the previous retry; null on the original event), and `retries` (retry events spawned from this one). ### The `payload` shape varies by trigger **Carrier approval.** Route on `update.carrier_invoice.status.APPROVED`. Upwell looks up the invoice at dispatch time. Read its current status from `payload.carrierInvoice.status`. A first payment that also records approval can already show `PAID` or `PART_PAID`. If the invoice lookup returns no row, `carrierInvoice` is null. These excerpts show selected fields. ```json theme={null} { "trigger": "update.carrier_invoice.status.APPROVED", "operation": "UPDATE", "resourceId": "cari_f68wIfYF", "payload": { "carrierInvoice": { "id": "cari_f68wIfYF", "status": "APPROVED", "invoiceNumber": "INV-99821", "totalAmount": 220000, "currency": "USD", "carrierProNumber": "SH-100015", "issueDate": "2026-06-29", "shipment": { "id": "shi_...", "shipmentNumber": "SH-100015" }, "bill": { "id": "bil_...", "proNumber": "SH-100015", "totalAmount": 914917, "carrier": { "id": "car_...", "name": "Acme Freight" }, "vendor": null } } } } ``` **Carrier exception.** Route on `update.carrier_invoice.status.EXCEPTION`. Read the status transition from the snake_case rows in `payload.old` and `payload.new`. Both include the same shipment looked up when the event was queued, or null. The customer invoice trigger is `update.invoice.status.PORTAL_EXCEPTION`. ```json theme={null} { "trigger": "update.carrier_invoice.status.EXCEPTION", "operation": "UPDATE", "resourceId": "cari_example", "payload": { "old": { "id": "cari_example", "invoice_number": "INV-2000", "status": "UNDER_REVIEW", "shipment": null }, "new": { "id": "cari_example", "invoice_number": "INV-2000", "status": "EXCEPTION", "shipment": null } } } ``` **Shipment link changes.** Compare `payload.old.shipment_id` and `payload.new.shipment_id`. Both rows carry the same shipment lookup. If the same update enters `APPROVED`, the delivery carries `payload.carrierInvoice` instead. ```json theme={null} { "trigger": "update.carrier_invoice.shipment_updated", "operation": "UPDATE", "resourceId": "cari_example", "payload": { "old": { "id": "cari_example", "invoice_number": "INV-2000", "shipment_id": null, "shipment": { "id": "shi_example", "shipment_number": "SH-1000" } }, "new": { "id": "cari_example", "invoice_number": "INV-2000", "shipment_id": "shi_example", "shipment": { "id": "shi_example", "shipment_number": "SH-1000" } } } } ``` ## Authenticating deliveries You choose how Upwell authenticates to your receiver when you create the subscription. Three options: > [accordion] Custom header (recommended) > > You pick a header name and a secret value; Upwell sends that header on every delivery. A common choice is a token header: > > ``` > X-Upwell-Token: > ``` > > Your receiver compares the header against the secret you configured and rejects mismatches. **The header name is your choice** — `X-Upwell-Token` is a convention, not a built-in. > [accordion] Basic auth > > Upwell sends `Authorization: Basic base64(username:password)` using the credentials you configure. > [accordion] None > > No auth header. Rely on URL secrecy / network controls. Not recommended for production. Upwell always sends `Content-Type: application/json` and a `User-Agent` of `UpwellWebhookService/ (https://www.upwell.com)`. > [!NOTE] > > There is **no payload signing (HMAC) or replay protection** — authentication is the static > header or Basic credentials you configure above. Treat the shared secret like a password: > rotate it if it leaks, and always compare it on every delivery. ## Reliability * **What retries:** deliveries that return **`429`** or **`5xx`**, time out, or fail at the network level are retried, up to the subscription's `retryAttempts`. * **What does NOT retry:** any other **`4xx`** response is treated as delivered — it is recorded as successful and never retried. A misconfigured receiver (broken auth check, wrong route) that 4xxes will silently lose every event while Upwell's side shows success. **Alert on your receiver's 4xx rate**, and reconcile with polling (below). * **Retry schedule:** exponential backoff starting at 1 minute and doubling each attempt (1, 2, 4, 8, … minutes). * **`retryAttempts` counts retries *beyond* the first attempt** — `retryAttempts: 3` (the default) means up to 4 total deliveries. The dashboard form accepts 0–10. * Each delivery attempt has a **15-second** timeout. Return a `2xx` quickly; do slow work asynchronously. * Build an **idempotent** receiver: dedupe on the delivery `id`, and treat a non-null `retryOfId` as a redelivery of the original event. * After retries exhaust there is no automatic replay — pair webhooks with a periodic reconciliation poll so a missed delivery never strands a record (see [Knowing when a carrier invoice is processed](/api-guides/carrier-invoice-status)). ## Example receiver ```javascript theme={null} import express from 'express'; const app = express(); app.use(express.json()); app.post('/webhooks/upwell', (req, res) => { if (req.get('X-Upwell-Token') !== process.env.UPWELL_WEBHOOK_TOKEN) return res.status(401).send('unauthorized'); const event = req.body; // the envelope switch (event.trigger) { case 'update.carrier_invoice.status.APPROVED': onApproved(event.resourceId, event.payload.carrierInvoice); break; case 'update.carrier_invoice.status.EXCEPTION': onException(event.resourceId, event.payload.new, event.payload.old); break; case 'update.carrier_invoice.shipment_updated': if (event.payload.new?.shipment_id || event.payload.carrierInvoice?.shipment) onMatched(event.resourceId, event.payload.new ?? event.payload.carrierInvoice); break; } // Acknowledge quickly. Upwell retries 429, 5xx and timeouts. res.json({ ok: true }); }); ``` > [card] [See it end-to-end](/api-guides/carrier-invoice-submission) > > Pair the receiver above with a polling fallback, and walk the full submit → attach → process flow in the [submission guide](/api-guides/carrier-invoice-submission). # Create One Address Source: https://docs.upwell.com/api-reference/addresses/create-one-address /api-reference/openapi.json post /api/rest/addresses Create a new address > [!NOTE] > > Addresses have **no external key** — store the returned `addr_` id; recovering it later means paging the collection. Types are load-bearing: see [Working with addresses](/conventions/addresses). # Delete One Address Source: https://docs.upwell.com/api-reference/addresses/delete-one-address /api-reference/openapi.json delete /api/rest/addresses/{id} Delete an address by ID # Get Many Addresses Source: https://docs.upwell.com/api-reference/addresses/get-many-addresses /api-reference/openapi.json get /api/rest/addresses Query a list of addresses > [!NOTE] > > Default `limit` is **10** — a request with no parameters silently returns only the first ten records. Always pass `limit`/`offset` when syncing or reconciling. See [API conventions](/api-reference/introduction). # Get One Address Source: https://docs.upwell.com/api-reference/addresses/get-one-address /api-reference/openapi.json get /api/rest/addresses/{id} Get an address by ID # Update One Address Source: https://docs.upwell.com/api-reference/addresses/update-one-address /api-reference/openapi.json put /api/rest/addresses/{id} Update an address by ID # Accounts payable API Source: https://docs.upwell.com/api-reference/ap-overview The objects you touch to automate payables — what a carrier invoice, bill, and bill payment each do, and the order they happen in. **Accounts payable is money out**: making sure what you pay your carriers is accurate. Upwell's job is to audit what a carrier *actually billed you* against what your TMS *expected to owe* — and to flag the difference. The endpoint reference is alphabetical, which is deliberately neutral but doesn't tell you what belongs together. This page does. For the receivables side, see [Accounts receivable API](/api-reference/ar-overview). ## Wait for exception evaluation [`exceptionsLastEvaluatedAt`](/conventions/dates-and-times#exceptions-last-evaluated-at) is a read-only, nullable timestamp on customer invoices, carrier invoices, and remittances. A null or absent value means evaluation has not completed. Do not treat an empty exceptions list as permission to approve, release for billing, or send while this value is missing. Require a non-null timestamp **and** the existing exception and approval conditions. A populated timestamp does not mean the record passed its checks. Attempts to approve or send before evaluation finishes are blocked, including exception overrides. Purchase orders are excluded. Historical records may have a documented rollout baseline; later recalculations retain the previous timestamp until completion. External systems such as Transport Pro may synchronize a customer invoice from `DRAFT` to `CREATED` while evaluation is pending. This does not approve sending or mark evaluation complete. See the [customer-invoice readiness guidance](/api-reference/ar-overview#wait-for-exception-evaluation) for filtering drafts when using Upwell to decide release eligibility. Carrier-invoice approval and remittance dispatch still require completed evaluation. ## The lifecycle **1. Your TMS syncs the expected payable** You push a **bill** — what your TMS says you owe a carrier for a shipment. **2. The carrier bills you** A **carrier invoice** arrives, usually by email, or you submit it via API. It starts in `RECEIVED`. **3. Upwell matches and audits** Matching links the carrier invoice to its shipment, carrier, and bill. The audit compares them and raises **exceptions** for any mismatch — a wrong amount, a missing POD, an unexpected accessorial. **4. Someone approves it** A clean invoice can auto-approve; otherwise a reviewer clears the exceptions. If your system owns the decision, Upwell sends you an **approval request** and waits. **5. Payment settles it** A **bill payment** records the money going out, with **carrier payment line items** recording which bills it covered. The invoice reaches `PAID`. ## The objects | Object | What it does | | - | - | | **Bills** | The *expected* payable from your TMS — the baseline the audit compares against. Owed to either a carrier or a vendor, never both. | | **Bill Line Items** | Priced rows on a bill. No list endpoint — read them through the parent bill. | | **Carrier Invoices** | The *received* payable — what the carrier actually sent. The AP entry point. | | **Carrier Invoice Documents** | The invoice scan, BOL, POD, and notice of assignment attached to that invoice. | | **Carrier Invoice Approval Requests** | A pending decision Upwell hands to your system to approve or reject. | | **Bill Payments** | The money going out. Links to bills only through its line items, never directly. | | **Carrier Payment Line Items** | Which bills a payment covered, and for how much. | | **Vendors** | A payable party that isn't a hauling carrier — a lumper service, a factor, a supplier. | | **Vendor Invoices** | Non-freight AP invoices, parsed from a standalone PDF upload. | | **Purchase Orders** | Inbound customer POs, parsed the same way and matched to vendor invoices. | > [!NOTE] > > **Bill vs. carrier invoice** is the distinction people get wrong most often. A **bill** is what your TMS says you *should* owe; a **carrier invoice** is what the carrier *actually* sent. Auditing one against the other is the whole point of AP. See [Core concepts](/concepts/data-model). ## Before any of this works Payables reference records that have to exist first. These aren't AP-specific, so they live in their own guide: * **Carriers** — who gets paid. Sync before bills. * **Shipments** — the load a bill and invoice both point at. * **Documents** — the upload mechanism the invoice scan and POD travel through. See [Syncing foundation entities](/api-guides/syncing-foundation-entities) for all three. ## Guides for this side > [card] [Submit a carrier invoice](/api-guides/carrier-invoice-submission) > > Create the invoice, attach documents, record payment. > [card] [Know when it's processed](/api-guides/carrier-invoice-status) > > Poll or subscribe to learn when matching and the audit finish. > [card] [Respond to an approval request](/api-guides/carrier-invoice-approval) > > Approve or reject from your own system. > [card] [Purchase orders & vendor invoices](/api-guides/purchase-orders-and-vendor-invoices) > > Upload standalone PDFs and read the parsed records. > [card] [Carrier invoice audit](/accounts-payable/carrier-invoice-audit) > > What the audit checks and how exceptions are raised. > [card] [Exceptions](/concepts/exceptions) > > Why an invoice is held and what clears it. # Accounts receivable integration requirements Source: https://docs.upwell.com/api-reference/ar-overview Keep customer invoice balances, statuses, statements, reminders, and online payments accurate by syncing a complete AR lifecycle. **Accounts receivable is money in**: getting your customers paid up, quickly. Upwell's job is to get an accurate invoice out the door and then apply the cash that comes back to the right invoices. Statements, reminders, aging, collections, and hosted payment pages all depend on each invoice's current `balance` and `status`. Syncing invoices without a way to represent payments or an authoritative outstanding balance leaves those features with no reliable way to know what a customer still owes. This page defines the required AR data contract. For the payables side, see [Accounts payable API](/api-reference/ap-overview). ## Wait for exception evaluation [`exceptionsLastEvaluatedAt`](/conventions/dates-and-times#exceptions-last-evaluated-at) is a read-only, nullable timestamp on customer invoices, carrier invoices, and remittances. A null or absent value means evaluation has not completed. Do not treat an empty exceptions list as permission to approve, release for billing, or send while this value is missing. Require a non-null timestamp **and** the existing exception and approval conditions. A populated timestamp does not mean the record passed its checks. Attempts to approve or send before evaluation finishes are blocked, including exception overrides. Purchase orders are excluded. Historical records may have a documented rollout baseline; ordinary later recalculations retain the previous timestamp until completion. A customer invoice that was already evaluated can return to a null timestamp when Upwell invalidates its earlier result. For example, this happens when a connected TMS sends a newer version of a `DRAFT` or `CREATED` invoice that is not yet approved to send. It also happens when a `CANCELLED`, `WRITE_OFF`, or `REFUNDED` invoice is reactivated. Upwell then re-evaluates the invoice and populates the timestamp again. Treat a null timestamp as not ready to send, whether the invoice was never evaluated or is being re-evaluated. A null timestamp is not a hold or an exception, so do not cache an earlier non-null value as permission to send. External systems such as Transport Pro may synchronize a customer invoice from `DRAFT` to `CREATED` even while evaluation is pending. This status change does not approve the invoice for sending or mark its checks complete; Upwell approval and delivery remain blocked until evaluation completes. To use Upwell's checks when deciding which drafts to release for billing, include `"exceptionsLastEvaluatedAt": { "_isNull": false }` in the `where` filter of `POST /api/rest/invoices/search`, alongside the existing blocking-exception filters. The external system owns its release decision. Prebilling supporting-document uploads remain independent. ## The lifecycle **1. A shipment becomes an invoice** You create an **invoice** for a customer and link the **shipments** it bills. New invoices start in `CREATED`. **2. Charges go on it** **Invoice line items** carry the priced rows — line haul, fuel, accessorials — and sum to the invoice total. **3. It clears review** Rules and exceptions can hold an invoice back. Once it's clean it's approved for sending — either automatically or through the **invoice approval** queue. **4. It goes out** Delivery happens by email, customer portal, EDI, or print — or the invoice is rolled into a statement or list bill instead of being sent alone. **5. Cash comes back and gets applied** A **customer payment** records what arrived. Its **line items** say which invoices the money applies to. Upwell recalculates each invoice's balance and moves it to `PART_PAID` or `PAID`. ## Keep outstanding balances accurate Use one of the following balance models. Do not mix a partial payment history with invoice balance snapshots: both systems would be trying to explain the same balance from incomplete data. ### Payment-ledger model (recommended) This is the standard model for API integrations and gives Upwell a complete audit trail: 1. Create each new invoice with `balance` equal to `totalAmount`. 2. Create a [customer payment](/api-guides/customer-payments) when money is received. 3. Create one customer payment line item for every invoice the payment applies to. A payment header without line items does not affect any invoice. 4. Correct or delete the original payment line item when an application is changed, voided, returned, or removed. Changing only a payment or line-item `status` does not unapply its amount. 5. Backfill open invoices **and all payment applications that contribute to their current balances** before enabling statements or reminders. Continue syncing both invoices and applications after cutover. For an API-managed invoice, Upwell derives: ```text theme={null} balance = totalAmount - applied payment line items - credits + debits ``` Upwell then sets the payment state from that result: | Derived balance | Invoice status | | - | - | | Equal to `totalAmount` after a payment is removed | `OPEN` if the invoice was `PAID` or `PART_PAID` | | Greater than `0` and less than `totalAmount` | `PART_PAID` | | `0` or less | `PAID` | > [!WARNING] > > The amount used for a payment application is `totalAmountWithFees` when that field is present; otherwise it is `totalAmount`. Only send `totalAmountWithFees` when it is the principal applied to the invoice. Do not put processing fees or an unapplied gross payment in that field. > [!NOTE] > > Payment and payment-line-item statuses are useful integration metadata, but a line item's amount is what applies cash in the standard model. Create the linked line item only when the application should reduce the invoice balance. ### Authoritative-balance model If your source system cannot provide a complete payment-application ledger, it must provide the current outstanding balance and matching paid state for every invoice instead. Coordinate this model with Upwell before implementation; externally owned balances require integration-specific handling so local payment events and source-system snapshots cannot overwrite one another. At minimum, the source must: * send `balance` in integer cents whenever the amount owed changes; * send a matching `status` (`PART_PAID`, `PAID`, or the appropriate open lifecycle status); * backfill current balances and statuses before statements are enabled; * publish corrections and reversals, not only forward-moving payments; and * provide stable `sourceSystem` and `sourceSystemId` values so updates target the original invoice. > [!WARNING] > > Do not implement the authoritative-balance model by sending occasional invoice snapshots alongside an incomplete set of payment line items. Contact Upwell to agree on ownership and cutover behavior first. ## What statements use Statement generation reads each stored invoice `balance`; it does not independently reconstruct what is owed from the source system. The invoice must also be linked to the correct `customerId` and have the dates and status required by the selected statement filter. The default **All outstanding** filter includes `OPEN`, `APPROVED`, `OVERDUE`, `DISPUTED`, `PART_PAID`, `SENT`, `VIEWED`, and `DELIVERED`. It excludes `PAID`, `CANCELLED`, and draft `CREATED` invoices. Use the **All outstanding including created** preset only when drafts are intentionally statement-ready. Before turning on statements, reconcile at least one full customer account and then the cutover population: * the sum of invoice balances in Upwell equals the source system's customer balance; * every fully paid invoice has a zero balance and `PAID` status; * every partially paid invoice has the expected remaining balance and `PART_PAID` status; * voided or returned applications reopen the invoice when money is owed again; and * invoice [`issueDate`](/conventions/dates-and-times#issue-date) and [`dueDate`](/conventions/dates-and-times#due-date) values produce the expected aging buckets. ## The objects | Object | What it does | | - | - | | **Invoices** | What you bill your customer. An unqualified "invoice" always means this one. | | **Invoice Line Items** | The priced rows. They sum to the invoice total. | | **Invoice Shipments** | Which shipments an invoice bills. Use these endpoints to add or remove one *after* the invoice exists. | | **Invoice Documents** | Supporting paperwork on the invoice. Documents on a linked shipment appear automatically. | | **Invoice Approval** | The queue of invoices waiting for sign-off before delivery. | | **Customer Payments** | An incoming remittance — what arrived, and on which check or ACH. | | **Customer Payment Line Items** | How that money splits across invoices. This is what makes cash application work when one check covers many invoices. | > [!NOTE] > > **Invoice vs. carrier invoice** — same word, opposite directions of money. An **invoice** (`inv_`) is you billing your customer. A **carrier invoice** (`cari_`) is a carrier billing you. Throughout these docs an unqualified "invoice" is always the customer one. See [Core concepts](/concepts/data-model). > [!WARNING] > > Payment line-item amounts **need not** sum to the payment total. A remittance can be partially applied and reconciled later, so don't treat a shortfall as an error. Only the amount actually linked to an invoice reduces that invoice's balance. ## Before any of this works Receivables reference records that have to exist first: * **Customers** — who you bill. Sync before invoices. Note that deleting a customer also deletes their invoices, so deactivate instead. * **Shipments** — the load being billed. * **Documents** — how supporting paperwork gets attached. * **Rules** — optional, but this is how you hold invoices that shouldn't go out yet. See [Syncing foundation entities](/api-guides/syncing-foundation-entities). ## Guides for this side > [card] [Manage customer invoices](/api-guides/customer-invoices) > > Create invoices, add line items, attach documents, link shipments. > [card] [Record customer payments](/api-guides/customer-payments) > > Create a remittance with its line items and reconcile it. > [card] [Receivables management](/accounts-receivable/receivables) > > The AR dashboard, aging, and collections workflow. > [card] [Remittances](/accounts-receivable/remittances) > > How remittance data arrives and gets matched. > [card] [Payment reminders](/accounts-receivable/reminders) > > Automated follow-up on overdue invoices. > [card] [Online payments](/accounts-receivable/online-payments) > > Let customers pay from the portal. # Create One Bill Line Item Source: https://docs.upwell.com/api-reference/bill-line-items/create-one-bill-line-item /api-reference/openapi.json post /api/rest/bill_line_items Create a new bill line item # Delete One Bill Line Item Source: https://docs.upwell.com/api-reference/bill-line-items/delete-one-bill-line-item /api-reference/openapi.json delete /api/rest/bill_line_items/{id} Delete an bill line item by ID # Update One Bill Line Item Source: https://docs.upwell.com/api-reference/bill-line-items/update-one-bill-line-item /api-reference/openapi.json patch /api/rest/bill_line_items/{id} Update an bill line item by ID # Create bill payment Source: https://docs.upwell.com/api-reference/bill-payments/create-bill-payment /api-reference/openapi.json post /api/rest/bill-payments Create a new bill payment record. # Delete bill payment Source: https://docs.upwell.com/api-reference/bill-payments/delete-bill-payment /api-reference/openapi.json delete /api/rest/bill-payments/{id} Delete a bill payment by its ID. # Get bill payment Source: https://docs.upwell.com/api-reference/bill-payments/get-bill-payment /api-reference/openapi.json get /api/rest/bill-payments/{id} Retrieve a single bill payment by its ID. # List bill payments Source: https://docs.upwell.com/api-reference/bill-payments/list-bill-payments /api-reference/openapi.json get /api/rest/bill-payments Retrieve a paginated list of bill payments with optional filtering and sorting. > [!NOTE] > > Default `limit` is **10** — a request with no parameters silently returns only the first ten records. Always pass `limit`/`offset` when syncing or reconciling. See [API conventions](/api-reference/introduction). # Search bill payments Source: https://docs.upwell.com/api-reference/bill-payments/search-bill-payments /api-reference/openapi.json post /api/rest/bill-payments/search Search for bill payments by source system and source system ID. # Update bill payment Source: https://docs.upwell.com/api-reference/bill-payments/update-bill-payment /api-reference/openapi.json put /api/rest/bill-payments/{id} Update an existing bill payment by its ID. # Create Many Bills Source: https://docs.upwell.com/api-reference/bills/create-many-bills /api-reference/openapi.json post /api/rest/bulk-bills Create multiple bills at once > [!NOTE] > > Upserts on the external key like the singular endpoint; the batch is all-or-nothing. Bodies use the `{ "inputs": [...] }` wrapper. See [Syncing foundation entities](/api-guides/syncing-foundation-entities). # Create One Bill Source: https://docs.upwell.com/api-reference/bills/create-one-bill /api-reference/openapi.json post /api/rest/bills Create a new bill # Delete One Bill Source: https://docs.upwell.com/api-reference/bills/delete-one-bill /api-reference/openapi.json delete /api/rest/bills/{id} Delete a bill by ID # Get Many Bills Source: https://docs.upwell.com/api-reference/bills/get-many-bills /api-reference/openapi.json get /api/rest/bills Query a list of bills > [!NOTE] > > Default `limit` is **10** — a request with no parameters silently returns only the first ten records. Always pass `limit`/`offset` when syncing or reconciling. See [API conventions](/api-reference/introduction). # Get One Bill Source: https://docs.upwell.com/api-reference/bills/get-one-bill /api-reference/openapi.json get /api/rest/bills/{id} Get a bill by ID # Search Bills Source: https://docs.upwell.com/api-reference/bills/search-bills /api-reference/openapi.json post /api/rest/bills/search Advanced search for bills with complex filtering criteria # Update One Bill Source: https://docs.upwell.com/api-reference/bills/update-one-bill /api-reference/openapi.json put /api/rest/bills/{id} Update a bill by ID # Get carrier invoice approval request Source: https://docs.upwell.com/api-reference/carrier-invoice-approval-requests/get-carrier-invoice-approval-request /api-reference/openapi.json get /api/rest/carrier_invoice_approval_requests/{id} Retrieve a single carrier invoice approval request by its ID. # List carrier invoice approval requests Source: https://docs.upwell.com/api-reference/carrier-invoice-approval-requests/list-carrier-invoice-approval-requests /api-reference/openapi.json get /api/rest/carrier_invoice_approval_requests Retrieve a paginated list of carrier invoice approval requests with optional filtering and sorting. > [!NOTE] > > Default `limit` is **10** — a request with no parameters silently returns only the first ten records. Always pass `limit`/`offset` when syncing or reconciling. See [API conventions](/api-reference/introduction). # Update Carrier Invoice Approval Request Source: https://docs.upwell.com/api-reference/carrier-invoice-approval-requests/update-carrier-invoice-approval-request /api-reference/openapi.json patch /api/rest/carrier_invoice_approval_requests/{id} Update a carrier invoice approval request status and response payload # Create Carrier Invoice Document Source: https://docs.upwell.com/api-reference/carrier-invoice-documents/create-carrier-invoice-document /api-reference/openapi.json post /api/rest/carrier_invoices/{carrierInvoiceId}/documents Create a new carrier invoice document # Delete Carrier Invoice Document Source: https://docs.upwell.com/api-reference/carrier-invoice-documents/delete-carrier-invoice-document /api-reference/openapi.json delete /api/rest/carrier_invoices/{carrierInvoiceId}/documents/{id} Delete a carrier invoice document by ID # Get Many Carrier Invoice Documents Source: https://docs.upwell.com/api-reference/carrier-invoice-documents/get-many-carrier-invoice-documents /api-reference/openapi.json get /api/rest/carrier_invoices/{carrierInvoiceId}/documents Query a list of carrier invoice documents # Approve One Carrier Invoice Source: https://docs.upwell.com/api-reference/carrier-invoices/approve-one-carrier-invoice /api-reference/openapi.json post /api/rest/carrier_invoices/{carrierInvoiceId}/approve Approve a carrier invoice by ID > [!WARNING] > > Business failures return **inside a `200` body** (`error.code`: `OPEN_EXCEPTIONS`, `INVOICE_NOT_FOUND`) — check the nested `error`, not just the HTTP status. See [Error handling](/api-reference/error-codes). # Create Many Carrier Invoices Source: https://docs.upwell.com/api-reference/carrier-invoices/create-many-carrier-invoices /api-reference/openapi.json post /api/rest/bulk-carrier-invoices Create multiple carrier invoices at once > [!NOTE] > > Bulk bodies use `{ "inputs": [ ... ] }` (plural) — not the singular `input` wrapper. See [Money & payloads](/conventions/money-and-payloads#wrapping-post-payloads). # Create One Carrier Invoice Source: https://docs.upwell.com/api-reference/carrier-invoices/create-one-carrier-invoice /api-reference/openapi.json post /api/rest/carrier_invoices Create a new carrier invoice > [!WARNING] > > Duplicates are handled **asynchronously**: a re-`POST` succeeds with a **new id**, and a background pass later soft-deletes the newer row (key: tenant + `sourceSystemId`). Don't trust the id from a retried `POST` — see [Re-submitting](/api-guides/carrier-invoice-submission#re-submitting). # Delete One Carrier Invoice Source: https://docs.upwell.com/api-reference/carrier-invoices/delete-one-carrier-invoice /api-reference/openapi.json delete /api/rest/carrier_invoices/{id} Delete a carrier invoice by ID # Get Many Carrier Invoices Source: https://docs.upwell.com/api-reference/carrier-invoices/get-many-carrier-invoices /api-reference/openapi.json get /api/rest/carrier_invoices Query a list of carrier invoices > [!NOTE] > > Default `limit` is **10** — a request with no parameters silently returns only the first ten records. Always pass `limit`/`offset` when syncing or reconciling. See [API conventions](/api-reference/introduction). # Get One Carrier Invoice Source: https://docs.upwell.com/api-reference/carrier-invoices/get-one-carrier-invoice /api-reference/openapi.json get /api/rest/carrier_invoices/{id} Get a carrier invoice by ID # Update One Carrier Invoice Source: https://docs.upwell.com/api-reference/carrier-invoices/update-one-carrier-invoice /api-reference/openapi.json put /api/rest/carrier_invoices/{id} Update a carrier invoice by ID # Create Many Carrier Payment Line Items Source: https://docs.upwell.com/api-reference/carrier-payment-line-items/create-many-carrier-payment-line-items /api-reference/openapi.json post /api/rest/bulk-carrier-payment-line-items Create multiple carrier payment line items at once > [!NOTE] > > Bulk bodies use `{ "inputs": [ ... ] }` (plural) — not the singular `input` wrapper. See [Money & payloads](/conventions/money-and-payloads#wrapping-post-payloads). # Create One Carrier Payment Line Item Source: https://docs.upwell.com/api-reference/carrier-payment-line-items/create-one-carrier-payment-line-item /api-reference/openapi.json post /api/rest/carrier_payment_line_items Create a new carrier payment line item # Delete One Carrier Payment Line Item Source: https://docs.upwell.com/api-reference/carrier-payment-line-items/delete-one-carrier-payment-line-item /api-reference/openapi.json delete /api/rest/carrier_payment_line_items/{id} Delete a carrier payment line item by ID # Get Many Carrier Payment Line Items Source: https://docs.upwell.com/api-reference/carrier-payment-line-items/get-many-carrier-payment-line-items /api-reference/openapi.json get /api/rest/carrier_payment_line_items Query a list of carrier payment line items > [!NOTE] > > Default `limit` is **10** — a request with no parameters silently returns only the first ten records. Always pass `limit`/`offset` when syncing or reconciling. See [API conventions](/api-reference/introduction). # Get One Carrier Payment Line Item Source: https://docs.upwell.com/api-reference/carrier-payment-line-items/get-one-carrier-payment-line-item /api-reference/openapi.json get /api/rest/carrier_payment_line_items/{id} Get a carrier payment line item by ID # Update One Carrier Payment Line Item Source: https://docs.upwell.com/api-reference/carrier-payment-line-items/update-one-carrier-payment-line-item /api-reference/openapi.json put /api/rest/carrier_payment_line_items/{id} Update a carrier payment line item by ID # Create Many Carriers Source: https://docs.upwell.com/api-reference/carriers/create-many-carriers /api-reference/openapi.json post /api/rest/bulk-carriers Create multiple carriers at once > [!WARNING] > > **No upsert**: a duplicate external key anywhere in the batch fails the **entire batch**, and there is no partial success. See [Syncing foundation entities](/api-guides/syncing-foundation-entities). # Create One Carrier Source: https://docs.upwell.com/api-reference/carriers/create-one-carrier /api-reference/openapi.json post /api/rest/carriers Create a new carrier > [!WARNING] > > A duplicate `(sourceSystem, sourceSystemId)`**silently no-ops** — it does not update any field you send. To change an existing carrier, use `PUT`. See [Idempotency & retries](/conventions/idempotency-and-retries). # Delete One Carrier Source: https://docs.upwell.com/api-reference/carriers/delete-one-carrier /api-reference/openapi.json delete /api/rest/carriers/{id} Delete a carrier by ID > [!NOTE] > > **Hard delete**; carriers have no archive state. See [Deleting and archiving](/conventions/deletes-and-archiving). # Delete One Carrier By Source System Id Source: https://docs.upwell.com/api-reference/carriers/delete-one-carrier-by-source-system-id /api-reference/openapi.json delete /api/rest/carriers Delete a carrier by source system id > [!NOTE] > > **Hard delete**; carriers have no archive state. See [Deleting and archiving](/conventions/deletes-and-archiving). # Get Many Carriers Source: https://docs.upwell.com/api-reference/carriers/get-many-carriers /api-reference/openapi.json get /api/rest/carriers Query a list of carriers > [!NOTE] > > Default `limit` is **10** — a request with no parameters silently returns only the first ten records. Always pass `limit`/`offset` when syncing or reconciling. See [API conventions](/api-reference/introduction). # Get One Carrier Source: https://docs.upwell.com/api-reference/carriers/get-one-carrier /api-reference/openapi.json get /api/rest/carriers/{id} Get a carrier by ID # Search Carriers Source: https://docs.upwell.com/api-reference/carriers/search-carriers /api-reference/openapi.json post /api/rest/carriers/search Search for carriers based on specified criteria # Update One Carrier Source: https://docs.upwell.com/api-reference/carriers/update-one-carrier /api-reference/openapi.json put /api/rest/carriers/{id} Update a carrier by ID # Update One Carrier By Source System Id Source: https://docs.upwell.com/api-reference/carriers/update-one-carrier-by-source-system-id /api-reference/openapi.json put /api/rest/carriers Update a carrier by source system id > [!NOTE] > > Updates by **external key**: send `sourceSystem` + `sourceSystemId` inside `input` to update without the Upwell id. See [Idempotency & retries](/conventions/idempotency-and-retries). # Create company Source: https://docs.upwell.com/api-reference/companies/create-company /api-reference/openapi.json post /api/rest/companies Create a new company record. # Delete company Source: https://docs.upwell.com/api-reference/companies/delete-company /api-reference/openapi.json delete /api/rest/companies/{id} Delete a company by its ID. > [!NOTE] > > **Soft delete** — the record is retained with `deletedAt`, its name is freed (unique case-insensitively), and its addresses are **not** removed. See [Deleting and archiving](/conventions/deletes-and-archiving). # Get company Source: https://docs.upwell.com/api-reference/companies/get-company /api-reference/openapi.json get /api/rest/companies/{id} Retrieve a single company by its ID. # List companies Source: https://docs.upwell.com/api-reference/companies/list-companies /api-reference/openapi.json get /api/rest/companies Retrieve a paginated list of companies with optional filtering and sorting. > [!NOTE] > > Default `limit` is **10** — a request with no parameters silently returns only the first ten records. Always pass `limit`/`offset` when syncing or reconciling. See [API conventions](/api-reference/introduction). # Update company Source: https://docs.upwell.com/api-reference/companies/update-company /api-reference/openapi.json put /api/rest/companies/{id} Update an existing company by its ID. # Create a shipment line item Source: https://docs.upwell.com/api-reference/create-a-shipment-line-item /api-reference/openapi.json post /api/rest/shipment_line_items Add a commodity line to a shipment. Each line carries the freight detail for one commodity: description, packaging and handling units, weight, dimensions, NMFC number and class, and the hazmat flag. `shipmentId` is required and must reference a shipment in your organization. # Create Many Customer Payment Line Items Source: https://docs.upwell.com/api-reference/customer-payment-line-items/create-many-customer-payment-line-items /api-reference/openapi.json post /api/rest/bulk-customer-payment-line-items Create multiple customer payment line items at once > [!NOTE] > > Bulk bodies use `{ "inputs": [ ... ] }` (plural) — not the singular `input` wrapper. See [Money & payloads](/conventions/money-and-payloads#wrapping-post-payloads). # Create One Customer Payment Line Item Source: https://docs.upwell.com/api-reference/customer-payment-line-items/create-one-customer-payment-line-item /api-reference/openapi.json post /api/rest/customer_payment_line_items Create a new customer payment line item # Delete One Customer Payment Line Item Source: https://docs.upwell.com/api-reference/customer-payment-line-items/delete-one-customer-payment-line-item /api-reference/openapi.json delete /api/rest/customer_payment_line_items/{id} Delete a specific customer payment line item # Get Many Customer Payment Line Items Source: https://docs.upwell.com/api-reference/customer-payment-line-items/get-many-customer-payment-line-items /api-reference/openapi.json get /api/rest/customer_payment_line_items Retrieve a list of customer payment line items > [!NOTE] > > Default `limit` is **10** — a request with no parameters silently returns only the first ten records. Always pass `limit`/`offset` when syncing or reconciling. See [API conventions](/api-reference/introduction). # Get One Customer Payment Line Item Source: https://docs.upwell.com/api-reference/customer-payment-line-items/get-one-customer-payment-line-item /api-reference/openapi.json get /api/rest/customer_payment_line_items/{id} Retrieve details of a specific customer payment line item # Search Customer Payment Line Items Source: https://docs.upwell.com/api-reference/customer-payment-line-items/search-customer-payment-line-items /api-reference/openapi.json post /api/rest/customer_payment_line_items/search Search for customer payment line items based on specified criteria # Update One Customer Payment Line Item Source: https://docs.upwell.com/api-reference/customer-payment-line-items/update-one-customer-payment-line-item /api-reference/openapi.json put /api/rest/customer_payment_line_items/{id} Update details of a specific customer payment line item # Create Many Customer Payments Source: https://docs.upwell.com/api-reference/customer-payments/create-many-customer-payments /api-reference/openapi.json post /api/rest/bulk-customer-payments Create multiple customer payments at once > [!NOTE] > > Bulk bodies use `{ "inputs": [ ... ] }` (plural) — not the singular `input` wrapper. See [Money & payloads](/conventions/money-and-payloads#wrapping-post-payloads). # Create One Customer Payment Source: https://docs.upwell.com/api-reference/customer-payments/create-one-customer-payment /api-reference/openapi.json post /api/rest/customer_payments Create a new customer payment # Delete One Customer Payment Source: https://docs.upwell.com/api-reference/customer-payments/delete-one-customer-payment /api-reference/openapi.json delete /api/rest/customer_payments/{id} Delete a specific customer payment # Get Many Customer Payments Source: https://docs.upwell.com/api-reference/customer-payments/get-many-customer-payments /api-reference/openapi.json get /api/rest/customer_payments Retrieve a list of customer payments > [!NOTE] > > Default `limit` is **10** — a request with no parameters silently returns only the first ten records. Always pass `limit`/`offset` when syncing or reconciling. See [API conventions](/api-reference/introduction). # Get One Customer Payment Source: https://docs.upwell.com/api-reference/customer-payments/get-one-customer-payment /api-reference/openapi.json get /api/rest/customer_payments/{id} Retrieve details of a specific customer payment # Search Customer Payments Source: https://docs.upwell.com/api-reference/customer-payments/search-customer-payments /api-reference/openapi.json post /api/rest/customer_payments/search Search for customer payments based on specified criteria # Update One Customer Payment Source: https://docs.upwell.com/api-reference/customer-payments/update-one-customer-payment /api-reference/openapi.json put /api/rest/customer_payments/{id} Update details of a specific customer payment # Create Many Customers Source: https://docs.upwell.com/api-reference/customers/create-many-customers /api-reference/openapi.json post /api/rest/bulk-customers Create multiple customers at once > [!NOTE] > > Bulk bodies use `{ "inputs": [ ... ] }` (plural) — not the singular `input` wrapper. See [Money & payloads](/conventions/money-and-payloads#wrapping-post-payloads). # Create One Customer Source: https://docs.upwell.com/api-reference/customers/create-one-customer /api-reference/openapi.json post /api/rest/customers Create One Customer. Existing native customer fields, nested create inputs, filters and role permissions remain validated by Hasura. Recipient arrays use the existing delivery settings; entries are normalized, deduplicated and validated. Do not combine a convenience array with its native deliveryMethods, statementSchedules or reminderSettings representation. Unsupported, malformed, absent/ambiguous/foreign statement targets reject before customer or customer-rule writes. Runtime transport/database failures across mutation stages may follow committed changes: GET the customer, then retry the remaining changes with PUT. A post-insert invoice-recipient error identifies the stored customer ID; do not retry POST blindly. POST is for first sync; an existing source identity returns HTTP 400. Read the stored customer and use PUT for updates. Validation failures return HTTP 400. > [!WARNING] > > **Not retry-safe.** Re-`POST`ing an existing `(sourceSystem, sourceSystemId)` pair returns `400 Uniqueness violation` — create once, then update with `PUT`. See [Idempotency & retries](/conventions/idempotency-and-retries). # Delete One Customer Source: https://docs.upwell.com/api-reference/customers/delete-one-customer /api-reference/openapi.json delete /api/rest/customers/{id} Delete a customer by ID > [!WARNING] > > **Hard delete** — the customer's addresses are deleted with it (and per the [AR overview](/api-reference/ar-overview), its invoices too). Prefer the reversible soft delete (`PUT` with `deletedAt`). See [Deleting and archiving](/conventions/deletes-and-archiving). # Delete One Customer By Source System Id Source: https://docs.upwell.com/api-reference/customers/delete-one-customer-by-source-system-id /api-reference/openapi.json delete /api/rest/customers Delete a customer by source system id > [!WARNING] > > **Hard delete** — the customer's addresses are deleted with it (and per the [AR overview](/api-reference/ar-overview), its invoices too). Prefer the reversible soft delete (`PUT` with `deletedAt`). See [Deleting and archiving](/conventions/deletes-and-archiving). # Get Many Customers Source: https://docs.upwell.com/api-reference/customers/get-many-customers /api-reference/openapi.json get /api/rest/customers Query a list of customers > [!NOTE] > > Default `limit` is **10** — a request with no parameters silently returns only the first ten records. Always pass `limit`/`offset` when syncing or reconciling. See [API conventions](/api-reference/introduction). # Get One Customer Source: https://docs.upwell.com/api-reference/customers/get-one-customer /api-reference/openapi.json get /api/rest/customers/{id} Get a customer by ID # Search Customers Source: https://docs.upwell.com/api-reference/customers/search-customers /api-reference/openapi.json post /api/rest/customers/search Search for customers based on specified criteria # Set customer invoice email recipients by ID Source: https://docs.upwell.com/api-reference/customers/set-customer-invoice-email-recipients-by-id /api-reference/openapi.json put /api/rest/customers/{id}/delivery_recipients Replace the invoice email recipients for the customer with this Upwell id. Same behavior as `PUT /api/rest/customer_delivery_recipients`: full-replacement list, every address validated (any malformed address rejects the request), only the email delivery method is written (created if missing) with other delivery settings preserved, the default routing rule and its primary target are updated or created only when your organization has delivery routing switched on (other targets on that rule keep their recipients), and an empty list requires `input.forceClearRecipients: true`. A rejected request still returns HTTP `200`, with the error message in the body and no `setCustomerEmailDeliveryRecipients` object. # Set customer invoice email recipients by source system id Source: https://docs.upwell.com/api-reference/customers/set-customer-invoice-email-recipients-by-source-system-id /api-reference/openapi.json put /api/rest/customer_delivery_recipients Replace the invoice email recipients for the customer identified by `sourceSystem` + `sourceSystemId` (query parameters). Use this to keep Upwell in sync when the AP contact changes in your TMS. **Behavior:** - `input.emailAddresses` is the **full replacement list**. Each entry may itself be comma- or semicolon-separated (e.g. `"ap@acme.com; cc@acme.com"`). Addresses are trimmed, lowercased and de-duplicated. - Every address is validated; any malformed address rejects the whole request and nothing is written. - Writes the customer's **email** delivery method only. Portal and EDI delivery methods are never modified. If the customer has no email delivery method, one is created. - Only the recipient list changes. Other delivery settings (subject, schedule, delivery mode, conditional recipients) are preserved. - Delivery routing is written only when your organization has delivery routing switched on (Customer Settings → Delivery Routing). Then the customer's default routing rule is updated (or created) with the same recipients, and only the rule's **primary** target is replaced: any additional targets on that rule keep their own recipients and keep receiving routed invoices. The delivery method and the routing rule are written together: if the routing write fails, the delivery method change is rolled back. With routing off, routing rules are not read or changed and `routingRuleId` is `null` in the response. - An empty `emailAddresses` list is rejected unless `input.forceClearRecipients` is `true`. A forced clear clears the email delivery method's recipients only; routing rules require at least one recipient and are left unchanged (`routingRuleId` is `null` in the response), so routed invoice email can keep going to the existing routing targets. - `sourceSystem` matches case-insensitively; `sourceSystemId` must match exactly. The request is rejected if no customer, or more than one, matches. **Errors:** a rejected request still returns HTTP `200`. The body has no `setCustomerEmailDeliveryRecipientsBySourceSystemId` object and instead carries the error message (for example `Invalid email address(es): ...`). Check for the result object before reading it. # Update One Customer Source: https://docs.upwell.com/api-reference/customers/update-one-customer /api-reference/openapi.json put /api/rest/customers/{id} Update One Customer. Existing native customer fields, nested create inputs, filters and role permissions remain validated by Hasura. Recipient arrays use the existing delivery settings; entries are normalized, deduplicated and validated. Do not combine a convenience array with its native deliveryMethods, statementSchedules or reminderSettings representation. Unsupported, malformed, absent/ambiguous/foreign statement targets reject before customer or customer-rule writes. Runtime transport/database failures across mutation stages may follow committed changes: GET the customer, then retry the remaining changes with PUT. A post-insert invoice-recipient error identifies the stored customer ID; do not retry POST blindly. Validation failures return HTTP 400. # Update One Customer By Source System Id Source: https://docs.upwell.com/api-reference/customers/update-one-customer-by-source-system-id /api-reference/openapi.json put /api/rest/customers Update One Customer By Source System Id. Existing native customer fields, nested create inputs, filters and role permissions remain validated by Hasura. Recipient arrays use the existing delivery settings; entries are normalized, deduplicated and validated. Do not combine a convenience array with its native deliveryMethods, statementSchedules or reminderSettings representation. Unsupported, malformed, absent/ambiguous/foreign statement targets reject before customer or customer-rule writes. Runtime transport/database failures across mutation stages may follow committed changes: GET the customer, then retry the remaining changes with PUT. A post-insert invoice-recipient error identifies the stored customer ID; do not retry POST blindly. Validation failures return HTTP 400. > [!NOTE] > > Updates by **external key**: send `sourceSystem` + `sourceSystemId` inside `input` to update without the Upwell id. See [Idempotency & retries](/conventions/idempotency-and-retries). # Delete a shipment line item Source: https://docs.upwell.com/api-reference/delete-a-shipment-line-item /api-reference/openapi.json delete /api/rest/shipment_line_items/{id} Delete a shipment line item by its `sli_` ID. # Create One Document Reference Specification Source: https://docs.upwell.com/api-reference/document-reference-specifications/create-one-document-reference-specification /api-reference/openapi.json post /api/rest/document_reference_specifications Create a new document reference specification # Delete One Document Reference Specification Source: https://docs.upwell.com/api-reference/document-reference-specifications/delete-one-document-reference-specification /api-reference/openapi.json delete /api/rest/document_reference_specifications/{id} Delete a document reference specification by ID # Get Many Document Reference Specifications Source: https://docs.upwell.com/api-reference/document-reference-specifications/get-many-document-reference-specifications /api-reference/openapi.json get /api/rest/document_reference_specifications Query a list of document reference specifications > [!NOTE] > > Default `limit` is **10** — a request with no parameters silently returns only the first ten records. Always pass `limit`/`offset` when syncing or reconciling. See [API conventions](/api-reference/introduction). # Get One Document Reference Specification Source: https://docs.upwell.com/api-reference/document-reference-specifications/get-one-document-reference-specification /api-reference/openapi.json get /api/rest/document_reference_specifications/{id} Get a document reference specification by ID # Update One Document Reference Specification Source: https://docs.upwell.com/api-reference/document-reference-specifications/update-one-document-reference-specification /api-reference/openapi.json put /api/rest/document_reference_specifications/{id} Update a document reference specification by ID # Generate Upload Presigned Url Source: https://docs.upwell.com/api-reference/documents/generate-upload-presigned-url /api-reference/openapi.json post /api/rest/generate-upload-presigned-url Generate a presigned URL for direct S3 file upload. **Integration notes:** - If you provide `sourceSystem` you must also provide `sourceSystemId` (and vice versa) — the `documents_source_system_pair_nullity_chk` constraint requires both or neither. - On the subsequent `PUT` to the returned `uploadUrl`, prefer an `ArrayBuffer` body over `Blob`. Wrapping in a `Blob` with an explicit type can cause some Node fetch implementations to add headers that aren't in `X-Amz-SignedHeaders`, breaking the SigV4 signature. See [Integration patterns](/conventions/documents#document-upload-two-step-presigned-url). > [!NOTE] > > Step 1 of the two-step upload — and the **only path that runs AI classification** for carrier-invoice documents. Re-presigning an already-uploaded `(sourceSystem, sourceSystemId)` fails with `400 DOCUMENT_ALREADY_UPLOADED`. See [Document conventions](/conventions/documents). # Get One Document Source: https://docs.upwell.com/api-reference/documents/get-one-document /api-reference/openapi.json get /api/rest/documents/{id} Get a document by id — the status check for API uploads. `status` of `UPLOAD_CONTENT_REJECTED` means the uploaded bytes failed content verification (not a valid PDF) and the document will never be parsed; re-upload with a new `sourceSystemId` (rejection is terminal: re-presigning the same `sourceSystem`+`sourceSystemId` returns `400 DOCUMENT_ALREADY_UPLOADED`). Multi-document uploads: a purchase-order / vendor-invoice PDF containing several documents of that type is automatically split and each one is parsed individually — `status` becomes `SPLIT_FOR_PROCESSING` while the pieces parse, `PROCESSING_COMPLETED` when every piece has produced its record, and `PROCESSING_FAILED` if any piece permanently fails to parse (records for the pieces that did parse remain available, and a later successful re-parse of the failed piece transitions the document to `PROCESSING_COMPLETED`); the records appear incrementally on the by-document list endpoints. A null/other status with no parsed record yet means parsing is still in progress. # Update One Document Source: https://docs.upwell.com/api-reference/documents/update-one-document /api-reference/openapi.json patch /api/rest/documents/{id} Update a document by ID # Endpoint index Source: https://docs.upwell.com/api-reference/endpoint-index The parts of the API reference no guide walks through, grouped by what they do The guides in **Build** cover the main integration paths end to end. This page indexes what they leave out: endpoint families that exist in the sidebar reference with full request and response schemas, but that no guide walks you through. If you went looking for something and concluded it did not exist, check here before you build around it. Some of these families are also tracked on [Can I…?](/developer-guide/can-i) with caveats — check your row there before committing to one. ## Two different `/search` endpoints Twelve resources expose `POST //search`, and the suffix hides two unrelated contracts. **External-key lookup** — takes `sourceSystem` and `sourceSystemId` as query parameters and answers "which Upwell record corresponds to mine?": `bill-payments` · `purchase-orders` · `shipment_line_items` · `vendor-invoices` · `vendors` **Filtered list** — takes `limit` and `offset` as query parameters plus a filter body, and answers "which records match these criteria?": `bills` · `carriers` · `customer_payment_line_items` · `customer_payments` · `customers` · `invoices` · `shipments` The two forms fail differently when misused. The external-key form's two parameters are **required** — omitting them fails the request. The filtered form's parameters all have defaults (`limit` 10, `offset` 0, empty filter), so a request that omits or mis-names its filter can succeed anyway and return the first page of **unfiltered** rows instead of an error. Pagination on the filtered-list form follows the same `limit`/`offset` rules as any list `GET`, including the default `limit` of 10. ## Invoice queues Two read-only endpoints return customer-invoice work queues, so you can drive your own review UI from them. Both accept `limit` and `offset`, and both return an `invoicesAggregate` count alongside the rows. | Endpoint | Returns | | - | - | | `GET /invoices/queues/ready-for-approval` | Customer invoices in `CREATED` status with `approvedToSend` false and no open or in-progress exceptions. | | `GET /invoices/queues/ready-to-send` | The **Ready To Send** queue: `CREATED` invoices that are not on hold, have a customer, have no open or in-progress exceptions, are not scheduled, are not manual portal work, and are not owned by a customer's auto-send email rule. Invoices that [automatic delivery skips](/api-guides/customer-invoices#invoices-that-automatic-delivery-skips) stay in this queue even when they are scheduled or owned by an auto-send email rule. `approvedToSend` may be either value. Deliberately a **superset** of the in-app Pre-Invoice Audit lane — the app also hides auto-portal invoices its automation will drain; this endpoint keeps them so you never silently lose an actionable invoice. | The two queues are not nested — an invoice can appear in one, both, or neither, so read each one on its own rather than treating the first as a subset of the second. ## Approving | Endpoint | Notes | | - | - | | `POST /carrier_invoices/{carrierInvoiceId}/approve` | Approves one carrier invoice. Accepts an `overrideExceptions` query parameter to approve despite open exceptions. | | `POST /invoices/{id}/approve` | Approves one customer invoice. | These approve **on the Upwell side**. If your own system owns the approve/reject decision, the flow you want is [approval requests](/api-guides/carrier-invoice-approval) instead. For what approval means downstream, and what blocks it, see [Approvals](/concepts/approvals). ## Bill payments The money-out side of accounts payable. Bills themselves are covered in the [AP overview](/api-reference/ap-overview); their payments are not. * `GET /bill-payments` — list, `limit`/`offset` * `POST /bill-payments` — create * `POST /bill-payments/search` — external-key lookup * `GET`, `PUT`, `DELETE /bill-payments/{id}` Bill line items are managed separately: `POST /bill_line_items`, then `PATCH` or `DELETE /bill_line_items/{id}`. ## Shipment structure Shipments are covered in [Syncing foundation entities](/api-guides/syncing-foundation-entities), but two of their child resources are not. **Stops** — `GET`/`POST /stops`, and `GET`/`PUT`/`DELETE /stops/{id}`. Stops carry the pickup and delivery detail for a shipment. **Shipment line items** — the freight detail for one commodity on a shipment: description, packaging and handling units, weight, dimensions, NMFC number and class, and the hazmat flag. Create with `POST /shipment_line_items`, then `GET`, `PATCH`, or `DELETE /shipment_line_items/{id}`. `shipmentId` is required on create. Note that these update with `PATCH`, not `PUT`. ## Payment line items Line items on payments are addressable individually, which is how you correct a single allocation without rewriting the payment: * `GET`, `PUT`, `DELETE /carrier_payment_line_items/{id}` — creating them (`POST /carrier_payment_line_items`, plus the bulk variant) is covered in [Recording carrier payments](/api-guides/carrier-invoice-submission#recording-carrier-payments); the by-id operations are only in the reference. * `GET`, `PUT`, `DELETE /customer_payment_line_items/{id}`, and `POST /customer_payment_line_items/search` for the filtered-list form. Customer payments themselves — `GET`/`PUT`/`DELETE /customer_payments/{id}` and `POST /customer_payments/search` — are walked through in [Managing customer payments](/api-guides/customer-payments). ## Documents The two-step upload flow is covered in [Working with documents](/conventions/documents), listing a carrier invoice's documents in [Knowing when a carrier invoice is processed](/api-guides/carrier-invoice-status), and polling parsed vendor invoices out of an uploaded document in [Purchase orders & vendor invoices](/api-guides/purchase-orders-and-vendor-invoices). What no guide covers is attaching and detaching: | Endpoint | Purpose | | - | - | | `POST /carrier_invoices/{carrierInvoiceId}/documents` | Attach a document to a carrier invoice. | | `DELETE /carrier_invoices/{carrierInvoiceId}/documents/{id}` | Detach a document from a carrier invoice. | | `DELETE /invoices/{invoiceId}/documents/{id}` | Detach a document from a customer invoice. | **Document reference specifications** — `GET`/`POST /document_reference_specifications` and `GET`/`PUT`/`DELETE /document_reference_specifications/{id}` define per-customer name and format patterns used to validate the reference numbers on documents. ## Covered in guides, easy to miss Two families often assumed missing are documented — just not where people look first: * **Unlinking an invoice from a shipment** — `DELETE /invoice_shipments/{invoiceId}/{shipmentId}` removes the association without deleting either record. Worked example in [Customer invoices](/api-guides/customer-invoices). * **Bulk creates** — the family is wider than the two endpoints most people find: `bulk-bills`, `bulk-carriers`, `bulk-customers`, `bulk-carrier-invoices`, `bulk-customer-payments`, `bulk-customer-payment-line-items`, and `bulk-carrier-payment-line-items`. Replay behavior **differs per endpoint** — `bulk-bills` upserts on the external key while `bulk-carriers` fails the entire batch on a duplicate — so read [Bulk create](/api-guides/syncing-foundation-entities#bulk-create) before retrying any of them. > [!NOTE] > > Every endpoint on this page is in the sidebar reference with its full request and > response schema. If something you need is missing from both, ask > [support@upwell.com](mailto:support@upwell.com) rather than assuming it is > unsupported — the reference is generated from the API, so absence there means the > endpoint is genuinely not exposed. # Error handling Source: https://docs.upwell.com/api-reference/error-codes The error shapes the Upwell API actually returns, the HTTP status codes that occur, real error messages and their fixes, and what is safe to retry. ## Error Response Format Upwell API errors are **flat JSON objects** — a message string, sometimes with a machine code alongside it: ```json theme={null} { "error": "Not-NULL violation. null value in column \"shipment_id\" of relation \"shipments\" violates not-null constraint", "code": "constraint-violation" } ``` There is no nested error envelope, no `details` object, and no `timestamp` field. Parse `error` as the human-readable message and treat `code` (when present, e.g. `constraint-violation`, `bad-request`, or `access-denied`) as the machine-readable category. Authentication failures also include a Hasura `path` (normally `$`). ## HTTP Status Codes The codes you will actually encounter: | Status Code | Meaning | What to do | | - | - | - | | `200` | Success — including creates and action endpoints. | Note: action endpoints can report business errors *inside* a 200 body — see below. | | `400` | Malformed or invalid request: missing required field, duplicate external key, wrong wrapper, non-integer money. | Fix the payload — see the [error messages table](#real-error-messages-and-their-fixes). Not retryable as-is. | | `401` | Missing, invalid, or revoked API key. Flat JSON with `error`, `path`, and `code: "access-denied"`. | Check the `Authorization` header and the key's status — see [Authentication](/authentication). | | `404` | The **path** doesn't exist (wrong URL or method-path combination). | A missing *record* on a valid path does **not** 404 — see [Not-found semantics](#not-found-semantics). | | `405` | Method not supported on that path (e.g. `GET` on a `POST`-only endpoint). | Check the endpoint's methods in the reference. | | `500` | Server-side error. | Safe to retry with exponential backoff — but see the [retry rules](#what-is-safe-to-retry) for `POST`. | Two codes conspicuously absent, on purpose: * **`201` is not used** — successful creates return `200`. * **`429` is not used** — see [Rate limiting](#rate-limiting) below. ## Business errors inside a 200 The approval action endpoints report failure in the **response body**, not the HTTP status. A `POST /api/rest/invoices/{id}/approve` that can't proceed still returns `200`: ```json theme={null} { "approveInvoice": { "success": false, "error": { "code": "OPEN_EXCEPTIONS", "message": "Cannot approve invoice with open exceptions" }, "exceptions": [ { "id": "...", "type": "...", "status": "OPEN" } ] } } ``` | Code | Meaning | Fix | | - | - | - | | `OPEN_EXCEPTIONS` | The invoice has unresolved exceptions. | Resolve them, or re-call with `overrideExceptions=true` to force approval. | | `CRITICAL_EXCEPTIONS` | The invoice has an open or in-progress exception with `CRITICAL` severity. The message is `Invoice cannot be approved until critical exceptions are resolved.` and `exceptions` lists only the critical ones. | Resolve the critical exceptions, then retry. `overrideExceptions=true` doesn't bypass them; see [how exceptions affect approval](/concepts/exceptions#how-exceptions-affect-approval). | | `INVOICE_NOT_FOUND` | The invoice doesn't exist or isn't in an approvable state. | Verify the id and the invoice's current `status`. | Always check the nested `success` / `error` fields on action endpoints — checking only the HTTP status will miss these. ## Real error messages and their fixes The messages you'll actually see in `400` responses, and what each one means: | Error contains | Cause | Fix | | - | - | - | | `Uniqueness violation` | Re-`POST` of an existing `(sourceSystem, sourceSystemId)` pair — or a second `CUSTOMER_BILLING` address on one customer. | First sync is `POST`, updates are `PUT` — semantics differ per resource; see [idempotent upserts](/conventions/idempotency-and-retries). | | `Not-NULL violation. null value in column "..."` | A required field with no server default was omitted — the column name is in the message (e.g. `shipment_id`, `balance`). | Send the field; see [required fields without defaults](/conventions/idempotency-and-retries#required-fields-without-server-side-defaults). | | `Check constraint violation. ... documents_source_system_pair_nullity_chk` | A document was given `sourceSystem` without `sourceSystemId` (or vice versa). | Send both or neither. | | `The value ... lies outside the bounds or is not an integer` | Money sent as a float (`2847.5`). | All monetary fields are **integer cents**: `284750`. | | `bad-request: Unexpected variable ...` | Payload not wrapped correctly, or an unknown field name. | Singular creates wrap in `{ "input": { ... } }`; bulk endpoints use `{ "inputs": [ ... ] }` — see [wrapping POST payloads](/conventions/money-and-payloads#wrapping-post-payloads). | | `DOCUMENT_ALREADY_UPLOADED` | Re-requesting a presigned upload URL for a `(sourceSystem, sourceSystemId)` pair that already uploaded successfully. | Fetch the existing document instead; see the [PO & vendor invoice guide](/api-guides/purchase-orders-and-vendor-invoices). | | `invalid_reference: customer_id "..." was merged into customer "..."` | An invoice or shipment was created with, or changed to, a customer that was merged into another one — usually a stale ID kept in your integration's mapping. After a merge, Upwell moves that customer's invoices and shipments to the surviving customer, so updates that resend the old ID are rejected too. | Update your mapping to the customer ID named in the message and retry. Retrying the old ID will keep failing. | | `invalid_reference: customer_id "..." refers to a deleted customer` | The customer was deleted (and not merged into an active customer). Deleted customers are not returned by the API. | Choose an active customer for your mapping and retry. | | `invalid_reference: customer_id "..." is not available in this account` | The customer ID belongs to another organization. | Use a customer ID from your own account. | ## Not-found semantics A lookup by an id that doesn't exist — deleted, mistyped, or belonging to a different organization — is **not** an HTTP error. The single-resource `GET`s declare a nullable resource and return it inside a `200`: ```json theme={null} { "customer": null } ``` List endpoints likewise return empty arrays. So: * **Check the body, not just the status**, when verifying a record exists. * A real `404` means the *path* is wrong, not that the record is missing. * Remember Upwell ids are **prefixed strings** (`cus_…`, `inv_…`, `cari_…`) — a truncated or unprefixed id is a common cause of "exists in the dashboard but null over the API." * To find records by your own keys instead, use the `POST //search` endpoints (see [Integration patterns](/integration-patterns)). ## Rate limiting **The Upwell API does not currently enforce rate limits.** There are no `429` responses, no `X-RateLimit-*` headers, and no `Retry-After` header — don't build handling machinery for them. If you do observe a `429`, it originated from infrastructure on *your* side (a proxy or gateway), not from Upwell. That's a description of today's behavior, not an invitation: keep client concurrency bounded and batch with the `bulk-*` endpoints where they exist. If limits are introduced, they'll be announced in the [changelog](/changelog). ## What is safe to retry 1. **Network failures and `5xx`** — retry with exponential backoff and jitter. 2. **`POST` retries need per-resource care.** A retried create is *not* uniformly safe: customers/shipments/invoices reject duplicates with `400 Uniqueness violation`, carriers silently no-op, and carrier invoices deduplicate asynchronously — read [idempotent upserts](/conventions/idempotency-and-retries) before writing retry logic. 3. **`400` is never retryable as-is** — the request itself is wrong; fix the payload. 4. **`401` is not retryable** — fix the credential. ```javascript theme={null} async function apiCall(url, options, maxRetries = 3) { for (let attempt = 1; attempt <= maxRetries; attempt++) { let response; try { response = await fetch(url, options); } catch (error) { if (attempt === maxRetries) throw error; await new Promise((r) => setTimeout(r, 2 ** attempt * 1000 + Math.random() * 250)); continue; } if (response.status >= 500) { if (attempt === maxRetries) { throw new Error(`API error ${response.status}: server error after ${attempt} attempts`); } await new Promise((r) => setTimeout(r, 2 ** attempt * 1000 + Math.random() * 250)); continue; } if (!response.ok) { // 4xx — fail immediately and surface the flat JSON error body const body = await response.json().catch(() => null); const message = body?.error ?? 'Unparseable client-error response'; const code = body?.code ? ` (${body.code})` : ''; throw new Error(`API error ${response.status}: ${message}${code}`); } return await response.json(); } } ``` ## Getting Help If an error doesn't match anything on this page: 1. **Capture the full exchange** — endpoint, HTTP method, request body (redact the API key), the complete response body, and the timestamp. 2. **Note the last 4 characters of the API key** you used (never send the full key). 3. **Contact support** at [support@upwell.com](mailto:support@upwell.com). For platform-level troubleshooting beyond API errors, see the [Troubleshooting guide](/troubleshooting). # Get a shipment line item Source: https://docs.upwell.com/api-reference/get-a-shipment-line-item /api-reference/openapi.json get /api/rest/shipment_line_items/{id} Retrieve a single shipment line item by its `sli_` ID. # API Reference Source: https://docs.upwell.com/api-reference/introduction Complete reference for the Upwell REST API ## Welcome to the Upwell API The Upwell REST API provides programmatic access to the core functionality of the Upwell platform — accounts payable automation, accounts receivable management, and document processing for logistics and freight companies. The endpoint reference in this section is generated directly from Upwell's live OpenAPI specification, so it always reflects the current request and response shapes. Objects are listed **alphabetically** — a neutral order that deliberately implies nothing about importance. To see which objects belong together, start with the overview for the side you're building: > [card] [Accounts payable](/api-reference/ap-overview) > > Money out — bills, carrier invoices, approvals, and payments to carriers. > [card] [Accounts receivable](/api-reference/ar-overview) > > Money in — customer invoices, delivery, and applying remittances. **Base URL (production)**: `https://api.upwell.com` **Base URL (staging)**: `https://staging.api.upwell.com` **Path prefix**: `/api/rest/` **OpenAPI specification**: [app.upwell.com/openapi.json](https://app.upwell.com/openapi.json) Download the OpenAPI specification to import the API into Postman or generate a client for your language. It is the same filtered spec this reference is built from and is updated with every release. ## Start here > [card] [Authentication](/authentication) > > Get an API key and authenticate your requests. > [card] [Integration patterns](/integration-patterns) > > Idempotent upserts, integer-cents money, and the two-step document upload. > [card] [Submit a carrier invoice](/api-guides/carrier-invoice-submission) > > Create a carrier invoice and attach its documents via the API. > [card] [Purchase orders & vendor invoices](/api-guides/purchase-orders-and-vendor-invoices) > > Upload and manage parsed purchase orders and vendor invoices. > [card] [Track processing status](/api-guides/carrier-invoice-status) > > Know when a carrier invoice is received, processed, or flagged. > [card] [Outbound webhooks](/api-guides/webhooks) > > Subscribe to events and authenticate the deliveries you receive. > [card] [Error handling](/api-reference/error-codes) > > HTTP status codes, real error shapes, and retry guidance. ## API conventions * **RESTful design** — standard HTTP methods (`GET`, `POST`, `PUT`, `PATCH`, `DELETE`). * **JSON** — all requests and responses are JSON. * **Authentication** — API-key based, sent in the `Authorization` header. See the [Authentication guide](/authentication). * **Money is integer cents** — monetary fields are integers in cents, never floating-point dollars. See [Money & payloads](/conventions/money-and-payloads). * **Pagination is `limit` + `offset`, and the default `limit` is 10** — a list `GET` with no parameters returns only the first ten records, with nothing marking the response as truncated (a few endpoints default to 100). Always pass `limit`/`offset` explicitly when syncing or reconciling. Server-side filtering lives on the `POST //search` endpoints ([Integration patterns](/integration-patterns)). * **`sourceSystem` + `sourceSystemId` is your external key** — the pair that ties an Upwell record back to yours, unique per tenant. It is **not** a blanket upsert: `POST` once, then update with the method that resource accepts (below), and check the per-resource retry semantics in [Idempotency & retries](/conventions/idempotency-and-retries) before you build retries. Addresses are the exception — they have no external key at all. * **Updates are `PUT` on most resources and `PATCH` on ten of them** — there is no resource that accepts both, so sending the wrong verb fails rather than falling back. These ten take `PATCH`: `bill_line_items`, `carrier_invoice_approval_requests`, `documents`, `invoice_line_items`, `purchase-order-line-items`, `purchase-orders`, `shipment_line_items`, `vendor-invoice-line-items`, `vendor-invoices`, and `vendors`. Everything else updates with `PUT`. Each endpoint's reference page in the sidebar shows the verb it accepts. * **Child records nest under a `data` key, on create only** — a `POST` body can create a record's children in the same call. The wrapper is `{ "data": [ … ] }` for a list (a customer's `addresses`, an invoice's `invoiceLineItems`) and `{ "data": { … } }` for a single slot (a shipment's `pickupAddress`). Each of these fields links to its own schema in the reference below — expand it to see the exact child shape. **Update bodies take no nested children**: `PUT` sets scalar columns on the record itself, so a child has to be written with its own endpoint. See [Working with addresses](/conventions/addresses) for the full pattern. ## Authentication All API requests must include your API key in the `Authorization` header — bare, or with a `Bearer ` prefix (both are accepted). See the [Authentication guide](/authentication) for how to obtain, scope, and rotate keys. ```bash theme={null} curl -X GET "https://api.upwell.com/api/rest/invoices" \ -H "Authorization: YOUR_API_KEY" ``` ## Responses Successful responses return JSON keyed by the resource the endpoint operates on — a single object under its singular name (`{ "carrierInvoice": { ... } }`) or a list under its plural one (`{ "carrierInvoices": [ ... ] }`). Four list endpoints return a count alongside the rows, under an `…Aggregate` key: `GET /invoices` and `GET /customers` (as `invoicesAggregate` and `customersAggregate`), and the two [invoice queues](/api-reference/endpoint-index#invoice-queues), which both use `invoicesAggregate`. Every other list endpoint returns rows only, so page until you get a short page rather than expecting a total. A single-resource `GET` for an id that doesn't exist returns `200` with a `null` resource, not a `404`. The exact shape for each endpoint is documented on its reference page in the sidebar. Errors follow the format described in [Error handling](/api-reference/error-codes). ## Getting started 1. [Obtain your API key](/authentication#getting-your-api-key). 2. Skim [Integration patterns](/integration-patterns) for the conventions above. 3. Browse the endpoint reference in the sidebar, or follow a [developer guide](/api-guides/carrier-invoice-submission). 4. Handle errors using the [Error handling](/api-reference/error-codes) reference. For additional support, contact our [technical support team](mailto:support@upwell.com). # Approve customer invoice Source: https://docs.upwell.com/api-reference/invoice-approval/approve-customer-invoice /api-reference/openapi.json post /api/rest/invoices/{id}/approve Approve a customer invoice for sending. If the invoice has open exceptions, approval will fail unless overrideExceptions=true is passed, which will close all open exceptions and approve the invoice. > [!WARNING] > > Business failures return **inside a `200` body** (`approveInvoice.error.code`: `OPEN_EXCEPTIONS`, `INVOICE_NOT_FOUND`) — check `success`/`error`, not just the HTTP status. `overrideExceptions=true` closes open exceptions and approves. See [Error handling](/api-reference/error-codes). # List invoices ready for approval Source: https://docs.upwell.com/api-reference/invoice-approval/list-invoices-ready-for-approval /api-reference/openapi.json get /api/rest/invoices/queues/ready-for-approval Retrieve a paginated list of customer invoices ready for approval: `CREATED` status, `approvedToSend` false, and no exception in `OPEN` or `IN_PROGRESS`. > [!NOTE] > > Default `limit` is **10** — a request with no parameters silently returns only the first ten records. Always pass `limit`/`offset` when syncing or reconciling. See [API conventions](/api-reference/introduction). # List invoices ready to send Source: https://docs.upwell.com/api-reference/invoice-approval/list-invoices-ready-to-send /api-reference/openapi.json get /api/rest/invoices/queues/ready-to-send Retrieve a paginated list of customer invoices in the Ready To Send queue: `CREATED` status, not on hold, a customer assigned, no exception in `OPEN` or `IN_PROGRESS`, not scheduled, not manual portal work, and not owned by a customer's auto-send email rule. `approvedToSend` may be either value. This feed is deliberately a superset of the in-app Pre-Invoice Audit lane: invoices that automation will drain via auto-portal are excluded in the app but included here, so a consumer never silently loses an actionable invoice. > [!NOTE] > > Default `limit` is **10** — a request with no parameters silently returns only the first ten records. Always pass `limit`/`offset` when syncing or reconciling. See [API conventions](/api-reference/introduction). # Create Invoice Document Source: https://docs.upwell.com/api-reference/invoice-documents/create-invoice-document /api-reference/openapi.json post /api/rest/invoices/{invoiceId}/documents Create a new invoice document # Delete Invoice Document Source: https://docs.upwell.com/api-reference/invoice-documents/delete-invoice-document /api-reference/openapi.json delete /api/rest/invoices/{invoiceId}/documents/{id} Delete an invoice document by ID # Get Many Invoice Documents Source: https://docs.upwell.com/api-reference/invoice-documents/get-many-invoice-documents /api-reference/openapi.json get /api/rest/invoices/{invoiceId}/documents Query a list of invoice documents # Create One Invoice Line Item Source: https://docs.upwell.com/api-reference/invoice-line-items/create-one-invoice-line-item /api-reference/openapi.json post /api/rest/invoice_line_items Create a new invoice line item # Delete One Invoice Line Item Source: https://docs.upwell.com/api-reference/invoice-line-items/delete-one-invoice-line-item /api-reference/openapi.json delete /api/rest/invoice_line_items/{id} Delete an invoice line item by ID # Update One Invoice Line Item Source: https://docs.upwell.com/api-reference/invoice-line-items/update-one-invoice-line-item /api-reference/openapi.json patch /api/rest/invoice_line_items/{id} Update an invoice line item by ID # Link invoice to shipment Source: https://docs.upwell.com/api-reference/invoice-shipments/link-invoice-to-shipment /api-reference/openapi.json post /api/rest/invoice_shipments Create an association between an invoice and a shipment. # Unlink invoice from shipment Source: https://docs.upwell.com/api-reference/invoice-shipments/unlink-invoice-from-shipment /api-reference/openapi.json delete /api/rest/invoice_shipments/{invoiceId}/{shipmentId} Remove the association between an invoice and a shipment. # Create One Invoice Source: https://docs.upwell.com/api-reference/invoices/create-one-invoice /api-reference/openapi.json post /api/rest/invoices Create a new invoice. **Integration notes:** - `POST` errors with `400 Uniqueness violation` on duplicate `(sourceSystem, sourceSystemId)`. Use `PUT` for updates. - `balance` is `NOT NULL` with no server-side default — for a new invoice it should equal `totalAmount`. - `totalAmount` (and other monetary fields) are integer cents, not float dollars. - The invoice number field is `number` (not `invoiceNumber`) and the issue date is [`issueDate`](/conventions/dates-and-times#issue-date) (not [`invoiceDate`](/conventions/dates-and-times#invoice-date)). See [Integration patterns](/integration-patterns). > [!WARNING] > > **Not retry-safe.** Re-`POST`ing an existing `(sourceSystem, sourceSystemId)` pair returns `400 Uniqueness violation` — create once, then update with `PUT`. See [Idempotency & retries](/conventions/idempotency-and-retries). # Delete One Invoice Source: https://docs.upwell.com/api-reference/invoices/delete-one-invoice /api-reference/openapi.json delete /api/rest/invoices/{id} Delete an invoice by ID # Delete One Invoice By Source System Id Source: https://docs.upwell.com/api-reference/invoices/delete-one-invoice-by-source-system-id /api-reference/openapi.json delete /api/rest/invoices Delete an invoice by source system id # Get Many Invoices Source: https://docs.upwell.com/api-reference/invoices/get-many-invoices /api-reference/openapi.json get /api/rest/invoices Query a list of invoices > [!NOTE] > > Default `limit` is **10** — a request with no parameters silently returns only the first ten records. Always pass `limit`/`offset` when syncing or reconciling. See [API conventions](/api-reference/introduction). # Get One Invoice Source: https://docs.upwell.com/api-reference/invoices/get-one-invoice /api-reference/openapi.json get /api/rest/invoices/{id} Get an invoice by ID # Search Invoices Source: https://docs.upwell.com/api-reference/invoices/search-invoices /api-reference/openapi.json post /api/rest/invoices/search Search invoices with pagination, ordering, and a Hasura boolean `where` expression. To find an invoice by external key, filter `sourceSystem` and `sourceSystemId` under `where`. # Update One Invoice Source: https://docs.upwell.com/api-reference/invoices/update-one-invoice /api-reference/openapi.json put /api/rest/invoices/{id} Update an invoice by ID # Update One Invoice By Source System Id Source: https://docs.upwell.com/api-reference/invoices/update-one-invoice-by-source-system-id /api-reference/openapi.json put /api/rest/invoices Update an invoice by source system id > [!NOTE] > > Updates by **external key**: send `sourceSystem` + `sourceSystemId` inside `input` to update without the Upwell id. See [Idempotency & retries](/conventions/idempotency-and-retries). # Get One Purchase Order Source: https://docs.upwell.com/api-reference/purchase-orders/get-one-purchase-order /api-reference/openapi.json get /api/rest/purchase-orders/{id} Get a parsed purchase order by id, including line items and party addresses. # List Purchase Orders Source: https://docs.upwell.com/api-reference/purchase-orders/list-purchase-orders /api-reference/openapi.json get /api/rest/purchase-orders List recent purchase orders (newest first). Optional `limit` query parameter caps the result count. > [!NOTE] > > Default `limit` is **10** — a request with no parameters silently returns only the first ten records. Always pass `limit`/`offset` when syncing or reconciling. See [API conventions](/api-reference/introduction). # List Purchase Orders By Document Source: https://docs.upwell.com/api-reference/purchase-orders/list-purchase-orders-by-document /api-reference/openapi.json get /api/rest/documents/{documentId}/purchase-orders Get the parsed purchase order(s) created from an uploaded document. Returns an empty list until parsing completes — poll after uploading to the presigned URL. If the uploaded PDF contained multiple documents it is split automatically and this returns one purchase order per document in the file, each appearing as its parse completes; the upload is fully processed when the document's `status` is `PROCESSING_COMPLETED`. # Search Purchase Orders By Source System Source: https://docs.upwell.com/api-reference/purchase-orders/search-purchase-orders-by-source-system /api-reference/openapi.json post /api/rest/purchase-orders/search Find the purchase order(s) created from a document you uploaded, keyed by the `sourceSystem` + `sourceSystemId` you supplied at presign time. Records from a multi-document upload are included: the search matches the uploaded document's ids even when the purchase order was parsed from an automatically split piece of it. Body: `{ "sourceSystem": "...", "sourceSystemId": "..." }`. # Update One Purchase Order Source: https://docs.upwell.com/api-reference/purchase-orders/update-one-purchase-order /api-reference/openapi.json patch /api/rest/purchase-orders/{id} Update parsed purchase order header fields. Body: `{ "input": { ...fields to set... } }` using the record's camelCase field names (amounts in integer cents). System-managed columns (ids, tenant/document linkage, party references, match state) are not updatable and are rejected. # Update One Purchase Order Line Item Source: https://docs.upwell.com/api-reference/purchase-orders/update-one-purchase-order-line-item /api-reference/openapi.json patch /api/rest/purchase-order-line-items/{id} Update parsed purchase order line item fields. Body: `{ "input": { ...fields to set... } }` using the record's camelCase field names (amounts in integer cents). System-managed columns (ids, tenant/document linkage, party references, match state) are not updatable and are rejected. # Create One Rule Source: https://docs.upwell.com/api-reference/rules/create-one-rule /api-reference/openapi.json post /api/rest/rules Create a new rule > [!NOTE] > > The fields to populate depend on the rule's `type` — three distinct shapes; mixing them produces a rule that silently never fires. See [Rules](/conventions/rules). # Delete One Rule Source: https://docs.upwell.com/api-reference/rules/delete-one-rule /api-reference/openapi.json delete /api/rest/rules/{id} Delete a rule by ID > [!WARNING] > > Rules never soft-delete — this is **permanent**. Prefer `PUT` with `enabled: false` to pause a rule. See [Rules](/conventions/rules). # Get Many Rules Source: https://docs.upwell.com/api-reference/rules/get-many-rules /api-reference/openapi.json get /api/rest/rules Query a list of rules > [!NOTE] > > Default `limit` is **10** — a request with no parameters silently returns only the first ten records. Always pass `limit`/`offset` when syncing or reconciling. See [API conventions](/api-reference/introduction). # Get One Rule Source: https://docs.upwell.com/api-reference/rules/get-one-rule /api-reference/openapi.json get /api/rest/rules/{id} Get a rule by ID # Update One Rule Source: https://docs.upwell.com/api-reference/rules/update-one-rule /api-reference/openapi.json put /api/rest/rules/{id} Update a rule by ID # Create Shipment Document Source: https://docs.upwell.com/api-reference/shipment-documents/create-shipment-document /api-reference/openapi.json post /api/rest/shipments/{shipmentId}/documents Create a new shipment document # Delete Shipment Document Source: https://docs.upwell.com/api-reference/shipment-documents/delete-shipment-document /api-reference/openapi.json delete /api/rest/shipments/{shipmentId}/documents/{id} Delete a shipment document by ID # Get Many Shipment Documents Source: https://docs.upwell.com/api-reference/shipment-documents/get-many-shipment-documents /api-reference/openapi.json get /api/rest/shipments/{shipmentId}/documents Query a list of shipment documents # Search Shipment Line Items Source: https://docs.upwell.com/api-reference/shipment-line-items/search-shipment-line-items /api-reference/openapi.json post /api/rest/shipment_line_items/search Search for shipment line items by source system and source system ID # Create One Shipment Source: https://docs.upwell.com/api-reference/shipments/create-one-shipment /api-reference/openapi.json post /api/rest/shipments Create a new shipment. **Integration notes:** - `POST` errors with `400 Uniqueness violation` on duplicate `(sourceSystem, sourceSystemId)`. Use `PUT` for updates. - `shipmentId` is `NOT NULL` with no server-side default — you must provide a unique string. - `customerTotalRate` and `carrierTotalRate` are integer cents, not float dollars. See [Integration patterns](/integration-patterns). > [!WARNING] > > **Not retry-safe** (`400 Uniqueness violation` on a duplicate external key), and `shipmentId` is **required with no server default**. See [Idempotency & retries](/conventions/idempotency-and-retries). # Create Shipment Note Source: https://docs.upwell.com/api-reference/shipments/create-shipment-note /api-reference/openapi.json post /api/rest/shipments/{shipmentId}/notes Append a note to a shipment. Send `{ "content": "…" }`; the note is always owned by the shipment in the path. # Delete One Shipment Source: https://docs.upwell.com/api-reference/shipments/delete-one-shipment /api-reference/openapi.json delete /api/rest/shipments/{id} Delete a shipment by ID # Delete One Shipment By Source System Id Source: https://docs.upwell.com/api-reference/shipments/delete-one-shipment-by-source-system-id /api-reference/openapi.json delete /api/rest/shipments Delete a shipment by source system id # Get Many Shipments Source: https://docs.upwell.com/api-reference/shipments/get-many-shipments /api-reference/openapi.json get /api/rest/shipments Query a list of shipments > [!NOTE] > > Default `limit` is **10** — a request with no parameters silently returns only the first ten records. Always pass `limit`/`offset` when syncing or reconciling. See [API conventions](/api-reference/introduction). # Get One Shipment Source: https://docs.upwell.com/api-reference/shipments/get-one-shipment /api-reference/openapi.json get /api/rest/shipments/{id} Get a shipment by ID # Search Shipments Source: https://docs.upwell.com/api-reference/shipments/search-shipments /api-reference/openapi.json post /api/rest/shipments/search Search for shipments based on specified criteria # Update One Shipment Source: https://docs.upwell.com/api-reference/shipments/update-one-shipment /api-reference/openapi.json put /api/rest/shipments/{id} Update a shipment by ID. **Integration notes:** - Accepts the shipment's own scalar fields only; `customerTotalRate`, `carrierTotalRate` and `declaredValue` are integer cents. - Correct related records through their own endpoints: `PUT /api/rest/addresses/{id}`, `PUT /api/rest/stops/{id}`, `PATCH /api/rest/shipment_line_items/{id}`, `POST /api/rest/shipments/{shipmentId}/notes`. Pickup and consignee address links are fixed at creation. - Mirror a TMS hold with `onHold` and `holdReason`: send `onHold: true` when the load is held and `onHold: false, holdReason: null` when it is released. See [Holding a shipment](/api-guides/syncing-foundation-entities#holding-a-shipment). # Update One Shipment By Source System Id Source: https://docs.upwell.com/api-reference/shipments/update-one-shipment-by-source-system-id /api-reference/openapi.json put /api/rest/shipments Update a shipment by source system id. **Integration notes:** - Accepts the shipment's own scalar fields only; `customerTotalRate`, `carrierTotalRate` and `declaredValue` are integer cents. - Correct related records through their own endpoints: `PUT /api/rest/addresses/{id}`, `PUT /api/rest/stops/{id}`, `PATCH /api/rest/shipment_line_items/{id}`, `POST /api/rest/shipments/{shipmentId}/notes`. Pickup and consignee address links are fixed at creation. - Mirror a TMS hold with `onHold` and `holdReason`: send `onHold: true` when the load is held and `onHold: false, holdReason: null` when it is released. See [Holding a shipment](/api-guides/syncing-foundation-entities#holding-a-shipment). > [!NOTE] > > Updates by **external key**: send `sourceSystem` + `sourceSystemId` inside `input` to update without the Upwell id. See [Idempotency & retries](/conventions/idempotency-and-retries). # Create One Stop Source: https://docs.upwell.com/api-reference/stops/create-one-stop /api-reference/openapi.json post /api/rest/stops Create a new stop # Delete One Stop Source: https://docs.upwell.com/api-reference/stops/delete-one-stop /api-reference/openapi.json delete /api/rest/stops/{id} Delete a stop by ID # Get Many Stops Source: https://docs.upwell.com/api-reference/stops/get-many-stops /api-reference/openapi.json get /api/rest/stops Query a list of stops > [!NOTE] > > Default `limit` is **10** — a request with no parameters silently returns only the first ten records. Always pass `limit`/`offset` when syncing or reconciling. See [API conventions](/api-reference/introduction). # Get One Stop Source: https://docs.upwell.com/api-reference/stops/get-one-stop /api-reference/openapi.json get /api/rest/stops/{id} Get a stop by ID # Update One Stop Source: https://docs.upwell.com/api-reference/stops/update-one-stop /api-reference/openapi.json put /api/rest/stops/{id} Update a stop by ID # Update a shipment line item Source: https://docs.upwell.com/api-reference/update-a-shipment-line-item /api-reference/openapi.json patch /api/rest/shipment_line_items/{id} Update a shipment line item by its `sli_` ID. Send only the fields you want to change — omitted fields keep their stored values. # Get One Vendor Invoice Source: https://docs.upwell.com/api-reference/vendor-invoices/get-one-vendor-invoice /api-reference/openapi.json get /api/rest/vendor-invoices/{id} Get a parsed vendor invoice by id, including line items, party addresses, and the matched purchase order. # List Vendor Invoices Source: https://docs.upwell.com/api-reference/vendor-invoices/list-vendor-invoices /api-reference/openapi.json get /api/rest/vendor-invoices List recent vendor invoices (newest first). Optional `limit` query parameter caps the result count. > [!NOTE] > > Default `limit` is **10** — a request with no parameters silently returns only the first ten records. Always pass `limit`/`offset` when syncing or reconciling. See [API conventions](/api-reference/introduction). # List Vendor Invoices By Document Source: https://docs.upwell.com/api-reference/vendor-invoices/list-vendor-invoices-by-document /api-reference/openapi.json get /api/rest/documents/{documentId}/vendor-invoices Get the parsed vendor invoice(s) created from an uploaded document. Returns an empty list until parsing completes — poll after uploading to the presigned URL. If the uploaded PDF contained multiple documents it is split automatically and this returns one vendor invoice per document in the file, each appearing as its parse completes; the upload is fully processed when the document's `status` is `PROCESSING_COMPLETED`. # Search Vendor Invoices By Source System Source: https://docs.upwell.com/api-reference/vendor-invoices/search-vendor-invoices-by-source-system /api-reference/openapi.json post /api/rest/vendor-invoices/search Find the vendor invoice(s) created from a document you uploaded, keyed by the `sourceSystem` + `sourceSystemId` you supplied at presign time. Records from a multi-document upload are included: the search matches the uploaded document's ids even when the vendor invoice was parsed from an automatically split piece of it. Body: `{ "sourceSystem": "...", "sourceSystemId": "..." }`. # Update One Vendor Invoice Source: https://docs.upwell.com/api-reference/vendor-invoices/update-one-vendor-invoice /api-reference/openapi.json patch /api/rest/vendor-invoices/{id} Update parsed vendor invoice header fields. Body: `{ "input": { ...fields to set... } }` using the record's camelCase field names (amounts in integer cents). System-managed columns (ids, tenant/document linkage, party references, match state) are not updatable and are rejected. # Update One Vendor Invoice Line Item Source: https://docs.upwell.com/api-reference/vendor-invoices/update-one-vendor-invoice-line-item /api-reference/openapi.json patch /api/rest/vendor-invoice-line-items/{id} Update parsed vendor invoice line item fields. Body: `{ "input": { ...fields to set... } }` using the record's camelCase field names (amounts in integer cents). System-managed columns (ids, tenant/document linkage, party references, match state) are not updatable and are rejected. # Create One Vendor Source: https://docs.upwell.com/api-reference/vendors/create-one-vendor /api-reference/openapi.json post /api/rest/vendors Create a new vendor > [!NOTE] > > `name`, `sourceSystem`, and `sourceSystemId` are **required** on vendors. See [Syncing foundation entities](/api-guides/syncing-foundation-entities). # Delete One Vendor Source: https://docs.upwell.com/api-reference/vendors/delete-one-vendor /api-reference/openapi.json delete /api/rest/vendors/{id} Delete a vendor by ID > [!WARNING] > > **Permanent hard delete**, and it **fails outright** if any bill still references the vendor. See [Deleting and archiving](/conventions/deletes-and-archiving). # Get One Vendor Source: https://docs.upwell.com/api-reference/vendors/get-one-vendor /api-reference/openapi.json get /api/rest/vendors/{id} Get a vendor by ID # Search Vendors Source: https://docs.upwell.com/api-reference/vendors/search-vendors /api-reference/openapi.json post /api/rest/vendors/search Search for vendors based on Source System and Source System ID # Update One Vendor Source: https://docs.upwell.com/api-reference/vendors/update-one-vendor /api-reference/openapi.json patch /api/rest/vendors/{id} Update a vendor by ID # Vocabulary Source: https://docs.upwell.com/api-reference/vocabulary Every enum value the API can produce — statuses, address types, document types, stop types — generated from the API schema rather than hand-maintained. # Vocabulary The core integration enums — statuses, exceptions, approvals, address types, stop types, payment statuses, and document types. **Values are generated from the API schema**, not hand-maintained, so each list below is the complete set as of the release that published it. Handle unrecognized values defensively — a value added to the API since then will not appear here until this page is regenerated. 1 value(s) below do not yet have a published definition; their Meaning cell says so and points you at support. Field-level enums not listed here (e.g. country and currency codes) are documented on their endpoints in the API reference. ## Carrier invoice statuses The `status` field on carrier invoices (AP). Lifecycle guidance: [Knowing when a carrier invoice is processed](/api-guides/carrier-invoice-status). | Value | Meaning | | - | - | | `APPROVED` | Approved — cleared to pay (review lifecycle). | | `AWAITING_BILL` | A shipment is matched but no bill is linked yet; auto-promotes to `RECEIVED` once one is. Also set if a linked bill is later cancelled or voided, freeing the invoice to re-match. | | `AWAITING_CARRIER_RESPONSE` | Waiting on the carrier. | | `AWAITING_INVOICE` | Created ahead of the invoice document; auto-promotes to `RECEIVED` when that document arrives and parses. | | `CANCELLED` | Terminal. The invoice was nullified, either by request or because it was issued in error — it drops out of the actionable queues. | | `CARRIER_EXCEPTION` | A carrier-side issue needs resolving. | | `CARRIER_RESPONDED` | The carrier has responded. | | `DISPUTED` | Disputed. | | `EXCEPTION` | An audit exception needs resolving. | | `PAID` | Fully paid. | | `PART_PAID` | Partially paid. | | `PROCESSING` | In-flight processing. | | `RECEIVED` | Submitted / in review. Ingestion (matching + audit) usually runs while status stays here. | | `REFUNDED` | Terminal. A previously paid invoice was reversed and the payment returned. | | `REJECTED` | Rejected. | | `UNDER_REVIEW` | In manual review. | ## Customer invoice statuses The `status` field on customer invoices (AR). Lifecycle guidance: [Managing customer invoices](/api-guides/customer-invoices). | Value | Meaning | | - | - | | `APPROVED` | Invoice has been approved for sending. | | `CANCELLED` | Invoice was cancelled. | | `CREATED` | Invoice record exists but hasn't been finalized. | | `DELIVERED` | Invoice delivery has been confirmed. | | `DISPUTED` | Customer has raised a dispute. | | `DRAFT` | A pre-`CREATED` stage for invoices synced from a TMS before the TMS posts the bill. Excluded from portal delivery, manual send, and receivables — sending one returns `409` — until it promotes to `CREATED` (or to `CANCELLED` if the TMS voids it). | | `OPEN` | Invoice is finalized and ready for delivery. | | `OVERDUE` | Past due date with an outstanding balance. | | `PAID` | Fully paid — balance is `0`. | | `PART_PAID` | Partially paid — balance is between `0` and `totalAmount`. | | `PORTAL_EXCEPTION` | The invoice hit an exception during portal delivery. | | `PORTAL_RESOLVED` | A portal exception has been resolved. | | `PROCESSING` | Invoice is being processed for delivery. | | `REFUNDED` | A refund was issued. | | `REJECTED` | Invoice was rejected. | | `SEND_ERROR` | Invoice delivery failed. | | `SENT` | Invoice has been delivered to the customer. | | `VIEWED` | Customer has viewed the invoice (online portal). | | `WRITE_OFF` | Written off as uncollectible. | ## Exception statuses The lifecycle of an [exception](/concepts/exceptions). `OPEN` and `IN_PROGRESS` are the two "still needs attention" states that hold an invoice back. | Value | Meaning | | - | - | | `CLOSED` | Closed; no further action needed. | | `IN_PROGRESS` | Someone is actively working it. | | `OPEN` | Raised but not yet addressed — needs attention. | | `RESOLVED` | Worked and resolved. | | `RULE_DISABLED` | Suppressed because the audit rule that generated it was turned off. | ## Approval request statuses The `status` on [carrier-invoice approval requests](/api-guides/carrier-invoice-approval). Your integration resolves a request by PATCHing `SUCCEEDED` or `FAILED`. | Value | Meaning | | - | - | | `ABANDONED` | Upwell gave up waiting: the request was still unresolved 10 minutes after dispatch. The carrier invoice is **not** approved, and resolving the request afterwards will not approve it. | | `FAILED` | Resolved rejected. The carrier invoice is left where it is — Upwell does not move it to a rejected status for you. | | `INITIATED` | The request record has been created and validated; Upwell has not dispatched it to you yet. This is the state every request starts in. | | `IN_PROGRESS` | Upwell has dispatched the request to your webhook endpoint and is waiting for you to resolve it. Dispatch also starts the 10-minute abandonment clock. | | `RETRYING` | Reserved. No Upwell code path currently sets this; if you do encounter it, treat it like `IN_PROGRESS` — still in flight, not yet resolved. | | `SUCCEEDED` | Resolved approved — moves the carrier invoice to `APPROVED`. | ## Address types `type` is required on every address and several product surfaces query it exactly — see [Working with addresses](/conventions/addresses) for which types are load-bearing. | Value | Meaning | | - | - | | `ADDRESS_BOOK` | **Inert — nothing reads it.** Not a safe generic default; always use the specific role type. | | `CARRIER` | A carrier's primary address (descriptive). | | `CARRIER_BILLING` | Where a carrier wants payment sent (descriptive; remit-to logic is driven by factoring documents). | | `COMPANY_ADDRESS` | **Load-bearing.** The only type the company pages render. | | `COMPANY_REMITTANCE_ADDRESS` | Definition not yet published — contact [support@upwell.com](mailto:support@upwell.com) for the current meaning of this value. | | `CONTACT` | An address on a contact record (descriptive). | | `CUSTOMER_BILLING` | **Load-bearing.** A customer's billing address — the invoice bill-to block and delivery routing read this exact value. At most one per customer. | | `DELIVERY_RECEIPT` | Written by Upwell's document-parsing pipelines — read-only for integrations. | | `LUMPER_RECEIPT` | Written by Upwell's document-parsing pipelines — read-only for integrations. | | `SHIPMENT_CONSIGNEE` | A shipment's destination slot. | | `SHIPMENT_PICKUP` | A shipment's origin slot. | | `STOP` | An address used by a route stop (descriptive). | | `SUPPORTING_DOC_PARTY` | Written by Upwell's document-parsing pipelines — you'll see it on reads; don't create it. | ## Stop types The constrained vocabulary for a stop's `type` field. A stop carries **two** type fields — the enum-constrained `type` below and a separate free-text `stopType` — and different surfaces read each, so populate both where you can. The legacy `POST /api/rest/shipments` endpoint can only set `stopType`; see [Syncing foundation entities](/api-guides/syncing-foundation-entities). Today only `PICKUP` and `DELIVERY` are branched on in logic; the rest are recorded and passed through (for example to outbound EDI) but nothing keys off them. | Value | Meaning | | - | - | | `CONSOLIDATION` | A stop to combine multiple smaller shipments into a larger load. | | `CROSS_DOCK` | A facility where goods move directly from inbound to outbound trailer with minimal storage. | | `CUSTOMS` | A checkpoint or border crossing for regulatory inspection. | | `DECONSOLIDATION` | A stop to break down a larger load into multiple smaller shipments. | | `DELIVERY` | The final or primary destination where freight is delivered. **Load-bearing** — a `DELIVERY` stop that has an address is what lets proof-of-delivery exceptions evaluate per stop; without one, evaluation falls back to the shipment's consignee address. | | `DROP_OFF` | A location where a partial shipment is unloaded (for example, on a multi-stop route). | | `FUEL_STOP` | A planned stop for refueling or vehicle service. | | `LAYOVER` | A stop for driver rest or waiting (for example, required by hours-of-service rules). | | `ORIGIN` | The initial starting point for the shipment. | | `OTHER` | Catch-all for unclassified or special-case stops — integrations map unrecognized external codes here. | | `PICKUP` | A location where freight is physically picked up. **Load-bearing** — the carrier-invoice shipments view treats the first `PICKUP` stop as the shipment origin. | | `RETURN` | Returning freight to an origin or warehouse (for example, refused shipments or product returns). | | `STORAGE` | A temporary storage or holding location for freight. | | `TERMINAL` | A main hub for consolidation, deconsolidation, or staging. | | `TRANSFER` | A location where freight changes carriers, modes, or vehicles. | ## Payment statuses The `status` field on payment records. Two things to know before you branch on it. **The field is nullable**, and a `null` status means a legacy or externally-recorded payment — Upwell treats those as `SUCCEEDED`, so read it as `status ?? SUCCEEDED` rather than assuming a value is present. And **only `PENDING` is not yet money**: `FAILED` and `PAYMENT_REVERSED` both mean funds did not stay with you, but they differ in whether the money ever landed at all. | Value | Meaning | | - | - | | `DISPUTED` | The payer opened a chargeback against a settled card payment. Applied amounts are deliberately left in place because the dispute may be won, but funds may be withheld meanwhile. | | `FAILED` | Declined or errored **before** capture — no money ever moved and the invoice balance is unchanged. | | `PAYMENT_REVERSED` | The bank involuntarily reversed an already-settled payment (an ACH return or NSF). The invoice reopens with its balance restored — the payer still owes you. Distinct from `REFUNDED`, which is deliberate. | | `PENDING` | Submitted to the payment processor and not yet confirmed. No funds have landed. | | `REFUNDED` | The payment was **fully** refunded to the payer. A partial refund does not land here — it adjusts the applied amounts and leaves the payment `SUCCEEDED`. | | `SUCCEEDED` | The processor confirmed the payment and captured funds, recorded at the amount the bank actually received. | ## Document types The canonical `documentType` codes (send the code, not a display label — `PROOF_OF_DELIVERY`, not "POD"). The full generated list follows the table; the table covers the types integrations set most, per the guides. | Type | Meaning | | - | - | | `BILL_OF_LADING` | Bill of lading. | | `CARRIER_INVOICE` | The carrier's invoice document — parsing it populates blank header fields and line items on the carrier invoice. | | `CARRIER_RATE_CONFIRMATION` | The rate you agreed to **pay the carrier** — carrier cost; used by the carrier-invoice audit. Never type a customer rate con as this (or vice versa) — see [Document conventions](/conventions/documents). | | `CUSTOMER_INVOICE` | The customer-invoice PDF (AR). | | `CUSTOMER_RATE_CONFIRMATION` | The rate your **customer agreed to pay you** — revenue; used to validate customer invoices. | | `LUMPER_RECEIPT` | A lumper service receipt. | | `NOTICE_OF_ASSIGNMENT` | A factoring notice — parsing it populates a carrier invoice's remit-to / factor. | | `PROOF_OF_DELIVERY` | Proof of delivery ("POD" is the display label). | | `PURCHASE_ORDER` | A standalone purchase order — uploaded via the presigned flow and parsed into a purchase-order record. | | `VENDOR_INVOICE` | A standalone non-freight vendor invoice — parsed into a vendor-invoice record. | All 134 values: ```text theme={null} ACCESSORIAL_RECEIPT ADVANCE_REQUEST AGENT_INVOICE ARRIVAL_NOTICE ASBESTOS_DECLARATION AUSFTA AUTHORITY AUTH_RELEASE B3_CANADIAN_ENTRY BALANCE_DUE BILL_OF_LADING CARRIER_ACH_SETUP_FORM CARRIER_BOOKING_REQUEST CARRIER_INSURANCE_CERTIFICATE CARRIER_INVOICE CARRIER_INVOICE_SUMMARY CARRIER_INVOICE_WITH_SUPPORTING_DOCUMENTATION CARRIER_RATE_CONFIRMATION CARRIER_W9 CARTAGE_ADVICE_WITH_RECEIPT CERTIFICATE_OF_ORIGIN CFDI CLAIM CLAIM_NOTICE COMCHECK COMMERCIAL_INVOICE CONSIGNMENT_SECURITY_DECLARATION CONTRACT CORRECTION_NOTICE COVER_SHEET CREDIT_APPLICATION CUSTOMER_DOCUMENTS_OTHER CUSTOMER_INVOICE CUSTOMER_INVOICE_WITH_SUPPORTING_DOCUMENTATION CUSTOMER_RATE_CONFIRMATION CUSTOMER_RELEASE CUSTOMS_AUTHORITY CUSTOMS_CLEARANCE_REQUEST CUSTOMS_DOCUMENT CUSTOMS_ENTRY_SUMMARY CUSTOMS_POWER_OF_ATTORNEY DANGEROUS_GOODS_DECLARATION DELIVERY_ORDER DELIVERY_PHOTO DELIVERY_RECEIPT DEMURRAGE_RECEIPT DETENTION_APPROVAL DOCUMENT_BUNDLE DOCUMENT_PACKET DRIVER_FORM ELECTRONIC_INTERCHANGE_RECEIPT EMAIL_APPROVAL EMAIL_SIGNATURE_IMAGE ESCORT_RECEIPT EXIT_PASS EXPORT_AUTHORITY EXPORT_DECLARATION FACTOR_INVOICE FERRY_RECEIPT FINE FORM_1113_PUBLIC_VOUCHER FREETIME_NOTIFICATION FREIGHT_LABEL FUEL_RECEIPT FUMIGATION_CERTIFICATE FUNDING_REQUEST_FORM GATE_PASS GOVERNMENT_BOL HIDDEN_BOL HOUSE_AIRWAY_BILL HOUSE_BOL HOUSE_OCEAN_BOL INSPECTION_CERTIFICATE INSTRUCTION_PAGE INTERMODAL_IN_TRANSIT_NOTICE INTERNAL_DOCUMENTS_OTHER INTERNAL_PROOF_OF_DELIVERY INTERNATIONAL_BOL INVOICE_STATEMENT ISF_FILING_INSTRUCTION LAYOVER_APPROVAL LETTER_OF_ASSIGNMENT LETTER_OF_CREDIT LUMPER_APPROVAL LUMPER_RECEIPT MANIFEST MASTER_AIRWAY_BILL MASTER_BOL MASTER_OCEAN_BOL MOTOR_VEHICLE_CERT MSDS NAFTA_CERT NMFC_W_I_CERT NOTICE_OF_ASSIGNMENT NOTICE_OF_RELEASE OTHER PACKING_DECLARATION PACKING_SLIP PALLET_RECEIPT PERMIT_TO_TRANSFER PER_DIEM_RECEIPT PICKUP_NUMBER PRE_ALERT PROFORMA_INVOICE PROOF_OF_DELIVERY PURCHASE_ORDER REMITTANCE RETURN_RECEIPT RUN_TICKET SANITARY_CERTIFICATE SCALE_TICKET SHIPPERS_LETTER SHIPPER_SECURITY_DECLARATION SOLAS_FORM SPOT_QUOTE_APPROVAL STEAMING_RECEIPT SUPPORTING_DOCUMENTATION TELEX_RELEASE TOLL_RECEIPT TONU_APPROVAL TRACKING_STATUS TRAILER_INTERCHANGE_REPORT TRUCK_BOL UNKNOWN US_CUSTOMS_DOC VENDOR_INVOICE VETERINARY_CERTIFICATE VGM_CONTAINER_INFO VOIDED_CHECK WASH_RECEIPT WAYBILL WEIGHT_MEASUREMENT_REPORT WEIGHT_TICKET WEIGHT_UNLOADED ``` # Handle a changed carrier invoice shipment link Source: https://docs.upwell.com/api-reference/webhooks/handle-a-changed-carrier-invoice-shipment-link /api-reference/openapi.json webhook onCarrierInvoiceUpdateShipmentUpdatedEvent A carrier invoice shipment_id changed. Compare shipment_id on the rows. Both shipment objects contain the same lookup. If this update also enters APPROVED, the dispatcher sends payload.carrierInvoice. # Handle carrier invoice creation with shipment information Source: https://docs.upwell.com/api-reference/webhooks/handle-carrier-invoice-creation-with-shipment-information /api-reference/openapi.json webhook onCarrierInvoiceUpdateShipmentCreatedEvent Carrier invoice creation with a shipment_id column. Read the current shipment lookup from payload.new.shipment (possibly null). # Handle carrier invoice events Source: https://docs.upwell.com/api-reference/webhooks/handle-carrier-invoice-events /api-reference/openapi.json webhook onCarrierInvoiceEvent Generic carrier invoice row events carry snake_case column snapshots with a shipment lookup. Status and shipment-link triggers have separate entries. Hard deletes cannot be enriched after the invoice is removed. # Handle carrier invoice exceptions Source: https://docs.upwell.com/api-reference/webhooks/handle-carrier-invoice-exceptions /api-reference/openapi.json webhook onCarrierInvoiceStatusExceptionEvent Read the before and after carrier invoice rows in payload.old and payload.new. Both include the same shipment lookup, or null. The customer invoice portal exception has its own trigger. # Handle carrier invoice status approved events Source: https://docs.upwell.com/api-reference/webhooks/handle-carrier-invoice-status-approved-events /api-reference/openapi.json webhook onCarrierInvoiceStatusApprovedEvent Read the invoice fetched at dispatch in payload.carrierInvoice. A first payment recording approval also fires this trigger. The current invoice can be PAID or PART_PAID. A missing invoice is returned as null. Upwell suppresses this notification on the follow-through status update for an outbound approval request. # Handle customer payment events Source: https://docs.upwell.com/api-reference/webhooks/handle-customer-payment-events /api-reference/openapi.json webhook onCustomerPaymentsEvent Customer payment creation, update and deletion send snake_case row snapshots. The old row is null on insert and the new row is null on delete. # Handle invoice status portal exception events Source: https://docs.upwell.com/api-reference/webhooks/handle-invoice-status-portal-exception-events /api-reference/openapi.json webhook onInvoiceStatusPortalExceptionEvent A customer invoice entered PORTAL_EXCEPTION. Read the before and after rows in payload.old and payload.new. # Handle invoice status sent events Source: https://docs.upwell.com/api-reference/webhooks/handle-invoice-status-sent-events /api-reference/openapi.json webhook onInvoiceStatusSentEvent A customer invoice entered SENT. Read the before and after rows in payload.old and payload.new. # Handle shipment documents events Source: https://docs.upwell.com/api-reference/webhooks/handle-shipment-documents-events /api-reference/openapi.json webhook onShipmentDocumentsEvent Shipment file association inserts and updates deliver shipment, signed file URL and document details for each populated row. If the deleted association cannot be found at dispatch, delivery is skipped. # Handles invoice events Source: https://docs.upwell.com/api-reference/webhooks/handles-invoice-events /api-reference/openapi.json webhook onInvoiceEvent Generic customer invoice changes carry row snapshots. Soft deletion sends delete.invoice with operation DELETE and a null new row. Restoration sends create.invoice with operation INSERT and a null old row. # Handles remittance events Source: https://docs.upwell.com/api-reference/webhooks/handles-remittance-events /api-reference/openapi.json webhook onRemittanceEvent Creation, updates and tracked status changes deliver a dispatch-time lookup in payload.remittance, including lineItems. A missing lookup returns null. A hard delete has no new row for the mapper to read and produces no POST. # Authentication Source: https://docs.upwell.com/authentication Learn how to authenticate your requests to the Upwell API ## API Key Authentication All requests to the Upwell API must be authenticated using your API key, included in the `Authorization` header of each request. ### Getting Your API Key API keys are self-serve — you create them in the Upwell dashboard: **1. Log into your Upwell dashboard** Any member of your organization can create an API key. **2. Navigate to Account → API keys** If **API keys** isn't visible in your navigation, it isn't enabled for your organization yet — ask your Upwell administrator or [support@upwell.com](mailto:support@upwell.com). **3. Click "Add API Key"** The key value is displayed **once**, at creation. Copy and store it securely — you can't retrieve it again later, only revoke it and create a new one. ![The API keys page under Account, with the Add API Key button above an empty list of keys](https://mintcdn.com/upwell/-Pwd7QcUk6Cnh82_/images/settings-api-keys.png?fit=max\&auto=format\&n=-Pwd7QcUk6Cnh82_\&q=85\&s=6f6b5ae0f8d8b544431924d47e2c32e4) Account then API keys. Add API Key issues a key; the value is shown once, at creation. > [!NOTE] > > API keys are sensitive credentials. Never share your API key or commit it to > version control. If your key is compromised, create a new one immediately > and revoke the old key from the same **Account → API keys** page. ### Key scope * **One key belongs to one Upwell organization (tenant)** — the one it was created in. All data access through that key is scoped to that organization. * **Integrating with more than one Upwell customer?** There is no cross-tenant credential: you hold one API key per customer, each created inside that customer's own dashboard. * **Keys don't expire.** Rotation is manual: create a new key, switch your integration over, then revoke the old one. ### Environments | Environment | Base URL | | - | - | | Production | `https://api.upwell.com` | | Staging | `https://staging.api.upwell.com` | * **Keys are environment-specific.** Each environment is a separate deployment with its own data, so a key created in your production dashboard authenticates only against `api.upwell.com`. * **Staging access is provisioned by Upwell**, not self-serve — ask [support@upwell.com](mailto:support@upwell.com) or your Upwell contact to set up a staging organization and credentials for integration testing. **Staging can make real outbound deliveries.** Separate data and API keys do not prevent invoices from reaching configured email recipients or customer portals. For an email-only test, verify the customer has only the intended email delivery method and check all recipients, including the default Upwell monitoring BCC. Current customer settings must be verified in staging before sending; they are not established by the API documentation. ### Using Your API Key Include your API key in the `Authorization` header of all API requests. The key is an opaque string — send it exactly as issued: ```bash theme={null} curl https://api.upwell.com/api/rest/invoices \ -H "Authorization: YOUR_API_KEY" ``` A `Bearer ` scheme prefix is **also accepted** (case-insensitive), so HTTP clients and generated SDKs that default to it work unchanged: ```bash theme={null} curl https://api.upwell.com/api/rest/invoices \ -H "Authorization: Bearer YOUR_API_KEY" ``` Both forms are equivalent — use whichever your HTTP client produces naturally. ### Example Requests ```javascript theme={null} // Using fetch fetch('https://api.upwell.com/api/rest/invoices', { headers: { Authorization: 'YOUR_API_KEY', }, }); ``` ```python theme={null} # Using requests import requests headers = { 'Authorization': 'YOUR_API_KEY' } response = requests.get('https://api.upwell.com/api/rest/invoices', headers=headers) ``` # Changelog Source: https://docs.upwell.com/changelog New features, improvements, and fixes across the Upwell platform and API. Subscribe to this changelog as an [RSS feed](https://docs.upwell.com/changelog/rss.xml) to get API and platform changes in Slack, email, or any feed reader — new entries publish to the feed automatically. **November 2026** ## Webhook `table` compatibility restored Outbound webhook bodies include `table` again after its removal broke existing receivers. The field is deprecated and will continue to be sent while consumers migrate. Use `trigger` to select the payload format and handler, and `resourceId` to correlate or refetch the resource. No removal date is scheduled. Any future sunset date will be published in the [webhook guide](/api-guides/webhooks) and communicated to API consumers before removal. ## Carrier invoice webhook reference corrected For `update.carrier_invoice.status.APPROVED`, read `payload.carrierInvoice`. For `update.carrier_invoice.status.EXCEPTION`, compare `payload.old` and `payload.new`. Both send `operation: "UPDATE"`. The OpenAPI entry formerly named `onCarrierInvoiceStatusPortalExceptionEvent` is now `onCarrierInvoiceStatusExceptionEvent`. Existing subscriptions use the same trigger strings. See the [receiver examples](/api-guides/webhooks). **October 2026** ## Send TMS shipment holds Shipments now document and return `onHold` and `holdReason`. Set them on `POST /api/rest/shipments` or `PUT /api/rest/shipments` to mirror a hold in your TMS, and read them back from the shipment endpoints. With the matching Receivables or Payables setting on, a held shipment holds its customer invoices from sending and flags its carrier invoices until you send `onHold: false`. See [Holding a shipment](/api-guides/syncing-foundation-entities#holding-a-shipment). **August 2026** ## API reference corrections and a rebuilt developer docs experience The API reference is now **generated end-to-end from the live spec pipeline**, which fixed several long-standing documentation bugs at the source: * **Status enum values are documented in their real UPPERCASE form** (`RECEIVED`, `PART_PAID`, …) — the lowercase values previously shown on some endpoints were never accepted by the API. The new generated [Vocabulary](/api-reference/vocabulary) page lists the complete value set for the core integration enums — statuses, exceptions, approvals, address types, stop types, payment statuses, and document types — straight from the live schema. * **Invoice ⇄ shipment linking is documented**: `POST /api/rest/invoices` accepts the nested `invoiceShipments` relation at create time; the reference now shows its real schema. * **Authentication and error responses are in the spec**: every endpoint documents the `Authorization` API-key scheme and the real flat-JSON `400`/`401` behavior, and the interactive playground offers the **staging server** in its server dropdown. * **Behavioral contracts on the endpoint pages**: where an endpoint has a non-obvious contract — retry safety, delete semantics, pagination defaults, in-`200` business errors — it's stamped onto the generated reference page, linking to the guide that owns the full story. * **Reorganized navigation**: a **Start** tab (conventions, contracts, and planning pages) and a **Build** tab (guides organized by what you're building) replace the single Guides tab, with [Error handling](/api-reference/error-codes) rebuilt around the API's real error strings. * **This changelog is now subscribable** via [RSS](https://docs.upwell.com/changelog/rss.xml). **July 2026** ## Purchase orders and vendor invoices API guide Added a developer guide for **purchase orders and vendor invoices**: upload a PDF via the standalone supporting-doc presigned flow (`PURCHASE_ORDER` / `VENDOR_INVOICE`), poll until parsing creates the record, then list, search, and patch headers and line items. Linked from the introduction, quickstart, and API Reference start-here cards. **July 2026** ## TMS integration guides and AR coverage Added two new developer guides: **Syncing foundation entities** (customers, carriers, shipments, bills) covers the prerequisite data every TMS integration needs, and **Managing customer invoices (AR)** documents the full AR invoice lifecycle — creating invoices, adding line items, attaching documents, and tracking status. Updated the introduction and quickstart with a developer onboarding path. ![Syncing foundation entities developer guide, covering the customers, carriers, shipments, and bills every TMS integration syncs first](https://mintcdn.com/upwell/qzWZWZraAUFa6Lwk/images/syncing-foundation-entities-guide.png?fit=max\&auto=format\&n=qzWZWZraAUFa6Lwk\&q=85\&s=7885e393ba6bf1d07379a88e5db9acda) The Syncing foundation entities guide **July 2026** ## Developer docs and a filtered API reference Launched the Upwell developer docs with a filtered OpenAPI reference generated from the live API, plus the first API guides for carrier invoice submission, status, and approval, shipment documents, customer payments, and webhooks. Added a Core Concepts data model overview so every guide shares one vocabulary. ![Upwell API reference with the interactive playground open on a carrier payment endpoint](https://mintcdn.com/upwell/Dsl239FYTC-PHbSt/images/api-reference-playground.png?fit=max\&auto=format\&n=Dsl239FYTC-PHbSt\&q=85\&s=e1bdca618600bb9b99832f7c399b6ba0) The interactive API reference # How carrier invoices get approved Source: https://docs.upwell.com/concepts/approvals The three ways a carrier invoice is approved — manual review, auto-approval rules, and external request-for-approval — and the exception gate that governs all of them. # How carrier invoices get approved Approving a carrier invoice is the sign-off that it's correct and cleared to pay. This page covers what makes an invoice *ready* to approve, and the three paths it can take to get there. > [!NOTE] > > This is about **carrier invoices** (accounts payable — money out). The customer/AR side has its own "approve & send" step that queues an invoice for delivery — see [Accounts receivable management](/accounts-receivable/receivables). If the AP/AR distinction is fuzzy, start with the [data model](/concepts/data-model). ## Exceptions and approval Upwell audits every carrier invoice against its [bill](/concepts/data-model) and raises [exceptions](/concepts/exceptions) for anything that doesn't line up. How an open exception affects approval **depends on the path**: * **Auto-approval acts only on clean invoices.** An invoice with any open or in-progress exception is excluded outright — as are invoices not yet matched to a bill and a carrier, or missing a total amount. There is no override. * **Manual approval can override open exceptions.** A reviewer may approve despite open exceptions by explicitly overriding them — with one hard limit: a **`CARRIER_PAY_FROZEN`** exception can *never* be overridden and always blocks approval until it's cleared. So an open exception doesn't *categorically* prevent approval: it always blocks auto-approval, and blocks manual approval unless a reviewer chooses to override (and never for carrier-pay-frozen). ## The three ways an invoice gets approved > [card] Manual > > A person reviews the invoice and approves it. > [card] Auto-approval > > Eligible invoices are approved automatically by rules you configure. > [card] External request > > Upwell hands the decision to your integration to resolve. ### 1. Manual approval The default. A reviewer looks at the invoice — its amount, its matched bill, and any exceptions — and approves it. If the invoice still has open exceptions, the reviewer can **override** them to approve anyway (except `CARRIER_PAY_FROZEN`, which must be cleared first). In most tenants, approving moves the invoice's `status` straight to `APPROVED`, which is what kicks off the downstream payables work (see the [carrier-invoice lifecycle](/api-guides/carrier-invoice-status)). > [!NOTE] > > If your tenant hands the final decision to an external system (path 3 below), clicking **Approve** is *not* immediate: instead of setting `APPROVED`, it opens an approval request and the invoice waits for that system to resolve it. The manual review and the external request are two stages of the **same** action, not separate paths. ### 2. Auto-approval If you enable auto-approval in your payables settings, Upwell approves invoices that are **clean** — no open or in-progress exceptions, matched to a bill and a carrier, and with a total amount — and that fall inside the guardrails you set, no clicking required. Auto-approval runs automatically on a regular basis, not the instant an invoice arrives. The guardrails: | Setting | Effect | | - | - | | **Enabled** | Master switch. Off by default — nothing auto-approves until you turn it on. | | **Maximum amount** | Only invoices at or below this amount (in **cents**) auto-approve; anything larger waits for manual review. Leave unset for no limit. | | **Exclude Quick Pay** | When on, Quick Pay carriers are held for manual review even if otherwise eligible. | | **Exclude LTL** | When on, LTL shipments are held for manual review. | > [!WARNING] > > Auto-approval never bypasses the exception gate. An invoice with an open or in-progress exception is **not** auto-approved, regardless of your settings — the **auto-approval job** leaves it alone until the exception is resolved. (A manual reviewer can still override it and approve — except `CARRIER_PAY_FROZEN`.) Auto-approval only ever acts on already-clean, fully-matched invoices. Auto-approval also skips invoices whose customer approves carrier bills outside Upwell. See [Customers that approve carrier bills outside Upwell](#customers-that-approve-carrier-bills-outside-upwell). ### 3. External request for approval For integrations that own the approve/reject decision in their own system, the **Approve** action doesn't finalize the invoice in Upwell — it **opens an approval request** and hands the decision off. This isn't a separate button: in tenants with an external approval integration enabled, it's exactly what clicking **Approve** does. The same readiness checks run first, so the request is governed by the same gate as any other approval: the invoice must be matched to a bill, and an open or in-progress exception still blocks it unless the reviewer explicitly overrides it (and `CARRIER_PAY_FROZEN` blocks it outright, override or not). Only then is the request created — a request never bypasses the exception gate. Your integration then reads the pending request and resolves it: `SUCCEEDED` moves the invoice to `APPROVED`; `FAILED` rejects it. Until it resolves, the invoice stays in its pre-approval state and the **Approve** action shows as in progress. See the developer guide: [Responding to a carrier-invoice approval request](/api-guides/carrier-invoice-approval). Upwell doesn't open a new approval request for an invoice whose customer approves carrier bills outside Upwell. That customer setting applies on top of your tenant's integration, as described in the next section. ## Customers that approve carrier bills outside Upwell You can require a customer's carrier bills to be approved outside Upwell, for example directly in your TMS. Turn on **Approve carrier bills outside Upwell** in the customer's settings under **Rules** > **Carrier Doc Rules**, or set `carrierApprovalBlocked` to `true` with `PUT /api/rest/customers/{id}`. The setting defaults to `false`. The setting applies to carrier invoices matched to a shipment that belongs to that customer. Upwell checks the shipment's current customer each time, including when the customer is archived. Invoices with no matched shipment are not affected. While the setting is on, no new approval starts in Upwell for those invoices: * **Manual approval** is refused. `POST /api/rest/carrier_invoices/{carrierInvoiceId}/approve` returns `success: false` with the error code `CUSTOMER_CARRIER_APPROVAL_BLOCKED`. Overriding exceptions or a hold doesn't waive it. * **Auto-approval** skips the invoices. * **External request for approval** is not started. Upwell doesn't create an approval request for them. Bill-status reconciliation from your TMS and payment progression continue as usual. When the bill is approved outside Upwell, the carrier invoice's status still updates in Upwell. Turning the setting on doesn't cancel approval requests that are already open, so review those before you enable it. If a shipment moves to a different customer, the next approval follows the new customer's setting. For a carrier invoice that is already `APPROVED`, `PART_PAID` or `PAID`, Upwell refuses a user change that moves the invoice to another shipment, or moves its shipment to another customer, when the old or the new customer approves outside Upwell. ## Putting it together **1. Ingest & audit** A carrier invoice arrives, is matched to its bill and carrier, and is audited. Any mismatch becomes an [exception](/accounts-payable/carrier-invoice-audit). **2. Clear (or override) exceptions** Open exceptions are resolved (manually or as the data catches up). Auto-approval waits until they're gone; a manual reviewer can override open exceptions to approve anyway — except `CARRIER_PAY_FROZEN`, which must be cleared first. **3. Approve** The invoice is approved — by a reviewer, by your auto-approval rules, or by your integration resolving an approval request — and moves to `APPROVED`. > [!NOTE] > > To watch these transitions programmatically, use the signals and webhooks in [Knowing when a carrier invoice is processed](/api-guides/carrier-invoice-status). For the objects referenced here — bill, carrier invoice, exception, approval request — see the [data model](/concepts/data-model). # Core concepts & data model Source: https://docs.upwell.com/concepts/data-model The handful of objects Upwell is built around — shipments, invoices, bills, carrier invoices, payments — what each means, how they connect, and the terms people mix up. # Core concepts & data model Upwell sits between your TMS and your money. It has two jobs: * **Accounts receivable (AR) — money in.** Getting your **customers** (shippers) to pay you, quickly. * **Accounts payable (AP) — money out.** Making sure what you pay your **carriers** is accurate. Almost everything in the product is one of a small set of objects. Learn these once and the rest of the docs read easily. ## The objects | Object | ID prefix | Side | What it is | | - | - | - | - | | **Shipment** (load) | `shi_` | — | A freight movement from your TMS. The hub everything else hangs off — it carries a customer and a carrier. | | **Customer** (shipper) | `cus_` | AR | Who you bill and collect from. | | **Carrier** | `car_` | AP | Who hauls the freight and gets paid. | | **Invoice** | `inv_` | AR | What **you bill your customer**. "Invoice" on its own always means this — the customer/AR invoice. | | **Bill** | `bil_` | AP | What your TMS says you **expect to owe a carrier** for a shipment. The *expected* payable. | | **Carrier invoice** | `cari_` | AP | What a **carrier actually billed you** — the document they send. The *received* payable. | | **Document** | `doc_` | both | A file — BOL, POD, rate confirmation, etc. Usually attached to a shipment, invoice, or carrier invoice, but a purchase order or vendor invoice can also be uploaded **standalone**, with no pre-existing entity to associate it with. See [Purchase orders and vendor invoices](/api-guides/purchase-orders-and-vendor-invoices). | | **Address** | `addr_` | both | A **typed** physical address (pickup, consignee, customer billing, etc.) attached to a parent — a shipment, customer, carrier, company, or contact. A per-owner record, **not** a globally shared entity. See [Addresses](#addresses). | | **Customer payment** (remittance) | `pym_` | AR | Money received from a customer, split into line items that apply to invoices. | | **Bill payment** | `blp_` | AP | A payment that settles what you owe a carrier, split into line items that apply to bills — the same shape as a customer payment, mirrored on the AP side. There's no direct bill payment → bill link; it always runs through the line items. | | **Company** | `comp_` | — | Your own branding/legal-entity record (not an external company) — the entity name, logo, and contact details a shipment or address can carry when you operate multiple divisions or legal entities under one tenant. | | **Vendor** | `ven_` | AP | A payable party that isn't a hauling carrier — a lumper service, a factor, a non-freight supplier. A bill is owed to *either* a carrier *or* a vendor. | Two more terms come up constantly but aren't objects you create directly — Upwell derives them: * **Exception** — a flagged audit finding on an invoice: a mismatch, a missing document, or a failed match. Exceptions arise on **both** sides — carrier invoices (AP) and customer invoices (AR). See [Exceptions](/concepts/exceptions). * **Approval request** — a pending decision on a carrier invoice, awaiting sign-off before Upwell proceeds. See [how approvals work](/concepts/approvals) and [responding to an approval request](/api-guides/carrier-invoice-approval). ## How they connect ```mermaid theme={null} flowchart LR subgraph AR["Accounts receivable — money in"] Customer["Customer (shipper)
cus_"] Invoice["Invoice
inv_"] Payment["Customer payment
pym_"] Customer -->|is billed on an| Invoice Payment -->|applies to| Invoice end subgraph AP["Accounts payable — money out"] Carrier["Carrier
car_"] Bill["Bill — expected
bil_"] CarrierInvoice["Carrier invoice — actual
cari_"] BillPayment["Bill payment"] Carrier -->|is owed on a| Bill Carrier -->|sends a| CarrierInvoice Bill -.->|audited against| CarrierInvoice BillPayment -->|line items apply to| Bill end Shipment["Shipment / load
shi_"] Shipment --> Customer Shipment --> Carrier ``` A shipment ties the two sides together: the same load you **invoice a customer for** (AR) is the load a **carrier bills you for** (AP). ## Addresses Addresses are the one object people most often model wrong, so it's worth being explicit: **an address is not a globally shared, deduplicated entity the way a customer or a carrier is.** A customer (`cus_`) or carrier (`car_`) represents a business entity that integrations generally retain and reference by ID. Addresses do **not** represent a shared physical-place identity in that way. An **address** (`addr_`) is a **typed snapshot associated with the record that uses it**: * Each address carries a **`type`** describing the role it plays, and it is **required** — there's no default. Two types are load-bearing and must be exact: **`CUSTOMER_BILLING`** (what the invoice bill-to block and delivery routing read) and **`COMPANY_ADDRESS`** (the only type a company page will display). `SHIPMENT_PICKUP` and `SHIPMENT_CONSIGNEE` fill a shipment's origin/destination slots. `CARRIER`, `CARRIER_BILLING`, `CONTACT` and `STOP` are descriptive. **`ADDRESS_BOOK` is inert** — nothing reads it, so it is not a safe generic default. The same party can hold several rows (a customer's billing address and its dock address are two). * Each address describes a particular use — for example, a shipment pickup or consignee, a customer billing location, a company address, or a contact address. It is created **in that context**, not looked up from a shared pool. * There is **no automatic dedup at the address level.** The same physical location on two different shipments is **two separate `addr_` rows**. Two customers at the same building have two address records. This is expected — and it's usually what trips up integrations that assume one ID per real-world place. * **Addresses have no `sourceSystem` / `sourceSystemId` pair** — unlike every other resource in this table. There is no upsert-by-external-key for an address; you must store and track the Upwell `addr_` id yourself for every address you create. > [!WARNING] > > If you're keeping your own records straight against Upwell, key off the **parent object and the address `type`** (e.g. "the `SHIPMENT_CONSIGNEE` address on shipment `shi_…`"), **not** off an assumption that a given physical address always maps to one stable address ID. It doesn't. > [!NOTE] > > For the mechanics — creating a record with its address, adding one later, updating it, and which direction the link runs for each parent type — see [Working with addresses](/conventions/addresses). ### Canonical addresses — where dedup actually happens The "one global ID per real place, with a key to prevent duplicates" idea **does** exist in Upwell — just one layer down, and not as an object you create or reference directly. A **canonical address** (`can_`) is a normalized, **cross-tenant** record keyed by a verification key from our address-verification provider (Smarty). It's upserted on that key, so repeated matches for the same verified US address resolve to the **same** canonical record — that's the deduplication. An `addr_` record can carry a **`canonicalAddressId`** pointing at its canonical match. > [!WARNING] > > **In practice, don't expect to see this populated.** Assume `canonicalAddressId` is unset on any address you create: it is effectively never set on `CARRIER`, `CARRIER_BILLING`, `CUSTOMER_BILLING`, or any type besides `SHIPMENT_PICKUP`/`SHIPMENT_CONSIGNEE` — and not reliably even there. The real driver is the customer **location codes** feature (named pickup/delivery locations a customer configures): almost every canonicalized address traces back to a location-code match, not general address processing. Canonicalization is a byproduct of that narrow, opt-in feature, not something that runs against the addresses a typical integration creates. Canonical addresses are an **internal normalization and matching aid**, not a first-class API resource. The API may expose an address's `canonicalAddressId`, but integrations should treat it as system-maintained metadata rather than a stable identifier they manage themselves. Matching is **US-only and best-effort** — a non-US or unverifiable address simply has no canonical match. ## Four pairs people mix up > [accordion] Address vs. canonical address > > * An **address** (`addr_`) is a **typed, per-owner snapshot** — the pickup on *this* shipment, the billing address on *that* customer. The same physical place used in two spots is two separate address rows; there's no global dedup at this level. > * A **canonical address** (`can_`) is the normalized, cross-tenant record keyed by an address-verification key — *this* is the deduplicated "one ID per verified place." It's an internal matching aid; integrations should treat `canonicalAddressId` as system-maintained metadata. See [Addresses](#addresses). > [accordion] Bill vs. carrier invoice > > Both are on the payables side, and this is the one that trips people up most. > > * A **bill** (`bil_`) is what your **TMS** says you *should* owe a carrier — the **expected** amount. > * A **carrier invoice** (`cari_`) is what the **carrier** *actually* sent you — the **received** amount. > > Upwell's core AP job is auditing the carrier invoice **against** the bill. When they don't agree, that difference becomes an [**exception**](/accounts-payable/carrier-invoice-audit). > [accordion] Invoice vs. carrier invoice > > Same word, opposite directions of money: > > * An **invoice** (`inv_`) is **you billing your customer** — accounts *receivable*, money **in**. > * A **carrier invoice** (`cari_`) is a **carrier billing you** — accounts *payable*, money **out**. > > Throughout the docs and API, an unqualified "invoice" always means the customer/AR invoice. > [accordion] Customer vs. carrier > > * Your **customer** (`cus_`) is the **shipper** — they pay *you* (AR). > * Your **carrier** (`car_`) is who you hire to move the freight — you pay *them* (AP). ## How money moves **1. Receivables — collecting from customers (money in)** A shipment produces an **invoice** to the **customer**. When they pay, that arrives as a **customer payment** whose line items apply to the invoices it covers. See [Recording customer payments](/api-guides/customer-payments) and [Accounts receivable management](/accounts-receivable/receivables). **2. Payables — paying carriers accurately (money out)** Your TMS provides a **bill** — what you expect to owe the **carrier**. The carrier sends a **carrier invoice**; Upwell audits it against the bill and flags **exceptions** for any mismatch. Once it's approved, a **bill payment** settles it, its line items applying to the bill(s) it covers — the same pattern as a customer payment on the AR side. See [Carrier invoice audit](/accounts-payable/carrier-invoice-audit) and [Submitting carrier invoices via API](/api-guides/carrier-invoice-submission). > [!NOTE] > > This page defines the core money-flow objects; the guides go deeper on each. For every other term — freight jargon (accessorial, lumper, SCAC, LTL), AP/AR terms (aging, remit-to, factoring), and other objects (stop, rule, document reference specification) — see the [glossary](/concepts/glossary). For the exact fields and endpoints, the [API Reference](/api-reference/introduction) is generated from the API schema. # How documents flow through Upwell Source: https://docs.upwell.com/concepts/document-lifecycle Where documents come from, how they get classified and attached, who can see them, and how they leave — the lifecycle of a POD, BOL, rate confirmation, or invoice PDF. # How documents flow through Upwell Documents — PODs, bills of lading, rate confirmations, carrier invoices, invoice PDFs — move through a consistent lifecycle no matter how they arrive: **in → classified → attached → shared → out**. This page is the conceptual map; the [shipment documents guide](/api-guides/shipment-documents) covers the API. ## 1. How documents come in | Source | What happens | | - | - | | **Inbound email** | Attachments on emails to your Upwell inbound addresses are ingested automatically, then grouped and classified (below). | | **API upload** | You attach bytes directly — base64 for smaller files, or a two-step presigned URL for large ones. See [shipment documents](/api-guides/shipment-documents) and [integration patterns](/conventions/documents#document-upload-two-step-presigned-url). | | **Integration sync** | Documents pulled from a connected TMS or portal during sync. | | **Generated** | Upwell renders some documents itself — most notably the **customer-invoice PDF**, generated for an AR customer invoice. That PDF then travels with the invoice at delivery (the outbound step below). | ## 2. Classification An incoming document doesn't yet know what it is. Upwell classifies it — automatically for emailed/parsed documents, or from the `type` you supply on API upload — assigning a **document type** (POD, BOL, rate confirmation, carrier invoice, and so on) drawn from your account's available document types. > [!NOTE] > > Until a document is classified, its `type` reads as `UNKNOWN`. Over the API that's the signal that classification is still in flight — treat a document still `UNKNOWN` past your timeout as *needs manual review*, not a hard failure. See [Knowing when a carrier invoice is processed](/api-guides/carrier-invoice-status). > [!WARNING] > > When writing a document's `type` via the API, use the **canonical type code**, not its display label — e.g. `PROOF_OF_DELIVERY`, where `POD` is only the label. The [shipment documents guide](/api-guides/shipment-documents) covers this. ## 3. Attachment A classified document is linked to the record it belongs to — a **shipment** (the load), a **carrier invoice** (AP), or a **customer invoice** (AR). The same underlying file can be associated with more than one record; removing an association detaches the document from that record without destroying the file. The [data model](/concepts/data-model) covers these objects. > [!NOTE] > > A required document that's missing surfaces as an [exception](/concepts/exceptions) (e.g. *Missing POD*), which can hold up [approval](/concepts/approvals) until it's resolved. ## 4. Visibility Two independent flags control who can see a document when it's shared: * `visibleToCarrier` — whether it's exposed to the carrier. * `visibleToCustomer` — whether it's exposed to the customer. They're set when you attach a document and can differ per document, so a shipment can hold a mix of internal-only and shared files. ## 5. How documents go out * **Customer delivery (AR).** When a customer invoice is delivered, its supporting documents go with it — by email, EDI, or portal, per the customer's configuration. See [Accounts receivable management](/accounts-receivable/receivables). * **Integration push (AP & AR).** Documents can be pushed back to a connected TMS/portal through a retriable, persisted upload queue, so a transient failure retries rather than dropping the document. > [!NOTE] > > This page is the conceptual overview. To actually list, add, or remove a shipment's documents over the API, see [Retrieving and managing shipment documents](/api-guides/shipment-documents). To submit a carrier invoice with its documents, see [Submitting carrier invoices via API](/api-guides/carrier-invoice-submission). # Exceptions Source: https://docs.upwell.com/concepts/exceptions What an exception is, the lifecycle it moves through, the common types, and how open exceptions hold an invoice back from approval. # Exceptions An **exception** is an audit finding — Upwell's way of flagging that something about an invoice doesn't line up and a person should look at it. Exceptions are what stand between an invoice and approval: a clean invoice sails through, one with an open exception waits. ## What raises an exception Every invoice is audited as it's ingested and matched. On the payables side that means checking a [carrier invoice](/concepts/data-model) against its [bill](/concepts/data-model); on the receivables side it means checking a customer invoice against what's required to send it. Anything that doesn't reconcile — a mismatch, a missing document, a failed match — becomes an exception. > [!NOTE] > > Exceptions exist on **both sides**. Carrier-invoice (AP) exceptions like a total-amount mismatch or a missing POD, and customer-invoice (AR) exceptions like a missing invoice copy or BOL, are both surfaced the same way. The audit rules that generate them are configurable per account, so the exact set an account sees varies. ## The lifecycle (The [Vocabulary](/api-reference/vocabulary#exception-statuses) page carries this list in its generated form.) An exception moves through a small set of statuses: | Status | Meaning | | - | - | | `OPEN` | Raised but not yet addressed — needs attention. | | `IN_PROGRESS` | Someone is actively working it. | | `RESOLVED` | Worked and resolved. | | `CLOSED` | Closed; no further action needed. | | `RULE_DISABLED` | Suppressed because the audit rule that generated it was turned off. | `OPEN` and `IN_PROGRESS` are the two "still needs attention" states — they're what hold an invoice back. The rest mean the finding is no longer standing in the way. ## Common exceptions A representative sample of what Upwell flags (not exhaustive — the active set depends on your account's audit rules): | Category | Examples | | - | - | | **Matching** | No matching shipment · No matching bill · Carrier mismatch · Container mismatch · Missing customer | | **Amounts** | Carrier-invoice total-amount mismatch · Rate mismatch · Remit-to mismatch | | **Missing documents** | Missing carrier invoice · Missing POD · Missing rate confirmation · Missing lumper receipt · Missing delivery signature · Missing required document · (AR) missing invoice copy / BOL | | **Document quality** | Document not legible · Document load-number mismatch · BOL/PO number mismatch · Missing invoice number · Missing invoice issue date | | **Holds & status** | TMS status mismatch · **Carrier Pay Frozen** · Shipment on hold (AP) and Shipment On Hold in TMS (AR), raised by a [shipment hold](/api-guides/syncing-foundation-entities#holding-a-shipment) | ### Customer-required documents Some customers require specific documents, such as a scale ticket, before a carrier invoice for their loads is approved. The list of required document types is configurable per customer. When a carrier invoice for that customer lacks one of those types, Upwell raises a **Missing required document** exception (`CARRIER_INVOICE_MISSING_REQUIRED_DOCUMENT`) that names each missing type. A required document counts as present when it's attached to the carrier invoice itself or to its load (shipment). A scale ticket and a weight ticket satisfy each other. When you add, remove, or reclassify a document on the load, Upwell re-evaluates the carrier invoices on that load that aren't yet approved or paid, so attaching the missing document through [shipment documents](/api-guides/shipment-documents) clears the exception without a change to the invoice. ### Container mismatch When the **Verify container number** rule is on for your workspace, Upwell compares the container numbers on a carrier invoice with the load's container number. If the invoice names any container that isn't the load's, Upwell opens a **Container mismatch** exception (`CARRIER_INVOICE_CONTAINER_NUMBER_MISMATCH`). The exception has one detail per extra container, and each detail names both the invoice's container and the load's. Upwell ignores spaces, dashes and letter case when it compares the numbers. An invoice container counts only when it has a valid ISO 6346 check digit, so a misread number that fails the check digit doesn't raise the exception. Invoice references labelled as pickup, return or empty containers are skipped. Loads with no container number, such as non-drayage loads, and invoices that name no container aren't checked. ## How exceptions affect approval Open and in-progress exceptions are the gate on approval — but the exact rules differ by side: **Carrier invoices (AP):** * **Auto-approval** skips any carrier invoice with an open or in-progress exception entirely — no override. * **Manual approval** can override open exceptions to approve anyway — with one exception: **Carrier Pay Frozen** can never be overridden and must be cleared first. **Customer invoices (AR):** * Approval can likewise proceed over open exceptions with an explicit override, but there's no Carrier Pay Frozen carve-out (that's a payables hold). There's no carrier-invoice-style auto-approval on the AR side. * **Critical exceptions** can't be overridden. While a customer invoice has an open or in-progress exception with `CRITICAL` severity, Upwell refuses to approve, send, or schedule it, even with `overrideExceptions=true`. Approving it returns the `CRITICAL_EXCEPTIONS` error code with the message `Invoice cannot be approved until critical exceptions are resolved.` Resolve the critical exception first. The refused approval changes nothing, so the invoice's other open exceptions stay open too. Delivery exceptions, which record a failed send that Upwell is still retrying, don't block approval even when marked critical. * **Warnings** from a warn-only [shipper rule](/conventions/rules#warn-instead-of-block) (`CUSTOMER_INVOICE_WARNING`) never block approval or sending, and need no override. Approval leaves them open; they resolve when the rule passes or someone closes them. > [!NOTE] > > For the approval paths in full — manual, auto-approval, and the external request-for-approval — see [How carrier invoices get approved](/concepts/approvals); for the lifecycle and API signals, see [Knowing when a carrier invoice is processed](/api-guides/carrier-invoice-status). Over the API, a carrier invoice exposes its open findings as the `exceptions` field — a **comma-joined string** (e.g. `"INVOICE AMOUNT MISMATCH"`), empty when clean. > [!WARNING] > > Don't judge `exceptions` until **ingestion has run**. A brand-new invoice always shows matching findings ("no matching shipment / bill") that clear on their own once matching completes — see the [lifecycle guide](/api-guides/carrier-invoice-status). > [!NOTE] > > For how exceptions are surfaced and worked in the app, see [Carrier invoice audit](/accounts-payable/carrier-invoice-audit). For the objects referenced here, see the [data model](/concepts/data-model). # Glossary Source: https://docs.upwell.com/concepts/glossary Every Upwell, freight, and AP/AR term you will run into — in plain language, with links to the pages that go deeper. # Glossary Upwell sits at the intersection of freight, accounts payable, and accounts receivable, so the vocabulary comes from all three. This page defines the terms and objects that come up across the product and the API — in plain language. For the money-flow objects and how they connect, start with the [data model](/concepts/data-model); this page is the wider dictionary. > [!NOTE] > > Terms are grouped by where they come from — the **objects**, then **freight & logistics**, **accounts payable / receivable**, **Upwell product concepts**, and **developer conventions**. Within each group they're roughly ordered by how often you'll meet them. ## Objects The core money-flow objects — **shipment, customer, carrier, invoice, bill, carrier invoice, document, address, customer payment, bill payment, company, vendor** — are defined on the [data model](/concepts/data-model) page. A few more objects show up in the API and the app that the data model doesn't cover: | Object | What it is | | - | - | | **Vendor** | A party you owe money that isn't necessarily a hauling carrier — a lumper service, a factor, a utility, a non-freight supplier. A [bill](/concepts/data-model) is owed to *either* a **carrier** *or* a **vendor**: the API exposes both `carrierId` and `vendorId`, and only one is set. Where a carrier carries freight identifiers (SCAC, DOT#, MC#), a vendor is a lighter record — mostly a name and where it came from. A vendor has **no soft-delete**: deleting one is permanent, and it fails outright if any bill still references it. It is a narrow, lightly-exercised object — non-carrier payables belong here, but validate that it fits your case before building on it, and don't expect the field depth or lifecycle surface a carrier has. | | **Company** | **Your own** branding/legal-entity record — not an external company or customer/carrier-style CRM object. It represents a division or legal entity *you* operate under one tenant (seeded from your account's own company info), and other objects like addresses and shipments can reference it when you need to say which of your own entities a record belongs to. | | **Stop** | A single point on a shipment's route — a pickup, delivery, terminal, cross-dock, fuel stop, and so on. A shipment has an ordered list of stops (each with a sequence number, an address, and often an appointment). A stop has **two separate type-ish fields**: `stopType` (free text) and `type` (a constrained enum). Both are read, by different surfaces, and `type` is unset on a substantial share of TMS-sourced stops — so populate both, and when reading `type`, handle null rather than assuming it is present. The [Vocabulary](/api-reference/vocabulary#stop-types) defines the enum values. Deleting a stop's shipment deletes the stop too (cascade); deleting a stop's address does **not** cascade — it's blocked instead if the address is still referenced. See **appointment type** below. | | **Line item** | One priced row on an invoice, bill, or payment — e.g. a line haul charge, a fuel surcharge, or an accessorial. On invoices and bills the line items sum to the total; on a **customer payment** they need not — a remittance can be partially applied, so the applied line items may total less than the amount received. Invoices, bills, and payments each have their own line-item type. **Shipment line items are the exception** — see below. | | **Shipment line item** | Cargo/freight metadata on a shipment (commodity description, NMFC class, handling-unit and package quantities, weight, hazmat flag) — **not** a priced row like the other line-item types. It carries no rate, amount, or charge field at all. | | **Payment line item** | How a single [customer payment](/api-guides/customer-payments) splits across the invoices it pays — one line item per invoice the money is applied to. This is what makes cash application work when one check covers many invoices. | | **Carrier payment line item** | The AP counterpart to a payment line item — how a single [bill payment](/concepts/data-model) splits across the bills it settles. Exposed over the API as `carrier_payment_line_items`; despite the public name it shares its underlying table with bill payments, and only `bill_payment_id`, not `bill_id` alone, is the true link to the payment that made it — see [Recording carrier payments](/api-guides/carrier-invoice-submission#recording-carrier-payments). There is no `GET`/list endpoint for the analogous **bill line item** (a bill's own priced rows) — only create/update/delete. | | **Rule** | A configurable if-this-then-that instruction Upwell evaluates during processing — to require a document, raise an [exception](/concepts/exceptions), route by SCAC, or set the customer. Rules are how each account tailors the audit and matching to its own policies. A rule can be scoped to one customer or left tenant-wide, has a `priority` for ordering, and a real `enabled` toggle — disabling is preferred over deleting since deletion is permanent. Depending on the rule's type, it's configured through a small DSL expression pair, through `actionType`/`actionValue` alone, or (legacy, not what to build against) structured criteria fields. See [Rules: three shapes, not two](/conventions/rules). | | **Document reference specification** | A per-customer (or tenant-wide, if unscoped) configuration record that defines what a reference number should look like — a name, plus regexes for validating its format and label. Used to validate/find-or-create reference numbers like a portal-generated invoice number against a known pattern. A niche configuration object tied to specific portal integrations — most integrations will not need it. | | **Address** | A **typed** physical-address snapshot (billing, pickup, consignee, and so on) associated with the record that uses it, so one party or shipment can have several. It is **not a globally deduplicated entity**: the same physical place on two shipments is two address records. Cross-tenant matching lives one layer down in a **canonical address**; integrations should treat its `canonicalAddressId` as system-maintained metadata. See [Addresses on the data model page](/concepts/data-model#addresses). | | **Approval request** | A pending decision on a [carrier invoice](/concepts/data-model) that Upwell hands to an external system to resolve. See [how approvals work](/concepts/approvals). | ## Freight & logistics | Term | Plain-language meaning | | - | - | | **Shipment (load)** | One freight movement from origin to destination. In Upwell, the hub that invoices, bills, and documents hang off. "Load" is the same thing. | | **Shipper** | The party whose freight is being moved — in Upwell this is your **customer** (the one you bill). "Customer" and "shipper" are used interchangeably. | | **Mode** | How the freight moves. Common values: **LTL** (less-than-truckload — you share a trailer and pay for part of it), **TL / FTL** (truckload / full truckload — you take the whole trailer), and **INTERMODAL** (rail + truck). | | **Line haul** | The base charge for moving the freight from A to B, before any extras. | | **Accessorial** | Any charge on top of the line haul — detention, lumper, liftgate, fuel surcharge, layover, and the like. | | **Lumper** | A third party paid to load or unload a trailer (common at warehouses/grocery DCs). A **lumper receipt** proves the charge; a carrier invoice with a lumper line item but no receipt raises an exception. | | **Detention** | A charge for a truck kept waiting beyond the free time allowed to load or unload. | | **TONU** | "Truck Ordered, Not Used" — a fee when a carrier is booked and shows up but the load is cancelled. | | **Layover** | A charge when a driver has to wait overnight (or longer) between pickup and delivery. | | **Appointment type** | How a stop's timing works: **APT** (a scheduled appointment window) or **FCFS** ("first come, first served" — no appointment, handled in arrival order). | | **Freight charge terms** | Who owes the freight charge and when — e.g. **prepaid** (shipper pays), **collect** (consignee pays), or third-party billing. | | **Owner-operator** | A carrier that is a single driver who owns their truck, rather than a larger fleet. | | **BOL (bill of lading)** | The contract/receipt for a shipment, issued when freight is picked up. Lists what's being shipped, from and to whom. | | **POD (proof of delivery)** | A signed document confirming the freight was delivered. Over the API its document type code is `PROOF_OF_DELIVERY` (`POD` is only the display label). | | **Rate confirmation** | The document that confirms the agreed rate for a load. Upwell distinguishes a **carrier** rate confirmation (what you owe the carrier — payables) from a **customer** rate confirmation (what you charge the customer — receivables). | | **SCAC** | Standard Carrier Alpha Code — a short code identifying a carrier. Upwell uses it to match carrier invoices that reference a SCAC instead of a name. | | **DOT number** | The carrier's U.S. Department of Transportation registration number. | | **MC number** | Motor Carrier number — a carrier's FMCSA operating-authority number. | | **DUNS number** | A Dun & Bradstreet business identifier, used to identify a company. | | **PRO number** | The carrier's tracking number for a shipment (from the carrier's own system). Upwell treats it as one of the strongest keys for matching a carrier invoice to a shipment. | | **Lane** | An origin–destination pair a carrier runs (e.g. Chicago → Dallas). Used in reporting to compare cost and volume by route. | ## Accounts payable & receivable | Term | Plain-language meaning | | - | - | | **AR (accounts receivable)** | Money **in** — getting your customers (shippers) to pay you. | | **AP (accounts payable)** | Money **out** — paying your carriers and vendors accurately. | | **Receivable** | An amount a customer owes you (a customer invoice). | | **Payable** | An amount you owe a carrier or vendor (a bill). | | **Aging** | How long a receivable has been outstanding, bucketed by age (e.g. 0–30, 31–60, 61–90 days). Drives collections priority and reminder timing. | | **Dunning** | The sequence of increasingly firm reminders sent to collect an overdue invoice. See [payment reminders](/accounts-receivable/reminders). | | **Cash application** | Matching an incoming payment to the open invoices it pays, then marking those invoices paid. See [recording customer payments](/api-guides/customer-payments). | | **Remittance** | A notification of payment — the record of what a customer sent and which invoices it's meant to cover. In everyday use it's spoken of interchangeably with a **customer payment** (`pym_`). If you build against the API, note that webhooks also expose a distinct lower-level `remittance` resource (with its own line items) that can arrive separately — e.g. over EDI — from the applied customer payment; treat them as related but separate streams. | | **Short pay** | When a customer pays less than the invoiced amount, leaving a balance to resolve. | | **Write-off** | Formally giving up on collecting a balance and closing it off the books (invoice status `WRITE_OFF`). | | **Reconciliation** | Confirming that recorded payments and balances agree with the money that actually moved (e.g. against a bank feed). | | **Credit limit** | The maximum outstanding balance you'll extend to a customer before requiring payment. | | **Payment terms** | How long a customer has to pay, e.g. **Net 30** (due 30 days after issue). Drives aging and reminder scheduling. | | **ACH** | Automated Clearing House — an electronic bank-to-bank transfer, a common way customers pay and carriers get paid. | | **Quick Pay** | An arrangement where a carrier is paid faster than standard terms, usually for a small fee or discount. Carriers can be flagged as Quick Pay, and auto-approval can be set to exclude them. | | **Factoring** | When a carrier sells its receivables to a third party (a **factor**) who then gets paid instead of the carrier. Signaled by a **Notice of Assignment** (`NOTICE_OF_ASSIGNMENT`) document and reflected in the invoice's **remit-to**. | | **Remit-to** | Where a payment should actually be sent — which can differ from the carrier when a factor is involved. A remit-to mismatch is a common audit exception. | ## Upwell product concepts | Term | Plain-language meaning | | - | - | | **Tenant** | One customer organization's isolated space in Upwell. An API key or an app session can only read and write its own organization's records; "per-tenant" means a setting or behavior applies to just that organization. Two things sit above the tenant boundary by design: a small number of internal normalization tables (canonical addresses) and Upwell staff administration. Neither is reachable with tenant credentials — see [canonical addresses](/concepts/data-model#addresses). | | **Foundation entities** | The prerequisite records a TMS integration syncs first — **customers, carriers, shipments, and bills** — before invoices and documents can be matched to them. See [syncing foundation entities](/api-guides/syncing-foundation-entities). | | **Exception** | An audit finding that flags something needing attention before an invoice can be approved. See [exceptions](/concepts/exceptions). | | **Matching** | Linking an incoming carrier invoice to the right shipment, carrier, and bill so it can be audited. Until matching runs, a new invoice shows "no matching" findings that clear on their own. | | **Ingestion** | The first processing phase — a document/invoice arrives, is classified, matched, and audited — as distinct from the later review-and-approval phase. See [the carrier-invoice lifecycle](/api-guides/carrier-invoice-status). | | **Auto-approval** | Rules that approve clean, in-guardrail carrier invoices with no human clicking. See [approvals](/concepts/approvals). | | **Needs Review** | The work queue in the app for carrier invoices that aren't cleared yet — where reviewers work exceptions and approve. | | **Portal** | Two different things share this word: **(1) the customer portal** — the self-service page where your customers view and pay their invoices (AR); and **(2) audit-and-payment portals** — third-party systems like **Cass**, CTSI, or MercuryGate that some shippers require carrier invoices to be submitted through and that send status back (AP). | | **CASS (Cass Information Systems)** | A large third-party freight-bill audit-and-payment provider. Some shippers pay through Cass, so Upwell can submit to and read invoice status from the Cass portal, and can match a customer by their Cass ID. | | **Breakthrough Fuel** | A third-party fuel-price/fuel-recovery provider. Upwell ingests fuel data batches from Breakthrough Fuel; over webhooks these appear as `btf_batch` events. | | **EDI** | Electronic Data Interchange — a standardized format for exchanging business documents (invoices, remittances, status) between systems, used by many shippers and portals. | | **Integration / source system** | An external system connected to Upwell (a TMS, a portal, an API client). Every synced record is stamped with the `sourceSystem` it came from. See [developer conventions](#developer-conventions). | | **Feature flag** | A per-organization switch that turns a section or capability on or off, so what one account sees can differ from another. | | **Roles** | Who can do what in the app: **Team Member** (`ORGMEMBER`, day-to-day work), **Cash Application** (`ORGCASHAPP`, payment matching and reconciliation), **Manager** (`ORGADMIN`, user and workflow configuration), and **Admin** (`ORGOWNER`, full control including billing and role changes). Upwell support staff additionally hold an internal administrative role that operates across organizations; it is not assignable within yours. See [user roles](/user-interface/user-roles). | | **Trevor** | The embedded third-party business-intelligence tool behind the analytics dashboard — deeper reporting inside the app, no separate login. | ## Developer conventions These come up throughout the API. Each is covered in depth on the linked page — they're here so the vocabulary is in one place. | Term | Plain-language meaning | | - | - | | **Integer cents** | All money is sent and returned as whole cents — `$2,847.50` is `284750`. No decimals, no currency symbols. See the [quickstart](/quickstart). | | **`sourceSystem` / `sourceSystemId`** | Your external identity / uniqueness key — a constant string naming your system plus your own primary key for the record, unique per tenant, tying an Upwell record back to yours. It is **not** a general upsert: `POST` a record once, then `PUT` to update it; re-`POST`ing the same pair is rejected as a `400 Uniqueness violation` on most resources. **Carrier invoices behave differently, not simply "async instead of sync"** — the duplicate is created and briefly live under its own id before an asynchronous pass soft-deletes it, and the dedup key isn't integration-scoped. See [Re-submitting](/api-guides/carrier-invoice-submission#re-submitting) before relying on this for retries. See [integration patterns](/integration-patterns) for the per-endpoint retry/update semantics generally. | | **ID prefixes** | Every Upwell ID is prefixed by its type — e.g. `shi_` shipment, `cus_` customer, `car_` carrier, `inv_` invoice, `bil_` bill, `cari_` carrier invoice, `doc_` document, `file_` file, `fias_` file association, `addr_` address, `can_` canonical address, `pym_` customer payment, `pli_` payment line item, `blp_` bill payment, `comp_` company, `ven_` vendor, `drs_` document reference specification. See the [data model](/concepts/data-model). | | **Presigned URL** | The two-step way to upload a large file: ask Upwell for a short-lived upload URL, then PUT the bytes to it. See [integration patterns](/conventions/documents#document-upload-two-step-presigned-url). | | **Standardized code sets** | Currency codes (ISO 4217), country codes (ISO 3166), and the EDI accessorial, handling-unit, and weight-unit code lists are large industry-standard sets — the exact allowed values are in the [API Reference](/api-reference/introduction) rather than enumerated here. | > [!NOTE] > > Something missing that you had to look up? That's a gap worth closing — the goal is that no one has to ask what a term means. For the objects and how money moves between them, the [data model](/concepts/data-model) is the place to start. # Connect your AI assistant to Upwell Source: https://docs.upwell.com/connect-ai-assistant Install Upwell from the Claude directory or configure a remote MCP connection to look up freight billing records in your workspace. Use your assistant to look up an invoice, check a payment, or find a shipment's proof of delivery. The Upwell connector gives it read-only access to records your Upwell account can see. You'll need an active Upwell Admin, Manager, Team Member, Cash Application, or system administrator account in a workspace with MCP access enabled. If Upwell says your organization doesn't have access, contact [Upwell support](mailto:support@upwell.com). ## Claude 1. Open [Upwell in the Claude directory](https://claude.ai/directory/upwell). You can also search for **Upwell** in Claude's connector directory. 2. Select **Connect**. If your organization manages connectors and Upwell is unavailable, ask a workspace administrator to enable the directory connector, then return to the listing. 3. Sign in to Upwell. Check that the consent screen shows the expected app, account, and workspace, then select **Allow Access**. 4. Open a Claude chat, enable Upwell in the connectors menu, and try the invoice lookup below. ## Manual setup Use this server URL wherever your assistant asks for an MCP endpoint. It connects to your workspace over **Streamable HTTP**. ```text theme={null} https://app.upwell.com/api/mcp ``` > [tab] ChatGPT > > 1. Open [Plugins in ChatGPT](https://chatgpt.com/plugins) on the web. Select **+ → Add custom MCP server**. On Business, an owner or administrator creates the connection. On Enterprise or Edu, ask a workspace administrator for access if the option is unavailable. > 2. Enter `Upwell` as the name and `Look up freight billing records` as the description. Under **Connection**, choose the public HTTPS endpoint and paste the server URL above. > 3. Choose **OAuth**. Leave optional client ID and client secret fields empty so ChatGPT can discover the sign-in settings. Review the warning, acknowledge it, and select **Create as a plugin**. > 4. Sign in to Upwell when prompted, check the account and workspace, and select **Allow Access**. Review the discovered tools and install the plugin. Start a new chat and type `@Upwell` to select it. > > [ChatGPT setup guide](https://developers.openai.com/plugins/deploy/connect-chatgpt) > [tab] Grok > > 1. Open [Grok Connectors](https://grok.com/connectors). For personal setup, select **New Connector → Custom** and paste the Upwell server URL above. > 2. For Grok Business or Enterprise, a team administrator first selects the team in the xAI console, opens **Grok Business → Connectors → + Add Connector**, chooses **Other**, and enters the same server URL. > 3. In a managed team, open the connector your administrator added on your own Grok Connectors page. Each member authorizes their own Upwell account. > 4. Follow the sign-in prompt, confirm your Upwell account and workspace, and select **Allow Access**. Open a Grok conversation and try the lookup below. > > [Grok connector setup](https://docs.x.ai/grok/connectors) · [Team administrator steps](https://docs.x.ai/grok/connector-management) > [tab] VS Code > > 1. Open the Command Palette and run **MCP: Add Server**. > 2. Choose **HTTP**, paste the server URL above, and enter `upwell` as the server ID. Choose your personal or global configuration when prompted. > 3. Open **MCP Servers** in chat customizations and start **upwell** if prompted. Review the trust prompt, sign in to Upwell, confirm the workspace, and select **Allow Access**. > 4. In an agent chat, enable the Upwell tools in the tool picker and try the lookup below. > > [VS Code MCP setup](https://code.visualstudio.com/docs/agent-customization/mcp-servers) > [tab] Gemini CLI > > 1. On a computer where you can complete browser sign-in, run the following in a terminal. > > ```bash theme={null} > gemini mcp add --scope user --transport http upwell https://app.upwell.com/api/mcp > ``` > > 2. Start Gemini CLI. At its prompt, enter `/mcp auth upwell` if it asks you to authenticate. > > 3. Sign in to Upwell, confirm the workspace, and select **Allow Access**. Back in Gemini CLI, enter `/mcp list` to see the connected server before running the lookup below. > > [Gemini CLI MCP setup](https://geminicli.com/docs/tools/mcp-server/) > [tab] Cursor desktop > > These steps use an Upwell API key. You'll need access to **Account → API keys** in Upwell. The MCP tools are read-only, but the key can also authenticate to other Upwell API endpoints. > > 1. Create a dedicated key for Cursor using the [Upwell API key instructions](/authentication). Store it in the environment variable `UPWELL_API_KEY` and launch Cursor with that variable available to it. > > 2. Open your personal Cursor configuration at `~/.cursor/mcp.json`. For a new file, use the example below. If it already contains servers, add only the `upwell` entry inside `mcpServers`. Keep the environment reference in the file so the key stays out of the configuration. > > ```json theme={null} > { > "mcpServers": { > "upwell": { > "url": "https://app.upwell.com/api/mcp", > "headers": { > "Authorization": "Bearer ${env:UPWELL_API_KEY}" > } > } > } > } > ``` > > 3. Save the file. In Cursor's MCP settings, enable **upwell** and check that its tools appear. Open an Agent chat and try the lookup below. > > [Cursor MCP configuration](https://cursor.com/docs/mcp) ## Check the connection Choose a customer invoice you can already open in Upwell. Replace the bracketed text with its number and ask your assistant the following question. > Use Upwell to look up customer invoice \[invoice number]. What is its payment status? Include a link to the invoice. Open the returned record and compare its invoice number and payment status with the answer. If the assistant returns documentation instead, check that the configured URL is `https://app.upwell.com/api/mcp`. The separate [documentation search server](/developer-guide/ai-tools#connect-the-documentation-search-server) answers questions about the public guides. ## Disconnect For connections made through Upwell sign-in, open **Account → Connected apps**, find the assistant, and select **Revoke access**. Cash Application users can open **Connected apps** directly from the sidebar. For the Cursor API-key setup, revoke the dedicated key under **Account → API keys** and remove the server entry from Cursor. # Working with addresses Source: https://docs.upwell.com/conventions/addresses The address playbook: per-parent link direction, create/attach/update tasks, load-bearing address types, visibility in the app, the one-billing-address rule, and read-back paths. Addresses behave differently from every other object in the API, and the difference causes real integration bugs. Read [Addresses on the data-model page](/concepts/data-model#addresses) for *why*; this section is the *how*. Three rules govern everything below: 1. **An address belongs to one parent.** It is not shared master data and is never deduplicated by content. The same physical place used in two roles is two address records. 2. **There is no external key.** Addresses have no `sourceSystem`/`sourceSystemId`, so there is no upsert-by-your-id. **Store the `addr_` id Upwell returns**, keyed by parent and address type, or you lose your ability to update that address later. 3. **You can embed an address when you create its parent. You can never embed one on an update.** Updates always take a separate call. > [!WARNING] > > The nested `addresses` object exists on **create** inputs only. Sending it on a `PUT`/`PATCH` does nothing useful — the update inputs for customers, companies, and shipments have no address field at all. If an address "silently didn't save" on an update, this is why. ## Which direction the link runs This is the part that surprises people: **the foreign key lives on a different side depending on the entity.** | Parent | Where the link lives | To attach an existing address | | - | - | - | | Customer | On the **address** (`customerId`) | `PUT /api/rest/addresses/{addressId}` with `{ "customerId": "cus_…" }` | | Company | On the **address** (`companyId`) | `PUT /api/rest/addresses/{addressId}` with `{ "companyId": "comp_…" }` | | Contact | On the **address** (`contactId`) | `PUT /api/rest/addresses/{addressId}` with `{ "contactId": "…" }` — but note contacts aren't exposed as a REST resource, so this only applies if you already hold a contact id | | Carrier | On the **carrier** (`addressId`, `billingAddressId`) | `PUT /api/rest/carriers/{carrierId}` with `{ "billingAddressId": "addr_…" }` | | Shipment | On the **shipment** (`pickupAddressId`, `consigneeAddressId`) | **Not possible after creation** — see the warning below | So for a customer or company you patch *the address*; for a carrier you patch *the carrier*. Patching the customer itself does nothing, because there is no field there to accept it. > [!WARNING] > > **A shipment's pickup and consignee addresses can only be *linked* when the shipment is created.** At creation you can either embed a new address (`pickupAddress` / `consigneeAddress`) or point at an existing one (`pickupAddressId` / `consigneeAddressId`). After that the link is fixed: the shipment update input exposes neither id field, and there is no dedicated endpoint to relink them. > > This is rarely a problem in practice, because correcting the **address record** is almost always what you actually want — `PUT /api/rest/addresses/{id}` changes it in place and the shipment keeps pointing at it. You only hit the wall if you need to swap a shipment onto a *different* address row. ## Task: create a record with its address Embed the address under its parent. Use `{ "data": [ … ] }` for a list of addresses (customers, companies) and `{ "data": { … } }` for a single slot (a shipment's pickup or consignee). ```bash theme={null} # A customer with its billing address, in one call curl -X POST https://api.upwell.com/api/rest/customers \ -H "Authorization: YOUR_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "input": { "name": "Acme Manufacturing", "sourceSystem": "YOUR_TMS", "sourceSystemId": "CUST-10042", "addresses": { "data": [ { "type": "CUSTOMER_BILLING", "streetLine1": "123 Main St", "city": "Chicago", "stateOrProvince": "IL", "zipOrPostalCode": "60601", "country": "US" } ] } } }' ``` Don't set `customerId` inside a nested address — the parent supplies it. **Read the created address ids out of the response and store them**, because this is the only moment they're handed to you without a lookup. > [!WARNING] > > **Companies are the exception.** `POST /api/rest/companies` returns the > company's own fields only — the nested addresses come back with **no ids**. Since a company > exposes no address read path either, and addresses have no `sourceSystem`/`sourceSystemId` to > look them up by, an address created that way is recoverable only by paging the unfiltered > `GET /api/rest/addresses` list. > > If you need the id — and you do, to ever update that address — create it standalone instead: > `POST /api/rest/addresses` with `companyId` and `type: "COMPANY_ADDRESS"`, which returns the > `addr_` id directly. Nested creation is fine for customers and shipments, whose responses do > include the new ids. ## Task: add an address to a record that already exists Two calls, and the second one depends on the entity (see the direction table above). **1. Create the address on its own** `POST /api/rest/addresses` with the address fields, its `type`, and — for a customer or company — the parent id (`customerId` / `companyId`) directly on the address. **2. Link it, if the parent holds the link** For a **carrier**, `PUT /api/rest/carriers/{id}` with `addressId` or `billingAddressId`. For a customer or company you're already done: step 1 set the link. ```bash theme={null} # Step 1 — create the address, pointing it at its customer curl -X POST https://api.upwell.com/api/rest/addresses \ -H "Authorization: YOUR_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "input": { "type": "CUSTOMER_BILLING", "customerId": "cus_abc123", "streetLine1": "456 Dock Rd", "city": "Joliet", "stateOrProvince": "IL", "zipOrPostalCode": "60431", "country": "US" } }' # -> { "createAddress": { "id": "addr_xYz789", ... } } <- store this id ``` ## Task: change an existing address If you kept the `addr_` id, this is one call: ```bash theme={null} curl -X PUT https://api.upwell.com/api/rest/addresses/addr_xYz789 \ -H "Authorization: YOUR_API_KEY" \ -H "Content-Type: application/json" \ -d '{ "input": { "streetLine1": "789 New Dock Rd" } }' ``` If you didn't keep it, fetch the parent and read the address off it first — `GET /api/rest/customers/{id}` returns the customer's addresses, and `GET /api/rest/carriers/{id}` returns `addressId` / `billingAddressId`. Match on the address **`type`** to pick the right one. > [!NOTE] > > Updating the address in place is almost always what you want. Because the parent points at the same `addr_` id, every record using that address sees the change — no relinking needed. ## Address types `type` is **required on every address** — there is no default and no fallback. It records the role the address plays, and several product surfaces query it directly, so a valid address carrying the wrong type saves successfully and then does nothing. These are the ones an integration sets: | Type | Use for | What depends on it | | - | - | - | | `CUSTOMER_BILLING` | A customer's billing address | **Load-bearing.** The invoice bill-to block, EDI output, invoice delivery routing, and the customer detail page all select on this exact value — the wrong type means no billing address is found. | | `COMPANY_ADDRESS` | One of your own entity's addresses | **Load-bearing.** The company pages query `type = COMPANY_ADDRESS` and render nothing else — an address on a company with any other type is invisible in the app. Companies have a single address type today; there's no separate street/mailing/billing distinction. | | `SHIPMENT_PICKUP` | A shipment's origin | Routing reads the shipment's pickup *slot*, so the slot matters more than the label — but set it correctly anyway. | | `SHIPMENT_CONSIGNEE` | A shipment's destination | Same as pickup: the slot is what's read. | | `CARRIER` | A carrier's primary address | Descriptive. | | `CARRIER_BILLING` | Where a carrier wants payment sent | Descriptive; remit-to logic is driven by factoring documents, not this field. | | `CONTACT` | An address on a contact record | Descriptive. | | `STOP` | An address used by a route stop | Descriptive. | | `ADDRESS_BOOK` | A saved address not tied to a specific role | **Inert — nothing reads it.** No product surface queries `ADDRESS_BOOK`: it won't appear on a customer or company page, won't be used as a bill-to, and won't drive routing. It is not a safe generic default. Always use the specific type for the role the address plays. | Upwell also writes `SUPPORTING_DOC_PARTY`, `DELIVERY_RECEIPT`, and `LUMPER_RECEIPT` addresses from its own document-parsing pipelines. You'll see them on reads; you shouldn't create them. > [!NOTE] > > **One physical place, two roles, two records.** If the same warehouse is both the consignee on one shipment and the pickup on another, that's two address records with two different types. This is expected — there's no way to share one row across two type slots, and no dedup will merge them. ## Where an address shows up in the app An address can save cleanly — `201`, real `addr_` id, readable back over the API — and still appear nowhere in the UI. That is not a bug and it produces no error: **the pages filter on address `type`**, and they select a narrow set of fields. | Page | Address types it will render | Fields it loads | | - | - | - | | Company detail | Only `COMPANY_ADDRESS` | street lines, city, state/province, postal code, country — **and nothing else** | | Company list | Only `COMPANY_ADDRESS`, and only the **oldest** one ([`createdAt`](/conventions/dates-and-times#created-at) ascending, limit 1) | same | | Customer detail | Only `CUSTOMER_BILLING` | the full address record, including `name`, `companyName` and `phoneNumber` | Two consequences worth internalizing before you debug a "missing" address: * **An `ADDRESS_BOOK` address on a customer or company is invisible.** It exists, it's linked, and no page will ever draw it. This is the single most common cause of "the API accepted it but I can't see it." * **An address `phoneNumber` never reaches a company page.** The company pages don't load that field at all, so putting a phone number on a `COMPANY_ADDRESS` row is a dead end. The phone shown on a company record is the company's own `primaryPhone` — a field on the company itself, set with `PUT /api/rest/companies/{id}`. (Customer pages *do* load the address phone number, so this asymmetry is company-specific.) > [!TIP] > > Debug in this order: > > 1. **`GET /api/rest/addresses/{addressId}`** — confirms the row saved and returns its `type`. Check that against the table above: the type is wrong far more often than the write failed. > > 2. **Confirm the link from the parent** — the address endpoints never return `customerId` or `companyId`, so an orphaned address is indistinguishable from a linked one when you fetch it directly. For a **customer**, `GET /api/rest/customers/{id}` and look for it in `addresses`. For a **carrier**, `GET /api/rest/carriers/{id}` and check `addressId` / `billingAddressId`. > > > [!WARNING] > > > > **Step 2 has no company equivalent.** `GET /api/rest/companies/{id}` returns no `addresses`, and the address endpoints return no `companyId`, so the link is exposed by neither side. Step 1 still works — you can always read the `type` back — but if the type is right and the address still doesn't render, you cannot confirm the link over the API. Two things to check before assuming it's broken: that the address carries a `companyId` at all — if you created it standalone you had to send one, whereas the nested form on `POST /api/rest/companies` sets it for you — and, on the company **list** view only, the oldest-address rule above. ## One billing address per customer A customer can hold many addresses, but **at most one `CUSTOMER_BILLING` address**. This is a database constraint, not a convention — a second one is rejected outright: ``` Uniqueness violation. duplicate key value violates unique constraint "idx_addresses_unique_customer_billing" ``` So "create the billing address" is only safe the first time. The supported pattern for keeping one in sync — the same one Upwell's own TMS integrations use — is **match by type, then update in place**: **1. Read the customer's existing addresses** `GET /api/rest/customers/{id}` returns its `addresses`, each with its `type`. **2. Find the CUSTOMER_BILLING row** Match on `type`, not on street or city — the address content is what changes. **3. Update it if present, create it if absent** Present → `PUT /api/rest/addresses/{addressId}`. Absent → `POST /api/rest/addresses` with `customerId` and `type: "CUSTOMER_BILLING"`. This is also why re-sending a full customer payload with a nested `addresses` block is not a safe "upsert" — the nested block always *inserts*. Use it on first creation only. > [!NOTE] > > No other address type is constrained this way. A customer may hold any number of > `ADDRESS_BOOK` or `CONTACT` rows, and a company any number of `COMPANY_ADDRESS` rows (though > only the oldest shows in the company list view). ## Reading addresses back Read paths are narrower than write paths, which matters when you're verifying a sync: | To read | Use | Caveat | | - | - | - | | A customer's addresses | `GET /api/rest/customers/{id}` | Returns `id`, `type`, street lines 1–2, city, state/province, postal code, country. Does **not** return `phoneNumber`, `name`, or `streetLine3`. | | A company's addresses | `GET /api/rest/addresses/{addressId}` | `GET /api/rest/companies/{id}` and `GET /api/rest/companies` **return no addresses at all.** You need the `addr_` id from the create response, or the full address list. | | A carrier's addresses | `GET /api/rest/carriers/{id}` | Returns `addressId` / `billingAddressId`; fetch each address separately. | | One address, widest field set | `GET /api/rest/addresses/{addressId}` | Returns every address field **except its links**: no `customerId`, `companyId`, `contactId`, `canonicalAddressId` or `locationCodeId`, even though all five are writable. To learn which parent an address belongs to you must read the parent, and only two parents expose it — a customer (`addresses`) and a carrier (`addressId` / `billingAddressId`). Company, contact, canonical-address and location-code links are readable from neither side. | > [!WARNING] > > **The list endpoints take no filters.** `GET /api/rest/addresses`, `GET /api/rest/companies` > and the other collection `GET`s accept only `limit` and `offset` — there is no `where` > parameter. Server-side filtering exists only on the `POST /…/search` endpoints, and those > exist for customers, carriers, shipments, shipment line items, invoices, bills, bill payments, > customer payments, customer payment line items, vendors, purchase orders and vendor invoices — > **not** for addresses or companies. > > Practically: **store the `addr_` id when you create an address.** Recovering it later means > paging the whole collection or going through the parent. # Dates and timestamps Source: https://docs.upwell.com/conventions/dates-and-times Business definitions, date formats, timezone rules, and REST/webhook field names. Dates describe different events. A shipment becoming ready, freight being picked up, an invoice being issued, and money arriving are separate events; do not substitute one date for another. Each definition lists the entities that own the field and links to an API operation that includes it. An entity may appear inside another response; for example, appointmentEnd belongs to a shipment stop. Some fields are exposed only in create/update inputs, search filters, or webhook payloads. Expand the request or response fields on the linked page to see that context. ## Formats and timezones | Schema | JSON representation | Meaning | | - | - | - | | `date` / `NullableDate` | `"2026-10-16"` | Calendar date (YYYY-MM-DD), without a time or timezone. Do not convert a date-only value through UTC and shift its day. | | `timestamptz` / `NullableTimestamptz` / `DateTime` | `"2026-10-16T14:30:00Z"` or `"2026-10-16T10:30:00-04:00"` | Timestamp identifying an instant. Include an explicit UTC marker or offset. The returned offset may differ while representing the same instant. | | `timestamp` | `"2026-10-16T14:30:00"` | Timestamp stored without timezone. An input offset does not survive storage. Keep the originating timezone separately when it matters; do not assume UTC. | The field's endpoint schema determines its representation. Fields with the same business meaning can have different REST and webhook representations. Stop appointmentTimezone and actualTimezone carry the local scheduling/event context separately. ## Missing values and updates Omit an optional field on update to leave its value unchanged. Null is a value, not an instruction to use today's date: only send it where the endpoint accepts clearing that field. Do not send an empty string as a date. Requiredness, write access, and defaults are endpoint-specific; an absent date is not evidence that the event occurred. ## REST and webhook names REST generally uses camelCase; invoice webhook payloads use snake_case. For example, issue_date corresponds to issueDate, due_date to dueDate, ship_date to shipDate, and sent_at to sentAt. They link to the same business definitions below. The invoice create/update field is issueDate, not invoiceDate. Vendor invoices and remittance lines have their own invoiceDate field. ## Business and lifecycle definitions ## Automatic hold expires at **Field:** `automaticHoldExpiresAt` **Entities:** [Customer invoices](/api-reference/invoices/search-invoices). Timestamp when the customer-configured automatic invoice hold becomes eligible for release. The expiry worker normally releases it on the next five-minute scan. Null means no scheduled automatic release. A separate manual hold can remain after this timer expires. ## Issue date **Field:** `issueDate` **Entities:** [Bills](/api-reference/bills/get-one-bill); [Carrier invoice approval webhook](/api-reference/webhooks/handle-carrier-invoice-status-approved-events); [Carrier invoice webhook payload](/api-reference/webhooks/handle-carrier-invoice-events); [Carrier invoices](/api-reference/carrier-invoices/get-one-carrier-invoice); [Customer invoice webhook payload](/api-reference/webhooks/handles-invoice-events); [Customer invoices](/api-reference/invoices/get-one-invoice). Date the invoice was issued, as printed on the invoice. This is the invoice date for customer and carrier invoices; creating the Upwell record is a separate event recorded by createdAt. ## Invoice date **Field:** `invoiceDate` **Entities:** [Remittance webhook line items](/api-reference/webhooks/handles-remittance-events); [Vendor invoices](/api-reference/vendor-invoices/get-one-vendor-invoice). Date printed on the vendor invoice, or the invoice date reported on a remittance line. Customer and carrier invoice endpoints call this field issueDate; invoiceDate is not an alias accepted by those endpoints. ## Due date **Field:** `dueDate` **Entities:** [Bills](/api-reference/bills/get-one-bill); [Carrier invoice approval webhook](/api-reference/webhooks/handle-carrier-invoice-status-approved-events); [Carrier invoice webhook payload](/api-reference/webhooks/handle-carrier-invoice-events); [Carrier invoices](/api-reference/carrier-invoices/get-one-carrier-invoice); [Customer invoice webhook payload](/api-reference/webhooks/handles-invoice-events); [Customer invoices](/api-reference/invoices/get-one-invoice); [Vendor invoices](/api-reference/vendor-invoices/get-one-vendor-invoice). Date payment is due under the invoice payment terms. Used for accounts-receivable aging and reminders; it is not the shipment delivery date. ## Ready date **Field:** `readyDate` **Entities:** [Shipments](/api-reference/shipments/create-one-shipment). Date the shipment is scheduled to be ready for pickup. This is a readiness/planning date, not confirmation that pickup occurred. Source integrations may populate it from the earliest scheduled pickup date. ## Ship date **Field:** `shipDate` **Entities:** [Customer invoice webhook payload](/api-reference/webhooks/handles-invoice-events); [Customer invoices](/api-reference/invoices/create-one-invoice). Shipping date recorded on the invoice or reported by its source system. It describes the freight movement, not invoice issuance. Source systems may report a planned or actual shipping date; this field alone does not certify actual pickup. Use shipment/stop event timestamps for recorded movement events. ## Delivery date **Field:** `deliveryDate` **Entities:** [Customer invoice webhook payload](/api-reference/webhooks/handles-invoice-events); [Customer invoices](/api-reference/invoices/create-one-invoice); [Purchase-order line schedules (schedules\[\])](/api-reference/purchase-orders/get-one-purchase-order). Freight delivery date recorded on the invoice. On a purchase-order line schedule, the scheduled delivery date of that release. It does not mean the invoice email was delivered; invoice sending is recorded separately by sentAt. ## Pickup at **Field:** `pickupAt` **Entities:** [Shipments](/api-reference/shipments/get-one-shipment). Pickup timestamp recorded for the shipment. A source integration may supply an actual event or a scheduling fallback; inspect stop actualArrival/actualDeparture for explicitly recorded actual events. Distinct from the date-only readyDate. ## Delivered at **Field:** `deliveredAt` **Entities:** [Shipments](/api-reference/shipments/get-one-shipment). Delivery timestamp recorded for the shipment and used by post-delivery invoice workflows. Some creation/import workflows supply a fallback value, so it is not by itself proof of delivery. Distinct from invoice delivery/sending. ## Release date **Field:** `releaseDate` **Entities:** [Shipments](/api-reference/shipments/get-one-shipment). Shipment release/planned-start date supplied by the source system. Some integrations copy readyDate or use the planned load start; it is not a guarantee of actual departure. ## Covered date **Field:** `coveredDate` **Entities:** [Shipments](/api-reference/shipments/get-one-shipment). Date the shipment was recorded as covered by a carrier in the source system. Distinct from dispatch, pickup, and delivery. ## Dispatched date **Field:** `dispatchedDate` **Entities:** [Shipments](/api-reference/shipments/get-one-shipment). Date the shipment was recorded as dispatched in the source system. Dispatch does not confirm physical pickup. ## Loaded date **Field:** `loadedDate` **Entities:** [Shipments](/api-reference/shipments/get-one-shipment). Date the shipment was recorded as loaded in the source system. Distinct from the planned readiness date. ## Billed date **Field:** `billedDate` **Entities:** [Shipments](/api-reference/shipments/get-one-shipment). Date the shipment was recorded as billed in the source system. This shipment lifecycle date need not equal an associated invoice's issueDate. ## Appointment start **Field:** `appointmentStart` **Entities:** [Shipment stops](/api-reference/stops/get-one-stop). Start of the scheduled appointment window at a stop. Use appointmentTimezone to interpret the stop's local scheduling context; this is not an actual arrival event. ## Appointment end **Field:** `appointmentEnd` **Entities:** [Shipment stops](/api-reference/stops/get-one-stop). End of the scheduled appointment window at a stop. Use appointmentTimezone for the local scheduling context; this is not an actual departure event. ## Actual arrival **Field:** `actualArrival` **Entities:** [Shipment stops](/api-reference/stops/create-one-stop). Recorded actual arrival time at a stop. Distinct from appointmentStart, which describes the scheduled window. actualTimezone identifies the local event context. ## Actual departure **Field:** `actualDeparture` **Entities:** [Shipment stops](/api-reference/stops/create-one-stop). Recorded actual departure time from a stop. Distinct from appointmentEnd, which describes the scheduled window. actualTimezone identifies the local event context. ## Paid date **Field:** `paidDate` **Entities:** [Customer invoices](/api-reference/invoices/create-one-invoice). Timestamp recorded for invoice payment. It is separate from individual payment transaction dates and from a scheduled or promised payment date. Determine the outstanding amount from balance and payment records. ## Scheduled payment date **Field:** `scheduledPaymentDate` **Entities:** [Customer invoice webhook payload](/api-reference/webhooks/handles-invoice-events); [Customer invoices](/api-reference/invoices/create-one-invoice). Expected or scheduled date of payment reported for the invoice. It is a forecast, not proof that funds were received. ## Transaction date **Field:** `transactionDate` **Entities:** [Bill payments](/api-reference/bill-payments/get-bill-payment); [Carrier payment line items](/api-reference/carrier-payment-line-items/get-one-carrier-payment-line-item); [Customer payment line items](/api-reference/customer-payment-line-items/get-one-customer-payment-line-item); [Customer payments](/api-reference/customer-payments/get-one-customer-payment). Accounting transaction date recorded on a payment or payment allocation. It can differ from the date printed on a check and the date funds become available at the bank. ## Check date **Field:** `checkDate` **Entities:** [Customer payment line items](/api-reference/customer-payment-line-items/get-one-customer-payment-line-item); [Customer payments](/api-reference/customer-payments/get-one-customer-payment). Date printed on the check or reported by the payment source for the check/ACH remittance. It does not establish when the bank settled the payment. ## Payment date **Field:** `paymentDate` **Entities:** [Remittance webhook payload](/api-reference/webhooks/handles-remittance-events). Payment date reported in the remittance webhook. This reflects the source remittance's payment date, not the webhook delivery time. ## Value date **Field:** `valueDate` **Entities:** [Document annotations (purchase orders and vendor invoices)](/api-reference/purchase-orders/get-one-purchase-order). Date value extracted for a document annotation on a purchase order or vendor invoice, such as a date written beside a signature or stamp. Interpret it with the annotation's fieldLabel, text, and type. It is not inherently a bank settlement date or an invoice issue date. ## Po date **Field:** `poDate` **Entities:** [Purchase orders](/api-reference/purchase-orders/get-one-purchase-order). Date the purchase order was issued, as recorded on the document. Distinct from requested shipment and delivery dates. ## Order date **Field:** `orderDate` **Entities:** [Vendor invoices](/api-reference/vendor-invoices/get-one-vendor-invoice). Order date stated on the purchase order or vendor invoice. This describes the underlying order, not invoice creation in Upwell. ## Revision date **Field:** `revisionDate` **Entities:** [Purchase orders](/api-reference/purchase-orders/get-one-purchase-order). Date of the document revision, as printed on the purchase order. It does not represent the original order date. ## Requested ship date **Field:** `requestedShipDate` **Entities:** [Purchase orders](/api-reference/purchase-orders/get-one-purchase-order). Date the buyer requests goods to be shipped. A requested date is not confirmation that shipment occurred. ## Requested delivery date **Field:** `requestedDeliveryDate` **Entities:** [Purchase orders](/api-reference/purchase-orders/get-one-purchase-order); [Purchase-order line items](/api-reference/purchase-orders/get-one-purchase-order). Date the buyer requests goods or a particular order line to be delivered. A requested date is not confirmation of delivery. ## Promised delivery date **Field:** `promisedDeliveryDate` **Entities:** [Purchase-order line items](/api-reference/purchase-orders/get-one-purchase-order). Delivery date promised or scheduled by the supplier for an order line. Distinct from the buyer's requestedDeliveryDate and actual delivery. ## Cancel after date **Field:** `cancelAfterDate` **Entities:** [Purchase orders](/api-reference/purchase-orders/get-one-purchase-order). Purchase-order cancellation cutoff printed on the document. Recording this date does not itself cancel an order in Upwell. ## Pickup date **Field:** `pickupDate` **Entities:** [Purchase orders](/api-reference/purchase-orders/get-one-purchase-order). Pickup date stated on the source purchase order or vendor document. This document field is distinct from the shipment pickupAt timestamp. ## Shipped date **Field:** `shippedDate` **Entities:** [Vendor invoice shipment details (shipmentInfo)](/api-reference/vendor-invoices/update-one-vendor-invoice). Shipping date printed in a vendor invoice's shipmentInfo block. It reflects the source document rather than an independently observed shipment event. ## Cargo insurance expire date **Field:** `cargoInsuranceExpireDate` **Entities:** [Carriers](/api-reference/carriers/get-one-carrier). Expiration date recorded for the carrier's cargo insurance policy. A populated date is not a verification that coverage is currently valid. ## General liability insurance expire date **Field:** `generalLiabilityInsuranceExpireDate` **Entities:** [Carriers](/api-reference/carriers/get-one-carrier). Expiration date recorded for the carrier's general liability insurance policy. Distinct from cargo and other liability coverage. ## Liability insurance expire date **Field:** `liabilityInsuranceExpireDate` **Entities:** [Carriers](/api-reference/carriers/get-one-carrier). Expiration date recorded for the carrier's liability insurance policy. Consult the policy for coverage details; this field is not a coverage guarantee. ## Automation go live date **Field:** `automationGoLiveDate` **Entities:** [Customer automation settings (customerRule)](/api-reference/customers/update-one-customer-by-source-system-id). Configured go-live date for customer automation. It is an automation setting, not an invoice issue date or shipment event. ## Created at **Field:** `createdAt` **Entities:** [Addresses](/api-reference/addresses/get-one-address); [Bill line items](/api-reference/bill-line-items/create-one-bill-line-item); [Bill payments](/api-reference/bill-payments/get-bill-payment); [Bills](/api-reference/bills/get-one-bill); [Carrier invoice approval requests](/api-reference/carrier-invoice-approval-requests/get-carrier-invoice-approval-request); [Carrier invoice approval webhook](/api-reference/webhooks/handle-carrier-invoice-status-approved-events); [Carrier invoice documents](/api-reference/carrier-invoice-documents/get-many-carrier-invoice-documents); [Carrier invoice exceptions](/api-reference/carrier-invoices/approve-one-carrier-invoice); [Carrier invoice webhook payload](/api-reference/webhooks/handle-carrier-invoice-events); [Carrier invoices](/api-reference/carrier-invoices/get-one-carrier-invoice); [Carrier payment line items](/api-reference/carrier-payment-line-items/get-one-carrier-payment-line-item); [Carriers](/api-reference/carriers/get-one-carrier); [Companies](/api-reference/companies/get-company); [Customer invoice documents](/api-reference/invoice-documents/get-many-invoice-documents); [Customer invoice exceptions](/api-reference/invoice-approval/approve-customer-invoice); [Customer invoice line items](/api-reference/invoice-line-items/create-one-invoice-line-item); [Customer invoice webhook payload](/api-reference/webhooks/handles-invoice-events); [Customer invoices](/api-reference/invoices/get-one-invoice); [Customer payment line items](/api-reference/customer-payment-line-items/get-one-customer-payment-line-item); [Customer payments](/api-reference/customer-payments/get-one-customer-payment); [Customers](/api-reference/customers/get-one-customer); [Document reference specifications](/api-reference/document-reference-specifications/get-one-document-reference-specification); [Documents](/api-reference/documents/get-one-document); [Invoice–shipment links](/api-reference/invoice-shipments/link-invoice-to-shipment); [Notes (shipments and carrier invoices)](/api-reference/shipments/create-shipment-note); [Purchase orders](/api-reference/purchase-orders/get-one-purchase-order); [Remittance webhook line items](/api-reference/webhooks/handles-remittance-events); [Remittance webhook payload](/api-reference/webhooks/handles-remittance-events); [Rules](/api-reference/rules/get-one-rule); [Shipment document webhook](/api-reference/webhooks/handle-shipment-documents-events); [Shipment documents](/api-reference/shipment-documents/get-many-shipment-documents); [Shipment line items](/api-reference/shipment-line-items/search-shipment-line-items); [Shipment stops](/api-reference/stops/get-one-stop); [Shipments](/api-reference/shipments/get-one-shipment); [Vendor invoices](/api-reference/vendor-invoices/get-one-vendor-invoice); [Vendors](/api-reference/vendors/get-one-vendor); [Webhook delivery envelope](/api-reference/webhooks/handle-carrier-invoice-events). Timestamp when this record was created in Upwell. It is not the business document date and may be much later when historical data is imported. ## Updated at **Field:** `updatedAt` **Entities:** [Addresses](/api-reference/addresses/get-one-address); [Bill line items](/api-reference/bill-line-items/create-one-bill-line-item); [Bill payments](/api-reference/bill-payments/get-bill-payment); [Bills](/api-reference/bills/get-one-bill); [Carrier invoice approval requests](/api-reference/carrier-invoice-approval-requests/get-carrier-invoice-approval-request); [Carrier invoice documents](/api-reference/carrier-invoice-documents/get-many-carrier-invoice-documents); [Carrier invoice exceptions](/api-reference/carrier-invoices/approve-one-carrier-invoice); [Carrier invoice webhook payload](/api-reference/webhooks/handle-carrier-invoice-events); [Carrier invoices](/api-reference/carrier-invoices/get-one-carrier-invoice); [Carrier payment line items](/api-reference/carrier-payment-line-items/get-one-carrier-payment-line-item); [Carriers](/api-reference/carriers/get-one-carrier); [Companies](/api-reference/companies/get-company); [Customer invoice documents](/api-reference/invoice-documents/get-many-invoice-documents); [Customer invoice exceptions](/api-reference/invoice-approval/approve-customer-invoice); [Customer invoice line items](/api-reference/invoice-line-items/create-one-invoice-line-item); [Customer invoice webhook payload](/api-reference/webhooks/handles-invoice-events); [Customer invoices](/api-reference/invoices/get-one-invoice); [Customer payment line items](/api-reference/customer-payment-line-items/get-one-customer-payment-line-item); [Customer payments](/api-reference/customer-payments/get-one-customer-payment); [Customers](/api-reference/customers/get-one-customer); [Document reference specifications](/api-reference/document-reference-specifications/get-one-document-reference-specification); [Remittance webhook line items](/api-reference/webhooks/handles-remittance-events); [Remittance webhook payload](/api-reference/webhooks/handles-remittance-events); [Rules](/api-reference/rules/get-one-rule); [Shipment document webhook](/api-reference/webhooks/handle-shipment-documents-events); [Shipment documents](/api-reference/shipment-documents/get-many-shipment-documents); [Shipment line items](/api-reference/shipment-line-items/search-shipment-line-items); [Shipment stops](/api-reference/stops/get-one-stop); [Shipments](/api-reference/shipments/get-one-shipment); [Vendors](/api-reference/vendors/get-one-vendor); [Webhook delivery envelope](/api-reference/webhooks/handle-carrier-invoice-events). Timestamp of the record's latest recorded update in Upwell. It is not a shipment event, payment date, or document revision date. ## Deleted at **Field:** `deletedAt` **Entities:** [Carrier invoice webhook payload](/api-reference/webhooks/handle-carrier-invoice-events); [Carrier invoices](/api-reference/carrier-invoices/update-one-carrier-invoice); [Companies](/api-reference/companies/get-company); [Customers](/api-reference/customers/update-one-customer-by-source-system-id). Timestamp recorded when the object was marked deleted. A deletion marker is separate from invoice cancellation status. ## Sent at **Field:** `sentAt` **Entities:** [Customer invoice webhook payload](/api-reference/webhooks/handles-invoice-events); [Customer invoices](/api-reference/invoices/update-one-invoice-by-source-system-id). Timestamp recorded for sending the invoice. It does not establish freight delivery or guarantee that the recipient opened or accepted the invoice. ## Received at **Field:** `receivedAt` **Entities:** [Carrier invoice webhook payload](/api-reference/webhooks/handle-carrier-invoice-events); [Carrier invoices](/api-reference/carrier-invoices/get-one-carrier-invoice); [Customer invoice webhook payload](/api-reference/webhooks/handles-invoice-events); [Customer invoices](/api-reference/invoices/search-invoices). Timestamp when the relevant inbound record or document was received. It is not the date printed on that document. ## Pinned at **Field:** `pinnedAt` **Entities:** [Notes (shipments and carrier invoices)](/api-reference/shipments/create-one-shipment). Timestamp when the note was pinned. It is a note-management event rather than a financial or shipment date. ## Scheduled at **Field:** `scheduledAt` **Entities:** [Webhook delivery envelope](/api-reference/webhooks/handle-carrier-invoice-events). Timestamp when the asynchronous job is scheduled to run. It is not a promise of completion at that time. ## Processed at **Field:** `processedAt` **Entities:** [Webhook delivery envelope](/api-reference/webhooks/handle-carrier-invoice-events). Timestamp recorded for processing the event or job. It is separate from the event's underlying business date. ## Synced at **Field:** `syncedAt` **Entities:** [Remittance webhook payload](/api-reference/webhooks/handles-remittance-events). Timestamp recorded when the synchronization ran. It describes data synchronization, not invoice issuance or shipment movement. ## Exceptions last evaluated at **Field:** `exceptionsLastEvaluatedAt` **Entities:** [Carrier invoice approval webhook](/api-reference/webhooks/handle-carrier-invoice-status-approved-events); [Carrier invoices](/api-reference/carrier-invoices/get-one-carrier-invoice); [Customer invoices](/api-reference/invoices/get-one-invoice); [Remittance webhook payload](/api-reference/webhooks/handles-remittance-events). Timestamp when the record's exception checks were last evaluated. It is a processing marker, not the date an exception first occurred or was resolved. ## Portal documents uploaded at **Field:** `portalDocumentsUploadedAt` **Entities:** [Customer invoices](/api-reference/invoices/search-invoices). Timestamp when a user marked the customer invoice's documents as uploaded to the customer portal by hand. It is not the freight delivery time or invoice issue date. ## Enabled at **Field:** `enabledAt` **Entities:** [Customers](/api-reference/customers/search-customers). Timestamp when the associated feature or workflow was enabled. This lifecycle timestamp does not describe the invoice or shipment itself. ## Final check passed at **Field:** `finalCheckPassedAt` **Entities:** [Customer invoices](/api-reference/invoices/search-invoices). Timestamp when the invoice's final processing check was recorded as passed. It is separate from approval, sending, and payment dates. ## Lifecycle event at **Field:** `lifecycleEventAt` **Entities:** [Customer payments](/api-reference/customer-payments/search-customer-payments). Timestamp recorded for the associated lifecycle event. Interpret it with that event's type rather than treating it as an invoice issue date. ## Debits updated at **Field:** `debits_updated_at` **Entities:** [Customer invoice webhook payload](/api-reference/webhooks/handles-invoice-events). Timestamp when the invoice's debit-related data was updated. This is a change-tracking marker in the webhook payload. ## Documents modified at **Field:** `documents_modified_at` **Entities:** [Carrier invoice webhook payload](/api-reference/webhooks/handle-carrier-invoice-events). Timestamp when the invoice's document data was modified. This is a change-tracking marker, not a document issue date. ## Documents type or customer visibility updated at **Field:** `documents_type_or_customer_visibility_updated_at` **Entities:** [Carrier invoice webhook payload](/api-reference/webhooks/handle-carrier-invoice-events). Timestamp when document classification or customer visibility changed. This is distinct from the document's own issue date. ## File associations updated at **Field:** `file_associations_updated_at` **Entities:** [Customer invoice webhook payload](/api-reference/webhooks/handles-invoice-events). Timestamp when the invoice's file associations changed. It tracks attachment links rather than invoice issuance. ## Line items last updated at **Field:** `line_items_last_updated_at` **Entities:** [Customer invoice webhook payload](/api-reference/webhooks/handles-invoice-events). Timestamp when invoice line-item data was last updated. It is a change-tracking marker rather than a financial transaction date. # Deleting and archiving Source: https://docs.upwell.com/conventions/deletes-and-archiving What DELETE actually does on each resource — hard vs. soft — and whether your external key is freed for reuse. ## Deleting and archiving `DELETE` does not mean the same thing on every resource, and the difference decides whether you can reuse an external key afterwards. | Resource | What `DELETE` does | Reusing the key afterwards | | - | - | - | | **Customer** | **Hard delete.** The row is gone, and its addresses are deleted with it. | Frees `(sourceSystem, sourceSystemId)` for reuse. Soft-deleting instead — `PUT` with [`deletedAt`](/conventions/dates-and-times#deleted-at) — frees it too, and is recoverable. | | **Carrier** | **Hard delete.** Carriers have no archive state at all. | Frees `(sourceSystem, sourceSystemId)`. In practice you rarely need this: `POST /api/rest/carriers` already no-ops on a duplicate key rather than failing. | | **Customer invoice** | **Hard delete.** `DELETE /api/rest/invoices/{id}` removes the invoice row, subject to related-record constraints. It does not set `deletedAt` or void/cancel it. | The deleted row no longer holds its external key. | | **Company** | **Soft delete.** The row is retained with [`deletedAt`](/conventions/dates-and-times#deleted-at) set and disappears from the app. | Frees the company name for reuse. Names are unique **case-insensitively** per tenant, so `Acme` and `ACME` collide. | | **Address** | **Hard delete.** No archive state. | n/a — addresses have no external key. | | **Vendor** | **Hard delete.** No archive state. | See the [vendors warning](/api-guides/syncing-foundation-entities#vendors) — it fails if a bill still references the vendor. | Two consequences that surprise people: * **You cannot delete an address a carrier points at.** `addressId` and `billingAddressId` are restrict-on-delete. Clear the reference on the carrier first, then delete the address. * **Deleting a company does not delete its addresses.** Because the delete is soft, the cascade never fires — the address rows survive, still pointing at a company that no longer appears anywhere. Delete those address rows explicitly if your integration needs them removed. > [!TIP] > > For customers, prefer the soft delete (`PUT` with [`deletedAt`](/conventions/dates-and-times#deleted-at)) over `DELETE`. It frees the > external key exactly the same way, but it's reversible and it doesn't take the customer's > address history with it. # Document conventions Source: https://docs.upwell.com/conventions/documents The sourceSystem/sourceSystemId pair rule, the two-step presigned upload (the only path that runs AI classification), and typing rate confirmations correctly. ## Document sourceSystem / sourceSystemId pair constraint On `documents`, the check constraint `documents_source_system_pair_nullity_chk` requires both fields to be set or both to be null. Setting only `sourceSystem` without `sourceSystemId` fails with: ``` "Check constraint violation. ... documents_source_system_pair_nullity_chk" ``` The simplest pattern: always pass a `sourceSystemId` alongside `sourceSystem`. If you don't have a meaningful external id for a document, generate one (e.g. a UUID, or `_doc_`). ## Document upload: two-step presigned URL Use the two-step presigned flow for document uploads — for **carrier-invoice documents it's the only path that runs AI classification**: a combined or `UNKNOWN` PDF sent through an inline-base64 endpoint is filed but never classified or parsed, so nothing populates from it. The flow: 1. `POST /api/rest/generate-upload-presigned-url` with `{ associationType, associationId, documentType, fileName, mimeType, sourceSystem, sourceSystemId }` returns `{ documentId, uploadUrl }`. 2. `PUT` the file bytes directly to `uploadUrl`. > [!TIP] > > The presigned URL is signed for `host`-only headers. You can send `Content-Type` on the `PUT`, > but avoid adding headers that aren't in `X-Amz-SignedHeaders`. Wrapping the body in a `Blob` > with an explicit type can cause some Node `fetch` implementations to add headers that break the > signature — passing an `ArrayBuffer` is the safe path. Full upload mechanics: > [Document conventions](/conventions/documents#document-upload-two-step-presigned-url). ### Upload size limits Inline base64 means sending the file encoded as text in the JSON request (for example, `input.base64` on `POST /api/rest/invoices/{invoiceId}/documents`). It is a different mechanism from requesting a presigned URL and uploading raw bytes to S3. | Mechanism | Limit | | - | - | | **Presigned S3 URL through the API, or the UI document uploader** | No application file-size cap is configured in these upload paths. The file goes directly to S3, so the inline API payload limit does not apply; [S3 upload limits](https://docs.aws.amazon.com/AmazonS3/latest/userguide/upload-objects.html) still apply. | | **Inline-base64 API** | [Netlify's 6 MB buffered request limit](https://docs.netlify.com/build/functions/configuration/#default-values) includes the encoded file and request overhead. Base64 expands the file by roughly one third, leaving approximately **4.5 MB minus overhead** for the original bytes. This is not an exact decoded-file allowance. | | **Inbound email** | [SendGrid's 30 MB limit](https://www.twilio.com/docs/sendgrid/for-developers/parsing-email/inbound-email) covers the whole email, including its body and all attachments. The sending mail provider may impose a lower limit. | ### Rate confirmations: customer vs. carrier A customer rate confirmation and a carrier rate confirmation are two separate document types in Upwell — separate `documentType` values, separate parsers, and separate storage. **Sending the correct one matters:** | `documentType` | What it is | Used for | | - | - | - | | `CARRIER_RATE_CONFIRMATION` | The rate you agreed to **pay the carrier** — carrier cost. | Carrier-invoice audit (payables). | | `CUSTOMER_RATE_CONFIRMATION` | The rate your **customer agreed to pay you** — customer revenue. | Validating customer invoices (receivables). | Type a carrier rate confirmation as `CARRIER_RATE_CONFIRMATION` and a customer rate confirmation as `CUSTOMER_RATE_CONFIRMATION`. Each is AI-parsed on upload (through the two-step presigned flow above) by its own parser into its own storage, including the total rate. A document typed as one is never parsed, stored, or evaluated as the other. > [!WARNING] > > Never label a carrier rate confirmation as `CUSTOMER_RATE_CONFIRMATION` (or vice versa). The carrier rate is your cost/margin and must never reach the customer. If a rate confirmation is mis-typed on upload, re-type the document and re-process it rather than editing the parsed amount. # Field shapes and JSON values Source: https://docs.upwell.com/conventions/field-shapes How to read field definitions, send reference numbers and JSON metadata, and construct filters. The API reference describes the JSON value for each field, including nested objects and arrays. Send the representation documented for the field in the request body. A JSON object and a string containing serialized JSON are distinct values; some legacy fields support both. ## Reference numbers Customer invoices and shipments support an object keyed by the purpose of each reference: ```json theme={null} { "referenceNumbers": { "billOfLadingNumber": "BOL-123", "customerPoNumber": "PO-456", "otherReferenceNumbers": [ { "name": "Booking", "value": "BK-789" } ] } } ``` Keep identifiers as strings to preserve leading zeros. Additional source-specific keys may be present. Source integrations also use `additionalReferenceNumbers`, whose entries contain `name`, `value`, and optionally `normalizedName` (for example, `customerPoNumber`). These collections are not interchangeable in every workflow; use the field documented for the receiving entity. Customer invoices also support a top-level array of named references, such as `[{ "name": "Customer PO", "value": "PO-456" }]`. Invoice reference resolution uses this array shape. Preserve the shape used by the source and receiving workflow when reading and updating references. Invoices and shipments can also contain arrays of plain reference strings, such as `["REF-001", "REF-002"]`. These identifiers have no separate label. An invoice's `additionalReferenceNumbers` collection can be null when no named references are available. Legacy invoice clients also send JSON-encoded reference objects, such as `"referenceNumbers": "{\"reference\":\"123\"}"`, and the API can return that string unchanged. Preserve this representation when round-tripping existing records; it is distinct from an unstructured comma-separated string. Dedicated fields such as `customerPoNumber`, `billOfLadingNumber`, and `carrierProNumber` remain separate fields. Setting a key inside `referenceNumbers` does not automatically update its top-level counterpart. Purchase-order and vendor-invoice `referenceNumbers` use an array of named references, such as `[{ "name": "Customer PO", "normalizedName": "customerPoNumber", "value": "PO-123" }]`. These parsed-document fields use the array directly, without an `otherReferenceNumbers` wrapper. Stop references additionally support lists of `{ "name": "PO", "value": "PO-123" }` entries. Older sources may return a JSON-encoded string for stop references. Prefer an object or array for new integrations. A plain comma-separated string is not the documented invoice reference-number shape. Shipments from sources such as Tai/Metafora can instead use a top-level array: ```json theme={null} { "referenceNumbers": [ { "value": "CONT-123", "referenceType": "Container Number" } ] } ``` Preserve the source's labels and shape when round-tripping these records. Shipment matching recognizes specific identifier labels, including `Container Number`, `Custom Reference Number`, `Custom Reference Number 2`, `Delivery Number`, `Rail Pickup Number`, `Load Release Number`, and `Tracking Reference Number`; arbitrary labels are not a promise of matching behavior. ## Custom JSON values In the API reference, **`{key}` means a property name you choose**. It is a placeholder for additional keys, not a literal property to send and not a requirement to invent a key. The type selector shows the alternatives allowed for that custom value. For `referenceNumbers`, prefer a standard string property such as `customerPoNumber`, or a named entry in `otherReferenceNumbers`. Custom keys are useful for preserving source-specific data. These are three different examples: ```json Standard reference theme={null} { "referenceNumbers": { "customerPoNumber": "PO-456" } } ``` ```json Custom text value theme={null} { "referenceNumbers": { "bookingReference": "BK-789" } } ``` ```json Custom object value theme={null} { "referenceNumbers": { "bookingReference": { "number": "BK-789", "source": "TMS" } } } ``` In the object example, `bookingReference`, `number`, and `source` are illustrative names chosen by the sender. The object has no required keys. Its values can be strings, numbers, booleans, null, arrays, or further objects. For example, `"bookingReference": { "numbers": ["BK-789", "BK-790"] }` is also a JSON object value. This flexibility applies to **custom keys**. It does not change the types of the named properties: `customerPoNumber` is documented as a string, so do not replace it with `{ "number": "PO-456" }`. Saving a custom object does not make its keys searchable reference types or trigger matching automatically. Use the documented standard properties or named-reference collections for those workflows. For a JSON type selector, the example belongs to the selected type: text appears in quotes, an object uses `{ ... }`, and an array uses `[ ... ]`. An empty object `{}` means an object with no keys; it is not a definition of which business keys you should send. ## Metadata and other JSON fields JSON-valued `metadata` and `sourceSystemMeta` fields support objects with source/caller-defined keys. They can contain nested objects, arrays, strings, numbers, booleans, and null. Legacy source metadata also supports JSON-encoded object strings, such as `"sourceSystemMeta": "{\"source\":\"test\"}"`. They do not have a universal set of business keys. Preserve the existing representation and keys when sending a replacement value. Stop `metadata` is a text field: send a string such as `"{}"`, or serialize a JSON object into that string. Check the entity's schema before using the object example below. ```json theme={null} { "metadata": { "externalBatchId": "BATCH-123", "labels": ["priority"], "reviewed": false } } ``` Other JSON fields have specific shapes in the reference. For example, contact `email` is an object such as `{ "email": "billing@example.com", "type": "default" }`, while an email field on a different entity may be a plain string. Purchase-order `schedules` is an array of delivery-date/quantity entries; it is not an arbitrary scheduling configuration. Rule action values depend on the selected action. Exception details and downstream response payloads depend on the event/service that produced them. Their schemas explicitly allow JSON values rather than inventing a fixed set of keys. ## Required, omitted, and null * **Required** means the request must include the field. Create and update schemas can differ. * **Omitted on update** generally leaves the field unchanged. Omitted on create uses a server default if one exists; it does not imply a default of zero or today's date. * **Null** is an explicit value. It clears a nullable field where the endpoint permits that; it can fail a database constraint on other fields. * **Nested data** inserts related records during creation. An object relation uses `{ "data": { ... } }`; an array relation uses `{ "data": [ ... ] }`. Update inputs set the supplied JSON column value; they do not recursively merge a partial JSON object with the old value. Read and preserve the keys you want to keep. An empty object, an empty array, an empty string, and null are different values. ## Query filters Search endpoints accept objects keyed by selectable fields. Scalar fields contain comparison objects; related records contain another filter object. The API key's permissions still determine which fields are accepted. ```json theme={null} { "where": { "sourceSystem": { "_eq": "YOUR_TMS" }, "issueDate": { "_gte": "2026-10-01", "_lte": "2026-10-31" }, "_or": [ { "number": { "_ilike": "INV-%" } }, { "customerPoNumber": { "_eq": "PO-123" } } ] }, "orderBy": { "createdAt": "desc" }, "limit": 50, "offset": 0 } ``` `_and` requires every expression, `_or` requires at least one, and `_not` negates an expression. Multiple comparisons on a field are combined with AND. `_isNull` checks null without comparing it to a string. `_in` and `_nin` take arrays. String `_like` and `_ilike` use SQL LIKE wildcards; `%` matches any sequence of characters. JSON `_contains` takes a JSON value, not serialized JSON text. Aggregate relationship filters use a function envelope. For example, where an endpoint exposes `invoiceLineItemsAggregate`, `{ "count": { "predicate": { "_gt": 0 } } }` tests whether at least one related line exists. Availability depends on that relationship and your API key's aggregate permissions. Sort values are `asc`, `desc`, `asc_nulls_first`, `asc_nulls_last`, `desc_nulls_first`, and `desc_nulls_last`. Related-record sorting uses a nested sort object. Match the outer `orderBy` object/array wrapper shown by the specific endpoint. See [Dates and timestamps](/conventions/dates-and-times) for the business meaning of each date, and [Money and payloads](/conventions/money-and-payloads) for monetary units and request wrappers. # Idempotency & retries Source: https://docs.upwell.com/conventions/idempotency-and-retries The sourceSystem/sourceSystemId external key, per-resource POST duplicate semantics (including the carrier-invoice async dedup), and the fields that are required with no default. ## External keys and updates via sourceSystem + sourceSystemId Every primary record (customers, carriers, shipments, invoices, bills) carries two fields: * `sourceSystem` — a constant string identifying you (e.g. `"YOUR_TMS"`) * `sourceSystemId` — your own primary key for the record Together this pair is your stable external handle into Upwell. Send both on every record. Upwell uses the pair so that webhooks and callbacks can reference your records by your IDs. **For the first sync of a record, use `POST`.** For updates, use **`PUT //{id}`** with the Upwell id you stored on first sync — or `PUT /` (no id in the URL) with `sourceSystem` + `sourceSystemId` in the request body to update by your external key. For the public `PUT /api/rest/shipments` endpoint, a source pair with no match returns **HTTP 200** with `{"updateShipment":{"affectedRows":0,"returning":[]}}`; it creates nothing. A matching update returns its affected-row count and updated records under `updateShipment`. Check `affectedRows` and use `POST /api/rest/shipments` to create a missing record: this `PUT` is update-only, not a create-or-update upsert. > [!WARNING] > > There is **no** `/by-source-system-id/{id}` URL pattern — the by-external-key update goes to the **base resource path**, not a suffixed one: `PUT /api/rest/carriers` (not `PUT /api/rest/carriers/by-source-system-id/{id}`), with `sourceSystem` + `sourceSystemId` inside `input`. > [!WARNING] > > `POST` is **not** retry-safe across the full surface. `POST /api/rest/customers`, `POST /api/rest/shipments`, and `POST /api/rest/invoices` will return a `400 Uniqueness violation` if you re-post a record with an existing `(sourceSystem, sourceSystemId)` pair. Treat first-sync as `POST` and every subsequent change as `PUT`. > > `POST /api/rest/carrier_invoices` behaves differently, and less strictly than "no duplicate": the insert always succeeds synchronously and returns a **new** id, even when you re-post a `sourceSystemId` that already exists. De-duplication happens **afterward**, asynchronously: a background enrichment step tries to stamp the new row's identity and, on detecting the same `(tenant, sourceSystemId)` already live, soft-deletes the **newer** row and leaves the original standing. Two things follow: > > * **The dedup key is `(tenant, sourceSystemId)` — it is not scoped by integration.** Two different integrations on the same tenant that happen to reuse the same external id string will collide with each other, not just with themselves. > * **There's a real window (seconds) where the duplicate is live** under its own id before the background pass soft-deletes it. If your client never received the response to an earlier submit and retries, you may end up holding the id from the losing (soon-to-be-deleted) copy rather than the surviving original. Don't treat the id from a retried `POST` as authoritative — reconcile with `GET /api/rest/carrier_invoices`, filtering `where` on **both** `sourceSystemId` and `deletedAt: {"_isNull": true}`. The second condition is not optional: the list endpoint doesn't exclude soft-deleted rows on its own, so without it the lookup can return the dead duplicate alongside the survivor. And because the dedup itself is asynchronous — and the timed-out original may still be in flight — a lookup made too early can return two **live** rows, or a single live row that later loses the dedup race to the original insert. Poll until the **same** single live row comes back across polls a few seconds apart before persisting its id. > > See the [carrier-invoice submission guide](/api-guides/carrier-invoice-submission#re-submitting) for the full mechanics. ## Required fields without server-side defaults A few fields are `NOT NULL` in our schema and have no default — you need to provide them on insert. | Endpoint | Field | What to send | | - | - | - | | `POST /api/rest/shipments` | `shipmentId` | A unique string. Generate from your own id, e.g. `"YOUR_TMS-SHIP-1001"`. | | `POST /api/rest/invoices` | `balance` | Outstanding balance in cents. For a new invoice this equals `totalAmount`. | Omitting these returns a `400 constraint-violation` with the column name in the error message: ``` "error":"Not-NULL violation. null value in column \"shipment_id\" of relation \"shipments\" violates not-null constraint" ``` # Money & payload conventions Source: https://docs.upwell.com/conventions/money-and-payloads Integer-cents money, the input/inputs body wrappers, and the authentication header — the request conventions every endpoint shares. ## All monetary fields are integer cents Money is stored as integers in the smallest currency unit (US cents for USD). A \$2,847.50 shipment rate goes over the wire as `284750`. This applies to `customerTotalRate`, `carrierTotalRate`, `totalAmount`, `balance`, `totalTaxAmount`, and similar fields. Float values are rejected at runtime: ``` "error":"The value 2847.5 lies outside the bounds or is not an integer. Maybe it is a float, or is there integer overflow?" ``` ## Wrapping POST payloads For most insert endpoints, the request body shape is: ```json theme={null} { "input": { "field": "value", "...": "..." } } ``` A few endpoints (the bulk inserts) use `{ "inputs": [...] }`. If you get a `bad-request: Unexpected variable ` error, your payload likely needs to be wrapped in `input`. ## Authentication header Send your API key in the `Authorization` header — bare or with a `Bearer ` prefix, both accepted. Keys, scope, environments, and rotation are covered in [Authentication](/authentication). # Rules: three shapes, not two Source: https://docs.upwell.com/conventions/rules The rules engine's three field shapes — action-only, DSL expression pair, and legacy structured criteria — and a worked DSL example. ## Rules: three shapes, not two `/api/rest/rules` is a general-purpose object for account-specific if-this-then-that policies (see [Rule](/concepts/glossary#objects) in the glossary), but the fields you populate depend on the rule's `type` — mixing them up produces a rule that silently never fires. * **Action-only** — no condition fields at all: only `actionType` + `actionValue` are set, and the rule's `type` itself determines when it applies. This is the most common shape (e.g. `ON_CREATION_FROM_EMAIL` rules) — don't assume every rule needs a condition or a DSL expression. * **DSL expression pair** — used by `type: "CUSTOMER_INVOICE_EXCEPTION"` rules: `conditionExpression` (when the rule applies — an expression like `Shipment.mode = 'FTL' AND Invoice.totalAmount > 1000`, or the literals `ALWAYS` / `NEVER`) and `validationExpression` (what to check — `REQUIRE Document WHERE ...` or `VALIDATE ... = ...`, see the worked example below). **For `CUSTOMER_INVOICE_EXCEPTION` rules, send both DSL fields** — a DSL-driven rule that carries only one of them is rejected with a `400`. The exception is **config-managed** exception types — ones evaluated in application code rather than by the DSL, which are allowed to carry NULL expressions and act as on/off toggles. That exempt set has been widened several times, so don't assume a given type is or isn't exempt: send both `conditionExpression` and `validationExpression` unless you know the type is config-managed. If a toggle-style rule returns an unexpected `400`, the response names the `check_rule_dsl_format` constraint — that's the signal the type you're writing is not exempt; ask [support@upwell.com](mailto:support@upwell.com) which types currently are. * **Structured criteria** (`criteriaObject` / `criteriaField` / `criteriaOperator` / `criteriaValue`) exist in the API but are not the mechanism rules are built on — treat them as legacy and use the shapes above instead. Other fields that apply regardless of mechanism: | Field | Notes | | - | - | | `customerId` | Scopes the rule to one customer. Omit (`null`) for a tenant-wide rule. | | `priority` | Integer, defaults to `0`. Used to order evaluation when more than one rule could apply. | | `enabled` | Boolean, defaults to `true`. **A real, API-settable toggle** — set it to `false` to deactivate a rule without deleting it; this is the recommended way to pause a rule temporarily. | > [!TIP] > > Rules don't soft-delete (no [`deletedAt`](/conventions/dates-and-times#deleted-at)) — `DELETE /api/rest/rules/{id}` is permanent. If you might want the rule back later, `PUT` it with `enabled: false` instead of deleting it. ### Example: validate a customer invoice against its customer rate confirmation Once customer rate confirmations are flowing in, a **shipper rule** (a `CUSTOMER_INVOICE_EXCEPTION`-type [rule](#rules-three-shapes-not-two) using the DSL expression pair) can hold a customer invoice for review when its amount doesn't match the customer's rate confirmation. The rule compares the parsed customer rate confirmation total against the shipment's customer total rate — both customer-side amounts, stored in cents: ``` REQUIRE Document WHERE Document.type = "CUSTOMER_RATE_CONFIRMATION" AND VALIDATE CustomerRateConfirmation.totalRate = Shipment.customerTotalRate ``` When the amounts differ, the invoice opens a `CUSTOMER_INVOICE_EXCEPTION` and stays in Needs Review instead of going out to the customer. The comparison only ever reads `CUSTOMER_RATE_CONFIRMATION` documents — it never compares against a `CARRIER_RATE_CONFIRMATION`. ### Warn instead of block A shipper rule's `exceptionType` field sets what happens when the rule fails. In the app, this is the rule's **When this rule fails** setting. Leave `exceptionType` unset to keep the default behavior shown above, **Block sending**. Set it to `CUSTOMER_INVOICE_WARNING` for **Warn only (don't block)**. A failing warn-only rule raises a `CUSTOMER_INVOICE_WARNING` exception on the invoice instead of a `CUSTOMER_INVOICE_EXCEPTION`. The warning flags the invoice for your team but doesn't hold it back: approving and sending the invoice don't require an override. Approval doesn't close the warning. It resolves when the rule passes, or when someone closes it. # Use these docs with AI tools Source: https://docs.upwell.com/developer-guide/ai-tools Machine-readable exports, an MCP server, and one-click handoffs so your AI assistant can read the Upwell docs while you build. # Use these docs with AI tools Most integrations against Upwell are now written with an AI assistant in the loop. This site ships machine-readable surfaces so that assistant reads the **same verified truth** you do — including the per-endpoint retry and delete semantics baked into the [API reference](/api-reference/introduction) and the generated [vocabulary](/api-reference/vocabulary). > [!NOTE] > > These surfaces cover the **public** docs. Pages that require authentication are not > included in `llms.txt`, `llms-full.txt`, or the Markdown exports — those are built from > the public pages only. ## Point your assistant at the docs > [card] [llms.txt](https://docs.upwell.com/llms.txt) > > A machine-readable index of every public page — the sitemap your AI tool reads first. > Also served at `/.well-known/llms.txt`. > [card] [llms-full.txt](https://docs.upwell.com/llms-full.txt) > > The full content of the public docs in one file, for tools that ingest everything up > front instead of following links. Every page is also available as plain Markdown — append `.md` to its URL (for example, `docs.upwell.com/authentication.md`), or press Cmd+C (Ctrl+C on Windows) on any page to copy it as Markdown for pasting into a conversation. ## The contextual menu The menu at the top of every page bundles these handoffs into one click: copy the page as Markdown, view it raw, open it as context in **Claude** or **ChatGPT**, connect the docs MCP server to **Cursor** or **VS Code**, or copy the MCP server URL. On API reference pages it can also download the OpenAPI spec directly. ## Connect your Upwell workspace data To look up invoices, payments, shipments, or freight documents in your own workspace, follow [Connect your AI assistant to Upwell](/connect-ai-assistant). ## Connect the documentation search server The docs host a search [MCP](https://modelcontextprotocol.io) server at: ```text theme={null} https://docs.upwell.com/mcp ``` Once connected, your AI tool can search and retrieve doc content live while you work — ask it *"is `POST /api/rest/carriers` retry-safe?"* and it answers from the same [idempotency contract](/conventions/idempotency-and-retries) documented here, instead of guessing. > [tab] Claude Code > > ```bash theme={null} > claude mcp add --transport http upwell-docs https://docs.upwell.com/mcp > ``` > [tab] Claude > > 1. Open [Settings → Connectors](https://claude.ai/settings/connectors). > 2. Click **Add custom connector**. > 3. Name it `Upwell docs` and paste `https://docs.upwell.com/mcp`. > 4. In a conversation, click the **+** (attachments) button and select the connector. > [tab] Cursor / VS Code > > Use **Connect to Cursor** or **Connect to VS Code** in the contextual menu at the top > of any page — both install the server in one click. Agents and tools can also discover the server without configuration via the standard discovery document at `/.well-known/mcp`. ## skill.md For agents that consume [skill files](https://agentskills.io), an automatically generated capability summary of the Upwell platform is available at [`docs.upwell.com/skill.md`](https://docs.upwell.com/skill.md). It stays in sync with the docs and requires no maintenance; agents connected to the MCP server can also discover it as an MCP resource. ## What to rely on AI answers are only as good as their source. Two properties of these docs are worth knowing when you delegate to an assistant: * **Generated, not typed** — enum values on the [vocabulary page](/api-reference/vocabulary) and the endpoint schemas in the reference come from Upwell's live OpenAPI pipeline, so an assistant reading them can't inherit hand-typo'd values. * **Behavioral contracts live on the endpoint pages** — where an endpoint has a non-obvious contract (retry safety, delete semantics, in-`200` business errors), it's stamped onto that generated endpoint page, so landing there from search surfaces it. If an assistant's claim about the API contradicts these docs, trust the docs — and if the docs turn out wrong, [tell us](mailto:support@upwell.com); that's a bug we fix at the source. # Can I…? Source: https://docs.upwell.com/developer-guide/can-i The feasibility reference: what the Upwell API supports today, what has caveats, what it does not do, and what is real but undocumented — with a source link for every row. # Can I…? Feasibility before code. **✅ Supported** (documented and real) · **⚠️ Supported with caveats** (read the note) · **❌ Not supported** (today, as documented) · **❓ Undocumented** (the API surface exists in the OpenAPI spec but no guide covers it — treat it as unsupported until a guide describes it). ## Accounts payable | Can I… | | Notes | | - | - | - | | submit carrier invoices via API? | ✅ | [Submission guide](/api-guides/carrier-invoice-submission) | | attach documents and get them AI-classified? | ✅ | Presigned flow only — base64 uploads are filed, never classified ([Integration patterns](/integration-patterns)) | | know when an invoice is processed? | ✅ | Poll signals + webhooks ([status guide](/api-guides/carrier-invoice-status)) | | see every status the lifecycle can produce? | ✅ | Every value is defined in the [Vocabulary](/api-reference/vocabulary#carrier-invoice-statuses), which is generated from the API schema rather than hand-maintained | | own approve/reject in my system? | ✅ | [Approval requests](/api-guides/carrier-invoice-approval) — PATCH `SUCCEEDED`/`FAILED` | | approve an invoice programmatically on the Upwell side? | ❓ | `POST /carrier_invoices/{id}/approve` (+`overrideExceptions`) exists in the spec; no guide covers it | | list only *pending* approval requests? | ⚠️ | The spec declares limit/offset only; list GETs also accept a `?where=` filter that the spec doesn't describe, so a generated client won't expose it — see [filtering](/developer-guide/what-happens-if#reading-data-back) | | read the catalog of exception types/tokens? | ❌ | No catalog of exception tokens is published; treat `exceptions` as an opaque comma-joined string rather than parsing individual tokens ([status guide](/api-guides/carrier-invoice-status)) | | work exceptions (list/resolve) via API? | ❌ | No exceptions resource; lifecycle is UI-documented only ([Exceptions](/concepts/exceptions)) | | record carrier payments? | ✅ | Payment line items + bulk ([submission guide](/api-guides/carrier-invoice-submission)) | | read, correct, or delete carrier payments? | ❓ | GET/PUT/DELETE exist in the spec; guides document POST only | | use bill payments (settlement objects)? | ❓ | Full `bill-payments` endpoint family exists in the spec; no guide covers it yet | | manage bill line items? | ❓ | Endpoints + nested create exist in spec; the bills guide never mentions line items | | pay lumpers/factors (non-carrier payables)? | ✅ | Vendors + `vendorId` on bills ([syncing guide](/api-guides/syncing-foundation-entities)) | | upload & parse POs and vendor invoices? | ✅ | [PO & vendor invoices guide](/api-guides/purchase-orders-and-vendor-invoices) | | get an event when a PO/vendor invoice finishes parsing? | ❌ | No trigger exists in the [catalog](/api-guides/webhook-events); poll `GET /documents/{id}` | | retract/delete a submitted carrier invoice? | ❓ | `DELETE /carrier_invoices/{id}` in spec; no guide, no semantics documented | | configure auto-approval via API? | ❌ | Dashboard settings only ([Approvals](/concepts/approvals)); the auto-approval cadence is not published | ## Accounts receivable | Can I… | | Notes | | - | - | - | | create invoices with line items in one call? | ✅ | Nested `invoiceLineItems` ([guide](/api-guides/customer-invoices)) | | link an invoice to shipments? | ✅ | Nested `invoiceShipments` on create (now in the spec) or `POST /invoice_shipments` ([guide](/api-guides/customer-invoices)) | | make Upwell deliver the invoice (email/EDI/portal)? | ⚠️ | The product does; the API action that triggers delivery is not documented — confirm the delivery contract for your tenant with Upwell | | record customer payments/remittances? | ✅ | [Customer payments](/api-guides/customer-payments) | | have payments auto-update invoice balance/status? | ✅ | Invoice-linked payment line items recalculate both in the standard model ([requirements](/api-reference/ar-overview#payment-ledger-model-recommended)) | | update or unapply a payment line item? | ✅ | Correct with `PUT`; unapply with `DELETE` ([guide](/api-guides/customer-payments#correct-or-reverse-an-application)) | | get events for payments recorded inside Upwell? | ⚠️ | Triggers exist ([catalog](/api-guides/webhook-events)); their payload shapes are not documented | | drive reminders/dunning via API? | ❌ | No reminders API exists — email reminders are configured in the dashboard ([Payment Reminders](/accounts-receivable/reminders)) | | manage payment plans / disputes / bank feeds via API? | ❌ | No API surface; banking-integration ingestion is Upwell-operated ([Remittances](/accounts-receivable/remittances)) | | integrate the customer payment portal? | ❓ | Payments land as ordinary `customer_payments` ([Online Payments](/accounts-receivable/online-payments)); `portalSlug` exists on invoice reads; no portal API is documented | | track whether a customer opened an invoice? | ❓ | `VIEWED` exists in the status enum; no page explains who sets it or when | | send statements / list bills? | ⚠️ | Statements are a product feature, not a public API; your integration must keep their source balances accurate ([requirements](/api-reference/ar-overview#what-statements-use)) | ## Foundation data & sync | Can I… | | Notes | | - | - | - | | push customers, carriers, shipments, companies, bills? | ✅ | [Syncing foundation entities](/api-guides/syncing-foundation-entities) | | bulk-load for the initial sync? | ⚠️ | bulk-customers/carriers/bills exist; **no bulk-shipments**; batch failure semantics differ per endpoint | | upsert everything by my own IDs? | ⚠️ | Works everywhere except **addresses** (no external key — store `addr_` ids); POST duplicate semantics differ per resource | | get called back when foundation data changes in Upwell? | ❌ | By design — no foundation-entity triggers ([catalog](/api-guides/webhook-events)) | | search/filter server-side? | ⚠️ | `POST /search` on 12 resources; addresses/companies have none; list GETs also accept `?where=`, which the spec doesn't declare ([details](/developer-guide/what-happens-if#reading-data-back)) | | page safely through big collections? | ✅ | limit/offset; **default limit is 10** — always pass it explicitly ([API conventions](/api-reference/introduction)) | | model multi-stop routes? | ⚠️ | `stops` nested + standalone CRUD; a stop has both a free-text `stopType` and an enum `type`, read by different surfaces — populate both ([Vocabulary](/api-reference/vocabulary#stop-types)) | | model bill-to hierarchies? | ✅ | `billToCustomerId` ([syncing guide](/api-guides/syncing-foundation-entities)) | | merge duplicate customers? | ❌ | Internal operation; treat `mergedIntoCustomerId` as read-only ([syncing guide](/api-guides/syncing-foundation-entities)) | ## Events & platform | Can I… | | Notes | | - | - | - | | subscribe to carrier-invoice lifecycle events? | ⚠️ | Per-status triggers only for `APPROVED`/`EXCEPTION`; no `PAID`/`UNDER_REVIEW` triggers ([status guide](/api-guides/carrier-invoice-status)) | | subscribe to carrier-document / invoice-APPROVED events? | ⚠️ | Exist but not self-service — marked † in the [catalog](/api-guides/webhook-events); contact support | | manage webhook subscriptions via API? | ❌ | Dashboard only ([webhooks guide](/api-guides/webhooks)) | | verify deliveries cryptographically (HMAC)? | ❌ | Static header/Basic auth only — no signing or replay protection ([webhooks guide](/api-guides/webhooks)) | | inspect or replay past deliveries? | ❌ | No surface exists; recover by polling ([webhooks guide](/api-guides/webhooks), Reliability) | | trust that 4xx responses will be retried? | ❌ | **Only `429` is retried. Other 4xx responses are recorded as delivered.** Alert on your own 4xx rate ([webhooks guide](/api-guides/webhooks)) | | test against a sandbox? | ⚠️ | `staging.api.upwell.com` exists; access is provisioned by Upwell, and keys are environment-specific ([Environments](/authentication#environments)) | | plan around published rate limits? | ✅ | None exist today — no `429`/`X-RateLimit-*` ([Error handling](/api-reference/error-codes)) | | serve many Upwell tenants with one credential? | ❌ | One API key = one organization; no partner credential ([Key scope](/authentication#key-scope)) | | rotate/revoke an API key? | ✅ | Create → switch → revoke, in the dashboard; no key-management API ([Authentication](/authentication)) | | generate a client from the OpenAPI spec? | ✅ | The spec declares auth, required fields, real enums, nested inserts, and 400/401 responses; one caveat — the `where`/`orderBy` filters that some list GETs accept are not in the spec ([details](/developer-guide/what-happens-if#errors-limits-and-the-reference)) | | follow API changes over time? | ⚠️ | The [changelog](/changelog) is the channel; entries are docs-only so far, and no deprecation policy is published | > [!NOTE] > > Rows marked ❓ are opportunities as much as risks: the surface exists and is tenant-scoped like > everything else, but it is undocumented, so treat it as unsupported until a guide describes it. > If a ❓ row is on your critical path, tell us at > [support@upwell.com](mailto:support@upwell.com) — we'll answer directly and then document it. > Something else missing or wrong on this page? Same address. # Choose your integration path Source: https://docs.upwell.com/developer-guide/choose-your-path Start from what you want to accomplish, pick the right integration path, and know the prerequisites, first successful call, and production checklist for each. # Choose your integration path This page routes you from **goal** to **integration path**. Each path lists its prerequisites in order, the shortest route to a first successful call, and the checklist that separates a demo from a production integration. It links into the deeper guides rather than repeating them. ## Orient yourself first (10 minutes) Whatever your path, read these two pages first — everything else assumes them: > [card] [Core concepts & data model](/concepts/data-model) > > The dozen objects and the two sides: AR (invoice your customers) and AP (audit what carriers bill you). Five minutes that prevents the classic mis-mappings. > [card] [Integration patterns](/integration-patterns) > > The cross-cutting mechanics: integer-cents money, the `input` wrapper, `sourceSystem`/`sourceSystemId` upserts, per-resource retry semantics, addresses, deletes. Three facts to carry into every path: 1. **Auth** — send your API key in the `Authorization` header; bare or `Bearer`-prefixed both work. Keys are self-serve in the dashboard and **scoped to one organization** — an integration serving several Upwell customers holds one key per customer, and keys are environment-specific. See [Authentication](/authentication). 2. **Money is integer cents.** `$2,847.50` → `284750`. Floats are rejected at runtime ([Money & payloads](/conventions/money-and-payloads)). 3. **Writes are not uniformly retry-safe.** `POST` duplicate handling differs per resource — customers hard-fail, carriers silently no-op, carrier invoices dedupe asynchronously. See [What happens if I retry a POST?](/developer-guide/what-happens-if) before writing retry code. ## Which developer are you? > [accordion] I'm at a TMS / platform vendor, evaluating a native integration > > Read the two orientation pages, then [Syncing foundation entities](/api-guides/syncing-foundation-entities) > to size the sync engine, and the [webhook event catalog](/api-guides/webhook-events) to see > exactly which events Upwell will and won't push to you (foundation entities: none — your TMS > stays the system of record). > > The operational facts to plan around: > > * **Credential model at scale.** One API key per customer organization, created inside each > customer's own dashboard — there is no partner-level or cross-tenant credential, and no > published partner/certification program today. Engage > [support@upwell.com](mailto:support@upwell.com) (or your Upwell contact) to coordinate a > multi-customer rollout. See [Key scope](/authentication#key-scope). > * **Pre-production access.** A staging environment exists at > `https://staging.api.upwell.com`; access is provisioned by Upwell rather than self-serve — > see [Environments](/authentication#environments). > * **Operational guarantees.** No SLA or status page is published, and the > [changelog](/changelog) is where API and platform changes will be announced. If your > evaluation needs availability or support commitments beyond that, > [support@upwell.com](mailto:support@upwell.com) (or your Upwell contact) will route you > to the right team. > [accordion] I'm at a broker/carrier that uses Upwell — 'get us connected' > > Your path is almost always: get an API key → push foundation data → pick the AP or AR flow > below. Follow the [developer quickstart](/quickstart) top to bottom. API keys are generated > in the Upwell dashboard (**Account → API keys**) by any org member — if you don't see the > page, ask your Upwell admin to have it enabled ([Authentication](/authentication)). > [accordion] I only need to consume events (ship data into my system) > > You can be read-only: subscribe to webhooks in the Upwell dashboard (there is no > subscription API) and correlate deliveries back via `GET` calls. Start with > [Outbound webhooks](/api-guides/webhooks), then the [event catalog](/api-guides/webhook-events) > — and read the reliability notes in Path D below, especially the non-`429` 4xx behavior. > [accordion] I need to know if something is even possible > > Go straight to [Can I…?](/developer-guide/can-i) — a feasibility table for the questions > integrators actually ask, each row with a link to the page that documents it. ## Path A — AP: submit and track carrier invoices *You have carrier invoices (What a carrier actually billed you (AP) — the received payable, audited against the bill.) (your own, or your carriers') and want Upwell to audit, approve, and track them.* **1. Prerequisites, in dependency order** 1. API key ([Authentication](/authentication)). 2. Carriers, then shipments — a shipment needs `customerId`/`carrierId`, a **required** `shipmentId` string of your own, and `carrierProNumber` (the strongest invoice-match key). See [Syncing foundation entities](/api-guides/syncing-foundation-entities). 3. Bills (What your TMS says you expect to owe a carrier for a shipment — the expected payable.) — optional but strongly recommended: without a bill there is no expected amount, so no amount-mismatch audit. Note `bills.proNumber` must equal the shipment's `shipmentId` (it is *not* the carrier's PRO — that goes on the shipment as `carrierProNumber`). **2. First successful call** `POST /api/rest/carrier_invoices` with the `input` wrapper, then attach the invoice PDF via the presigned flow. Follow [Submitting carrier invoices](/api-guides/carrier-invoice-submission) literally — including its warning that only the **presigned** upload path runs AI classification. **3. Observe the result** Ingestion is asynchronous. Poll `GET /api/rest/carrier_invoices/{id}` for `updatedAt > createdAt`, then read `exceptions` (a comma-joined string, empty = clean) and `shipmentId`. Don't judge `exceptions` before ingestion — matching findings clear on their own. Full signal table: [Knowing when a carrier invoice is processed](/api-guides/carrier-invoice-status). **4. Production checklist** * Webhooks **and** a reconciliation poll — a missed delivery must not strand an invoice ([carrier-invoice status guide](/api-guides/carrier-invoice-status)). * Retry handling for submits: a retried `POST` can hand you the id of the row async-dedup will soft-delete — reconcile per [Re-submitting](/api-guides/carrier-invoice-submission#re-submitting). * Error handling against **flat string errors** (`{"error": "Not-NULL violation…"}`), not a structured envelope — see [Error handling](/api-reference/error-codes). * Decide your approval model now: manual / auto-approval / external request — they gate differently on exceptions (A flagged audit finding on an invoice — a mismatch, missing document, or failed match. Open exceptions gate approval.) ([How approvals work](/concepts/approvals)). If your system owns the decision, build [the approval-request responder](/api-guides/carrier-invoice-approval). * Record settlements with carrier payment line items ([submission guide, payments section](/api-guides/carrier-invoice-submission)). ## Path B — AR: create customer invoices and record payments *You bill shippers (The shipper — the party you bill and collect from (AR).) and want Upwell to deliver invoices (What YOU bill your customer — accounts receivable, money in. An unqualified "invoice" always means this.) and manage receivables.* **1. Prerequisites, in dependency order** 1. API key. 2. Customers — each with a `CUSTOMER_BILLING` address (a separate, typed address record; at most one per customer; it drives the invoice bill-to block). See [Working with addresses](/conventions/addresses). 3. Shipments referencing those customers. **2. First successful call** `POST /api/rest/invoices` — include `balance` (equal to `totalAmount` for a new invoice), line items, and shipment links. Follow [Customer invoices](/api-guides/customer-invoices). **3. Know the two AR ownership questions** * **Who triggers delivery?** Upwell delivers invoices by email/EDI/portal per customer configuration; the API action that initiates delivery is not currently documented. Confirm the delivery contract for your tenant with your Upwell contact before assuming a `PUT` sends anything. * **Who owns the outstanding balance?** In the recommended payment-ledger model, your integration sends complete invoice-linked payment applications and Upwell recalculates `balance` and payment status. If your source cannot provide that ledger, agree on an authoritative-balance model with Upwell before implementation. See the [AR integration requirements](/api-reference/ar-overview#keep-outstanding-balances-accurate). **4. Production checklist** * Record remittances with [customer payments](/api-guides/customer-payments), including one line item per invoice application. Backfill every application that contributes to an open invoice's cutover balance, and update or delete the original line item for corrections and reversals. * Reconcile invoice balances by customer before enabling statements, reminders, or hosted payments. * Subscribe to `update.invoice.status.SENT` and payment/remittance triggers ([event catalog](/api-guides/webhook-events)). Payload shapes for these events are not documented and vary by trigger — correlate on `resourceId` from the envelope and refetch the resource via `GET` rather than depending on payload fields. * The AR feature pages (reminders, online payments) describe product capabilities — check [Can I…?](/developer-guide/can-i) for what has API surface today. ## Path C — Documents only: purchase orders & vendor invoices *You have PDFs (POs, vendor invoices, combined stacks) and want Upwell to parse them.* No foundation entities required — these upload standalone: presign → PUT bytes → poll the document status (`GET /api/rest/documents/{id}`), then read the parsed record via the search endpoints. Follow [Purchase orders & vendor invoices](/api-guides/purchase-orders-and-vendor-invoices). Two things to plan around: parsing completion has **no webhook trigger** — polling is the only mechanism (the [event catalog](/api-guides/webhook-events) has no purchase-order or vendor-invoice triggers) — and re-using a `sourceSystem`/`sourceSystemId` pair at presign fails fast with `DOCUMENT_ALREADY_UPLOADED` (unlike carrier invoices' async dedup). ## Path D — Events-only consumer *Upwell is the system of action; you mirror its events.* 1. Host an HTTPS receiver; subscribe in the dashboard with a custom auth header ([Outbound webhooks](/api-guides/webhooks)). 2. Branch on the envelope's `trigger`, correlate on `resourceId`, and **refetch the resource via GET** rather than trusting payload shapes — they vary by trigger. 3. Reliability facts for your on-call runbook (full detail in the [webhooks guide](/api-guides/webhooks)): * Timeout 15 s per delivery; `429`, `5xx`, timeouts, and network failures retry with exponential backoff (1, 2, 4, … minutes); `retryAttempts: N` means N retries *beyond* the first attempt (default 3). * **A `4xx` other than `429` from your receiver is recorded as delivered and is never retried.** If your auth middleware breaks, events are silently lost — alert on your own 4xx rate. * There is no delivery-inspection or replay surface; recover by polling the resource endpoints. * There is no payload signing (HMAC) — treat your configured header secret like a password. 4. Know what never fires: foundation entities (customers, carriers, shipments, addresses, companies) have no triggers — poll if you need to read them back ([event catalog](/api-guides/webhook-events)). ## Before you write retry code, read these two > [card] [What happens if…?](/developer-guide/what-happens-if) > > The consequence reference: retries, duplicates, deletes, pagination, webhooks misbehaving — what actually happens down each branch. > [card] [Can I…?](/developer-guide/can-i) > > The feasibility reference: supported, supported-with-caveats, not supported, or undocumented — with a source link for every row. If your path isn't covered here, or you hit something these guides don't answer, email [support@upwell.com](mailto:support@upwell.com). # What happens if…? Source: https://docs.upwell.com/developer-guide/what-happens-if The consequence reference: what the system actually does when you retry, duplicate, delete, paginate, or misconfigure — one answer per question, with sources. # What happens if…? Docs usually tell you the happy path. This page tells you what happens down the *other* branch — the retry, the duplicate, the delete, the misconfigured receiver. Each answer links its source. If the question blocking you isn't answered here, ask [support@upwell.com](mailto:support@upwell.com). ## Writes and retries > [accordion] …I POST the same customer / shipment / invoice twice? > > The second `POST` fails with `400 Uniqueness violation` on the > `(sourceSystem, sourceSystemId)` pair. First sync is `POST`, every later change is `PUT`. > Source: [Idempotency & retries](/conventions/idempotency-and-retries). > [accordion] …I POST the same carrier twice? > > It **silently succeeds and changes nothing** — a no-op upsert that does not update `name`, > `email`, `phone`, or anything else you sent. If you meant to update, use `PUT`. Source: > [Syncing foundation entities](/api-guides/syncing-foundation-entities). > [accordion] …I POST the same carrier invoice twice (e.g. a retry after a timeout)? > > Both inserts succeed and return **different ids**. Seconds later, an async dedup pass > soft-deletes the **newer** row, keyed on `(tenant, sourceSystemId)` — note: not scoped by > integration, so two integrations reusing id strings collide. The id your retry returned may > be the deleted one; reconcile by looking the invoice up by `sourceSystemId` afterward, and > filter [`deletedAt`](/conventions/dates-and-times#deleted-at) null in the same `where` — the list returns soft-deleted rows too. Poll > until the **same** single live row comes back a few seconds apart: two rows means dedup > hasn't run, and a lone row seen too early can still lose the race to the original insert. > Source: [Re-submitting](/api-guides/carrier-invoice-submission#re-submitting). One caveat on > the lookup itself — see [filtering a list](#reading-data-back) below. > [accordion] …I re-request a presigned upload URL for the same document pair? > > Fails fast with `400 DOCUMENT_ALREADY_UPLOADED` — synchronous, unlike carrier invoices. > Exception: re-requesting one whose upload never completed returns a fresh URL for the same > document. Source: [Purchase orders & vendor invoices](/api-guides/purchase-orders-and-vendor-invoices). > [accordion] …a duplicate sneaks into a bulk batch? > > `bulk-carriers`: the **entire batch fails** (no upsert). `bulk-bills`: upserts like its > singular endpoint. Neither reports partial success, and Upwell does not document which row > caused the failure — validate batch contents before sending. Source: > [Syncing foundation entities](/api-guides/syncing-foundation-entities). > [accordion] …I send money as dollars-and-cents floats? > > Runtime rejection: `"The value 2847.5 lies outside the bounds or is not an integer."` All > monetary fields are integer cents. Source: [Money & payloads](/conventions/money-and-payloads). > [accordion] …I omit a required field that has no server default? > > `400` with the column name in a flat error string, e.g. `"Not-NULL violation. null value in > column \"shipment_id\"…"`. Known cases: `shipments.shipmentId`, `invoices.balance` — the > OpenAPI spec marks these `required`, so generated clients catch them before the wire. > Source: [Integration patterns](/integration-patterns). ## Errors, limits, and the reference > [accordion] …a call fails — what shape is the error? > > A **flat object**: `{"error": ""}`, sometimes with a `code` such as > `constraint-violation` or `bad-request`. An invalid or missing API key returns `401` with > `error`, `path`, and `code: "access-denied"`. There is no nested error envelope. The > message→fix table lives in [Error handling](/api-reference/error-codes). > [accordion] …I exceed the rate limit? > > There is currently **no rate limiting** on the API — no `429`, no `X-RateLimit-*` headers, > no `Retry-After`. A `429` you observe came from your own proxy or gateway. Design your > client politely (bounded concurrency, backoff on `5xx`), but don't build 429 machinery. > Source: [Error handling](/api-reference/error-codes). > [accordion] …I generate a client from the published OpenAPI spec? > > It now declares authentication (`ApiKeyAuth` in the `Authorization` header), the > machine-enforced required fields, the real UPPER_SNAKE_CASE status enums, the nested > `invoiceShipments` insert, and generic `400`/`401` responses. One remaining caveat: the > `where`/`orderBy` filters that some list `GET`s accept are **not** in the spec, so they > won't appear in a generated client. Prefer the `POST /search` endpoints for filtering. ## Reading data back > [accordion] …I GET a list endpoint with no parameters? > > You get the **first 10 records** — the default `limit` is 10 (a handful of endpoints default > to 100). Nothing marks the response as truncated. Always pass `limit`/`offset` explicitly. > Source: [API conventions](/api-reference/introduction). > [accordion] …I need to filter a list server-side? > > Three cases: > > 1. `POST //search` exists for customers, carriers, shipments, shipment line items, > invoices, bills, bill payments, customer payments (+ line items), vendors, purchase > orders, vendor invoices — use it ([Integration patterns](/integration-patterns)). > 2. Addresses and companies have **no** search — page the collection or go through the parent. > 3. List GETs also accept a `?where=` JSON filter, but the spec doesn't declare it — so a > client generated from the spec won't expose it, and you'd be hand-rolling the request. > Prefer `POST //search` where it exists; otherwise page the collection. > [accordion] …I try to read back an address I created nested under a company? > > You can't get its id from the create response (`POST /api/rest/companies` returns no address > ids), companies expose no address read path, and addresses carry no external key — the row > is recoverable only by paging `GET /api/rest/addresses`. Create company addresses standalone > instead. Source: [Working with addresses](/conventions/addresses). ## Deletes > [accordion] …I DELETE a customer? > > **Hard delete**, and its addresses go with it — and per the > [AR overview](/api-reference/ar-overview), its invoices too. The external key pair is freed. > Prefer the reversible soft delete (`PUT` with [`deletedAt`](/conventions/dates-and-times#deleted-at)), which frees the key equally — > it is the documented way to deactivate a customer, and no separate deactivate endpoint is > published. Source: [Deleting and archiving](/conventions/deletes-and-archiving). > [accordion] …I DELETE a company? > > **Soft delete** — the record disappears from the app, its (case-insensitively unique) name > is freed, and its addresses are orphaned rather than removed. Source: > [Deleting and archiving](/conventions/deletes-and-archiving). > [accordion] …I DELETE a vendor that still has bills? > > It fails outright (restrict-on-delete). Reassign or remove the bills first. Vendor deletes > are permanent — no soft-delete column. Source: > [Syncing foundation entities](/api-guides/syncing-foundation-entities). > [accordion] …I DELETE a rule I might want back? > > Gone permanently — rules never soft-delete. Set `enabled: false` instead. Source: > [Rules](/conventions/rules). ## Webhooks misbehaving > [accordion] …my receiver returns 429, 5xx or times out? > > The delivery retries — `429`, `5xx`, timeouts, and network failures all count — up to the > subscription's `retryAttempts`, with exponential backoff (1 min, 2 min, 4 min, …). > `retryAttempts: 3` (the default) means up to **4 total deliveries**. Each attempt has a > 15-second timeout — ack fast, work async. Source: > [Outbound webhooks](/api-guides/webhooks). > [accordion] …my receiver returns another 4xx (bad auth config, wrong route)? > > **Any `4xx` other than `429` is recorded as delivered and never retried.** This is the silent-loss case: > Upwell's side shows success while your side rejected everything. Alert on your receiver's > 4xx rate; reconcile by polling. Source: [Outbound webhooks](/api-guides/webhooks), > Reliability. > [accordion] …I miss deliveries entirely (outage on my side)? > > After retries exhaust, there is no automatic replay and no delivery-inspection surface — > recovery is polling the resource endpoints (`GET /carrier_invoices/{id}` etc.), which the > [status guide](/api-guides/carrier-invoice-status) recommends running periodically anyway. > Source: [Outbound webhooks](/api-guides/webhooks), Reliability. > [accordion] …I subscribe to update.carrier_invoice expecting every change? > > Each change fires **at most one** trigger — the most specific that applies. A tracked status > transition (e.g. to `APPROVED`) fires only `update.carrier_invoice.status.APPROVED`, *not* > also the generic `update.carrier_invoice`. Subscribe to every trigger you care about. > Source: [Webhook event catalog](/api-guides/webhook-events). > [accordion] …I want carrier-document or customer-invoice-APPROVED events? > > Those four triggers (`create/update/delete.carrier_document`, > `update.invoice.status.APPROVED`) exist in the dispatcher but are **not self-service** — > they're marked † in the [event catalog](/api-guides/webhook-events); contact support to > enable them. > [accordion] …a customer/carrier/shipment changes inside Upwell? > > No webhook fires — foundation entities have no triggers by design; your system remains the > system of record and reads state back by polling. Source: > [Webhook event catalog](/api-guides/webhook-events). ## Lifecycle surprises > [accordion] …my new carrier invoice immediately shows exceptions? > > Expected. A brand-new row lists matching findings ("no matching shipment / bill") that clear > on their own when ingestion completes. Wait for `updatedAt > createdAt` before judging > `exceptions`. Source: [Carrier invoice status](/api-guides/carrier-invoice-status). > [accordion] …an invoice sits in a status my table doesn't list? > > Every carrier-invoice status value is defined in the > [Vocabulary](/api-reference/vocabulary#carrier-invoice-statuses), which is generated from the > API schema at each docs build rather than hand-maintained — start there, and handle an > unrecognized value defensively rather than switching exhaustively. The three easiest to hit > unexpectedly: `AWAITING_BILL` (matched to a shipment, no bill linked yet — it promotes itself > to `RECEIVED`), and the terminal pair `CANCELLED` and `REFUNDED`, which drop the invoice out > of the actionable queues. > [accordion] …an approval request is resolved FAILED? > > The request is recorded as rejected and the invoice's `status` is left exactly where it > was — Upwell does not move it to `REJECTED` or `EXCEPTION` for you. Only `SUCCEEDED` > moves an invoice, to `APPROVED`. If your workflow needs the invoice to reflect the > rejection, write that status yourself. Source: > [How approvals work](/concepts/approvals), > [Responding to approval requests](/api-guides/carrier-invoice-approval). > [accordion] …a clean invoice isn't auto-approving? > > Auto-approval runs on a schedule, not instantly; it only touches invoices with no open or > in-progress exceptions, matched to a bill and carrier, inside your guardrails — and the > master switch is off by default. The sweep is periodic rather than event-driven, so expect > a lag of minutes between an invoice becoming eligible and it being approved. Source: > [How approvals work](/concepts/approvals). > [accordion] …I apply a customer payment via the API — does the invoice update itself? > > Yes, when you create a payment line item linked to the invoice. Upwell recalculates the > invoice's `balance` and derives `PART_PAID` or `PAID` in the standard API-managed model. A > payment header alone has no invoice effect, and changing only a status does not reverse an > application — update or delete the original line item instead. Source: > [Customer payments](/api-guides/customer-payments#how-applications-update-invoices), > [AR integration requirements](/api-reference/ar-overview#keep-outstanding-balances-accurate). > [accordion] …I upload a rate confirmation with the wrong documentType? > > It is parsed and stored as what you labeled it — a carrier rate con typed > `CUSTOMER_RATE_CONFIRMATION` pollutes customer-side validation and vice versa. Re-type and > re-process rather than editing amounts; never let carrier cost reach the customer side. > Source: [Document conventions](/conventions/documents). > [accordion] …I save an address that never shows up in the app? > > Almost always a `type` problem: pages render only specific types (`CUSTOMER_BILLING`, > `COMPANY_ADDRESS`), and `ADDRESS_BOOK` is read by nothing. The write succeeded; the page > filtered it out. Debug order and per-page field lists: > [Working with addresses](/conventions/addresses). # Integration patterns Source: https://docs.upwell.com/integration-patterns The cross-cutting conventions every integration needs # Integration patterns The endpoint reference describes *what* each endpoint accepts. These pages cover the *how* — the cross-cutting patterns and gotchas we've seen customers hit when building against Upwell. If you followed a link to a specific section of this page, pick it from the cards below — each topic has its own page. > [card] [Money & payloads](/conventions/money-and-payloads) > > Integer-cents money, the `input`/`inputs` wrappers, and the auth header. > [card] [Idempotency & retries](/conventions/idempotency-and-retries) > > Your external key, per-resource POST duplicate semantics, and required fields with no defaults. > [card] [Documents](/conventions/documents) > > The presigned upload flow, the sourceSystem pair rule, and rate-confirmation typing. > [card] [Addresses](/conventions/addresses) > > The full address playbook — link direction, types, visibility, and the one-billing-address rule. > [card] [Deletes & archiving](/conventions/deletes-and-archiving) > > Hard vs. soft delete per resource, and external-key reuse. > [card] [Rules](/conventions/rules) > > The three rule shapes and a worked DSL example. # Welcome to Upwell Source: https://docs.upwell.com/introduction Streamline your logistics accounts payable and receivable processes with our intelligent automation platform ![The Upwell carrier document queue, listing ingested carrier documents with their status, carrier, and matched load](https://mintcdn.com/upwell/-Pwd7QcUk6Cnh82_/images/carrier-docs-all.png?fit=max\&auto=format\&n=-Pwd7QcUk6Cnh82_\&q=85\&s=6aa3e9fe98464a26f83ee0b5cb6fa8d5) ## Transforming Logistics Finance Operations Upwell's intelligent automation platform revolutionizes how logistics companies handle accounts payable and receivable processes. Our solution eliminates manual data entry, reduces errors, and accelerates payment cycles to optimize your cash flow. > [card] [Quick Start Guide](/quickstart) > > Set up your account, connect your TMS, and route carrier invoices in for processing > [card] [Authentication Setup](/authentication) > > Learn how to authenticate with the Upwell API ## For Developers & TMS Partners Building an integration? Start here. > [card] [Core Concepts & Data Model](/concepts/data-model) > > Understand the objects — shipments, invoices, bills, carriers — and how they connect > [card] [Syncing Foundation Entities](/api-guides/syncing-foundation-entities) > > Push customers, carriers, shipments, and bills from your TMS > [card] [Carrier Invoice Submission (AP)](/api-guides/carrier-invoice-submission) > > Submit carrier invoices for audit and matching > [card] [Customer Invoices (AR)](/api-guides/customer-invoices) > > Create and manage customer invoices and line items > [card] [Purchase Orders & Vendor Invoices](/api-guides/purchase-orders-and-vendor-invoices) > > Upload, parse, and manage purchase orders and vendor invoices via the API ## Core Features Discover how Upwell's powerful features can transform your financial operations. > [card] [Carrier invoice audit](/accounts-payable/carrier-invoice-audit) > > Automate invoice processing, approval workflows, and payment scheduling > [card] [AR Automation](/accounts-receivable/receivables) > > Streamline billing, collections, and reconciliation with machine learning > [card] [Navigation Guide](/user-interface/navigation-guide) > > Learn to navigate the Upwell dashboard and main platform sections > [card] [User Roles](/user-interface/user-roles) > > Understand user roles, permissions, and access controls ## Resources for Success Access everything you need to maximize your investment in Upwell. > [card] [Troubleshooting](/troubleshooting) > > Common issues and solutions for using the Upwell platform > [card] [API Reference](/api-reference/introduction) > > Integrate Upwell's capabilities into your existing systems > [card] [Error Handling](/api-reference/error-codes) > > Real error shapes, messages, and retry guidance > [card] [Support Center](mailto:support@upwell.com) > > Contact our customer success team for assistance # Quickstart Source: https://docs.upwell.com/quickstart Get started with Upwell in 5 simple steps ## Getting Started with Upwell Follow these steps to set up your Upwell account and start processing carrier invoices. ### Initial Setup > [accordion] 1. Log in to Upwell > > Use the email address provided by your account manager to access your Upwell account. > If you haven't received your login credentials, please contact your account manager. > [accordion] 2. Configure TMS Integration > > Navigate to the Integrations page to set up your Transportation Management System (TMS) integration: > > 1. Click on "Integrations" in the main navigation > 2. Select your TMS provider > 3. Follow the provider-specific configuration steps > 4. Test the connection to ensure proper data flow > [accordion] 3. Set up Shipper Portal Integrations > > Configure your shipper portal connections to enable automated rate validation: > > 1. Go to the Shipper Portal section > 2. Add your carrier credentials > 3. Verify the connection for each carrier ### Final Configuration > [accordion] 4. Configure Inbound Email Settings > > Set up your email configuration to receive carrier invoices: > > 1. Navigate to Email Settings > 2. Configure your dedicated invoice processing email address > 3. Set up any required email filters or rules > [accordion] 5. Start Processing Invoices > > Begin sending carrier invoices to your configured email address. The system will automatically: > > * Receive and process incoming invoices > * Match invoices against shipment data > * Validate rates and accessorials > * Flag any discrepancies for review ## For Developers If you're building a TMS integration or working with the Upwell API directly, start here instead: **1. Get your API key** Create one in the Upwell dashboard under **Account → API keys** — it authenticates every request via the `Authorization` header (with or without a `Bearer` prefix, both work). See [Authentication](/authentication). ![The API keys page under Account, with the Add API Key button above an empty list of keys](https://mintcdn.com/upwell/-Pwd7QcUk6Cnh82_/images/settings-api-keys.png?fit=max\&auto=format\&n=-Pwd7QcUk6Cnh82_\&q=85\&s=6f6b5ae0f8d8b544431924d47e2c32e4) Account then API keys. Add API Key issues a key; the value is shown once, at creation. **2. Learn the data model** Understand the core objects (shipments, invoices, bills (What your TMS says you expect to owe a carrier for a shipment — the expected payable.), carrier invoices (What a carrier actually billed you (AP) — the received payable, audited against the bill.), payments) and how they relate. See [Core concepts & data model](/concepts/data-model). **3. Sync your foundation data** Push customers, carriers, shipments, and bills from your TMS. See [Syncing foundation entities](/api-guides/syncing-foundation-entities). **4. Build your AP or AR flow** Choose your starting point: [Carrier invoice submission (AP)](/api-guides/carrier-invoice-submission), [Customer invoices (AR)](/api-guides/customer-invoices), or [Purchase orders & vendor invoices](/api-guides/purchase-orders-and-vendor-invoices). **5. Subscribe to webhooks** Get notified when invoices are processed, approved, or hit exceptions. See [Outbound webhooks](/api-guides/webhooks). > [!TIP] > > Read [Integration patterns](/integration-patterns) for cross-cutting conventions: integer-cents money, the `sourceSystem` / `sourceSystemId` upsert key, the `input` wrapper, and the presigned-upload flow. ## Need Help? > [card] [Contact Support](mailto:support@upwell.com) > > Get help from our support team. > [card] [API Reference](/api-reference/introduction) > > Browse our detailed API documentation. > [card] [Troubleshooting](/troubleshooting) > > Find solutions to common issues. > [card] [Authentication Guide](/authentication) > > Learn how to authenticate with the API. # Troubleshooting Guide Source: https://docs.upwell.com/troubleshooting Common issues and solutions for using the Upwell platform ## Quick Troubleshooting Checklist > [accordion] Before You Start > > Before diving into specific issues, verify these basics: > > * ✅ Your API key is valid and hasn't been revoked > * ✅ You're using the correct base URL: `https://api.upwell.com` > * ✅ All required headers are included > * ✅ Request format follows the API specification > * ✅ You have sufficient permissions for the operation ## Common Issues and Solutions ### Authentication Problems > [accordion] API Key Not Working > > **Symptoms**: Getting 401 Unauthorized errors > > **Solutions**: > > 1. **Verify the header format** > The key is an opaque string — send it exactly as issued, bare or with a `Bearer ` prefix > (both are accepted): > ```bash theme={null} > curl -H "Authorization: YOUR_API_KEY" https://api.upwell.com/api/rest/invoices > curl -H "Authorization: Bearer YOUR_API_KEY" https://api.upwell.com/api/rest/invoices > ``` > Watch for copy-paste issues: whitespace, quotes, or a truncated key. > > 2. **Confirm the key wasn't revoked** > * Log into your Upwell dashboard > * Navigate to **Account → API keys** > * Confirm the key still appears in the list. Keys don't expire, but a revoked key stops > working immediately. > > 3. **Rotate the key** > * Create a new key (**Add API Key**), update your application with it, > then revoke the old one. The key value is shown only once at creation. > * See [Authentication](/authentication) for the full flow. > [accordion] Permission Denied Errors > > **Symptoms**: Getting 403 Forbidden errors > > **Solutions**: > > 1. **Check User Permissions** > * Verify your user account has the necessary permissions > * Contact your administrator to update permissions > 2. **Check which organization the key belongs to** > * An API key is scoped to the one Upwell organization it was created in — it cannot > read or write another organization's data > * If you work with multiple Upwell organizations, confirm you're using the right > organization's key > 3. **Resource Access Rights** > * Ensure you have access to the specific customer/carrier data > * Verify organization-level permissions ### Data Integration Issues > [accordion] Invoice Upload Failures > > **Symptoms**: Invoices not processing correctly > > **Solutions**: > > 1. **Use the right upload path for the file** > * The inline base64 document endpoints reject payloads past a few MB — use the > [two-step presigned upload](/conventions/documents#document-upload-two-step-presigned-url) > for anything larger. > * For carrier-invoice documents, the presigned flow is the **only** path that runs AI > classification — a PDF sent through a base64 endpoint is filed but never classified > or parsed. > 2. **Verify Email Ingestion** > * Emailed invoices must go to your organization's **dedicated inbound address** — > find or configure it under **Email Settings** in the dashboard (see the > [quickstart](/quickstart)), and confirm senders are forwarding to exactly that > address. > 3. **Check classification status** > * A document's `type` stays `UNKNOWN` while classification is in flight; one still > `UNKNOWN` well past upload needs manual review rather than a retry — see > [Knowing when a carrier invoice is processed](/api-guides/carrier-invoice-status). > [accordion] TMS Integration Problems > > **Symptoms**: Shipment data not syncing > > **Solutions**: > > 1. **Connection Testing** > ```bash theme={null} > curl -X GET "https://api.upwell.com/api/rest/shipments" \ > -H "Authorization: YOUR_API_KEY" > ``` > > 2. **Data Format Validation** > * Ensure shipment IDs match between systems > * Verify date formats are ISO 8601 compliant > * Check required fields are populated > > 3. **Webhook Configuration** > * Verify webhook URLs are accessible > * Check SSL certificate validity > * Confirm webhook authentication is configured > [accordion] Payment Processing Issues > > **Symptoms**: Payments not applying to invoices > > **Solutions**: > > 1. **Check the payment's line items** > * A payment applies to invoices **through its line items** — each line item must > carry the target `invoiceId` and an integer-cents `totalAmount`. A payment with no > line items applies to nothing. See [Customer payments](/api-guides/customer-payments). > 2. **Verify the application amount** > * A linked line item automatically recalculates the target invoice's `balance` and > payment status in the standard API-managed model. If `totalAmountWithFees` is > present, it takes precedence over `totalAmount`; make sure it contains only the > principal applied to the invoice. > 3. **Correct reversals on the original line item** > * Changing only a payment or line-item `status` does not unapply the amount. Update > or delete the original line item and confirm the invoice reopens as expected. > 4. **Manual Payment Application** > * Payments recorded inside Upwell can be applied from the dashboard — see > [Accounts receivable management](/accounts-receivable/receivables). ### Performance and Rate Limiting > [accordion] Slow API Response Times > > **Symptoms**: API calls taking longer than expected > > **Solutions**: > > 1. **Optimize Query Parameters** > ```javascript theme={null} > // Use pagination for large datasets > const response = await fetch( > 'https://api.upwell.com/api/rest/invoices?limit=50&offset=0' > ); > ``` > > 2. **Filter server-side with the search endpoints** > ```javascript theme={null} > // POST //search takes a Hasura-style `where` body — > // filter by date range instead of paging the whole collection > const response = await fetch('https://api.upwell.com/api/rest/invoices/search', { > method: 'POST', > headers: { Authorization: 'YOUR_API_KEY', 'Content-Type': 'application/json' }, > body: JSON.stringify({ > where: { createdAt: { _gte: '2026-07-01', _lt: '2026-08-01' } }, > limit: 50, > offset: 0, > }), > }); > ``` > > 3. **Use Bulk Operations — where a bulk endpoint exists** > Only some resources have a `bulk-*` create endpoint (`bulk-customers`, `bulk-carriers`, `bulk-bills`, `bulk-carrier-invoices`, `bulk-customer-payments`, `bulk-customer-payment-line-items`, `bulk-carrier-payment-line-items`). **Invoices have no bulk endpoint** — there is no `/api/rest/bulk-invoices`; loop individual `POST`/`PUT` calls to `/api/rest/invoices` instead. > > ```javascript theme={null} > // Bulk-create multiple customers in one request — note the `inputs` (plural) wrapper > const bulkCreate = await fetch( > 'https://api.upwell.com/api/rest/bulk-customers', > { > method: 'POST', > headers: { Authorization: 'YOUR_API_KEY', 'Content-Type': 'application/json' }, > body: JSON.stringify({ inputs: customerArray }), > } > ); > ``` > [accordion] Getting 429 Too Many Requests errors > > **The Upwell API does not currently enforce rate limits** — it never returns `429` and > sends no `X-RateLimit-*` or `Retry-After` headers. A `429` you observe is coming from > infrastructure on **your** side (a corporate proxy, API gateway, or serverless platform > limit), so debug it there. > > Keep your client polite anyway — bound your concurrency, and retry only server-side > failures: > > ```python theme={null} > import time > import random > > def api_call_with_backoff(url, headers, max_retries=5): > for attempt in range(max_retries): > response = requests.get(url, headers=headers) > > if response.status_code >= 500: > # Server-side error — back off and retry > time.sleep((2 ** attempt) + random.uniform(0, 1)) > continue > > return response # 2xx and 4xx are final — don't blind-retry 4xx > ``` > > See [Error handling](/api-reference/error-codes) for what is and isn't safe to retry. ### Data Quality and Validation > [accordion] Validation Errors > > **Symptoms**: Getting `400 Bad Request` responses > > The error body is a flat message string that names the problem — match on it: > > | Error contains | Fix | > | - | - | > | `Not-NULL violation. null value in column "..."` | Send the named field — e.g. `shipmentId` on shipments, `balance` on invoices. See [required fields](/conventions/idempotency-and-retries#required-fields-without-server-side-defaults). | > | `Uniqueness violation` | You re-`POST`ed an existing `(sourceSystem, sourceSystemId)` — update with `PUT` instead. | > | `The value ... is not an integer` | Money must be **integer cents**: `284750`, never `2847.50`. | > | `bad-request: Unexpected variable ...` | Wrap create payloads in `{ "input": { ... } }` (bulk endpoints use `inputs`), and check the field name against the reference — fields are `camelCase` (`customerId`, [`dueDate`](/conventions/dates-and-times#due-date)). | > > Validate before sending: > > ```javascript theme={null} > // Field names are camelCase; money is integer cents > const invoice = { > customerId: 'cus_abc123', > totalAmount: 450000, // $4,500.00 > balance: 450000, // required — equals totalAmount for a new invoice > dueDate: '2026-08-30', > }; > if (!Number.isInteger(invoice.totalAmount)) { > throw new Error('totalAmount must be integer cents'); > } > ``` > > The full message-to-fix table lives in [Error handling](/api-reference/error-codes). > [accordion] Data Not Found > > **Symptoms**: A record you expect isn't coming back > > **Solutions**: > > 1. **Check the body, not the status code** > * A lookup for a missing record does **not** return `404`: the single-resource > `GET`s return `200` with a `null` resource (`{ "customer": null }`), and lists > return empty arrays. A real `404` means the URL path itself is wrong. > 2. **Verify Resource IDs** > * Upwell ids are **prefixed strings** (`cus_…`, `inv_…`, `cari_…`) — check for > truncation or a stripped prefix > * Confirm the record wasn't deleted, and that your API key belongs to the > organization that owns it > 3. **Search by your own keys instead** > ```bash theme={null} > # POST //search takes a JSON body with a where filter > curl -X POST https://api.upwell.com/api/rest/invoices/search \ > -H "Authorization: YOUR_API_KEY" \ > -H "Content-Type: application/json" \ > -d '{ "where": { "number": { "_eq": "INV-001" } }, "limit": 10 }' > ``` ## Testing and Debugging ### API Testing Tools > [accordion] Using Curl for Testing > > **Basic Request Testing**: > > ```bash theme={null} > # Test authentication > curl -v -H "Authorization: YOUR_API_KEY" \ > https://api.upwell.com/api/rest/invoices > > # Test with verbose output for debugging — note the input wrapper, > # camelCase fields, and integer-cents money > curl -v -X POST https://api.upwell.com/api/rest/invoices \ > -H "Authorization: YOUR_API_KEY" \ > -H "Content-Type: application/json" \ > -d '{"input": {"customerId": "cus_abc123", "totalAmount": 10000, "balance": 10000}}' > ``` > [accordion] Using Postman for API Testing > > **Setting Up Postman**: > > 1. Import the [Upwell OpenAPI specification](https://app.upwell.com/openapi.json) > 2. Configure environment variables: > * `base_url`: [https://api.upwell.com](https://api.upwell.com) > * `api_key`: YOUR_API_KEY > 3. Set up authentication in the Authorization tab > 4. Use the Collection Runner for batch testing ### Logging and Monitoring > [accordion] Request Logging > > **Essential Logging Information**: > > ```python theme={null} > import logging > > def log_api_request(method, url, status_code, response_time): > logging.info(f"API Request: {method} {url} - {status_code} ({response_time}ms)") > > if status_code >= 400: > logging.error(f"API Error: {status_code} - Check error response for details") > ``` > [accordion] Performance Monitoring > > **Key Metrics to Track**: > > * Response times by endpoint > * Error rates by status code and error message > * Success/failure ratios > > ```javascript theme={null} > const metrics = { > totalRequests: 0, > successfulRequests: 0, > averageResponseTime: 0, > errorsByCode: {} > }; > ``` ## Getting Additional Help ### Support Channels > [card] [Technical Support](mailto:support@upwell.com) > > For API and integration issues > [card] [API Documentation](/api-reference/introduction) > > Complete endpoint reference > [card] [Error Handling Reference](/api-reference/error-codes) > > Real error shapes, messages, and retry rules > [card] [Implementation Guide](/quickstart) > > Step-by-step setup instructions ### When Contacting Support Include the following information in your support request: 1. **Error Details** * Complete error message and code * Request timestamp * Endpoint being called 2. **Request Information** * HTTP method and URL * Request headers (excluding API key) * Request body (if applicable) 3. **Environment Details** * Programming language and version * Library/SDK versions * Network configuration (if relevant) 4. **Steps to Reproduce** * Detailed steps that led to the issue * Expected vs. actual behavior * Frequency of occurrence ### Best Practices for Smooth Operation 1. **Keep API Keys Secure** * Never commit keys to version control * Use environment variables * Rotate keys regularly 2. **Implement Proper Error Handling** * Handle all HTTP status codes appropriately * Implement retry logic for transient errors * Log errors for debugging 3. **Monitor API Usage** * Track request volumes and patterns * Set up alerts for unusual activity 4. **Test Thoroughly** * Test error scenarios in addition to success cases * Use staging environment for integration testing * Validate data before sending to API 5. **Stay Updated** * Watch the [changelog](/changelog) for API and platform changes — or subscribe to its [RSS feed](https://docs.upwell.com/changelog/rss.xml) to get them pushed to Slack, email, or a feed reader * Review documentation updates * Test new features in staging first # Dashboard Overview Source: https://docs.upwell.com/user-interface/dashboard-overview Understand the Upwell dashboard interface and its key components ## Dashboard Introduction "Dashboard" in these docs means the Upwell web application as a whole — the workspace you sign in to, where your AP and AR work lives. This page describes how that workspace is laid out. ## Where you land Signing in takes you to your **home page**, not to a summary screen. Each user has their own home page setting, and new users start on **Receivables**, so the first thing you see is a working list you can act on rather than a set of tiles to read. From there, everything is reached from the sidebar — see the [Navigation guide](/user-interface/navigation-guide) for what each section contains. ## Analytics Reporting beyond the working lists is available as an embedded analytics view powered by Trevor. It is controlled by a feature flag, so it is not switched on for every organization — ask your Upwell contact or [support@upwell.com](mailto:support@upwell.com) if you want it enabled. > [card] Trevor Analytics > > **Purpose**: Deeper, embedded business intelligence and reporting > > **Key features**: > > * Interactive data visualizations and reporting > * Broader analytics across your Upwell data > * Embedded directly in the app — no separate login > > **Best for**: Organizations that want richer analytics alongside their day-to-day lists ## Dashboard Layout Structure ### Header Navigation The top header provides consistent navigation across the platform: > [accordion] Main Navigation > > * **Logo/Home**: Return to dashboard > * **User Menu**: Account settings and logout > * **Notifications**: System alerts and updates > * **Search**: Global search functionality > [accordion] User Information > > * Current user name and role > * Organization context > * Quick access to user settings > * Session management ### Sidebar Navigation Collapsible sidebar providing access to all platform sections: * **Responsive Design**: Automatically adapts to screen size * **Collapse/Expand**: Toggle for more workspace * **Role-Based**: Menu items based on user permissions * **Feature Flags**: Sections controlled by organizational settings ### Main Content Area Central dashboard space displaying: * **Key Metrics**: Important business indicators * **Recent Activity**: Latest transactions and updates * **Quick Actions**: Common tasks and workflows * **System Status**: Platform health and notifications ## Dashboard Features ### Real-Time Updates > [accordion] Live Data > > **Automatic Refresh**: Dashboard data updates automatically > > **Real-Time Metrics**: > > * Transaction processing status > * System health indicators > * Recent activity feeds > * Alert notifications > > **Manual Refresh**: Force refresh option for immediate updates > [accordion] Notifications > > **System Alerts**: Important system messages and updates > > **Process Notifications**: > > * Invoice processing completion > * Payment status updates > * Error notifications > * Integration status changes > > **User Actions**: Notifications requiring user attention ### Responsive Design > [accordion] Mobile Optimization > > **Responsive Layout**: Adapts to all screen sizes > > **Mobile Features**: > > * Touch-friendly navigation > * Optimized data display > * Simplified interactions > * Fast loading performance > > **Tablet Support**: Enhanced tablet experience with larger touch targets > [accordion] Desktop Experience > > **Full Feature Access**: Complete platform functionality > > **Desktop Optimizations**: > > * Multi-column layouts > * Advanced data visualization > * Keyboard shortcuts > * Extended workspace ## Feature Flag Management Dashboard behavior is controlled through feature flags: * **Embedded Analytics**: Enable or disable the embedded Trevor analytics dashboard * **Navigation Sections**: Control sidebar menu visibility * **Feature Access**: Enable/disable specific functionality * **Role Integration**: Combine with user roles for precise access control ## Getting Started ### First-Time Users **1. Initial Login** Use credentials provided by your administrator **2. Dashboard Orientation** Familiarize yourself with the main dashboard layout **3. Navigation Exploration** Explore sidebar menu options based on your role **4. Key Features** Identify frequently used features for your workflow ### Customization Options > [accordion] User Preferences > > **Available Settings**: > > * Dashboard refresh intervals > * Notification preferences > * Display options > * Language and locale settings > > **Access**: User menu → Settings > [accordion] Layout Options > > **Sidebar Control**: Collapse/expand for more workspace > > **Navigation**: Customize frequently accessed sections > > **Mobile**: Optimized layouts for mobile devices ## Performance and Reliability ### Loading Performance * **Fast Initial Load**: Optimized dashboard startup * **Progressive Loading**: Content loads as needed * **Caching**: Intelligent data caching for performance * **Background Updates**: Non-blocking data refresh ### System Reliability * **High Availability**: Designed for 24/7 operation * **Error Handling**: Graceful error management * **Offline Support**: Limited offline capabilities * **Recovery**: Automatic session recovery ## Support and Help ### Dashboard Support * **User Guides**: Built-in help and documentation * **Tooltips**: Contextual help throughout interface * **Training Resources**: Video tutorials and guides * **Technical Support**: [Contact Support](mailto:support@upwell.com) ### Common Tasks > [accordion] How do I access different dashboard types? > > Dashboard type is controlled by your organization's feature flag settings. > Contact your administrator if you need access to a different dashboard variant. > [accordion] Why are some menu items missing? > > Menu visibility is controlled by your user role and organizational feature flags. > Contact your administrator if you believe you should have access to specific features. > [accordion] How do I customize my dashboard view? > > Use the user menu to access settings and preferences. > Some customizations may require administrator permissions. # Navigation Guide Source: https://docs.upwell.com/user-interface/navigation-guide Understanding the Upwell dashboard navigation and main sections ## Main Navigation Overview The Upwell application features a collapsible sidebar navigation that provides access to all platform sections. The navigation is organized into logical groups based on functionality. ![The Upwell sidebar expanded next to a list view, showing the main destinations and the expandable sections](https://mintcdn.com/upwell/-Pwd7QcUk6Cnh82_/images/nav-sidebar.png?fit=max\&auto=format\&n=-Pwd7QcUk6Cnh82_\&q=85\&s=9d2616491efadb31525005f91bbbeb9f) The expanded sidebar: the main destinations, with Transactions, Partners, Workflow Setup, and Account expanding into their own sub-sections. ## Core Navigation Sections ### Main Operations > [accordion] Dashboard > > **Location**: `/` > > **Purpose**: Central hub showing key metrics and system overview > > **Features**: > > * Configurable dashboard views (operational dashboard and embedded Trevor analytics) > * Key performance indicators > * Quick access to recent activities > * System health monitoring > > **Access**: Available to all user roles > [accordion] Shipments > > **Location**: `/shipments` > > **Purpose**: Transportation and logistics tracking > > **Features**: > > * Shipment status tracking > * Document management > * TMS integration data > * Logistics coordination > > **Access**: Controlled by user permissions > [accordion] Receivables > > **Location**: `/invoices` > > **Purpose**: Customer billing and accounts receivable management > > **Features**: > > * Customer invoice processing > * Payment tracking > * Collections management > * Billing workflows > > **Access**: AR-focused roles and administrators > [accordion] Carrier Docs > > **Location**: `/carrier-invoices` > > **Purpose**: Carrier invoice and payables processing > > **Features**: > > * Carrier invoice automation > * Document processing > * Approval workflows > * Payment processing > > **Access**: AP-focused roles and administrators ### Data Management > [accordion] Carriers > > **Location**: `/carriers` > > **Purpose**: Carrier relationship and data management > > **Features**: > > * Carrier profiles > * Contract management > * Performance tracking > * Payment terms > [accordion] Customers > > **Location**: `/customers` > > **Purpose**: Customer profile and relationship management > > **Features**: > > * Customer profiles > * Credit management > * Payment history > * Billing preferences > [accordion] Email > > **Location**: `/email` > > **Purpose**: Email processing and communication management > > **Features**: > > * Inbound email processing > * Document extraction > * Communication history > * Email workflows > [accordion] Transactions > > **Location**: `/transactions` > > **Purpose**: Financial transaction tracking and management > > **Features**: > > * Transaction history > * Payment tracking > * Financial reconciliation > * Audit trails ### Workflow Settings > [accordion] Workflow Settings > > **Purpose**: System configuration and workflow management > > **Sub-sections**: > > * **Templates** (`/workflow-settings/templates`) — Document and email templates > * **Reminders** (`/workflow-settings/reminder-schedule`) — Automated reminder scheduling > * **Documents** (`/workflow-settings/documents`) — Document processing rules > * **Rules** (`/workflow-settings/rules`) — Business logic and automation rules > * **Delivery** (`/workflow-settings/delivery`) — Document delivery preferences > * **Payables** (`/workflow-settings/payables`) — Payables workflow configuration > > **Access**: Administrative roles with configuration permissions > [accordion] Integrations > > **Location**: `/integrations` > > **Purpose**: Third-party system integrations > > **Features**: > > * TMS connections > * API integrations > * Data synchronization > * Integration monitoring ### Account Management > [accordion] Account Settings > > **Purpose**: Organization and user account management > > **Sub-sections**: > > * **Company Profile** — Organization details and settings > * **Payments** — Payment method and billing configuration > * **Email Settings** — Email processing and delivery configuration > * **API Keys** — API access management > * **Users** — User management and permissions > * **AI Custom Instructions** — Custom AI processing instructions > > **Access**: Admin and Manager roles ## Navigation Features ### Sidebar Behavior * **Collapsible Design**: Click the menu icon to collapse/expand the sidebar * **Mobile Responsive**: Automatically adapts to mobile devices * **Visual Indicators**: Active page highlighting and clear navigation state * **Tooltips**: Helpful tooltips when sidebar is collapsed ### Feature Flags The navigation system uses feature flags to control which sections are visible to users: * Different features can be enabled/disabled per organization * Gradual rollout of new functionality * Role-based feature access control ### Keyboard Navigation * **Tab Navigation**: Navigation elements are reachable and operable with the Tab key * **Shortcuts**: Quick access to main sections * **Screen Reader Support**: Navigation elements are labeled for screen readers ## Tips for Efficient Navigation 1. **Use Bookmarks**: Bookmark frequently accessed pages 2. **Keyboard Shortcuts**: Learn keyboard shortcuts for faster navigation 3. **Collapse Sidebar**: Collapse sidebar for more screen space when working with data 4. **Mobile Access**: The interface is responsive and adapts to mobile devices; data-heavy screens are best used on desktop ## Getting Help If you need assistance with navigation or access to specific sections, contact your organization admin or [support team](mailto:support@upwell.com). # User Roles & Permissions Source: https://docs.upwell.com/user-interface/user-roles Understanding user roles and access controls in the Upwell platform ## User Role Overview Upwell uses a role-based access control system with four organization roles. Each role provides different levels of access to platform features and data based on organizational responsibilities. Roles are assigned per person under **Account → Users**, alongside the status that decides which actions are open on that row. ![The Users page under Account, listing members with their role and status](https://mintcdn.com/upwell/-Pwd7QcUk6Cnh82_/images/settings-user-roles.png?fit=max\&auto=format\&n=-Pwd7QcUk6Cnh82_\&q=85\&s=734db6f6df5398d799d2805624ef2935) User management: each member's role, and the status that decides which actions are open on their row. ## User Roles ### Team Member > [card] Team Member > > **Role Code**: `ORGMEMBER` > > **Access Level**: Standard user access > > **Typical Responsibilities**: > > * Process daily transactions > > * View assigned data and reports > > * Execute standard workflows > > * Access core platform features > > **Permissions**: > > * Read access to assigned data > > * Process invoices and payments within scope > > * Generate standard reports > > * Use integrated tools and features > > **Restrictions**: > > * Cannot modify system settings > > * Limited administrative functions > > * Cannot manage other users > > * Cannot access sensitive configuration areas ### Cash Application > [card] Cash Application > > **Role Code**: `ORGCASHAPP` > > **Access Level**: Focused access, limited to the Transactions area > > **Typical Responsibilities**: > > * Match remittances and bank credits to open invoices > > * Record and reconcile payments > > * Work bank reconciliation queues > > **Permissions**: > > * Full access to remittances, payments, and bank reconciliation > > * Read access to shipments and invoices for matching context > > * Connect an AI assistant through the read-only [Upwell connector](/connect-ai-assistant) and manage their own connections under **Connected apps** > > **Restrictions**: > > * No receivables, collections, or invoicing workflows > > * No carrier documents or payables access > > * No partner (customer/carrier) management > > * No organization settings or user management > > * Invoices are visible only inside matching flows, not as a standalone tab ### Manager > [card] Manager > > **Role Code**: `ORGADMIN` > > **Access Level**: Administrative access > > **Typical Responsibilities**: > > * Manage organization settings > > * Configure workflows and rules > > * Add and manage user accounts > > * Oversee platform operations > > **Permissions**: > > * Full access to organization data > > * Add users as Team Members or Managers, and manage existing users > > * Workflow and rule configuration > > * Integration setup and management > > * Advanced reporting and analytics > > * API key management > > **Additional Access**: > > * Workflow Settings section > > * Account management features > > * Integration configuration > > * Advanced system settings ### Admin > [card] Admin > > **Role Code**: `ORGOWNER` > > **Access Level**: Full organizational control > > **Typical Responsibilities**: > > * Ultimate authority over organization > > * Billing and subscription management > > * Strategic configuration decisions > > * Organization-wide policy setting > > **Permissions**: > > * All Manager permissions plus: > > * Billing and payment management > > * Organization deletion/modification > > * Add users with any role and change an existing user's role > > * Strategic platform configuration > > * Contract and subscription management > > **Unique Capabilities**: > > * Transfer ownership > > * Delete organization > > * Manage billing settings > > * Set organization-wide policies > [!NOTE] > > Upwell support staff hold an internal administrative role used only for support and > platform operations. It is not assignable within your organization and will not appear > in your role picker. ## Permission Inheritance ### Role Hierarchy ```text theme={null} ORGOWNER: Admin (Organization Level) ↓ ORGADMIN: Manager (Administrative Level) ↓ ORGMEMBER: Team Member (Standard User Level) ORGCASHAPP: Cash Application (lateral, restricted scope) ``` ### Access Patterns * **Higher roles in the hierarchy inherit lower role permissions** * **Additional permissions are added at each level** * **Cash Application sits outside the hierarchy**: it is a restricted, focused role limited to the Transactions area rather than a level below Team Member * **Restrictions are applied based on organizational boundaries** * **Feature flags can modify available functionality** ## User Management ### Adding Users **1. Access User Management** Navigate to Account → Users (Admin or Manager access required) **2. Invite New User** Click "Add User" and enter email address **3. Assign Role** Select appropriate role: * Team Member (standard users) * Cash Application (payment matching specialists) * Manager (department managers) * Admin (organization leaders) Managers can add users only as Team Members or Managers. Admins can assign any role. **4. Send Invitation** User receives email invitation to join **5. User Activation** User completes account setup process ### Role Assignment Guidelines > [accordion] When to Assign Team Member Role > > **Ideal for**: > > * Data entry personnel > * Customer service representatives > * Processing specialists > * Standard operational staff > > **Use cases**: > > * Invoice processing > * Customer inquiries > * Data entry and verification > * Standard report generation > [accordion] When to Assign Cash Application Role > > **Ideal for**: > > * Cash application specialists > * Payment processing teams > * Treasury/banking operations staff > > **Use cases**: > > * Remittance-to-invoice matching > * Payment recording and reconciliation > * Bank feed review and reconciliation > [accordion] When to Assign Manager Role > > **Ideal for**: > > * Department managers > * Operations supervisors > * IT coordinators > * Process improvement specialists > > **Use cases**: > > * Team management > * Workflow configuration > * Integration setup > * Advanced reporting > * User training and support > [accordion] When to Assign Admin Role > > **Ideal for**: > > * C-level executives > * Business owners > * Primary decision makers > * Budget controllers > > **Use cases**: > > * Strategic planning > * Billing management > * Organization-wide policy > * Contract negotiations ## Security Features ### Access Controls * **Role-based permissions** ensure users only access appropriate features * **Data scope limitations** restrict access to relevant information * **Feature flags** control functionality availability * **Audit logging** tracks all user actions ### Best Practices 1. **Principle of Least Privilege**: Assign minimum required permissions 2. **Regular Reviews**: Periodically review user roles and access 3. **Proper Onboarding**: Ensure new users understand their role boundaries 4. **Documentation**: Maintain records of role assignments and changes ## Feature Flag Integration User roles work in conjunction with feature flags to control access. Each navigation section can be enabled or disabled per organization, so what you see depends on both your role and your organization's configuration. If a section you expect is missing, contact your organization admin. ## Getting Help ### Role-Related Support * **Access Issues**: Contact your organization admin * **Permission Questions**: Review this guide or contact support * **Role Changes**: Request changes through your organization admin. Only Admins can change an existing user's role * **Technical Support**: [Contact Upwell Support](mailto:support@upwell.com) ### Common Questions > [accordion] How do I request additional permissions? > > Contact your organization admin to discuss your access needs. > They can modify your role or grant additional permissions as appropriate. > [accordion] Why can't I see certain menu items? > > Navigation visibility is controlled by both your user role and feature flags. > Contact your admin if you believe you should have access to specific features. > [accordion] What happens if I need temporary admin access? > > Admins can temporarily modify user roles for specific projects or tasks. > Ensure roles are reset appropriately when temporary access is no longer needed.