Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Change request API routes cannot be called with Api-Key auth prefix #5146

Open
3 of 4 tasks
rolodato opened this issue Feb 20, 2025 · 0 comments
Open
3 of 4 tasks

Change request API routes cannot be called with Api-Key auth prefix #5146

rolodato opened this issue Feb 20, 2025 · 0 comments
Labels
bug Something isn't working

Comments

@rolodato
Copy link
Member

How are you running Flagsmith

  • Self Hosted with Docker
  • Self Hosted with Kubernetes
  • SaaS at flagsmith.com
  • Some other way (add details in description below)

Describe the bug

According to our API docs, workflows endpoints such as Get change request by ID can be called with an Admin API key. However, calling them with Authorization: Api-Key ... returns a 401:

{"detail":"Valid Master API Key not found."}

Steps To Reproduce

curl 'https://api.flagsmith.com/api/v1/features/workflows/change-requests/8048/' -H 'User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:135.0) Gecko/20100101 Firefox/135.0' -H 'Accept: application/json' -H 'Accept-Language: en-US,en;q=0.7,es-AR;q=0.3' -H 'Accept-Encoding: gzip, deflate, br, zstd' -H 'Referer: https://app.flagsmith.com/' -H 'AUTHORIZATION: Api-Key ...' -H 'Origin: https://app.flagsmith.com' -H 'Connection: keep-alive' -H 'Sec-Fetch-Dest: empty' -H 'Sec-Fetch-Mode: cors' -H 'Sec-Fetch-Site: same-site' -H 'Priority: u=0' -H 'TE: trailers'

Expected behavior

Accept both Api-Key and Token prefixes for all Admin API endpoints.

Screenshots

No response

@rolodato rolodato added the bug Something isn't working label Feb 20, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant