# Retrieve a ticket

You can fetch the details of a single ticket.

Endpoint: GET /tickets/{id}
Version: 2.9
Security: bearerAuth

## Path parameters:

  - `id` (string, required)
    The unique identifier for the ticket which is given by Intercom.
{% admonition type="info" name="Not the Inbox ticket ID" %}
This is the internal `id` field from the API response, not the `ticket_id` displayed in the Intercom Inbox (e.g., #12345). Use the `id` value from the ticket object returned by the API.
{% /admonition %}

## Header parameters:

  - `Intercom-Version` (string)

## Response 200 fields (application/json):

  - `type` (string)
    Always ticket
    Enum: "ticket"

  - `id` (string)
    The unique identifier for the ticket which is given by Intercom.
    Example: 1295

  - `ticket_id` (string)
    The ID of the Ticket used in the Intercom Inbox and Messenger. Do not use ticket_id for API queries.
    Example: 1390

  - `ticket_state` (string)
    The state the ticket is currenly in
    Enum: "submitted", "in_progress", "waiting_on_customer", "resolved"

  - `ticket_state_internal_label` (string)
    The state the ticket is currently in, in a human readable form - visible in Intercom

  - `ticket_state_external_label` (string)
    The state the ticket is currently in, in a human readable form - visible to customers, in the messenger, email and tickets portal.

  - `ticket_type` (object)
    A ticket type, used to define the data fields to be captured in a ticket.

  - `ticket_type.type` (string)
    String representing the object's type. Always has the value `ticket_type`.
    Example: ticket_type

  - `ticket_type.id` (string)
    The id representing the ticket type.
    Example: 1295

  - `ticket_type.name` (string)
    The name of the ticket type
    Example: Bug

  - `ticket_type.description` (string)
    The description of the ticket type
    Example: A bug that has been reported.

  - `ticket_type.icon` (string)
    The icon of the ticket type
    Example: 🐞

  - `ticket_type.workspace_id` (string)
    The id of the workspace that the ticket type belongs to.
    Example: ecahpwf5

  - `ticket_type.ticket_type_attributes` (object)
    A list of attributes associated with a given ticket type.

  - `ticket_type.ticket_type_attributes.type` (string)
    String representing the object's type. Always has the value `ticket_type_attributes.list`.

  - `ticket_type.ticket_type_attributes.ticket_type_attributes` (array)
    A list of ticket type attributes associated with a given ticket type.

  - `ticket_type.ticket_type_attributes.ticket_type_attributes.type` (string)
    String representing the object's type. Always has the value `ticket_type_attribute`.
    Example: ticket_type_attribute

  - `ticket_type.ticket_type_attributes.ticket_type_attributes.id` (string)
    The id representing the ticket type attribute.
    Example: 1

  - `ticket_type.ticket_type_attributes.ticket_type_attributes.workspace_id` (string)
    The id of the workspace that the ticket type attribute belongs to.
    Example: ecahpwf5

  - `ticket_type.ticket_type_attributes.ticket_type_attributes.name` (string)
    The name of the ticket type attribute
    Example: Title

  - `ticket_type.ticket_type_attributes.ticket_type_attributes.description` (string)
    The description of the ticket type attribute
    Example: Bug title.

  - `ticket_type.ticket_type_attributes.ticket_type_attributes.data_type` (string)
    The type of the data attribute (allowed values: "string list integer decimal boolean datetime files")
    Example: string

  - `ticket_type.ticket_type_attributes.ticket_type_attributes.input_options` (object)
    Input options for the attribute
    Example: multiline: true

  - `ticket_type.ticket_type_attributes.ticket_type_attributes.order` (integer)
    The order of the attribute against other attributes
    Example: 1

  - `ticket_type.ticket_type_attributes.ticket_type_attributes.required_to_create` (boolean)
    Whether the attribute is required or not for teammates.
    Example: false

  - `ticket_type.ticket_type_attributes.ticket_type_attributes.required_to_create_for_contacts` (boolean)
    Whether the attribute is required or not for contacts.
    Example: false

  - `ticket_type.ticket_type_attributes.ticket_type_attributes.visible_on_create` (boolean)
    Whether the attribute is visible or not to teammates.
    Example: false

  - `ticket_type.ticket_type_attributes.ticket_type_attributes.visible_to_contacts` (boolean)
    Whether the attribute is visible or not to contacts.
    Example: false

  - `ticket_type.ticket_type_attributes.ticket_type_attributes.default` (boolean)
    Whether the attribute is built in or not.
    Example: true

  - `ticket_type.ticket_type_attributes.ticket_type_attributes.ticket_type_id` (integer)
    The id of the ticket type that the attribute belongs to.
    Example: 42

  - `ticket_type.ticket_type_attributes.ticket_type_attributes.archived` (boolean)
    Whether the ticket type attribute is archived or not.
    Example: false

  - `ticket_type.ticket_type_attributes.ticket_type_attributes.created_at` (integer)
    The date and time the ticket type attribute was created.

  - `ticket_type.ticket_type_attributes.ticket_type_attributes.updated_at` (integer)
    The date and time the ticket type attribute was last updated.

  - `ticket_type.archived` (boolean)
    Whether the ticket type is archived or not.
    Example: false

  - `ticket_type.created_at` (integer)
    The date and time the ticket type was created.

  - `ticket_type.updated_at` (integer)
    The date and time the ticket type was last updated.

  - `contacts` (object)
    The list of contacts affected by a ticket.

  - `contacts.type` (string)
    always contact.list
    Enum: "contact.list"

  - `contacts.contacts` (array)
    The list of contacts affected by this ticket.

  - `contacts.contacts.type` (string)
    always contact
    Enum: "contact"

  - `contacts.contacts.id` (string)
    The unique identifier for the contact which is given by Intercom.
    Example: 5ba682d23d7cf92bef87bfd4

  - `contacts.contacts.external_id` (string)
    The unique identifier for the contact which is provided by the Client.
    Example: f3b87a2e09d514c6c2e79b9a

  - `admin_assignee_id` (string)
    The id representing the admin assigned to the ticket.
    Example: 1295

  - `team_assignee_id` (string)
    The id representing the team assigned to the ticket.
    Example: 1295

  - `created_at` (integer)
    The time the ticket was created as a UTC Unix timestamp.
    Example: 1663597223

  - `updated_at` (integer)
    The last time the ticket was updated as a UTC Unix timestamp.
    Example: 1663597260

  - `ticket_parts` (object)
    A list of Ticket Part objects for each note and event in the ticket. There is a limit of 500 parts.

  - `ticket_parts.type` (string)
    Enum: "ticket_part.list"

  - `ticket_parts.ticket_parts` (array)
    A list of Ticket Part objects for each ticket. There is a limit of 500 parts.

  - `ticket_parts.ticket_parts.type` (string)
    Always ticket_part
    Example: ticket_part

  - `ticket_parts.ticket_parts.id` (string)
    The id representing the ticket part.
    Example: 3

  - `ticket_parts.ticket_parts.part_type` (string)
    The type of ticket part.
    Example: comment

  - `ticket_parts.ticket_parts.body` (string)
    The message body, which may contain HTML.
    Example: <p>Okay!</p>

  - `ticket_parts.ticket_parts.previous_ticket_state` (string)
    The previous state of the ticket.
    Enum: "submitted", "in_progress", "waiting_on_customer", "resolved"

  - `ticket_parts.ticket_parts.ticket_state` (string)
    The state of the ticket.
    Enum: "submitted", "in_progress", "waiting_on_customer", "resolved"

  - `ticket_parts.ticket_parts.created_at` (integer)
    The time the ticket part was created.
    Example: 1663597223

  - `ticket_parts.ticket_parts.updated_at` (integer)
    The last time the ticket part was updated.
    Example: 1663597260

  - `ticket_parts.ticket_parts.assigned_to` (object)
    reference to another object

  - `ticket_parts.ticket_parts.assigned_to.type` (string)
    Example: contact

  - `ticket_parts.ticket_parts.assigned_to.id` (string)
    Example: 1a2b3c

  - `ticket_parts.ticket_parts.author` (object)
    The author that wrote or triggered the part. Can be a bot, admin, team or user.

  - `ticket_parts.ticket_parts.author.type` (string)
    Enum: "admin", "bot", "team"

  - `ticket_parts.ticket_parts.author.id` (string)
    The id of the author
    Example: 274

  - `ticket_parts.ticket_parts.author.name` (string)
    The name of the author
    Example: Operator

  - `ticket_parts.ticket_parts.author.email` (string)
    The email of the author
    Example: operator+abcd1234@intercom.io

  - `ticket_parts.ticket_parts.attachments` (array)
    A list of attachments for the part.

  - `ticket_parts.ticket_parts.attachments.type` (string)
    The type of attachment
    Example: upload

  - `ticket_parts.ticket_parts.attachments.name` (string)
    The name of the attachment
    Example: example.png

  - `ticket_parts.ticket_parts.attachments.url` (string)
    The URL of the attachment
    Example: https://picsum.photos/200/300

  - `ticket_parts.ticket_parts.attachments.content_type` (string)
    The content type of the attachment
    Example: image/png

  - `ticket_parts.ticket_parts.attachments.filesize` (integer)
    The size of the attachment
    Example: 100

  - `ticket_parts.ticket_parts.attachments.width` (integer)
    The width of the attachment
    Example: 100

  - `ticket_parts.ticket_parts.attachments.height` (integer)
    The height of the attachment
    Example: 100

  - `ticket_parts.ticket_parts.external_id` (string)
    The external id of the ticket part
    Example: abcd1234

  - `ticket_parts.ticket_parts.redacted` (boolean)
    Whether or not the ticket part has been redacted.
    Example: false

  - `ticket_parts.total_count` (integer)
    Example: 2

  - `is_shared` (boolean)
    Whether or not the ticket is shared with the customer.
    Example: true

## Response 401 fields (application/json):

  - `type` (string, required)
    The type is error.list
    Example: error.list

  - `request_id` (string)
    Example: f93ecfa8-d08a-4325-8694-89aeb89c8f85

  - `errors` (array, required)
    An array of one or more error objects

  - `errors.code` (string, required)
    A string indicating the kind of error, used to further qualify the HTTP response code
    Example: unauthorized

  - `errors.message` (string)
    Optional. Human readable description of the error.
    Example: Access Token Invalid

  - `errors.field` (string)
    Optional. Used to identify a particular field or query parameter that was in error.
    Example: email

