首页 > 解决方案 > 来自linkedin的JSON api响应

问题描述

使用下面的 URL,我得到了来自linkedin 的 XML 形式的配置文件响应。

this.http.get('https://api.linkedin.com/v1/people/~?oauth2_access_token='+token,{headers: headers})

如何获得 JSON 格式的响应?我已尝试使用 URL,但出现错误。

https://api.linkedin.com/v1/people/~?format=json~?oauth2_access_token=

标签: angularoauth-2.0linkedinlinkedin-api

解决方案


format应作为查询参数发送:

尝试:

https://api.linkedin.com/v1/people/~?format=json&oauth2_access_token=xxxx

推荐阅读