PlanDocket

Benutzerdefinierte Felder

Business+

Verwalten Sie benutzerdefinierte Feldwerte.

Erforderliche Bereiche: custom_fields
Zugriffsstufe: GET custom_fields:read POST / PUT / PATCH / DELETE custom_fields:write Mehr zu Zugriffsstufen

Endpunkte

GET /api/v1/custom-fields/definitions

Alle benutzerdefinierten Felder auflisten

GET /api/v1/custom-fields/{entity_type}/{entity_id}

Feldwerte für Entität abrufen

PUT /api/v1/custom-fields/{entity_type}/{entity_id}

Feldwerte aktualisieren

Abfrageparameter

Parameter Beschreibung
entity_type Definitionen nach Entitätstyp filtern
is_active Definitionen nach Aktivstatus filtern (0 oder 1)

Request-Schema

Parameter Typ Erforderlich Beschreibung
{field_key} mixed Nein Wert für das benutzerdefinierte Feld, identifiziert durch den Feldschlüssel. Der Typ hängt vom Feldtyp ab (Text, Zahl, Datum usw.).

Response-Schema

Feld Typ
id integer
form_id integer|null
entity_type string
field_key string
field_label string
field_type string
section_key string|null
field_options string|null
validation_rules string|null
is_required boolean
is_searchable boolean
applicant_visibility string
is_active boolean
display_order integer

Codebeispiele

curl -X GET "https://ihr-mandant.plandocket.com/api/v1/custom-fields/definitions?entity_type=contact" \
  -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/custom-fields/definitions?entity_type=contact',
    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/custom-fields/definitions?entity_type=contact`, {
  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/custom-fields/definitions?entity_type=contact', headers=headers)
data = response.json()
print(data)

Beispiel-Antwort

200 OK
{
    "data": [
        {
            "id": 1,
            "form_id": 1,
            "entity_type": "string",
            "field_key": "string",
            "field_label": "string",
            "field_type": "string",
            "section_key": "string",
            "field_options": "string",
            "validation_rules": "string",
            "is_required": true,
            "is_searchable": true,
            "applicant_visibility": "string",
            "is_active": true,
            "display_order": 1
        }
    ]
}
API Version v1.0