2
votes

I am following the instruction on how to get an access token from Paypal using Postman.

I keep on getting this error message:

"error": "unsupported_grant_type", "error_description": "Grant Type is NULL"

Here is my postman setting:

Url: https://api.sandbox.paypal.com/v1/oauth2/token

Authrization: Username: client_id... Password: secret...

Header: Content-Type -> application/x-www-form-urlencoded

body: form-urlencoded

key: grant_type
value: client_credentials
2
What does your request look like in Postman? Can you post a screenshot, masking out your Auth details obviously. - Danny Dainton

2 Answers

8
votes

Follow the screenshots. I guess your problem in flow when you insert grant_type in body.

Choose "Basic auth" type

Add body content

0
votes

check the structure of the body, like below.

body: {
    mode: 'urlencoded',
    urlencoded: [
    {key: "grant_type", value: "openapi_2lo", disabled: false},
]