Docs

Flows API

Create, list, update, and delete retention flows programmatically.

List Flows

GET /api/v1/public/flows
Authorization: Bearer rq_live_xxx

# Response
{
  "flows": [
    {
      "id": "uuid",
      "name": "Pro Plan Cancellation",
      "slug": "pro-plan-cancel-a36722",
      "product_name": "Pro Plan",
      "status": "published",
      "flow_mode": "simple",
      "current_version": 2,
      "updated_at": "2026-08-20T10:00:00Z"
    }
  ]
}

Get Flow

GET /api/v1/public/flows/:id
Authorization: Bearer rq_live_xxx

Create Flow

POST /api/v1/public/flows
Authorization: Bearer rq_live_xxx
Content-Type: application/json

{
  "name": "Starter Plan Offboarding",
  "product_name": "Starter Plan",
  "cancellation_url": "https://myapp.com/cancelled",
  "flow_mode": "simple",
  "description": "Retention flow for starter plan users",
  "estimated_monthly_value": 19,
  "notification_email": "team@myapp.com"
}

# Response (201)
{
  "id": "uuid",
  "name": "Starter Plan Offboarding",
  "slug": "starter-plan-offboarding-x7k2m9"
}

Required Fields

FieldTypeDescription
namestringFlow name
product_namestringProduct this flow is for
cancellation_urlstringWhere to redirect on cancel

Update Flow

PUT /api/v1/public/flows/:id
Authorization: Bearer rq_live_xxx
Content-Type: application/json

{
  "name": "Updated Name",
  "status": "published"
}

# Response
{ "updated": true, "id": "uuid" }

Delete (Archive) Flow

DELETE /api/v1/public/flows/:id
Authorization: Bearer rq_live_xxx

# Response
{ "archived": true, "id": "uuid" }