---
title: "Update invoice line"
method: PATCH
path: "/v1/invoice-receivables/{invoiceReceivableId}/lines/{lineId}"
tags: ["v1 - Invoice Receivables"]
---

# Update invoice line

`PATCH /v1/invoice-receivables/{invoiceReceivableId}/lines/{lineId}`

## Request

- Base URL: `https://light.inc` (the document declares no server; this is the origin it was published from)
- URL: `https://light.inc/v1/invoice-receivables/{invoiceReceivableId}/lines/{lineId}`
- Auth: one of:
  - API key in header `Authorization`
  - HTTP bearer

Updates an invoice line item

## Path parameters

- `invoiceReceivableId` string, uuid, required
- `lineId` string, uuid, required

## Request body

- ExternalUpdateInvoiceReceivableLineRequestV1Model
  - `productId` string, uuid, nullable: ID of the product
  - `quantity` number, nullable: Quantity of the product
  - `accountId` string, uuid, nullable: ID of the ledger account for this line
  - `taxCodeId` string, uuid, nullable: ID of the tax code to apply to this line
  - `discount` ExternalAccountReceivableLineDiscountV1Model, nullable: Discount to apply to this line (can be percentage or amount-based)
    - `type` 'PERCENTAGE' | 'AMOUNT': ⚠️ This enum is not exhaustive; new values may be added in the future.
  - `priceOverwrite` integer, nullable: Price overwrite in smallest denomination. If not provided, the product's default price will be used
  - `productNameOverwrite` string, nullable: Product name overwrite. If not provided, the product's default name will be used
  - `taxAmountOverwrite` integer, nullable: Tax amount override in smallest denomination. Bypasses tax calculation and sets the exact tax amount for this line. Requirements: The line must have a valid amount (product price or priceOverwrite must be set). The taxAmount field in the response will reflect this override value. Amounts use smallest denomination. Examples: GBP 42.15 = 4215, JPY 12345 = 12345, BHD 7.321 = 7321.
  - `avataxCode` string, nullable: Avalara tax code. Used when the invoice tax engine is AVATAX
  - `billingStart` string, date, nullable: Start of the billing period for this line
  - `billingEnd` string, date, nullable: End of the billing period for this line
  - `customProperties` ExternalSetCustomPropertyRequestV1Model[], nullable: List of custom properties to set on the invoice or line
    - `groupId` string, uuid: ID of the custom property group.
    - `valueIds` string[]: IDs of the selected custom property values. It behaves as a PUT operation, so if empty the existing ones will be effectively deleted.
    - `inlineValues` string[], nullable: Inline custom property values (used for TEXT/NUMERIC/DATE/etc. groups). It behaves as a PUT operation, so if empty or null the existing ones will be effectively deleted.
  - `accrualTemplateId` string, uuid, nullable: ID of the accrual/amortization template to apply to this line
  - `accrualStartDate` string, date, nullable: Start date for accrual/amortization
  - `accrualEndDate` string, date, nullable: End date for accrual/amortization

## Response `default`

default response

- ExternalInvoiceReceivableLineV1Model
  - `id` string, uuid: Unique identifier for the object
  - `companyId` string, uuid: ID of the company
  - `invoiceReceivableId` string, uuid: ID of the invoice receivable this line belongs to
  - `productId` string, uuid: ID of the product
  - `quantity` number: Quantity of the product
  - `taxCodeId` string, uuid, nullable: ID of the tax code
  - `accountId` string, uuid, nullable: ID of the ledger account
  - `discount` ExternalAccountReceivableLineDiscountV1Model, nullable: Discount to apply to this line (can be percentage or amount-based)
    - `type` 'PERCENTAGE' | 'AMOUNT': ⚠️ This enum is not exhaustive; new values may be added in the future.
  - `discountAmount` integer, nullable: Discount amount in smallest denomination
  - `netAmount` integer, nullable: Net amount in smallest denomination after discount but before tax
  - `taxAmount` integer, nullable: Tax amount in smallest denomination
  - `avataxCode` string, nullable: Avalara tax code. Used when the invoice tax engine is `AVATAX`
  - `billingStart` string, date, nullable: Start of the billing period
  - `billingEnd` string, date, nullable: End of the billing period
  - `priceOverwrite` integer, nullable: Custom product price in smallest denomination. This overrides the default product's price
  - `productNameOverwrite` string, nullable: Custom product name. This overrides the default product's name
  - `createdAt` string, date-time: Timestamp when the line was created
  - `updatedAt` string, date-time: Timestamp when the line was last updated
  - `accrualTemplateId` string, uuid, nullable: ID of the accrual template
  - `accrualStartDate` string, date, nullable: Start date for accrual
  - `accrualEndDate` string, date, nullable: End date for accrual
  - `customProperties` ExternalCustomPropertyV1Model[], nullable: List of custom properties associated with the line
    - `groupId` string, uuid: ID of the custom property group
    - `groupInternalName` string: Internal name of the custom property group
    - `values` ExternalCustomPropertyValueV1Model[]: List of values. Note that this will be a single value unless the group input type supports multiple values
      - `id` string, uuid: Unique identifier for the object
      - `groupId` string, uuid: ID of the custom property group
      - `groupInternalName` string: Internal name of the custom property group
      - `companyId` string, uuid: ID of the company
      - `internalName` string: Internal name of the custom property value
      - `label` string: Label of the custom property value
      - `context` string, nullable: Context/description of the custom property value
      - `createdAt` string, date-time: Timestamp when the custom property value was created
      - `updatedAt` string, date-time: Timestamp when the custom property value was last updated

---

[API](https://skmtc.dev/light/apis/light-api.md) - [All operations](https://skmtc.dev/light/apis/light-api/llms.txt) - [OpenAPI document](https://skmtc.dev/light/apis/light-api/revisions/84f51306f648?raw)
