Discuss and resolve questions on Liquid, JavaScript, themes, sales channels, and site speed enhancements.
Why when i try to make a giftCardDeactivate request with Graphql , tell me that doesn't exists ?
This is the error returned : Field \'giftCardDeactivate\' doesn\'t exist on type \'Mutation\
And below the code :
$mutation = <<<GRAPHQL
mutation giftCardDeactivate(\$id: ID!) {
giftCardDeactivate(id: \$id) {
giftCard {
id
deactivatedAt
}
userErrors {
message
field
code
}
}
}
GRAPHQL;
$variables = ['id' => $giftCardId];
$response = $this->graphClient->query(['query' => $mutation,'variables' => $variables]);
$data = $response->getDecodedBody();
var_dump($data);
June brought summer energy to our community. Members jumped in with solutions, clicked ...
By JasonH Jun 5, 2025Learn how to build powerful custom workflows in Shopify Flow with expert guidance from ...
By Jacqui May 7, 2025Did You Know? May is named after Maia, the Roman goddess of growth and flourishing! ...
By JasonH May 2, 2025