Skip to content
Help Center Guide · Workflows & Automation
2 min readVerified 2026-11-16

Workflow Configuration

Configure Wallet Experience automation triggers and template switch/bundle rules inside your Passinstance workspace.

In This Guide

Overview

Passinstance provides two complementary automation engines inside the Dashboard (/workflows, /automations, and /settings/workspace/integrations):

  1. 1
    Workflow Engine (Workflow Engine API at /api/v1/workflows): Event-driven DAG state machines backed by workflow trigger type (29 trigger types), workflow action type (25 action types), IF_CONDITION, and DELAY.
  2. 2
    Universal Automations (Automations API at /api/v1/automations): Policy-driven e-commerce and PassFlow rules supporting ExistingCardPolicy (REUSE_AND_UPDATE, ISSUE_ADDITIONAL, REPLACE, NO_OP, etc.) and ConflictResolutionPolicy (ALLOW_ALL, RUN_ALL, HIGHEST_PRIORITY, BEST_OFFER, FIRST_MATCH, EXCLUSIVE, EXCLUSIVE_BY_SCOPE).

Prerequisites: Creating or modifying workflows via POST /api/v1/workflows requires edit-template permissions (templates:manage) and at least one published Pass Template. Newly created workflows start in DRAFT or INACTIVE until activated via POST /api/v1/workflows/:workflowId/activate.

Workflow Execution Pipeline

SYSTEM ARCHITECTURE FLOW
INTERACTIVE ARCHITECTURE
EVENT-DRIVEN WORKFLOW ENGINE & PROCESSOR
PARTICIPATING SYSTEM ACTORS
P1 Domain Event Bus / Cron
P2 Workflow Engine API & Matcher
P3 Workflow Execution Engine (Bull Queue)
STEP 1 REQUEST / ACTION Emit Trigger Event
STEP 2 REQUEST / ACTION Match Active Workflows
›
TIER_CHANGED, PASS_SCANNED)
›
(status: ACTIVE, filters)
STEP 3 REQUEST / ACTION Enqueue Execution Job
STEP 4 REQUEST / ACTION Evaluate conditions
›
& IF_CONDITION actions
STEP 5 REQUEST / ACTION Execute ordered actions[]
›
(DELAY, SEND_PUSH_NOTIFICATION,
›
SWITCH_WALLET_EXPERIENCE)

Managing Workflows via REST (Workflow Engine API)

MethodEndpointDescription
GET/api/v1/workflowsLists workspace workflows (filterable by status in workflow status: DRAFT, ACTIVE, PAUSED, INACTIVE, ARCHIVED, ERROR).
POST/api/v1/workflowsCreates a new workflow using request payload (name, trigger, actions, conditions, tags).
GET/api/v1/workflows/:workflowIdRetrieves workflow definition, execution history (/:workflowId/executions), and logs (/:workflowId/logs).
PUT/api/v1/workflows/:workflowIdUpdates workflow triggers, conditions, actions, or status (request payload).
POST/api/v1/workflows/:workflowId/activateActivates a workflow immediately (deactivate pauses execution; trigger runs manually).
DELETE/api/v1/workflows/:workflowIdDeletes a workflow and cancels pending delayed jobs.

Supported Triggers (workflow trigger type)

The workflow trigger type supported enum defines all 29 canonical workflow trigger types:

Trigger Categoryworkflow trigger type ValuesWhen It Fires
Pass & Template LifecyclePASS_CREATED, PASS_UPDATED, PASS_SCANNED, PASS_VOIDED, PASS_DELETED, PASS_DOWNLOADED, TEMPLATE_CREATED, TEMPLATE_UPDATEDImmediately when a pass or template is created, modified, scanned, voided, deleted, or downloaded.
Wallet, Mechanics & Opt-InPASS_INSTALLED, PASS_REMOVED, USER_OPT_IN, USER_OPT_OUT, POINTS_UPDATED, TIER_CHANGED, BALANCE_CHANGED, EVENT_EXPIRED, PASS_INACTIVE, SCAN_PERFORMEDWhen Apple/Google Wallet device registration changes, marketing consent toggles, or points/tier/balance thresholds cross.
User, Billing & ScheduleUSER_REGISTERED, USER_LOGIN, USER_PROFILE_UPDATED, SUBSCRIPTION_CHANGED, PAYMENT_RECEIVED, PAYMENT_FAILED, WEBHOOK_RECEIVED, API_CALL, SCHEDULED, MANUAL, CUSTOM_API_EVENTOn user/payment events, inbound webhook receipts (POST /api/v1/workflows/webhook/:customerId/:workflowId), cron schedules (normalized to workspace timezone), or manual/API runs.

Example: Creating a Tier Upgrade Follow-Up Workflow (POST /api/v1/workflows)

request payload accepts a top-level trigger object and an ordered actions array (IWorkflowActionConfig[]), alongside optional conditions, dataMapping, maxRetries (default 3), and timeout (default 300 seconds):

JSON
{
  "name": "Gold Tier Upgrade Celebration & Companion Voucher",
  "description": "Sends congratulatory push and waits 1 hour before issuing bonus drink voucher",
  "trigger": {
    "type": "TIER_CHANGED",
    "filters": {
      "templateId": "tmpl_loyalty_01"
    }
  },
  "conditions": {
    "field": "pass.tier",
    "operator": "EQUALS",
    "value": "GOLD"
  },
  "actions": [
    {
      "type": "SEND_PUSH_NOTIFICATION",
      "name": "Gold Upgrade Alert",
      "config": {
        "message": "Welcome to Gold Tier! Enjoy 2x points on every visit."
      }
    },
    {
      "type": "DELAY",
      "name": "Wait 60 Minutes",
      "config": {
        "durationMinutes": 60
      }
    },
    {
      "type": "GENERATE_ADDITIONAL_PASS",
      "name": "Issue Companion Voucher",
      "config": {
        "targetTemplateId": "tmpl_gold_welcome_drink",
        "linkToParentPass": true
      }
    }
  ],
  "tags": ["loyalty", "gold-tier"]
}

Explore all action types in Automated Pass Operations and visual orchestration at /workflow-engine.

Related Product & Developer Documentation

Ready to launch your first pass program?

Create your workspace, configure your pass template, and test a real pass in Apple Wallet and Google Wallet before you scale.