Patch Invoice items

patch/v1/invoice-items/{invoice_item_id}

Partially updates an invoice line item's editable attributes within the active workspace. Side effects: persists the changes, bumps updated_at, and the parent invoice totals are recomputed when amounts change.

Requires a bearer token: Authorization: Bearer <token>.

Path parameters

NameTypeRequiredDescription
invoice_item_idstring <uuid>YesPublic UUID of the invoice item to update.e.g. 33333333-0000-4000-8000-0000000000d1

Request

cURL
curl -X PATCH https://api.wellapp.ai/v1/invoice-items/{invoice_item_id} \
  -H "Authorization: Bearer $WELL_API_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
  "data": {
    "type": "invoice_items",
    "attributes": {
      "quantity": 90000000,
      "line_total": 1350
    }
  }
}'
Request body
{
  "data": {
    "type": "invoice_items",
    "attributes": {
      "quantity": 90000000,
      "line_total": 1350
    }
  }
}

Responses

200The updated invoice item.

{
  "data": {
    "type": "invoice_item",
    "id": "33333333-0000-4000-8000-0000000000d1",
    "attributes": {
      "line_id": "1",
      "sku": "CLAUDE-API",
      "name": "Claude API tokens",
      "description": "Input and output tokens, April 2026",
      "unit_price": 0.000015,
      "currency": "USD",
      "unit": "token",
      "quantity": 90000000,
      "line_total": 1350,
      "tax_rate": 0,
      "tax_amount": 0,
      "created_at": "2026-04-12T08:00:00Z",
      "updated_at": "2026-05-01T14:00:00Z",
      "deleted_at": null
    },
    "relationships": {
      "invoice": {
        "data": {
          "type": "invoice",
          "id": "00000000-0000-4000-8000-000000000001"
        }
      },
      "ledger_account": {
        "data": {
          "type": "ledger_account",
          "id": "00000000-0000-4000-8000-000000000001"
        }
      },
      "applied_tax_rate": {
        "data": {
          "type": "tax_rate",
          "id": "00000000-0000-4000-8000-000000000001"
        }
      },
      "media": {
        "data": {
          "type": "media",
          "id": "00000000-0000-4000-8000-000000000001"
        }
      }
    }
  }
}

400Bad request

{
  "code": "BAD_REQUEST",
  "status": 400,
  "title": "Bad Request",
  "message": "See title.",
  "meta": {
    "trace_id": "a1b2c3",
    "log_id": "a1b2c3"
  }
}

401Unauthorized

{
  "code": "UNAUTHORIZED",
  "status": 401,
  "title": "Unauthorized",
  "message": "See title.",
  "meta": {
    "trace_id": "a1b2c3",
    "log_id": "a1b2c3"
  }
}

404Not found

{
  "code": "NOT_FOUND",
  "status": 404,
  "title": "Not Found",
  "message": "See title.",
  "meta": {
    "trace_id": "a1b2c3",
    "log_id": "a1b2c3"
  }
}