Knock · Arazzo Workflow

Knock Merge Users and Re-notify

Version 1.0.0

Identify a surviving user, merge a duplicate into it, then notify the merged user.

1 workflow 2 source APIs 1 provider
View Spec View on GitHub NotificationMessagingInfrastructureWorkflowsCross-ChannelEmailSMSPushIn-AppChatSlackWebhookMCPAI AgentsDeveloper PlatformArazzoWorkflows

Provider

knock-app

Workflows

merge-users-and-renotify
Identify a surviving user, merge a duplicate in, and trigger a workflow.
Upserts the surviving user, merges the duplicate user into it, and triggers a workflow for the consolidated recipient.
3 steps inputs: apiKey, data, email, fromUserId, userId, workflowKey outputs: mergedUserId, workflowRunId
1
identifySurvivor
Upsert the surviving user so the merge target exists with current properties.
2
mergeUser
Merge the duplicate user (from_user_id) into the surviving user so all data consolidates onto a single record.
3
renotify
{$sourceDescriptions.workflowsApi.url}#/paths/~1v1~1workflows~1{key}~1trigger/post
Trigger the workflow for the consolidated user so notifications resume against the surviving record.

Source API Descriptions

Arazzo Workflow Specification

Raw ↑
arazzo: 1.0.1
info:
  title: Knock Merge Users and Re-notify
  summary: Identify a surviving user, merge a duplicate into it, then notify the merged user.
  description: >-
    When two records represent the same person, Knock can merge one user into
    another. This flow identifies the surviving user, merges a duplicate user
    into it, and triggers a workflow for the surviving record so notifications
    resume against the consolidated user. Every step spells out its request
    inline so the flow can be read and executed without opening the underlying
    OpenAPI description.
  version: 1.0.0
sourceDescriptions:
- name: usersApi
  url: ../openapi/knock-app-users-api-openapi.yml
  type: openapi
- name: workflowsApi
  url: ../openapi/knock-app-workflows-api-openapi.yml
  type: openapi
workflows:
- workflowId: merge-users-and-renotify
  summary: Identify a surviving user, merge a duplicate in, and trigger a workflow.
  description: >-
    Upserts the surviving user, merges the duplicate user into it, and triggers
    a workflow for the consolidated recipient.
  inputs:
    type: object
    required:
    - apiKey
    - userId
    - fromUserId
    - workflowKey
    properties:
      apiKey:
        type: string
        description: Knock secret API key (sk_...) used as a Bearer token.
      userId:
        type: string
        description: The id of the surviving user to merge into.
      email:
        type: string
        description: The primary email address to set on the surviving user.
      fromUserId:
        type: string
        description: The id of the duplicate user to merge from.
      workflowKey:
        type: string
        description: The key of the workflow to trigger after the merge.
      data:
        type: object
        description: Optional data payload passed into the workflow run.
  steps:
  - stepId: identifySurvivor
    description: >-
      Upsert the surviving user so the merge target exists with current
      properties.
    operationId: identifyUser
    parameters:
    - name: Authorization
      in: header
      value: Bearer $inputs.apiKey
    - name: user_id
      in: path
      value: $inputs.userId
    requestBody:
      contentType: application/json
      payload:
        email: $inputs.email
    successCriteria:
    - condition: $statusCode == 200
    outputs:
      userId: $response.body#/id
  - stepId: mergeUser
    description: >-
      Merge the duplicate user (from_user_id) into the surviving user so all
      data consolidates onto a single record.
    operationId: mergeUser
    parameters:
    - name: Authorization
      in: header
      value: Bearer $inputs.apiKey
    - name: user_id
      in: path
      value: $steps.identifySurvivor.outputs.userId
    requestBody:
      contentType: application/json
      payload:
        from_user_id: $inputs.fromUserId
    successCriteria:
    - condition: $statusCode == 200
    outputs:
      mergedUserId: $response.body#/id
  - stepId: renotify
    description: >-
      Trigger the workflow for the consolidated user so notifications resume
      against the surviving record.
    operationPath: '{$sourceDescriptions.workflowsApi.url}#/paths/~1v1~1workflows~1{key}~1trigger/post'
    parameters:
    - name: Authorization
      in: header
      value: Bearer $inputs.apiKey
    - name: key
      in: path
      value: $inputs.workflowKey
    requestBody:
      contentType: application/json
      payload:
        recipients:
        - $steps.mergeUser.outputs.mergedUserId
        data: $inputs.data
    successCriteria:
    - condition: $statusCode == 200
    outputs:
      workflowRunId: $response.body#/workflow_run_id
  outputs:
    mergedUserId: $steps.mergeUser.outputs.mergedUserId
    workflowRunId: $steps.renotify.outputs.workflowRunId

Work with this as data

Every workflow here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for arazzo workflows

4 MCP tools reach this
  • find_arazzoBrowse and filter every workflow in the catalog.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This workflow
curl "https://apis.io/api/v1/arazzo/knock-app-merge-users-and-renotify-workflow"
All arazzo workflows
curl "https://apis.io/api/v1/arazzo?limit=25"

Discovery needs no key. Ratings and market analysis are Pro.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.