Skip to content

Commit 01ca60d

Browse files
Add workflow export API to OpenAPI spec (Unstable) (#347)
* Add workflow export API to OpenAPI spec (Unstable) - Add GET /export/workflows/{id} endpoint - Add Workflows tag - Add workflow_export schema This documents the workflow export API for EU Data Act compliance. Related PR: intercom/intercom#462983 Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com> * Fix 404 and 403 error response examples Add proper error.list examples for error responses to fix Swagger validation. Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com> --------- Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
1 parent 970826f commit 01ca60d

File tree

1 file changed

+170
-0
lines changed

1 file changed

+170
-0
lines changed

descriptions/0/api.intercom.io.yaml

Lines changed: 170 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9735,6 +9735,87 @@ paths:
97359735
download_expires_at: ''
97369736
schema:
97379737
"$ref": "#/components/schemas/data_export"
9738+
"/export/workflows/{id}":
9739+
get:
9740+
summary: Export a workflow
9741+
parameters:
9742+
- name: Intercom-Version
9743+
in: header
9744+
schema:
9745+
"$ref": "#/components/schemas/intercom_version"
9746+
- name: id
9747+
in: path
9748+
description: The unique identifier for the workflow
9749+
required: true
9750+
schema:
9751+
type: string
9752+
example: "12345"
9753+
tags:
9754+
- Workflows
9755+
operationId: exportWorkflow
9756+
description: |
9757+
Export a workflow configuration by its ID. This endpoint returns the complete workflow definition including its steps, targeting rules, and attributes.
9758+
9759+
This endpoint is designed for EU Data Act compliance, allowing customers to export their workflow configurations.
9760+
9761+
{% admonition type="warning" name="Unstable API" %}
9762+
This API is currently in the Unstable version. Its behavior may change in future releases.
9763+
{% /admonition %}
9764+
responses:
9765+
'200':
9766+
description: Workflow exported successfully
9767+
content:
9768+
application/json:
9769+
examples:
9770+
successful:
9771+
value:
9772+
export_version: "1.0"
9773+
exported_at: "2026-01-26T12:00:00Z"
9774+
app_id: 12345
9775+
workflow:
9776+
id: "67890"
9777+
title: "My Workflow"
9778+
description: "A workflow that handles customer inquiries"
9779+
trigger_type: "inbound_conversation"
9780+
state: "live"
9781+
target_channels: ["chat"]
9782+
preferred_devices: ["desktop", "mobile"]
9783+
created_at: "2025-06-15T10:30:00Z"
9784+
updated_at: "2026-01-20T14:45:00Z"
9785+
targeting: {}
9786+
snapshot: {}
9787+
attributes: []
9788+
embedded_rules: []
9789+
schema:
9790+
"$ref": "#/components/schemas/workflow_export"
9791+
'404':
9792+
description: Workflow not found
9793+
content:
9794+
application/json:
9795+
examples:
9796+
Workflow not found:
9797+
value:
9798+
type: error.list
9799+
request_id: b3c8c472-8478-4f10-a29e-a23dbf921c46
9800+
errors:
9801+
- code: not_found
9802+
message: Workflow not found
9803+
schema:
9804+
"$ref": "#/components/schemas/error"
9805+
'403':
9806+
description: Workflow export is not available for this app
9807+
content:
9808+
application/json:
9809+
examples:
9810+
Feature not available:
9811+
value:
9812+
type: error.list
9813+
request_id: d92f7e84-5c31-4a2b-b8e6-9f4c3d2a1b0e
9814+
errors:
9815+
- code: api_plan_restricted
9816+
message: Workflow export is not available for this app
9817+
schema:
9818+
"$ref": "#/components/schemas/error"
97389819
"/download/content/data/{job_identifier}":
97399820
get:
97409821
summary: Download content data export
@@ -23988,6 +24069,93 @@ components:
2398824069
type: string
2398924070
description: Automatically generated identifier for the Visitor.
2399024071
example: 8a88a590-e1c3-41e2-a502-e0649dbf721c
24072+
workflow_export:
24073+
title: Workflow Export
24074+
type: object
24075+
description: A workflow export containing the complete workflow configuration.
24076+
properties:
24077+
export_version:
24078+
type: string
24079+
description: The version of the export format.
24080+
example: "1.0"
24081+
exported_at:
24082+
type: string
24083+
format: date-time
24084+
description: The timestamp when the export was generated.
24085+
example: "2026-01-26T12:00:00Z"
24086+
app_id:
24087+
type: integer
24088+
description: The workspace identifier.
24089+
example: 12345
24090+
workflow:
24091+
type: object
24092+
description: The workflow configuration.
24093+
properties:
24094+
id:
24095+
type: string
24096+
description: The unique identifier for the workflow.
24097+
example: "67890"
24098+
title:
24099+
type: string
24100+
description: The title of the workflow.
24101+
example: "My Workflow"
24102+
description:
24103+
type: string
24104+
nullable: true
24105+
description: The description of the workflow.
24106+
example: "A workflow that handles customer inquiries"
24107+
trigger_type:
24108+
type: string
24109+
description: The type of trigger that starts this workflow.
24110+
example: "inbound_conversation"
24111+
state:
24112+
type: string
24113+
description: The current state of the workflow.
24114+
enum:
24115+
- live
24116+
- draft
24117+
- paused
24118+
example: "live"
24119+
target_channels:
24120+
type: array
24121+
items:
24122+
type: string
24123+
description: The channels this workflow targets.
24124+
example: ["chat"]
24125+
preferred_devices:
24126+
type: array
24127+
items:
24128+
type: string
24129+
description: The preferred devices for this workflow.
24130+
example: ["desktop", "mobile"]
24131+
created_at:
24132+
type: string
24133+
format: date-time
24134+
description: When the workflow was created.
24135+
example: "2025-06-15T10:30:00Z"
24136+
updated_at:
24137+
type: string
24138+
format: date-time
24139+
description: When the workflow was last updated.
24140+
example: "2026-01-20T14:45:00Z"
24141+
targeting:
24142+
type: object
24143+
nullable: true
24144+
description: The targeting rules for this workflow.
24145+
snapshot:
24146+
type: object
24147+
nullable: true
24148+
description: The current snapshot of workflow steps and configuration.
24149+
attributes:
24150+
type: array
24151+
items:
24152+
type: object
24153+
description: Custom attributes defined for this workflow.
24154+
embedded_rules:
24155+
type: array
24156+
items:
24157+
type: object
24158+
description: Rules embedded within the workflow steps.
2399124159
ai_call_response:
2399224160
title: AI Call Response
2399324161
type: object
@@ -24278,3 +24446,5 @@ tags:
2427824446
description: Everything about your tickets
2427924447
- name: Visitors
2428024448
description: Everything about your Visitors
24449+
- name: Workflows
24450+
description: Export workflow configurations from your workspace.

0 commit comments

Comments
 (0)