Answer the question
In order to leave comments, you need to log in
Authentication via REST API by direct request?
I decided to try RestAPI in PHP.
The framework chose lemonade.
I'm trying to put together a simple authentication system.
The request looks something like this 127.0.0.1/uchet/api/v1.0/auth/ivan/123
I'm confused by passing the password to the URL, is this allowed at all, can it be somehow different?
Answer the question
In order to leave comments, you need to log in
Use JWT, just remember that this is not authentication, but just a token format that provides a certain level of trust. And not in get query string, but headers.
Especially for those who advise POST - read what REST Verbs are, why they are needed and about caching. Caching GET is critical for the API, if you use POST to get data, and not to write, it is no longer REST.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question