0
votes

I am using the PayPal REST API for the first time and trying to get an authentication token but keep getting an "Invalid credentials error".

I am following Step 2 in the documentation found here: https://developer.paypal.com/webapps/developer/docs/integration/direct/make-your-first-call/

I am using the Chrome extension "Advanced rest client"

Here are the values entered in the rest client:

Header: content-type:application/x-www-form-urlencoded Accept:application/json

Form data grant_type:client_credentials clientId:ASF6RRBP0uTq7FnC90tpFx7vfA-Pliw8uQDjv5RZ10Y_NVspuc88pUPLN6yM secret: EAdx7BDKzWczDomYG2QDHu8jhaAXj4xDZLHadvL5aRfesjwo5c81zbSpRxuE

When I send the request I get the following error: { error: "invalid_client" error_description: "Invalid client credentials" }

Can anyone help me to figure what I am doing wrong here?

1
did you ever solve this? - baash05

1 Answers

0
votes

Form data should only contain

grant_type=client_credentials

and then add header

Authorization: Basic put base64of(clientid:secret)here

don't pass client id and secret in form data.