Skip to main content

cancelStorefrontEditGeneration

Requires permission storefront:storefront:update.

Stop an edit job. Aborts the model call when this API instance runs the job and returns it CANCELLED; on another instance the job stops at its next model turn, so keep polling. A job that already ended is returned unchanged. Credits already charged stay charged (creditsUsedCents).

Errors: a failed call returns a GraphQL errors entry, not a field on the result, and data may be null or partial. Read the entry's extensions.code and message; every shape and code is in the Error reference.

Example:

mutation CancelStorefrontEditGeneration($jobId: ID!) {
cancelStorefrontEditGeneration(jobId: $jobId) {
status
costDisplay
creditsUsedCents
error
jobId
partial
}
}

Variables:

{
"jobId": "id"
}

Response:

{
"data": {
"cancelStorefrontEditGeneration": {
"status": "CANCELLED",
"costDisplay": "string",
"creditsUsedCents": 0,
"error": "string",
"jobId": "id",
"partial": "string"
}
}
}
cancelStorefrontEditGeneration(
jobId: ID!
): StorefrontEditJob!

Arguments​

cancelStorefrontEditGeneration.jobId ● ID! non-null scalar​

The edit job to stop, as startStorefrontEditGeneration returned it.

Type​

StorefrontEditJob object​

A started storefront edit.