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

How to get and use access tokens for api requests #3370

Closed
a-waider opened this issue Oct 23, 2024 · 3 comments
Closed

How to get and use access tokens for api requests #3370

a-waider opened this issue Oct 23, 2024 · 3 comments
Labels
setup issue possibly or definitely an issue with the user setup

Comments

@a-waider
Copy link

Issue

Hello,

in addition to #3249 I want to create a service which syncs the recipes with KptnCook. I was already able to download the recipes from KptnCook and now need to upload them via the API to Tandoor.

All API requests should be behind some authentication and I found two different APIs for that purpose:

  • /api-auth-token: Gives me a permanent redirect which then gives me a 405 with this response {"detail":"Method \"GET\" not allowed."}
curl --data '{"username":"username","password":"password"}' https://tandoor.dev/api-token-auth -v -L
  • /api/access-token: Gives me a 403 with this response {"detail":"Authentication credentials were not provided."}
curl --data '{"username":"username","password":"password"}' https://tandoor.local.haus/api/access-token -v -L

Could someone elaborate how to get an API token?

Also I didn't saw any references on how to use these API tokens. Is the usage documented anywhere?

Thanks!

Tandoor Version

1.5.20

OS Version

Docker

Setup

Docker / Docker-Compose

Reverse Proxy

Traefik

Other

No response

Environment file

No response

Docker-Compose file

No response

Relevant logs

No response

@a-waider a-waider added the setup issue possibly or definitely an issue with the user setup label Oct 23, 2024
@smilerz
Copy link
Collaborator

smilerz commented Oct 23, 2024

Under the api section of /settings/

@smilerz smilerz closed this as completed Oct 23, 2024
@a-waider
Copy link
Author

@smilerz There is no section called /settings

@smilerz
Copy link
Collaborator

smilerz commented Oct 23, 2024

@smilerz There is no section called /settings

That's the url. Or you can navigate via the menu.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
setup issue possibly or definitely an issue with the user setup
Projects
None yet
Development

No branches or pull requests

2 participants