Get object of protected issue

Hi, community!
I’m trying to get issue’s object on ACE. My code is:

        url: `/rest/api/3/issue/${issueId}`,
      function (err, response, body) {
        if (err) {
          console.log(response.statusCode + ": " + err);
          res.send("Error: " + response.statusCode + ": " + err);
        } else {
          const bodyData = JSON.parse(body);

It works fine in all cases except for restricted issues of team projects. I also tried using


But I’m getting the same error in all cases:

errorMessages: [ 'Issue does not exist or you do not have permission to see it.' ],
errors: {}

Can you guys help me? I just wanna get project id and expect to get this information from the issue’s object. Can you prompt another way to request it?