Get folders
curl --request GET \
--url https://api.chift.eu/consumers/{consumer_id}/accounting/foldersimport requests
url = "https://api.chift.eu/consumers/{consumer_id}/accounting/folders"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://api.chift.eu/consumers/{consumer_id}/accounting/folders', 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/folders",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$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.chift.eu/consumers/{consumer_id}/accounting/folders"
req, _ := http.NewRequest("GET", url, nil)
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.chift.eu/consumers/{consumer_id}/accounting/folders")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.chift.eu/consumers/{consumer_id}/accounting/folders")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body[
{
"id": "<string>",
"name": "<string>",
"selected": true,
"active": true,
"vat": "<string>",
"company_number": "<string>",
"main_currency": "<string>",
"addresses": [
{
"street": "<string>",
"number": "<string>",
"box": "<string>",
"postal_code": "<string>",
"city": "<string>",
"country": "<string>"
}
]
}
]{
"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": {}
}
]
}Folders
Get folders
Returns the list of accounting folders (companies or dossiers) the consumer has access to in the accounting system.
GET
/
consumers
/
{consumer_id}
/
accounting
/
folders
Get folders
curl --request GET \
--url https://api.chift.eu/consumers/{consumer_id}/accounting/foldersimport requests
url = "https://api.chift.eu/consumers/{consumer_id}/accounting/folders"
response = requests.get(url)
print(response.text)const options = {method: 'GET'};
fetch('https://api.chift.eu/consumers/{consumer_id}/accounting/folders', 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/folders",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
]);
$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.chift.eu/consumers/{consumer_id}/accounting/folders"
req, _ := http.NewRequest("GET", url, nil)
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.chift.eu/consumers/{consumer_id}/accounting/folders")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.chift.eu/consumers/{consumer_id}/accounting/folders")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
response = http.request(request)
puts response.read_body[
{
"id": "<string>",
"name": "<string>",
"selected": true,
"active": true,
"vat": "<string>",
"company_number": "<string>",
"main_currency": "<string>",
"addresses": [
{
"street": "<string>",
"number": "<string>",
"box": "<string>",
"postal_code": "<string>",
"city": "<string>",
"country": "<string>"
}
]
}
]{
"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": {}
}
]
}Learn more:
Path Parameters
Response
Successful Response
Indicates whether the folder was selected during the Chift activation process. Only selected folders can be used in subsequent requests. Requests targeting a folder that was not selected will be rejected. If only one folder is selected, it will be used by default when no folder is specified in the request.
Indicates whether the folder is currently active in the target accounting software. Requests targeting an inactive folder will fail on the target software side.
Format: ISO 3166-1 codes.
Show child attributes
Show child attributes