Close a store to the public
const url = 'https://apibase.ecomweb.app/api/v1/stores/example/close';const options = {method: 'POST', 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 POST \ --url https://apibase.ecomweb.app/api/v1/stores/example/close \ --header 'x-api-key: <x-api-key>'Puts the store back behind the coming soon page: visitors can no longer browse or buy. Reopening later needs no setup steps and sends no email. Returns the updated setup guide.
Required scopes: write:settings
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”The store’s ref, as returned by GET /stores.
Responses
Section titled “Responses”object
When the store was first opened, as an ISO 8601 timestamp, or null.
When setup was ended without opening, as an ISO 8601 timestamp, or null.
The setup steps and which are done.
object
product, shipping, payment, theme or domain.
Whether the step must be done before the store can open.
Whether the step is done.
Summary of the shipping rates.
object
The nationwide rate as a decimal string, or null.
The order amount above which shipping is free, as a decimal string, or null.
Number of shipping rates.
The payment methods that are turned on.
The store’s custom domain, or null.
ID of the live theme, or null.
Name of the live theme, or null.
The starter theme the live theme was copied from, meridian or default, or null.
True while visitors see the coming soon page.
Whether the guide is hidden in the dashboard.
Number of required steps still to do.
Whether the store can be opened now.
Number of untouched sample products.
Number of active products the merchant added.
Example
{ "steps": [ { "id": "product" } ], "live_theme_source": "meridian"}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"}