Import External Document
Imports a document created outside the system and links it to an existing voucher record. This document can then be used for dunning and if configured collection.
Basic authentication is a simple authentication scheme built into the HTTP protocol. To use it, send your HTTP requests with an Authorization header that contains the word Basic followed by a space and a base64-encoded string username:password.Example: Authorization: Basic ZGVtbzpwQDU1dzByZA==
In: header
Path Parameters
Your invoiceReference (The Invoice ID in your system)
Label of the communication, additional information about the document. Shown in our UI.
File to upload
binaryName of the file, including extension. This will also be visible to your customer if the document is sent as an attachment. Allowed extensions are: pdf and eml
Kind of communication, use what best describes the document, use "invoice" for the orignal invoice that was sent to the customer.
"invoice" | "creditnote" | "reminder" | "dunning1" | "dunning2" | "dunning3" | "dunning4" | "email" | "letter"Label of the communication to identity the document. Shown in our UI.
Response Body
curl -X POST "https://staging1.abillify.dev/api/invoices/string/importExternalDocument" \
-F file="string" \
-F filename="RE12345.pdf" \
-F kind="invoice"const body = new FormData();
body.set(file, "string")
body.set(filename, "RE12345.pdf")
body.set(kind, "invoice")
fetch("https://staging1.abillify.dev/api/invoices/string/importExternalDocument", {
body
})package main
import (
"fmt"
"net/http"
"io/ioutil"
"mime/multipart"
"bytes"
)
func main() {
url := "https://staging1.abillify.dev/api/invoices/string/importExternalDocument"
body := new(bytes.Buffer)
mp := multipart.NewWriter(payload)
mp.WriteField("file", `string`)
mp.WriteField("filename", `RE12345.pdf`)
mp.WriteField("kind", `invoice`)
req, _ := http.NewRequest("POST", url, body)
req.Header.Add("Content-Type", "multipart/form-data")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := ioutil.ReadAll(res.Body)
fmt.Println(res)
fmt.Println(string(body))
}import requests
url = "https://staging1.abillify.dev/api/invoices/string/importExternalDocument"
body = {
"file": "string",
"filename": "RE12345.pdf",
"kind": "invoice"
}
response = requests.request("POST", url, data = body, headers = {
"Content-Type": "multipart/form-data"
})
print(response.text){
"communicationReference": "_12345",
"fileReference": "_67890",
"voucherReference": "_1234"
}{
"code": 400,
"details": [
{
"error": "Value for field 'debtor' is of wrong type, expected bigint.",
"fields": [
"debtor"
],
"hint": "Value must be a number or a string containing only a number."
}
],
"message": "InvalidValue, see error details",
"name": "ClientError",
"type": "ERR_INVALID_VALUE"
}{
"code": 400,
"details": [
{
"error": "Value for field 'debtor' is of wrong type, expected bigint.",
"fields": [
"debtor"
],
"hint": "Value must be a number or a string containing only a number."
}
],
"message": "InvalidValue, see error details",
"name": "ClientError",
"type": "ERR_INVALID_VALUE"
}Get payments and charges for invoice by reference GET
Retrieves detailed payment and charge information for the specified invoice. The response includes all payments applied to the invoice and any charges/fees added to it. **Payments** originate from two sources: - **Transactions** (bank transfers, etc.): Identified when `booking.transaction` is set - **Other vouchers** (credit notes): Identified when `booking.transaction` is null and `booking.voucher` is set **Charges** include: - Dunning fees added during the collection process - Writeoffs for slight underpayments or adjustments - Other fees or adjustments applied to the voucher balance Use this endpoint to get a complete overview of the payment status and all financial adjustments for an invoice.
List invoices with pagination GET
Next Page