storeCreditUpdate
mutation
An access token is required to call this API. Refer to Authorization for more information about how to obtain the token.
- If the customer does not have a store credit account, issue new store credits to the existing customer
- If the customer already has a store credit account, modify the existing store credits for the existing customer
Arguments
storeCredit Update Param
Return
List of encountered errors during Mutations execution.
Status and error codes
For detailed information about common codes, see Status and error codes.
Example
storeCredit Update
Code
Query
mutation storeCreditUpdate($input: StoreCreditUpdateInput!) {
storeCreditUpdate(input: $input) {
userErrors {
field
message
}
}
}
Variables
{
"input": {
"creditsUpdateWay": "MODIFY_EXISTING",
"creditsUpdateReason": "COMPENSATION",
"businessId":"5509754221485361218",
"remarksCustomers":"remark",
"customerId":"gid://shopline/Customer/4602226680",
"creditsUpdateType":"INCREASE",
"updatedValue":"30000",
"expiryTime":"2024-07-27T17:18:25z"
}
}
Response
{
"data": {
"storeCreditUpdate": {
"userErrors": []
}
}
}
Was this article helpful to you?