Skip to content

Instantly share code, notes, and snippets.

@voxpelli
Created August 21, 2010 23:00
Show Gist options
  • Star 4 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save voxpelli/542989 to your computer and use it in GitHub Desktop.
Save voxpelli/542989 to your computer and use it in GitHub Desktop.
<?php
$provider = new stdClass;
$provider->disabled = FALSE; /* Edit this to true to make a default provider disabled initially */
$provider->name = 'linkedin';
$provider->title = 'LinkedIn';
$provider->url = 'https://api.linkedin.com';
$provider->consumer_advanced = array(
'signature method' => 'HMAC-SHA1',
'authentication realm' => '',
'request token endpoint' => '/uas/oauth/requestToken',
'authorization endpoint' => '/uas/oauth/authenticate',
'access token endpoint' => '/uas/oauth/accessToken',
);
$provider->mapping = array(
'fields' => array(
'uid' => array(
'resource' => 'https://api.linkedin.com/v1/people/~:(id,first-name,picture-url)',
'method post' => 0,
'field' => 'id',
),
'real name' => array(
'resource' => 'https://api.linkedin.com/v1/people/~:(id,first-name,picture-url)',
'method post' => 0,
'field' => 'first-name',
),
'avatar' => array(
'resource' => 'https://api.linkedin.com/v1/people/~:(id,first-name,picture-url)',
'method post' => 0,
'field' => 'picture-url',
),
),
'format' => 'xml',
);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment