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

# updatePurchaseOrder

> Update a purchase order. Returns null if no purchase order with that id is owned by the caller. Changing `items` re-syncs the order's inbound shipments: on an order with exactly one shipment the lines mirror through, and on one with several new lines are left unassigned. Throws a 409 CONFLICT error (with an extension code of PURCHASE_ORDER_NOT_EDITABLE, PURCHASE_ORDER_ITEM_HAS_RECEIPTS, or PURCHASE_ORDER_NUMBER_TAKEN) if the change conflicts with the order's current state.

**Required scopes:** [`inventory_write`](/docs/api-reference/v3/reference/scopes#scope-inventory_write)

## Arguments

<ResponseField name="id" type="ID!" required>
  The id of the purchase order to update.
</ResponseField>

<ResponseField name="input" type={<a href="/docs/api-reference/v3/reference/procurement/update-purchase-order-input">UpdatePurchaseOrderInput!</a>} required>
  The fields to change on the purchase order.

  <Expandable title="fields" lazyRender>
    <ResponseField name="items" type={<a href="/docs/api-reference/v3/reference/procurement/update-purchase-order-item-input">[UpdatePurchaseOrderItemInput!]</a>}>
      Replaces the order's line items, matched by product. Omit to leave them unchanged. Any product not listed is removed from the order, which fails if that line has received stock. Must not be empty — an order always has at least one item.

      <Expandable title="fields" lazyRender>
        <ResponseField name="productId" type="ID!" required>
          The product being ordered.
        </ResponseField>

        <ResponseField name="quantity" type="Int!" required>
          How many units to order. Must not be negative.
        </ResponseField>

        <ResponseField name="totalTax" type={<a href="/docs/api-reference/v3/reference/common/money-input">MoneyInput</a>}>
          Total tax for this line. Must use the order's currency. Defaults to zero.
        </ResponseField>

        <ResponseField name="unitCost" type={<a href="/docs/api-reference/v3/reference/common/money-input">MoneyInput</a>}>
          Cost per unit. Must use the order's currency. Defaults to zero.
        </ResponseField>
      </Expandable>
    </ResponseField>

    <ResponseField name="locationId" type="ID">
      The location the ordered inventory is destined for. Send null to clear.
    </ResponseField>

    <ResponseField name="note" type="String">
      An internal note on the purchase order. Send null to clear.
    </ResponseField>

    <ResponseField name="orderedAt" type={<a href="/docs/api-reference/v3/reference/common/date">Date</a>}>
      The date the order was placed with the supplier. Send null to clear.
    </ResponseField>

    <ResponseField name="poNumber" type="String">
      Your own purchase order number. Cannot be cleared.
    </ResponseField>

    <ResponseField name="referenceNumber" type="String">
      An external reference for the purchase order. Send null to clear.
    </ResponseField>

    <ResponseField name="supplierId" type="ID">
      The supplier the order is placed with. Send null to clear.
    </ResponseField>

    <ResponseField name="supplierNote" type="String">
      A note shared with the supplier. Send null to clear.
    </ResponseField>

    <ResponseField name="tags" type="[String!]">
      Replaces the order's tags. Send an empty list to clear them.
    </ResponseField>
  </Expandable>
</ResponseField>

## Returns

<ResponseField name="updatePurchaseOrder" type={<a href="/docs/api-reference/v3/reference/procurement/purchase-order">PurchaseOrder</a>}>
  An order placed with a supplier to restock inventory.

  <Expandable title="fields" lazyRender>
    <ResponseField name="closedAt" type={<a href="/docs/api-reference/v3/reference/common/date-time">DateTime</a>}>
      When the purchase order was closed.
    </ResponseField>

    <ResponseField name="createdAt" type={<a href="/docs/api-reference/v3/reference/common/date-time">DateTime!</a>} required>
      When the record was created.
    </ResponseField>

    <ResponseField name="id" type="ID!" required>
      The id of this purchase order.
    </ResponseField>

    <ResponseField name="items" type={<a href="/docs/api-reference/v3/pagination">PurchaseOrderItemConnection!</a>} required>
      A paginated list of the order's line items.

      **Requires:** [`inventory_read`](/docs/api-reference/v3/reference/scopes#scope-inventory_read)

      <Expandable title="fields" lazyRender>
        **Arguments**

        <ResponseField name="after" type="String">
          Forward pagination cursor — returns items after it. Pass an `edges[].cursor` or `pageInfo.endCursor` from a previous page.
        </ResponseField>

        <ResponseField name="before" type="String">
          Backward pagination cursor — returns items before it. Pass an `edges[].cursor` or `pageInfo.startCursor` from a previous page.
        </ResponseField>

        <ResponseField name="first" type="Int">
          Forward pagination: returns the first N items (max 100, default 25). Use with `after`; mutually exclusive with `last`/`before`.
        </ResponseField>

        <ResponseField name="last" type="Int">
          Backward pagination: returns the last N items (max 100, default 25). Use with `before`; mutually exclusive with `first`/`after`.
        </ResponseField>

        **Fields**

        <ResponseField name="edges" type={<a href="/docs/api-reference/v3/pagination">[PurchaseOrderItemEdge!]!</a>} required>
          The list of edges (each a node plus its pagination `cursor`).

          <Expandable title="fields" lazyRender>
            <ResponseField name="cursor" type="String!" required>
              Opaque cursor for this item; pass to `after`/`before` to page from here.
            </ResponseField>

            <ResponseField name="node" type={<a href="/docs/api-reference/v3/reference/procurement/purchase-order-item">PurchaseOrderItem!</a>} required>
              The item at this edge.
            </ResponseField>
          </Expandable>
        </ResponseField>

        <ResponseField name="nodes" type={<a href="/docs/api-reference/v3/reference/procurement/purchase-order-item">[PurchaseOrderItem!]!</a>} required>
          The nodes in this page, without the edge/cursor wrapper — a convenience over `edges`.

          <Expandable title="fields" lazyRender>
            <ResponseField name="createdAt" type={<a href="/docs/api-reference/v3/reference/common/date-time">DateTime!</a>} required>
              When the record was created.
            </ResponseField>

            <ResponseField name="damagedQuantity" type="Int!" required>
              The quantity received damaged for this line item.
            </ResponseField>

            <ResponseField name="id" type="ID!" required>
              The id of this line item.
            </ResponseField>

            <ResponseField name="product" type={<a href="/docs/api-reference/v3/reference/catalog/product">Product</a>}>
              The product this line item orders.

              **Requires:** [`products_read`](/docs/api-reference/v3/reference/scopes#scope-products_read)
            </ResponseField>

            <ResponseField name="quantity" type="Int!" required>
              The quantity ordered for this line item.
            </ResponseField>

            <ResponseField name="receivedQuantity" type="Int!" required>
              The quantity received so far against this line item.
            </ResponseField>

            <ResponseField name="totalTax" type={<a href="/docs/api-reference/v3/reference/common/money">Money</a>}>
              The total tax charged on this line item.
            </ResponseField>

            <ResponseField name="unitCost" type={<a href="/docs/api-reference/v3/reference/common/money">Money</a>}>
              The cost per unit for this line item.
            </ResponseField>

            <ResponseField name="updatedAt" type={<a href="/docs/api-reference/v3/reference/common/date-time">DateTime!</a>} required>
              When the record was last updated.
            </ResponseField>
          </Expandable>
        </ResponseField>

        <ResponseField name="pageInfo" type={<a href="/docs/api-reference/v3/pagination">PageInfo!</a>} required>
          Pagination metadata for the current page.

          <Expandable title="fields" lazyRender>
            <ResponseField name="endCursor" type="String">
              Cursor of the last edge in this page; pass to `after` to page forward.
            </ResponseField>

            <ResponseField name="hasNextPage" type="Boolean!" required>
              Whether more items exist after this page (drives forward pagination with `first`/`after`).
            </ResponseField>

            <ResponseField name="hasPreviousPage" type="Boolean!" required>
              Whether more items exist before this page (drives backward pagination with `last`/`before`).
            </ResponseField>

            <ResponseField name="startCursor" type="String">
              Cursor of the first edge in this page; pass to `before` to page backward.
            </ResponseField>
          </Expandable>
        </ResponseField>
      </Expandable>
    </ResponseField>

    <ResponseField name="location" type={<a href="/docs/api-reference/v3/reference/inventory/location">Location</a>}>
      The location the order's inventory is destined for.

      **Requires:** [`locations_read`](/docs/api-reference/v3/reference/scopes#scope-locations_read)

      <Expandable title="fields" lazyRender>
        <ResponseField name="city" type="String">
          The city of the location's address.
        </ResponseField>

        <ResponseField name="company" type="String">
          The company name associated with the location.
        </ResponseField>

        <ResponseField name="countryCode" type="String">
          The country code, e.g. "US".
        </ResponseField>

        <ResponseField name="createdAt" type={<a href="/docs/api-reference/v3/reference/common/date-time">DateTime!</a>} required>
          When the record was created.
        </ResponseField>

        <ResponseField name="id" type="ID!" required>
          The id of this location.
        </ResponseField>

        <ResponseField name="inventoryItems" type={<a href="/docs/api-reference/v3/pagination">InventoryItemConnection!</a>} required>
          Traceable inventory units at this warehouse.

          **Requires:** [`inventory_read`](/docs/api-reference/v3/reference/scopes#scope-inventory_read)

          <Expandable title="fields" lazyRender>
            **Arguments**

            <ResponseField name="after" type="String">
              Forward pagination cursor — returns items after it. Pass an `edges[].cursor` or `pageInfo.endCursor` from a previous page.
            </ResponseField>

            <ResponseField name="before" type="String">
              Backward pagination cursor — returns items before it. Pass an `edges[].cursor` or `pageInfo.startCursor` from a previous page.
            </ResponseField>

            <ResponseField name="first" type="Int">
              Forward pagination: returns the first N items (max 100, default 25). Use with `after`; mutually exclusive with `last`/`before`.
            </ResponseField>

            <ResponseField name="last" type="Int">
              Backward pagination: returns the last N items (max 100, default 25). Use with `before`; mutually exclusive with `first`/`after`.
            </ResponseField>

            **Fields**

            <ResponseField name="edges" type={<a href="/docs/api-reference/v3/pagination">[InventoryItemEdge!]!</a>} required>
              The list of edges (each a node plus its pagination `cursor`).
            </ResponseField>

            <ResponseField name="nodes" type={<a href="/docs/api-reference/v3/reference/inventory/inventory-item">[InventoryItem!]!</a>} required>
              The nodes in this page, without the edge/cursor wrapper — a convenience over `edges`.
            </ResponseField>

            <ResponseField name="pageInfo" type={<a href="/docs/api-reference/v3/pagination">PageInfo!</a>} required>
              Pagination metadata for the current page.
            </ResponseField>
          </Expandable>
        </ResponseField>

        <ResponseField name="inventoryLevels" type={<a href="/docs/api-reference/v3/pagination">LocationInventoryLevelConnection!</a>} required>
          Per-product inventory levels held at this location.

          **Requires:** [`inventory_read`](/docs/api-reference/v3/reference/scopes#scope-inventory_read)

          <Expandable title="fields" lazyRender>
            **Arguments**

            <ResponseField name="after" type="String">
              Forward pagination cursor — returns items after it. Pass an `edges[].cursor` or `pageInfo.endCursor` from a previous page.
            </ResponseField>

            <ResponseField name="before" type="String">
              Backward pagination cursor — returns items before it. Pass an `edges[].cursor` or `pageInfo.startCursor` from a previous page.
            </ResponseField>

            <ResponseField name="first" type="Int">
              Forward pagination: returns the first N items (max 100, default 25). Use with `after`; mutually exclusive with `last`/`before`.
            </ResponseField>

            <ResponseField name="last" type="Int">
              Backward pagination: returns the last N items (max 100, default 25). Use with `before`; mutually exclusive with `first`/`after`.
            </ResponseField>

            **Fields**

            <ResponseField name="edges" type={<a href="/docs/api-reference/v3/pagination">[LocationInventoryLevelEdge!]!</a>} required>
              The list of edges (each a node plus its pagination `cursor`).
            </ResponseField>

            <ResponseField name="nodes" type={<a href="/docs/api-reference/v3/reference/inventory/location-inventory-level">[LocationInventoryLevel!]!</a>} required>
              The nodes in this page, without the edge/cursor wrapper — a convenience over `edges`.
            </ResponseField>

            <ResponseField name="pageInfo" type={<a href="/docs/api-reference/v3/pagination">PageInfo!</a>} required>
              Pagination metadata for the current page.
            </ResponseField>
          </Expandable>
        </ResponseField>

        <ResponseField name="name" type="String!" required>
          The location's display name.
        </ResponseField>

        <ResponseField name="phone" type="String">
          The contact phone number for the location.
        </ResponseField>

        <ResponseField name="postalCode" type="String">
          The postal or ZIP code, e.g. "84101".
        </ResponseField>

        <ResponseField name="stateCode" type="String">
          The state or province code, e.g. "UT".
        </ResponseField>

        <ResponseField name="storageLocations" type={<a href="/docs/api-reference/v3/pagination">StorageLocationConnection!</a>} required>
          Bins and other storage locations within this warehouse.

          **Requires:** [`locations_read`](/docs/api-reference/v3/reference/scopes#scope-locations_read)

          <Expandable title="fields" lazyRender>
            **Arguments**

            <ResponseField name="after" type="String">
              Forward pagination cursor — returns items after it. Pass an `edges[].cursor` or `pageInfo.endCursor` from a previous page.
            </ResponseField>

            <ResponseField name="before" type="String">
              Backward pagination cursor — returns items before it. Pass an `edges[].cursor` or `pageInfo.startCursor` from a previous page.
            </ResponseField>

            <ResponseField name="first" type="Int">
              Forward pagination: returns the first N items (max 100, default 25). Use with `after`; mutually exclusive with `last`/`before`.
            </ResponseField>

            <ResponseField name="last" type="Int">
              Backward pagination: returns the last N items (max 100, default 25). Use with `before`; mutually exclusive with `first`/`after`.
            </ResponseField>

            **Fields**

            <ResponseField name="edges" type={<a href="/docs/api-reference/v3/pagination">[StorageLocationEdge!]!</a>} required>
              The list of edges (each a node plus its pagination `cursor`).
            </ResponseField>

            <ResponseField name="nodes" type={<a href="/docs/api-reference/v3/reference/inventory/storage-location">[StorageLocation!]!</a>} required>
              The nodes in this page, without the edge/cursor wrapper — a convenience over `edges`.
            </ResponseField>

            <ResponseField name="pageInfo" type={<a href="/docs/api-reference/v3/pagination">PageInfo!</a>} required>
              Pagination metadata for the current page.
            </ResponseField>
          </Expandable>
        </ResponseField>

        <ResponseField name="street1" type="String">
          The first line of the street address.
        </ResponseField>

        <ResponseField name="street2" type="String">
          The second line of the street address.
        </ResponseField>

        <ResponseField name="updatedAt" type={<a href="/docs/api-reference/v3/reference/common/date-time">DateTime!</a>} required>
          When the record was last updated.
        </ResponseField>
      </Expandable>
    </ResponseField>

    <ResponseField name="note" type="String">
      An internal note on the purchase order.
    </ResponseField>

    <ResponseField name="orderedAt" type={<a href="/docs/api-reference/v3/reference/common/date">Date</a>}>
      The date the order was placed with the supplier.
    </ResponseField>

    <ResponseField name="poNumber" type="String!" required>
      The merchant-facing purchase order number.
    </ResponseField>

    <ResponseField name="referenceNumber" type="String">
      An external reference for the purchase order.
    </ResponseField>

    <ResponseField name="shipments" type={<a href="/docs/api-reference/v3/pagination">InboundShipmentConnection!</a>} required>
      Inbound shipments fulfilling this purchase order.

      **Requires:** [`inventory_read`](/docs/api-reference/v3/reference/scopes#scope-inventory_read)

      <Expandable title="fields" lazyRender>
        **Arguments**

        <ResponseField name="after" type="String">
          Forward pagination cursor — returns items after it. Pass an `edges[].cursor` or `pageInfo.endCursor` from a previous page.
        </ResponseField>

        <ResponseField name="before" type="String">
          Backward pagination cursor — returns items before it. Pass an `edges[].cursor` or `pageInfo.startCursor` from a previous page.
        </ResponseField>

        <ResponseField name="first" type="Int">
          Forward pagination: returns the first N items (max 100, default 25). Use with `after`; mutually exclusive with `last`/`before`.
        </ResponseField>

        <ResponseField name="last" type="Int">
          Backward pagination: returns the last N items (max 100, default 25). Use with `before`; mutually exclusive with `first`/`after`.
        </ResponseField>

        **Fields**

        <ResponseField name="edges" type={<a href="/docs/api-reference/v3/pagination">[InboundShipmentEdge!]!</a>} required>
          The list of edges (each a node plus its pagination `cursor`).

          <Expandable title="fields" lazyRender>
            <ResponseField name="cursor" type="String!" required>
              Opaque cursor for this item; pass to `after`/`before` to page from here.
            </ResponseField>

            <ResponseField name="node" type={<a href="/docs/api-reference/v3/reference/procurement/inbound-shipment">InboundShipment!</a>} required>
              The item at this edge.
            </ResponseField>
          </Expandable>
        </ResponseField>

        <ResponseField name="nodes" type={<a href="/docs/api-reference/v3/reference/procurement/inbound-shipment">[InboundShipment!]!</a>} required>
          The nodes in this page, without the edge/cursor wrapper — a convenience over `edges`.

          <Expandable title="fields" lazyRender>
            <ResponseField name="actualArrivalDate" type={<a href="/docs/api-reference/v3/reference/common/date">Date</a>}>
              The date the shipment actually arrived.
            </ResponseField>

            <ResponseField name="carrier" type="String">
              The carrier transporting the shipment.
            </ResponseField>

            <ResponseField name="createdAt" type={<a href="/docs/api-reference/v3/reference/common/date-time">DateTime!</a>} required>
              When the record was created.
            </ResponseField>

            <ResponseField name="dutyCost" type={<a href="/docs/api-reference/v3/reference/common/money">Money</a>}>
              The duty cost incurred for the shipment.
            </ResponseField>

            <ResponseField name="estimatedArrivalDate" type={<a href="/docs/api-reference/v3/reference/common/date">Date</a>}>
              The estimated date the shipment will arrive.
            </ResponseField>

            <ResponseField name="freightCost" type={<a href="/docs/api-reference/v3/reference/common/money">Money</a>}>
              The cost of freight for the shipment.
            </ResponseField>

            <ResponseField name="freightType" type="String">
              The type of freight used for the shipment.
            </ResponseField>

            <ResponseField name="id" type="ID!" required>
              The id of this inbound shipment.
            </ResponseField>

            <ResponseField name="items" type={<a href="/docs/api-reference/v3/pagination">InboundShipmentItemConnection!</a>} required>
              A paginated list of the shipment's line items.

              **Requires:** [`inventory_read`](/docs/api-reference/v3/reference/scopes#scope-inventory_read)

              <Expandable title="fields" lazyRender>
                **Arguments**

                <ResponseField name="after" type="String">
                  Forward pagination cursor — returns items after it. Pass an `edges[].cursor` or `pageInfo.endCursor` from a previous page.
                </ResponseField>

                <ResponseField name="before" type="String">
                  Backward pagination cursor — returns items before it. Pass an `edges[].cursor` or `pageInfo.startCursor` from a previous page.
                </ResponseField>

                <ResponseField name="first" type="Int">
                  Forward pagination: returns the first N items (max 100, default 25). Use with `after`; mutually exclusive with `last`/`before`.
                </ResponseField>

                <ResponseField name="last" type="Int">
                  Backward pagination: returns the last N items (max 100, default 25). Use with `before`; mutually exclusive with `first`/`after`.
                </ResponseField>
              </Expandable>
            </ResponseField>

            <ResponseField name="location" type={<a href="/docs/api-reference/v3/reference/inventory/location">Location</a>}>
              The location the shipment is arriving at.

              **Requires:** [`locations_read`](/docs/api-reference/v3/reference/scopes#scope-locations_read)
            </ResponseField>

            <ResponseField name="paymentTerms" type="String">
              The payment terms agreed for the shipment.
            </ResponseField>

            <ResponseField name="purchaseOrders" type={<a href="/docs/api-reference/v3/pagination">PurchaseOrderConnection!</a>} required>
              Purchase orders this shipment fulfills.

              **Requires:** [`inventory_read`](/docs/api-reference/v3/reference/scopes#scope-inventory_read)

              <Expandable title="fields" lazyRender>
                **Arguments**

                <ResponseField name="after" type="String">
                  Forward pagination cursor — returns items after it. Pass an `edges[].cursor` or `pageInfo.endCursor` from a previous page.
                </ResponseField>

                <ResponseField name="before" type="String">
                  Backward pagination cursor — returns items before it. Pass an `edges[].cursor` or `pageInfo.startCursor` from a previous page.
                </ResponseField>

                <ResponseField name="first" type="Int">
                  Forward pagination: returns the first N items (max 100, default 25). Use with `after`; mutually exclusive with `last`/`before`.
                </ResponseField>

                <ResponseField name="last" type="Int">
                  Backward pagination: returns the last N items (max 100, default 25). Use with `before`; mutually exclusive with `first`/`after`.
                </ResponseField>
              </Expandable>
            </ResponseField>

            <ResponseField name="shipmentId" type="String">
              The carrier's identifier for the shipment.
            </ResponseField>

            <ResponseField name="status" type={<a href="/docs/api-reference/v3/reference/procurement/inbound-shipment-status">InboundShipmentStatus!</a>} required>
              The current status of the shipment.
            </ResponseField>

            <ResponseField name="trackingNumber" type="String">
              The shipment's tracking number.
            </ResponseField>

            <ResponseField name="trackingUrl" type="String">
              A URL to track the shipment.
            </ResponseField>

            <ResponseField name="updatedAt" type={<a href="/docs/api-reference/v3/reference/common/date-time">DateTime!</a>} required>
              When the record was last updated.
            </ResponseField>
          </Expandable>
        </ResponseField>

        <ResponseField name="pageInfo" type={<a href="/docs/api-reference/v3/pagination">PageInfo!</a>} required>
          Pagination metadata for the current page.

          <Expandable title="fields" lazyRender>
            <ResponseField name="endCursor" type="String">
              Cursor of the last edge in this page; pass to `after` to page forward.
            </ResponseField>

            <ResponseField name="hasNextPage" type="Boolean!" required>
              Whether more items exist after this page (drives forward pagination with `first`/`after`).
            </ResponseField>

            <ResponseField name="hasPreviousPage" type="Boolean!" required>
              Whether more items exist before this page (drives backward pagination with `last`/`before`).
            </ResponseField>

            <ResponseField name="startCursor" type="String">
              Cursor of the first edge in this page; pass to `before` to page backward.
            </ResponseField>
          </Expandable>
        </ResponseField>
      </Expandable>
    </ResponseField>

    <ResponseField name="status" type={<a href="/docs/api-reference/v3/reference/procurement/purchase-order-status">PurchaseOrderStatus!</a>} required>
      The current lifecycle status of the purchase order.
    </ResponseField>

    <ResponseField name="supplier" type={<a href="/docs/api-reference/v3/reference/procurement/supplier">Supplier</a>}>
      The supplier the order was placed with.

      **Requires:** [`inventory_read`](/docs/api-reference/v3/reference/scopes#scope-inventory_read)

      <Expandable title="fields" lazyRender>
        <ResponseField name="contacts" type={<a href="/docs/api-reference/v3/reference/procurement/supplier-contact">[SupplierContact!]!</a>} required>
          The contact people at this supplier.

          <Expandable title="fields" lazyRender>
            <ResponseField name="createdAt" type={<a href="/docs/api-reference/v3/reference/common/date-time">DateTime!</a>} required>
              When the record was created.
            </ResponseField>

            <ResponseField name="email" type="String">
              The contact's email address.
            </ResponseField>

            <ResponseField name="id" type="ID!" required>
              The id of this contact.
            </ResponseField>

            <ResponseField name="name" type="String!" required>
              The contact's name.
            </ResponseField>

            <ResponseField name="phone" type="String">
              The contact's phone number.
            </ResponseField>

            <ResponseField name="updatedAt" type={<a href="/docs/api-reference/v3/reference/common/date-time">DateTime!</a>} required>
              When the record was last updated.
            </ResponseField>
          </Expandable>
        </ResponseField>

        <ResponseField name="createdAt" type={<a href="/docs/api-reference/v3/reference/common/date-time">DateTime!</a>} required>
          When the record was created.
        </ResponseField>

        <ResponseField name="currency" type="String">
          The ISO 4217 currency code the supplier transacts in.
        </ResponseField>

        <ResponseField name="id" type="ID!" required>
          The id of this supplier.
        </ResponseField>

        <ResponseField name="leadTimeDays" type="Int">
          The supplier's typical lead time, in days.
        </ResponseField>

        <ResponseField name="name" type="String!" required>
          The supplier's name.
        </ResponseField>

        <ResponseField name="phone" type="String">
          The supplier's phone number.
        </ResponseField>

        <ResponseField name="productVendors" type="[String!]!" required>
          Product vendor names associated with this supplier.
        </ResponseField>

        <ResponseField name="purchaseOrders" type={<a href="/docs/api-reference/v3/pagination">PurchaseOrderConnection!</a>} required>
          Purchase orders placed with this supplier.

          **Requires:** [`inventory_read`](/docs/api-reference/v3/reference/scopes#scope-inventory_read)

          <Expandable title="fields" lazyRender>
            **Arguments**

            <ResponseField name="after" type="String">
              Forward pagination cursor — returns items after it. Pass an `edges[].cursor` or `pageInfo.endCursor` from a previous page.
            </ResponseField>

            <ResponseField name="before" type="String">
              Backward pagination cursor — returns items before it. Pass an `edges[].cursor` or `pageInfo.startCursor` from a previous page.
            </ResponseField>

            <ResponseField name="first" type="Int">
              Forward pagination: returns the first N items (max 100, default 25). Use with `after`; mutually exclusive with `last`/`before`.
            </ResponseField>

            <ResponseField name="last" type="Int">
              Backward pagination: returns the last N items (max 100, default 25). Use with `before`; mutually exclusive with `first`/`after`.
            </ResponseField>

            **Fields**

            <ResponseField name="edges" type={<a href="/docs/api-reference/v3/pagination">[PurchaseOrderEdge!]!</a>} required>
              The list of edges (each a node plus its pagination `cursor`).
            </ResponseField>

            <ResponseField name="nodes" type={<a href="/docs/api-reference/v3/reference/procurement/purchase-order">[PurchaseOrder!]!</a>} required>
              The nodes in this page, without the edge/cursor wrapper — a convenience over `edges`.
            </ResponseField>

            <ResponseField name="pageInfo" type={<a href="/docs/api-reference/v3/pagination">PageInfo!</a>} required>
              Pagination metadata for the current page.
            </ResponseField>
          </Expandable>
        </ResponseField>

        <ResponseField name="updatedAt" type={<a href="/docs/api-reference/v3/reference/common/date-time">DateTime!</a>} required>
          When the record was last updated.
        </ResponseField>

        <ResponseField name="website" type="String">
          The supplier's website URL.
        </ResponseField>
      </Expandable>
    </ResponseField>

    <ResponseField name="supplierNote" type="String">
      A note shared with the supplier.
    </ResponseField>

    <ResponseField name="tags" type="[String!]!" required>
      Free-form tags applied to the purchase order.
    </ResponseField>

    <ResponseField name="updatedAt" type={<a href="/docs/api-reference/v3/reference/common/date-time">DateTime!</a>} required>
      When the record was last updated.
    </ResponseField>
  </Expandable>
</ResponseField>

## Example

```graphql theme={null}
mutation {
  updatePurchaseOrder(id: "...", input: { ... }) {
    closedAt
    createdAt
    id
    items {
      nodes {
        createdAt
        damagedQuantity
        id
        quantity
        receivedQuantity
        updatedAt
      }
      pageInfo { hasNextPage endCursor }
    }
    note
    orderedAt
    poNumber
    referenceNumber
    # ...
  }
}
```


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