Discussions

Ask a Question
Back to All

The Rates API returns "User doesn't have permissions for this request"

acroding the instruction blow

"How to Get an API Access Token
Login to your Easyship dashboard
Click Connect > New Integration and select API Integration.
Give the new integration a name and click Connect
You will be provided with an access token for our Production and Sandbox environments and will be able to adjust the API scopes you want to access. "

I try to call the API by using postman,
I aleady generated two API Access Token, but it doesn't work?

the request body is :

{
"origin_address": {
"line_1": "55 Prospect St",
"line_2": "Unit 401",
"state": "NY",
"city": "Sydney",
"postal_code": "11201",
"country_alpha2": "US"
},
"destination_address": {
"line_1": "1 quai de Jemmapes",
"line_2": "Porte A",
"state": "CA",
"city": "Paris",
"postal_code": "75010",
"country_alpha2": "FR"
},
"incoterms": "DDU",
"insurance": {
"is_insured": false,
"insured_amount": 10,
"insured_currency": "USD"
},
"courier_selection": {
"apply_shipping_rules": true
},
"shipping_settings": {
"units": {
"weight": "lb",
"dimensions": "in"
},
"output_currency": "HKD"
},
"parcels": [
{
"total_actual_weight": 0.8,
"box": {
"slug": null,
"length": 10,
"width": 8,
"height": 5
},
"items": [
{
"description": "Silk dress",
"category": "fashion",
"sku": "test01",
"quantity": 2,
"dimensions": {
"length": null,
"width": null,
"height": null
},
"actual_weight": 10,
"declared_currency": "USD",
"declared_customs_value": 20
}
]
}
]
}

and I add the header
Authorization: Bearer prod_qiR0tLw3kGWy+ozKO4jNl0kxeQZf8JFSlQMVcQwew2Y=