cancel
Showing results for 
Search instead for 
Did you mean: 

Get orders with Rest API results in 401

SOLVED

Get orders with Rest API results in 401

Hi,

I´m starting to get desperate. I´m trying to access orders (/rest/V1/orders/1) through Postman but I get following as response:
"message": "The consumer isn't authorized to access %resources.",
"parameters": {
"resources": "Magento_Sales::actions_view"
}

If I´m trying for example to get all the categories or something else it works. So i´ts only the orders endpoint that doesn´t work.

I use an admin user and the user role has access to everything. I just don´t get why it doesn´t work.

Does anyone have a clue?

 

 

1 ACCEPTED SOLUTION

Accepted Solutions

Re: Get orders with Rest API results in 401

I´ve solved it by adding json_decode to the token variable.

Not sure why this only happend with the Orders endpoint but anyhow it works

View solution in original post

1 REPLY 1

Re: Get orders with Rest API results in 401

I´ve solved it by adding json_decode to the token variable.

Not sure why this only happend with the Orders endpoint but anyhow it works