curl --request GET \
--url https://api.comstruct.com/v1/invoices/{id} \
--header 'X-API-Key: <api-key>'import requests
url = "https://api.comstruct.com/v1/invoices/{id}"
headers = {"X-API-Key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'X-API-Key': '<api-key>'}};
fetch('https://api.comstruct.com/v1/invoices/{id}', 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.comstruct.com/v1/invoices/{id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"X-API-Key: <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.comstruct.com/v1/invoices/{id}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-API-Key", "<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.comstruct.com/v1/invoices/{id}")
.header("X-API-Key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.comstruct.com/v1/invoices/{id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["X-API-Key"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"id": "123",
"external_id": "EXT-123",
"external_status": "EXPORTED",
"invoice_number": "INV-2024-001",
"invoice_date": "2024-01-15",
"due_date": "2024-02-15",
"receipt_date": "2023-11-07T05:31:56Z",
"project_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"project_number": "PRJ-2024-001",
"supplier_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"supplier_name": "ABC Supplies Ltd.",
"supplier_tax_id": "<string>",
"supplier_iban": "<string>",
"customer_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"currency": "EUR",
"net_amount": 1000,
"total_tax_amount": 190,
"total_amount": 1190,
"deducted_net_amount": 800,
"deducted_total_tax_amount": 152,
"deducted_total_amount": 952,
"tax_rate": 123,
"status": "NEW",
"document_type": "INVOICE",
"electronic_invoice_type": "ZUGFERD",
"down_payment_number": 123,
"payment_reference": "RF18539007547034",
"reference_type": "QRR",
"payment_term": {
"number": "<string>",
"title": "<string>"
},
"region_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"legal_entity_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"project_region": {
"id": "<string>",
"title": "<string>",
"number": "<string>"
},
"legal_entity": {
"id": "<string>",
"title": "<string>",
"number": "<string>"
},
"supplier": {
"id": "<string>",
"title": "<string>",
"external_id": "<string>",
"legal_uid": "<string>"
},
"project": {
"id": "<string>",
"title": "<string>",
"project_number": "<string>",
"description": "<string>",
"project_region": {
"number": "<string>",
"title": "<string>"
},
"legal_entity": {
"number": "<string>",
"title": "<string>"
}
},
"invoice_accounts": [
{
"net_amount": 1000,
"gross_amount": 1190,
"tax_amount": 190,
"account_type": "DEBIT",
"comment": "<string>",
"quantity": 10,
"unit": "Stück",
"project_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"project": {
"id": "<string>",
"title": "<string>",
"project_number": "<string>"
},
"account": {
"id": "<string>",
"number": "<string>",
"title": "<string>"
},
"tax_code": {
"id": "<string>",
"number": "<string>",
"title": "<string>"
}
}
],
"document": {
"id": "<string>",
"title": "<string>"
},
"comment": "<string>",
"payment_terms": "<string>",
"payment_term_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"discount_rate": 123,
"discount_date": "2023-12-25",
"file_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"created_at": "2024-01-15T10:00:00Z",
"updated_at": "2024-01-16T14:30:00Z",
"assignee_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
}Rechnung abrufen
Erforderliche Berechtigungen: invoices:read
Gibt eine einzelne Rechnung anhand ihrer numerischen ID zurück. Die Antwort entspricht strukturell den
Einträgen in GET /invoices (inkl. invoice_accounts, created_at, updated_at), ohne Verlauf und ohne Positionen.
Positionen über GET /invoices/{id}/items. Verlauf über GET /invoices/{id}/history.
curl --request GET \
--url https://api.comstruct.com/v1/invoices/{id} \
--header 'X-API-Key: <api-key>'import requests
url = "https://api.comstruct.com/v1/invoices/{id}"
headers = {"X-API-Key": "<api-key>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {'X-API-Key': '<api-key>'}};
fetch('https://api.comstruct.com/v1/invoices/{id}', 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.comstruct.com/v1/invoices/{id}",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"X-API-Key: <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.comstruct.com/v1/invoices/{id}"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("X-API-Key", "<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.comstruct.com/v1/invoices/{id}")
.header("X-API-Key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.comstruct.com/v1/invoices/{id}")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["X-API-Key"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"id": "123",
"external_id": "EXT-123",
"external_status": "EXPORTED",
"invoice_number": "INV-2024-001",
"invoice_date": "2024-01-15",
"due_date": "2024-02-15",
"receipt_date": "2023-11-07T05:31:56Z",
"project_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"project_number": "PRJ-2024-001",
"supplier_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"supplier_name": "ABC Supplies Ltd.",
"supplier_tax_id": "<string>",
"supplier_iban": "<string>",
"customer_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"currency": "EUR",
"net_amount": 1000,
"total_tax_amount": 190,
"total_amount": 1190,
"deducted_net_amount": 800,
"deducted_total_tax_amount": 152,
"deducted_total_amount": 952,
"tax_rate": 123,
"status": "NEW",
"document_type": "INVOICE",
"electronic_invoice_type": "ZUGFERD",
"down_payment_number": 123,
"payment_reference": "RF18539007547034",
"reference_type": "QRR",
"payment_term": {
"number": "<string>",
"title": "<string>"
},
"region_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"legal_entity_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"project_region": {
"id": "<string>",
"title": "<string>",
"number": "<string>"
},
"legal_entity": {
"id": "<string>",
"title": "<string>",
"number": "<string>"
},
"supplier": {
"id": "<string>",
"title": "<string>",
"external_id": "<string>",
"legal_uid": "<string>"
},
"project": {
"id": "<string>",
"title": "<string>",
"project_number": "<string>",
"description": "<string>",
"project_region": {
"number": "<string>",
"title": "<string>"
},
"legal_entity": {
"number": "<string>",
"title": "<string>"
}
},
"invoice_accounts": [
{
"net_amount": 1000,
"gross_amount": 1190,
"tax_amount": 190,
"account_type": "DEBIT",
"comment": "<string>",
"quantity": 10,
"unit": "Stück",
"project_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"project": {
"id": "<string>",
"title": "<string>",
"project_number": "<string>"
},
"account": {
"id": "<string>",
"number": "<string>",
"title": "<string>"
},
"tax_code": {
"id": "<string>",
"number": "<string>",
"title": "<string>"
}
}
],
"document": {
"id": "<string>",
"title": "<string>"
},
"comment": "<string>",
"payment_terms": "<string>",
"payment_term_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"discount_rate": 123,
"discount_date": "2023-12-25",
"file_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"created_at": "2024-01-15T10:00:00Z",
"updated_at": "2024-01-16T14:30:00Z",
"assignee_id": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
}GET /invoices (inkl. invoice_accounts, created_at, updated_at), ohne Verlauf und ohne Positionen. Positionen: GET /invoices/{id}/items. Verlauf: GET /invoices/{id}/history.Autorisierungen
API-Schlüssel zur Authentifizierung. Kontaktieren Sie Ihren Customer Success Manager, um einen API-Schlüssel zu erhalten.
Jeder Endpunkt erfordert spezifische Berechtigungen (Scopes); die erforderlichen Scopes werden pro Endpunkt angezeigt.
Pfadparameter
Rechnungs-ID (Integer). Die in Listenantworten zurückgegebene id ist ein String (z. B. "123"),
kann aber direkt als Pfadparameter verwendet werden.
Antwort
Erfolgreich
Die eindeutige Kennung der Rechnung (numerischer String, der eine Integer-ID darstellt)
^[0-9]+$"123"
Die externe Kennung der Rechnung
"EXT-123"
Freier Status aus einem externen System (gesetzt via PATCH /invoices/{id}/external-status).
"EXPORTED"
Die Rechnungsnummer
"INV-2024-001"
Das Rechnungsdatum
"2024-01-15"
Das Fälligkeitsdatum der Rechnung
"2024-02-15"
Das Eingangsdatum der Rechnung
Die Projektkennung
Die Projektnummer
"PRJ-2024-001"
Die Lieferantenkennung
Der Name des Lieferanten
"ABC Supplies Ltd."
Die Steuer-ID des Lieferanten
Die IBAN des Lieferanten
Die Kundenkennung
Die Rechnungswährung (ISO 4217-Code)
"EUR"
Der Nettobetrag der Rechnung
1000
Der Gesamtsteuerbetrag der Rechnung
190
Der Gesamtbetrag der Rechnung
1190
Der abgezogene Nettobetrag der Rechnung
800
Der abgezogene Gesamtsteuerbetrag der Rechnung
152
Der abgezogene Gesamtbetrag (brutto) der Rechnung
952
Der Steuersatz der Rechnung
Der Rechnungsstatus
NEW, PROCESSING, FACTUAL_CHECKING, PRICE_CHECKING, POSITIONS_CHECK, CHECKED, CANCELLED, ERROR, OPEN "NEW"
Dokumenttyp (z.B. INVOICE, CREDIT_NOTE, DOWN_PAYMENT, FINAL_INVOICE, PAYMENT_REMINDER)
"INVOICE"
Typ der elektronischen Rechnung (falls zutreffend)
ZUGFERD, XRECHNUNG, FACTURX "ZUGFERD"
Abschlagszahlungsnummer
Zahlungsreferenz (z.B. Schweizer QR-Rechnung Referenz)
"RF18539007547034"
Typ der Zahlungsreferenz
QRR, SCOR, NON "QRR"
Zahlungsbedingungsdetails
Show child attributes
Show child attributes
Die Regionskennung
Die Gesellschaftskennung
Projektregion-Informationen
Show child attributes
Show child attributes
Gesellschaftsinformationen
Show child attributes
Show child attributes
Lieferanteninformationen
Show child attributes
Show child attributes
Projektinformationen
Show child attributes
Show child attributes
Rechnungskonten
Show child attributes
Show child attributes
Dokumentinformationen
Show child attributes
Show child attributes
Ein optionaler Kommentar
Die Zahlungsbedingungen (Freitext)
Die Zahlungsbedingungskennung
Der Skontosatz
Das Skontodatum
Die Dateikennung für das Rechnungsdokument
Der Erstellungszeitstempel der Rechnung
"2024-01-15T10:00:00Z"
Zeitstempel der letzten Aktualisierung der Rechnung (serverseitig)
"2024-01-16T14:30:00Z"
Die ID des für die Rechnungsprüfung verantwortlichen Benutzers