> This page is for Unified.

> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://docs.merge.dev/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://docs.merge.dev/_mcp/server.

# /tickets

GET https://api.merge.dev/api/ticketing/v1/tickets

Returns a list of `Ticket` objects.

Reference: https://docs.merge.dev/merge-unified/ticketing/common-models/tickets/list

## Authentication

- `Authorization` header (bearer token, required) — Token-based authentication with required prefix "Bearer"

## Servers

- `https://api.merge.dev/api` (Production, default)
- `https://api-eu.merge.dev/api` (ProductionEU)
- `https://api-ap.merge.dev/api` (ProductionAPSE1)

## Request

### Query parameters

- `account_id` (string, optional) — If provided, will only return tickets for this account.
- `assignee_ids` (string, optional) — If provided, will only return tickets assigned to the assignee_ids; multiple assignee_ids can be separated by commas.
- `collection_ids` (string, optional) — If provided, will only return tickets assigned to the specified collection_ids, including tickets in any nested or child collections. Multiple collection_ids can be separated by commas.
- `completed_after` (datetime, optional) — If provided, will only return tickets completed after this datetime.
- `completed_before` (datetime, optional) — If provided, will only return tickets completed before this datetime.
- `contact_id` (string, optional) — If provided, will only return tickets for this contact.
- `created_after` (datetime, optional) — If provided, will only return objects created after this datetime.
- `created_before` (datetime, optional) — If provided, will only return objects created before this datetime.
- `creator_id` (string, optional) — If provided, will only return tickets created by this creator_id.
- `creator_ids` (string, optional) — If provided, will only return tickets created by the creator_ids; multiple creator_ids can be separated by commas.
- `cursor` (string, optional) — The pagination cursor value.
- `due_after` (datetime, optional) — If provided, will only return tickets due after this datetime.
- `due_before` (datetime, optional) — If provided, will only return tickets due before this datetime.
- `expand` (list of enum, optional) — Which relations should be returned in expanded form. Multiple relation names should be comma separated without spaces.
  - Allowed values: `account`, `assigned_teams`, `assignees`, `attachments`, `collections`, `contact`, `creator`, `parent_ticket`, `permissions`
