curl --request GET \
--url https://coreapi.io/api/analytics/finance/revenue/excel \
--header 'Authorization: Bearer <token>'import requests
url = "https://coreapi.io/api/analytics/finance/revenue/excel"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://coreapi.io/api/analytics/finance/revenue/excel', 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://coreapi.io/api/analytics/finance/revenue/excel",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}"<string>"{
"status": 409,
"type": "ANALYTICS_MRR_FINANCIALS__SNAPSHOT_MONTH_NOT_ENDED",
"title": "An error occurred",
"detail": "<string>"
}{
"status": 422,
"type": "https://tools.ietf.org/html/rfc2616#section-10",
"violations": [
{
"propertyPath": "to",
"message": "Der Zeitraum darf höchstens 36 Monate umfassen.",
"code": "analytics.mrr_financials.range_too_long"
}
],
"title": "Validation Failed",
"detail": "<string>"
}{
"status": 409,
"type": "ANALYTICS_MRR_FINANCIALS__SNAPSHOT_MONTH_NOT_ENDED",
"title": "An error occurred",
"detail": "<string>"
}Export the revenue page as XLSX
The page with the same query as GET /api/analytics/finance/revenue: “Info”, “Umsatz je Monat” (MRR at the end of the month, one-off and variable revenue), “Umsatz je Land”, “ARR am Periodenende”, “Umsatz je Produkt”, “Top-Produkte”, “Umsatzdetails” (every currency), “Umsatz je Kunde und Produkt” (every page of the customer table in its ranking, narrowed by search; page and pageSize are ignored), “Rohdaten Umsatzzeilen” (every revenue line of the range, all classes, without a row limit), “Definitionen”. File name: revenue_{organisation}_{from}_{to}.xlsx.
Required permission: analytics:read.
curl --request GET \
--url https://coreapi.io/api/analytics/finance/revenue/excel \
--header 'Authorization: Bearer <token>'import requests
url = "https://coreapi.io/api/analytics/finance/revenue/excel"
headers = {"Authorization": "Bearer <token>"}
response = requests.get(url, headers=headers)
print(response.text)const options = {method: 'GET', headers: {Authorization: 'Bearer <token>'}};
fetch('https://coreapi.io/api/analytics/finance/revenue/excel', 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://coreapi.io/api/analytics/finance/revenue/excel",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}"<string>"{
"status": 409,
"type": "ANALYTICS_MRR_FINANCIALS__SNAPSHOT_MONTH_NOT_ENDED",
"title": "An error occurred",
"detail": "<string>"
}{
"status": 422,
"type": "https://tools.ietf.org/html/rfc2616#section-10",
"violations": [
{
"propertyPath": "to",
"message": "Der Zeitraum darf höchstens 36 Monate umfassen.",
"code": "analytics.mrr_financials.range_too_long"
}
],
"title": "Validation Failed",
"detail": "<string>"
}{
"status": 409,
"type": "ANALYTICS_MRR_FINANCIALS__SNAPSHOT_MONTH_NOT_ENDED",
"title": "An error occurred",
"detail": "<string>"
}Autorisierungen
API token of the organisation. Send it as Authorization: Bearer api_... The token is bound to exactly one organisation.
Abfrageparameter
First month (YYYY-MM, time zone of the organisation). Default: to minus 11 months.
Last month (YYYY-MM). Default: the current month. At most 36 months.
ISO-4217 code. Default: the default currency.
Movement scope. Default: the organisation setting.
subscription, invoice_address, customer, organisation Analytics segment filter.
Customer filter.
Product filter.
Customer table only: customer name, customer number or the name of one of the customer's products contains this text.
100Antwort
XLSX file download.
The response is of type file.
War diese Seite hilfreich?