Quotes

Update a quote item

Updates a line of this quote; total is recomputed when a pricing field changes.

Package line (is_package: true): quantity, unit_price (the price of one package unit), is_option, is_offered, discount_percent, the day and the order are carried over to its articles, and the response is the package as it now stands. vat is ignored (each article keeps its rate). discount_amount above 0 and is_discount are refused (package_discount_amount). The id of an article (package.articles[].id) is refused (package_article): update the package line. Role permission: quotes.manage.

patch/quotes/{id}/items/{itemId}

Request

  • Base URL: https://joinways.app/api/v1
  • URL: https://joinways.app/api/v1/quotes/{id}/items/{itemId}
  • Auth: one of:
    • HTTP bearer
    • OAuth 2 (authorization code, authorization URL https://joinways.app/oauth/authorize, token URL https://joinways.app/api/oauth/token, scopes: mcp.write)

Headers

Idempotency-Keystring

Optional client-generated key (1 to 255 characters, e.g. a UUID v4) that makes the request idempotent for 24 hours: a retry with the same key replays the recorded response (marked Idempotency-Replayed: true) instead of executing the operation again. Same key with another body: 422 idempotency_key_reuse; while the first request runs: 409 idempotency_conflict. See the Idempotency section.

Request body

titlestring
descriptionstring
quantitynumber
unit_pricenumber
vatnumber
location_item_idstring uuid nullable
is_optionboolean
is_discountboolean
is_offeredboolean
discount_amountnumber
discount_percentnumber nullable
event_dayinteger
event_day_datestring date nullable
sort_orderinteger

Response

The updated item.

idstring uuid
quote_idstring uuid
account_idstring uuid nullable
titlestring
descriptionstring
quantitynumber
unit_pricenumber

Price per unit, excluding tax. On a package: the price of one package unit (package.unit_price).

vatnumber nullable

Tax rate as a percentage (e.g. 20 for 20 %). A package mixes rates: this is only the lowest of them, read package.tax_rates and never compute its tax from vat.

totalnumber nullable

Computed line total, excluding tax, after the line discount. On a package: the sum of its articles (package.total_excl_tax).

is_packageboolean

The line is a package; package is then present.

parent_item_idstring uuid nullable

The package line an article belongs to. null on the items returned: the articles of a package are under its package.articles, not items of their own.

location_item_idstring uuid nullable

The catalog item this line was priced from, if any.

min_price_appliednumber nullable

Catalog minimum price the line was checked against.

is_optionboolean nullable
is_discountboolean nullable
is_offeredboolean nullable

Offered (free) line; bypasses the catalog minimum-price check.

discount_amountnumber nullable
discount_percentnumber nullable
event_dayinteger

1-based day this line belongs to (multi-day events).

event_day_datestring date nullable
sort_orderinteger

Display order within the day.

client_selected_atstring date-time nullable

When the client ticked this option on the public quote.

inherited_from_item_idstring uuid nullable
ai_rationalestring nullable
created_atstring date-time

Example response

{
  "title": "Plated dinner, 3 courses",
  "quantity": 80,
  "unit_price": 95,
  "vat": 20,
  "total": 7600,
  "package": {
    "unit_price": 69.545453,
    "total_excl_tax": 2781.81,
    "total_tax": 378.19,
    "total_incl_tax": 3160,
    "tax_rates": [
      10,
      20
    ],
    "articles": [
      {
        "title": "Meeting room",
        "quantity": 40,
        "package_unit_quantity": 1,
        "unit_price": 25,
        "vat": 20,
        "total": 1000
      }
    ]
  }
}

Changes

No recorded changes to this operation across all 1 revision of this API.