List theme versions
const url = 'https://apibase.ecomweb.app/api/v1/stores/example/themes/example/versions';const options = {method: 'GET', headers: {'x-api-key': '<x-api-key>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url https://apibase.ecomweb.app/api/v1/stores/example/themes/example/versions \ --header 'x-api-key: <x-api-key>'Returns the theme’s 100 newest versions, newest first, of every kind: catalog releases, builds of your code and links to your own site. Each says whether it is the one in use, whether the storefront serves it, and whether it can be used. A key with only the deploy:storefront scope can call this route.
Required scopes: read:settings or deploy:storefront
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”The theme ID.
The store’s ref, as returned by GET /stores.
Responses
Section titled “Responses”object
release: a catalog release. build: a deployment of your code. link: your own site.
When the version was added, as an ISO 8601 timestamp.
ID of the user who added it, or null.
Why the version cannot be used. Only when usable is false.
The catalog release. Only for a release.
object
The catalog theme ID.
The release version.
The build. Only for a build.
object
Why the build failed, or null.
When the build ended, as an ISO 8601 timestamp, or null.
How long the build took, in seconds, or null.
Deployment ID.
The deployment’s status.
source or prebuilt: what was uploaded.
The linked site. Only for a link.
object
Extra origins the site is served from.
The site address.
Deprecated: use build.status. Only for a build.
Deprecated: use build.error. Only for a build.
Deprecated: use usable. Only for a build.
Version ID.
A short name for the version.
Whether the theme uses this version.
Whether the store’s storefront serves this version now.
Whether the version can be used now. See unusable_reason when it cannot.
Example
[ { "kind": "release", "unusable_reason": "build_failed" }]The key is missing, invalid, revoked or expired.
object
The HTTP status code.
What went wrong; validation failures list one message per problem.
The HTTP status text, such as Bad Request.
object
A stable, machine-readable error code.
A human-readable explanation.
Extra context about the error, when there is any.
object
When the error happened, as an ISO 8601 timestamp.
Example generated
{ "statusCode": 1, "message": [ "example" ], "error": "example"}The key may not do this: a missing scope, a readonly key, a publishable key on a Store API route, or a disallowed origin.
object
The HTTP status code.
What went wrong; validation failures list one message per problem.
The HTTP status text, such as Bad Request.
object
A stable, machine-readable error code.
A human-readable explanation.
Extra context about the error, when there is any.
object
When the error happened, as an ISO 8601 timestamp.
Example generated
{ "statusCode": 1, "message": [ "example" ], "error": "example"}The resource does not exist in this store.
object
The HTTP status code.
What went wrong; validation failures list one message per problem.
The HTTP status text, such as Bad Request.
object
A stable, machine-readable error code.
A human-readable explanation.
Extra context about the error, when there is any.
object
When the error happened, as an ISO 8601 timestamp.
Example generated
{ "statusCode": 1, "message": [ "example" ], "error": "example"}