Hi @Arpan Pandey
Could you explain in more detail what you're trying to do?
I'm trying to create a CLI so client side things
But I need a JWT to use client-side auth
I don't know how to create a JWT without opening a browser
What version of Appwrite are you using?
Cloud
1.1.2
Okay mind if I ask why you're using JWT? Can't you use the normal email/password auth method?
After I get a session
With email password
How do I use it to perform actions on user's behalf?
Ah okay that's what you want to do. Okay let me just check this out real quick.
As far as I can see in the docs, there are no docs for REST.
Are you restricted to using REST, or can you use something else?
I can use GraphQL
Or anything that doesn't need a browser or native app
GraphQL is not available in cloud
Web, Flutter, Apple and Android are the only methods available for v1.1.2
So I should use external auth?
And then maybe link it using Auth0?
I didn't understand
I am saying I think I need to use an external auth provider
Ah yes. The current cloud version doesn't support what you need, so it's best to go for external auth.
Ok, thanks a ton!
you would have to call the create email session API manually and grab the cookie so that it can be used in the rest of the CLI tool.
See how we're extracting the cookie here: https://github.com/appwrite/sdk-for-cli/blob/b4619977eb95ca6650aa5291eb6a26d6bfa46eda/lib/client.js#L196
Recommended threads
- Appwriter Linux Key Bindings
Any tips for configuring appwriter for ubuntu? Actually the keybindings are tightly binded to either windows or mac. Working well on windows but in ubuntu some ...
- Admin Impersonating Clients?
I have a client that needs to use the admin User, to impersonate the Clients in order to debug better the App and the services that they are providing, could yo...
- create project api-rest
Hello good afternoon, I'm developing a project where I need to create a project by apirest, but I'm stuck with this "projects.read" permission, can I change my ...