arazzo: 1.0.1
info:
title: Zendesk Create Ticket and Assign Group
summary: Look up a support group by name, then open a ticket assigned to that group.
description: >-
A routing pattern for Zendesk Support. The workflow lists the account's
groups, selects the one whose name matches the supplied value, and when found
opens a new ticket assigned to that group via the group_id field. The ticket
request body uses the documented {ticket:{...}} envelope and is spelled out
inline.
version: 1.0.0
x-realizes-capability-ids:
- BC-430.10
x-capability-derivation:
method: 'deterministic join: sourceDescriptions -> per-tag OpenAPI -> tag/capability edge. No classification at this step.'
min_confidence: 0.7
sources:
- capability_id: BC-430.10
capability_name: Customer Inquiry Management
spec: zendesk-tickets-api-openapi.yml
confidence: 0.92
model: Turbo EA Capabilities by Vincent Verdet — Turbo EA, https://github.com/vincentmakes/turbo-ea-capabilities, CC BY 4.0
sourceDescriptions:
- name: groupsApi
url: ../openapi/zendesk-groups-api-openapi.yml
type: openapi
- name: ticketsApi
url: ../openapi/zendesk-tickets-api-openapi.yml
type: openapi
workflows:
- workflowId: create-ticket-assign-group
summary: Resolve a group by name and open a ticket assigned to it.
description: >-
Lists groups, finds the one matching the supplied name, and opens a ticket
routed to that group.
inputs:
type: object
required:
- groupName
- subject
- commentBody
properties:
groupName:
type: string
description: The name of the group to route the ticket to.
subject:
type: string
description: The subject line of the new ticket.
commentBody:
type: string
description: The body of the first public comment on the ticket.
steps:
- stepId: listGroups
description: List the account's groups so the target group can be resolved.
operationId: $sourceDescriptions.groupsApi.ListGroups
successCriteria:
- condition: $statusCode == 200
outputs:
groups: $response.body#/groups
onSuccess:
- name: groupsLoaded
type: goto
stepId: createTicket
criteria:
- context: $response.body
condition: $.groups[?(@.name == '$inputs.groupName')]
type: jsonpath
- stepId: createTicket
description: Open a ticket assigned to the resolved group.
operationId: $sourceDescriptions.ticketsApi.CreateTicket
requestBody:
contentType: application/json
payload:
ticket:
subject: $inputs.subject
comment:
body: $inputs.commentBody
public: true
group_id: $steps.listGroups.outputs.groups[0].id
successCriteria:
- condition: $statusCode == 201
outputs:
ticketId: $response.body#/ticket/id
assignedGroupId: $response.body#/ticket/group_id
outputs:
ticketId: $steps.createTicket.outputs.ticketId
assignedGroupId: $steps.createTicket.outputs.assignedGroupId
Calls without X-API-Key need no key. Calls with it need a paid plan — get a key.
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. By signing up you are subscribing to the APIs.io and API Evangelist
newsletters — you can unsubscribe from any issue. See our
Privacy Policy and Terms.