Dedicated to the Hydrogen framework, headless commerce, and building custom storefronts using the Storefront API.
We are using StoreFront API for making mobile app. When we try to place an order using “COD” function name is “checkoutCompleteFree" its generate an error message “Checkout Requires Payment”. Can anyone help me out on this.
This is the Header
X-Shopify-Storefront-Access-Token
xxxxxxxxxxxxxxxxxxxxxxx
This is the endpoint
https://XYZ.myshopify.com/api/graphql.json
mutation checkoutCompleteFree {
checkoutCompleteFree(checkoutId: "Z2lkOi8vc2hvcGlmeS9DaGVja291dC80ZTI0MWM3MjEzMzVlZmE2YmZhN2Q1ZDJjMGZmM2ZkZT9rZXk9ZmNhOWZkOTdmOGMwZDk3YWExOTIxODMxNzE5OWYwNDM=") {
userErrors {
field
message
}
checkout {
id
}
}
}
Response : -
{
"data": {
"checkoutCompleteFree": null
},
"errors": [
{
"message": "Checkout requires payment.",
"locations": [
{
"line": 3,
"column": 3
}
],
"path": [
"checkoutCompleteFree"
]
}
]
}
Hello,
I am getting the same issue while tring to checkout for free for COD. Please help me in this.
Thanks,
Anurag
Same problem as above. worrisome that this was posted in May of 2017, is there any progress or explanation of this problem?
Hello,
Ashley from escalated support here. I did some digging on checkoutCompleteFree and found that mutation is used only for completing a checkout that doesn't cost anything - it must be free. The GraphQL API and the SDK currently don't support manual payments that are available in Admin.
So a work around would be to use the REST API until we have a Graphql mutator for COD use.
I hope this answers your question,
Ashley Fulks
Escalated Support Shopify
To learn more visit the Shopify Help Center or the Community Blog.
Hello,
Can anyone please suggest me that which Api should be used for Cash On Dilivery?
Thanks,
Anurag
Any update on this API? I tired to complete order, but got this error.
I'm getting the same error using checkoutCompleteFree API, is there an API for COD yet?