Skip to main content
PATCH
/
orders
/
{id}
/
items
/
{item_id}
Update a line item quantity or notes
curl --request PATCH \
  --url https://api.arcuserp.com/v1/orders/{id}/items/{item_id} \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "quantity": 2,
  "sell_rate": 123,
  "unit_price": 123,
  "notes": "<string>",
  "override": true,
  "override_reason": "<string>"
}
'
import requests

url = "https://api.arcuserp.com/v1/orders/{id}/items/{item_id}"

payload = {
"quantity": 2,
"sell_rate": 123,
"unit_price": 123,
"notes": "<string>",
"override": True,
"override_reason": "<string>"
}
headers = {
"Authorization": "Bearer <token>",
"Content-Type": "application/json"
}

response = requests.patch(url, json=payload, headers=headers)

print(response.text)
const options = {
method: 'PATCH',
headers: {Authorization: 'Bearer <token>', 'Content-Type': 'application/json'},
body: JSON.stringify({
quantity: 2,
sell_rate: 123,
unit_price: 123,
notes: '<string>',
override: true,
override_reason: '<string>'
})
};

fetch('https://api.arcuserp.com/v1/orders/{id}/items/{item_id}', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));
<?php

$curl = curl_init();

curl_setopt_array($curl, [
CURLOPT_URL => "https://api.arcuserp.com/v1/orders/{id}/items/{item_id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "PATCH",
CURLOPT_POSTFIELDS => json_encode([
'quantity' => 2,
'sell_rate' => 123,
'unit_price' => 123,
'notes' => '<string>',
'override' => true,
'override_reason' => '<string>'
]),
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"Content-Type: application/json"
],
]);

$response = curl_exec($curl);
$err = curl_error($curl);

curl_close($curl);

if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}
package main

import (
"fmt"
"strings"
"net/http"
"io"
)

func main() {

url := "https://api.arcuserp.com/v1/orders/{id}/items/{item_id}"

payload := strings.NewReader("{\n \"quantity\": 2,\n \"sell_rate\": 123,\n \"unit_price\": 123,\n \"notes\": \"<string>\",\n \"override\": true,\n \"override_reason\": \"<string>\"\n}")

req, _ := http.NewRequest("PATCH", url, payload)

req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("Content-Type", "application/json")

res, _ := http.DefaultClient.Do(req)

defer res.Body.Close()
body, _ := io.ReadAll(res.Body)

fmt.Println(string(body))

}
HttpResponse<String> response = Unirest.patch("https://api.arcuserp.com/v1/orders/{id}/items/{item_id}")
.header("Authorization", "Bearer <token>")
.header("Content-Type", "application/json")
.body("{\n \"quantity\": 2,\n \"sell_rate\": 123,\n \"unit_price\": 123,\n \"notes\": \"<string>\",\n \"override\": true,\n \"override_reason\": \"<string>\"\n}")
.asString();
require 'uri'
require 'net/http'

url = URI("https://api.arcuserp.com/v1/orders/{id}/items/{item_id}")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Patch.new(url)
request["Authorization"] = 'Bearer <token>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"quantity\": 2,\n \"sell_rate\": 123,\n \"unit_price\": 123,\n \"notes\": \"<string>\",\n \"override\": true,\n \"override_reason\": \"<string>\"\n}"

response = http.request(request)
puts response.read_body
{
  "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "entity_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "order_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "product_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "variant_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "sku": "<string>",
  "title": "<string>",
  "quantity": 123,
  "quantity_fulfilled": 123,
  "quantity_returned": 123,
  "sell_rate": 123,
  "unit_price": 123,
  "list_price": 123,
  "pricing_rule_adjustment": 123,
  "coupon_adjustment": 123,
  "discount_amount": 123,
  "line_subtotal": 123,
  "tax_amount": 123,
  "line_total": 123,
  "adjustments": [
    {
      "id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
      "source_type": "<string>",
      "source_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
      "source_label": "<string>",
      "per_unit_amount": 123,
      "quantity": 123,
      "line_amount": 123,
      "proration_ratio": 123,
      "applied_at": "2023-11-07T05:31:56Z"
    }
  ],
  "unit_cost": 123,
  "weight": 123,
  "is_tax_exempt": true,
  "product_tax_code": "<string>",
  "sort_order": 123,
  "product_vendor_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
  "created_at": "2023-11-07T05:31:56Z",
  "updated_at": "2023-11-07T05:31:56Z"
}
{
"error": "not_found",
"code": "not_found",
"type": "not_found",
"hint": "The requested order does not exist or does not belong to this entity.",
"param": "expand[0]",
"required": "accounts:read",
"request_id": "req_abc123"
}
{
"error": "not_found",
"code": "not_found",
"type": "not_found",
"hint": "The requested order does not exist or does not belong to this entity.",
"param": "expand[0]",
"required": "accounts:read",
"request_id": "req_abc123"
}
{
"error": "not_found",
"code": "not_found",
"type": "not_found",
"hint": "The requested order does not exist or does not belong to this entity.",
"param": "expand[0]",
"required": "accounts:read",
"request_id": "req_abc123"
}
{
"error": "not_found",
"code": "not_found",
"type": "not_found",
"hint": "The requested order does not exist or does not belong to this entity.",
"param": "expand[0]",
"required": "accounts:read",
"request_id": "req_abc123"
}
{
"error": "not_found",
"code": "not_found",
"type": "not_found",
"hint": "The requested order does not exist or does not belong to this entity.",
"param": "expand[0]",
"required": "accounts:read",
"request_id": "req_abc123"
}

