#4764 Getting an issue using and API and Authentication token results in EINVALIDTOK
Closed: Fixed 4 years ago by jlanda. Opened 4 years ago by cverna.

When trying to get a specific issue using the API, if I am using a Auth token in the headers of the request the response returns a EINVALIDTOK error.

The token I used had all the permission toggled.

It should be possible to query a project issue with a token.

To reproduce

import httpx

url = "https://pagure.io//api/0/releng/failed-composes/issue/1"
headers = {"Authorization": f"token {TOKEN}"}

with httpx.Client(headers=headers) as client:
    r = client.get(url)

print(r.json())

Metadata Update from @jlanda:
- Issue assigned to jlanda

4 years ago

Metadata Update from @jlanda:
- Issue tagged with: bug

4 years ago

issue viewing endpoint is limited to project tokens. I'll fix that now

Metadata Update from @jlanda:
- Issue close_status updated to: Fixed
- Issue status updated to: Closed (was: Open)

4 years ago

Login to comment on this ticket.

Metadata
Related Pull Requests
  • #4766 Merged 4 years ago