How to develop an OAuth2 client plugin in joomla

46 views Asked by At

I'm developing a plugin for a component. this plugin needs to request datas from rest API and for doing it needs OAuth2 authentication.

As you probably know, after the authentication you will be redirected to your site with a code in the url (authorization code) that i need to store.

I have a problem with the redirect URI.

I can not use as redirect URI this url that is were i write my code:

https://www.example.com/administrator/index.php?option=com_plugins&view=plugin&layout=edit&extension_id={id-plugin} 

but the authentication is accepting as redirect URI urls likes:

https://www.example.com/administrator

After the authorization the Url will be:

https://www.example.com/?code=iS0vynEEvRFA9i6kZ8gvNDnnOGE...
0

There are 0 answers