additional LinkedIn Fields

Is it possible to import fields for user's Company Name and Position? If so, how can I do that?

Is saw this page but do not know what the OneAll field names, if they exist, would be to replace "gender" on this line:
update_user_meta ($user_data->id, 'gender', $identity->gender);
https://docs.oneall.com/plugins/guide/social-login-wordpress/

If the Social Login plugin as is doesn't have its own field names for company and position, maybe I can add them in?

In LinkedIn's API, it looks like the field selectors would be:
positions:(company:(name))
positions:(title)

Documentation from LinkedIn:
https://developer.linkedin.com/docs/fields/basic-profile
https://developer.linkedin.com/docs/fields/positions
https://developer.linkedin.com/docs/fields/companies
https://developer-programs.linkedin.com/documents/field-selectors
https://developer-programs.linkedin.com/documents/understanding-field-selectors

Thank you in advance for your quick reply.

Answers

  • Hi,
    We support Job Position (and can add more if needed), however the first thing to do is request proper access from LinkedIn. Please have a look at this discussion for more details.
    support.oneall.com/forums/discussion/comment/1701/#Comment_1701

    Regards.
  • Hi Frederic,

    I have the API public and secret keys from LinkedIn.

    Is adding this line of code to functions.php what is necessary for getting the position?
    update_user_meta ($user_data->id, 'positions:(title)', $identity->position);

    Please do add the company name retrieval functionality. How long do you think that will take to be implemented?

    Thank you!
  • Hi,
    The array $identity->organizations may already contain what you want.
    If present in the user's identity, it holds the organization, position, industry..., such as:
    [organizations] => Array
            (
                [0] => stdClass Object
                    (
                        [name] => oneall
                        [location] => Luxembourg
                        [industry] => Internet
                        [title] => Web Developer
                        [description] => Social network integration.
                        [startDate] => 2015-05
                    )
    
            )
    So, you could do something like (in the theme functions.php file, as you already found in the docs):
    update_user_meta ($user_data->id, 'current_org', $identity->organizations[0]->name);where 'current_org' is the field name in the database, and you can choose almost what you want. This is a rough indication, test if the organizations property is present before accessing it.

    Hope this helps.
    PS: Feel free to contact us by email for more details.
  • Hi Frederic,

    I tried emailing but I'm not sure if it went through. Please let me know the best email address to use.

    Thank you,

    Jonah
  • Hi Jonah,

    No, I did not see your email, maybe try: fpinel@oneall.com

    Thanks.

Welcome!

Please sign in to your OneAll account to ask a new question or to contribute to the discussions.

Please click on the link below to connect to the forum with your OneAll account.