API · v1 · stabil
CODEMETA OSDeveloper Center
Konsole öffnen
Entity · tickets

Ticket Schema

Schema-ID
ticket
Collection
tickets
Permissions
  • Lesenticket_view
  • Anlegenticket_create
  • Ändernticket_edit
  • Löschenticket_delete

Felder

Ticket Schema

tickets4 Permissions

Schema for validating ticket entities

titlestringerforderlich

The ticket title

1–500 Zeichen
descriptionstringoptional

Detailed ticket description

nullable
descriptionHtmlstringoptional

Rich text HTML version of the ticket description

nullable
aiSummarystringoptional

Best-effort AI summary of the imported ticket content (external-master mirrors, e.g. TANSS — their description holds the raw source mail). Written only by the worker (queue-ai-summary), null when AI is disabled for the tenant. Distinct from dispatch.aiSummary, which is an internal metadata field of the auto-dispatch pipeline and is not rendered.

read-onlynullable
aiSummaryAttemptedAtdatetimeoptional

Set by the worker whenever an AI summary was attempted — even when the LLM returned nothing (AI off, content too short). Prevents the lazy on-open trigger from re-enqueuing the same ticket on every load.

read-onlynullable
statusstringerforderlich

Current ticket status

prioritystringerforderlich

Ticket priority level

LOWNORMALHIGHCRITICAL
partyIduuidoptional

Associated party UUID

nullable
partyAddressIduuidoptional

Specific site/address of the associated party

Default: nullnullable
contactPartyIduuidoptional

Associated contact person UUID

nullable
assignedToIduuidoptional

Assigned user UUID

nullable
dispatcherIduuidoptional

Human dispatcher responsible for this ticket (ADR 0260): the person who manually created/dispatched it or confirmed/overrode the AI dispatch. Null for pure AI auto-dispatch (no human dispatcher). Server-managed — drives the per-dispatcher Rückfragen-KPI (Dispo-Zielvereinbarung).

nullable
orgUnitIduuidoptional

Associated org unit UUID

nullable
handlingTierstringoptional

Current ownership tier: CUSTOMER (customer IT) or MSP. null/absent means MSP (legacy).

CUSTOMERMSPnull
read-onlynullable
handedToCustomerAtdatetimeoptional

When the ticket was last handed to CUSTOMER (SLA pause start). Server-managed.

read-onlynullable
slaPausedMsnumberoptional

Accumulated milliseconds the SLA clock was paused while the ticket sat at CUSTOMER. Server-managed.

read-onlynullable
handoverPreviousAssigneeIdstringoptional

Assignee parked while the ticket sits at CUSTOMER; restored on hand-back. Server-managed.

read-onlynullable
contractIduuidoptional

Associated contract UUID

nullable
projectIduuidoptional

Associated project UUID

nullable
salesOrderIduuidoptional

Linked sales_order UUID (the order this ticket originated from)

read-onlynullable
salesOrderItemIdstringoptional

ID of the orderItem inside the linked sales_order (matches salesOrder.orderItems[].id)

read-onlynullable
salesOrderItemSourcestringoptional

Origin of the linked sales-order item — internal or weclapp

internalweclappnull
read-onlynullable
dueAtdatetimeoptional

Due date in ISO format

nullable
resolvedAtdatetimeoptional

Resolution date in ISO format

nullable
closedAtdatetimeoptional

Closure date in ISO format

nullable
statusChangedAtdatetimeoptional

Timestamp of the last status change (denormalized for time limit queries)

nullable
reopenedAtdatetimeoptional

Timestamp of the last reopen event (system or manual). Cleared on next non-reopen status change.

nullable
reopenedBystringoptional

User UUID of the actor who reopened the ticket, or one of the sentinel strings "system:auto_close_undo", "system:inbound_mail_ai", "system:inbound_mail_closed" for system-triggered reopens.

nullable
reopenReasonstringoptional

Why the ticket was reopened — drives UI banners and audit.

MANUALINBOUND_MAIL_AIINBOUND_MAIL_CLOSEDAUTO_CLOSE_UNDOnull
nullable
reopenedFromStatusstringoptional

The status the ticket was in immediately before being reopened.

nullable
aiReopenDecisionstringoptional

Einstufung des Klassifikators, die zur Wiedereröffnung geführt hat.

thanksreopenunclearnull
read-onlynullable
aiReopenConfidencenumberoptional

Konfidenz (0…1) der Einstufung zum Zeitpunkt der Wiedereröffnung.

0 – 1read-onlynullable
aiReopenBasisstringoptional

