我正在使用gem 'linkedin', :git => "git://github.com/pengwynn/linkedin.git"
当我创建客户端并获取配置文件时,我得到以下值
headline: url: last_name: first_name:summary
我的问题是如何获得用户的
picture-url,public_profile_url: location: country: school_name: degree: field_of_study: start_date: end_date:
答案 0 :(得分:0)
使用picture_url如下
client.profile(:fields => [:headline,:first_name,:last_name,:picture_url,:educations,:positions])client.profile(:fields => [:headline,:first_name,:last_name ,:picture_url,:educations,:positions])
答案 1 :(得分:0)
有关您可以使用的所有字段的列表,请参阅LinkedIn https://developer.linkedin.com/documents/profile-fields
上的文档#Gemfile
gem 'linkedin-oauth2', '~> 1.0.0'
# Other file
api = LinkedIn::API.new(linkedin.token)
profile = api.profile(
fields: [
:headline,
:first_name,
:last_name,
:email_address,
:phone_numbers,
:im_accounts,
:industry,
:main_address,
:primary_twitter_account,
:picture_url,
:public_profile_url,
:positions
]
)