Read, create and update your tickets and your releases from your scripts, your CI or your own tools. Every request of this page can be sent for real with your API key, and gives you its code in cURL, PHP, Node.js and Python.
curl "https://www2.ubugtrack.com/api/YOUR_API_KEY/project/12/tickets/?filter_status=open"
The API key identifies you: a request made with your key acts as you, on all your projects, with your rights in each project. It is unique for your account.
The URL says what is done. .../tickets/ lists the tickets, .../newticket/ creates one, .../ticket/42/update updates ticket #42. The HTTP method (GET, POST...) changes nothing: there is no action hidden in it. Each endpoint of this page is marked with what it does:
Nothing can be deleted with the API.
https://www2.ubugtrack.com/api/{api_key}/..., in HTTPS. The ids (project, ticket, release version) are in the URL, URL encoded: version 1.2 RC1 → 1.2%20RC1.filter_status, result_limit...): in the URL (?filter_status=open) or in the body, as JSON or form fields.Content-Type: application/json. Most tools can only send a body with POST: the code samples use it.success (true or false) and message ("Success" or the error). The HTTP status is always 200: check success."id": "42"), except markdown (boolean), labels (array) and total (number). In the requests, numbers can be sent as numbers or strings.date_created is YYYYMMDD ("20261105"), time_updated a Unix timestamp in seconds.Returned by List tickets, Get a ticket and Update a ticket.
| Field | Type | Description |
|---|---|---|
| id | string | Number of the ticket in the project (#42). |
| date_created | string | Creation date, YYYYMMDD. |
| time_updated | string | Last change, Unix timestamp. |
| title | string | Title. |
| description | string | Description. < > come as < >. |
| markdown | boolean | The description is Markdown. |
| status | string | "0" to "6", see statuses. |
| priority | string | "0" to "4", see priorities. |
| labels | array | Names of the labels (3 max). |
| label1..3 | string | null | Ids of the labels. |
| external_id | string | Id in another tool. |
| assigned_displayname | string | null | Name of the assignee, null if nobody. |
| release_id | string | Id of its release, "0" if none. |
{
"id": "42",
"date_created": "20261105",
"time_updated": "1793923200",
"title": "Crash when I click on Login",
"description": "Steps to reproduce: ...",
"markdown": true,
"status": "1",
"priority": "2",
"label1": "3",
"label2": null,
"label3": null,
"labels": ["Bug"],
"external_id": "JIRA-1234",
"assigned_displayname": "Alice",
"release_id": "0"
}
In the requests, give the number or the name. The responses always give the number.
| Value | Status | Name in requests |
|---|---|---|
| 0 | Waiting | waiting |
| 1 | Open | open |
| 2 | In progress | in_progress |
| 3 | Fixed/Done | fixed |
| 4 | Ready for Testing | ready_for_testing |
| 5 | Closed | closed |
| 6 | Won't Do | wont_do |
| Value | Priority | Name in requests |
|---|---|---|
| 0 | Low | low |
| 1 | Normal | normal |
| 2 | High | high |
| 3 | Urgent | urgent |
| 4 | Emergency | emergency |
The API applies your role in each project, exactly like the website.
| Role | Read tickets | Create tickets | Update tickets | Create releases |
|---|---|---|---|---|
| Admin | All | Yes | All | Yes |
| Developer | All | Yes | All | Yes |
| Reporter | All | Yes | The ones he created | No |
| Viewer | All | No | No | No |
| External Reporter | The ones he created | Yes | The ones he created | No |
| Not a member (public project) | All | No | No | No |
An error answers "success": false and explains the problem in message:
{
"success": false,
"message": "Invalid API Key"
}
| Message | Why |
|---|---|
Missing project API Key | No API key in the URL. |
Invalid API Key | The key doesn't exist, or it was regenerated or revoked. |
Invalid request | Unknown URL: check the path. |
Empty project ID, Invalid project ID | The project doesn't exist, or it is private and you are not a member. |
Empty ticket ID, Invalid ticket ID | The ticket doesn't exist in this project (or, for an External Reporter, it is not his). |
Invalid action ... | Unknown action after the ticket id: only update exists. |
Invalid Json Content | The body is missing or is not a JSON object. |
Invalid filter_status, Invalid status: ..., Invalid priority: ... | A status or a priority that doesn't exist. |
Nothing to update: ... | The body of an update has none of the fields that can change. |
You are not allowed to update this ticket | Your role doesn't allow it (see permissions). |
No ticket created: ... | No title nor description, or your role doesn't allow it. |
Ticket not created: ... | The projects of its owner reached the tickets limit of their plan (500 for all their projects together on Free). When some tickets of the request were created first, they are returned with this text in warning. |
Missing version and include_mode, Invalid version, Invalid include mode | Wrong body for a new release. |
Only the Admins and Developers of the project can create a release | Your role doesn't allow it. |
Unknown release ... | No release with this version name or id in the project. |
The projects you are a member of: the ones you own, and the ones you were invited to, directly or through a group. Their id is used in all the other requests.
No parameter.
Every user.
{
"success": true,
"message": "Success",
"projects": [
{
"id": "12",
"name": "My App",
"user_owner_id": "345"
}
]
}| Field | Type | Description |
|---|---|---|
| projects[].id | string | Id of the project. |
| projects[].name | string | Name of the project. |
| projects[].user_owner_id | string | Id of the user who owns the project. |
One project: a project you are a member of, or a public project.
| Parameter | Type | Description |
|---|---|---|
| project_idin the URL | integer required | Id of the project, given by List projects. |
The members of the project. Anyone for a public project.
{
"success": true,
"message": "Success",
"project": {
"id": "12",
"name": "My App",
"user_owner_id": "345"
}
}| Field | Type | Description |
|---|---|---|
| project | object | Same fields as in List projects. |
Errors: Invalid project ID
The tickets of a project, by pages of 50 (up to 100). By default the tickets that are not Closed or Won't Do, sorted by status, then priority (highest first), then the newest first.
| Parameter | Type | Description |
|---|---|---|
| project_idin the URL | integer required | Id of the project, given by List projects. |
| filter_statusoption: URL or body | string optionaldefault: not closed | Empty: every ticket that is not Closed or Won't Do. all: every ticket. A status (number or name, e.g. 1 or open). 100: Open and In progress. 101: every status but In progress. 102: the tickets in a release. |
| filter_releaseoption: URL or body | string optional | Version name of a release: its tickets, whatever their status (1000 max). filter_status, result_start, result_limit and order are then ignored. |
| result_startoption: URL or body | integer optionaldefault: 0 | Position of the first ticket returned (offset), to get the next pages. |
| result_limitoption: URL or body | integer optionaldefault: 50 | Number of tickets returned, 100 max. |
| orderoption: URL or body | integer optionaldefault: status | 1 newest first, 2 oldest first, 3 last updated first, 4 last updated last, 5 highest priority first, 6 lowest priority first. Default: status, then priority, then newest (last updated first with filter_status=5). |
The members of the project, anyone for a public project. An External Reporter only gets the tickets he created.
{
"success": true,
"message": "Success",
"total": 128,
"tickets": [
{
"id": "42",
"date_created": "20261105",
"time_updated": "1793923200",
"title": "Crash when I click on Login",
"description": "Steps to reproduce: ...",
"markdown": true,
"status": "1",
"priority": "2",
"label1": "3",
"label2": null,
"label3": null,
"labels": ["Bug"],
"external_id": "JIRA-1234",
"assigned_displayname": "Alice",
"release_id": "0"
}
]
}| Field | Type | Description |
|---|---|---|
| total | number | Number of tickets that match the filter, all pages together. Next page while result_start + result_limit < total. |
| tickets[] | array | The tickets of the page. |
Errors: Invalid project ID, Invalid filter_status
{"filter_status": "open", "result_limit": 20}) or as form fields, instead of the URL.One ticket of a project.
| Parameter | Type | Description |
|---|---|---|
| project_idin the URL | integer required | Id of the project, given by List projects. |
| ticket_idin the URL | integer required | Number of the ticket in the project: #42 → 42. |
The members of the project, anyone for a public project. An External Reporter only gets the tickets he created.
{
"success": true,
"message": "Success",
"ticket": {
"id": "42",
"date_created": "20261105",
"time_updated": "1793923200",
"title": "Crash when I click on Login",
"description": "Steps to reproduce: ...",
"markdown": true,
"status": "1",
"priority": "2",
"label1": "3",
"label2": null,
"label3": null,
"labels": ["Bug"],
"external_id": "JIRA-1234",
"assigned_displayname": "Alice",
"release_id": "0"
}
}| Field | Type | Description |
|---|---|---|
| ticket | object | The ticket. |
Errors: Invalid project ID, Invalid ticket ID
Change some fields of a ticket. Only the fields given in the JSON body change, the others keep their value.
| Parameter | Type | Description |
|---|---|---|
| project_idin the URL | integer required | Id of the project, given by List projects. |
| ticket_idin the URL | integer required | Number of the ticket in the project: #42 → 42. |
| titleJSON body | string optional | New title. HTML tags and double quotes are removed. |
| descriptionJSON body | string optional | New description: replaces the whole description. |
| markdownJSON body | boolean optional | true: the description is displayed as Markdown. |
| statusJSON body | integer | string optional | A status: number (2) or name (in_progress). |
| priorityJSON body | integer | string optional | A priority: number (3) or name (urgent). |
| external_idJSON body | string optional | Id of the ticket in another tool, 32 characters max. |
{
"status": "fixed",
"priority": 2,
"external_id": "JIRA-1234"
}Admin and Developer: every ticket. Reporter and External Reporter: the tickets they created. Not a Viewer.
{
"success": true,
"message": "Success",
"ticket": { ...the ticket after the update... }
}| Field | Type | Description |
|---|---|---|
| ticket | object | The ticket after the update. |
Errors: Invalid ticket ID, Invalid Json Content, You are not allowed to update this ticket, Invalid status: ..., Invalid priority: ..., Nothing to update: ...
Create a ticket, or several at once. You are the creator of the ticket and you receive its notifications. The integrations of the project (Slack...) are notified like for a ticket created on the website.
| Parameter | Type | Description |
|---|---|---|
| project_idin the URL | integer required | Id of the project, given by List projects. |
| titleJSON body | string optional | Title. A title or a description is required. HTML tags and double quotes are removed. |
| descriptionJSON body | string optional | Description. < and > are kept as text (returned as < >). |
| markdownJSON body | boolean optionaldefault: false | true: the description is displayed as Markdown. |
| statusJSON body | integer | string optionaldefault: 0 (Waiting) | A status: number or name. The words of other tools are understood too (to do, in review, done...): handy for an import. Not understood: Waiting. |
| priorityJSON body | integer | string optionaldefault: 1 (Normal) | A priority: number or name (medium and critical are understood too). Not understood: Normal. |
| external_idJSON body | string optional | Id of the ticket in another tool, 32 characters max. |
| fixed_in_releaseJSON body | string optional | Version name of the release that contains the ticket. The release is created if it doesn't exist. Admin and Developer only, ignored for the other roles. |
| open_in_releaseJSON body | string optional | Version in which the bug was found (free text). |
{
"title": "Crash when I click on Login",
"description": "Steps to reproduce: ...",
"markdown": true,
"status": "open",
"priority": "high",
"external_id": "JIRA-1234"
}Several tickets in one request: put them in a tickets array.
{
"tickets": [
{ "title": "First ticket", "priority": 2 },
{ "title": "Second ticket", "status": "open" }
]
}Admin, Developer, Reporter and External Reporter. Not a Viewer.
{
"success": true,
"message": "Success",
"ticket_id": "43",
"ticket_ids": ["43", "44"]
}| Field | Type | Description |
|---|---|---|
| ticket_id | string | Number of the (first) ticket created. |
| ticket_ids | array | Numbers of all the tickets created. A ticket without title nor description is skipped. |
Errors: Invalid Json Content, No ticket created: ..., Ticket not created: ...
Create a release and put the tickets that are done in it, e.g. at the end of your build. Only the tickets that are not in a release yet are included. If the version already exists, it is reused and the tickets are added to it. The integrations of the project (Slack...) are notified when tickets are included.
| Parameter | Type | Description |
|---|---|---|
| project_idin the URL | integer required | Id of the project, given by List projects. |
| versionJSON body | string required | Version name of the release. |
| include_modeJSON body | integer optionaldefault: 0 | Tickets put in the release: 0 none, 1 the Closed tickets, 2 the Fixed/Done, Ready for Testing and Closed tickets. |
{
"version": "1.2.4",
"include_mode": 2
}Admin and Developer.
{
"success": true,
"message": "Success",
"release_id": "87"
}| Field | Type | Description |
|---|---|---|
| release_id | string | Id of the release (new or existing). |
Errors: Missing version and include_mode, Invalid version, Invalid include mode, Only the Admins and Developers of the project can create a release
The tickets of a release, one per line: #42 Closed Crash when I click on Login, sorted by status. Without version: the tickets Fixed/Done, Ready for Testing or Closed that are not in a release yet (what the next release will contain).
| Parameter | Type | Description |
|---|---|---|
| project_idin the URL | integer required | Id of the project, given by List projects. |
| formatin the URL | string required | releasenote: JSON. releasenotetext: plain text, only the lines (handy in a build script). |
| versionin the URL | string optional | Version name of the release (1.2.4) or its id. Empty: the tickets done that are not in a release yet. |
The members of the project, anyone for a public project.
{
"success": true,
"message": "Success",
"release": { "id": "87", "version": "1.2.4" },
"releasenote": "#42 Closed Crash when I click on Login\n#45 Fixed/Done Export to CSV\n"
}| Field | Type | Description |
|---|---|---|
| release | object | null | The release: id and version. null without version. |
| releasenote | string | The lines of the release note. |
Errors: Invalid project ID, Unknown release ...