Error while making call for oauth token api call from classic asp
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi,
I am getting the given below error message while making a call to https://api.sandbox.paypal.com/v1/oauth2/token/ api from classic asp.
msxml6.dll (0x80090326)
The message received was unexpected or badly formatted.
I am using given below code:
Set xmlhttp = server.createObject("MSXML2.ServerXMLHTTP.6.0")
url = "https://api.sandbox.paypal.com/v1/oauth2/token/"
xmlhttp.open "POST", url, false
xmlhttp.setRequestHeader "Accept", "application/json"
xmlhttp.setRequestHeader "Accept-Language", "en_US"
xmlhttp.setRequestHeader "Authorization", "Basic "& Base64Encode(client-id&":"&secret-key)
xmlhttp.send "grant_type=client_credentials"
Error is produced at
xmlhttp.send "grant_type=client_credentials"
line of code.
Thanks in advance
- Labels:
-
Payments REST APIs
Haven't Found your Answer?
It happens. Hit the "Login to Ask the community" button to create a question for the PayPal community.
- REST API issues in sandbox in REST APIs
- RATE_LIMIT_REACHED errors when creating auth token for select users in REST APIs
- Get all available scopes in REST APIs
- how to make demo payment from sandbox account by using payment ID, token and payer ID? in REST APIs
- Withdrawals are failing in paypal live https://api.sandbox.paypal.com/v2/transfers/withdrawals in REST APIs