我正在使用vb.net Web应用程序。 我希望通过paypal凭证获得papyal用户信息。 我的代码如下:
Dim url As String = "https://api.sandbox.paypal.com/v1/oauth2/token/userinfo?schema=openid"
Dim req As HttpWebRequest = DirectCast(WebRequest.Create(url), HttpWebRequest)
req.ContentType = "application/json"
req.Headers.Add("Authorization", accesstoken)
req.Method = "GET"
Dim responseData As String = ""
Dim Response As HttpWebResponse = DirectCast(req.GetResponse(), HttpWebResponse)
Using reader As StreamReader = New StreamReader(Response.GetResponseStream())
responseData = reader.ReadToEnd()
End Using
响应仅返回User_id。
user_id: https://www.paypal.com/webapps/auth/identity/user/.............
但想获得用户的所有信息。 怎么可能?