curl --request GET \
--url https://eu.sequencehq.com/api/invoices/{invoice}/line-items \
--header 'Authorization: <authorization>'import requests
url = "https://eu.sequencehq.com/api/invoices/{invoice}/line-items"
headers = {"Authorization": "<authorization>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: '<authorization>'}};
fetch('https://eu.sequencehq.com/api/invoices/{invoice}/line-items', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://eu.sequencehq.com/api/invoices/{invoice}/line-items",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: <authorization>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://eu.sequencehq.com/api/invoices/{invoice}/line-items"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "<authorization>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://eu.sequencehq.com/api/invoices/{invoice}/line-items")
.header("Authorization", "<authorization>")
.asString();require 'uri'
require 'net/http'
url = URI("https://eu.sequencehq.com/api/invoices/{invoice}/line-items")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = '<authorization>'
response = http.request(request)
puts response.read_body{
"items": [
{
"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"
}
],
"pagination": {
"after": "MDE4NDUyNjYtNmQ2NC03N2M4LTlhZGYtNDQ4N2Q5NGQxNDU3",
"before": "MDE4NDQyMWUtYTljYy03MTFiLWFmOTMtYmYwNTExZDRkODMz",
"totalResultSize": 10
}
}This response has no body data.This response has no body data.This response has no body data.List all Line Items
List all Line Items
curl --request GET \
--url https://eu.sequencehq.com/api/invoices/{invoice}/line-items \
--header 'Authorization: <authorization>'import requests
url = "https://eu.sequencehq.com/api/invoices/{invoice}/line-items"
headers = {"Authorization": "<authorization>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: '<authorization>'}};
fetch('https://eu.sequencehq.com/api/invoices/{invoice}/line-items', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://eu.sequencehq.com/api/invoices/{invoice}/line-items",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: <authorization>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://eu.sequencehq.com/api/invoices/{invoice}/line-items"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "<authorization>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://eu.sequencehq.com/api/invoices/{invoice}/line-items")
.header("Authorization", "<authorization>")
.asString();require 'uri'
require 'net/http'
url = URI("https://eu.sequencehq.com/api/invoices/{invoice}/line-items")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = '<authorization>'
response = http.request(request)
puts response.read_body{
"items": [
{
"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"
}
],
"pagination": {
"after": "MDE4NDUyNjYtNmQ2NC03N2M4LTlhZGYtNDQ4N2Q5NGQxNDU3",
"before": "MDE4NDQyMWUtYTljYy03MTFiLWFmOTMtYmYwNTExZDRkODMz",
"totalResultSize": 10
}
}This response has no body data.This response has no body data.This response has no body data.Headers
Your API credentials. Eg. Basic {credentials}.
Use this header to select an API version
2024-07-30 Path Parameters
The Invoice ID
Query Parameters
Pagination cursor. To page through items, omit this parameter to retrieve the first page, and then successively use the value you get from pagination.after or pagination.before to retrieve each page.
Pagination cursor. To page through items, omit this parameter to retrieve the first page, and then successively use the value you get from pagination.after or pagination.before to retrieve each page.
Maximum number of objects to return per-page. Must be between 1 and 100 (inclusive).
Sort order. Default: DESC (descending, most often used for reverse chronological sorting).
ASC, DESC Response
OK
LineItems
Show child attributes
Show child attributes
[
{
"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"
}
]
Results pagination
Show child attributes
Show child attributes
{
"after": "MDE4NDUyNjYtNmQ2NC03N2M4LTlhZGYtNDQ4N2Q5NGQxNDU3",
"before": "MDE4NDQyMWUtYTljYy03MTFiLWFmOTMtYmYwNTExZDRkODMz",
"totalResultSize": 10
}