From 655a019af11082454870dcf12b18c90c55a31555 Mon Sep 17 00:00:00 2001 From: Andre Macedo Date: Mon, 23 Nov 2026 15:48:36 +0100 Subject: [PATCH 1/2] Document POST /procedures/{procedure_id}/proactive_trigger (Preview) Co-Authored-By: Claude Opus 5.5 --- descriptions/0/api.intercom.io.yaml | 149 +++++++++++++++++++++++++++- 1 file changed, 148 insertions(+), 1 deletion(-) diff --git a/descriptions/0/api.intercom.io.yaml b/descriptions/0/api.intercom.io.yaml index c11b070a..f4fe1788 100644 --- a/descriptions/0/api.intercom.io.yaml +++ b/descriptions/0/api.intercom.io.yaml @@ -39760,6 +39760,153 @@ paths: message: This HITL request has already been fulfilled schema: "$ref": "#/components/schemas/error" + "/procedures/{procedure_id}/proactive_trigger": + post: + summary: Proactively trigger a procedure for a user + parameters: + - name: Intercom-Version + in: header + schema: + "$ref": "#/components/schemas/intercom_version" + - name: procedure_id + in: path + required: true + description: The ID of the procedure, or of the Fin skill, to trigger. + example: '12345' + schema: + type: string + tags: + - Procedures + operationId: proactiveTriggerProcedure + description: | + Start a new Fin conversation with a user and run the given procedure in it, without waiting for the user to write in first. + + The procedure must have an API trigger configured; otherwise the request returns a 404. The user must already exist in your workspace, identified by their `user_id`; this endpoint does not create users. + + {% admonition type="info" name="Authentication" %} + This endpoint requires an OAuth token with the `write_conversations` scope. + {% /admonition %} + requestBody: + required: true + content: + application/json: + schema: + type: object + required: + - user + properties: + user: + type: object + description: The user to start the conversation with. + required: + - id + properties: + id: + type: string + description: The `user_id` you assigned to the contact (their external ID), not the Intercom contact ID. + example: user-8261 + locale: + type: string + description: The locale Fin should use in the conversation. A locale Fin can't serve for your workspace falls back to the workspace default instead of failing the request. + example: fr + context: + type: object + description: Optional key-value data that is passed to the procedure when it starts. + additionalProperties: true + example: + order_id: ORD-1029 + examples: + Trigger with locale and context: + value: + user: + id: user-8261 + locale: fr + context: + order_id: ORD-1029 + responses: + '200': + description: Procedure triggered + content: + application/json: + examples: + Successful response: + value: + status: triggered + conversation_id: '215473853299345' + procedure_id: '12345' + schema: + type: object + properties: + status: + type: string + description: Always `triggered`. + example: triggered + conversation_id: + type: string + description: The ID of the conversation the procedure was started in. + example: '215473853299345' + procedure_id: + type: string + description: The `procedure_id` from the request path. + example: '12345' + fin_skill_id: + type: string + description: The ID of the Fin skill that was triggered. Present only when `procedure_id` identifies a Fin skill. + example: '67890' + '400': + description: Bad request + content: + application/json: + examples: + Missing user id: + value: + type: error.list + request_id: b68959ea-6328-4f70-83cb-e7913dba1542 + errors: + - code: bad_request + message: user.id is required + schema: + "$ref": "#/components/schemas/error" + '401': + "$ref": "#/components/responses/Unauthorized" + '404': + description: The procedure or Fin skill was not found or has no API trigger, + or no user has the given `user.id`. + content: + application/json: + examples: + No API trigger: + value: + type: error.list + request_id: b68959ea-6328-4f70-83cb-e7913dba1542 + errors: + - code: not_found + message: Procedure does not have a api trigger + User not found: + value: + type: error.list + request_id: b68959ea-6328-4f70-83cb-e7913dba1542 + errors: + - code: not_found + message: User Not Found + schema: + "$ref": "#/components/schemas/error" + '422': + description: The procedure can't be triggered for this user, for example + because the user is outside the Fin skill's audience or can't be contacted + on the configured channel. + content: + application/json: + examples: + Outside audience: + value: + type: error.list + request_id: b68959ea-6328-4f70-83cb-e7913dba1542 + errors: + - code: unprocessable_entity + message: User is not in the Fin skill's audience + schema: + "$ref": "#/components/schemas/error" components: schemas: office_hours_time_interval: @@ -60219,7 +60366,7 @@ tags: OAuth token with the `read_write_office_hours` scope. - name: Procedures description: | - Submit human-collected input to Fin Procedures via the HITL (Human in the Loop) API. + Proactively trigger Fin Procedures for a user, and submit human-collected input to Fin Procedures via the HITL (Human in the Loop) API.   From d1959e4b29342f10c538bc1faa7b7cdd86a9c594 Mon Sep 17 00:00:00 2001 From: Andre Macedo Date: Mon, 23 Nov 2026 16:17:22 +0100 Subject: [PATCH 2/2] Match the proactive trigger entry to the developer docs spec Co-Authored-By: Claude Opus 5.5 --- descriptions/0/api.intercom.io.yaml | 183 +++++++++++++++++----------- 1 file changed, 115 insertions(+), 68 deletions(-) diff --git a/descriptions/0/api.intercom.io.yaml b/descriptions/0/api.intercom.io.yaml index f4fe1788..a428602e 100644 --- a/descriptions/0/api.intercom.io.yaml +++ b/descriptions/0/api.intercom.io.yaml @@ -39762,7 +39762,7 @@ paths: "$ref": "#/components/schemas/error" "/procedures/{procedure_id}/proactive_trigger": post: - summary: Proactively trigger a procedure for a user + summary: Trigger a Fin Procedure for a user parameters: - name: Intercom-Version in: header @@ -39771,140 +39771,128 @@ paths: - name: procedure_id in: path required: true - description: The ID of the procedure, or of the Fin skill, to trigger. + description: The ID of the procedure to trigger. example: '12345' schema: type: string tags: - Procedures - operationId: proactiveTriggerProcedure + operationId: triggerProcedure description: | - Start a new Fin conversation with a user and run the given procedure in it, without waiting for the user to write in first. + Start a Fin Procedure on a new conversation for an existing user. Fin sends the user the procedure's opening message and the procedure runs from there. - The procedure must have an API trigger configured; otherwise the request returns a 404. The user must already exist in your workspace, identified by their `user_id`; this endpoint does not create users. + The procedure must have an API trigger. Identify the user by the `user_id` you assigned to them in Intercom. The user must already exist; this endpoint does not create users. - {% admonition type="info" name="Authentication" %} - This endpoint requires an OAuth token with the `write_conversations` scope. - {% /admonition %} + If you send a `locale` that Fin does not support for your workspace, the conversation uses your workspace's default language. requestBody: required: true content: application/json: schema: - type: object - required: - - user - properties: - user: - type: object - description: The user to start the conversation with. - required: - - id - properties: - id: - type: string - description: The `user_id` you assigned to the contact (their external ID), not the Intercom contact ID. - example: user-8261 - locale: - type: string - description: The locale Fin should use in the conversation. A locale Fin can't serve for your workspace falls back to the workspace default instead of failing the request. - example: fr - context: - type: object - description: Optional key-value data that is passed to the procedure when it starts. - additionalProperties: true - example: - order_id: ORD-1029 + "$ref": "#/components/schemas/trigger_procedure_request" examples: + Trigger for a user: + value: + user: + id: user-456 Trigger with locale and context: value: user: - id: user-8261 + id: user-456 locale: fr context: - order_id: ORD-1029 + order_id: ord-789 + plan: premium responses: '200': - description: Procedure triggered + description: The procedure was triggered. content: application/json: examples: Successful response: value: status: triggered - conversation_id: '215473853299345' + conversation_id: '192837465' procedure_id: '12345' schema: - type: object - properties: - status: - type: string - description: Always `triggered`. - example: triggered - conversation_id: - type: string - description: The ID of the conversation the procedure was started in. - example: '215473853299345' - procedure_id: - type: string - description: The `procedure_id` from the request path. - example: '12345' - fin_skill_id: - type: string - description: The ID of the Fin skill that was triggered. Present only when `procedure_id` identifies a Fin skill. - example: '67890' + "$ref": "#/components/schemas/trigger_procedure_response" '400': - description: Bad request + description: Bad Request content: application/json: examples: - Missing user id: + Missing user: + value: + type: error.list + request_id: b68959ea-6328-4f70-83cb-e7913dba1542 + errors: + - code: bad_request + message: user parameter is required + Missing user ID: value: type: error.list request_id: b68959ea-6328-4f70-83cb-e7913dba1542 errors: - code: bad_request message: user.id is required + Invalid context: + value: + type: error.list + request_id: b68959ea-6328-4f70-83cb-e7913dba1542 + errors: + - code: bad_request + message: context must be an object + Not available in this API version: + value: + type: error.list + request_id: b68959ea-6328-4f70-83cb-e7913dba1542 + errors: + - code: intercom_version_invalid + message: Requested resource is not available in current API version schema: "$ref": "#/components/schemas/error" '401': "$ref": "#/components/responses/Unauthorized" '404': - description: The procedure or Fin skill was not found or has no API trigger, - or no user has the given `user.id`. + description: Not Found content: application/json: examples: - No API trigger: + User not found: value: type: error.list request_id: b68959ea-6328-4f70-83cb-e7913dba1542 errors: - code: not_found - message: Procedure does not have a api trigger - User not found: + message: User Not Found + Procedure not found: value: type: error.list request_id: b68959ea-6328-4f70-83cb-e7913dba1542 errors: - code: not_found - message: User Not Found + message: Procedure not found + No API trigger: + value: + type: error.list + request_id: b68959ea-6328-4f70-83cb-e7913dba1542 + errors: + - code: not_found + message: Procedure does not have a api trigger schema: "$ref": "#/components/schemas/error" '422': - description: The procedure can't be triggered for this user, for example - because the user is outside the Fin skill's audience or can't be contacted - on the configured channel. + description: Unprocessable Entity content: application/json: examples: - Outside audience: + Procedure cannot be triggered: value: type: error.list request_id: b68959ea-6328-4f70-83cb-e7913dba1542 errors: - code: unprocessable_entity - message: User is not in the Fin skill's audience + message: Id matches both a procedure and a Fin skill schema: "$ref": "#/components/schemas/error" components: @@ -44286,6 +44274,65 @@ components: required: - step_id - attribute_values + trigger_procedure_request: + title: Trigger Procedure Request + type: object + x-tags: + - Procedures + description: Request body for triggering a Fin Procedure for a user. + properties: + user: + type: object + description: The user to start the procedure for. + properties: + id: + type: string + description: The `user_id` you assigned to the user in Intercom. + example: user-456 + required: + - id + locale: + type: string + description: The language for the conversation, such as `fr`. If omitted, + or if Fin does not support it for your workspace, your workspace's default + language is used. + example: fr + context: + type: object + description: Data about why you are triggering the procedure, made available + to the procedure as it runs. Send an object of any shape. + additionalProperties: true + example: + order_id: ord-789 + plan: premium + required: + - user + trigger_procedure_response: + title: Trigger Procedure Response + type: object + x-tags: + - Procedures + description: The result of triggering a Fin Procedure. + properties: + status: + type: string + description: Always `triggered`. + enum: + - triggered + example: triggered + conversation_id: + type: string + description: The ID of the conversation the procedure runs on. + example: '192837465' + procedure_id: + type: string + description: The procedure ID from the request path. + example: '12345' + fin_skill_id: + type: string + description: The ID of the Fin skill that ran. Returned only when the procedure + ran as a Fin skill. + example: '67890' company: title: Company type: object @@ -60366,7 +60413,7 @@ tags: OAuth token with the `read_write_office_hours` scope. - name: Procedures description: | - Proactively trigger Fin Procedures for a user, and submit human-collected input to Fin Procedures via the HITL (Human in the Loop) API. + Trigger Fin Procedures for your users, and submit human-collected input to Fin Procedures via the HITL (Human in the Loop) API.