PlanDocket

Dienstleistungsbestellungen

Business+

Bestellungen für Zusatzleistungen anzeigen und bearbeiten.

Erforderliche Bereiche: service_orders
Zugriffsstufe: GET service_orders:read POST / PUT / PATCH / DELETE service_orders:write Mehr zu Zugriffsstufen
Feature-Flag: service_orders

Endpunkte

GET /api/v1/service-orders

Alle Bestellungen auflisten

GET /api/v1/service-orders/{id}

Einzelne Bestellung abrufen

PATCH /api/v1/service-orders/{id}

Status ändern: submitted → confirmed oder cancelled, confirmed → completed oder cancelled ("cancellation_reason" optional). Beim Stornieren wird der Bestand zurückgebucht und offene abrechenbare Leistungen entfallen; eine bereits abgerechnete Bestellung kann nicht storniert werden (409, Korrektur über Gutschrift). Löst service_order.confirmed / .completed / .cancelled aus

POST /api/v1/service-orders/{id}/status

Wie PATCH /service-orders/{id} (für Clients, die kein PATCH senden können)

Abfrageparameter

Parameter Beschreibung
event_key Nach Event-Schlüssel filtern
status Nach Bestellungsstatus filtern
participant_id Nach Teilnehmer-ID filtern
order_number Nach Bestellnummer filtern
sort Sortierfeld (order_number, total, status, submitted_at, created_at)
order Sortierrichtung (ASC oder DESC, Standard: DESC)
include Verknüpfte Daten einschließen (items, participant)

Request-Schema

Parameter Typ Erforderlich Beschreibung
status string Ja Neuer Status: confirmed, completed oder cancelled
cancellation_reason string Nein Begründung für den Aussteller beim Stornieren (optional)

Response-Schema

Feld Typ
id integer
order_number string|null
event_participant_id integer|null
status string
subtotal float
tax_total float
total float
currency string
notes string|null
submitted_at string|null
confirmed_at string|null
cancelled_at string|null
cancellation_reason string|null
created_at string
updated_at string

Codebeispiele

curl -X GET "https://ihr-mandant.plandocket.com/api/v1/service-orders" \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Accept: application/json"
<?php
$apiKey = 'YOUR_API_KEY';
$baseUrl = 'https://ihr-mandant.plandocket.com';

$ch = curl_init();
curl_setopt_array($ch, [
    CURLOPT_URL => $baseUrl . '/api/v1/service-orders',
    CURLOPT_RETURNTRANSFER => true,
    CURLOPT_HTTPHEADER => [
        'Authorization: Bearer ' . $apiKey,
    ],
]);

$response = curl_exec($ch);
curl_close($ch);

$data = json_decode($response, true);
print_r($data);
const apiKey = 'YOUR_API_KEY';
const baseUrl = 'https://ihr-mandant.plandocket.com';

const response = await fetch(`${baseUrl}/api/v1/service-orders`, {
  method: 'GET',
  headers: {
    'Authorization': `Bearer ${apiKey}`,
  },
});

const data = await response.json();
console.log(data);
import requests

api_key = 'YOUR_API_KEY'
base_url = 'https://ihr-mandant.plandocket.com'

headers = {
    'Authorization': f'Bearer {api_key}',
}

response = requests.get(f'{base_url}/api/v1/service-orders', headers=headers)
data = response.json()
print(data)

Beispiel-Antwort

200 OK
{
    "data": [
        {
            "id": 1,
            "order_number": "string",
            "event_participant_id": 1,
            "status": "string",
            "subtotal": 100,
            "tax_total": 100,
            "total": 100,
            "currency": "string",
            "notes": "string",
            "submitted_at": "2026-01-15T10:00:00+01:00",
            "confirmed_at": "2026-01-15T10:00:00+01:00",
            "cancelled_at": "2026-01-15T10:00:00+01:00",
            "cancellation_reason": "string",
            "created_at": "2026-01-15T10:00:00+01:00",
            "updated_at": "2026-01-15T10:00:00+01:00"
        }
    ],
    "meta": {
        "current_page": 1,
        "per_page": 25,
        "total": 1,
        "total_pages": 1
    }
}
API Version v1.0