cURL
curl --request GET \
--url https://api.gcore.com/billing/org/v1/erp-invoices \
--header 'Authorization: <api-key>'import requests
url = "https://api.gcore.com/billing/org/v1/erp-invoices"
headers = {"Authorization": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: '<api-key>'}};
fetch('https://api.gcore.com/billing/org/v1/erp-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://api.gcore.com/billing/org/v1/erp-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: <api-key>"
],
]);
$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://api.gcore.com/billing/org/v1/erp-invoices"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.gcore.com/billing/org/v1/erp-invoices")
.header("Authorization", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.gcore.com/billing/org/v1/erp-invoices")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"count": 123,
"results": [
{
"id": 123,
"name": "<string>",
"move_type": "out_invoice",
"currency": "<string>",
"invoice_date": "2023-12-25",
"invoice_date_due": "2023-12-25",
"billing_period_from": "2023-12-25",
"billing_period_to": "2023-12-25",
"amount_untaxed": "<string>",
"amount_tax": "<string>",
"amount_total": "<string>",
"payment_state": "not_paid",
"client_id": -1,
"payer_id": 123,
"invoice_id": 123,
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z"
}
],
"next": "http://api.example.org/accounts/?offset=400&limit=100",
"previous": "http://api.example.org/accounts/?offset=200&limit=100"
}erp-invoices
Get billingorgv1erp invoices
Mixin for viewsets that provides a queryset based on a model class.
GET
/
billing
/
org
/
v1
/
erp-invoices
cURL
curl --request GET \
--url https://api.gcore.com/billing/org/v1/erp-invoices \
--header 'Authorization: <api-key>'import requests
url = "https://api.gcore.com/billing/org/v1/erp-invoices"
headers = {"Authorization": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: '<api-key>'}};
fetch('https://api.gcore.com/billing/org/v1/erp-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://api.gcore.com/billing/org/v1/erp-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: <api-key>"
],
]);
$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://api.gcore.com/billing/org/v1/erp-invoices"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api.gcore.com/billing/org/v1/erp-invoices")
.header("Authorization", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.gcore.com/billing/org/v1/erp-invoices")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"count": 123,
"results": [
{
"id": 123,
"name": "<string>",
"move_type": "out_invoice",
"currency": "<string>",
"invoice_date": "2023-12-25",
"invoice_date_due": "2023-12-25",
"billing_period_from": "2023-12-25",
"billing_period_to": "2023-12-25",
"amount_untaxed": "<string>",
"amount_tax": "<string>",
"amount_total": "<string>",
"payment_state": "not_paid",
"client_id": -1,
"payer_id": 123,
"invoice_id": 123,
"created_at": "2023-11-07T05:31:56Z",
"updated_at": "2023-11-07T05:31:56Z"
}
],
"next": "http://api.example.org/accounts/?offset=400&limit=100",
"previous": "http://api.example.org/accounts/?offset=200&limit=100"
}Authorizations
Query Parameters
Ordering of the results.
For ascending sort order use field.asc, for descending sort order use field.desc.
For sorting by multiple parameters write them as comma separated string: client_id.asc,id.desc.
Final stable tiebreak ordering is added except when pk sorting used.
id.asc- Idid.desc- Id (descending)invoice_date.asc- Invoice dateinvoice_date.desc- Invoice date (descending)amount_total.asc- Amount totalamount_total.desc- Amount total (descending)created_at.asc- Created atcreated_at.desc- Created at (descending)name.asc- Namename.desc- Name (descending)
Available options:
amount_total.asc, amount_total.desc, created_at.asc, created_at.desc, id.asc, id.desc, invoice_date.asc, invoice_date.desc, name.asc, name.desc Ordering of the results.
This field is left for compatibility and can be deprecated in future versions. Use order_by instead.
Default sort order is ascending. Put - before value for descending sort order: -id.
For sorting by multiple parameters write them as comma separated string: -client_id,id.
Final stable tiebreak ordering is added except when pk sorting used.
id- Id-id- Id (descending)invoice_date- Invoice date-invoice_date- Invoice date (descending)amount_total- Amount total-amount_total- Amount total (descending)created_at- Created at-created_at- Created at (descending)name- Name-name- Name (descending)
Available options:
-amount_total, -created_at, -id, -invoice_date, -name, amount_total, created_at, id, invoice_date, name Was this page helpful?