Woraus sich die Wiedereröffnung ergab: Schwellwert erreicht ("threshold"), Tenant-Fallback bei Unsicherheit ("fallback") oder von einem Menschen bestätigt ("confirmed").

thresholdfallbackconfirmednull
read-onlynullable
aiReopenConfirmedBystringoptional

User-UUID der Person, die die unsichere KI-Einstufung bestätigt hat (nur bei aiReopenBasis "confirmed").

read-onlynullable
aiReopenSuggestionobjectoptional

Zustand der manuellen Bestätigung einer unsicheren KI-Einstufung.

read-onlynullable
statusstringerforderlich

PENDING blockiert Auto-Close; alle anderen Werte sind Endzustände. Genau ein PENDING pro Ticket (neuere Mail aktualisiert das bestehende).

PENDINGCONFIRMEDDISMISSEDEXPIRED
decisionstringoptional
thanksreopenunclear
nullable
confidencenumberoptional
0 – 1nullable
reasoningstringoptional
nullable
modelNamestringoptional
nullable
emailMessageIdstringoptional
nullable
messageIdstringoptional
nullable
suggestedAtdatetimeoptional
nullable
expiresAtdatetimeoptional
nullable
taskIdstringoptional
nullable
decidedAtdatetimeoptional
nullable
decidedBystringoptional
nullable
tagsstring[]optional

Ticket tags

Default: []nullable
billingOverrideobjectoptional

ADR 0146 — explicit permission to invoice time bookings for this ticket while it is still open (e.g. customer ghosted). When `allowedWhileOpen` is true the billing-guard treats the ticket as billable. The reason is internal and propagates into the Leistungsnachweis snapshot, not onto the customer invoice.

Default: nullnullable
allowedWhileOpenbooleanerforderlich
Default: false
reasonstringoptional
max 1000 Zeichennullable
allowedByuuidoptional
nullable
allowedAtdatetimeoptional
nullable
standaloneBillingobjectoptional

ADR 0274 — mark this ticket for STANDALONE billing: its billable time is carved out of the customer collective Leistungsnachweis (and, if the ticket belongs to a project, out of the project LN too) and billed on its own via POST /tickets/:id/generate-performance-record. `enabledBy`/`enabledAt` and the `performanceRecord*`/`invoicedAt` back-references are set server-side only. Set via PUT /tickets/:id/standalone-billing (permission `ticket_billing_override`).

Default: nullnullable
enabledbooleanerforderlich
Default: false
reasonstringoptional
max 1000 Zeichennullable
enabledByuuidoptional
read-onlynullable
enabledAtdatetimeoptional
read-onlynullable
performanceRecordIduuidoptional
read-onlynullable
performanceRecordNumberstringoptional
read-onlynullable
invoicedAtdatetimeoptional
read-onlynullable
difficultyintegeroptional

Ticket difficulty (0–100). Feeds the XP award formula on close. Defaults to 50 at award time if null.

0 – 100nullable
requiredSkillsobject[]optional

Structured skill requirements for dispatch matching

Default: []nullable
skillIduuiderforderlich

UUID of the skill_definition

minimumLevelstringoptional

Minimum proficiency level required. Null = any level.

BEGINNERINTERMEDIATEADVANCEDEXPERTnull
nullable
sourcestringoptional

How this skill requirement was added. ASSET_DERIVED = auto-derived from the customer's assets (CMDB) via skill assetMatchRules.

MANUALAI_DETECTEDASSET_DERIVED
Default: "MANUAL"
detectedLanguagestringoptional

Automatically detected language of the ticket content (ISO 639-1, via fastText lid.176)

aaabaeafakamanarasavayazbabebgbhbibmbnbo
nullable
detectedLanguageConfidencenumberoptional

Detection confidence (0..1). Used with LANGUAGE_DETECTION_CONFIDENCE_THRESHOLD

0 – 1nullable
detectedLanguageAtdatetimeoptional

Timestamp of the last language detection run

nullable
attachmentsobject[]optional
Default: []nullable
s3Keystringerforderlich
fileNamestringerforderlich
mimeTypestringerforderlich
sizeBytesnumbererforderlich
≥ 0
uploadedAtdatetimeerforderlich
uploadedByuuiderforderlich
isInternalbooleanerforderlich
linkedEntitiesobject[]optional
Default: []nullable
entityTypestringerforderlich
partyassetticketcontractprojectuseropportunity
entityIduuiderforderlich
rolestringerforderlich
convertedToobjectoptional

