New Instance 404's on all API Endpoints

Hello all,

We have an integration that connects to an external system, recently we decided to spin up a completely new instance of JIRA to test with but are receiving 404s on every endpoint with a vague error message. We have a project setup and have added a few test tickets through the UI.

Here is an example request URL:
https://api.atlassian.com/ex/jira/{My_Cloud_Id}/rest/api/2/issue/createmeta

And and example response:

{
    "timestamp": "2022-08-01T15:55:18.251393Z",
    "status": 404,
    "error": "Not Found",
    "message": "No message available",
    "path": "/ex/jira/{My_Cloud_Id}/rest/api/2/issue/createmeta"
}

This is working perfectly fine on our old instance (not setup by me) and our client’s instances. Are we missing some configuration? We gave ourselves full admin rights though the permission system is very complicated and I could have easily missed something.

I am also just using basic authentication with an API key and Email, which also works fine for other instances.

I will note this is a trial account for now but from other forum posts it appears this should work just like a normal instance, did that change perhaps or are those other posts incorrect? I would expect different errors if it was just because of a trial though.

Any help would be greatly appreciated,

Thank you!

Hi @AlexHofer ,

This seems strange. I think the best way forward is for you to raise a support issue.

Regards,
Dugald

Hello @AlexHofer,

You said

But you’re using OAuth2 endpoints. You should use this API in https://developer.atlassian.com/cloud/jira/platform/rest/v2/api-group-issues/#api-rest-api-2-issue-createmeta-get

curl --request GET --url "https://<sitename>.atlassian.net/rest/api/2/issue/createmeta"

Does this work?

Regards,
James.

That also does not work, I just get an error saying basic authentication is deprecated. Basic auth using the URL I posted above works for me in our client instances and our company one, just not this new one.

The documentation also doesn’t seem to specify which kind of authentication you can use per endpoint though.

Hi @AlexHofer,

Sorry, I should have made that clearer. You need to use a token from

with

curl --user email@example.com:token --request GET --url "https://<sitename>.atlassian.net/rest/api/2/issue/createmeta"

James.

Ah ok that other way did work.

Why then does the other way I have been doing it not work for my new instance but works for the old instances and how do I ensure new instances work like old ones do?

I would prefer to be consistent and use the routes I posted. I will say we did use OAuth 2 for a while but ran into a ton of issues with our refresh tokens expiring early and had to switch to basic auth after months of support ticket back and forth. Could that be what is allowing us to use basic auth in those instances? That we had used OAuth previously?

Edit: Actually no, one of our customers was able to integrate after we had swapped over to basic auth and never used our OAuth 2 connection.

Hi @AlexHofer,

I can’t say exactly what’s going on, but I suspect the older instances haven’t had the deprecated authentication methods deactivated.

It would be better to use OAuth2. If you use a framework like the latest Spring Boot then it will take care of the token rotation for you.

But in general, stay away from using passwords and use tokens instead if you want to stick with Basic Authentication.

James.

Ah ok, looks like I need to go update all of that then. I hope the documentation is updated to reflect this issue.

We did use a framework for OAuth 2 but intermittently our refresh token was coming back already expired. After a month or so of going back and forth in a support ticket we just moved away from OAuth because we couldn’t wait any longer and the scoping at the time was in flux so we weren’t sure how to proceed, there appears to be some others in the forum experiencing the same issue but so far so no one has managed to find a fix for that issue. If one is ever found we will move back to it!