List invoices
curl --request GET \
--url https://app.blinksale.test/api/v1/invoices \
--header 'Authorization: Bearer <token>'import requests
url = "https://app.blinksale.test/api/v1/invoices"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://app.blinksale.test/api/v1/invoices', 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://app.blinksale.test/api/v1/invoices",
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: Bearer <token>"
],
]);
$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://app.blinksale.test/api/v1/invoices"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://app.blinksale.test/api/v1/invoices")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.blinksale.test/api/v1/invoices")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"success": true,
"message": "Resources retrieved successfully",
"data": [
{
"id": "01jtbf0c9zaraqx3swthf88n5y",
"organization_id": "01jtbf0c9zaraqx3swthf88n5y",
"client_id": "01jtbf0c9zaraqx3swthf88n5y",
"converted_from": "01jtbf0c9zaraqx3swthf88n5y",
"converted_from_number": "EST-00001",
"invoice_number": "INV-00001",
"prefix": "INV-",
"number": 1,
"currency": "USD",
"currency_name": "US Dollar",
"currency_symbol": "$",
"tax_id": "01jtbf0c9zaraqx3swthf88n5y",
"tax_name": "Sales Tax",
"tax_percent": 8.5,
"tax_distribution": "PER_DOCUMENT",
"tax_distribution_name": "Per Document",
"discount_type": "PERCENTAGE",
"discount_type_name": "Percentage",
"discount_value": 10,
"discount_distribution": "PER_DOCUMENT",
"discount_distribution_name": "Per Document",
"net_terms": "NET30",
"net_terms_name": "Net 30",
"has_late_fee": true,
"late_fee_kind": "PERCENTAGE",
"late_fee_kind_name": "Percentage",
"late_fee_interval": "ONE_TIME",
"late_fee_interval_name": "One Time",
"late_fee": 5,
"next_late_fee_update_at": "2023-11-07T05:31:56Z",
"total_late_fee": 0,
"shipping": 15,
"total": 1642.5,
"total_paid": 0,
"total_due": 1642.5,
"total_due_unsettled": 1642.5,
"notes": "Payment due within 30 days.",
"options": {},
"status": "DRAFT",
"status_name": "Draft",
"is_editable": true,
"issued_at": "2023-06-15",
"due_at": "2023-07-15",
"client": {
"id": "01jtbf0c9zaraqx3swthf88n5y",
"name": "Acme Inc",
"email": "[email protected]",
"kind": "BUSINESS",
"kind_name": "Business",
"profile": {
"company_name": "Acme Inc",
"website": "https://acme.com"
},
"address": {
"line1": "123 Main St",
"line2": "Suite 101",
"city": "San Francisco",
"state": "CA",
"zip": "94107",
"country": "US"
},
"document_defaults": {
"currency": "USD"
},
"contact_count": 3,
"note_count": 2,
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z"
},
"organization": {
"id": "01jtbf0c9zaraqx3swthf88n5y",
"name": "Acme Inc",
"stripe_id": "<string>",
"subscription": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"trial_ends_at": "2023-11-07T05:31:56Z",
"ends_at": "2023-11-07T05:31:56Z",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z"
},
"profile": {},
"role": "OWNER",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z"
},
"line_items": [
{
"id": "01jtbf0c9zaraqx3swthf88n5y",
"organization_id": "01jtbf0c9zaraqx3swthf88n5y",
"name": "Consulting Services",
"description": "Professional consulting services",
"quantity": 10,
"price": 150,
"unit_of_measurement_id": "01jtbf0c9zaraqx3swthf88n5y",
"unit_name": "Hour",
"tax_id": "01jtbf0c9zaraqx3swthf88n5y",
"tax_name": "Sales Tax",
"tax_percent": 8.5,
"discount_type": "PERCENTAGE",
"discount_value": 10,
"subtotal": 1500,
"tax_amount": 127.5,
"total": 1627.5
}
],
"subtotal": 1500,
"document_discount": 0,
"tax_amount": 127.5,
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z"
}
],
"meta": {
"current_page": 1,
"from": 1,
"last_page": 5,
"links": [
{
"url": "<string>",
"label": "<string>",
"active": true
}
],
"path": "<string>",
"per_page": 15,
"to": 15,
"total": 75
}
}{
"success": false,
"message": "An error occurred",
"errors": {
"email": [
"The email field is required."
]
}
}{
"success": false,
"message": "An error occurred",
"errors": {
"email": [
"The email field is required."
]
}
}Invoices
List Invoices
Get paginated list of invoices
GET
/
v1
/
invoices
List invoices
curl --request GET \
--url https://app.blinksale.test/api/v1/invoices \
--header 'Authorization: Bearer <token>'import requests
url = "https://app.blinksale.test/api/v1/invoices"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://app.blinksale.test/api/v1/invoices', 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://app.blinksale.test/api/v1/invoices",
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: Bearer <token>"
],
]);
$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://app.blinksale.test/api/v1/invoices"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://app.blinksale.test/api/v1/invoices")
.header("Authorization", "Bearer <token>")
.asString();require 'uri'
require 'net/http'
url = URI("https://app.blinksale.test/api/v1/invoices")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
response = http.request(request)
puts response.read_body{
"success": true,
"message": "Resources retrieved successfully",
"data": [
{
"id": "01jtbf0c9zaraqx3swthf88n5y",
"organization_id": "01jtbf0c9zaraqx3swthf88n5y",
"client_id": "01jtbf0c9zaraqx3swthf88n5y",
"converted_from": "01jtbf0c9zaraqx3swthf88n5y",
"converted_from_number": "EST-00001",
"invoice_number": "INV-00001",
"prefix": "INV-",
"number": 1,
"currency": "USD",
"currency_name": "US Dollar",
"currency_symbol": "$",
"tax_id": "01jtbf0c9zaraqx3swthf88n5y",
"tax_name": "Sales Tax",
"tax_percent": 8.5,
"tax_distribution": "PER_DOCUMENT",
"tax_distribution_name": "Per Document",
"discount_type": "PERCENTAGE",
"discount_type_name": "Percentage",
"discount_value": 10,
"discount_distribution": "PER_DOCUMENT",
"discount_distribution_name": "Per Document",
"net_terms": "NET30",
"net_terms_name": "Net 30",
"has_late_fee": true,
"late_fee_kind": "PERCENTAGE",
"late_fee_kind_name": "Percentage",
"late_fee_interval": "ONE_TIME",
"late_fee_interval_name": "One Time",
"late_fee": 5,
"next_late_fee_update_at": "2023-11-07T05:31:56Z",
"total_late_fee": 0,
"shipping": 15,
"total": 1642.5,
"total_paid": 0,
"total_due": 1642.5,
"total_due_unsettled": 1642.5,
"notes": "Payment due within 30 days.",
"options": {},
"status": "DRAFT",
"status_name": "Draft",
"is_editable": true,
"issued_at": "2023-06-15",
"due_at": "2023-07-15",
"client": {
"id": "01jtbf0c9zaraqx3swthf88n5y",
"name": "Acme Inc",
"email": "[email protected]",
"kind": "BUSINESS",
"kind_name": "Business",
"profile": {
"company_name": "Acme Inc",
"website": "https://acme.com"
},
"address": {
"line1": "123 Main St",
"line2": "Suite 101",
"city": "San Francisco",
"state": "CA",
"zip": "94107",
"country": "US"
},
"document_defaults": {
"currency": "USD"
},
"contact_count": 3,
"note_count": 2,
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z"
},
"organization": {
"id": "01jtbf0c9zaraqx3swthf88n5y",
"name": "Acme Inc",
"stripe_id": "<string>",
"subscription": {
"id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"trial_ends_at": "2023-11-07T05:31:56Z",
"ends_at": "2023-11-07T05:31:56Z",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z"
},
"profile": {},
"role": "OWNER",
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z"
},
"line_items": [
{
"id": "01jtbf0c9zaraqx3swthf88n5y",
"organization_id": "01jtbf0c9zaraqx3swthf88n5y",
"name": "Consulting Services",
"description": "Professional consulting services",
"quantity": 10,
"price": 150,
"unit_of_measurement_id": "01jtbf0c9zaraqx3swthf88n5y",
"unit_name": "Hour",
"tax_id": "01jtbf0c9zaraqx3swthf88n5y",
"tax_name": "Sales Tax",
"tax_percent": 8.5,
"discount_type": "PERCENTAGE",
"discount_value": 10,
"subtotal": 1500,
"tax_amount": 127.5,
"total": 1627.5
}
],
"subtotal": 1500,
"document_discount": 0,
"tax_amount": 127.5,
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z"
}
],
"meta": {
"current_page": 1,
"from": 1,
"last_page": 5,
"links": [
{
"url": "<string>",
"label": "<string>",
"active": true
}
],
"path": "<string>",
"per_page": 15,
"to": 15,
"total": 75
}
}{
"success": false,
"message": "An error occurred",
"errors": {
"email": [
"The email field is required."
]
}
}{
"success": false,
"message": "An error occurred",
"errors": {
"email": [
"The email field is required."
]
}
}Authorizations
Access token obtained from the /v1/auth/login endpoint
Query Parameters
Number of records per page
Search term to filter invoices
Filter by status (DRAFT, SENT, VIEWED, PAID, PARTIAL, OVERDUE, CANCELED, REFUNDED)
Filter by client ID
⌘I

