List commission plans
curl --request GET \
--url https://coreapi.io/api/commissions/plans \
--header 'Authorization: Bearer <token>'import requests
url = "https://coreapi.io/api/commissions/plans"
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/commissions/plans', 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/commissions/plans",
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;
}{
"data": [
{
"id": "<string>",
"name": "<string>",
"type": "<string>",
"percentage": "<string>",
"basisType": "<string>",
"triggerEvent": "<string>",
"commissionScope": "<string>",
"requireDeal": true,
"payoutThresholdAmount": {
"amount": 123,
"displayAmount": 123,
"currency": "<string>",
"precision": 123
},
"monthlyRevenueThreshold": {
"amount": 123,
"displayAmount": 123,
"currency": "<string>",
"precision": 123
},
"isActive": true,
"rules": [
{
"id": "<string>",
"productId": "<string>",
"externalProductReference": "<string>",
"percentage": "<string>",
"priority": 123
}
],
"createdAt": "2023-11-07T05:31:56Z",
"updatedAt": "2023-11-07T05:31:56Z"
}
],
"meta": {
"count": 123,
"total": 123
},
"pagination": {
"cursor": "<string>",
"hasMore": true,
"nextCursor": "<string>",
"prevCursor": "<string>",
"limit": 20,
"totalItems": 123,
"itemsPerPage": 123,
"currentPage": 123,
"totalPages": 123,
"pageTotalItems": 123
}
}{
"status": 404,
"type": "PLAN__NOT_FOUND",
"title": "An error occurred",
"detail": "Plan not found."
}{
"status": 404,
"type": "PLAN__NOT_FOUND",
"title": "An error occurred",
"detail": "Plan not found."
}Provisionspläne
List commission plans
Beta. This endpoint is unstable and may still change without notice. Pin against the dated version and watch the changelog.
List the commission plans of your Organisation. Supports cursor-based pagination by default and page-based pagination when you pass page or offset.
GET
/
api
/
commissions
/
plans
List commission plans
curl --request GET \
--url https://coreapi.io/api/commissions/plans \
--header 'Authorization: Bearer <token>'import requests
url = "https://coreapi.io/api/commissions/plans"
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/commissions/plans', 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/commissions/plans",
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;
}{
"data": [
{
"id": "<string>",
"name": "<string>",
"type": "<string>",
"percentage": "<string>",
"basisType": "<string>",
"triggerEvent": "<string>",
"commissionScope": "<string>",
"requireDeal": true,
"payoutThresholdAmount": {
"amount": 123,
"displayAmount": 123,
"currency": "<string>",
"precision": 123
},
"monthlyRevenueThreshold": {
"amount": 123,
"displayAmount": 123,
"currency": "<string>",
"precision": 123
},
"isActive": true,
"rules": [
{
"id": "<string>",
"productId": "<string>",
"externalProductReference": "<string>",
"percentage": "<string>",
"priority": 123
}
],
"createdAt": "2023-11-07T05:31:56Z",
"updatedAt": "2023-11-07T05:31:56Z"
}
],
"meta": {
"count": 123,
"total": 123
},
"pagination": {
"cursor": "<string>",
"hasMore": true,
"nextCursor": "<string>",
"prevCursor": "<string>",
"limit": 20,
"totalItems": 123,
"itemsPerPage": 123,
"currentPage": 123,
"totalPages": 123,
"pageTotalItems": 123
}
}{
"status": 404,
"type": "PLAN__NOT_FOUND",
"title": "An error occurred",
"detail": "Plan not found."
}{
"status": 404,
"type": "PLAN__NOT_FOUND",
"title": "An error occurred",
"detail": "Plan not found."
}Autorisierungen
Abfrageparameter
War diese Seite hilfreich?