$socialManager
$socialManager : \Social\Service\SocialManager
The manager that handles basic logic for the Social module
Class FoursquareProvider Social Media OAuth2 provider for FOURSQUARE
$socialManager : \Social\Service\SocialManager
The manager that handles basic logic for the Social module
__construct(\Social\Service\SocialManager $socialManager)
Constructor Instantiate (extending) class and pass Social manager and set the extending social provider name.
\Social\Service\SocialManager | $socialManager |
sendClientRequest(string $callback, array $queryParams) : array
Send Client Request Form client request URL with query params and send via Zend Client
string | $callback | the callback URL |
array | $queryParams | parameters to append to end of callback URL |
that contains the user profile
getUserProfile(\Zend\Http\Client $client, string $token) : array
Make new request to FOURSQUARE to get user profile Using the access token that FOURSQUARE returned for previous request
\Zend\Http\Client | $client | Zend Client that makes the HTTP request |
string | $token |
corresponding to the user
handleAccessTokenResponse(\Zend\Http\Client $client, \Social\Providers\Response $response) : array
Handle response after requesting access token from FOURSQUARE
\Zend\Http\Client | $client | Zend Client that makes the HTTP request |
\Social\Providers\Response | $response |
corresponding to the user
processUserProfile(\Social\Providers\Response $response) : array
Process the response that FOURSQUARE returned to the getUserProfile request
\Social\Providers\Response | $response |
if the response does not contain user profile
array containing user profile
checkReturnedQuery(array $params)
Check the query string provided by the social provider to ensure that it has the keys code and state and that the value of state corresponds to the CSRF value that was sent to the provider
array | $params | the params that need checking |
checkUserProfile(\Social\Providers\Zend\Http\Response $response) : \Social\Providers\JSON
CHeck that the returned response has the required parameters
\Social\Providers\Zend\Http\Response | $response |
when returned object does not conform to requirements
object