Authorizations

Authorization
string
header
required

API key issued per entity via Settings > Developers > API Keys. Each key carries scopes (e.g. orders:read, products:write). Bearer token format: Authorization: Bearer ark_live_ent_Test keys use ark_test_ent_. Both are issued per entity
via Settings > Developers > API Keys.

Headers

Idempotency-Key
string

Client-generated unique key for idempotent POST/PATCH/DELETE operations. Alias for the Idempotency parameter. Max 255 chars. On retry with the same key, the original response is returned without re-executing the operation. Keys expire after 24 hours.

Maximum string length: 255

Path Parameters

id
string<uuid>
required
item_id
string<uuid>
required

Body

application/json
quantity
integer
Required range: x >= 1
sell_rate
number

Override unit price (canonical Arcus field).

unit_price
number

Alias of sell_rate (Stripe/Shopify convention). Conflict / invalid handled identically to add. Triggers warnings entries plus order.price_override audit when applied price differs from catalog.

notes
string
override
boolean

Set true (with the orders.revision_override permission) to revise a paid/billed order. Without it, a paid/billed order returns 422 edit_not_allowed (suggested_action revise_order).

override_reason
string

Optional reason recorded in the audit log when override is used.

Response

Updated order item. Response includes unit_price alias. When override detected, response carries warnings array entries.

A line item on an order. Sub-resource of Order.

id
string<uuid>
entity_id
string<uuid>
read-only

Multi-tenant scoping column (Layer 1 isolation). Set automatically from the parent orders.entity_id and enforced by Postgres trigger trg_order_items_entity_parity (P0-ENTITY-ID-CHILD-TABLES, 2026-05-18). Cross-tenant writes are rejected at the database layer.

order_id
string<uuid>
product_id
string<uuid> | null
variant_id
string<uuid> | null
sku
string | null
title
string
quantity
integer
quantity_fulfilled
integer
read-only
quantity_returned
integer
read-only
sell_rate
number

Canonical Arcus per-unit price column (matches order_items.sell_rate).

unit_price
number

Public-API alias of sell_rate (Stripe/Shopify/QuickBooks convention). Always populated on read; equal to sell_rate. Set per NEW-GAP-API-V1-CALLER-UNIT-PRICE-SILENTLY-OVERRIDDEN 2026-05-17 closure.

list_price
number
pricing_rule_adjustment
number
read-only

Per-unit pricing-rule savings (list_price minus sell_rate, positive magnitude). Already baked into sell_rate (and therefore line_subtotal) per ASC 606 transaction-price pricing; surfaced for the gross-to-net bridge display, never re-subtracted.

coupon_adjustment
number
read-only

Per-line allocated coupon/order-level discount (signed; negative for a discount). Reflected in line_subtotal.

discount_amount
number
line_subtotal
number
read-only
tax_amount
number
read-only
line_total
number
read-only
adjustments
object[]
read-only

Per-line, per-source adjustment breakdown from order_item_adjustments (the canonical SSOT). Each entry attributes a signed line_amount to a source (pricing_rule | order_adjustment | coupon | manual_line_override | return_refund_adjust | restocking_fee). Empty array for lines with no allocations (and on legacy orders predating the writer). Industry parity: Shopify Admin GraphQL LineItem.discountAllocations[].

unit_cost
number | null
weight
number | null
is_tax_exempt
boolean
product_tax_code
string | null
sort_order
integer
product_vendor_id
string<uuid> | null

For purchase_order document_type lines only: exact product_vendors row this line is bound to (NEW-GAP-ORDER-ITEMS-PRODUCT-VENDOR-ID-PROVENANCE, 2026-05-14). NULL for legacy PO lines and all non-PO doc types; PDF falls back to the deterministic default-vendor-part pick.

created_at
string<date-time>
read-only
updated_at
string<date-time>
read-only