Order Intake Profile Schema
Felder
Order Intake Profile Schema
ADR 0285 — tenant-configurable rule set that turns a confirmed weclapp sales order into a native project + positions + tasks + checklists.
name
Profile name.
isDefault
Exactly one active profile per tenant is the default (used when no party override matches).
enabled
Disabled profiles never run (rollout kill-switch).
partyId
Optional customer party this profile is pinned to; null = tenant-wide.
triggerGate
Explicit confirmation flag that must hold before the automation runs, evaluated against sales_order.weclappCustomAttributes. null = status pre-filter only.
projectDefaults
Defaults applied to the created project.
titleTemplate
Handlebars-subset template for the project title.
descriptionTemplate
Handlebars-subset template for the project (and, by default, task) description.
deadlineKey
weclappCustomAttributes key whose (date) value maps to project.endDate / task.dueDate (date-only, ADR 0285 G3).
contactKey
weclappCustomAttributes key holding the customer contact as a weclapp PARTY ID (ITF: "Verantwortlicher_AuftragKunde"). Resolved to the local party so templates can render `{{party.contactName}}`; the raw attribute value is an opaque id and unusable in text. Unset / unresolvable → `{{party.contactName}}` renders empty.
orgUnitId
Dispo org unit the created project lands in (ADR 0285, Decision 7). Also the fallback when `orgUnitSource: WECLAPP_ATTRIBUTE` finds no mapping for the order.
orgUnitSource
Where project/task `orgUnitId` comes from. FIXED = always the `orgUnitId` above. WECLAPP_ATTRIBUTE = read the team from the weclapp custom attribute `orgUnitKey` and translate it via `orgUnitMapping`; an unmapped / missing value falls back to `orgUnitId`, so the automation never lands a project nowhere.
FIXEDWECLAPP_ATTRIBUTEorgUnitKey
weclappCustomAttributes key carrying the team on the order (e.g. "Team"). Only read when orgUnitSource = WECLAPP_ATTRIBUTE.
orgUnitMapping
weclapp team value → Codemeta org unit. Matching is case-insensitive on the trimmed value; the first matching entry wins. A mapping table rather than an org-unit name comparison on purpose: a renamed org unit would silently stop matching.
descriptionOnTasks
Whether to also copy the full description onto every task (matches the ITF n8n default).
teamCanManage
ADR 0421 — set task.teamCanManage on materialised tasks so every member of the assigned dispatch team may fully manage (edit/delete) them, not only work them off. Worker-created tasks have no human creator, so without this only the project manager or an admin can touch them.
writeBack
Optional narrow write-back to the weclapp sales order after materialisation. null = no write-back.
rules
Ordered match → outcome rules. The first matching rule wins per order position.
match
Match criteria against the (already-synced) article + order item. All present criteria must hold (AND). Omitted / null on the fallback rule.
position
Project-position outcome (ADR 0310) for a matched order item.
billingModel
Force the position billing model. null = derive from the order item unit (hour-like → time_and_material, fixed amount → flat_rate).
flat_ratetime_and_materialnullweclappBilling
ADR 0634 — wie die weclapp-Auftragsposition am Ende abgerechnet wird. `position` (Default) = heutiges Verhalten: die Position bleibt im Auftrag stehen (DL-Positionen werden in weclapp bebucht, Nicht-DL-Positionen bleiben als verkaufte Position bestehen). `replace` = die Position ist eine Nicht-DL-Platzhalterposition für Aufwand; beim Abrechnungsabschluss wird sie im weclapp-Auftrag durch die gerenderten Buchungspositionen ERSETZT (Auftrag kurz zurück auf „Auftrag wird erfasst"). Der Wert wird beim Materialisieren auf project_position.weclappBillingMode gestempelt und danach dort gepflegt — ein Re-Import überschreibt ihn nicht.
positionreplacelimitMode
Hard budget cap on the lead task (ADR 0139). `derive` = take the cap from the order position (hour-like unit → minutes, fixed amount → amount); `minutes` / `amount` = force that dimension; `no_cap` = explicitly no cap. `none` is DEPRECATED — it used to mean `derive` while the UI labelled it "no cap", which made an explicit "no cap" inexpressible; it is still accepted (and read as `derive`) so profiles written before the rename keep working until the migration `scripts/migrations/2026-07-30-rename-intake-limit-mode.mjs` has run.
deriveminutesamountno_capnonetask
Task outcome for a matched order item.
titleTemplate
Handlebars-subset template for the task title.
checklistTemplateId
checklist_template to attach to the position / lead task (ADR 0217).
assign
Assignment outcome (ADR 0285, Decision 7 / ADR 0224).
mode
OPEN = unassigned, dispatcher schedules via "Aufgaben planen". FIXED = pin to userId/orgUnitId. DISPATCH_RULE = set task.dispatchPending + dispatchRuleId.
OPENFIXEDDISPATCH_RULEuserId
orgUnitId
dispatchRuleId
fallbackRule
Outcome applied to order positions that match no rule (ITF service/consulting default).
Keine Felder passen zum Filter.
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/order_intake_profiles— Liste, paginiert + filterbarGET /api/v1/order_intake_profiles/<id>— Einzelne EntityPOST /api/v1/order_intake_profiles— AnlegenPATCH /api/v1/order_intake_profiles/<id>— Teil-UpdateDELETE /api/v1/order_intake_profiles/<id>— Soft-DeleteGET /api/v1/order_intake_profiles/<id>/timeline— Audit + Aktivitäten