#Sites
GET /sites
List the organization's sites, alphabetically by default. Supports filtering and cursor pagination.
Requires the settings:read permission.
Query parameters
limitnumberThe number of records to return.
cursorstringA pagination cursor. Fetch the next page by passing the nextCursor value from the previous response.
sortname | -name | slug | -slug | createdAt | -createdAtThe sort order. Prefix a field with - to sort descending. Defaults to name.
filterstringA JSON-encoded filter document, for example {"createdAt":{"$gte":"2025-01-01T00:00:00Z"}}. Filterable fields: id, name, slug, baseUrl, createdAt. See Filtering for the syntax.
curl \
"https://your-store.meisei.app/api/sites" \
-H "Authorization: Bearer sk_YOUR_SECRET_KEY"import { client } from "@meisei/api/admin/client"
import { getSites } from "@meisei/api/admin"
client.setConfig({
baseUrl: "https://your-store.meisei.app/api",
headers: { Authorization: "Bearer sk_YOUR_SECRET_KEY" },
})
const { data, error } = await getSites()require "meisei"
meisei = Meisei::Client.new(
secret_key: "sk_YOUR_SECRET_KEY",
base_url: "https://your-store.meisei.app/api",
)
page = meisei.sites.listfrom meisei import Client
meisei = Client(
secret_key="sk_YOUR_SECRET_KEY",
base_url="https://your-store.meisei.app/api",
)
page = meisei.sites.list(){
"data": [
{
"id": "A4Ws1igz",
"name": "string",
"slug": "string",
"baseUrl": "string",
"brandSettings": {
"primaryColor": "...",
"pageColor": "...",
"contentColor": "...",
"textColor": "...",
"mutedColor": "...",
"logoUrl": "...",
"iconUrl": "..."
},
"metadata": "...",
"sendingDomainId": "string",
"emailLocalPart": "string",
"emailReplyTo": "user@example.com",
"signInUrl": "string",
"hostnames": ["..."],
"createdAt": "2025-01-15T09:30:00Z",
"updatedAt": "2025-01-15T09:30:00Z"
}
],
"nextCursor": "string"
}{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"type": "object",
"properties": {
"data": {
"type": "array",
"items": {
"type": "object",
"properties": {
"id": {
"type": "string",
"description": "Unique identifier for the site.",
"idCodec": "sqid"
},
"name": {
"type": "string",
"description": "The site's display name."
},
"slug": {
"type": "string",
"description": "The site's short handle, unique within the organization. Used by imports and widgets."
},
"baseUrl": {
"type": "string",
"description": "The storefront's base URL, used to build links back to it."
},
"brandSettings": {
"type": "object",
"properties": {
"primaryColor": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"description": "Accent color used for buttons and links, as a CSS color string."
},
"pageColor": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"description": "Page background color, as a CSS color string."
},
"contentColor": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"description": "Background color for cards and panels, as a CSS color string."
},
"textColor": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"description": "Body text color, as a CSS color string."
},
"mutedColor": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"description": "Color for secondary and helper text, as a CSS color string."
},
"logoUrl": {
"anyOf": [
{
"type": "string",
"format": "uri"
},
{
"type": "null"
}
],
"description": "Public URL of the site's logo image."
},
"iconUrl": {
"anyOf": [
{
"type": "string",
"format": "uri"
},
{
"type": "null"
}
],
"description": "Public URL of the site's square icon."
}
},
"required": [
"primaryColor",
"pageColor",
"contentColor",
"textColor",
"mutedColor",
"logoUrl",
"iconUrl"
],
"additionalProperties": false,
"description": "Colors and imagery used to brand emails and customer-facing pages for this site."
},
"metadata": {
"type": "object",
"propertyNames": {
"type": "string"
},
"additionalProperties": {
"anyOf": [
{
"type": "string"
},
{
"type": "number"
},
{
"type": "boolean"
},
{
"type": "array",
"items": {
"type": "string"
}
}
],
"description": "A metadata value: a string, a number, true or false, or a list of strings. A key with a metadata definition holds the type its definition names."
},
"description": "Key/value pairs for your own data. Keys you define with `/metadata-definitions` are typed and validated; any other key is free-form. Individual keys are filterable with a dot path, for example `metadata.category`."
},
"sendingDomainId": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"description": "The verified domain this site's shopper emails are sent from, or null to send through Meisei."
},
"emailLocalPart": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"description": "The part of the From address before the `@`, such as `hello`. Null means the site has no sending address of its own yet."
},
"emailReplyTo": {
"anyOf": [
{
"type": "string",
"format": "email",
"pattern": "^(?!\\.)(?!.*\\.\\.)([A-Za-z0-9_'+\\-\\.]*)[A-Za-z0-9_+-]@([A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$"
},
{
"type": "null"
}
],
"description": "Where replies to the site's shopper emails go, or null to reply to the From address."
},
"signInUrl": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"description": "Where shoppers sign in to the storefront. The loyalty widget sends a shopper who is not signed in there. Null leaves its sign-in hint as plain text."
},
"hostnames": {
"type": "array",
"items": {
"type": "object",
"properties": {
"id": {
"type": "string",
"description": "Unique identifier for the hostname.",
"idCodec": "sqid"
},
"siteId": {
"type": "string",
"description": "The site whose customer pages this hostname serves.",
"idCodec": "sqid"
},
"domainId": {
"type": "string",
"description": "The verified domain the hostname sits under.",
"idCodec": "sqid"
},
"hostname": {
"type": "string",
"description": "The hostname itself, lowercase."
},
"purpose": {
"anyOf": [
{
"type": "string",
"enum": ["reviews", "wishlists"],
"description": "Which links point at this hostname: `reviews` for review and unsubscribe pages, `wishlists` for shared wishlists."
},
{
"type": "null"
}
],
"description": "Which links point at this hostname, or null to use it for anything the site needs."
},
"active": {
"type": "boolean",
"description": "Whether a certificate has been issued, which is when links start using it."
},
"records": {
"type": "array",
"items": {
"type": "object",
"properties": {
"type": {
"type": "string",
"enum": ["TXT", "CNAME", "MX"],
"description": "The type of DNS record to create."
},
"name": {
"type": "string",
"description": "The fully qualified host the record goes on."
},
"value": {
"type": "string",
"description": "The value the record has to hold."
},
"purpose": {
"type": "string",
"enum": ["dkim", "return-path", "spf", "ownership", "pages", "acme"],
"description": "What the record is for: `dkim` and `return-path` for sending email, `spf` for the sender policy, `ownership` for proving you control the domain, `pages` for pointing a hostname at Meisei, and `acme` for issuing its certificate."
},
"verified": {
"type": "boolean",
"description": "Whether the record has been seen in DNS yet."
}
},
"required": ["type", "name", "value", "purpose", "verified"],
"additionalProperties": false
},
"description": "The DNS records the hostname needs, with what the provider can see so far."
},
"dnsConfiguredAt": {
"anyOf": [
{
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
},
{
"type": "null"
}
],
"description": "When the hostname was first seen pointing at Meisei."
},
"certificateIssuedAt": {
"anyOf": [
{
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
},
{
"type": "null"
}
],
"description": "When the certificate was issued, or null if it has not been yet."
},
"lastCheckedAt": {
"anyOf": [
{
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
},
{
"type": "null"
}
],
"description": "When Meisei last checked the hostname's DNS."
},
"createdAt": {
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$",
"description": "When the hostname was added."
},
"updatedAt": {
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$",
"description": "When the hostname was last changed."
}
},
"required": [
"id",
"siteId",
"domainId",
"hostname",
"purpose",
"active",
"records",
"dnsConfiguredAt",
"certificateIssuedAt",
"lastCheckedAt",
"createdAt",
"updatedAt"
],
"additionalProperties": false
},
"description": "The custom hostnames this site serves its customer pages on."
},
"createdAt": {
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$",
"description": "When the site was created."
},
"updatedAt": {
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$",
"description": "When the site was last changed."
}
},
"required": [
"id",
"name",
"slug",
"baseUrl",
"brandSettings",
"metadata",
"sendingDomainId",
"emailLocalPart",
"emailReplyTo",
"signInUrl",
"hostnames",
"createdAt",
"updatedAt"
],
"additionalProperties": false
},
"description": "The page of records, in the requested sort order."
},
"nextCursor": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"description": "Pass this back as `cursor` to fetch the next page. Null once the last page has been returned."
}
},
"required": ["data", "nextCursor"],
"additionalProperties": false
}POST /sites
Create a site. Fails if the organization is already at its plan's site limit, or if another site already uses the slug. Triggers the site.created webhook.
Requires the settings:write permission.
Body parameters
namestringrequiredThe site's display name.
slugstringrequiredA short handle for the site, unique within the organization.
baseUrlstring (uri)requiredThe storefront's base URL, such as https://shop.example.com.
brandSettingsobjectBranding for the site's emails and customer-facing pages. Defaults to unset everywhere.
metadataobjectKey/value pairs for your own data. Keys you define with /metadata-definitions are typed and validated; any other key is free-form. Individual keys are filterable with a dot path, for example metadata.category.
curl \
-X POST \
"https://your-store.meisei.app/api/sites" \
-H "Authorization: Bearer sk_YOUR_SECRET_KEY" \
-H "Content-Type: application/json" \
-d '{
"name": "string",
"slug": "string",
"baseUrl": "https://example.com",
"brandSettings": {
"logoKey": "string",
"iconKey": "string",
"primaryColor": "string",
"pageColor": "string",
"contentColor": "string",
"textColor": "string",
"mutedColor": "string"
},
"metadata": "..."
}'import { client } from "@meisei/api/admin/client"
import { postSites } from "@meisei/api/admin"
client.setConfig({
baseUrl: "https://your-store.meisei.app/api",
headers: { Authorization: "Bearer sk_YOUR_SECRET_KEY" },
})
const { data, error } = await postSites({
body: {
name: "string",
slug: "string",
baseUrl: "https://example.com",
brandSettings: {
logoKey: "string",
iconKey: "string",
primaryColor: "string",
pageColor: "string",
contentColor: "string",
textColor: "string",
mutedColor: "string",
},
metadata: "...",
},
})require "meisei"
meisei = Meisei::Client.new(
secret_key: "sk_YOUR_SECRET_KEY",
base_url: "https://your-store.meisei.app/api",
)
result = meisei.sites.create(
name: "string",
slug: "string",
base_url: "https://example.com",
brand_settings: {
logo_key: "string",
icon_key: "string",
primary_color: "string",
page_color: "string",
content_color: "string",
text_color: "string",
muted_color: "string",
},
metadata: "...",
)from meisei import Client
meisei = Client(
secret_key="sk_YOUR_SECRET_KEY",
base_url="https://your-store.meisei.app/api",
)
result = meisei.sites.create(
name="string",
slug="string",
base_url="https://example.com",
brand_settings={
"logo_key": "string",
"icon_key": "string",
"primary_color": "string",
"page_color": "string",
"content_color": "string",
"text_color": "string",
"muted_color": "string",
},
metadata={},
){
"id": "A4Ws1igz",
"name": "string",
"slug": "string",
"baseUrl": "string",
"brandSettings": {
"primaryColor": "string",
"pageColor": "string",
"contentColor": "string",
"textColor": "string",
"mutedColor": "string",
"logoUrl": "https://example.com",
"iconUrl": "https://example.com"
},
"metadata": "...",
"sendingDomainId": "string",
"emailLocalPart": "string",
"emailReplyTo": "user@example.com",
"signInUrl": "string",
"hostnames": [
{
"id": "A4Ws1igz",
"siteId": "A4Ws1igz",
"domainId": "A4Ws1igz",
"hostname": "string",
"purpose": "reviews",
"active": true,
"records": ["..."],
"dnsConfiguredAt": "2025-01-15T09:30:00Z",
"certificateIssuedAt": "2025-01-15T09:30:00Z",
"lastCheckedAt": "2025-01-15T09:30:00Z",
"createdAt": "2025-01-15T09:30:00Z",
"updatedAt": "2025-01-15T09:30:00Z"
}
],
"createdAt": "2025-01-15T09:30:00Z",
"updatedAt": "2025-01-15T09:30:00Z"
}{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"type": "object",
"properties": {
"id": {
"type": "string",
"description": "Unique identifier for the site.",
"idCodec": "sqid"
},
"name": {
"type": "string",
"description": "The site's display name."
},
"slug": {
"type": "string",
"description": "The site's short handle, unique within the organization. Used by imports and widgets."
},
"baseUrl": {
"type": "string",
"description": "The storefront's base URL, used to build links back to it."
},
"brandSettings": {
"type": "object",
"properties": {
"primaryColor": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"description": "Accent color used for buttons and links, as a CSS color string."
},
"pageColor": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"description": "Page background color, as a CSS color string."
},
"contentColor": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"description": "Background color for cards and panels, as a CSS color string."
},
"textColor": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"description": "Body text color, as a CSS color string."
},
"mutedColor": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"description": "Color for secondary and helper text, as a CSS color string."
},
"logoUrl": {
"anyOf": [
{
"type": "string",
"format": "uri"
},
{
"type": "null"
}
],
"description": "Public URL of the site's logo image."
},
"iconUrl": {
"anyOf": [
{
"type": "string",
"format": "uri"
},
{
"type": "null"
}
],
"description": "Public URL of the site's square icon."
}
},
"required": [
"primaryColor",
"pageColor",
"contentColor",
"textColor",
"mutedColor",
"logoUrl",
"iconUrl"
],
"additionalProperties": false,
"description": "Colors and imagery used to brand emails and customer-facing pages for this site."
},
"metadata": {
"type": "object",
"propertyNames": {
"type": "string"
},
"additionalProperties": {
"anyOf": [
{
"type": "string"
},
{
"type": "number"
},
{
"type": "boolean"
},
{
"type": "array",
"items": {
"type": "string"
}
}
],
"description": "A metadata value: a string, a number, true or false, or a list of strings. A key with a metadata definition holds the type its definition names."
},
"description": "Key/value pairs for your own data. Keys you define with `/metadata-definitions` are typed and validated; any other key is free-form. Individual keys are filterable with a dot path, for example `metadata.category`."
},
"sendingDomainId": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"description": "The verified domain this site's shopper emails are sent from, or null to send through Meisei."
},
"emailLocalPart": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"description": "The part of the From address before the `@`, such as `hello`. Null means the site has no sending address of its own yet."
},
"emailReplyTo": {
"anyOf": [
{
"type": "string",
"format": "email",
"pattern": "^(?!\\.)(?!.*\\.\\.)([A-Za-z0-9_'+\\-\\.]*)[A-Za-z0-9_+-]@([A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$"
},
{
"type": "null"
}
],
"description": "Where replies to the site's shopper emails go, or null to reply to the From address."
},
"signInUrl": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"description": "Where shoppers sign in to the storefront. The loyalty widget sends a shopper who is not signed in there. Null leaves its sign-in hint as plain text."
},
"hostnames": {
"type": "array",
"items": {
"type": "object",
"properties": {
"id": {
"type": "string",
"description": "Unique identifier for the hostname.",
"idCodec": "sqid"
},
"siteId": {
"type": "string",
"description": "The site whose customer pages this hostname serves.",
"idCodec": "sqid"
},
"domainId": {
"type": "string",
"description": "The verified domain the hostname sits under.",
"idCodec": "sqid"
},
"hostname": {
"type": "string",
"description": "The hostname itself, lowercase."
},
"purpose": {
"anyOf": [
{
"type": "string",
"enum": ["reviews", "wishlists"],
"description": "Which links point at this hostname: `reviews` for review and unsubscribe pages, `wishlists` for shared wishlists."
},
{
"type": "null"
}
],
"description": "Which links point at this hostname, or null to use it for anything the site needs."
},
"active": {
"type": "boolean",
"description": "Whether a certificate has been issued, which is when links start using it."
},
"records": {
"type": "array",
"items": {
"type": "object",
"properties": {
"type": {
"type": "string",
"enum": ["TXT", "CNAME", "MX"],
"description": "The type of DNS record to create."
},
"name": {
"type": "string",
"description": "The fully qualified host the record goes on."
},
"value": {
"type": "string",
"description": "The value the record has to hold."
},
"purpose": {
"type": "string",
"enum": ["dkim", "return-path", "spf", "ownership", "pages", "acme"],
"description": "What the record is for: `dkim` and `return-path` for sending email, `spf` for the sender policy, `ownership` for proving you control the domain, `pages` for pointing a hostname at Meisei, and `acme` for issuing its certificate."
},
"verified": {
"type": "boolean",
"description": "Whether the record has been seen in DNS yet."
}
},
"required": ["type", "name", "value", "purpose", "verified"],
"additionalProperties": false
},
"description": "The DNS records the hostname needs, with what the provider can see so far."
},
"dnsConfiguredAt": {
"anyOf": [
{
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
},
{
"type": "null"
}
],
"description": "When the hostname was first seen pointing at Meisei."
},
"certificateIssuedAt": {
"anyOf": [
{
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
},
{
"type": "null"
}
],
"description": "When the certificate was issued, or null if it has not been yet."
},
"lastCheckedAt": {
"anyOf": [
{
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
},
{
"type": "null"
}
],
"description": "When Meisei last checked the hostname's DNS."
},
"createdAt": {
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$",
"description": "When the hostname was added."
},
"updatedAt": {
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$",
"description": "When the hostname was last changed."
}
},
"required": [
"id",
"siteId",
"domainId",
"hostname",
"purpose",
"active",
"records",
"dnsConfiguredAt",
"certificateIssuedAt",
"lastCheckedAt",
"createdAt",
"updatedAt"
],
"additionalProperties": false
},
"description": "The custom hostnames this site serves its customer pages on."
},
"createdAt": {
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$",
"description": "When the site was created."
},
"updatedAt": {
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$",
"description": "When the site was last changed."
}
},
"required": [
"id",
"name",
"slug",
"baseUrl",
"brandSettings",
"metadata",
"sendingDomainId",
"emailLocalPart",
"emailReplyTo",
"signInUrl",
"hostnames",
"createdAt",
"updatedAt"
],
"additionalProperties": false,
"description": "The new site."
}GET /sites/{id}
Get a single site by ID.
Requires the settings:read permission.
Path parameters
idstringrequiredThe ID of the site.
curl \
"https://your-store.meisei.app/api/sites/A4Ws1igz" \
-H "Authorization: Bearer sk_YOUR_SECRET_KEY"import { client } from "@meisei/api/admin/client"
import { getSitesById } from "@meisei/api/admin"
client.setConfig({
baseUrl: "https://your-store.meisei.app/api",
headers: { Authorization: "Bearer sk_YOUR_SECRET_KEY" },
})
const { data, error } = await getSitesById({
path: { id: "A4Ws1igz" },
})require "meisei"
meisei = Meisei::Client.new(
secret_key: "sk_YOUR_SECRET_KEY",
base_url: "https://your-store.meisei.app/api",
)
result = meisei.sites.retrieve("A4Ws1igz")from meisei import Client
meisei = Client(
secret_key="sk_YOUR_SECRET_KEY",
base_url="https://your-store.meisei.app/api",
)
result = meisei.sites.retrieve("A4Ws1igz"){
"id": "A4Ws1igz",
"name": "string",
"slug": "string",
"baseUrl": "string",
"brandSettings": {
"primaryColor": "string",
"pageColor": "string",
"contentColor": "string",
"textColor": "string",
"mutedColor": "string",
"logoUrl": "https://example.com",
"iconUrl": "https://example.com"
},
"metadata": "...",
"sendingDomainId": "string",
"emailLocalPart": "string",
"emailReplyTo": "user@example.com",
"signInUrl": "string",
"hostnames": [
{
"id": "A4Ws1igz",
"siteId": "A4Ws1igz",
"domainId": "A4Ws1igz",
"hostname": "string",
"purpose": "reviews",
"active": true,
"records": ["..."],
"dnsConfiguredAt": "2025-01-15T09:30:00Z",
"certificateIssuedAt": "2025-01-15T09:30:00Z",
"lastCheckedAt": "2025-01-15T09:30:00Z",
"createdAt": "2025-01-15T09:30:00Z",
"updatedAt": "2025-01-15T09:30:00Z"
}
],
"createdAt": "2025-01-15T09:30:00Z",
"updatedAt": "2025-01-15T09:30:00Z"
}{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"type": "object",
"properties": {
"id": {
"type": "string",
"description": "Unique identifier for the site.",
"idCodec": "sqid"
},
"name": {
"type": "string",
"description": "The site's display name."
},
"slug": {
"type": "string",
"description": "The site's short handle, unique within the organization. Used by imports and widgets."
},
"baseUrl": {
"type": "string",
"description": "The storefront's base URL, used to build links back to it."
},
"brandSettings": {
"type": "object",
"properties": {
"primaryColor": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"description": "Accent color used for buttons and links, as a CSS color string."
},
"pageColor": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"description": "Page background color, as a CSS color string."
},
"contentColor": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"description": "Background color for cards and panels, as a CSS color string."
},
"textColor": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"description": "Body text color, as a CSS color string."
},
"mutedColor": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"description": "Color for secondary and helper text, as a CSS color string."
},
"logoUrl": {
"anyOf": [
{
"type": "string",
"format": "uri"
},
{
"type": "null"
}
],
"description": "Public URL of the site's logo image."
},
"iconUrl": {
"anyOf": [
{
"type": "string",
"format": "uri"
},
{
"type": "null"
}
],
"description": "Public URL of the site's square icon."
}
},
"required": [
"primaryColor",
"pageColor",
"contentColor",
"textColor",
"mutedColor",
"logoUrl",
"iconUrl"
],
"additionalProperties": false,
"description": "Colors and imagery used to brand emails and customer-facing pages for this site."
},
"metadata": {
"type": "object",
"propertyNames": {
"type": "string"
},
"additionalProperties": {
"anyOf": [
{
"type": "string"
},
{
"type": "number"
},
{
"type": "boolean"
},
{
"type": "array",
"items": {
"type": "string"
}
}
],
"description": "A metadata value: a string, a number, true or false, or a list of strings. A key with a metadata definition holds the type its definition names."
},
"description": "Key/value pairs for your own data. Keys you define with `/metadata-definitions` are typed and validated; any other key is free-form. Individual keys are filterable with a dot path, for example `metadata.category`."
},
"sendingDomainId": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"description": "The verified domain this site's shopper emails are sent from, or null to send through Meisei."
},
"emailLocalPart": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"description": "The part of the From address before the `@`, such as `hello`. Null means the site has no sending address of its own yet."
},
"emailReplyTo": {
"anyOf": [
{
"type": "string",
"format": "email",
"pattern": "^(?!\\.)(?!.*\\.\\.)([A-Za-z0-9_'+\\-\\.]*)[A-Za-z0-9_+-]@([A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$"
},
{
"type": "null"
}
],
"description": "Where replies to the site's shopper emails go, or null to reply to the From address."
},
"signInUrl": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"description": "Where shoppers sign in to the storefront. The loyalty widget sends a shopper who is not signed in there. Null leaves its sign-in hint as plain text."
},
"hostnames": {
"type": "array",
"items": {
"type": "object",
"properties": {
"id": {
"type": "string",
"description": "Unique identifier for the hostname.",
"idCodec": "sqid"
},
"siteId": {
"type": "string",
"description": "The site whose customer pages this hostname serves.",
"idCodec": "sqid"
},
"domainId": {
"type": "string",
"description": "The verified domain the hostname sits under.",
"idCodec": "sqid"
},
"hostname": {
"type": "string",
"description": "The hostname itself, lowercase."
},
"purpose": {
"anyOf": [
{
"type": "string",
"enum": ["reviews", "wishlists"],
"description": "Which links point at this hostname: `reviews` for review and unsubscribe pages, `wishlists` for shared wishlists."
},
{
"type": "null"
}
],
"description": "Which links point at this hostname, or null to use it for anything the site needs."
},
"active": {
"type": "boolean",
"description": "Whether a certificate has been issued, which is when links start using it."
},
"records": {
"type": "array",
"items": {
"type": "object",
"properties": {
"type": {
"type": "string",
"enum": ["TXT", "CNAME", "MX"],
"description": "The type of DNS record to create."
},
"name": {
"type": "string",
"description": "The fully qualified host the record goes on."
},
"value": {
"type": "string",
"description": "The value the record has to hold."
},
"purpose": {
"type": "string",
"enum": ["dkim", "return-path", "spf", "ownership", "pages", "acme"],
"description": "What the record is for: `dkim` and `return-path` for sending email, `spf` for the sender policy, `ownership` for proving you control the domain, `pages` for pointing a hostname at Meisei, and `acme` for issuing its certificate."
},
"verified": {
"type": "boolean",
"description": "Whether the record has been seen in DNS yet."
}
},
"required": ["type", "name", "value", "purpose", "verified"],
"additionalProperties": false
},
"description": "The DNS records the hostname needs, with what the provider can see so far."
},
"dnsConfiguredAt": {
"anyOf": [
{
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
},
{
"type": "null"
}
],
"description": "When the hostname was first seen pointing at Meisei."
},
"certificateIssuedAt": {
"anyOf": [
{
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
},
{
"type": "null"
}
],
"description": "When the certificate was issued, or null if it has not been yet."
},
"lastCheckedAt": {
"anyOf": [
{
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
},
{
"type": "null"
}
],
"description": "When Meisei last checked the hostname's DNS."
},
"createdAt": {
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$",
"description": "When the hostname was added."
},
"updatedAt": {
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$",
"description": "When the hostname was last changed."
}
},
"required": [
"id",
"siteId",
"domainId",
"hostname",
"purpose",
"active",
"records",
"dnsConfiguredAt",
"certificateIssuedAt",
"lastCheckedAt",
"createdAt",
"updatedAt"
],
"additionalProperties": false
},
"description": "The custom hostnames this site serves its customer pages on."
},
"createdAt": {
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$",
"description": "When the site was created."
},
"updatedAt": {
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$",
"description": "When the site was last changed."
}
},
"required": [
"id",
"name",
"slug",
"baseUrl",
"brandSettings",
"metadata",
"sendingDomainId",
"emailLocalPart",
"emailReplyTo",
"signInUrl",
"hostnames",
"createdAt",
"updatedAt"
],
"additionalProperties": false,
"description": "The requested site."
}PUT /sites/{id}
Update a site's details or branding. Fails if the new slug is already in use by another site. Triggers the site.updated webhook.
Requires the settings:write permission.
Path parameters
idstringrequiredThe ID of the site to update.
Body parameters
namestringThe site's display name.
slugstringA short handle for the site, unique within the organization.
baseUrlstring (uri)The storefront's base URL.
brandSettingsobjectChanges the branding keys given and leaves the others as they are.
metadataobjectReplaces the site's metadata wholesale. Omit to leave it alone.
sendingDomainIdstring | nullA verified domain to send this site's shopper emails from. It has to be set up for email first. Null sends them through Meisei instead.
emailLocalPartstring | nullThe part of the From address before the @, such as hello. Letters, numbers, dots, dashes and underscores only. Only used once the sending domain is verified for email.
emailReplyTostring (email) | nullWhere replies to this site's shopper emails go. Null replies to the From address.
signInUrlstring (uri) | nullThe storefront's sign-in page, as a full http or https URL. The loyalty widget links a shopper who is not signed in to it. Null takes the link away.
curl \
-X PUT \
"https://your-store.meisei.app/api/sites/A4Ws1igz" \
-H "Authorization: Bearer sk_YOUR_SECRET_KEY" \
-H "Content-Type: application/json" \
-d '{
"name": "string",
"slug": "string",
"baseUrl": "https://example.com",
"brandSettings": {
"logoKey": "string",
"iconKey": "string",
"primaryColor": "string",
"pageColor": "string",
"contentColor": "string",
"textColor": "string",
"mutedColor": "string"
},
"metadata": "...",
"sendingDomainId": "string",
"emailLocalPart": "string",
"emailReplyTo": "user@example.com",
"signInUrl": "https://example.com"
}'import { client } from "@meisei/api/admin/client"
import { putSitesById } from "@meisei/api/admin"
client.setConfig({
baseUrl: "https://your-store.meisei.app/api",
headers: { Authorization: "Bearer sk_YOUR_SECRET_KEY" },
})
const { data, error } = await putSitesById({
path: { id: "A4Ws1igz" },
body: {
name: "string",
slug: "string",
baseUrl: "https://example.com",
brandSettings: {
logoKey: "string",
iconKey: "string",
primaryColor: "string",
pageColor: "string",
contentColor: "string",
textColor: "string",
mutedColor: "string",
},
metadata: "...",
sendingDomainId: "string",
emailLocalPart: "string",
emailReplyTo: "user@example.com",
signInUrl: "https://example.com",
},
})require "meisei"
meisei = Meisei::Client.new(
secret_key: "sk_YOUR_SECRET_KEY",
base_url: "https://your-store.meisei.app/api",
)
result = meisei.sites.update(
"A4Ws1igz",
name: "string",
slug: "string",
base_url: "https://example.com",
brand_settings: {
logo_key: "string",
icon_key: "string",
primary_color: "string",
page_color: "string",
content_color: "string",
text_color: "string",
muted_color: "string",
},
metadata: "...",
sending_domain_id: "string",
email_local_part: "string",
email_reply_to: "user@example.com",
sign_in_url: "https://example.com",
)from meisei import Client
meisei = Client(
secret_key="sk_YOUR_SECRET_KEY",
base_url="https://your-store.meisei.app/api",
)
result = meisei.sites.update(
"A4Ws1igz",
name="string",
slug="string",
base_url="https://example.com",
brand_settings={
"logo_key": "string",
"icon_key": "string",
"primary_color": "string",
"page_color": "string",
"content_color": "string",
"text_color": "string",
"muted_color": "string",
},
metadata={},
sending_domain_id="string",
email_local_part="string",
email_reply_to="user@example.com",
sign_in_url="https://example.com",
){
"id": "A4Ws1igz",
"name": "string",
"slug": "string",
"baseUrl": "string",
"brandSettings": {
"primaryColor": "string",
"pageColor": "string",
"contentColor": "string",
"textColor": "string",
"mutedColor": "string",
"logoUrl": "https://example.com",
"iconUrl": "https://example.com"
},
"metadata": "...",
"sendingDomainId": "string",
"emailLocalPart": "string",
"emailReplyTo": "user@example.com",
"signInUrl": "string",
"hostnames": [
{
"id": "A4Ws1igz",
"siteId": "A4Ws1igz",
"domainId": "A4Ws1igz",
"hostname": "string",
"purpose": "reviews",
"active": true,
"records": ["..."],
"dnsConfiguredAt": "2025-01-15T09:30:00Z",
"certificateIssuedAt": "2025-01-15T09:30:00Z",
"lastCheckedAt": "2025-01-15T09:30:00Z",
"createdAt": "2025-01-15T09:30:00Z",
"updatedAt": "2025-01-15T09:30:00Z"
}
],
"createdAt": "2025-01-15T09:30:00Z",
"updatedAt": "2025-01-15T09:30:00Z"
}{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"type": "object",
"properties": {
"id": {
"type": "string",
"description": "Unique identifier for the site.",
"idCodec": "sqid"
},
"name": {
"type": "string",
"description": "The site's display name."
},
"slug": {
"type": "string",
"description": "The site's short handle, unique within the organization. Used by imports and widgets."
},
"baseUrl": {
"type": "string",
"description": "The storefront's base URL, used to build links back to it."
},
"brandSettings": {
"type": "object",
"properties": {
"primaryColor": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"description": "Accent color used for buttons and links, as a CSS color string."
},
"pageColor": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"description": "Page background color, as a CSS color string."
},
"contentColor": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"description": "Background color for cards and panels, as a CSS color string."
},
"textColor": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"description": "Body text color, as a CSS color string."
},
"mutedColor": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"description": "Color for secondary and helper text, as a CSS color string."
},
"logoUrl": {
"anyOf": [
{
"type": "string",
"format": "uri"
},
{
"type": "null"
}
],
"description": "Public URL of the site's logo image."
},
"iconUrl": {
"anyOf": [
{
"type": "string",
"format": "uri"
},
{
"type": "null"
}
],
"description": "Public URL of the site's square icon."
}
},
"required": [
"primaryColor",
"pageColor",
"contentColor",
"textColor",
"mutedColor",
"logoUrl",
"iconUrl"
],
"additionalProperties": false,
"description": "Colors and imagery used to brand emails and customer-facing pages for this site."
},
"metadata": {
"type": "object",
"propertyNames": {
"type": "string"
},
"additionalProperties": {
"anyOf": [
{
"type": "string"
},
{
"type": "number"
},
{
"type": "boolean"
},
{
"type": "array",
"items": {
"type": "string"
}
}
],
"description": "A metadata value: a string, a number, true or false, or a list of strings. A key with a metadata definition holds the type its definition names."
},
"description": "Key/value pairs for your own data. Keys you define with `/metadata-definitions` are typed and validated; any other key is free-form. Individual keys are filterable with a dot path, for example `metadata.category`."
},
"sendingDomainId": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"description": "The verified domain this site's shopper emails are sent from, or null to send through Meisei."
},
"emailLocalPart": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"description": "The part of the From address before the `@`, such as `hello`. Null means the site has no sending address of its own yet."
},
"emailReplyTo": {
"anyOf": [
{
"type": "string",
"format": "email",
"pattern": "^(?!\\.)(?!.*\\.\\.)([A-Za-z0-9_'+\\-\\.]*)[A-Za-z0-9_+-]@([A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$"
},
{
"type": "null"
}
],
"description": "Where replies to the site's shopper emails go, or null to reply to the From address."
},
"signInUrl": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"description": "Where shoppers sign in to the storefront. The loyalty widget sends a shopper who is not signed in there. Null leaves its sign-in hint as plain text."
},
"hostnames": {
"type": "array",
"items": {
"type": "object",
"properties": {
"id": {
"type": "string",
"description": "Unique identifier for the hostname.",
"idCodec": "sqid"
},
"siteId": {
"type": "string",
"description": "The site whose customer pages this hostname serves.",
"idCodec": "sqid"
},
"domainId": {
"type": "string",
"description": "The verified domain the hostname sits under.",
"idCodec": "sqid"
},
"hostname": {
"type": "string",
"description": "The hostname itself, lowercase."
},
"purpose": {
"anyOf": [
{
"type": "string",
"enum": ["reviews", "wishlists"],
"description": "Which links point at this hostname: `reviews` for review and unsubscribe pages, `wishlists` for shared wishlists."
},
{
"type": "null"
}
],
"description": "Which links point at this hostname, or null to use it for anything the site needs."
},
"active": {
"type": "boolean",
"description": "Whether a certificate has been issued, which is when links start using it."
},
"records": {
"type": "array",
"items": {
"type": "object",
"properties": {
"type": {
"type": "string",
"enum": ["TXT", "CNAME", "MX"],
"description": "The type of DNS record to create."
},
"name": {
"type": "string",
"description": "The fully qualified host the record goes on."
},
"value": {
"type": "string",
"description": "The value the record has to hold."
},
"purpose": {
"type": "string",
"enum": ["dkim", "return-path", "spf", "ownership", "pages", "acme"],
"description": "What the record is for: `dkim` and `return-path` for sending email, `spf` for the sender policy, `ownership` for proving you control the domain, `pages` for pointing a hostname at Meisei, and `acme` for issuing its certificate."
},
"verified": {
"type": "boolean",
"description": "Whether the record has been seen in DNS yet."
}
},
"required": ["type", "name", "value", "purpose", "verified"],
"additionalProperties": false
},
"description": "The DNS records the hostname needs, with what the provider can see so far."
},
"dnsConfiguredAt": {
"anyOf": [
{
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
},
{
"type": "null"
}
],
"description": "When the hostname was first seen pointing at Meisei."
},
"certificateIssuedAt": {
"anyOf": [
{
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
},
{
"type": "null"
}
],
"description": "When the certificate was issued, or null if it has not been yet."
},
"lastCheckedAt": {
"anyOf": [
{
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
},
{
"type": "null"
}
],
"description": "When Meisei last checked the hostname's DNS."
},
"createdAt": {
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$",
"description": "When the hostname was added."
},
"updatedAt": {
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$",
"description": "When the hostname was last changed."
}
},
"required": [
"id",
"siteId",
"domainId",
"hostname",
"purpose",
"active",
"records",
"dnsConfiguredAt",
"certificateIssuedAt",
"lastCheckedAt",
"createdAt",
"updatedAt"
],
"additionalProperties": false
},
"description": "The custom hostnames this site serves its customer pages on."
},
"createdAt": {
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$",
"description": "When the site was created."
},
"updatedAt": {
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$",
"description": "When the site was last changed."
}
},
"required": [
"id",
"name",
"slug",
"baseUrl",
"brandSettings",
"metadata",
"sendingDomainId",
"emailLocalPart",
"emailReplyTo",
"signInUrl",
"hostnames",
"createdAt",
"updatedAt"
],
"additionalProperties": false,
"description": "The updated site."
}DELETE /sites/{id}
Delete a site. It is marked for deletion straight away and its records are cleared out in the background, so the site keeps showing up briefly. You cannot delete an organization's last site. Triggers the site.deleted webhook.
Requires the settings:write permission.
Path parameters
idstringrequiredThe ID of the site to delete.
curl \
-X DELETE \
"https://your-store.meisei.app/api/sites/A4Ws1igz" \
-H "Authorization: Bearer sk_YOUR_SECRET_KEY"import { client } from "@meisei/api/admin/client"
import { deleteSitesById } from "@meisei/api/admin"
client.setConfig({
baseUrl: "https://your-store.meisei.app/api",
headers: { Authorization: "Bearer sk_YOUR_SECRET_KEY" },
})
const { data, error } = await deleteSitesById({
path: { id: "A4Ws1igz" },
})require "meisei"
meisei = Meisei::Client.new(
secret_key: "sk_YOUR_SECRET_KEY",
base_url: "https://your-store.meisei.app/api",
)
result = meisei.sites.delete("A4Ws1igz")from meisei import Client
meisei = Client(
secret_key="sk_YOUR_SECRET_KEY",
base_url="https://your-store.meisei.app/api",
)
result = meisei.sites.delete("A4Ws1igz"){
"id": "A4Ws1igz",
"name": "string",
"slug": "string",
"baseUrl": "string",
"brandSettings": {
"primaryColor": "string",
"pageColor": "string",
"contentColor": "string",
"textColor": "string",
"mutedColor": "string",
"logoUrl": "https://example.com",
"iconUrl": "https://example.com"
},
"metadata": "...",
"sendingDomainId": "string",
"emailLocalPart": "string",
"emailReplyTo": "user@example.com",
"signInUrl": "string",
"hostnames": [
{
"id": "A4Ws1igz",
"siteId": "A4Ws1igz",
"domainId": "A4Ws1igz",
"hostname": "string",
"purpose": "reviews",
"active": true,
"records": ["..."],
"dnsConfiguredAt": "2025-01-15T09:30:00Z",
"certificateIssuedAt": "2025-01-15T09:30:00Z",
"lastCheckedAt": "2025-01-15T09:30:00Z",
"createdAt": "2025-01-15T09:30:00Z",
"updatedAt": "2025-01-15T09:30:00Z"
}
],
"createdAt": "2025-01-15T09:30:00Z",
"updatedAt": "2025-01-15T09:30:00Z"
}{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"type": "object",
"properties": {
"id": {
"type": "string",
"description": "Unique identifier for the site.",
"idCodec": "sqid"
},
"name": {
"type": "string",
"description": "The site's display name."
},
"slug": {
"type": "string",
"description": "The site's short handle, unique within the organization. Used by imports and widgets."
},
"baseUrl": {
"type": "string",
"description": "The storefront's base URL, used to build links back to it."
},
"brandSettings": {
"type": "object",
"properties": {
"primaryColor": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"description": "Accent color used for buttons and links, as a CSS color string."
},
"pageColor": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"description": "Page background color, as a CSS color string."
},
"contentColor": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"description": "Background color for cards and panels, as a CSS color string."
},
"textColor": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"description": "Body text color, as a CSS color string."
},
"mutedColor": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"description": "Color for secondary and helper text, as a CSS color string."
},
"logoUrl": {
"anyOf": [
{
"type": "string",
"format": "uri"
},
{
"type": "null"
}
],
"description": "Public URL of the site's logo image."
},
"iconUrl": {
"anyOf": [
{
"type": "string",
"format": "uri"
},
{
"type": "null"
}
],
"description": "Public URL of the site's square icon."
}
},
"required": [
"primaryColor",
"pageColor",
"contentColor",
"textColor",
"mutedColor",
"logoUrl",
"iconUrl"
],
"additionalProperties": false,
"description": "Colors and imagery used to brand emails and customer-facing pages for this site."
},
"metadata": {
"type": "object",
"propertyNames": {
"type": "string"
},
"additionalProperties": {
"anyOf": [
{
"type": "string"
},
{
"type": "number"
},
{
"type": "boolean"
},
{
"type": "array",
"items": {
"type": "string"
}
}
],
"description": "A metadata value: a string, a number, true or false, or a list of strings. A key with a metadata definition holds the type its definition names."
},
"description": "Key/value pairs for your own data. Keys you define with `/metadata-definitions` are typed and validated; any other key is free-form. Individual keys are filterable with a dot path, for example `metadata.category`."
},
"sendingDomainId": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"description": "The verified domain this site's shopper emails are sent from, or null to send through Meisei."
},
"emailLocalPart": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"description": "The part of the From address before the `@`, such as `hello`. Null means the site has no sending address of its own yet."
},
"emailReplyTo": {
"anyOf": [
{
"type": "string",
"format": "email",
"pattern": "^(?!\\.)(?!.*\\.\\.)([A-Za-z0-9_'+\\-\\.]*)[A-Za-z0-9_+-]@([A-Za-z0-9][A-Za-z0-9\\-]*\\.)+[A-Za-z]{2,}$"
},
{
"type": "null"
}
],
"description": "Where replies to the site's shopper emails go, or null to reply to the From address."
},
"signInUrl": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"description": "Where shoppers sign in to the storefront. The loyalty widget sends a shopper who is not signed in there. Null leaves its sign-in hint as plain text."
},
"hostnames": {
"type": "array",
"items": {
"type": "object",
"properties": {
"id": {
"type": "string",
"description": "Unique identifier for the hostname.",
"idCodec": "sqid"
},
"siteId": {
"type": "string",
"description": "The site whose customer pages this hostname serves.",
"idCodec": "sqid"
},
"domainId": {
"type": "string",
"description": "The verified domain the hostname sits under.",
"idCodec": "sqid"
},
"hostname": {
"type": "string",
"description": "The hostname itself, lowercase."
},
"purpose": {
"anyOf": [
{
"type": "string",
"enum": ["reviews", "wishlists"],
"description": "Which links point at this hostname: `reviews` for review and unsubscribe pages, `wishlists` for shared wishlists."
},
{
"type": "null"
}
],
"description": "Which links point at this hostname, or null to use it for anything the site needs."
},
"active": {
"type": "boolean",
"description": "Whether a certificate has been issued, which is when links start using it."
},
"records": {
"type": "array",
"items": {
"type": "object",
"properties": {
"type": {
"type": "string",
"enum": ["TXT", "CNAME", "MX"],
"description": "The type of DNS record to create."
},
"name": {
"type": "string",
"description": "The fully qualified host the record goes on."
},
"value": {
"type": "string",
"description": "The value the record has to hold."
},
"purpose": {
"type": "string",
"enum": ["dkim", "return-path", "spf", "ownership", "pages", "acme"],
"description": "What the record is for: `dkim` and `return-path` for sending email, `spf` for the sender policy, `ownership` for proving you control the domain, `pages` for pointing a hostname at Meisei, and `acme` for issuing its certificate."
},
"verified": {
"type": "boolean",
"description": "Whether the record has been seen in DNS yet."
}
},
"required": ["type", "name", "value", "purpose", "verified"],
"additionalProperties": false
},
"description": "The DNS records the hostname needs, with what the provider can see so far."
},
"dnsConfiguredAt": {
"anyOf": [
{
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
},
{
"type": "null"
}
],
"description": "When the hostname was first seen pointing at Meisei."
},
"certificateIssuedAt": {
"anyOf": [
{
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
},
{
"type": "null"
}
],
"description": "When the certificate was issued, or null if it has not been yet."
},
"lastCheckedAt": {
"anyOf": [
{
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
},
{
"type": "null"
}
],
"description": "When Meisei last checked the hostname's DNS."
},
"createdAt": {
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$",
"description": "When the hostname was added."
},
"updatedAt": {
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$",
"description": "When the hostname was last changed."
}
},
"required": [
"id",
"siteId",
"domainId",
"hostname",
"purpose",
"active",
"records",
"dnsConfiguredAt",
"certificateIssuedAt",
"lastCheckedAt",
"createdAt",
"updatedAt"
],
"additionalProperties": false
},
"description": "The custom hostnames this site serves its customer pages on."
},
"createdAt": {
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$",
"description": "When the site was created."
},
"updatedAt": {
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$",
"description": "When the site was last changed."
}
},
"required": [
"id",
"name",
"slug",
"baseUrl",
"brandSettings",
"metadata",
"sendingDomainId",
"emailLocalPart",
"emailReplyTo",
"signInUrl",
"hostnames",
"createdAt",
"updatedAt"
],
"additionalProperties": false,
"description": "The site now marked for deletion."
}GET /sites/{siteId}/hostnames
List the custom hostnames a site serves its customer pages on, alphabetically.
Requires the settings:read permission.
Path parameters
siteIdstringrequiredThe ID of the site.
curl \
"https://your-store.meisei.app/api/sites/A4Ws1igz/hostnames" \
-H "Authorization: Bearer sk_YOUR_SECRET_KEY"import { client } from "@meisei/api/admin/client"
import { getSitesBySiteIdHostnames } from "@meisei/api/admin"
client.setConfig({
baseUrl: "https://your-store.meisei.app/api",
headers: { Authorization: "Bearer sk_YOUR_SECRET_KEY" },
})
const { data, error } = await getSitesBySiteIdHostnames({
path: { siteId: "A4Ws1igz" },
})require "meisei"
meisei = Meisei::Client.new(
secret_key: "sk_YOUR_SECRET_KEY",
base_url: "https://your-store.meisei.app/api",
)
page = meisei.sites.hostnames.list("A4Ws1igz")from meisei import Client
meisei = Client(
secret_key="sk_YOUR_SECRET_KEY",
base_url="https://your-store.meisei.app/api",
)
page = meisei.sites.hostnames.list("A4Ws1igz"){
"data": [
{
"id": "A4Ws1igz",
"siteId": "A4Ws1igz",
"domainId": "A4Ws1igz",
"hostname": "string",
"purpose": "reviews",
"active": true,
"records": ["..."],
"dnsConfiguredAt": "2025-01-15T09:30:00Z",
"certificateIssuedAt": "2025-01-15T09:30:00Z",
"lastCheckedAt": "2025-01-15T09:30:00Z",
"createdAt": "2025-01-15T09:30:00Z",
"updatedAt": "2025-01-15T09:30:00Z"
}
]
}{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"type": "object",
"properties": {
"data": {
"type": "array",
"items": {
"type": "object",
"properties": {
"id": {
"type": "string",
"description": "Unique identifier for the hostname.",
"idCodec": "sqid"
},
"siteId": {
"type": "string",
"description": "The site whose customer pages this hostname serves.",
"idCodec": "sqid"
},
"domainId": {
"type": "string",
"description": "The verified domain the hostname sits under.",
"idCodec": "sqid"
},
"hostname": {
"type": "string",
"description": "The hostname itself, lowercase."
},
"purpose": {
"anyOf": [
{
"type": "string",
"enum": ["reviews", "wishlists"],
"description": "Which links point at this hostname: `reviews` for review and unsubscribe pages, `wishlists` for shared wishlists."
},
{
"type": "null"
}
],
"description": "Which links point at this hostname, or null to use it for anything the site needs."
},
"active": {
"type": "boolean",
"description": "Whether a certificate has been issued, which is when links start using it."
},
"records": {
"type": "array",
"items": {
"type": "object",
"properties": {
"type": {
"type": "string",
"enum": ["TXT", "CNAME", "MX"],
"description": "The type of DNS record to create."
},
"name": {
"type": "string",
"description": "The fully qualified host the record goes on."
},
"value": {
"type": "string",
"description": "The value the record has to hold."
},
"purpose": {
"type": "string",
"enum": ["dkim", "return-path", "spf", "ownership", "pages", "acme"],
"description": "What the record is for: `dkim` and `return-path` for sending email, `spf` for the sender policy, `ownership` for proving you control the domain, `pages` for pointing a hostname at Meisei, and `acme` for issuing its certificate."
},
"verified": {
"type": "boolean",
"description": "Whether the record has been seen in DNS yet."
}
},
"required": ["type", "name", "value", "purpose", "verified"],
"additionalProperties": false
},
"description": "The DNS records the hostname needs, with what the provider can see so far."
},
"dnsConfiguredAt": {
"anyOf": [
{
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
},
{
"type": "null"
}
],
"description": "When the hostname was first seen pointing at Meisei."
},
"certificateIssuedAt": {
"anyOf": [
{
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
},
{
"type": "null"
}
],
"description": "When the certificate was issued, or null if it has not been yet."
},
"lastCheckedAt": {
"anyOf": [
{
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
},
{
"type": "null"
}
],
"description": "When Meisei last checked the hostname's DNS."
},
"createdAt": {
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$",
"description": "When the hostname was added."
},
"updatedAt": {
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$",
"description": "When the hostname was last changed."
}
},
"required": [
"id",
"siteId",
"domainId",
"hostname",
"purpose",
"active",
"records",
"dnsConfiguredAt",
"certificateIssuedAt",
"lastCheckedAt",
"createdAt",
"updatedAt"
],
"additionalProperties": false
},
"description": "The site's hostnames."
}
},
"required": ["data"],
"additionalProperties": false
}POST /sites/{siteId}/hostnames
Add a hostname for a site's customer pages. It has to be one of your verified domains or a name under one. The response carries the DNS records to create; call POST /sites/:siteId/hostnames/:id/check once they are in place.
Requires the settings:write permission.
Costs 5 rate limit tokens instead of the usual one. See Rate limits.
Path parameters
siteIdstringrequiredThe ID of the site.
Body parameters
hostnamestringrequiredThe hostname to serve customer pages on, such as reviews.example.com. It has to be one of your verified domains or a name under one.
purposereviews | wishlists | nullWhich links should point at this hostname. Leave it out to use the hostname for anything the site needs.
curl \
-X POST \
"https://your-store.meisei.app/api/sites/A4Ws1igz/hostnames" \
-H "Authorization: Bearer sk_YOUR_SECRET_KEY" \
-H "Content-Type: application/json" \
-d '{
"hostname": "string",
"purpose": "reviews"
}'import { client } from "@meisei/api/admin/client"
import { postSitesBySiteIdHostnames } from "@meisei/api/admin"
client.setConfig({
baseUrl: "https://your-store.meisei.app/api",
headers: { Authorization: "Bearer sk_YOUR_SECRET_KEY" },
})
const { data, error } = await postSitesBySiteIdHostnames({
path: { siteId: "A4Ws1igz" },
body: {
hostname: "string",
purpose: "reviews",
},
})require "meisei"
meisei = Meisei::Client.new(
secret_key: "sk_YOUR_SECRET_KEY",
base_url: "https://your-store.meisei.app/api",
)
result = meisei.sites.hostnames.create(
"A4Ws1igz",
hostname: "string",
purpose: "reviews",
)from meisei import Client
meisei = Client(
secret_key="sk_YOUR_SECRET_KEY",
base_url="https://your-store.meisei.app/api",
)
result = meisei.sites.hostnames.create(
"A4Ws1igz",
hostname="string",
purpose="reviews",
){
"id": "A4Ws1igz",
"siteId": "A4Ws1igz",
"domainId": "A4Ws1igz",
"hostname": "string",
"purpose": "reviews",
"active": true,
"records": [
{
"type": "TXT",
"name": "string",
"value": "string",
"purpose": "dkim",
"verified": true
}
],
"dnsConfiguredAt": "2025-01-15T09:30:00Z",
"certificateIssuedAt": "2025-01-15T09:30:00Z",
"lastCheckedAt": "2025-01-15T09:30:00Z",
"createdAt": "2025-01-15T09:30:00Z",
"updatedAt": "2025-01-15T09:30:00Z"
}{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"type": "object",
"properties": {
"id": {
"type": "string",
"description": "Unique identifier for the hostname.",
"idCodec": "sqid"
},
"siteId": {
"type": "string",
"description": "The site whose customer pages this hostname serves.",
"idCodec": "sqid"
},
"domainId": {
"type": "string",
"description": "The verified domain the hostname sits under.",
"idCodec": "sqid"
},
"hostname": {
"type": "string",
"description": "The hostname itself, lowercase."
},
"purpose": {
"anyOf": [
{
"type": "string",
"enum": ["reviews", "wishlists"],
"description": "Which links point at this hostname: `reviews` for review and unsubscribe pages, `wishlists` for shared wishlists."
},
{
"type": "null"
}
],
"description": "Which links point at this hostname, or null to use it for anything the site needs."
},
"active": {
"type": "boolean",
"description": "Whether a certificate has been issued, which is when links start using it."
},
"records": {
"type": "array",
"items": {
"type": "object",
"properties": {
"type": {
"type": "string",
"enum": ["TXT", "CNAME", "MX"],
"description": "The type of DNS record to create."
},
"name": {
"type": "string",
"description": "The fully qualified host the record goes on."
},
"value": {
"type": "string",
"description": "The value the record has to hold."
},
"purpose": {
"type": "string",
"enum": ["dkim", "return-path", "spf", "ownership", "pages", "acme"],
"description": "What the record is for: `dkim` and `return-path` for sending email, `spf` for the sender policy, `ownership` for proving you control the domain, `pages` for pointing a hostname at Meisei, and `acme` for issuing its certificate."
},
"verified": {
"type": "boolean",
"description": "Whether the record has been seen in DNS yet."
}
},
"required": ["type", "name", "value", "purpose", "verified"],
"additionalProperties": false
},
"description": "The DNS records the hostname needs, with what the provider can see so far."
},
"dnsConfiguredAt": {
"anyOf": [
{
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
},
{
"type": "null"
}
],
"description": "When the hostname was first seen pointing at Meisei."
},
"certificateIssuedAt": {
"anyOf": [
{
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
},
{
"type": "null"
}
],
"description": "When the certificate was issued, or null if it has not been yet."
},
"lastCheckedAt": {
"anyOf": [
{
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
},
{
"type": "null"
}
],
"description": "When Meisei last checked the hostname's DNS."
},
"createdAt": {
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$",
"description": "When the hostname was added."
},
"updatedAt": {
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$",
"description": "When the hostname was last changed."
}
},
"required": [
"id",
"siteId",
"domainId",
"hostname",
"purpose",
"active",
"records",
"dnsConfiguredAt",
"certificateIssuedAt",
"lastCheckedAt",
"createdAt",
"updatedAt"
],
"additionalProperties": false,
"description": "The new hostname, with the records to create."
}PATCH /sites/{siteId}/hostnames/{id}
Change which links point at a hostname. Its certificate and records are kept, so a hostname that is already live stays live.
Requires the settings:write permission.
Path parameters
siteIdstringrequiredThe ID of the site.
idstringrequiredThe ID of the hostname.
Body parameters
purposereviews | wishlists | nullrequiredWhich links should point at this hostname from now on. Null uses it for anything the site needs.
curl \
-X PATCH \
"https://your-store.meisei.app/api/sites/A4Ws1igz/hostnames/A4Ws1igz" \
-H "Authorization: Bearer sk_YOUR_SECRET_KEY" \
-H "Content-Type: application/json" \
-d '{
"purpose": "reviews"
}'import { client } from "@meisei/api/admin/client"
import { patchSitesBySiteIdHostnamesById } from "@meisei/api/admin"
client.setConfig({
baseUrl: "https://your-store.meisei.app/api",
headers: { Authorization: "Bearer sk_YOUR_SECRET_KEY" },
})
const { data, error } = await patchSitesBySiteIdHostnamesById({
path: { siteId: "A4Ws1igz", id: "A4Ws1igz" },
body: {
purpose: "reviews",
},
})require "meisei"
meisei = Meisei::Client.new(
secret_key: "sk_YOUR_SECRET_KEY",
base_url: "https://your-store.meisei.app/api",
)
result = meisei.sites.hostnames.update(
"A4Ws1igz",
"A4Ws1igz",
purpose: "reviews",
)from meisei import Client
meisei = Client(
secret_key="sk_YOUR_SECRET_KEY",
base_url="https://your-store.meisei.app/api",
)
result = meisei.sites.hostnames.update(
"A4Ws1igz",
"A4Ws1igz",
purpose="reviews",
){
"id": "A4Ws1igz",
"siteId": "A4Ws1igz",
"domainId": "A4Ws1igz",
"hostname": "string",
"purpose": "reviews",
"active": true,
"records": [
{
"type": "TXT",
"name": "string",
"value": "string",
"purpose": "dkim",
"verified": true
}
],
"dnsConfiguredAt": "2025-01-15T09:30:00Z",
"certificateIssuedAt": "2025-01-15T09:30:00Z",
"lastCheckedAt": "2025-01-15T09:30:00Z",
"createdAt": "2025-01-15T09:30:00Z",
"updatedAt": "2025-01-15T09:30:00Z"
}{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"type": "object",
"properties": {
"id": {
"type": "string",
"description": "Unique identifier for the hostname.",
"idCodec": "sqid"
},
"siteId": {
"type": "string",
"description": "The site whose customer pages this hostname serves.",
"idCodec": "sqid"
},
"domainId": {
"type": "string",
"description": "The verified domain the hostname sits under.",
"idCodec": "sqid"
},
"hostname": {
"type": "string",
"description": "The hostname itself, lowercase."
},
"purpose": {
"anyOf": [
{
"type": "string",
"enum": ["reviews", "wishlists"],
"description": "Which links point at this hostname: `reviews` for review and unsubscribe pages, `wishlists` for shared wishlists."
},
{
"type": "null"
}
],
"description": "Which links point at this hostname, or null to use it for anything the site needs."
},
"active": {
"type": "boolean",
"description": "Whether a certificate has been issued, which is when links start using it."
},
"records": {
"type": "array",
"items": {
"type": "object",
"properties": {
"type": {
"type": "string",
"enum": ["TXT", "CNAME", "MX"],
"description": "The type of DNS record to create."
},
"name": {
"type": "string",
"description": "The fully qualified host the record goes on."
},
"value": {
"type": "string",
"description": "The value the record has to hold."
},
"purpose": {
"type": "string",
"enum": ["dkim", "return-path", "spf", "ownership", "pages", "acme"],
"description": "What the record is for: `dkim` and `return-path` for sending email, `spf` for the sender policy, `ownership` for proving you control the domain, `pages` for pointing a hostname at Meisei, and `acme` for issuing its certificate."
},
"verified": {
"type": "boolean",
"description": "Whether the record has been seen in DNS yet."
}
},
"required": ["type", "name", "value", "purpose", "verified"],
"additionalProperties": false
},
"description": "The DNS records the hostname needs, with what the provider can see so far."
},
"dnsConfiguredAt": {
"anyOf": [
{
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
},
{
"type": "null"
}
],
"description": "When the hostname was first seen pointing at Meisei."
},
"certificateIssuedAt": {
"anyOf": [
{
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
},
{
"type": "null"
}
],
"description": "When the certificate was issued, or null if it has not been yet."
},
"lastCheckedAt": {
"anyOf": [
{
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
},
{
"type": "null"
}
],
"description": "When Meisei last checked the hostname's DNS."
},
"createdAt": {
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$",
"description": "When the hostname was added."
},
"updatedAt": {
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$",
"description": "When the hostname was last changed."
}
},
"required": [
"id",
"siteId",
"domainId",
"hostname",
"purpose",
"active",
"records",
"dnsConfiguredAt",
"certificateIssuedAt",
"lastCheckedAt",
"createdAt",
"updatedAt"
],
"additionalProperties": false,
"description": "The hostname as it now stands."
}DELETE /sites/{siteId}/hostnames/{id}
Remove a hostname and its certificate. Links that were pointing at it go back to the Meisei-hosted pages.
Requires the settings:write permission.
Path parameters
siteIdstringrequiredThe ID of the site.
idstringrequiredThe ID of the hostname.
curl \
-X DELETE \
"https://your-store.meisei.app/api/sites/A4Ws1igz/hostnames/A4Ws1igz" \
-H "Authorization: Bearer sk_YOUR_SECRET_KEY"import { client } from "@meisei/api/admin/client"
import { deleteSitesBySiteIdHostnamesById } from "@meisei/api/admin"
client.setConfig({
baseUrl: "https://your-store.meisei.app/api",
headers: { Authorization: "Bearer sk_YOUR_SECRET_KEY" },
})
const { data, error } = await deleteSitesBySiteIdHostnamesById({
path: { siteId: "A4Ws1igz", id: "A4Ws1igz" },
})require "meisei"
meisei = Meisei::Client.new(
secret_key: "sk_YOUR_SECRET_KEY",
base_url: "https://your-store.meisei.app/api",
)
result = meisei.sites.hostnames.delete("A4Ws1igz", "A4Ws1igz")from meisei import Client
meisei = Client(
secret_key="sk_YOUR_SECRET_KEY",
base_url="https://your-store.meisei.app/api",
)
result = meisei.sites.hostnames.delete("A4Ws1igz", "A4Ws1igz"){
"id": "A4Ws1igz",
"siteId": "A4Ws1igz",
"domainId": "A4Ws1igz",
"hostname": "string",
"purpose": "reviews",
"active": true,
"records": [
{
"type": "TXT",
"name": "string",
"value": "string",
"purpose": "dkim",
"verified": true
}
],
"dnsConfiguredAt": "2025-01-15T09:30:00Z",
"certificateIssuedAt": "2025-01-15T09:30:00Z",
"lastCheckedAt": "2025-01-15T09:30:00Z",
"createdAt": "2025-01-15T09:30:00Z",
"updatedAt": "2025-01-15T09:30:00Z"
}{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"type": "object",
"properties": {
"id": {
"type": "string",
"description": "Unique identifier for the hostname.",
"idCodec": "sqid"
},
"siteId": {
"type": "string",
"description": "The site whose customer pages this hostname serves.",
"idCodec": "sqid"
},
"domainId": {
"type": "string",
"description": "The verified domain the hostname sits under.",
"idCodec": "sqid"
},
"hostname": {
"type": "string",
"description": "The hostname itself, lowercase."
},
"purpose": {
"anyOf": [
{
"type": "string",
"enum": ["reviews", "wishlists"],
"description": "Which links point at this hostname: `reviews` for review and unsubscribe pages, `wishlists` for shared wishlists."
},
{
"type": "null"
}
],
"description": "Which links point at this hostname, or null to use it for anything the site needs."
},
"active": {
"type": "boolean",
"description": "Whether a certificate has been issued, which is when links start using it."
},
"records": {
"type": "array",
"items": {
"type": "object",
"properties": {
"type": {
"type": "string",
"enum": ["TXT", "CNAME", "MX"],
"description": "The type of DNS record to create."
},
"name": {
"type": "string",
"description": "The fully qualified host the record goes on."
},
"value": {
"type": "string",
"description": "The value the record has to hold."
},
"purpose": {
"type": "string",
"enum": ["dkim", "return-path", "spf", "ownership", "pages", "acme"],
"description": "What the record is for: `dkim` and `return-path` for sending email, `spf` for the sender policy, `ownership` for proving you control the domain, `pages` for pointing a hostname at Meisei, and `acme` for issuing its certificate."
},
"verified": {
"type": "boolean",
"description": "Whether the record has been seen in DNS yet."
}
},
"required": ["type", "name", "value", "purpose", "verified"],
"additionalProperties": false
},
"description": "The DNS records the hostname needs, with what the provider can see so far."
},
"dnsConfiguredAt": {
"anyOf": [
{
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
},
{
"type": "null"
}
],
"description": "When the hostname was first seen pointing at Meisei."
},
"certificateIssuedAt": {
"anyOf": [
{
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
},
{
"type": "null"
}
],
"description": "When the certificate was issued, or null if it has not been yet."
},
"lastCheckedAt": {
"anyOf": [
{
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
},
{
"type": "null"
}
],
"description": "When Meisei last checked the hostname's DNS."
},
"createdAt": {
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$",
"description": "When the hostname was added."
},
"updatedAt": {
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$",
"description": "When the hostname was last changed."
}
},
"required": [
"id",
"siteId",
"domainId",
"hostname",
"purpose",
"active",
"records",
"dnsConfiguredAt",
"certificateIssuedAt",
"lastCheckedAt",
"createdAt",
"updatedAt"
],
"additionalProperties": false,
"description": "The hostname that was removed."
}POST /sites/{siteId}/hostnames/{id}/check
Check the hostname's DNS now and report what the certificate provider can see. Once a certificate has been issued, the site's links start using the hostname.
Requires the settings:write permission.
Costs 5 rate limit tokens instead of the usual one. See Rate limits.
Path parameters
siteIdstringrequiredThe ID of the site.
idstringrequiredThe ID of the hostname.
curl \
-X POST \
"https://your-store.meisei.app/api/sites/A4Ws1igz/hostnames/A4Ws1igz/check" \
-H "Authorization: Bearer sk_YOUR_SECRET_KEY"import { client } from "@meisei/api/admin/client"
import { postSitesBySiteIdHostnamesByIdCheck } from "@meisei/api/admin"
client.setConfig({
baseUrl: "https://your-store.meisei.app/api",
headers: { Authorization: "Bearer sk_YOUR_SECRET_KEY" },
})
const { data, error } = await postSitesBySiteIdHostnamesByIdCheck({
path: { siteId: "A4Ws1igz", id: "A4Ws1igz" },
})require "meisei"
meisei = Meisei::Client.new(
secret_key: "sk_YOUR_SECRET_KEY",
base_url: "https://your-store.meisei.app/api",
)
result = meisei.sites.hostnames.check("A4Ws1igz", "A4Ws1igz")from meisei import Client
meisei = Client(
secret_key="sk_YOUR_SECRET_KEY",
base_url="https://your-store.meisei.app/api",
)
result = meisei.sites.hostnames.check("A4Ws1igz", "A4Ws1igz"){
"id": "A4Ws1igz",
"siteId": "A4Ws1igz",
"domainId": "A4Ws1igz",
"hostname": "string",
"purpose": "reviews",
"active": true,
"records": [
{
"type": "TXT",
"name": "string",
"value": "string",
"purpose": "dkim",
"verified": true
}
],
"dnsConfiguredAt": "2025-01-15T09:30:00Z",
"certificateIssuedAt": "2025-01-15T09:30:00Z",
"lastCheckedAt": "2025-01-15T09:30:00Z",
"createdAt": "2025-01-15T09:30:00Z",
"updatedAt": "2025-01-15T09:30:00Z"
}{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"type": "object",
"properties": {
"id": {
"type": "string",
"description": "Unique identifier for the hostname.",
"idCodec": "sqid"
},
"siteId": {
"type": "string",
"description": "The site whose customer pages this hostname serves.",
"idCodec": "sqid"
},
"domainId": {
"type": "string",
"description": "The verified domain the hostname sits under.",
"idCodec": "sqid"
},
"hostname": {
"type": "string",
"description": "The hostname itself, lowercase."
},
"purpose": {
"anyOf": [
{
"type": "string",
"enum": ["reviews", "wishlists"],
"description": "Which links point at this hostname: `reviews` for review and unsubscribe pages, `wishlists` for shared wishlists."
},
{
"type": "null"
}
],
"description": "Which links point at this hostname, or null to use it for anything the site needs."
},
"active": {
"type": "boolean",
"description": "Whether a certificate has been issued, which is when links start using it."
},
"records": {
"type": "array",
"items": {
"type": "object",
"properties": {
"type": {
"type": "string",
"enum": ["TXT", "CNAME", "MX"],
"description": "The type of DNS record to create."
},
"name": {
"type": "string",
"description": "The fully qualified host the record goes on."
},
"value": {
"type": "string",
"description": "The value the record has to hold."
},
"purpose": {
"type": "string",
"enum": ["dkim", "return-path", "spf", "ownership", "pages", "acme"],
"description": "What the record is for: `dkim` and `return-path` for sending email, `spf` for the sender policy, `ownership` for proving you control the domain, `pages` for pointing a hostname at Meisei, and `acme` for issuing its certificate."
},
"verified": {
"type": "boolean",
"description": "Whether the record has been seen in DNS yet."
}
},
"required": ["type", "name", "value", "purpose", "verified"],
"additionalProperties": false
},
"description": "The DNS records the hostname needs, with what the provider can see so far."
},
"dnsConfiguredAt": {
"anyOf": [
{
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
},
{
"type": "null"
}
],
"description": "When the hostname was first seen pointing at Meisei."
},
"certificateIssuedAt": {
"anyOf": [
{
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
},
{
"type": "null"
}
],
"description": "When the certificate was issued, or null if it has not been yet."
},
"lastCheckedAt": {
"anyOf": [
{
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$"
},
{
"type": "null"
}
],
"description": "When Meisei last checked the hostname's DNS."
},
"createdAt": {
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$",
"description": "When the hostname was added."
},
"updatedAt": {
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$",
"description": "When the hostname was last changed."
}
},
"required": [
"id",
"siteId",
"domainId",
"hostname",
"purpose",
"active",
"records",
"dnsConfiguredAt",
"certificateIssuedAt",
"lastCheckedAt",
"createdAt",
"updatedAt"
],
"additionalProperties": false,
"description": "The hostname as it now stands."
}GET /sites/{siteId}/brand-assets
List the images and files uploaded for a site's branding, along with how much of the storage allowance they use.
Requires the settings:read permission.
Path parameters
siteIdstringrequiredThe ID of the site.
curl \
"https://your-store.meisei.app/api/sites/A4Ws1igz/brand-assets" \
-H "Authorization: Bearer sk_YOUR_SECRET_KEY"import { client } from "@meisei/api/admin/client"
import { getSitesBySiteIdBrandAssets } from "@meisei/api/admin"
client.setConfig({
baseUrl: "https://your-store.meisei.app/api",
headers: { Authorization: "Bearer sk_YOUR_SECRET_KEY" },
})
const { data, error } = await getSitesBySiteIdBrandAssets({
path: { siteId: "A4Ws1igz" },
})require "meisei"
meisei = Meisei::Client.new(
secret_key: "sk_YOUR_SECRET_KEY",
base_url: "https://your-store.meisei.app/api",
)
page = meisei.sites.brand_assets.list("A4Ws1igz")from meisei import Client
meisei = Client(
secret_key="sk_YOUR_SECRET_KEY",
base_url="https://your-store.meisei.app/api",
)
page = meisei.sites.brand_assets.list("A4Ws1igz"){
"data": [
{
"id": "A4Ws1igz",
"name": "string",
"url": "string",
"sizeBytes": 0,
"createdAt": "2025-01-15T09:30:00Z"
}
],
"totalSizeBytes": 0,
"limitBytes": 0
}{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"type": "object",
"properties": {
"data": {
"type": "array",
"items": {
"type": "object",
"properties": {
"id": {
"type": "string",
"description": "Unique identifier for the brand asset.",
"idCodec": "sqid"
},
"name": {
"type": "string",
"description": "The original file name, unique within the site."
},
"url": {
"type": "string",
"description": "Public URL the asset is served from."
},
"sizeBytes": {
"anyOf": [
{
"type": "number"
},
{
"type": "null"
}
],
"description": "Size of the file in bytes, or null if the upload never completed."
},
"createdAt": {
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$",
"description": "When the asset was added to the site."
}
},
"required": ["id", "name", "url", "sizeBytes", "createdAt"],
"additionalProperties": false
},
"description": "The site's brand assets, oldest first."
},
"totalSizeBytes": {
"type": "number",
"description": "Combined size of every brand asset on the site, in bytes."
},
"limitBytes": {
"type": "number",
"description": "How many bytes of brand assets the organization's plan allows per site."
}
},
"required": ["data", "totalSizeBytes", "limitBytes"],
"additionalProperties": false
}POST /sites/{siteId}/brand-assets
Attach an already-uploaded file to a site as a brand asset. Upload the file first with POST /files/upload-url, then pass the key it returns.
Requires the settings:write permission.
Path parameters
siteIdstringrequiredThe ID of the site.
Body parameters
keystringrequiredThe storage key returned by POST /files/upload-url for the uploaded file.
curl \
-X POST \
"https://your-store.meisei.app/api/sites/A4Ws1igz/brand-assets" \
-H "Authorization: Bearer sk_YOUR_SECRET_KEY" \
-H "Content-Type: application/json" \
-d '{
"key": "string"
}'import { client } from "@meisei/api/admin/client"
import { postSitesBySiteIdBrandAssets } from "@meisei/api/admin"
client.setConfig({
baseUrl: "https://your-store.meisei.app/api",
headers: { Authorization: "Bearer sk_YOUR_SECRET_KEY" },
})
const { data, error } = await postSitesBySiteIdBrandAssets({
path: { siteId: "A4Ws1igz" },
body: {
key: "string",
},
})require "meisei"
meisei = Meisei::Client.new(
secret_key: "sk_YOUR_SECRET_KEY",
base_url: "https://your-store.meisei.app/api",
)
result = meisei.sites.brand_assets.create("A4Ws1igz", key: "string")from meisei import Client
meisei = Client(
secret_key="sk_YOUR_SECRET_KEY",
base_url="https://your-store.meisei.app/api",
)
result = meisei.sites.brand_assets.create("A4Ws1igz", key="string"){
"id": "A4Ws1igz",
"name": "string",
"url": "string",
"sizeBytes": 0,
"createdAt": "2025-01-15T09:30:00Z"
}{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"type": "object",
"properties": {
"id": {
"type": "string",
"description": "Unique identifier for the brand asset.",
"idCodec": "sqid"
},
"name": {
"type": "string",
"description": "The original file name, unique within the site."
},
"url": {
"type": "string",
"description": "Public URL the asset is served from."
},
"sizeBytes": {
"anyOf": [
{
"type": "number"
},
{
"type": "null"
}
],
"description": "Size of the file in bytes, or null if the upload never completed."
},
"createdAt": {
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$",
"description": "When the asset was added to the site."
}
},
"required": ["id", "name", "url", "sizeBytes", "createdAt"],
"additionalProperties": false,
"description": "The new brand asset."
}DELETE /sites/{siteId}/brand-assets/{fileId}
Delete a brand asset. Anything still pointing at its URL, such as an email template, will break.
Requires the settings:write permission.
Path parameters
siteIdstringrequiredThe ID of the site the asset belongs to.
fileIdstringrequiredThe ID of the brand asset to delete.
curl \
-X DELETE \
"https://your-store.meisei.app/api/sites/A4Ws1igz/brand-assets/A4Ws1igz" \
-H "Authorization: Bearer sk_YOUR_SECRET_KEY"import { client } from "@meisei/api/admin/client"
import { deleteSitesBySiteIdBrandAssetsByFileId } from "@meisei/api/admin"
client.setConfig({
baseUrl: "https://your-store.meisei.app/api",
headers: { Authorization: "Bearer sk_YOUR_SECRET_KEY" },
})
const { data, error } = await deleteSitesBySiteIdBrandAssetsByFileId({
path: { siteId: "A4Ws1igz", fileId: "A4Ws1igz" },
})require "meisei"
meisei = Meisei::Client.new(
secret_key: "sk_YOUR_SECRET_KEY",
base_url: "https://your-store.meisei.app/api",
)
result = meisei.sites.brand_assets.delete("A4Ws1igz", "A4Ws1igz")from meisei import Client
meisei = Client(
secret_key="sk_YOUR_SECRET_KEY",
base_url="https://your-store.meisei.app/api",
)
result = meisei.sites.brand_assets.delete("A4Ws1igz", "A4Ws1igz"){
"id": "A4Ws1igz",
"name": "string",
"url": "string",
"sizeBytes": 0,
"createdAt": "2025-01-15T09:30:00Z"
}{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"type": "object",
"properties": {
"id": {
"type": "string",
"description": "Unique identifier for the brand asset.",
"idCodec": "sqid"
},
"name": {
"type": "string",
"description": "The original file name, unique within the site."
},
"url": {
"type": "string",
"description": "Public URL the asset is served from."
},
"sizeBytes": {
"anyOf": [
{
"type": "number"
},
{
"type": "null"
}
],
"description": "Size of the file in bytes, or null if the upload never completed."
},
"createdAt": {
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$",
"description": "When the asset was added to the site."
}
},
"required": ["id", "name", "url", "sizeBytes", "createdAt"],
"additionalProperties": false,
"description": "The deleted brand asset."
}GET /sites/{id}/widget-theme
Get how the storefront widgets look on one site: every property with the defaults filled in, the subset this site has actually changed, and the URL the widgets load the stylesheet from.
Requires the settings:read permission.
Path parameters
idstringrequiredThe ID of the site.
curl \
"https://your-store.meisei.app/api/sites/A4Ws1igz/widget-theme" \
-H "Authorization: Bearer sk_YOUR_SECRET_KEY"import { client } from "@meisei/api/admin/client"
import { getSitesByIdWidgetTheme } from "@meisei/api/admin"
client.setConfig({
baseUrl: "https://your-store.meisei.app/api",
headers: { Authorization: "Bearer sk_YOUR_SECRET_KEY" },
})
const { data, error } = await getSitesByIdWidgetTheme({
path: { id: "A4Ws1igz" },
})require "meisei"
meisei = Meisei::Client.new(
secret_key: "sk_YOUR_SECRET_KEY",
base_url: "https://your-store.meisei.app/api",
)
result = meisei.sites.widget_theme.retrieve("A4Ws1igz")from meisei import Client
meisei = Client(
secret_key="sk_YOUR_SECRET_KEY",
base_url="https://your-store.meisei.app/api",
)
result = meisei.sites.widget_theme.retrieve("A4Ws1igz"){
"siteId": "A4Ws1igz",
"theme": {
"fontFamily": "string",
"text": "string",
"mutedText": "string",
"surface": "string",
"surfaceMuted": "string",
"border": "string",
"accent": "string",
"accentText": "string",
"star": "string",
"danger": "string",
"radius": "string",
"customCss": "string"
},
"overrides": {
"fontFamily": "string",
"text": "string",
"mutedText": "string",
"surface": "string",
"surfaceMuted": "string",
"border": "string",
"accent": "string",
"accentText": "string",
"star": "string",
"danger": "string",
"radius": "string",
"customCss": "string"
},
"stylesheetUrl": "string",
"notes": ["string"]
}{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"type": "object",
"properties": {
"siteId": {
"type": "string",
"description": "The site this appearance belongs to.",
"idCodec": "sqid"
},
"theme": {
"type": "object",
"properties": {
"fontFamily": {
"type": "string",
"description": "The font stack the widgets use, as a CSS `font-family` value. `inherit` takes the storefront's own face."
},
"text": {
"type": "string",
"description": "Body text color, as a CSS color. `inherit` takes the color of whatever the widget sits in."
},
"mutedText": {
"type": "string",
"description": "Color for secondary text: dates, counts, help lines."
},
"surface": {
"type": "string",
"description": "The widgets' own background, as a CSS color. `transparent` lets the storefront's page show through."
},
"surfaceMuted": {
"type": "string",
"description": "Quiet fill behind rating bars, thumbnails and the summary panel."
},
"border": {
"type": "string",
"description": "Color of the hairlines between rows, cards and controls."
},
"accent": {
"type": "string",
"description": "Background of the filled buttons, the active tab and progress fills."
},
"accentText": {
"type": "string",
"description": "Text and glyph color on top of the accent color."
},
"star": {
"type": "string",
"description": "Fill of a rated star and of the rating breakdown bars."
},
"danger": {
"type": "string",
"description": "Color of error messages and of a negative review theme."
},
"radius": {
"type": "string",
"description": "Corner radius of cards, panels and controls, as a CSS length such as `8px`."
},
"customCss": {
"type": "string",
"description": "Extra CSS for these widgets. It is sanitized and scoped to the widget root before it is served, so it cannot restyle the rest of the page."
}
},
"required": [
"fontFamily",
"text",
"mutedText",
"surface",
"surfaceMuted",
"border",
"accent",
"accentText",
"star",
"danger",
"radius",
"customCss"
],
"additionalProperties": false,
"description": "The resolved appearance: every property, with the defaults filled in where the site has not set one."
},
"overrides": {
"type": "object",
"properties": {
"fontFamily": {
"type": "string",
"description": "The font stack the widgets use, as a CSS `font-family` value. `inherit` takes the storefront's own face."
},
"text": {
"type": "string",
"description": "Body text color, as a CSS color. `inherit` takes the color of whatever the widget sits in."
},
"mutedText": {
"type": "string",
"description": "Color for secondary text: dates, counts, help lines."
},
"surface": {
"type": "string",
"description": "The widgets' own background, as a CSS color. `transparent` lets the storefront's page show through."
},
"surfaceMuted": {
"type": "string",
"description": "Quiet fill behind rating bars, thumbnails and the summary panel."
},
"border": {
"type": "string",
"description": "Color of the hairlines between rows, cards and controls."
},
"accent": {
"type": "string",
"description": "Background of the filled buttons, the active tab and progress fills."
},
"accentText": {
"type": "string",
"description": "Text and glyph color on top of the accent color."
},
"star": {
"type": "string",
"description": "Fill of a rated star and of the rating breakdown bars."
},
"danger": {
"type": "string",
"description": "Color of error messages and of a negative review theme."
},
"radius": {
"type": "string",
"description": "Corner radius of cards, panels and controls, as a CSS length such as `8px`."
},
"customCss": {
"type": "string",
"description": "Extra CSS for these widgets. It is sanitized and scoped to the widget root before it is served, so it cannot restyle the rest of the page."
}
},
"additionalProperties": false,
"description": "Only the properties this site has actually changed."
},
"stylesheetUrl": {
"type": "string",
"description": "The path the widgets load this appearance from. The version in it changes whenever the appearance does, so the file can be cached indefinitely."
},
"notes": {
"type": "array",
"items": {
"type": "string"
},
"description": "Anything the sanitizer took out of the custom CSS you sent, so a dropped rule is never a silent one. Empty on a read."
}
},
"required": ["siteId", "theme", "overrides", "stylesheetUrl", "notes"],
"additionalProperties": false,
"description": "The site's widget appearance."
}PATCH /sites/{id}/widget-theme
Change how the widgets look on one site. Only the properties you send are changed. Custom CSS is sanitized before it is stored: at-rules other than @media, @supports and @container are dropped, url() may only carry a data: URI, and every selector is scoped to the widget root so it cannot reach the rest of the page. Saving custom CSS also records a version you can restore.
Requires the settings:write permission.
Path parameters
idstringrequiredThe ID of the site.
Body parameters
fontFamilystringThe font stack the widgets use, as a CSS font-family value. inherit takes the storefront's own face.
textstringBody text color, as a CSS color. inherit takes the color of whatever the widget sits in.
mutedTextstringColor for secondary text: dates, counts, help lines.
surfacestringThe widgets' own background, as a CSS color. transparent lets the storefront's page show through.
surfaceMutedstringQuiet fill behind rating bars, thumbnails and the summary panel.
borderstringColor of the hairlines between rows, cards and controls.
accentstringBackground of the filled buttons, the active tab and progress fills.
accentTextstringText and glyph color on top of the accent color.
starstringFill of a rated star and of the rating breakdown bars.
dangerstringColor of error messages and of a negative review theme.
radiusstringCorner radius of cards, panels and controls, as a CSS length such as 8px.
customCssstringExtra CSS for these widgets. It is sanitized and scoped to the widget root before it is served, so it cannot restyle the rest of the page.
curl \
-X PATCH \
"https://your-store.meisei.app/api/sites/A4Ws1igz/widget-theme" \
-H "Authorization: Bearer sk_YOUR_SECRET_KEY" \
-H "Content-Type: application/json" \
-d '{
"fontFamily": "string",
"text": "string",
"mutedText": "string",
"surface": "string",
"surfaceMuted": "string",
"border": "string",
"accent": "string",
"accentText": "string",
"star": "string",
"danger": "string",
"radius": "string",
"customCss": "string"
}'import { client } from "@meisei/api/admin/client"
import { patchSitesByIdWidgetTheme } from "@meisei/api/admin"
client.setConfig({
baseUrl: "https://your-store.meisei.app/api",
headers: { Authorization: "Bearer sk_YOUR_SECRET_KEY" },
})
const { data, error } = await patchSitesByIdWidgetTheme({
path: { id: "A4Ws1igz" },
body: {
fontFamily: "string",
text: "string",
mutedText: "string",
surface: "string",
surfaceMuted: "string",
border: "string",
accent: "string",
accentText: "string",
star: "string",
danger: "string",
radius: "string",
customCss: "string",
},
})require "meisei"
meisei = Meisei::Client.new(
secret_key: "sk_YOUR_SECRET_KEY",
base_url: "https://your-store.meisei.app/api",
)
result = meisei.sites.widget_theme.update(
"A4Ws1igz",
font_family: "string",
text: "string",
muted_text: "string",
surface: "string",
surface_muted: "string",
border: "string",
accent: "string",
accent_text: "string",
star: "string",
danger: "string",
radius: "string",
custom_css: "string",
)from meisei import Client
meisei = Client(
secret_key="sk_YOUR_SECRET_KEY",
base_url="https://your-store.meisei.app/api",
)
result = meisei.sites.widget_theme.update(
"A4Ws1igz",
font_family="string",
text="string",
muted_text="string",
surface="string",
surface_muted="string",
border="string",
accent="string",
accent_text="string",
star="string",
danger="string",
radius="string",
custom_css="string",
){
"siteId": "A4Ws1igz",
"theme": {
"fontFamily": "string",
"text": "string",
"mutedText": "string",
"surface": "string",
"surfaceMuted": "string",
"border": "string",
"accent": "string",
"accentText": "string",
"star": "string",
"danger": "string",
"radius": "string",
"customCss": "string"
},
"overrides": {
"fontFamily": "string",
"text": "string",
"mutedText": "string",
"surface": "string",
"surfaceMuted": "string",
"border": "string",
"accent": "string",
"accentText": "string",
"star": "string",
"danger": "string",
"radius": "string",
"customCss": "string"
},
"stylesheetUrl": "string",
"notes": ["string"]
}{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"type": "object",
"properties": {
"siteId": {
"type": "string",
"description": "The site this appearance belongs to.",
"idCodec": "sqid"
},
"theme": {
"type": "object",
"properties": {
"fontFamily": {
"type": "string",
"description": "The font stack the widgets use, as a CSS `font-family` value. `inherit` takes the storefront's own face."
},
"text": {
"type": "string",
"description": "Body text color, as a CSS color. `inherit` takes the color of whatever the widget sits in."
},
"mutedText": {
"type": "string",
"description": "Color for secondary text: dates, counts, help lines."
},
"surface": {
"type": "string",
"description": "The widgets' own background, as a CSS color. `transparent` lets the storefront's page show through."
},
"surfaceMuted": {
"type": "string",
"description": "Quiet fill behind rating bars, thumbnails and the summary panel."
},
"border": {
"type": "string",
"description": "Color of the hairlines between rows, cards and controls."
},
"accent": {
"type": "string",
"description": "Background of the filled buttons, the active tab and progress fills."
},
"accentText": {
"type": "string",
"description": "Text and glyph color on top of the accent color."
},
"star": {
"type": "string",
"description": "Fill of a rated star and of the rating breakdown bars."
},
"danger": {
"type": "string",
"description": "Color of error messages and of a negative review theme."
},
"radius": {
"type": "string",
"description": "Corner radius of cards, panels and controls, as a CSS length such as `8px`."
},
"customCss": {
"type": "string",
"description": "Extra CSS for these widgets. It is sanitized and scoped to the widget root before it is served, so it cannot restyle the rest of the page."
}
},
"required": [
"fontFamily",
"text",
"mutedText",
"surface",
"surfaceMuted",
"border",
"accent",
"accentText",
"star",
"danger",
"radius",
"customCss"
],
"additionalProperties": false,
"description": "The resolved appearance: every property, with the defaults filled in where the site has not set one."
},
"overrides": {
"type": "object",
"properties": {
"fontFamily": {
"type": "string",
"description": "The font stack the widgets use, as a CSS `font-family` value. `inherit` takes the storefront's own face."
},
"text": {
"type": "string",
"description": "Body text color, as a CSS color. `inherit` takes the color of whatever the widget sits in."
},
"mutedText": {
"type": "string",
"description": "Color for secondary text: dates, counts, help lines."
},
"surface": {
"type": "string",
"description": "The widgets' own background, as a CSS color. `transparent` lets the storefront's page show through."
},
"surfaceMuted": {
"type": "string",
"description": "Quiet fill behind rating bars, thumbnails and the summary panel."
},
"border": {
"type": "string",
"description": "Color of the hairlines between rows, cards and controls."
},
"accent": {
"type": "string",
"description": "Background of the filled buttons, the active tab and progress fills."
},
"accentText": {
"type": "string",
"description": "Text and glyph color on top of the accent color."
},
"star": {
"type": "string",
"description": "Fill of a rated star and of the rating breakdown bars."
},
"danger": {
"type": "string",
"description": "Color of error messages and of a negative review theme."
},
"radius": {
"type": "string",
"description": "Corner radius of cards, panels and controls, as a CSS length such as `8px`."
},
"customCss": {
"type": "string",
"description": "Extra CSS for these widgets. It is sanitized and scoped to the widget root before it is served, so it cannot restyle the rest of the page."
}
},
"additionalProperties": false,
"description": "Only the properties this site has actually changed."
},
"stylesheetUrl": {
"type": "string",
"description": "The path the widgets load this appearance from. The version in it changes whenever the appearance does, so the file can be cached indefinitely."
},
"notes": {
"type": "array",
"items": {
"type": "string"
},
"description": "Anything the sanitizer took out of the custom CSS you sent, so a dropped rule is never a silent one. Empty on a read."
}
},
"required": ["siteId", "theme", "overrides", "stylesheetUrl", "notes"],
"additionalProperties": false,
"description": "The site's appearance after the change."
}POST /sites/{id}/widget-theme/copy
Copy another site's widget appearance onto this one, custom CSS included. It is a copy, not a link: the two drift apart as soon as either is edited again.
Requires the settings:write permission.
Path parameters
idstringrequiredThe ID of the site.
Body parameters
fromSiteIdstringrequiredThe ID of the site to copy the appearance from.
curl \
-X POST \
"https://your-store.meisei.app/api/sites/A4Ws1igz/widget-theme/copy" \
-H "Authorization: Bearer sk_YOUR_SECRET_KEY" \
-H "Content-Type: application/json" \
-d '{
"fromSiteId": "string"
}'import { client } from "@meisei/api/admin/client"
import { postSitesByIdWidgetThemeCopy } from "@meisei/api/admin"
client.setConfig({
baseUrl: "https://your-store.meisei.app/api",
headers: { Authorization: "Bearer sk_YOUR_SECRET_KEY" },
})
const { data, error } = await postSitesByIdWidgetThemeCopy({
path: { id: "A4Ws1igz" },
body: {
fromSiteId: "string",
},
})require "meisei"
meisei = Meisei::Client.new(
secret_key: "sk_YOUR_SECRET_KEY",
base_url: "https://your-store.meisei.app/api",
)
result = meisei.sites.widget_theme.copy("A4Ws1igz", from_site_id: "string")from meisei import Client
meisei = Client(
secret_key="sk_YOUR_SECRET_KEY",
base_url="https://your-store.meisei.app/api",
)
result = meisei.sites.widget_theme.copy("A4Ws1igz", from_site_id="string"){
"siteId": "A4Ws1igz",
"theme": {
"fontFamily": "string",
"text": "string",
"mutedText": "string",
"surface": "string",
"surfaceMuted": "string",
"border": "string",
"accent": "string",
"accentText": "string",
"star": "string",
"danger": "string",
"radius": "string",
"customCss": "string"
},
"overrides": {
"fontFamily": "string",
"text": "string",
"mutedText": "string",
"surface": "string",
"surfaceMuted": "string",
"border": "string",
"accent": "string",
"accentText": "string",
"star": "string",
"danger": "string",
"radius": "string",
"customCss": "string"
},
"stylesheetUrl": "string",
"notes": ["string"]
}{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"type": "object",
"properties": {
"siteId": {
"type": "string",
"description": "The site this appearance belongs to.",
"idCodec": "sqid"
},
"theme": {
"type": "object",
"properties": {
"fontFamily": {
"type": "string",
"description": "The font stack the widgets use, as a CSS `font-family` value. `inherit` takes the storefront's own face."
},
"text": {
"type": "string",
"description": "Body text color, as a CSS color. `inherit` takes the color of whatever the widget sits in."
},
"mutedText": {
"type": "string",
"description": "Color for secondary text: dates, counts, help lines."
},
"surface": {
"type": "string",
"description": "The widgets' own background, as a CSS color. `transparent` lets the storefront's page show through."
},
"surfaceMuted": {
"type": "string",
"description": "Quiet fill behind rating bars, thumbnails and the summary panel."
},
"border": {
"type": "string",
"description": "Color of the hairlines between rows, cards and controls."
},
"accent": {
"type": "string",
"description": "Background of the filled buttons, the active tab and progress fills."
},
"accentText": {
"type": "string",
"description": "Text and glyph color on top of the accent color."
},
"star": {
"type": "string",
"description": "Fill of a rated star and of the rating breakdown bars."
},
"danger": {
"type": "string",
"description": "Color of error messages and of a negative review theme."
},
"radius": {
"type": "string",
"description": "Corner radius of cards, panels and controls, as a CSS length such as `8px`."
},
"customCss": {
"type": "string",
"description": "Extra CSS for these widgets. It is sanitized and scoped to the widget root before it is served, so it cannot restyle the rest of the page."
}
},
"required": [
"fontFamily",
"text",
"mutedText",
"surface",
"surfaceMuted",
"border",
"accent",
"accentText",
"star",
"danger",
"radius",
"customCss"
],
"additionalProperties": false,
"description": "The resolved appearance: every property, with the defaults filled in where the site has not set one."
},
"overrides": {
"type": "object",
"properties": {
"fontFamily": {
"type": "string",
"description": "The font stack the widgets use, as a CSS `font-family` value. `inherit` takes the storefront's own face."
},
"text": {
"type": "string",
"description": "Body text color, as a CSS color. `inherit` takes the color of whatever the widget sits in."
},
"mutedText": {
"type": "string",
"description": "Color for secondary text: dates, counts, help lines."
},
"surface": {
"type": "string",
"description": "The widgets' own background, as a CSS color. `transparent` lets the storefront's page show through."
},
"surfaceMuted": {
"type": "string",
"description": "Quiet fill behind rating bars, thumbnails and the summary panel."
},
"border": {
"type": "string",
"description": "Color of the hairlines between rows, cards and controls."
},
"accent": {
"type": "string",
"description": "Background of the filled buttons, the active tab and progress fills."
},
"accentText": {
"type": "string",
"description": "Text and glyph color on top of the accent color."
},
"star": {
"type": "string",
"description": "Fill of a rated star and of the rating breakdown bars."
},
"danger": {
"type": "string",
"description": "Color of error messages and of a negative review theme."
},
"radius": {
"type": "string",
"description": "Corner radius of cards, panels and controls, as a CSS length such as `8px`."
},
"customCss": {
"type": "string",
"description": "Extra CSS for these widgets. It is sanitized and scoped to the widget root before it is served, so it cannot restyle the rest of the page."
}
},
"additionalProperties": false,
"description": "Only the properties this site has actually changed."
},
"stylesheetUrl": {
"type": "string",
"description": "The path the widgets load this appearance from. The version in it changes whenever the appearance does, so the file can be cached indefinitely."
},
"notes": {
"type": "array",
"items": {
"type": "string"
},
"description": "Anything the sanitizer took out of the custom CSS you sent, so a dropped rule is never a silent one. Empty on a read."
}
},
"required": ["siteId", "theme", "overrides", "stylesheetUrl", "notes"],
"additionalProperties": false,
"description": "The site's appearance after the copy."
}GET /sites/{id}/widget-theme/revisions
List the saved versions of this site's custom CSS, newest first. A version is recorded every time the CSS changes, whoever or whatever changed it.
Requires the settings:read permission.
Path parameters
idstringrequiredThe ID of the site.
curl \
"https://your-store.meisei.app/api/sites/A4Ws1igz/widget-theme/revisions" \
-H "Authorization: Bearer sk_YOUR_SECRET_KEY"import { client } from "@meisei/api/admin/client"
import { getSitesByIdWidgetThemeRevisions } from "@meisei/api/admin"
client.setConfig({
baseUrl: "https://your-store.meisei.app/api",
headers: { Authorization: "Bearer sk_YOUR_SECRET_KEY" },
})
const { data, error } = await getSitesByIdWidgetThemeRevisions({
path: { id: "A4Ws1igz" },
})require "meisei"
meisei = Meisei::Client.new(
secret_key: "sk_YOUR_SECRET_KEY",
base_url: "https://your-store.meisei.app/api",
)
page = meisei.sites.widget_theme.revisions.list("A4Ws1igz")from meisei import Client
meisei = Client(
secret_key="sk_YOUR_SECRET_KEY",
base_url="https://your-store.meisei.app/api",
)
page = meisei.sites.widget_theme.revisions.list("A4Ws1igz"){
"data": [
{
"id": "A4Ws1igz",
"customCss": "string",
"source": "manual",
"prompt": "string",
"actorLabel": "string",
"createdAt": "2025-01-15T09:30:00Z"
}
]
}{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"type": "object",
"properties": {
"data": {
"type": "array",
"items": {
"type": "object",
"properties": {
"id": {
"type": "string",
"description": "Unique identifier for this saved version.",
"idCodec": "sqid"
},
"customCss": {
"type": "string",
"description": "The custom CSS as it was served by this version."
},
"source": {
"type": "string",
"enum": ["manual", "ai", "restore"],
"description": "Whether the custom CSS was typed, generated from a prompt, or put back from history."
},
"prompt": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"description": "What the merchant asked a model for, on a generated version only."
},
"actorLabel": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"description": "Who saved it, where that is known."
},
"createdAt": {
"type": "string",
"format": "date-time",
"pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d(?::[0-5]\\d(?:\\.\\d+)?)?(?:Z))$",
"description": "When it was saved."
}
},
"required": ["id", "customCss", "source", "prompt", "actorLabel", "createdAt"],
"additionalProperties": false
},
"description": "The saved versions, newest first."
}
},
"required": ["data"],
"additionalProperties": false
}POST /sites/{id}/widget-theme/revisions/{revisionId}/restore
Put a saved version of the custom CSS back. The restore is itself recorded as a version, so nothing is lost by undoing an undo.
Requires the settings:write permission.
Path parameters
idstringrequiredThe ID of the site.
revisionIdstringrequiredThe ID of the version to restore.
curl \
-X POST \
"https://your-store.meisei.app/api/sites/A4Ws1igz/widget-theme/revisions/A4Ws1igz/restore" \
-H "Authorization: Bearer sk_YOUR_SECRET_KEY"import { client } from "@meisei/api/admin/client"
import { postSitesByIdWidgetThemeRevisionsByRevisionIdRestore } from "@meisei/api/admin"
client.setConfig({
baseUrl: "https://your-store.meisei.app/api",
headers: { Authorization: "Bearer sk_YOUR_SECRET_KEY" },
})
const { data, error } = await postSitesByIdWidgetThemeRevisionsByRevisionIdRestore({
path: { id: "A4Ws1igz", revisionId: "A4Ws1igz" },
})require "meisei"
meisei = Meisei::Client.new(
secret_key: "sk_YOUR_SECRET_KEY",
base_url: "https://your-store.meisei.app/api",
)
result = meisei.sites.widget_theme.revisions.restore("A4Ws1igz", "A4Ws1igz")from meisei import Client
meisei = Client(
secret_key="sk_YOUR_SECRET_KEY",
base_url="https://your-store.meisei.app/api",
)
result = meisei.sites.widget_theme.revisions.restore("A4Ws1igz", "A4Ws1igz"){
"siteId": "A4Ws1igz",
"theme": {
"fontFamily": "string",
"text": "string",
"mutedText": "string",
"surface": "string",
"surfaceMuted": "string",
"border": "string",
"accent": "string",
"accentText": "string",
"star": "string",
"danger": "string",
"radius": "string",
"customCss": "string"
},
"overrides": {
"fontFamily": "string",
"text": "string",
"mutedText": "string",
"surface": "string",
"surfaceMuted": "string",
"border": "string",
"accent": "string",
"accentText": "string",
"star": "string",
"danger": "string",
"radius": "string",
"customCss": "string"
},
"stylesheetUrl": "string",
"notes": ["string"]
}{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"type": "object",
"properties": {
"siteId": {
"type": "string",
"description": "The site this appearance belongs to.",
"idCodec": "sqid"
},
"theme": {
"type": "object",
"properties": {
"fontFamily": {
"type": "string",
"description": "The font stack the widgets use, as a CSS `font-family` value. `inherit` takes the storefront's own face."
},
"text": {
"type": "string",
"description": "Body text color, as a CSS color. `inherit` takes the color of whatever the widget sits in."
},
"mutedText": {
"type": "string",
"description": "Color for secondary text: dates, counts, help lines."
},
"surface": {
"type": "string",
"description": "The widgets' own background, as a CSS color. `transparent` lets the storefront's page show through."
},
"surfaceMuted": {
"type": "string",
"description": "Quiet fill behind rating bars, thumbnails and the summary panel."
},
"border": {
"type": "string",
"description": "Color of the hairlines between rows, cards and controls."
},
"accent": {
"type": "string",
"description": "Background of the filled buttons, the active tab and progress fills."
},
"accentText": {
"type": "string",
"description": "Text and glyph color on top of the accent color."
},
"star": {
"type": "string",
"description": "Fill of a rated star and of the rating breakdown bars."
},
"danger": {
"type": "string",
"description": "Color of error messages and of a negative review theme."
},
"radius": {
"type": "string",
"description": "Corner radius of cards, panels and controls, as a CSS length such as `8px`."
},
"customCss": {
"type": "string",
"description": "Extra CSS for these widgets. It is sanitized and scoped to the widget root before it is served, so it cannot restyle the rest of the page."
}
},
"required": [
"fontFamily",
"text",
"mutedText",
"surface",
"surfaceMuted",
"border",
"accent",
"accentText",
"star",
"danger",
"radius",
"customCss"
],
"additionalProperties": false,
"description": "The resolved appearance: every property, with the defaults filled in where the site has not set one."
},
"overrides": {
"type": "object",
"properties": {
"fontFamily": {
"type": "string",
"description": "The font stack the widgets use, as a CSS `font-family` value. `inherit` takes the storefront's own face."
},
"text": {
"type": "string",
"description": "Body text color, as a CSS color. `inherit` takes the color of whatever the widget sits in."
},
"mutedText": {
"type": "string",
"description": "Color for secondary text: dates, counts, help lines."
},
"surface": {
"type": "string",
"description": "The widgets' own background, as a CSS color. `transparent` lets the storefront's page show through."
},
"surfaceMuted": {
"type": "string",
"description": "Quiet fill behind rating bars, thumbnails and the summary panel."
},
"border": {
"type": "string",
"description": "Color of the hairlines between rows, cards and controls."
},
"accent": {
"type": "string",
"description": "Background of the filled buttons, the active tab and progress fills."
},
"accentText": {
"type": "string",
"description": "Text and glyph color on top of the accent color."
},
"star": {
"type": "string",
"description": "Fill of a rated star and of the rating breakdown bars."
},
"danger": {
"type": "string",
"description": "Color of error messages and of a negative review theme."
},
"radius": {
"type": "string",
"description": "Corner radius of cards, panels and controls, as a CSS length such as `8px`."
},
"customCss": {
"type": "string",
"description": "Extra CSS for these widgets. It is sanitized and scoped to the widget root before it is served, so it cannot restyle the rest of the page."
}
},
"additionalProperties": false,
"description": "Only the properties this site has actually changed."
},
"stylesheetUrl": {
"type": "string",
"description": "The path the widgets load this appearance from. The version in it changes whenever the appearance does, so the file can be cached indefinitely."
},
"notes": {
"type": "array",
"items": {
"type": "string"
},
"description": "Anything the sanitizer took out of the custom CSS you sent, so a dropped rule is never a silent one. Empty on a read."
}
},
"required": ["siteId", "theme", "overrides", "stylesheetUrl", "notes"],
"additionalProperties": false,
"description": "The site's appearance after the restore."
}GET /sites/{id}/review-statement
Get the About our reviews statement shoppers can open from the product reviews widget on one site: what they read, the site's own wording if it has some, the link to the site's own page if it has one, and the statement generated from your current review settings.
Requires the settings:read permission.
Path parameters
idstringrequiredThe ID of the site.
curl \
"https://your-store.meisei.app/api/sites/A4Ws1igz/review-statement" \
-H "Authorization: Bearer sk_YOUR_SECRET_KEY"import { client } from "@meisei/api/admin/client"
import { getSitesByIdReviewStatement } from "@meisei/api/admin"
client.setConfig({
baseUrl: "https://your-store.meisei.app/api",
headers: { Authorization: "Bearer sk_YOUR_SECRET_KEY" },
})
const { data, error } = await getSitesByIdReviewStatement({
path: { id: "A4Ws1igz" },
})require "meisei"
meisei = Meisei::Client.new(
secret_key: "sk_YOUR_SECRET_KEY",
base_url: "https://your-store.meisei.app/api",
)
result = meisei.sites.review_statement.retrieve("A4Ws1igz")from meisei import Client
meisei = Client(
secret_key="sk_YOUR_SECRET_KEY",
base_url="https://your-store.meisei.app/api",
)
result = meisei.sites.review_statement.retrieve("A4Ws1igz"){
"siteId": "A4Ws1igz",
"text": "string",
"customText": "string",
"url": "string",
"generatedText": "string"
}{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"type": "object",
"properties": {
"siteId": {
"type": "string",
"description": "The site this statement belongs to.",
"idCodec": "sqid"
},
"text": {
"type": "string",
"description": "What shoppers read when they open About our reviews: the site's own wording if it has some, otherwise the generated statement."
},
"customText": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"description": "The site's own wording, or null when the widget shows the generated statement instead."
},
"url": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"description": "A page of your own that the About our reviews link opens instead of showing the text. Null shows the text."
},
"generatedText": {
"type": "string",
"description": "The statement Meisei writes from your current review settings: how reviews are collected, what Verified buyer means, how new reviews are published and when a review is deleted. It is generated on every read, so it follows your settings as they change."
}
},
"required": ["siteId", "text", "customText", "url", "generatedText"],
"additionalProperties": false,
"description": "The site's statement."
}PATCH /sites/{id}/review-statement
Replace the generated About our reviews statement on one site with your own wording, or point its link at a page of your own. Only the fields you send change; send null to go back to the generated statement or to take the link away.
Requires the settings:write permission.
Path parameters
idstringrequiredThe ID of the site.
Body parameters
textstring | nullYour own wording for the statement, in plain text. A blank line starts a new paragraph. Null goes back to the generated statement. Omit to leave it alone.
urlstring (uri) | nullA page on your own site that explains how you handle reviews, as a full http or https URL. The About our reviews link opens it instead of showing the text. Null shows the text again. Omit to leave it alone.
curl \
-X PATCH \
"https://your-store.meisei.app/api/sites/A4Ws1igz/review-statement" \
-H "Authorization: Bearer sk_YOUR_SECRET_KEY" \
-H "Content-Type: application/json" \
-d '{
"text": "string",
"url": "https://example.com"
}'import { client } from "@meisei/api/admin/client"
import { patchSitesByIdReviewStatement } from "@meisei/api/admin"
client.setConfig({
baseUrl: "https://your-store.meisei.app/api",
headers: { Authorization: "Bearer sk_YOUR_SECRET_KEY" },
})
const { data, error } = await patchSitesByIdReviewStatement({
path: { id: "A4Ws1igz" },
body: {
text: "string",
url: "https://example.com",
},
})require "meisei"
meisei = Meisei::Client.new(
secret_key: "sk_YOUR_SECRET_KEY",
base_url: "https://your-store.meisei.app/api",
)
result = meisei.sites.review_statement.update(
"A4Ws1igz",
text: "string",
url: "https://example.com",
)from meisei import Client
meisei = Client(
secret_key="sk_YOUR_SECRET_KEY",
base_url="https://your-store.meisei.app/api",
)
result = meisei.sites.review_statement.update(
"A4Ws1igz",
text="string",
url="https://example.com",
){
"siteId": "A4Ws1igz",
"text": "string",
"customText": "string",
"url": "string",
"generatedText": "string"
}{
"$schema": "https://json-schema.org/draft/2020-12/schema",
"type": "object",
"properties": {
"siteId": {
"type": "string",
"description": "The site this statement belongs to.",
"idCodec": "sqid"
},
"text": {
"type": "string",
"description": "What shoppers read when they open About our reviews: the site's own wording if it has some, otherwise the generated statement."
},
"customText": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"description": "The site's own wording, or null when the widget shows the generated statement instead."
},
"url": {
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"description": "A page of your own that the About our reviews link opens instead of showing the text. Null shows the text."
},
"generatedText": {
"type": "string",
"description": "The statement Meisei writes from your current review settings: how reviews are collected, what Verified buyer means, how new reviews are published and when a review is deleted. It is generated on every read, so it follows your settings as they change."
}
},
"required": ["siteId", "text", "customText", "url", "generatedText"],
"additionalProperties": false,
"description": "The site's statement after the change."
}