Set when this ticket was converted to another entity (opportunity/complaint). The ticket is kept — not deleted — so linked records (time records, tasks, callbacks) stay reachable and billable. Written only by the conversion routes.

read-onlynullable
entityTypestringerforderlich
ticketopportunitycomplaint
entityIduuiderforderlich
convertedAtdatetimeoptional
nullable
convertedBystringoptional
nullable
convertedFromobjectoptional

Set when this ticket was created by converting another entity (opportunity/complaint). Written only by the conversion routes.

read-onlynullable
entityTypestringerforderlich
ticketopportunitycomplaint
entityIduuiderforderlich
convertedAtdatetimeoptional
nullable
convertedBystringoptional
nullable
contractPositionRefobjectoptional

Reference to a contract position this ticket relates to

nullable
contractIdstringoptional
positionUuidstringoptional
positionTitlestringoptional
nullable
contactPartyNamestringoptional

Contact person name (used when contactPartyId is not available)

nullable
contactChannelstringoptional

Channel through which the ticket was reported

PHONEEMAILPORTALON_SITEREMOTETEAMSOTHER
nullable
ticketTypestringoptional

Ticket type — references the `key` of a ticket_type entity (e.g. INCIDENT, REPAIR). Configurable per tenant; no longer a fixed enum.

max 40 Zeichennullable
extTicketIdstringoptional

External ticket reference ID

nullable
estimatedMinutesintegeroptional

Estimated work time in minutes

≥ 0nullable
respondedAtdatetimeoptional

Timestamp of the first agent response (drives time_to_first_response targets, ADR 0117a)

nullable
inboundReplyAckedAtdatetimeoptional

Timestamp at which the latest inbound customer email was acknowledged as "handled, no reply needed". Clears the awaiting-reply badge when >= the last inbound email time; a newer inbound email re-arms the badge.

nullable
inboundReplyAckedBystringoptional

User who acknowledged the latest inbound customer email (see inboundReplyAckedAt).

nullable
targetsobject[]optional

Denormalized active service targets (ADR 0117a)

nullable
stageIdstringerforderlich
stageKindstringerforderlich
time_to_first_responsetime_in_statustime_to_statustime_to_close
stageStatusstringoptional
nullable
stageLabelstringoptional
nullable
bindingnessstringerforderlich
contractualinternal
deadlinedatetimeerforderlich
breachedAtdatetimeoptional
nullable
completedAtdatetimeoptional
nullable
profileIduuiderforderlich
mergedIntoTicketIduuidoptional

If set, this ticket was merged into the referenced ticket

nullable
mergedIntoTicketNumberstringoptional

Ticket number of the ticket this was merged into (denormalized for display)

nullable
linkedRiskIdsstring[]optional

Linked risk IDs

Default: []
incidentDataobjectoptional
nullable
incidentTypestringoptional
DATA_BREACHUNAUTHORIZED_ACCESSMALWAREPHISHINGDOSINSIDER_THREATSUPPLY_CHAINOTHER
severitystringoptional
CRITICALHIGHMEDIUMLOW
detectedAtdatetimeoptional
nullable
containedAtdatetimeoptional
nullable
resolvedAtdatetimeoptional
nullable
affectedDataCategoriesstring[]optional
Default: []
affectedPersonCountnumberoptional
nullable
rootCausestringoptional
nullable
lessonsLearnedstringoptional
nullable
timelineobject[]optional
Default: []
timestampdatetimeerforderlich
actionstringerforderlich
userIdstringerforderlich
descriptionstringerforderlich
linkedAssetIdsstring[]optional
Default: []
linkedRiskIdsstring[]optional
Default: []
breachNotificationsobject[]optional
Default: []
notificationTypestringerforderlich
DSGVO_ART33_AUTHORITYDSGVO_ART34_DATA_SUBJECTSNIS2_EARLY_WARNINGNIS2_NOTIFICATIONNIS2_FINAL_REPORTBSI_NOTIFICATION
statusstringerforderlich
DRAFTPENDING_REVIEWSUBMITTEDACKNOWLEDGED
recipientDetailsstringerforderlich
dueAtdatetimeerforderlich
submittedAtdatetimeoptional
nullable
contentMarkdownstringerforderlich
dmsDocumentIdstringoptional
nullable
budgetobjectoptional

Budget control: billing type, caps, consumed time, and lock state

nullable
billingTypestringoptional

Ticket billing model

TIME_AND_MATERIALFIXED_PRICENOT_BILLABLE
Default: "TIME_AND_MATERIAL"
fixedPriceAmountstringoptional

