LinkedIn API feeds - linkedin

I'm looking into an issue where a clients LinkedIn feeds on their website have stopped showing. Debugging the problem I've found that I get a 403 error shown below:
Member xxxxxx does not have permission to get company xxxxx
As the LinkedIn authentication process can be quite difficult to comprehend, I had a look online to see if others have had the same problem, and managed to find this. It suggests there have been recent changes to the LinkedIn API and users are now required to be the administrator of the company. What exactly does this mean?
From the very beginning we have simply been accessed the feeds by generating a url like this:
https://api.linkedin.com/v1/companies/xxxx/updates?oauth2_access_token=ACCESS_TOKEN
This has worked in the past. Do we need to regenerate the Secret and API keys?
Update
Looking at the announced changes here:
https://developer.linkedin.com/support/developer-program-transition
It suggests that the following endpoint will still work (which is exactly what I have):
/v1/companies/{id}
So I'm not sure what I'm missing.

is the access token generated by a account witch is Admin of that company page?
If not hen you will get 403.
The requester needs to be admin of that comapny page in order to get company updates.

Related

Getting r_fullprofile access to the Linkedin API

I am currently using a linkedin API with r_lightprofile in my application.
Two months ago, I sent a request for access to r_fullprofile using the Partner Program form.
https://business.linkedin.com/marketing-solutions/contact-us
http://prntscr.com/opfnpd
I also sent a request to the Marketing Developer Platform, but the request is still pending (http://prntscr.com/opfvfx)
After all this, I got an email with a form to fill out information about the company.
But after filling out the form, I did not receive an answer that the company is suitable or not suitable for full access.
1) How long does it usually take to get access?
2) Does the linkedin API have support? Email, Live chat or something else?
3) Have I done everything for access? Maybe I missed something?
4) Does Linkedin send an email in case of failure?
It's been a long way for me too, I'll give you some random tips:
Make sure your app is connected to a LinkedIn company page and that the status is Verified. To do this, from the app dashboard, add to the Team members an administrator of the LinkedIn company page (as Admin member) and let him access the app dashboard. He should be able to see a Verify button to confirm the authenticity of the app.
The only support that was really helpful to me was Zendesk.

How can I change a LinkedIn app's permissions?

I have a LinkedIn app which can access the LinkedIn v2 API (tested with v2 endpoints), having the following privileges (scopes) according to the LinkedIn Developer Portal:
r_ad_campaigns
r_basicprofile
rw_organization.
The application is already enrolled in the Marketing Partner Program as far as my knowledge goes.
Regarding the above, I would like to have two questions/requests in which I would like to ask for your help.
I would like to modify the app permissions (scopes) to be the following:
r_liteprofile
r_emailaddress
r_member_social
w_member_social
rw_organization_admin
w_organization_social
r_organization_social
r_organization_lookup
rw_ads
r_ads_reporting
Currently there is no way to do so via the developer platform, and the LinkedIn support sent me here, so my question is: how can I get the app's privileges changed?
Interestingly enough, with the current set of privileges I was able to get an auth token for a given user for the r_emailaddress scope, but when I tried to call either https://api.linkedin.com/v2/clientAwareMemberHandles?q=members&projection=(elements*(primary,type,handle~)) or https://api.linkedin.com/v2/emailAddress?q=members&projection=(elements*(handle~)) I have received 403 Forbidden response, presumably due to the missing permission in question 1. Even if so, the token shouldn't have been issued in this case if I am not mistaken.
Could you please confirm if this is expected, or if something else is in play here?
I'm pretty certain it's that you must apply to the Marketing Partner Program.
I'm having the same issue as well, and I just applied to the program. Currently awaiting approval, but will confirm/edit answer once I get confirmation.
LinkedIn has made a lot of changed to their API over the past few months. Check out the latest permission changes relevant to this post:
https://learn.microsoft.com/en-us/linkedin/shared/references/migrations/marketing-permissions-migration
EDIT: Confirmed. I didn't receive a notification that I was approved, however, it's 30 days later after applying and I just noticed there was a new product available under "Products" once you are logged in and on your App in the developer portal. You have to add the "Marketing Developer Platform" product, and once again fill out an application:
After completing, they say they will provide you with confirmation within 90 days.

LinkedIn New API - Can't Get r_network Permission

