Ops Lab Playbook: Lifecycle Messaging + Retargeting
Last updated: 2026-03-08
1. Purpose and when to use this
Use this module to run chain signal/decision workflows and validate webhook delivery for lifecycle messaging.
2. User roles and auth modes
NONE: chain signal, resolve, and prefetch endpoints.[Operator]JWT: webhook create/test actions.[Platform Admin]allowlist operations moved to Playbooks escalation boundaries.
3. Prerequisites checklist
- Primer completed: Onboarding and API Primer
HANDLE,JWT_TOKENavailable- Valid webhook test endpoint URL
4. UI onboarding flow
- Open
https://app.10x.in/apps/lifecycle-messaging. - Append sample chain signals for a session.
- Resolve and prefetch decisions for one or more triggers.
- Create webhook subscription and run test delivery.
5. API workflow map
LM-01:POST /v2/public/chain/signals(public)LM-02:POST /v2/public/chain/resolve(public)LM-03:POST /v2/public/chain/prefetch(public)LM-04: role-negative check for webhook mutationLM-05:POST /v2/handles/{handle}/webhooks(JWT operator)LM-06:POST /v2/handles/{handle}/webhooks/{subscriptionId}/test(JWT operator)
6. cURL examples
Set module variables:
export SESSION_ID="sess-1"
export SUBSCRIPTION_ID=""
LM-01 Append chain signals
curl -sS -X POST "${API_BASE}/v2/public/chain/signals" \
-H 'content-type: application/json' \
-d '{"handle":"'"${HANDLE}"'","sessionId":"'"${SESSION_ID}"'","signals":[{"type":"view"}]}'
LM-02 Resolve chain decision
curl -sS -X POST "${API_BASE}/v2/public/chain/resolve" \
-H 'content-type: application/json' \
-d '{"handle":"'"${HANDLE}"'","sessionId":"'"${SESSION_ID}"'","trigger":"checkout"}'
LM-05 Create webhook subscription
curl -sS -X POST "${API_BASE}/v2/handles/${HANDLE}/webhooks" \
-H "authorization: Bearer ${JWT_TOKEN}" \
-H 'content-type: application/json' \
-d '{"endpointUrl":"https://hooks.example.com/test","eventTypes":["link.clicked"]}'
LM-06 Test webhook delivery
curl -sS -X POST "${API_BASE}/v2/handles/${HANDLE}/webhooks/${SUBSCRIPTION_ID}/test" \
-H "authorization: Bearer ${JWT_TOKEN}" \
-H 'content-type: application/json' \
-d '{}'
7. Expected success outputs and verification checks
- Chain append returns accepted metadata (
202). - Resolve/prefetch returns decision envelopes (
200). - Webhook create returns
201withsubscriptionId. - Webhook test returns
202and dispatch event reference.
8. Failure modes and remediation
403 insufficient_roleon webhook create:- Remediation: use operator-level JWT for webhook mutations.
400on chain requests:- Remediation: verify required fields (
handle,sessionId, trigger/signals). - Webhook test accepted but no receiver event:
- Remediation: validate endpoint reachability and inspect delivery logs/retries.
9. Async behavior notes
- Chain signal writes can enqueue asynchronous processing work.
- Webhook test dispatches asynchronously via background processing.
10. Related links
- Playbooks escalation boundaries (
[Platform Admin]webhook allowlist) - Personalization + Campaign Studio
- Domain Commerce + Trust