Skip to content

POST   /tickets/merge

Merge tickets

Merge multiple duplicate tickets into one primary ticket

Authentication Required

Authorization: Bearer {token}   header string

This header is required to access this endpoint

Required Parameters

x-account-id   header string

Account ID for the request

Request Body

{
"primaryTicketId": "string",
"ticketIdsToMerge": [
"string"
]
}

Try it out

Loading...

Output:

Responses

Description

Tickets merged successfully

{
"success": false,
"primaryTicketId": "string",
"mergedTicketIds": [
"string"
],
"commentsMerged": 0,
"attachmentsMerged": 0,
"secondaryTicketsClosed": false,
"mergeNote": {
"id": "string",
"body": "string"
},
"errors": [
{
"ticketId": "string",
"error": "string"
}
],
"executionTime": 0
}

References

#/components/parameters/xAccountIdHeader

in: header
name: x-account-id
schema:
type: string
description: Account ID for the request
required: true
example: "2311"

#/components/schemas/MergeResult

type: object
properties:
success:
type: boolean
description: Overall merge success status
primaryTicketId:
type: string
description: ID of the primary ticket
mergedTicketIds:
type: array
items:
type: string
description: IDs of tickets that were merged
commentsMerged:
type: integer
description: Total number of comments merged
attachmentsMerged:
type: integer
description: Total number of attachments merged
secondaryTicketsClosed:
type: boolean
description: Whether secondary tickets were closed
mergeNote:
type: object
nullable: true
properties:
id:
type: string
body:
type: string
description: Internal note added to document the merge
errors:
type: array
items:
type: object
properties:
ticketId:
type: string
error:
type: string
description: Any errors encountered during merge
executionTime:
type: number
description: Total execution time in milliseconds

Route Source Code

Check out the source code for this route entrypoint here: /tickets/merge/route.ts

Or the swagger.yaml spec this documentation was generated from: /tickets/merge/swagger.yaml