Trying to fix an old script that used Basic Auth to connec to JIRA.
I see Basic Auth is no longer supported.
I read the following but although the queries return 200, they return no data.
https://developer.atlassian.com/cloud/jira/platform/basic-auth-for-rest-apis/
Here is the curl and output when using "-u":
curl -D- \
-u serge.prud.homme@erxxxxxn.com:COb....64A \
-X GET \
-H "Content-Type: application/json" \
https://NAME.atlassian.net/rest/api/2/search?reporter=serge.prudhomme
HTTP/2 200
server: AtlassianProxy/1.15.8.1
vary: Accept-Encoding
cache-control: no-cache, no-store, no-transform
content-type: application/json;charset=UTF-8
strict-transport-security: max-age=315360000; includeSubDomains; preload
date: Wed, 05 Feb 2020 13:22:12 GMT
atl-traceid: fbxxxxxxxxxxxxxx
x-arequestid: dfc1xxxxxxxxxxxxxxx8c3ea
x-xss-protection: 1; mode=block
timing-allow-origin: *
x-content-type-options: nosniff
set-cookie: atlassian.xsrf.token=BFK5-xxxxxxxxxxxxxxxxxxxxxxxx_lout; Path=/; Secure
{"startAt":0,"maxResults":50,"total":0,"issues":[]}
Same results if I try to create the header myself:
curl -D- \
-X GET \
-H "Authorization: Basic c2VyZ2UucHJ...2NSbWQ4OFF4TVAxbnJKS1AyNjRB" \
-H "Content-Type: application/json" \
https://NAME.atlassian.net/rest/api/2/search?reporter=serge.prudhomme
HTTP/2 200
server: AtlassianProxy/1.15.8.1
vary: Accept-Encoding
cache-control: no-cache, no-store, no-transform
content-type: application/json;charset=UTF-8
strict-transport-security: max-age=315360000; includeSubDomains; preload
date: Wed, 05 Feb 2020 13:23:37 GMT
atl-traceid: 70xxxxxxxxxxxxxx
x-arequestid: fa0a03xxxxxxxxxxxxxxxxxxx
x-xss-protection: 1; mode=block
timing-allow-origin: *
x-content-type-options: nosniff
set-cookie: atlassian.xsrf.token=BFK5xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxt; Path=/; Secure
{"startAt":0,"maxResults":50,"total":0,"issues":[]}