Giao diện
API · recurring-skip
Trang sinh tự động
Parse từ schema.graphql (SDL backend export) bằng parser graphql. Mô tả và quyền lấy nguyên văn từ description trong SDL.
1 query · 2 mutation.
Query
cycleSchedule
Schedule, immutable n/cutoff snapshot and skip state of an own Recurring order. Requires order.read (U-01, OWN).
query · quyền: order.read
| Tham số | Kiểu | Mặc định | Mô tả |
|---|---|---|---|
orderId | ID! |
Trả về CycleSchedule!
| Field | Kiểu | Mô tả |
|---|---|---|
orderId | ID! | |
orderVersion | Int! | |
orderState | OrderState! | |
campaignId | ID! | |
termCycles | Int! | |
serverTime | DateTime! | Server clock the cutoffs are evaluated against. |
skipLeadDays | Int | U28-P2-04 (DEC-U28-02). x_eff in days: skipCutoffAt = 00:00 Asia/Ho_Chi_Minh of (first day of the window - x_eff), x_eff = greatest(ordering.recurring_skip_lead_days, ordering.cycle_due_lead_days). Null when ordering.recurring_skip_lead_days is not set (owner 22 rule: 00:00 of the first day minus the cycle-due lead). PAF (DEC-PAF-05, BR-MD-10): superseded, a cycle can be skipped until it has a shipment; always 0. |
skipsUsed | Int! | Skips counted against maxCount: ACTIVE skip requests plus the periods left empty when ordering (G6-Q2), each period once. |
failedDeliveryCount | Int! | #479 A: cycles cancelled for a failed delivery. Not skips, but skipsUsed + failedDeliveryCount is what maxCount limits. |
skipPolicy | SkipPolicySnapshot! | |
cycles | [ScheduleCycle!]! |
Mutation
cancelCycleSkip
U28-P2-04 (DEC-U28-02): a confirmed skip cannot be undone, every call is conflict skip_irreversible (nothing written; the ACTIVE skips already recorded stay). Kept for compatibility. Requires order.request_skip (SKP-01, OWN).
mutation · quyền: order.request_skip
| Tham số | Kiểu | Mặc định | Mô tả |
|---|---|---|---|
input | CancelCycleSkipInput! |
Trả về CycleSkipResult!
| Field | Kiểu | Mô tả |
|---|---|---|
aggregateId | ID! | The skip request id. |
version | Int! | |
status | CommandStatus! | |
requestId | ID! | |
correlationId | ID! | |
nextAction | NextAction | |
skipRequestId | ID! | |
orderId | ID! | |
cycleNo | Int! | |
skipStatus | SkipRequestStatus! | |
changed | Boolean! | False when an active skip of the period already existed (counted once). |
requestedAt | DateTime! | |
decidedAt | DateTime | |
cancelledAt | DateTime | |
cutoffAt | DateTime! | |
maxCount | Int! | |
countAfter | Int! | |
countsAsDelivery | Boolean! | Always false: a skip is never a delivery and never cancels the commitment. |
requestCycleSkip
Skips one cycle of an own LOCKED Recurring order while the cycle has no shipment (cycle_in_shipment after; PAF DEC-PAF-05: no time lock, cutoff_passed no longer returned). Past the package n: conflict limit_reached, nothing written (owner 22/10, D13). U28-P2-04 (DEC-U28-03): a cycle empty after the MOQ is conflict cycle_empty, no skip counted. Requires order.request_skip (SKP-01, OWN).
mutation · quyền: order.request_skip
| Tham số | Kiểu | Mặc định | Mô tả |
|---|---|---|---|
input | RequestCycleSkipInput! |
Trả về CycleSkipResult!
| Field | Kiểu | Mô tả |
|---|---|---|
aggregateId | ID! | The skip request id. |
version | Int! | |
status | CommandStatus! | |
requestId | ID! | |
correlationId | ID! | |
nextAction | NextAction | |
skipRequestId | ID! | |
orderId | ID! | |
cycleNo | Int! | |
skipStatus | SkipRequestStatus! | |
changed | Boolean! | False when an active skip of the period already existed (counted once). |
requestedAt | DateTime! | |
decidedAt | DateTime | |
cancelledAt | DateTime | |
cutoffAt | DateTime! | |
maxCount | Int! | |
countAfter | Int! | |
countsAsDelivery | Boolean! | Always false: a skip is never a delivery and never cancels the commitment. |