本文へ移動
cccskills
無料GitHub で公開

order-lifecycle

Design the order lifecycle — order state machine, fulfillment workflow, returns/RMA, refunds, cancellations, and order events/webhooks. Platform-agnostic state and event modeling. Triggers: designing order states, modeling returns/refunds, defining order events.

日本語の概要は準備中です。原文の説明を表示しています。

SebastianLuser/claude-code-arcaneスター 3(GitHub 3 + cccskills 0)

実行スコア 未検証

インストール方法を見る

含まれるファイル(2)

  • SKILL.md3.7 KB
  • references/order-state-machine.md2.6 KB

SKILL.md(原文)

インストールする前に、エージェントに与えられる指示の中身を確認できます。

Order Lifecycle

An order is a long-lived state machine touched by payments, inventory, shipping, and support. Model its states, transitions, and events explicitly so nothing silently gets stuck — independent of platform.

Note: This skill may create or modify files in your project (a state-machine spec). It will ask before writing.

Before Starting

Gather: fulfillment model (single vs split/partial shipments), payment capture timing (auth-then-capture vs immediate), returns policy, and goal (design the full lifecycle, define the state machine, or model returns/refunds).

How This Skill Works

ModeTriggerOutput
DesigndesignEnd-to-end lifecycle + events
StatesstatesFormal state machine: states, transitions, guards
ReturnsreturnsRMA + refund flow and states

Phase 1 — The State Machine

Separate order status from payment status and fulfillment status — collapsing them into one field is the most common modeling mistake.

DimensionStates
Orderpending → confirmed → in_progress → completed / cancelled
Paymentpending → authorized → paid → partially_refunded → refunded / failed
Fulfillmentunfulfilled → partially_fulfilled → fulfilled → returned

Each transition has a guard (e.g. cannot fulfill before payment authorized) and emits an event.

For the full transition table, guards, and partial-shipment handling, see references/order-state-machine.md.


Phase 2 — Events & Webhooks

Every transition emits a durable, ordered event: order.created, order.paid, order.fulfilled, order.cancelled, order.refunded, return.requested, return.received.

  • Events are append-only — never mutate history; the current state is a projection.
  • Outbound webhooks must be idempotent and retried with signatures (hand off to payments-architecture for the reliability pattern).
  • Carry an idempotency key from order placement through fulfillment.

Phase 3 — Returns & Refunds

Flow: return.requested → approved → label_sent → in_transit → received → inspected → refunded/rejected.

ConcernRule
RestockOnly on received + inspected pass, back to available
RefundFull / partial / store-credit; never exceed captured amount
WindowEnforce return-window guard at request time
PartialPer line-item, not whole-order, for split fulfillment

Output Artifacts

RequestOutput
DesignLifecycle diagram + event catalog
StatesState/transition/guard table (the spec)
ReturnsRMA flow + refund rules

A lifecycle design is COMPLETE when order/payment/fulfillment statuses are independent, every transition has a guard and an event, and refunds/restocks are gated on inspection.


Related Skills

  • payments-architecture: capture/refund and webhook reliability for order events.
  • inventory-stock: reservations released and stock decremented per fulfillment.
  • cart-checkout: hands the placed order into this lifecycle.
  • commerce-analytics: order events feed funnel and revenue metrics.

レビュー

まだレビューはありません。使ってみた感想をお寄せください。

コメント

ログインなしで書き込めます。使ってみた感想、質問、動かなかった環境などを気軽にどうぞ。

まだコメントはありません。最初のコメントを書いてみませんか。

送信するとすぐに公開されます。メールアドレスや電話番号などの個人情報は書かないでください。URL は 2 つまでです。

0 / 1000 文字

このフォームは reCAPTCHA で保護されており、Google のプライバシーポリシーと利用規約が適用されます。

同じリポジトリのスキル

Plan, design, and implement A/B tests and experiments with statistical rigor. Covers hypothesis frameworks, sample sizing, metrics, and result analysis.

日本語の概要は準備中です。原文の説明を表示しています。

SebastianLuser/claude-code-arcane32026年10月27日 更新

Web/mobile accessibility decision guide: WCAG 2.2 AA, ARIA, keyboard nav, focus management, contrast, testing. Use for: a11y, accessibility, wcag, aria, screen reader, keyboard, contrast.

日本語の概要は準備中です。原文の説明を表示しています。

SebastianLuser/claude-code-arcane32026年10月27日 更新

Generate, iterate, and scale ad creative for paid advertising across Google, Meta, LinkedIn, and X. Covers platform specs, creative frameworks, and quality validation.

日本語の概要は準備中です。原文の説明を表示しています。

SebastianLuser/claude-code-arcane32026年10月27日 更新

Musica interactiva para juegos: layering vertical, re-secuenciacion horizontal, stingers, reglas de transicion con sync points, y mapeo de estados de gameplay a musica. Usar para: musica adaptativa, sistema de musica dinamica, transiciones musicales, combat music.

日本語の概要は準備中です。原文の説明を表示しています。

SebastianLuser/claude-code-arcane32026年10月27日 更新

Design multi-agent systems, create agent architectures, define communication patterns, and build autonomous agent workflows with structured evaluation frameworks.

日本語の概要は準備中です。原文の説明を表示しています。

SebastianLuser/claude-code-arcane32026年10月27日 更新

Inter-agent communication protocol for C-suite agent teams. Defines invocation syntax, loop prevention, isolation rules, response formats, and quality loops.

日本語の概要は準備中です。原文の説明を表示しています。

SebastianLuser/claude-code-arcane32026年10月27日 更新

SebastianLuser のスキルをすべて見る

このスキルの問題を報告する