Fixed price amount in EUR (when billingType is FIXED_PRICE)

Patternnullable
capMinutesintegeroptional

Hard budget cap in minutes. When reached, ticket is locked.

≥ 0nullable
capDisplayUnitstringoptional

How the cap was originally entered (MINUTES, HOURS or EUR). capMinutes stays the canonical value; this field lets the UI round-trip the input without precision loss.

MINUTESHOURSEUR
nullable
capDisplayValuestringoptional

Original cap value as entered, matched to capDisplayUnit. Stored as a decimal string to avoid float rounding (e.g. "2.5" hours or "199.99" EUR).

Patternnullable
capHourlyRateEurstringoptional

Hourly rate (EUR/h) used to convert capDisplayValue to capMinutes when capDisplayUnit=EUR. Frozen at the moment the cap was set so later rate changes do not silently re-interpret the cap.

Patternnullable
consumedMinutesintegeroptional

Denormalized sum of all time record durationMinutes for this ticket

≥ 0Default: 0read-only
lockedbooleanoptional

Whether the ticket is budget-locked (cap reached)

Default: falseread-only
lockedAtdatetimeoptional

When the budget lock was engaged

read-onlynullable
lockedReasonstringoptional

Reason the budget was locked (auto or manual)

max 500 Zeichenread-onlynullable
unlockRequestIduuidoptional

Pending approval request ID for budget unlock

read-onlynullable
lockStatusKeystringoptional

ADR 0223 — resolved at create from the ticket type / tenant default: the status the ticket is auto-transitioned into when the cap is reached. Null = no auto status change (only budget.locked is set).

max 100 Zeichennullable
capHistoryobject[]optional

History of budget cap changes

Default: []read-only
previousCapintegererforderlich
nullable
newCapintegererforderlich
changedAtdatetimeerforderlich
changedByuuiderforderlich
approvalRequestIdstringoptional
nullable
reasonstringoptional
nullable
dispatchobjectoptional

Auto-dispatch metadata set by the AI dispatch pipeline

read-onlynullable
dispatchDecisionIduuidoptional
nullable
dispatchedAtdatetimeoptional
nullable
dispatchStatusstringoptional
PENDINGDISPATCHEDSUGGESTEDMANUAL_OVERRIDEFAILED
nullable
aiSummarystringoptional
read-onlynullable
aiCategorystringoptional
nullable
aiEstimatedMinutesintegeroptional
≥ 0nullable
aiConfidencenumberoptional
0 – 1nullable
sourcestringoptional

Herkunftsmarker (EMAIL, M365_OUTLOOK, TANSS, …). Zwei Bedeutungen, die zusammenfallen: WOHER der Datensatz kam und — falls der Wert einem `externalMaster`-Provider entspricht — WER ihn führt. Ein Ticket mit `source: "TANSS"` ist ein read-only Spiegel (ADR 0377): Bearbeitungsversuche scheitern mit 423, gepflegt wird es ausschließlich vom Sync. Der Guard wirkt PRO DOKUMENT — in Codemeta angelegte Tickets tragen kein `source` und bleiben uneingeschränkt bearbeitbar, obwohl sie in derselben Collection liegen. Die Sperre lässt sich pro Ticket aufheben, ohne die Herkunft zu verfälschen: `externalOwnership: "LOCAL"` (ADR 0432) übernimmt den Vorgang nach Codemeta — `source` bleibt dann als Herkunftsangabe stehen, führt aber nicht mehr. Vorher wurde das Feld bereits ad hoc geschrieben (EMAIL/M365_OUTLOOK), war aber nie deklariert — bei `additionalProperties: false` konnte es über validierte Pfade nicht gesetzt werden.

max 50 ZeichenDefault: nullnullable
externalOwnershipstringoptional

Übernahme eines Fremdsystem-Spiegels in die lokale Verantwortung (ADR 0432). `"LOCAL"` hebt die read-only-Sperre aus ADR 0377 auf: das Ticket bleibt formal ein TANSS-Ticket (`source`/`sourceRef` bleiben erhalten, der Deeplink funktioniert weiter), wird aber ab jetzt in Codemeta zu Ende bearbeitet und vom TANSS-Sync nicht mehr angefasst. In TANSS trägt der Vorgang dann den Tag "CodemetaOS". Fehlt das Feld (Altbestand), gilt der Datensatz weiter als Spiegel — kein Backfill nötig. Nur über POST /tickets/:id/takeover setzbar (in `protectedFields`), niemals per generischem PATCH.

