LinkedIn API:获取访问令牌时访问被拒绝 [英] LinkedIn API: Access Denied when getting Access Token

查看:298
本文介绍了LinkedIn API:获取访问令牌时访问被拒绝的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试使用端点请求访问令牌:

I'm trying to request for an access token using the endpoint:

https://www.linkedin.com/oauth/v2/accessToken?grant_type=client_credentials&client_id={clientid}&client_secret={clientsecret}

我得到的答复是:

{
    "error": "access_denied",
    "error_description": "This application is not allowed to create application tokens"
}

我已将权限设置为r_basicprofile和rw_company_admin.

I have set the permissions to r_basicprofile and rw_company_admin.

推荐答案

客户端凭据流(两足式OAuth): https://docs.microsoft.com/zh-CN/linkedin/shared/authentication/client-credentials-flow?context=linkedin/consumer/context : 贡献者 如果您的应用程序需要访问不是特定于成员的API,请使用客户端凭据流.您的应用程序默认情况下无法访问这些API.与我们联系以使您的应用程序被授予使用此流程的权限.

Client Credential Flow (2-legged OAuth): https://docs.microsoft.com/en-us/linkedin/shared/authentication/client-credentials-flow?context=linkedin/consumer/context: Contributors If your application needs to access APIs that are not member specific, use the Client Credential Flow. Your application cannot access these APIs by default. Contact us to have your application granted permission to use this flow.

这篇关于LinkedIn API:获取访问令牌时访问被拒绝的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