API · v1 · stabil
CODEMETA OSDeveloper Center
Konsole öffnen

Create timer

POST/v1/timers

Create a new timer in the active tenant.

Datenmodell

Diese Operation arbeitet auf der Entität Timer (timer). Alle 12 Felder — Typ, Validierung, Pflichtangabe, Beziehungen — stehen in der Schema-Referenz.

  • Pflichtfelder: userId, title, startedAt, accumulatedSeconds, isRunning
  • Server-verwaltet: _id, schema, schemaVersion, tenantId, version, createdAt, updatedAt, createdBy, updatedBy, deletedAt, deletedBy — diese Felder vergibt die Plattform; im Request werden sie verworfen.

Request Body

NameTypBeschreibung
ticketIdstring
projectIdstring
partyIdstring
taskIdstring
titleerforderlichstring
notesstring

Beispiel

curl -X POST https://api.codemeta-os.de/v1/timers \
  -H "X-Tenant-Id: $TENANT" \
  -H "Content-Type: application/json" \
  -b cookies.txt \
  -d '{
  "ticketId": "string",
  "projectId": "string",
  "partyId": "string",
  "taskId": "string",
  "title": "string",
  "notes": "string"
}'
const result = await cm.timers.post({
  "ticketId": "string",
  "projectId": "string",
  "partyId": "string",
  "taskId": "string",
  "title": "string",
  "notes": "string"
});

Antwortcodes

HTTP Bedeutung
201 Default Response

Suche