Hi Team!
I don’t know what’s happening to the mutation product_delete
, but it is not working for me. I tried to make the request and it is returning “Unexpected Error”. Can I get some help to understand what is the problem here?
Thanks!
{
"errors": [
{
"message": "Unexpected Error",
"operation": "product_delete",
"field": "product_delete",
"request_id": "63fd1263843e0698a55c81ec",
"code": 22
}
],
"data": {
"product_delete": null
},
"extensions": {
"throttling": {
"estimated_complexity": 10,
"cost": 10,
"cost_detail": {
"product_delete": {
"items_count": 0,
"cost": 10,
"total_cost": 10,
"fields": {}
}
},
"user_quota": {
"credits_remaining": 2002,
"max_available": 2002,
"increment_rate": 30
}
}
}
}
Hey @marioreinike,
Thanks for reaching out!
Looking into this issue now, I’ll update you shortly.
Best,
RayanP
Hey @marioreinike,
Thanks for hanging in there!
Are you using the 3PL token when making that call?
For an action like product delete, the change must be made with the child accounts token. This is because the ownership of the product lies in the child account.
Please let me know if you have any questions or concerns.
Best,
RayanP
Yes, I’m always using the child accounts for all requests!
@sh-agent
I don’t know what is the problem here but we need to delete it! Here you can see the request that I’m doing (It is the same as every other product and only this one is not working):
{
"query": "\nmutation product_delete($data: DeleteProductInput!) {\n product_delete(data: $data) {\n request_id\n complexity\n }\n}",
"variables": {
"data": {
"customer_account_id": "70271",
"sku": "MAD-MCO208"
}
}
}
The thing is that I don’t want to delete it from Shiphero UI because that is a soft delete and it won’t let me create another product with the same SKU.
Hey @marioreinike,
Thanks for the additional information.
I’ll have to go ahead and escalate this one to our Engineering Team. I’ll keep you updated with our findings going forward.
Please let me know if you have any questions or concerns.
Best,
RayanP
is there a fast way to just delete this product in the database? it would be very helpful for us!
Hey @marioreinike,
Thanks for hanging in there.
I believe that product was successfully deleted from your primary warehouse. This was done by deleting the bin connection. I think going forward removing all bins from the 3PL side then deleting from the child account, should help with this issue.
Do note that they are still bins for this product in WH’s: 85985, 85986, and 85987.
Please let me know if you have any questions or concerns.
Best,
RayanP
OK I understand. I proceeded to delete all the locations for this product and it was deleted correctly, and it makes sense, because it shouldn’t be possible to delete a product if you have inventory associated. Thanks!
Just to keep in mind, it would be helpful that the API responded with some more descriptive error messages than just an “Unexpected Error”.
1 Like