POST
/
invoices-totals
Header
Body
curl --request POST \
  --url https://eu.sequencehq.com/api/invoices-totals \
  --header 'Authorization: <authorization>' \
  --header 'Content-Type: application/json' \
  --data '{
  "lineItems": [
    {
      "description": "Red",
      "externalIds": [
        {
          "key": "Xero",
          "value": "123"
        }
      ],
      "grossTotal": "0",
      "groupId": "befc8235-a295-4548-87bd-e9bcbbdf18b9",
      "id": "af60cab3-812d-4250-a051-0fb7133a00c7",
      "index": 2,
      "invoiceId": "cd11218d-fa00-4faa-8684-a43113d076a8",
      "netTotal": "0",
      "quantity": "2",
      "rate": "20000.10",
      "rateDisplay": "ABSOLUTE",
      "revenueClassification": "EARNED",
      "servicePeriod": {
        "endDate": "2022-10-24",
        "startDate": "2022-10-20"
      },
      "servicePeriodEnd": "2022-10-24T00:00:00Z",
      "servicePeriodStart": "2022-10-20T00:00:00Z",
      "taxRate": "0.2",
      "title": "Ferraris",
      "totalTax": "0"
    }
  ]
}'
{
  "lineItemGroupTotals": [
    {
      "id": "941272d1-f840-4e16-b698-0cd455c81e0e",
      "total": {
        "grossTotal": "22000",
        "netTotal": "200000",
        "totalTax": "10"
      }
    }
  ],
  "lineItemTotals": [
    {
      "id": "af60cab3-812d-4250-a051-0fb7133a00c7",
      "total": {
        "grossTotal": "22000",
        "netTotal": "200000",
        "totalTax": "10"
      }
    }
  ],
  "total": {
    "grossTotal": "22000",
    "netTotal": "200000",
    "totalTax": "10"
  }
}

Headers

Authorizationrequired
string

Your API credentials. Eg. Basic {credentials}.

Idempotency-Key
string

Specifying a unique ID for this request here lets you retry it without risk of performing the same operation twice.

Body

application/json
lineItemsrequired
object[]

Response

200 - application/json
lineItemGroupTotalsrequired
object[]
lineItemTotalsrequired
object[]
totalrequired
object