You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
what I'm current struggle is have providers returning common interface with basic data like
firstName, lastName, email, and image
My suggestion is create different interfaces and the providers implements those interfaces for example.
ResourceOwnerFirstNameInterface
ResourceOwnerLastNameInterface
ResourceOwnerEmailInterface
ResourceOwnerImageUrlInterface
Then I can use a simple code from my side, expecting the correct fields for each provider, because for now we do not have a pattern for providers with basic info.
As I didn't get any feedback in that repository, I was planning create a repository with those interfaces for example oauth2-contracts, and Open a PR here with adding this repository in your dependencies, and for the others libaries I'll do the same
Note: Note for all of them, just for want I'm using atm, But it can be implement easily for any other provider.
then I would like to know if does it make sense for you? if yes I would create that repository and Open a pull request with this feature!
The text was updated successfully, but these errors were encountered:
First step
My current suggestion started in this issue: thephpleague/oauth2-client#958
what I'm current struggle is have providers returning common interface with basic data like
firstName
,lastName
,email
, and imageMy suggestion is create different interfaces and the providers implements those interfaces for example.
Then I can use a simple code from my side, expecting the correct fields for each provider, because for now we do not have a pattern for providers with basic info.
some providers use the email field with
getEmail()
and other withgetUpn()
like in this one: https://github.com/TheNetworg/oauth2-azure/blob/master/src/Provider/AzureResourceOwner.php#L61Second step
As I didn't get any feedback in that repository, I was planning create a repository with those interfaces for example
oauth2-contracts
, and Open a PR here with adding this repository in your dependencies, and for the others libaries I'll do the sameNote: Note for all of them, just for want I'm using atm, But it can be implement easily for any other provider.
then I would like to know if does it make sense for you? if yes I would create that repository and Open a pull request with this feature!
The text was updated successfully, but these errors were encountered: