A space to discuss GraphQL queries, mutations, troubleshooting, throttling, and best practices.
We're moving the community! Starting July 7, the current community will be read-only for approx. 2 weeks. You can browse content, but posting will be temporarily unavailable. Learn more
Hi everyone,
is someone able to get the mocked High Risk order to reflect correctly though GraphQL API?
I read https://help.shopify.com/en/manual/orders/fraud-analysis and created a test order with shopify.test.high@shopify.com to get "HIGH" risk Order. It displays "HIGH" risk through Admin admin interface just fine.
But I have an issue when trying to fetch the same order's "riskLevel" through GraphQL API:
query($id: ID!) { order(id: $id) { riskLevel } }
{"data":{"order":{"riskLevel":"LOW"}}
Querying the same resource though Admin REST API also appears to work correctly:
https://xxxx.myshopify.com/admin/orders/xxxxx/risks.json
I get
{"risks":[{"id":xxxx,"order_id":xxxx,"checkout_id":xxxx,"source":"Internal","score":"1.0","recommendation":"cancel","display":true,"cause_cancel":null,"message":"Shopify recommendation","merchant_message":"Shopify recommendation"}]}
"recommendation":"cancel" correctly.
I cross referenced a production order with an actual "HIGH" risk and the status is correctly returned by GraphQL - Something is definitely broken when retrieving a mocked test order with GraphQL API.
Solved! Go to the solution
This is an accepted solution.
Hi @SSebastjan , just to update this. The risk level should be fixed in the API now going forward. Thanks again for taking the time and reaching out to us.
KB77 | API Support @ Shopify
- Was my reply helpful? Click Like to let me know!
- Was your question answered? Mark it as an Accepted Solution
- To learn more visit Shopify.dev or the Shopify Web Design and Development Blog
Hi @SSebastjan, We were able to replicate this in our tests and have raised the issue with the relevant developer team. Thank you for taking the time to bring this to our attention we hope this can be resolved shortly. Thanks again.
Developer Support @ Shopify
- Was this reply helpful? Click Like to let us know!
- Was your question answered? Mark it as an Accepted Solution
- To learn more visit Shopify.dev or the Shopify Web Design and Development Blog
(deleted)
Developer Support @ Shopify
- Was this reply helpful? Click Like to let us know!
- Was your question answered? Mark it as an Accepted Solution
- To learn more visit Shopify.dev or the Shopify Web Design and Development Blog
This is an accepted solution.
Hi @SSebastjan , just to update this. The risk level should be fixed in the API now going forward. Thanks again for taking the time and reaching out to us.
KB77 | API Support @ Shopify
- Was my reply helpful? Click Like to let me know!
- Was your question answered? Mark it as an Accepted Solution
- To learn more visit Shopify.dev or the Shopify Web Design and Development Blog