---
title: "Change the customer on a ticket"
method: PUT
path: "/tickets/{ticket}/customer"
tags: ["Tickets"]
---

# Change the customer on a ticket

`PUT /tickets/{ticket}/customer`

## Request

- Base URL: `https://there-there.app/api`
- URL: `https://there-there.app/api/tickets/{ticket}/customer`
- Auth: HTTP bearer

Assign an existing, unmerged contact in the current workspace to the ticket. The contact must be visible to the caller or have written a message on this ticket. The change is recorded in the ticket activity log and updates its greeting. A ticket the caller cannot access returns 404.

## Path parameters

- `ticket` string, required

## Headers

- `X-Workspace-Id` integer

## Request body

- object
  - `contact_ulid` string, required: ULID of the customer contact to assign.

## Response `200`

Updated ticket

- object
  - `data` Ticket
    - `id` integer
    - `ulid` string
    - `number` integer
    - `subject` string
    - `status` 'open' | 'waiting' | 'closed' | 'spam'
    - `channel` Channel
      - `id` integer
      - `ulid` string
      - `name` string
      - `type` 'email' | 'widget'
      - `color` string
      - `email_address` string, nullable
    - `assignee` User
      - `id` integer
      - `name` string
      - `email` string, email
      - `avatar_url` string, nullable
      - `timezone` string, nullable
    - `assigned_team` Team
      - `id` integer
      - `ulid` string
      - `name` string
      - `description` string, nullable
      - `logo_url` string, nullable
      - `member_count` integer
    - `contact` Contact
      - `id` integer
      - `ulid` string
      - `name` string, nullable
      - `email` string, email
      - `avatar_url` string, nullable
      - `company` ContactCompany
        - `ulid` string
        - `name` string
        - `domain` string, nullable
      - `ticket_count` integer, nullable
      - `last_activity_at` string, date-time, nullable
      - `notes` string, nullable
    - `tags` Tag[]
      - `id` integer
      - `ulid` string
      - `name` string
      - `color` string
    - `custom_fields` TicketCustomField[]: Every custom field that applies to this ticket's channel, whether or not it holds a value. Returned on GET /tickets/{ticket} and on every ticket write response; omitted from the paginated list.
      - `ulid` string
      - `name` string
      - `type` 'text' | 'single_select' | 'multi_select'
      - `value` string, nullable: Set for text fields only; null for the two select types.
      - `selected_option_ulids` string[]: Empty for text fields and for select fields with no value.
      - `options` TicketCustomFieldOption[]: The options an admin defined, in the order they arranged them. Empty for text fields.
        - `ulid` string
        - `name` string
        - `color` string, nullable
        - `icon` string, nullable
    - `latest_message_preview` string, nullable
    - `summary` string, nullable
    - `title` string, nullable
    - `from_address` string, nullable
    - `created_at` string, date-time
    - `updated_at` string, date-time
    - `last_activity_at` string, date-time

## Other responses

- `404`: Resource not found
- `422`: Missing, unknown, merged, or inaccessible contact.

---

[API](https://skmtc.dev/there-there/apis/there-there-api.md) · [All operations](https://skmtc.dev/there-there/apis/there-there-api/llms.txt) · [OpenAPI document](https://skmtc.dev/there-there/apis/there-there-api/revisions/1811fb0febc1?raw)
