Docs / Strand / advanced/approval-links

External Approval Links

Allow reviewers to approve or reject workflow steps directly from email, Slack, or any external channel, with no login required.

Overview

When a workflow hits an approval node, Strand can generate a secure, signed URL that allows the recipient to take action without logging into the application. This is useful when approvers are not regular Strand users, or when you want to enable quick action from mobile devices or notification channels.

How It Works

  1. Workflow execution pauses at an approval node
  2. Strand generates a cryptographically signed token
  3. A URL is created: https://app.tendrl.com/strand/approve/{token}
  4. The URL is delivered via the configured notification connector (Slack, email, etc.)
  5. The recipient clicks the link and sees a standalone approval page
  6. They can approve or reject with an optional comment
  7. The workflow resumes (on approve) or stops (on reject)

Setup

Option A: Built-In Notification

Configure notify_connector_id directly on the approval node:

Slack example:

json

{
  "message": "New expense report: ${{ payload.amount }} from {{ payload.employee }}",
  "instructions": "Approve if amount is within department budget.",
  "notify_connector_id": "slack-connector-id",
  "notify_channel": "#expense-approvals",
  "token_expiry_hours": 72
}

Email example:

json

{
  "message": "New expense report: ${{ payload.amount }} from {{ payload.employee }}",
  "instructions": "Approve if amount is within department budget.",
  "notify_connector_id": "email-connector-id",
  "notify_recipients": "{{ payload.manager_email }}",
  "token_expiry_hours": 72
}

Strand will automatically:

Option B: Connector Before Approval

For full control over the notification format, place a connector node before the approval node in your workflow graph. You can build the approval URL yourself using the token available in the notification metadata, or simply send a message saying "check Strand for a pending approval."

Security

External approval links are secured with multiple layers:

URL Configuration

Approval links point to your Strand application's public URL. This is configured at the platform level by your administrator. No user-side setup is needed.

API Reference

Get Approval Details

code

GET /api/approval-actions/{token}

Returns approval context for display on the approval page.

Response:

json

{
  "status": "waiting_approval",
  "approval_message": "New expense report: $500 from Jane",
  "approval_instructions": "Approve if within budget.",
  "workflow_name": "Expense Approval",
  "node_id": "approval_1",
  "run_status": "waiting_approval",
  "already_actioned": false,
  "actioned_at": null
}

Approve via Token

code

POST /api/approval-actions/{token}/approve

Body:

json

{
  "comment": "Approved; within budget."
}

Response:

json

{
  "message": "Approved successfully. Workflow is resuming."
}

Reject via Token

code

POST /api/approval-actions/{token}/reject

Body:

json

{
  "comment": "Over budget; please revise."
}

Response:

json

{
  "message": "Rejected successfully.",
  "run_status": "completed_with_errors"
}

Connector Payload

When using notify_connector_id, the connector receives a payload like:

json

{
  "payload": {
    "approval_message": "New expense report: $500 from Jane",
    "approval_instructions": "Approve if within budget.",
    "approval_url": "https://app.tendrl.com/strand/approve/eyJzIjoi...",
    "workflow_name": "Expense Approval",
    "run_id": "run_abc123",
    "step_run_id": "step_xyz789"
  },
  "meta": {
    "source": "approval_notification"
  }
}

You can configure the connector's message template to format this however you like (e.g., a Slack message with action buttons linking to the approval URL).

Best Practices

Tips
  1. Set token_expiry_hours appropriate to your use case (shorter for time-sensitive approvals)
  2. Include enough context in the message so the reviewer can decide without opening the app
  3. Use instructions to document the review criteria
  4. Test the approval flow end-to-end in development before deploying