Invoice Line Items

Update a line item

Changed on

Update a line item on an invoice

put/invoices/{invoice}/line-items/{id}

Request

  • Base URL
    https://sandbox.sequencehq.com/api
  • URL
    https://sandbox.sequencehq.com/api/invoices/{invoice}/line-items/{id}
  • Auth
    none declared. Required headers: Authorization

Path parameters

invoicestring required

The Invoice ID

idstring required

Line Item ID

Headers

Authorizationstring required

Your API credentials. Eg. Basic {credentials}.

sequence-version'2024-07-30'

Use this header to select an API version

Request body

titlestring required

Item Title

descriptionstring

Item Description

quantitystring required

Quantity

ratestring required

Price per Item

taxRatestring required

Tax Rate

servicePeriodStartstring

Start of the service period (the time period in which the service was provided)

servicePeriodEndstring

End of the service period (the time period in which the service was provided)

groupIdstring

Line Item Group ID

priceIdstring

Price ID

rateDisplay'ABSOLUTE' | 'PERCENTAGE'
revenueClassification'PREPAYMENT' | 'EARNED' | 'BURNDOWN'
creditGrantIdstring

Credit Grant ID

revenueRecognitionMethod'STRAIGHT_LINE' | 'USAGE' | 'MILESTONE' | 'POINT_IN_TIME'

Example request

{
  "title": "Ferraris",
  "description": "Red",
  "quantity": "2",
  "rate": "20000.10",
  "taxRate": "0.2",
  "servicePeriodStart": "2022-10-20T00:00:00Z",
  "servicePeriodEnd": "2022-10-24T00:00:00Z",
  "servicePeriod": {
    "startDate": "2022-10-20",
    "endDate": "2022-10-24"
  },
  "groupId": "cd11218d-fa00-4faa-8684-a43113d076a8",
  "priceId": "fe2fcd0b-4c53-45c7-b2ae-b6c1a7d21e95",
  "rateDisplay": "ABSOLUTE",
  "externalIds": [
    {
      "key": "Xero",
      "value": "123"
    }
  ],
  "revenueClassification": "EARNED",
  "creditGrantId": "fe2fcd0b-4c53-45c7-b2ae-b6c1a7d21e95",
  "revenueRecognitionMethod": "STRAIGHT_LINE"
}

Response

OK

idstring required

Line Item ID

invoiceIdstring required

Invoice ID

titlestring required

Item Title

descriptionstring

Item Description

quantitystring required

Quantity

ratestring required

Price per Item

taxRatestring required

Tax Rate

servicePeriodStartstring

Start of the service period (the time period in which the service was provided)

servicePeriodEndstring

End of the service period (the time period in which the service was provided)

indexinteger required

Index (for maintaining order)

groupIdstring

Line Item Group ID

netTotalstring required

Net total, in decimal format of the Invoice's currency

totalTaxstring required

Total tax, in decimal format of the Invoice's currency

grossTotalstring required

Gross total, in decimal format of the Invoice's currency

priceIdstring

Price ID

rateDisplay'ABSOLUTE' | 'PERCENTAGE' required
revenueClassification'PREPAYMENT' | 'EARNED' | 'BURNDOWN'
creditGrantIdstring

Credit Grant ID

productIdstring

Product ID

revenueRecognitionMethod'STRAIGHT_LINE' | 'USAGE' | 'MILESTONE' | 'POINT_IN_TIME'

Example response

{
  "id": "af60cab3-812d-4250-a051-0fb7133a00c7",
  "invoiceId": "cd11218d-fa00-4faa-8684-a43113d076a8",
  "title": "Ferraris",
  "description": "Red",
  "quantity": "2",
  "rate": "20000.10",
  "taxRate": "0.2",
  "servicePeriodStart": "2022-10-20T00:00:00Z",
  "servicePeriodEnd": "2022-10-24T00:00:00Z",
  "servicePeriod": {
    "startDate": "2022-10-20",
    "endDate": "2022-10-24"
  },
  "index": 2,
  "groupId": "cd11218d-fa00-4faa-8684-a43113d076a8",
  "netTotal": "51.20",
  "totalTax": "2.50",
  "grossTotal": "101.23",
  "priceId": "fe2fcd0b-4c53-45c7-b2ae-b6c1a7d21e95",
  "rateDisplay": "ABSOLUTE",
  "externalIds": [
    {
      "key": "Xero",
      "value": "123"
    }
  ],
  "revenueClassification": "EARNED",
  "creditGrantId": "fe2fcd0b-4c53-45c7-b2ae-b6c1a7d21e95",
  "productId": "dd55bf30-3b97-4644-a9fc-b15e0f59a110",
  "revenueRecognitionMethod": "USAGE"
}

Changes

    • breaking

      the / response's property format changed from date to no format for status

    • breaking

      the / response's property format changed from date to no format for status

    • warning

      deleted the header request parameter Sequence-Version

    • info

      added the new optional header request parameter sequence-version

    • info

      the / request property format was generalized from date to no format

    • info

      the / request property format was generalized from date to no format

    • breaking

      the / request property format changed from no format to date

    • breaking

      the / request property format changed from no format to date

    • warning

      deleted the header request parameter sequence-version

    • info

      added the new optional header request parameter Sequence-Version