Aufgaben
Business+Verwalten Sie Aufgaben und To-Dos.
Erforderliche Bereiche:
tasks
Feature-Flag:
tasks
Endpunkte
GET
/api/v1/tasks
Alle Aufgaben auflisten
GET
/api/v1/tasks/{id}
Einzelne Aufgabe abrufen
POST
/api/v1/tasks
Neue Aufgabe erstellen
PUT/PATCH
/api/v1/tasks/{id}
Aufgabe aktualisieren
DELETE
/api/v1/tasks/{id}
Aufgabe löschen
Abfrageparameter
| Parameter | Beschreibung |
|---|---|
search
|
Suchbegriff zum Filtern der Ergebnisse |
status
|
Nach Aufgabenstatus filtern |
priority
|
Nach Aufgabenpriorität filtern |
assigned_to
|
Nach zugewiesenem Administrator filtern |
entity_type
|
Nach verknüpftem Entitätstyp filtern |
entity_id
|
Nach verknüpfter Entitäts-ID filtern |
overdue
|
Nur überfällige Aufgaben anzeigen (1) |
sort
|
Sortierfeld (title, due_date, priority, status, created_at) |
order
|
Sortierrichtung (ASC oder DESC, Standard: DESC) |
include
|
Verknüpfte Daten einschließen (entity) |
Request-Schema
| Parameter | Typ | Erforderlich | Beschreibung |
|---|---|---|---|
title
|
string | Ja | Titel der Aufgabe |
description
|
string | Nein | Beschreibung der Aufgabe |
status
|
string | Nein | Status (pending, in_progress, completed, cancelled) |
priority
|
string | Nein | Priorität (urgent, high, normal, low) |
due_date
|
string | Nein | Fälligkeitsdatum (ISO 8601 Format) |
assigned_to
|
integer | Nein | ID des zugewiesenen Administrators |
entity_type
|
string | Nein | Verknüpfter Entitätstyp (event, contact, application, etc.) |
entity_id
|
integer | Nein | ID der verknüpften Entität |
Response-Schema
| Feld | Typ |
|---|---|
id
|
integer |
entity_type
|
string|null |
entity_id
|
integer|null |
assigned_to
|
integer|null |
assigned_to_name
|
string|null |
created_by
|
integer |
created_by_name
|
string|null |
title
|
string |
description
|
string|null |
due_date
|
string|null |
priority
|
string |
status
|
string |
completed_at
|
string|null |
completed_by
|
integer|null |
created_at
|
string |
updated_at
|
string |
Codebeispiele
curl -X GET "https://your-tenant.plandocket.com/api/v1/tasks" \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Content-Type: application/json"
<?php
$apiKey = 'YOUR_API_KEY';
$baseUrl = 'https://your-tenant.plandocket.com';
$ch = curl_init();
curl_setopt_array($ch, [
CURLOPT_URL => $baseUrl . '/api/v1/tasks',
CURLOPT_RETURNTRANSFER => true,
CURLOPT_HTTPHEADER => [
'Authorization: Bearer ' . $apiKey,
'Content-Type: application/json',
],
]);
$response = curl_exec($ch);
$data = json_decode($response, true);
curl_close($ch);
print_r($data);
const apiKey = 'YOUR_API_KEY';
const baseUrl = 'https://your-tenant.plandocket.com';
const response = await fetch(`${baseUrl}/api/v1/tasks`, {
method: 'GET',
headers: {
'Authorization': `Bearer ${apiKey}`,
'Content-Type': 'application/json',
},
});
const data = await response.json();
console.log(data);
import requests
api_key = 'YOUR_API_KEY'
base_url = 'https://your-tenant.plandocket.com'
headers = {
'Authorization': f'Bearer {api_key}',
'Content-Type': 'application/json',
}
response = requests.get(f'{base_url}/api/v1/tasks', headers=headers)
data = response.json()
print(data)
Beispiel-Antwort
200 OK
{
"data": {
"task_id": 1,
"created_at": 1704067200,
"updated_at": 1704067200
},
"meta": {
"request_id": "req_abc123"
}
}