From LinkedIn API I got this hash:
> #<LinkedIn::Mash all=[#<LinkedIn::Mash api_standard_profile_request=#<LinkedIn::Mash headers=#<LinkedIn::Mash
> all=[#<LinkedIn::Mash name="x-li-auth-token" value="name:_nNI">]
> total=1> url="http://api.linkedin.com/v1/people/asdasfga">
> first_name="first name" headline="job position"
> id="id of user" industry="industry"
> last_name="last name" location=#<LinkedIn::Mash
> country=#<LinkedIn::Mash code="en"> name="country">
> site_standard_profile_request=#<LinkedIn::Mash
> url="http://www.linkedin.com/profile?viewProfile=&key=key_number&authToken=_nNI&authType=name&trk=api*a_12346*s_12346*">>]
> total=1>
Already long time I try to get the first_name, url and country, but still I can’t parse it.
Could anyone help me?
Thanks in advance
EDIT attempts:
linkedin.connections.each do |item|
puts item
end
gives
total
1
all
#<LinkedIn::Mash api_standard_profile_request=#<LinkedIn::Mash headers=#<LinkedIn::Mash all=[#<LinkedIn::Mash name=...
When I tried
linkedin.connections.api_standard_profile_request.each do |item|
puts item
end
then I got
undefined method `each' for nil:NilClass
try this: