Home/Atlassian REST API reference
Jira and Confluence Cloud REST API
Jira /rest/api/3/search returns 410: use search/jql
The classic JQL search endpoints were removed. A GET to /rest/api/3/search or /rest/api/2/search answers 410 with a message that names /rest/api/3/search/jql as the replacement. The new endpoint changes paging (tokens instead of startAt), the default fields (id only) and bounds (JQL must be restricted).
Endpoints
| Method | Path | What it does |
|---|---|---|
GET | /rest/api/3/search | Removed. The OpenAPI file marks it deprecated. |
GET | /rest/api/3/search/jql | The replacement search by query parameters. |
POST | /rest/api/3/search/jql | The replacement search by JSON body. |
Examples
GET /rest/api/3/search
The v3 classic search answers 410.
curl
curl -G \
-u "you@example.com:$ATLASSIAN_API_TOKEN" \
-H 'Accept: application/json' \
--data-urlencode 'jql=project = WEB' \
--data-urlencode 'maxResults=1' \
'https://your-domain.atlassian.net/rest/api/3/search'Python (requests)
import os
import requests
EMAIL = "you@example.com"
r = requests.get(
'https://your-domain.atlassian.net/rest/api/3/search',
auth=(EMAIL, os.environ["ATLASSIAN_API_TOKEN"]),
headers={'Accept': 'application/json'},
params={'jql': 'project = WEB', 'maxResults': '1'},
)
print(r.status_code, r.text)Response: HTTP 410
{
"errorMessages": [
"The requested API has been removed. Please migrate to the /rest/api/3/search/jql API. A full migration guideline is available at https://developer.atlassian.com/changelog/#CHANGE-2046"
],
"errors": {}
}Sent to Atlassian Cloud on .
GET /rest/api/2/search
The v2 classic search answers the same.
curl
curl -G \
-u "you@example.com:$ATLASSIAN_API_TOKEN" \
-H 'Accept: application/json' \
--data-urlencode 'jql=project = WEB' \
--data-urlencode 'maxResults=1' \
'https://your-domain.atlassian.net/rest/api/2/search'Python (requests)
import os
import requests
EMAIL = "you@example.com"
r = requests.get(
'https://your-domain.atlassian.net/rest/api/2/search',
auth=(EMAIL, os.environ["ATLASSIAN_API_TOKEN"]),
headers={'Accept': 'application/json'},
params={'jql': 'project = WEB', 'maxResults': '1'},
)
print(r.status_code, r.text)Response: HTTP 410
{
"errorMessages": [
"The requested API has been removed. Please migrate to the /rest/api/3/search/jql API. A full migration guideline is available at https://developer.atlassian.com/changelog/#CHANGE-2046"
],
"errors": {}
}Sent to Atlassian Cloud on .
GET /rest/api/3/search/jql
The replacement GET with explicit fields.
curl
curl -G \
-u "you@example.com:$ATLASSIAN_API_TOKEN" \
-H 'Accept: application/json' \
--data-urlencode 'jql=project = WEB AND summary ~ "REST API reference test" ORDER BY created ASC' \
--data-urlencode 'fields=summary' \
--data-urlencode 'maxResults=2' \
'https://your-domain.atlassian.net/rest/api/3/search/jql'Python (requests)
import os
import requests
EMAIL = "you@example.com"
r = requests.get(
'https://your-domain.atlassian.net/rest/api/3/search/jql',
auth=(EMAIL, os.environ["ATLASSIAN_API_TOKEN"]),
headers={'Accept': 'application/json'},
params={'jql': 'project = WEB AND summary ~ "REST API reference test" ORDER BY created ASC',
'fields': 'summary',
'maxResults': '2'},
)
print(r.status_code, r.text)Response: HTTP 200
{
"issues": [
{
"id": "10766",
"key": "WEB-55",
"fields": {
"summary": "REST API reference test issue"
}
},
{
"id": "10767",
"key": "WEB-56",
"fields": {
"summary": "REST API reference test issue2 - delete"
}
}
],
"isLast": true
}Sent to Atlassian Cloud on .
POST /rest/api/3/search/jql
The replacement POST with a JSON body and paging token.
curl
curl -X POST \
-u "you@example.com:$ATLASSIAN_API_TOKEN" \
-H 'Accept: application/json' \
-H 'Content-Type: application/json' \
--data '{
"jql": "project = WEB AND summary ~ \"REST API reference test\" ORDER BY created ASC",
"fields": [
"summary",
"status"
],
"maxResults": 1
}' \
'https://your-domain.atlassian.net/rest/api/3/search/jql'Python (requests)
import os
import requests
EMAIL = "you@example.com"
r = requests.post(
'https://your-domain.atlassian.net/rest/api/3/search/jql',
auth=(EMAIL, os.environ["ATLASSIAN_API_TOKEN"]),
headers={'Accept': 'application/json'},
json={'jql': 'project = WEB AND summary ~ "REST API reference test" ORDER BY created ASC',
'fields': ['summary', 'status'],
'maxResults': 1},
)
print(r.status_code, r.text)Response: HTTP 200
{
"issues": [
{
"key": "WEB-55"
}
],
"nextPageToken": "CkhjcmVhdGVkJmNyZWF0ZWQmT1JERVJfQVNDI0xvbmcmTVRjNU5UazNNek0xTlRZNU9BPT0lU3RyaW5nJlYwVkMlSW50Jk5UVT0QARiRle_CojQiSnByb2plY3QgPSBXRUIgQU5EIHN1bW1hcnkgfiAiUkVTVCBBUEkgcmVmZXJlbmNlIHRlc3QiIE9SREVSIEJZIGNyZWF0ZWQgQVNDKgJbXQ==",
"isLast": false
}Sent to Atlassian Cloud on .
POST /rest/api/3/search/approximate-count
Replaces the total that the old response held.
curl
curl -X POST \
-u "you@example.com:$ATLASSIAN_API_TOKEN" \
-H 'Accept: application/json' \
-H 'Content-Type: application/json' \
--data '{
"jql": "project = WEB"
}' \
'https://your-domain.atlassian.net/rest/api/3/search/approximate-count'Python (requests)
import os
import requests
EMAIL = "you@example.com"
r = requests.post(
'https://your-domain.atlassian.net/rest/api/3/search/approximate-count',
auth=(EMAIL, os.environ["ATLASSIAN_API_TOKEN"]),
headers={'Accept': 'application/json'},
json={'jql': 'project = WEB'},
)
print(r.status_code, r.text)Response: HTTP 200
{
"count": 34
}Sent to Atlassian Cloud on .
How it behaves
- GET /rest/api/3/search?jql=project = WEB answered 410 with errorMessages that say the API has been removed and point to /rest/api/3/search/jql and a changelog entry.
- GET /rest/api/2/search answered the identical 410, so switching to v2 does not help.
- The replacement returns issues and isLast, adds nextPageToken while more results exist, and has no total or startAt.
Where the documentation differs
GET /rest/api/3/searchSent to Atlassian Cloud, . The documentation: The OpenAPI file for GET /rest/api/3/search is marked deprecated and "currently being removed", with the responses 200, 400 and 401.
What happened: The endpoint answers 410, a status the reference does not list for it.
Pitfalls
- A 410 is permanent for that path, so retrying the same call cannot succeed.
- Expect only ids unless fields is set, and add a search restriction to the JQL.
- Code that used total to show a result count needs the approximate count endpoint.
- The search changelog entry (CHANGE-2046) is what the 410 message points to.
Questions and answers
Is there a v2 version of the new endpoint?
Yes. A POST to /rest/api/2/search/jql answered 200 in the run set.
Does the new endpoint take startAt?
Not in the reference parameters. Paging uses nextPageToken.