TanqoryDocs

tanqoryExtThemeFileVersionRestore

  • Mutation
  • Content and shop

Restores one file to an older version: the version's text becomes the file's body, and the body it replaces is kept as a version. NOT_FOUND (not a version of this store, or the file was deleted since), ACCESS_DENIED (the theme is managed by the online store's editor and is read-only here).

Arguments

ArgumentTypeRequiredDefault
idID!Required

Returns

TanqoryExtThemeFileVersionRestorePayload

FieldTypeDescription
themeFileOnlineStoreThemeFile

The file with the restored body.

userErrors[TanqoryExtThemeFileVersionUserError!]!

Example request

A starting point: required arguments as variables and a few fields of the result. Replace the placeholders.

Set STORE_ID and TANQORY_ACCESS_TOKEN in your environment first (Make your first API call).

curl
curl -X POST "https://api.tanqory.com/admin/2026-10/stores/$STORE_ID/graphql" \
  -H "Authorization: Bearer $TANQORY_ACCESS_TOKEN" \
  -H "Content-Type: application/json" \
  --data '{"query":"mutation TanqoryExtThemeFileVersionRestore($id: ID!) {\n  tanqoryExtThemeFileVersionRestore(id: $id) {\n    userErrors {\n      code\n      field\n      message\n    }\n  }\n}","variables":{"id":"gid://tanqory/Type/id"}}'

Built from commit c0b3fb3fdef7 · API version 2026-10