- `include_deleted_data` (boolean, optional) — Indicates whether or not this object has been deleted in the third party platform. Full coverage deletion detection is a premium add-on. Native deletion detection is offered for free with limited coverage. [Learn more](https://docs.merge.dev/integrations/hris/supported-features/).
- `include_remote_data` (boolean, optional) — Whether to include the original data Merge fetched from the third-party to produce these models.
- `include_remote_fields` (boolean, optional) — Whether to include all remote fields, including fields that Merge did not map to common models, in a normalized format.
- `include_shell_data` (boolean, optional) — Whether to include shell records. Shell records are empty records (they may contain some metadata but all other fields are null).
- `modified_after` (datetime, optional) — If provided, only objects synced by Merge after this date time will be returned.
- `modified_before` (datetime, optional) — If provided, only objects synced by Merge before this date time will be returned.
- `name` (string, optional) — If provided, will only return tickets with this name.
- `page_size` (integer, optional) — Number of results to return per page. The maximum limit is 100.
- `parent_ticket_id` (string, optional) — If provided, will only return sub tickets of the parent_ticket_id.
- `priority` (enum, optional) — If provided, will only return tickets of this priority.
  - Allowed values: `HIGH`, `LOW`, `NORMAL`, `URGENT`
- `remote_created_after` (datetime, optional) — If provided, will only return tickets created in the third party platform after this datetime.
- `remote_created_before` (datetime, optional) — If provided, will only return tickets created in the third party platform before this datetime.
- `remote_fields` (enum, optional) — Deprecated. Use show_enum_origins.
  - Allowed values: `priority`, `priority,status`, `priority,status,ticket_type`, `priority,ticket_type`, `status`, `status,ticket_type`, `ticket_type`
- `remote_id` (string, optional) — The API provider's ID for the given object.
- `remote_ids` (string, optional) — If provided, will only return tickets with these remote IDs (comma-separated).
- `remote_updated_after` (datetime, optional) — If provided, will only return tickets updated in the third party platform after this datetime.
- `remote_updated_before` (datetime, optional) — If provided, will only return tickets updated in the third party platform before this datetime.
- `show_enum_origins` (enum, optional) — A comma separated list of enum field names for which you'd like the original values to be returned, instead of Merge's normalized enum values. [Learn more](https://help.merge.dev/en/articles/8950958-show_enum_origins-query-parameter)
  - Allowed values: `priority`, `priority,status`, `priority,status,ticket_type`, `priority,ticket_type`, `status`, `status,ticket_type`, `ticket_type`
- `status` (string, optional) — If provided, will only return tickets of this status.
- `tags` (string, optional) — If provided, will only return tickets matching the tags; multiple tags can be separated by commas.
- `ticket_type` (string, optional) — If provided, will only return tickets of this type.
- `ticket_url` (string, optional) — If provided, will only return tickets where the URL matches or contains the substring

### Headers

- `X-Account-Token` (string, required) — Token identifying the end user.

## Response

### 200

- `next` (string, optional, nullable)
- `previous` (string, optional, nullable)
- `results` (list of Ticket, optional)

## Types

### Ticket

# The Ticket Object ### Description The `Ticket` object is used to represent a ticket, issue, task or case. ### Usage Example TODO

- `id` (string, optional)
- `remote_id` (string, optional, nullable) — The third-party API ID of the matching object.
- `created_at` (datetime, optional) — The datetime that this object was created by Merge.
- `modified_at` (datetime, optional) — The datetime that this object was modified by Merge.
- `name` (string, optional, nullable) — The ticket's name.
- `assignees` (list of string, optional) — The individual `Users` who are assigned to this ticket. This does not include `Users` who just have view access to this ticket. To fetch all `Users` and `Teams` that can access the ticket, use the `GET /tickets/{ticket_id}/viewers` [endpoint](https://docs.merge.dev/ticketing/tickets/#tickets_viewers_list).
- `assigned_teams` (list of string, optional) — The `Teams` that are assigned to this ticket. This does not include `Teams` who just have view access to this ticket. To fetch all `Users` and `Teams` that can access this ticket, use the `GET /tickets/{ticket_id}/viewers` [endpoint](https://docs.merge.dev/ticketing/tickets/#tickets_viewers_list).
- `creator` (string, optional, nullable) — The user who created this ticket.
- `due_date` (datetime, optional, nullable) — The ticket's due date.
- `status` (enum, optional, nullable) — The current status of the ticket. This field is an open enum: Merge can return a value outside this list when an integration provides one it does not map. Pass `show_enum_origins=status` to receive the integration's own value instead.
  - Allowed values: `OPEN`, `CLOSED`, `IN_PROGRESS`, `ON_HOLD`
- `description` (string, optional, nullable) — The ticket’s description. HTML version of description is mapped if supported by the third-party platform.
- `collections` (list of string, optional) — The `Collections` that this `Ticket` is included in.
- `ticket_type` (string, optional, nullable) — The sub category of the ticket within the 3rd party system. Examples include incident, task, subtask or to-do. This field is an open enum: Merge can return a value outside this list when an integration provides one it does not map. Pass `show_enum_origins=ticket_type` to receive the integration's own value instead.
- `account` (string, optional, nullable) — The account associated with the ticket.
- `contact` (string, optional, nullable) — The contact associated with the ticket.
- `parent_ticket` (string, optional, nullable) — The ticket's parent ticket.
- `attachments` (list of string, optional)
- `access_level` (enum, optional, nullable) — The description of who is able to access a given ticket, or where access is inherited from.
  - Allowed values: `COMPANY`, `PUBLIC`, `PRIVATE`, `COLLECTION`
- `permissions` (list of Permission, optional)
- `tags` (list of string, optional)
- `roles` (list of string, optional)
- `ticket_url` (string, optional, nullable) — The 3rd party url of the Ticket.
- `priority` (enum, optional, nullable) — The priority or urgency of the Ticket. This field is an open enum: Merge can return a value outside this list when an integration provides one it does not map. Pass `show_enum_origins=priority` to receive the integration's own value instead.
  - Allowed values: `URGENT`, `HIGH`, `NORMAL`, `LOW`
- `remote_created_at` (datetime, optional, nullable) — When the third party's ticket was created.
- `remote_updated_at` (datetime, optional, nullable) — When the third party's ticket was updated.
- `completed_at` (datetime, optional, nullable) — When the ticket was completed.
- `remote_was_deleted` (boolean, optional) — Indicates whether or not this object has been deleted in the third party platform. Full coverage deletion detection is a premium add-on. Native deletion detection is offered for free with limited coverage. [Learn more](https://docs.merge.dev/integrations/hris/supported-features/).
- `field_mappings` (TicketFieldMappings, optional, nullable)
- `remote_data` (list of RemoteData, optional, nullable)
- `remote_fields` (list of RemoteField, optional)

### Permission

# The Permission Object ### Description The `Permission` object is used to represent permissions that can be applied to users, roles, teams, collections, and tickets. ### Usage Example TODO

- `id` (string, optional)
- `remote_id` (string, optional, nullable) — The third-party API ID of the matching object.
- `created_at` (datetime, optional) — The datetime that this object was created by Merge.
- `modified_at` (datetime, optional) — The datetime that this object was modified by Merge.
- `effect` (enum, optional, nullable) — Outcome of this permission rule for matching users.
  - Allowed values: `ALLOWED`, `DENIED`, `INHERITED`
- `actions` (list of enum, optional, nullable) — Operations that this permission applies to. If the entity inherits permission from a parent entity, then this should be an empty array. In that case, the entity would inherit the parent entity’s actions.
  - Allowed values: `VIEW`, `CREATE`, `EDIT`, `DELETE`
- `applied_to_users` (list of string, optional)
- `applied_to_roles` (list of string, optional)
- `applied_to_teams` (list of string, optional)
- `applied_to_collections` (list of string, optional)
- `remote_was_deleted` (boolean, optional) — Indicates whether or not this object has been deleted in the third party platform. Full coverage deletion detection is a premium add-on. Native deletion detection is offered for free with limited coverage. [Learn more](https://docs.merge.dev/integrations/hris/supported-features/).
- `field_mappings` (PermissionFieldMappings, optional, nullable)

### TicketFieldMappings

- `organization_defined_targets` (map from string to any, optional)
- `linked_account_defined_targets` (map from string to any, optional)

### RemoteData

# The RemoteData Object ### Description The `RemoteData` object is used to represent the full data pulled from the third-party API for an object. ### Usage Example TODO

- `path` (string, required) — The third-party API path that is being called.
- `data` (any, optional) — The data returned from the third-party for this object in its original, unnormalized format.

### RemoteField

- `remote_field_class` (RemoteFieldClass, required)
- `value` (map from string to any, optional)

### PermissionFieldMappings

- `organization_defined_targets` (map from string to any, optional)
- `linked_account_defined_targets` (map from string to any, optional)

### RemoteFieldClass

- `id` (string, optional)
- `display_name` (string, optional)
- `remote_key_name` (string, optional)
- `description` (string, optional)
- `is_custom` (boolean, optional)
- `is_common_model_field` (boolean, optional)
- `is_required` (boolean, optional)
- `field_type` (enum, optional)
  - Allowed values: `string`, `number`, `date`, `datetime`, `bool`, `list`
- `field_format` (enum, optional)
  - Allowed values: `string`, `number`, `date`, `datetime`, `bool`, `list`
- `field_choices` (list of string, optional)
- `item_schema` (ItemSchema, optional)

### ItemSchema

- `item_type` (enum, optional)
  - Allowed values: `string`, `number`, `date`, `datetime`, `bool`, `list`
- `item_format` (enum, optional)
  - Allowed values: `string`, `number`, `date`, `datetime`, `bool`, `list`
- `item_choices` (list of string, optional)

## Examples

**Response**

```json
{
  "next": "cD0yMDIxLTAxLTA2KzAzJTNBMjQlM0E1My40MzQzMjYlMkIwMCUzQTAw",
  "previous": "cj1sZXdwd2VycWVtY29zZnNkc2NzUWxNMEUxTXk0ME16UXpNallsTWtJ",
  "results": [
    {
      "id": "0958cbc6-6040-430a-848e-aafacbadf4ae",
      "remote_id": "19202938",
      "created_at": "2021-09-15T00:00:00Z",
      "modified_at": "2021-10-16T00:00:00Z",
      "name": "Please add more integrations",
      "assignees": [
        "17a54124-287f-494d-965e-3c5b330c9a68"
      ],
      "assigned_teams": [
        "4857c306-c1f9-489e-a6b6-90902f736dfe"
      ],
      "creator": "string",
      "due_date": "2022-10-11T00:00:00Z",
      "status": "OPEN",
      "description": "Can you please add more integrations? It'll make syncing data much easier!",
      "collections": [
        "fb8c55b6-1cb8-4b4c-9fb6-17924231619d"
      ],
      "ticket_type": "incident",
      "account": "0958cbc6-6040-430a-848e-aafacbadf4ae",
      "contact": "65c345ba-6870-4974-87ba-dd31509c367a",
      "parent_ticket": "75b33d04-30d2-4f3e-be45-27838bc94342",
      "attachments": [
        "42747df1-95e7-46e2-93cc-66f1191edca5",
        "92f972d0-2526-434b-9409-4c3b468e08f0"
      ],
      "access_level": "PRIVATE",
      "permissions": [
        {}
      ],
      "tags": [
        "enterprise",
        "other-tag"
      ],
      "roles": [
        "21a54124-397f-494d-985e-3c5b330b8a68",
        "17a54124-287f-494d-965e-3c5b330c9a68"
      ],
      "ticket_url": "https://thirdpartysoftware.com/project/3/issue/1",
      "priority": "HIGH",
      "remote_created_at": "2021-11-10T00:00:00Z",
      "remote_updated_at": "2021-12-09T00:00:00Z",
      "completed_at": "2021-12-09T00:00:00Z",
      "remote_was_deleted": true,
      "field_mappings": {
        "organization_defined_targets": {
          "custom_key": "custom_value"
        },
        "linked_account_defined_targets": {
          "custom_key": "custom_value"
        }
      },
      "remote_data": [
        {
          "path": "/platform-endpoint",
          "data": null
        }
      ],
      "remote_fields": [
        {
          "remote_field_class": {
            "id": "string",
            "display_name": "string",
            "remote_key_name": "string",
            "description": "string",
            "is_custom": true,
            "is_common_model_field": true,
            "is_required": true,
            "field_type": "string",
            "field_format": "string",
            "field_choices": [
              "string"
            ],
            "item_schema": {
              "item_type": "string",
              "item_format": "string",
              "item_choices": [
                "string"
              ]
            }
          },
          "value": "string"
        }
      ]
    }
  ]
}
```

**SDK Code**

```python
import requests

url = "https://api.merge.dev/api/ticketing/v1/tickets"

querystring = {"include_remote_data":"true"}

headers = {
    "X-Account-Token": "X-Account-Token",
    "Authorization": "Bearer <token>"
}

response = requests.get(url, headers=headers, params=querystring)

print(response.json())
```

```javascript
const url = 'https://api.merge.dev/api/ticketing/v1/tickets?include_remote_data=true';
const options = {
  method: 'GET',
  headers: {'X-Account-Token': 'X-Account-Token', Authorization: 'Bearer <token>'}
};

try {
  const response = await fetch(url, options);
  const data = await response.json();
  console.log(data);
} catch (error) {
  console.error(error);
}
```

```go
package main

import (
	"fmt"
	"net/http"
	"io"
)

func main() {

	url := "https://api.merge.dev/api/ticketing/v1/tickets?include_remote_data=true"

	req, _ := http.NewRequest("GET", url, nil)

	req.Header.Add("X-Account-Token", "X-Account-Token")
	req.Header.Add("Authorization", "Bearer <token>")

	res, _ := http.DefaultClient.Do(req)

	defer res.Body.Close()
	body, _ := io.ReadAll(res.Body)

	fmt.Println(res)
	fmt.Println(string(body))

}
```

```ruby
require 'uri'
require 'net/http'

url = URI("https://api.merge.dev/api/ticketing/v1/tickets?include_remote_data=true")

http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true

request = Net::HTTP::Get.new(url)
request["X-Account-Token"] = 'X-Account-Token'
request["Authorization"] = 'Bearer <token>'

response = http.request(request)
puts response.read_body
```

```java
import com.mashape.unirest.http.HttpResponse;
import com.mashape.unirest.http.Unirest;

HttpResponse<String> response = Unirest.get("https://api.merge.dev/api/ticketing/v1/tickets?include_remote_data=true")
  .header("X-Account-Token", "X-Account-Token")
  .header("Authorization", "Bearer <token>")
  .asString();
```

```php
<?php
require_once('vendor/autoload.php');

$client = new \GuzzleHttp\Client();

$response = $client->request('GET', 'https://api.merge.dev/api/ticketing/v1/tickets?include_remote_data=true', [
  'headers' => [
    'Authorization' => 'Bearer <token>',
    'X-Account-Token' => 'X-Account-Token',
  ],
]);

echo $response->getBody();
```

```csharp
using RestSharp;

var client = new RestClient("https://api.merge.dev/api/ticketing/v1/tickets?include_remote_data=true");
var request = new RestRequest(Method.GET);
request.AddHeader("X-Account-Token", "X-Account-Token");
request.AddHeader("Authorization", "Bearer <token>");
IRestResponse response = client.Execute(request);
```

```swift
import Foundation

let headers = [
  "X-Account-Token": "X-Account-Token",
  "Authorization": "Bearer <token>"
]

let request = NSMutableURLRequest(url: NSURL(string: "https://api.merge.dev/api/ticketing/v1/tickets?include_remote_data=true")! as URL,
                                        cachePolicy: .useProtocolCachePolicy,
                                    timeoutInterval: 10.0)
request.httpMethod = "GET"
request.allHTTPHeaderFields = headers

let session = URLSession.shared
let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in
  if (error != nil) {
    print(error as Any)
  } else {
    let httpResponse = response as? HTTPURLResponse
    print(httpResponse)
  }
})

dataTask.resume()
```