curl --request POST \
--url https://api.chift.eu/consumers/{consumer_id}/accounting/journal \
--header 'Content-Type: application/json' \
--data '
{
"code": "BNK",
"name": "Bank journal",
"counterpart_account": "<accounting-account-number>"
}
'import requests
url = "https://api.chift.eu/consumers/{consumer_id}/accounting/journal"
payload = {
"code": "BNK",
"name": "Bank journal",
"counterpart_account": "<accounting-account-number>"
}
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({
code: 'BNK',
name: 'Bank journal',
counterpart_account: '<accounting-account-number>'
})
};
fetch('https://api.chift.eu/consumers/{consumer_id}/accounting/journal', 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}/accounting/journal",
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([
'code' => 'BNK',
'name' => 'Bank journal',
'counterpart_account' => '<accounting-account-number>'
]),
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}/accounting/journal"
payload := strings.NewReader("{\n \"code\": \"BNK\",\n \"name\": \"Bank journal\",\n \"counterpart_account\": \"<accounting-account-number>\"\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}/accounting/journal")
.header("Content-Type", "application/json")
.body("{\n \"code\": \"BNK\",\n \"name\": \"Bank journal\",\n \"counterpart_account\": \"<accounting-account-number>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.chift.eu/consumers/{consumer_id}/accounting/journal")
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 \"code\": \"BNK\",\n \"name\": \"Bank journal\",\n \"counterpart_account\": \"<accounting-account-number>\"\n}"
response = http.request(request)
puts response.read_body{
"id": "<this-journal-id>",
"name": "Bank journal",
"journal_type": "customer_invoice",
"code": "BNK",
"counterpart_account": "<accounting-account-number>",
"unallocated_account": "<accounting-account-number>",
"next_document_numbers": [],
"iban": "BE00000000000000",
"currency": "EUR",
"other_currencies_allowed": true,
"blocked": false
}Create journal
Creates a new accounting journal (e.g., sales, purchase, or bank journal) in the accounting system.
curl --request POST \
--url https://api.chift.eu/consumers/{consumer_id}/accounting/journal \
--header 'Content-Type: application/json' \
--data '
{
"code": "BNK",
"name": "Bank journal",
"counterpart_account": "<accounting-account-number>"
}
'import requests
url = "https://api.chift.eu/consumers/{consumer_id}/accounting/journal"
payload = {
"code": "BNK",
"name": "Bank journal",
"counterpart_account": "<accounting-account-number>"
}
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({
code: 'BNK',
name: 'Bank journal',
counterpart_account: '<accounting-account-number>'
})
};
fetch('https://api.chift.eu/consumers/{consumer_id}/accounting/journal', 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}/accounting/journal",
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([
'code' => 'BNK',
'name' => 'Bank journal',
'counterpart_account' => '<accounting-account-number>'
]),
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}/accounting/journal"
payload := strings.NewReader("{\n \"code\": \"BNK\",\n \"name\": \"Bank journal\",\n \"counterpart_account\": \"<accounting-account-number>\"\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}/accounting/journal")
.header("Content-Type", "application/json")
.body("{\n \"code\": \"BNK\",\n \"name\": \"Bank journal\",\n \"counterpart_account\": \"<accounting-account-number>\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.chift.eu/consumers/{consumer_id}/accounting/journal")
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 \"code\": \"BNK\",\n \"name\": \"Bank journal\",\n \"counterpart_account\": \"<accounting-account-number>\"\n}"
response = http.request(request)
puts response.read_body{
"id": "<this-journal-id>",
"name": "Bank journal",
"journal_type": "customer_invoice",
"code": "BNK",
"counterpart_account": "<accounting-account-number>",
"unallocated_account": "<accounting-account-number>",
"next_document_numbers": [],
"iban": "BE00000000000000",
"currency": "EUR",
"other_currencies_allowed": true,
"blocked": false
}Path Parameters
Query Parameters
Id of the accounting folder instance. A folder represents a legal entity within the system. Required when the multiple folders feature is enabled.
Body
Short code or identifier of the journal (e.g., 'BNK', 'INV').
2"BNK"
Name or label of the journal as it appears in the accounting system.
1"Bank journal"
Type of journal.
customer_invoice, customer_refund, supplier_invoice, supplier_refund, bank, cash, miscellaneous_operation When journal is of type bank or cash, this is account number of the counterpart account used for the journal.
"<accounting-account-number>"
Response
Successful Response
"<this-journal-id>"
"Bank journal"
Category of the journal. In retrieved data the values are customer_invoice, customer_refund, supplier_invoice, supplier_refund, financial_operation, miscellaneous_operation, or unknown. 'bank' and 'cash' exist only in the creation model; a journal representing a bank or cash account is retrieved as financial_operation (typically with an iban), so filter on financial_operation, not 'bank'/'cash', to find treasury journals.
customer_invoice, customer_refund, supplier_invoice, supplier_refund, financial_operation, miscellaneous_operation, unknown "BNK"
Account number of the counterpart account used for the journal, for a treasury journal representing a bank or cash account (retrieved as journal_type financial_operation; bank/cash in the creation model).
"<accounting-account-number>"
Unallocated ledger account used to book entries when the final ledger account / client / supplier / employee is not yet known (specific to treasury journals, retrieved as journal_type financial_operation; bank/cash in the creation model).
"<accounting-account-number>"
The next document numbers to use when the accounting tool enforces its own numbering sequence on creation (one sequence per journal, per book year, per folder).
Show child attributes
Show child attributes
IBAN of the bank account linked to the journal, for a treasury journal representing a bank account (retrieved as journal_type financial_operation).
"BE00000000000000"
Currency of the journal (e.g., EUR). If empty, the journal follows the currency of the accounting folder.
"EUR"
Indicates if the journal allows other currencies. If it doesn't allow other currencies an exchange rate must be provided for Chift to convert the amounts to the journal currency. This only applicable if the journal currency is the same as the accounting folder currency.
Indicates if the journal is blocked for creating entries.