- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
pulling order IDs via REST API in Magento 2.0
we are seeing a big dependency between the order ID that we are getting from Magenta via REST and the order ID that we see in the order confirmation email. for example REST returns 45, the email has 200045646.
We implemented the increment features directly into the SQL database based on some posts here but it seems that REST APIs pull the original non incremented order ID. anyone was able to address this issue ?
We are using Magento as a backend an d talking to it via REST API
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Re: pulling order IDs via REST API in Magento 2.0
There is order_id (most commonly known as entity_id in sales tables) and increment_id which is human-readable number mostly used for accounting. The first one that you've mentioned is a classic primary key which increments, and the other one (bigger) is the number used for accounting purposes, and that is the actual number which will be mentioned on all pages/documents.
Both of them you can fetch via REST API, in the response of the same API.
If this response solved your problem, click accept as solution to help others solve this issue
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Re: pulling order IDs via REST API in Magento 2.0
Can you please provide the REST query to pull both values ?
- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Re: pulling order IDs via REST API in Magento 2.0
I want to update status via REST API.
For that, order 'entity_id' need in API. But we have 'increment_id'.
So how can we get 'entity_id' by 'increment_id'?