I inherited a program that was written with the old LinkedIn API, and I'm trying to migrate it to the new API. When I try to get the r_basicprofile permission, my oauth token works. However, when I try r_network or rw_nus, I get a response
invalid scope -- your application has not been authorized for
r_network.
Yet, when I go to www.linkedin.com/developer/apps/xxxx/auth, the boxes for r_network and rw_nus are checked.
I.e., A request to
https://www.linkedin.com/uas/oauth2/authorization?response_type=code&client_id=xxxxxx&scope=r_basicprofile&state=yyyy&redirect_uri=http%3A%2F%2Fkalatublog.com%2Fwp-content%2Fmu-plugins%2Fimb-en%2Fhelpers%2Fsocial-connect%2Fapi%2Ffinalize.php%3Fapi%3Dlinkedin%26ch%zzzzz
works, but a request to
https://www.linkedin.com/uas/oauth2/authorization?response_type=code&client_id=xxxxxx&scope=r_network&state=yyyy&redirect_uri=http%3A%2F%2Fkalatublog.com%2Fwp-content%2Fmu-plugins%2Fimb-en%2Fhelpers%2Fsocial-connect%2Fapi%2Ffinalize.php%3Fapi%3Dlinkedin%26ch%zzzzz
gives that error. What am I doing wrong?
As of May 15,
After the grace period expires, several REST API endpoints will no longer be available for general use. The following endpoints are the only ones that will remain available for use:
Profile API — /v1/people/~ `
Share API — /v1/people/~/shares
Companies API — /v1/companies/{id}
If your application is currently using any other API services (e.g. Connections, Groups, People Search, Invitation, Job Search, etc.) you will have to apply to become a member of a relevant Partner Program that provides the necessary API access to continue to leverage any of the endpoints that are not listed above.
It looks like linkedin no longer wants to share anything with their API. Creating a new app indicates that the only possible options are r_basicprofile, r_emailaddress, rw_company_admin, and w_share:
TLDR: they have locked down the API and restricted the usage to an extremely limited set of access points.
I did some more digging. The linkedin website is misleading. On my app linkedin page, it says that I'm approved for rw_nus and r_network, but on this page
https://developer.linkedin.com/support/developer-program-transition
it says those are no longer approved.
So the app home page in linkedin incorrectly said I had those permissions.
Heres the link if you want to Apply for Linkedin
https://help.linkedin.com/app/ask/path/api-dvr

LinkedIn API: How to get company from status-update link?

I have just one basic question about the LinkedIn API, I'm new to that and I don't even use LinkedIn.
Imagine that I have this link: https://www.linkedin.com/nhome/updates?topic=5967002483262787584 - how can I restore the company ID, updateKey for the company or something similar to that? Simply I want to get any information and I know how to use the company API but this is a bit problem (that cannot be solved by this API) and I don't know how to solve that...
Thanks a lot for every single help.
Ok - First take a look at this information:
How to get company logo from Linkedin API?
Then take a look at this web page:
https://www.linkedin.com/nhome/updates?topic=5967002483262787584
The other problem is similar to your problem. You will have to scrape the web page to get the information. If you look at the <TITLE>...</TITILE> part on the IBM web page you will see it says "IBM | LinkedIn".
That is how you get the company's name off of the web page's HTML.
The LinkedIn API says:
https://developer.linkedin.com/docs/fields/company-profile
Check out their Profile Information. Note the "name" field? The company's name should be in that field also.
(BTW: I do NOT work for Stack Overflow or LinkedIn. Just in case you were wondering. I'm just a good samaritan helping out. :-) )
Update: I just re-read your request. If you know what the company's name is you should be able to use the API to reload their profile which has their ID number on it. Don't know about an update key. Do you get what I am talking about?

Get linkedin public status updates

I am trying to get latest 3 public activities of our company from linkedin (ex: http://www.linkedin.com/company/4043/activity) and present it on our website but unfortunately I dont see a clear explanation to do so in the API documentations. I registered an API Key but I am confused if I need to do OAuth if so against what and then what API to call to get publicly available info?
Is OAuth really needed for something that is available?
Can I store an OAuth token for an internal user and keep fetching data on that? I would really do not want to authenticated the site visitors with oauth to get free linkedin content.
This question is on the lines of this one, but I still wanted to ask and see if I could get a better response/answer.
To get the company updates from the LinkedIn API, you will need to reference the following document:
https://developer.linkedin.com/reading-company-updates
The API is currently in preview mode, but the above document addresses your question re: OAuth as well as shows the specific calls as well as sample output. If you have any questions after reviewing the docs, please feel free to visit our developer forums at:
https://developer.linkedin.com/forums/rest
And one of someone from our team would be more than happy to help you further.
Enjoy!
-Jeremy

Resources