Skip to content
This repository was archived by the owner on Oct 4, 2019. It is now read-only.
This repository was archived by the owner on Oct 4, 2019. It is now read-only.

Orders: Get "new" orders from one API request #26

@ryelle

Description

@ryelle

For store on calypso, "new" orders are any in 'pending', 'processing', or 'on-hold'. If I want to get those orders via the API, I can't do it in one request - currently status only accepts a single status string, or 'any', but no (apparent) way to request a subset of statuses.

One solution would be to pass in a list of statuses, status[]=pending&status[]=processing&status[]=on-hold, and returning all orders that match one of those. This would be useful for other combined status listings, like if we wanted to include completed, cancelled (and refunded?) orders in a list of "finished" orders.

Another solution would be to allow the API to accept status=new, and behind the scenes translate that to [ pending, processing, on-hold ]. If wc extensions can add custom statuses, this might be better so they can indicate if some new status should be considered "new".

Metadata

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions