I want to access my top 5 linkedIn posts. I have generated the oauth access token from the admin user id but when I hit LinkedIn API with that generated token, it gives me permission error "Member does not have permission to get company." Please assist if I am missing anything
0
votes
Post some samples of your code with more detail about the endpoints your hitting and your expected result.
- Stewart
I am generating the authentication key using cleint id and client secret. When I am hitting the LinkedIn API using the same key and it is showing authentication error.
- Anjali
Steps I am following are:- 1. Hitting the below URL linkedin.com/oauth/v2/… Once the above URL is requested then, it will be redirected to another url with code. Note down the code. localhost:8089/auth/linkedin/…
- Anjali
2.Hit URL - linkedin.com/oauth/v2/…> Note down the access code forn the JSON returned 3.Hit the API using that obtained access key api.linkedin.com/v1/companies<linkedInCompanyID>/… obtained forn JSON>&event-type=status-update&count=5'
- Anjali
Hi @Anjali, I'm also trying to implement the same in my web app. I too followed the same steps. After hitting step 2, is it redirecting you to the specified redirect url? And how did you get the access token? Please share your implementation .
- Sankar
1 Answers
0
votes
Referring to their API change logs, it seems you need to be flagged as an admin of the company's linkedin page to access the company REST api. New requirement for Companies API
All calls to Companies API endpoints will require the authenticated user to be flagged as an administrator of the LinkedIn Company Page that is the target of the API call. You become the administrator of a page when you create it. If the page already exists, you will have to contact the existing administrator to grant admin access to other LinkedIn members.
Your API call will return a 403 Forbidden error if you do not have the appropriate admin permission to interact with the target company.
Source: https://developer.linkedin.com/support/developer-program-transition