curl --request POST \
--url https://api.chift.eu/consumers/{consumer_id}/invoicing/upload-document \
--header 'Content-Type: application/json' \
--data '
{
"base64_string": "<base64-encoded-file-content>"
}
'import requests
url = "https://api.chift.eu/consumers/{consumer_id}/invoicing/upload-document"
payload = { "base64_string": "<base64-encoded-file-content>" }
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({base64_string: '<base64-encoded-file-content>'})
};
fetch('https://api.chift.eu/consumers/{consumer_id}/invoicing/upload-document', 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.chift.eu/consumers/{consumer_id}/invoicing/upload-document",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'base64_string' => '<base64-encoded-file-content>'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.chift.eu/consumers/{consumer_id}/invoicing/upload-document"
payload := strings.NewReader("{\n \"base64_string\": \"<base64-encoded-file-content>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.chift.eu/consumers/{consumer_id}/invoicing/upload-document")
.header("Content-Type", "application/json")
.body("{\n \"base64_string\": \"<base64-encoded-file-content>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.chift.eu/consumers/{consumer_id}/invoicing/upload-document")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"base64_string\": \"<base64-encoded-file-content>\"\n}"
response = http.request(request)
puts response.read_body{
"id": "<this-id>",
"source_ref": {
"id": "<target-software-id>",
"model": "invoice"
},
"currency": "EUR",
"invoice_type": "customer_invoice",
"status": "cancelled",
"invoice_date": "2026-01-15",
"tax_amount": 42,
"untaxed_amount": 200,
"total": 242,
"lines": [],
"partner_id": "<invoicing-partner-id>",
"invoice_number": "INV-2026-0001",
"due_date": "2026-02-14",
"reference": "REF-0001",
"payment_communication": "+++000/0000/00000+++",
"customer_memo": "Thank you for your business.",
"journal_ref": {
"id": "<target-software-id>",
"model": "invoice",
"name": "Example Company S.A."
},
"italian_specificities": {
"stamp_duty_amount": 2,
"withholding_tax": {
"rate": 20,
"amount": 40,
"reason": "RT01",
"payment_reason": "A"
},
"welfare_fund": {
"rate": 4,
"amount": 8,
"type": "TC01"
},
"payment_reporting": {
"method": "MP01",
"conditions": "TP01"
}
},
"spanish_specificities": {
"withholding_tax": {
"tax_rate": -19,
"tax_code": "<accounting-tax-code>",
"tax_amount": -38
}
},
"last_updated_on": "2026-01-15T10:30:00Z",
"outstanding_amount": 0,
"last_payment_date": "2026-02-14",
"accounting_date": "2026-01-15",
"payment_method_id": "<invoicing-payment-method-id>",
"currency_exchange_rate": 1
}{
"message": "Error while trying to perform your request",
"status": "error"
}{
"message": "Validation error",
"status": "error",
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"input": "<unknown>",
"ctx": {}
}
]
}Upload a document (PDF)
Uploads a PDF document to the invoicing system and returns a reference to the stored document.
curl --request POST \
--url https://api.chift.eu/consumers/{consumer_id}/invoicing/upload-document \
--header 'Content-Type: application/json' \
--data '
{
"base64_string": "<base64-encoded-file-content>"
}
'import requests
url = "https://api.chift.eu/consumers/{consumer_id}/invoicing/upload-document"
payload = { "base64_string": "<base64-encoded-file-content>" }
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify({base64_string: '<base64-encoded-file-content>'})
};
fetch('https://api.chift.eu/consumers/{consumer_id}/invoicing/upload-document', 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.chift.eu/consumers/{consumer_id}/invoicing/upload-document",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
'base64_string' => '<base64-encoded-file-content>'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.chift.eu/consumers/{consumer_id}/invoicing/upload-document"
payload := strings.NewReader("{\n \"base64_string\": \"<base64-encoded-file-content>\"\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.post("https://api.chift.eu/consumers/{consumer_id}/invoicing/upload-document")
.header("Content-Type", "application/json")
.body("{\n \"base64_string\": \"<base64-encoded-file-content>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.chift.eu/consumers/{consumer_id}/invoicing/upload-document")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "{\n \"base64_string\": \"<base64-encoded-file-content>\"\n}"
response = http.request(request)
puts response.read_body{
"id": "<this-id>",
"source_ref": {
"id": "<target-software-id>",
"model": "invoice"
},
"currency": "EUR",
"invoice_type": "customer_invoice",
"status": "cancelled",
"invoice_date": "2026-01-15",
"tax_amount": 42,
"untaxed_amount": 200,
"total": 242,
"lines": [],
"partner_id": "<invoicing-partner-id>",
"invoice_number": "INV-2026-0001",
"due_date": "2026-02-14",
"reference": "REF-0001",
"payment_communication": "+++000/0000/00000+++",
"customer_memo": "Thank you for your business.",
"journal_ref": {
"id": "<target-software-id>",
"model": "invoice",
"name": "Example Company S.A."
},
"italian_specificities": {
"stamp_duty_amount": 2,
"withholding_tax": {
"rate": 20,
"amount": 40,
"reason": "RT01",
"payment_reason": "A"
},
"welfare_fund": {
"rate": 4,
"amount": 8,
"type": "TC01"
},
"payment_reporting": {
"method": "MP01",
"conditions": "TP01"
}
},
"spanish_specificities": {
"withholding_tax": {
"tax_rate": -19,
"tax_code": "<accounting-tax-code>",
"tax_amount": -38
}
},
"last_updated_on": "2026-01-15T10:30:00Z",
"outstanding_amount": 0,
"last_payment_date": "2026-02-14",
"accounting_date": "2026-01-15",
"payment_method_id": "<invoicing-payment-method-id>",
"currency_exchange_rate": 1
}{
"message": "Error while trying to perform your request",
"status": "error"
}{
"message": "Validation error",
"status": "error",
"detail": [
{
"loc": [
"<string>"
],
"msg": "<string>",
"type": "<string>",
"input": "<unknown>",
"ctx": {}
}
]
}Path Parameters
Body
Response
Successful Response
Technical id in Chift
"<this-id>"
Technical id in the target software
Show child attributes
Show child attributes
Currency of the uploaded document
"EUR"
Invoice type of the uploaded document
customer_invoice, customer_refund, supplier_invoice, supplier_refund, all Status of the uploaded document
cancelled, draft, posted, paid Invoicing date
"2026-01-15"
Taxes amount
42
Untaxed amount
200
Total amount incl. taxes
242
Invoice lines
Show child attributes
Show child attributes
Technical id of the vendor/customer in Chift
"<invoicing-partner-id>"
Number/sequence
"INV-2026-0001"
Due date
"2026-02-14"
Reference
"REF-0001"
Payment communication
"+++000/0000/00000+++"
Customer note/memo
"Thank you for your business."
Journal
Show child attributes
Show child attributes
Specificities for Italy
Show child attributes
Show child attributes
Specificities for Spain
Show child attributes
Show child attributes
"2026-01-15T10:30:00Z"
Amount left to be paid
0
Date of the last payment linked to the invoice
"2026-02-14"
Accounting date
"2026-01-15"
Technical id of the payment method in Chift
"<invoicing-payment-method-id>"
Exchange rate from the invoice currency to the connector's base currency, at the date of the invoice.