cancel
Showing results for 
Search instead for 
Did you mean: 

Magento 2 rest api - get orders with custom attributes

Magento 2 rest api - get orders with custom attributes

i would like to have the proper curl command for getting all pending orders with custom attributes in Magento 2 rest api.

I use this, but there are no custom attributes in the result.

curl -X GET -H "Authorization: Bearer xxxxxxxxxxxxxxxxxxxx" -H "Cache-Control: no-cache" 'http://xxxxxx.xxx/index.php/rest/V1/orders?searchCriteria[filter_groups][0][filters][0][field]=statu...'

What do i wrong? I get everything but not the product attributes and the custom product attributes.

1 REPLY 1

Re: Magento 2 rest api - get orders with custom attributes

I found. I have to get first the order item ids and after with rest/V1/orders/items/(orderid) get the attributes for all the orders.