---
title: "Retrieve a ticket"
method: GET
path: "/api/tickets/{id}"
tags: ["Tickets"]
---

# Retrieve a ticket

`GET /api/tickets/{id}`

## Request

- Base URL: `https://your-domain.gorgias.com`
- URL: `https://your-domain.gorgias.com/api/tickets/{id}`
- Auth: HTTP basic
- TypeScript: <https://skmtc.dev/gorgias/apis/gorgias-rest-api/docs/api/tickets/:id/get.ts> (a function with typed inputs; its response is checked against the schema)

## Path parameters

- `id` integer, required

## Query parameters

- `relationships` TicketExtraAttribute[]

## Response `200`

The requested ticket.

- Ticket: A ticket is a conversation between your support agents and one of your customers. It contains a list of [messages](#the-ticketmessage-object), can be associated with [tags](#the-tag-object), assigned to a [user](#the-user-object) and/or a team, and also collect customer's feedback with a [satisfaction survey](#the-satisfactionsurvey-object).
  - `id` integer, required: ID of the ticket.
  - `uri` string, required: URI of the ticket.
  - `external_id` string, required: External ID of the ticket in a foreign system. This field is not used by Gorgias, feel free to set it as you wish.
  - `events` TicketEvent[], required: All `action-executed` [events](#the-event-object) with the related user if any on the ticket.<br/><span style={{color: 'red'}}>This parameter has been deprecated.</span> Use [events api](/reference/list-events) instead.
    - `id` integer, required: ID of the event.
    - `type` string, required: Type of the event. Event types are used to discriminate between events. List of event types: `account-created`, `account-deactivated`, `account-setting-created`, `account-setting-updated`, `account-updated`, `account-renamed`, `action-executed`, `facebook-comment-created`, `facebook-comment-deleted`, `facebook-comment-edited`, `facebook-comment-hidden`, `facebook-comment-unhidden`, `facebook-comment-liked`, `facebook-comment-unliked`, `facebook-message-created`, `facebook-message-deleted`, `facebook-message-edited`, `facebook-post-created`, `facebook-post-deleted`, `facebook-post-edited`, `facebook-review-deleted`, `integration-created`, `integration-deleted`, `integration-updated`, `integration-deactivated`, `integration-reactivation-started`, `integration-reactivated`, `integration-data-item-created`, `integration-data-item-deleted`, `macro-created`, `macro-deleted`, `macro-updated`, `macro-applied`, `macro-archived`, `macro-unarchived`, `rule-created`, `rule-priority-updated`, `rule-deleted`, `rule-executed`, `rule-updated`, `rule-deactivated`, `rule-reactivated`, `rules-pipeline-executed`, `subscription-created`, `subscription-updated`, `subscription-self-serve-changed`, `tag-created`, `tag-deleted`, `tag-merged`, `tag-updated`, `tag-renamed`, `team-created`, `team-deleted`, `team-updated`, `team-member-created`, `team-member-deleted`, `ticket-assigned`, `ticket-closed`, `ticket-created`, `ticket-customer-updated`, `ticket-deleted`, `ticket-excluded-from-auto-merge`, `ticket-excluded-from-csat`, `ticket-marked-spam`, `ticket-merged`, `ticket-read-status-updated`, `ticket-reopened`, `ticket-satisfaction-survey-skipped`, `ticket-self-unsnoozed`, `ticket-sla-policy-assigned`, `ticket-snoozed`, `ticket-split`, `ticket-subject-updated`, `ticket-tags-added`, `ticket-tags-removed`, `ticket-team-assigned`, `ticket-team-unassigned`, `ticket-trashed`, `ticket-typing-activity-shopper-started`, `ticket-unassigned`, `ticket-unmarked-spam`, `ticket-untrashed`, `ticket-updated`, `ticket-viewed`, `ticket-handed-over`, `ticket-message-created`, `ticket-message-deleted`, `ticket-message-failed`, `ticket-message-summary-created`, `ticket-message-updated`, `customer-created`, `customer-updated`, `customer-merged`, `customer-deleted`, `custom-field-created`, `custom-field-updated`, `custom-field-condition-created`, `custom-field-condition-updated`, `custom-field-condition-enabled`, `custom-field-condition-disabled`, `custom-field-condition-deleted`, `custom-fields-ticket-values-updated`, `self-service-configurations-updated`, `self-service-configurations-update-started`, `user-created`, `user-invited`, `user-updated`, `user-mentioned`, `user-deleted`, `user-logged-in`, `user-logged-out`, `user-impersonated`, `user-password-changed`, `user-password-reset`, `user-2fa-changed`, `user-status-changed`, `user-availability-updated`, `user-setting-created`, `user-setting-updated`, `custom-availability-status-created`, `custom-availability-status-updated`, `custom-availability-status-deleted`, `view-deactivated`, `view-created`, `view-deleted`, `view-updated`, `view-section-created`, `view-section-updated`, `view-section-deleted`, `widget-created`, `widget-deleted`, `widget-updated`, `satisfaction-survey-sent`, `satisfaction-survey-updated`, `satisfaction-survey-responded`.
    - `user` TicketEventUser, required
      - `id` integer, required: ID of the user.
      - `firstname` string, required: First name of the user.
      - `lastname` string, required: Last name of the user.
      - `name` string, required: Full name of the user.
      - `email` string, required: Email address of the user. `password_confirmation` field must be provided to change the email.
    - `data` object, required: Data associated with the event (key-value data).
    - `created_datetime` string, date-time, required: When the event was created.
  - `status` 'open' | 'closed'
  - `channel` union, required: The channel used to initiate the conversation with the customer.
    - 'aircall' | 'api' | 'chat' | 'contact_form' | 'email' | 'facebook' | 'facebook-mention' | 'facebook-messenger' | 'facebook-recommendations' | 'help-center' | 'instagram-ad-comment' | 'instagram-comment' | 'instagram-direct-message' | 'instagram-mention' | 'internal-note' | 'phone' | 'sms' | 'twitter' | 'twitter-direct-message' | 'whatsapp' | 'yotpo-review'
    - string
  - `via` 'aircall' | 'api' | 'chat' | 'contact_form' | 'email' | 'facebook' | 'facebook-mention' | 'facebook-messenger' | 'facebook-recommendations' | 'form' | 'gorgias_chat' | 'help-center' | 'helpdesk' | 'instagram' | 'instagram-ad-comment' | 'instagram-comment' | 'instagram-direct-message' | 'instagram-mention' | 'internal-note' | 'offline_capture' | 'phone' | 'rule' | 'self_service' | 'shopify' | 'sms' | 'twilio' | 'twitter' | 'twitter-direct-message' | 'whatsapp' | 'yotpo' | 'yotpo-review' | 'zendesk', required
  - `from_agent` boolean, required: Whether the first message of the ticket was sent by your company to a customer, or the opposite.
  - `spam` boolean, required: Whether the ticket is considered as spam or not.
  - `imported` boolean, required: Whether the ticket was created by a historical import.
  - `customer` TicketCustomer, required
    - `id` integer, required: ID of the customer.
    - `email` string, required: Primary email address of the customer.
    - `name` string, required: Full name of the customer
    - `firstname` string, required: First name of the customer.
    - `lastname` string, required: Last name of the customer.
    - `meta` unknown, required
    - `channels` TicketCustomerChannel[], required: The [customer's contact channels](#the-customerchannel-object).
      - `id` integer, required: ID of the object
      - `type` string, required: Either the slug of a non-legacy channel or one of email,phone,chat,twitter,facebook,instagram,instagram-direct-message,whatsapp,whatsapp-bsuid
      - `address` string, required: Address can be email, phone, facebook id, etc...
      - `preferred` boolean: Is this the preferred or (primary) channel to contact this user.
      - `created_datetime` string, date-time, required: When the user channel was created.
      - `updated_datetime` string, date-time, required: When the user channel was last updated.
      - `deleted_datetime` string, date-time, required: When the user channel was deleted.
      - `user` TicketCustomerChannelCustomer, required
        - `id` integer, required: ID of the object
        - `name` string, required: Full name of the customer
      - `customer` TicketCustomerChannelCustomer, required
        - `id` integer, required: ID of the object
        - `name` string, required: Full name of the customer
    - `data` unknown, required
    - `customer` unknown, required
    - `integrations` object, required: Data coming from integrations (Shopify, Recharge, HTTP, etc...) associated with the customer. Keys of the object are integration IDs, values are raw data collected from the integrations.
    - `external_id` string, required: ID of the customer in a foreign system (Stripe, Aircall, etc...). This field is not used by Gorgias, feel free to set it as you wish.
    - `note` string, required: A note associated with the customer.
    - `external_data` object: External data associated with the customer.
    - `ecommerce_data` object: Ecommerce data associated with the customer.
  - `assignee_user` TicketUser, required
    - `id` integer, required: ID of the user.
    - `email` string, required: Email address of the user. `password_confirmation` field must be provided to change the email.
    - `name` string, required: Full name of the user.
    - `firstname` string, required: First name of the user.
    - `lastname` string, required: Last name of the user.
    - `meta` unknown, required
    - `bio` string, required: Short biography of the user.
  - `language` string, required: The language primarily used in the ticket. The language is automatically detected on the first messages by Gorgias if not set explicitly. Once the language has been set, it won't be updated according to future messages.
  - `subject` string, required: The subject of the ticket.
  - `summary` TicketSummary
    - `content` string, required: The content of the AI summary.
    - `created_datetime` string, date-time, required: When the ticket was summarized by AI for the first time.
    - `updated_datetime` string, date-time, required: When the ticket was summarized by AI for the last time.
    - `triggered_by` integer, required: The id of the user who triggered the summary generation, if triggered manually.
  - `meta` unknown, required
  - `tags` TicketTag[], required: [Tags](#the-tag-object) linked to the ticket.
    - `id` integer, required: ID of the tag
    - `name` string, required: Name of the tag. Tags' names are case sensitive.
    - `decoration` TicketTagDecoration, required
      - `color` string: The color of the tag (Hex color code).
  - `custom_fields` object: The custom fields associated with the ticket.
  - `messages` TicketMessage[], required: Messages of the ticket.
    - `id` integer, required: ID of the message.
    - `uri` string, required: URI of the message.
    - `message_id` string, required: ID of the message on the service that sent the message.It can be the ID of an email, a Messenger message, a Facebook comment, etc...
    - `ticket_id` integer, required: The ID of the ticket the message is associated with.
    - `external_id` string, required: ID of the message in a foreign system (Aircall, Zendesk, etc...). This field is not used by Gorgias, feel free to set it as you wish.
    - `public` boolean: Whether the message was sent/receive by a customer. Internal notes are not public.
    - `channel` union, required: The channel used to send the message.
      - 'aircall' | 'api' | 'chat' | 'contact_form' | 'email' | 'facebook' | 'facebook-mention' | 'facebook-messenger' | 'facebook-recommendations' | 'help-center' | 'instagram-ad-comment' | 'instagram-comment' | 'instagram-direct-message' | 'instagram-mention' | 'internal-note' | 'phone' | 'sms' | 'twitter' | 'twitter-direct-message' | 'whatsapp' | 'yotpo-review'
      - string
    - `via` 'aircall' | 'api' | 'chat' | 'contact_form' | 'email' | 'facebook' | 'facebook-mention' | 'facebook-messenger' | 'facebook-recommendations' | 'form' | 'gorgias_chat' | 'help-center' | 'helpdesk' | 'instagram' | 'instagram-ad-comment' | 'instagram-comment' | 'instagram-direct-message' | 'instagram-mention' | 'internal-note' | 'offline_capture' | 'phone' | 'rule' | 'self_service' | 'shopify' | 'sms' | 'twilio' | 'twitter' | 'twitter-direct-message' | 'whatsapp' | 'yotpo' | 'yotpo-review' | 'zendesk', required
    - `source` TicketMessageSource, required
      - `type` string, required: Describes a more detailed channel information of how the message was sent/received. Either the slug of a non-legacy channel or one of aircall,api,app,chat,chat-contact-form,chat-offline-capture,contact-form,email,facebook-comment,facebook-message,facebook-messenger,facebook-post,facebook-mention-post,facebook-mention-comment,facebook,facebook-review,facebook-review-comment,form,help-center,helpdesk,instagram-ad-comment,instagram-ad-media,instagram-comment,instagram-mention-comment,instagram-media,instagram-mention-media,instagram,instagram-direct-message,internal-note,ottspott-call,phone,rule,self_service,shopify,sms,system-message,twilio,yotpo-review,yotpo-review-public-comment,yotpo-review-private-comment,twitter-tweet,twitter-quoted-tweet,twitter-mention-tweet,twitter-direct-message,help-center-contact-form,whatsapp-message.
      - `to` TicketMessageSourceAddress[]: A list of To addresses. To and From are usually present for most channel types.
        - `name` string
        - `address` string
      - `cc` TicketMessageSourceAddress[]: A list of CC addresses. Only present in an email context.
        - `name` string
        - `address` string
      - `bcc` TicketMessageSourceAddress[]: A list of BCC addresses. Only present in an email context.
        - `name` string
        - `address` string
      - `from` TicketMessageSourceAddress
        - `name` string
        - `address` string
      - `extra` unknown
    - `sender` TicketMessageUserOrCustomer, required
      - `id` integer, required
      - `email` string, required
      - `name` string, required
      - `firstname` string, required
      - `lastname` string, required
      - `meta` unknown, required
    - `auth_customer_identity` TicketMessageAuthCustomerIdentity, required
      - `service` TicketMessageAuthCustomerIdentityService, required
        - `id` string, required: The ID of the service the identity belongs to.
        - `name` string, required: The name of the service the identity belongs to.
      - `identifier` string, required: The ID of the customer related to the service. E.g.: email address, phone number, Shopify customer ID, etc.
    - `integration_id` integer, required: ID of the integration that either received or sent the message.
    - `intents` TicketMessageIntent[], required
      - `name` string, required: The intention the message probably has, example: discount/request
      - `rejected` boolean, required: Whether or not the intent was rejected
      - `is_user_feedback` boolean, required: Whether or not the intent comes from a user feedback
    - `rule_id` integer, required: ID of the rule which sent the message, if any.
    - `from_agent` boolean, required: Whether the message was sent by your company to a customer, or the opposite.
    - `receiver` TicketMessageUserOrCustomer, required
      - `id` integer, required
      - `email` string, required
      - `name` string, required
      - `firstname` string, required
      - `lastname` string, required
      - `meta` unknown, required
    - `subject` string, required: The subject of the message.
    - `body_text` string, required: The full text version of the body of the message, if any.
    - `body_html` string, required: The full HTML version of the body of the message, if any.
    - `body_url` string, required: The URL to download the archived body of the email message. Empty until the body is archived, 30 days after it was sent or received. Only applies to email messages that have stripped bodies.
    - `stripped_text` string, required: The text version of the body of the message without email signatures and previous replies.
    - `stripped_html` string, required: The HTML version of the body of the message without email signatures and previous replies.
    - `stripped_signature` string, required
    - `attachments` TicketMessageAttachment[], required: A list of files attached to the message.
      - `url` string, required: The URL to access to the attached file.
      - `name` string: The name of the file.
      - `size` integer: The size of the file, in bytes.
      - `content_type` string, required: The MIME type of the file.
      - `public` boolean: Whether or not the attachment can be accessed.
      - `extra` unknown
    - `macros` TicketMessageMacro[]: A list of macros.
      - `id` integer, required
    - `actions` object[], required: A list of actions executed before the message was sent. These actions are set by macros.
    - `headers` object: Message headers. Used for email messages.
    - `imported` boolean, required: Whether the message was created by a historical import.
    - `meta` unknown, required
    - `created_datetime` string, date-time, required: When the message was created.
    - `processed_datetime` string, date-time, required: When the message was processed by Gorgias. Differs from `created_datetime` which refers to the external service.
    - `deleted_datetime` string, date-time: When the message was deleted.
    - `sent_datetime` string, date-time, required: When the message was sent. If omitted, the message will be sent by Gorgias.
    - `failed_datetime` string, date-time, required: When the message failed to be sent. Messages that couldn't be sent can be resend.
    - `opened_datetime` string, date-time, required: When the message was opened by the primary receiver.
    - `last_sending_error` TicketMessageSendingError, required
      - `error` string, required
    - `is_retriable` boolean, required: It determines if the message can be retried or not.
    - `replied_by` TicketMessageRepliedByOrTo
      - `integration_id` integer, required: ID of the integration which created the message.
      - `message_id` string, required: ID of the message in Gorgias.
      - `created_datetime` string, date-time, required: When the message was created.
      - `body_text` string, required: The full text version of the body of the message, if any.
      - `source` TicketMessageSource, required
        - `type` string, required: Describes a more detailed channel information of how the message was sent/received. Either the slug of a non-legacy channel or one of aircall,api,app,chat,chat-contact-form,chat-offline-capture,contact-form,email,facebook-comment,facebook-message,facebook-messenger,facebook-post,facebook-mention-post,facebook-mention-comment,facebook,facebook-review,facebook-review-comment,form,help-center,helpdesk,instagram-ad-comment,instagram-ad-media,instagram-comment,instagram-mention-comment,instagram-media,instagram-mention-media,instagram,instagram-direct-message,internal-note,ottspott-call,phone,rule,self_service,shopify,sms,system-message,twilio,yotpo-review,yotpo-review-public-comment,yotpo-review-private-comment,twitter-tweet,twitter-quoted-tweet,twitter-mention-tweet,twitter-direct-message,help-center-contact-form,whatsapp-message.
        - `to` TicketMessageSourceAddress[]: A list of To addresses. To and From are usually present for most channel types.
          - `name` string
          - `address` string
        - `cc` TicketMessageSourceAddress[]: A list of CC addresses. Only present in an email context.
          - `name` string
          - `address` string
        - `bcc` TicketMessageSourceAddress[]: A list of BCC addresses. Only present in an email context.
          - `name` string
          - `address` string
        - `from` TicketMessageSourceAddress
          - `name` string
          - `address` string
        - `extra` unknown
      - `customer` TicketMessageUserOrCustomer, required
        - `id` integer, required
        - `email` string, required
        - `name` string, required
        - `firstname` string, required
        - `lastname` string, required
        - `meta` unknown, required
      - `user` TicketMessageUserOrCustomer, required
        - `id` integer, required
        - `email` string, required
        - `name` string, required
        - `firstname` string, required
        - `lastname` string, required
        - `meta` unknown, required
    - `replied_to` TicketMessageRepliedByOrTo
      - `integration_id` integer, required: ID of the integration which created the message.
      - `message_id` string, required: ID of the message in Gorgias.
      - `created_datetime` string, date-time, required: When the message was created.
      - `body_text` string, required: The full text version of the body of the message, if any.
      - `source` TicketMessageSource, required
        - `type` string, required: Describes a more detailed channel information of how the message was sent/received. Either the slug of a non-legacy channel or one of aircall,api,app,chat,chat-contact-form,chat-offline-capture,contact-form,email,facebook-comment,facebook-message,facebook-messenger,facebook-post,facebook-mention-post,facebook-mention-comment,facebook,facebook-review,facebook-review-comment,form,help-center,helpdesk,instagram-ad-comment,instagram-ad-media,instagram-comment,instagram-mention-comment,instagram-media,instagram-mention-media,instagram,instagram-direct-message,internal-note,ottspott-call,phone,rule,self_service,shopify,sms,system-message,twilio,yotpo-review,yotpo-review-public-comment,yotpo-review-private-comment,twitter-tweet,twitter-quoted-tweet,twitter-mention-tweet,twitter-direct-message,help-center-contact-form,whatsapp-message.
        - `to` TicketMessageSourceAddress[]: A list of To addresses. To and From are usually present for most channel types.
          - `name` string
          - `address` string
        - `cc` TicketMessageSourceAddress[]: A list of CC addresses. Only present in an email context.
          - `name` string
          - `address` string
        - `bcc` TicketMessageSourceAddress[]: A list of BCC addresses. Only present in an email context.
          - `name` string
          - `address` string
        - `from` TicketMessageSourceAddress
          - `name` string
          - `address` string
        - `extra` unknown
      - `customer` TicketMessageUserOrCustomer, required
        - `id` integer, required
        - `email` string, required
        - `name` string, required
        - `firstname` string, required
        - `lastname` string, required
        - `meta` unknown, required
      - `user` TicketMessageUserOrCustomer, required
        - `id` integer, required
        - `email` string, required
        - `name` string, required
        - `firstname` string, required
        - `lastname` string, required
        - `meta` unknown, required
  - `created_datetime` string, date-time, required: When the ticket was created.
  - `processed_datetime` string, date-time, required: When the ticket was processed by Gorgias. Differs from `created_datetime` which refers to the external service.
  - `opened_datetime` string, date-time, required: When the ticket was opened for the first time by a user.
  - `last_received_message_datetime` string, date-time, required: When the last customer's message was sent.
  - `last_message_datetime` string, date-time, required: When the last message was sent.
  - `updated_datetime` string, date-time, required: When the ticket was lastly updated.
  - `closed_datetime` string, date-time, required: When the ticket was closed.
  - `trashed_datetime` string, date-time, required: When the ticket was moved to the trash.
  - `snooze_datetime` string, date-time, required: When the ticket will be re-opened.
  - `satisfaction_survey` TicketSatisfactionSurvey, required
    - `id` integer, required: ID of the survey.
    - `customer_id` integer, required: The ID of the customer who filled the survey.
    - `ticket_id` integer, required: The ID of the ticket the survey is associated with.
    - `sent_datetime` string, date-time, required: When the survey was sent. If is not set it means that it was not sent yet.
    - `scored_datetime` string, date-time, required: When the survey was filled by the customer.
    - `should_send_datetime` string, date-time, required: When the survey should be sent. If not set then the survey will not be sent by Gorgias.
    - `created_datetime` string, date-time, required: When the survey was created.
    - `score` integer, required: The level of satisfaction. Scores range from 1 to 5.
    - `body_text` string, required: The comment sent by the customer.
    - `meta` object, required: Data associated with the satisfaction survey. You can use this parameter to store structured information (key-value data) about the satisfaction survey. This field is not used by Gorgias.
  - `reply_options` object, required
  - `is_unread` boolean, required: Whether the ticket is unread for you.

## Changes

- **2026-11-03** `3fdfcb5b6678`: 1 info
  - endpoint added

[Operation history](https://skmtc.dev/gorgias/apis/gorgias-rest-api/changes/api/tickets/:id/get.md)

---

[API](https://skmtc.dev/gorgias/apis/gorgias-rest-api.md) - [All operations](https://skmtc.dev/gorgias/apis/gorgias-rest-api/llms.txt) - [OpenAPI document](https://skmtc.dev/gorgias/apis/gorgias-rest-api/revisions/3fdfcb5b6678?raw)
