Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
106 changes: 105 additions & 1 deletion descriptions/0/api.intercom.io.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11503,6 +11503,78 @@ paths:
ticket_attributes:
_default_title_: example
_default_description_: there is a problem
"/tickets/enqueue":
post:
summary: Enqueues ticket creation and returns the enqueue status. We recommend using this endpoint if you'd like to create tickets without waiting for immediate processing.
parameters:
- name: Intercom-Version
in: header
schema:
"$ref": "#/components/schemas/intercom_version"
tags:
- Tickets
description: You can enqueue a job to create a new ticket.
operationId: enqueueCreateTicket
responses:
'200':
description: Successful response
content:
application/json:
examples:
Successful response:
value:
type: enqueue_status
status: success
job_id: 20
job_url: https://api.intercom.io/jobs/status/20
schema:
"$ref": "#/components/schemas/enqueue_status"
'401':
description: Unauthorized
content:
application/json:
examples:
Unauthorized:
value:
type: error.list
request_id: c7bf358f-135e-48d7-8286-a4988a8a1d9b
errors:
- code: unauthorized
message: Access Token Invalid
schema:
"$ref": "#/components/schemas/error"
'400':
description: Bad Request
content:
application/json:
examples:
Bad Request:
value:
type: error.list
request_id: c7bf358f-135e-48d7-8286-a4988a8a1456
errors:
- code: parameter_invalid
message: "Missing required ticket }/attributes"
Comment on lines +11556 to +11557
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nit but I think for missing attributes, 422 might fit this better? Wdyt

https://stackoverflow.com/questions/16133923/400-vs-422-response-to-post-of-data

schema:
"$ref": "#/components/schemas/error"
requestBody:
content:
application/json:
schema:
allOf:
- "$ref": "#/components/schemas/create_ticket_request"
properties:
skip_notifications:
type: boolean
description: Option to disable notifications when a Ticket is created.
example: true
examples:
successful_response:
summary: Successful response
value:
status: success
job_id: 20
job_url: https://api.intercom.io/jobs/status/20
"/tickets/{id}":
put:
summary: Update a ticket
Expand Down Expand Up @@ -16232,11 +16304,16 @@ components:
assignment:
type: object
properties:
assignee_id:
admin_assignee_id:
type: string
description: The ID of the admin to which the ticket is assigned.
If not provided, the ticket will be unassigned.
example: '123'
team_assignee_id:
type: string
description: The ID of the team to which the ticket is assigned.
If not provided, the ticket will be unassigned.
example: '8'
Comment on lines +16307 to +16316
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should also be included as we've updated the admin/team assignee fields for the public API.

required:
- ticket_type_id
- contacts
Expand Down Expand Up @@ -17147,6 +17224,33 @@ components:
required:
- type
- errors
enqueue_status:
title: Enqueue Status
type: enqueue_status
description: Status of the enqueued job.
properties:
type:
type: string
description: Always enqueue_status
enum:
- enqueue_status
default: enqueue_status
example: enqueue_status
status:
type: string
description: Result of the enqueue
enum:
- success
- failed
example: success
job_id:
type: string
description: Id of the job that was created. Note this is not the id of the resource being created (i.e. ticket)
example: 20
job_url:
type: string
description: Url of the job that was created. This url should be used to fetch the status of the job.
example: https://api.intercom.io/jobs/status/20
external_page:
title: External Page
type: object
Expand Down