get uncancelled order via StoreFront API

Jimmy430
Tourist
12 0 1

HI,
Is there any way to get un-cancelled order via StoreFront API, like in REST admin API, I know I can use "status=open" to filter out only open orders, in GraphQL Admin API I could use the similar query "query: "status=open" " as well, but in StoreFront API what I can filter with order is only ProcessedAt, and I can't even get the cancelledAt value in the response, so what can I do if I only want to get the uncancelled orders?
Any suggestion would be thankful.

Replies 4 (4)

swalkinshaw
Shopify Staff
20 4 12

Hey Jimmy, unfortunately this isn't possible with the Storefront API. There's always going to be some differences between Storefront and Admin; especially because Storefront has different security and privacy concerns.

To learn more visit the Shopify Help Center or the Community Blog.

Jimmy430
Tourist
12 0 1

Hi @swalkinshaw ,
Thank you for your reply, I understand there is always security and privacy issues, but for me, showing a cancelled order in my previous order list doesn't make sense, or at least I could know which order has been cancelled, and that's why I ask this question.
If I really want to do that, is there any way to do? I'm OK if it need to implement with Admin API or some else, but what would be problems if I use Admin API in my client-end APP(especially security and privacy concerns)?
Sorry if my description is bad, I'm not a English native speaker.

swalkinshaw
Shopify Staff
20 4 12

I think my reply was misleading a bit, sorry. I wasn't specifically talking about the cancelled order example being a security/private issue; just wanted to point out that there's many reasons why there might be gaps between the Admin and Storefront API. I'll pass along this feature request to the appropriate team.

 

You definitely don't want to call the Admin API from your client app since it would expose your access token allowing anyone to make changes. Only the Storefront access token is meant to be publicly exposed.

To learn more visit the Shopify Help Center or the Community Blog.

Jimmy430
Tourist
12 0 1

I see, thanks for your reply, hope this feature would be implemented soon