LOCALnull
Default: nullread-onlynullable
externalOwnershipTakenAtdatetimeoptional

Zeitpunkt der Übernahme (ADR 0432).

Default: nullread-onlynullable
externalOwnershipTakenBystringoptional

Interne User-Id, die die Übernahme ausgelöst hat (ADR 0432).

Default: nullread-onlynullable
externalOwnershipTagstringoptional

Name des Tags, der bei der Übernahme im Fremdsystem gesetzt wurde (ADR 0432). Belegt, dass die Gegenseite markiert ist — die Übernahme wird nur bei Erfolg vollzogen. `null` BEI GESETZTEM `externalOwnership: "LOCAL"` ist die eine dokumentierte Ausnahme (ADR 0457): der Vorgang existierte im Fremdsystem nicht mehr, konnte deshalb nicht markiert werden, und die Übernahme wurde nach ausdrücklicher Bestätigung trotzdem vollzogen. Bei fehlendem `externalOwnership` heißt `null` schlicht „nie übernommen".

Default: nullread-onlynullable
sourceUrlstringoptional

Direktverweis auf den Datensatz in der Oberfläche des führenden Fremdsystems (ADR 0362/0377). Wird beim Spiegeln einmal mitgeschrieben, weil der Host nur in `integration_configs` steht — Daten, die die Ticketseite nicht lädt und ein Techniker nicht zwingend lesen darf. Fehlt das Feld (ältere Spiegel), zeigt die Oberfläche schlicht keinen Link — kein Backfill nötig.

Default: nullnullable
sourceRefobjectoptional

Reference to the source system this entity was imported from

Default: nullnullable
systemstringerforderlich

Source system identifier (e.g. tanss, weclapp)

idstringerforderlich

Entity ID in the source system

satisfactionobjectoptional

Customer satisfaction rating for this ticket, populated from survey responses

Default: nullnullable
scorenumbererforderlich

Raw score value (1-5 for CSAT, 0-10 for NPS)

scoreTypestringerforderlich

Type of satisfaction score

CSATNPS
normalizedScorenumberoptional

Score normalized to 0-100 scale for aggregation

0 – 100nullable
commentstringoptional

Optional free-text comment from the respondent

max 4000 Zeichennullable
responseIduuiderforderlich

UUID of the linked survey_response

invitationIduuidoptional

UUID of the survey_invitation that produced this response

nullable
surveyIduuidoptional

UUID of the survey used

nullable
submittedAtdatetimeerforderlich

When the response was submitted

respondentContactIduuidoptional

Contact person UUID who submitted the response

nullable
skillImpactobject[]optional

Audit of skill level deltas applied to the assignee from this response

Default: []nullable
skillIduuiderforderlich
deltaintegererforderlich
-101
sourcestringoptional

Which mapping produced this impact

required_skillssurvey_question
appliedToUserIduuidoptional
nullable
suitableForInternbooleanoptional

Whether this ticket is appropriate for an intern/junior to work on (auto-set when difficulty < 30; manual override possible)

nullable
parentIncidentIduuidoptional

Parent major incident this ticket is grouped under

nullable
snoozedUntildatetimeoptional

Ticket is snoozed until this timestamp; hidden from active queues

nullable
snoozedByuuidoptional

User who snoozed the ticket

nullable
snoozedAtdatetimeoptional

When the ticket was snoozed

nullable
snoozeReasonstringoptional

Reason provided when snoozing

max 500 Zeichennullable
suggestedTemplateIdsuuid[]optional

Top-N task_template IDs suggested by the dispatcher (ADR 0138 Hook A). Server-managed via /suggest-templates endpoint.

Default: []nullable
appliedTemplateIdsuuid[]optional

task_template IDs that have been applied to this ticket (used by skill-aware dispatch in Hook B).

Default: []nullable
suggestionsComputedAtdatetimeoptional

When the template suggestion pipeline last ran for this ticket.

nullable

Standard-Endpoints

Diese Resource folgt dem generischen CRUD-Vertrag der Plattform. Lesen Sie die Konventionen für Pagination, Idempotenz, Optimistic Locking und Audit. Die wichtigsten Endpoints:

  • GET /api/v1/tickets — Liste, paginiert + filterbar
  • GET /api/v1/tickets/<id> — Einzelne Entity
  • POST /api/v1/tickets — Anlegen
  • PATCH /api/v1/tickets/<id> — Teil-Update
  • DELETE /api/v1/tickets/<id> — Soft-Delete
  • GET /api/v1/tickets/<id>/timeline — Audit + Aktivitäten

Suche