E
E
Etmac2015-12-15 20:12:35
PHP
Etmac, 2015-12-15 20:12:35

How to make authorization using the API?

I'm new, so literally today I began to deal with the API. What you need to read / learn to work with API for example vk or facebook in order to create a simple authorization (I think this will be the most correct for a start). I looked at some examples and did not understand the implementation a little. I also understand that you need to be able to work with json , a little bit clearer with this, but what role does json play in user authorization? Storing access_token, id , username and password? I'm looking forward to your answers, thanks in advance!

Answer the question

In order to leave comments, you need to log in

1 answer(s)
W
wol_fi, 2015-12-15
@Etmac

The implementation is quite simple.
You send the user for authorization, he comes to you with a code (if successful), send the code to the authorization server - you get a token. Json/xml/plain text is just a way to serialize data, don't worry about it. You need to store the token only if you use it (make requests to api), but if you have a simple registration through the social network, then it is enough to get the user ID once, and that's it.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question