Policies

Read, update, translate, and subscribe to store policies through the Store API.

Each store has one policy of each type: privacy, terms, refund, shipping, cookie, legal_notice, contact_information, and terms_of_sale. Read and update a policy by its type. These endpoints do not create or delete policies. Reads require read_pages; writes require write_pages. Read field lengths from /policies/limits instead of hard-coding them.

Updates need the expected_revision from your last read and preserve omitted fields. They can change content, publishing, SEO, and the URL slug. Send null or an empty string to clear content, seo_title or seo_description; content with no text and no image or other media, such as <p> </p>, also counts as empty, and an empty field is stored as null. A source field with translations cannot be cleared until those translations are removed. The privacy and cookie policies used by an active consent banner, and the policies shown in the checkout footer, must remain published with content (POLICY_LOCKED_BY_CONSENT_BANNER, POLICY_LOCKED_BY_CHECKOUT). When you change a slug with create_redirect: false, redirects Tringify made earlier toward the old address move to the new one. Unknown or wrongly typed request fields are rejected with STORE_API_BODY_PROPERTY_UNKNOWN or STORE_API_BODY_PROPERTY_INVALID.

Policy translations use the policy's UUID returned by a read. Translation reads require read_pages and read_translations; writes require write_pages and write_translations.

Endpoints#

Policy limits

GET read_pages

Fetch Policy limits and per-field constraints.

Returns the per-field maximum lengths, enum values, and the fixed policy-type set that apply to Policy endpoints. status_options lists each status value with its English display label and a description of what it means for buyers. policy_type_options lists each policy value (one per store, in list order) with its English label and a description of what it covers.

Headers

Name Type Description
Authorization required string

Bearer Store API token.

Errors

  • 401 UNAUTHORIZED

    The Authorization header is missing.

  • 401 INVALID_TOKEN

    The Authorization header is not Bearer followed by a token, or the token is not in the form Tringify issues.

  • 401 TOKEN_NOT_ACCEPTED

    The token is unknown, expired, revoked or replaced, or its app was uninstalled.

  • 402 SUBSCRIPTION_REQUIRED

    The store does not have an active or trialing subscription.

  • 403 API_VERSION_UNSUPPORTED

    The credential is pinned to an API version that cannot be served.

  • 403 STORE_SUSPENDED

    Tringify has suspended the store. Every request is refused until it is reinstated.

  • 403 STORE_TERMINATED

    Tringify has terminated the store permanently. Every request is refused.

  • 400 STORE_API_QUERY_PARAMETER_UNKNOWN

    The request has a query parameter; this endpoint takes none.

  • 429 RATE_LIMITED

    The request allowance is exhausted. Wait for Retry-After before retrying.

List policies

GET read_pages

List all policies for the store.

Returns the store's fixed set of Policies — one row per policy type. There is no pagination: Policies are a fixed singleton set. Each policy carries status_display, its status as shown in Tringify, in English. storefront_url is the canonical absolute URL on the store's primary domain. storefront_path is the domain-independent baseline route; join it to the storefront address you are targeting. Hosted storefront responses apply translated slugs and locale/country prefixes.

Headers

Name Type Description
Authorization required string

Bearer Store API token.

Errors

  • 401 UNAUTHORIZED

    The Authorization header is missing.

  • 401 INVALID_TOKEN

    The Authorization header is not Bearer followed by a token, or the token is not in the form Tringify issues.

  • 401 TOKEN_NOT_ACCEPTED

    The token is unknown, expired, revoked or replaced, or its app was uninstalled.

  • 402 SUBSCRIPTION_REQUIRED

    The store does not have an active or trialing subscription.

  • 403 API_VERSION_UNSUPPORTED

    The credential is pinned to an API version that cannot be served.

  • 403 STORE_SUSPENDED

    Tringify has suspended the store. Every request is refused until it is reinstated.

  • 403 STORE_TERMINATED

    Tringify has terminated the store permanently. Every request is refused.

  • 400 STORE_API_QUERY_PARAMETER_UNKNOWN

    The request has a query parameter; this endpoint takes none.

  • 429 RATE_LIMITED

    The request allowance is exhausted. Wait for Retry-After before retrying.

Get a policy

GET read_pages

Fetch one policy by type.

Returns the Policy for the given type (privacy, terms, refund, shipping, cookie, legal_notice, contact_information, or terms_of_sale). status_display is its status as shown in Tringify, in English. storefront_url is the canonical absolute URL on the store's primary domain. storefront_path is the domain-independent baseline route; join it to the storefront address you are targeting. Hosted storefront responses apply translated slugs and locale/country prefixes.

Path parameters

Name Type Description
type required string

Policy type: privacy, terms, refund, shipping, cookie, legal_notice, contact_information, or terms_of_sale.

Example: privacy

Headers

Name Type Description
Authorization required string

Bearer Store API token.

Errors

  • 401 UNAUTHORIZED

    The Authorization header is missing.

  • 401 INVALID_TOKEN

    The Authorization header is not Bearer followed by a token, or the token is not in the form Tringify issues.

  • 401 TOKEN_NOT_ACCEPTED

    The token is unknown, expired, revoked or replaced, or its app was uninstalled.

  • 402 SUBSCRIPTION_REQUIRED

    The store does not have an active or trialing subscription.

  • 403 API_VERSION_UNSUPPORTED

    The credential is pinned to an API version that cannot be served.

  • 403 STORE_SUSPENDED

    Tringify has suspended the store. Every request is refused until it is reinstated.

  • 403 STORE_TERMINATED

    Tringify has terminated the store permanently. Every request is refused.

  • 400 POLICY_TYPE_INVALID

    Type is not one of the fixed policy types.

  • 404 NOT_FOUND

    The policy row does not exist in this store.

  • 400 STORE_API_QUERY_PARAMETER_UNKNOWN

    The request has a query parameter; this endpoint takes none.

  • 429 RATE_LIMITED

    The request allowance is exhausted. Wait for Retry-After before retrying.

Update a policy

PUT write_pages

Update one policy by type.

Updates provided fields on the existing fixed Policy row. Supply expected_revision from the latest Get response; a missing or stale revision returns CONTENT_REVISION_CONFLICT (409), even when the request would change nothing. Omitted fields are left unchanged. Send null or an empty string to clear content, seo_title, seo_description or social_image_id; content with no text and no image or other media (for example <p> </p>) also clears it, and a cleared field is stored as null. A source field that has translations cannot be cleared (TRANSLATION_SOURCE_FIELD_HAS_TRANSLATIONS). title, slug, status, robots and create_redirect cannot be null. A non-empty social_image_id must reference an uploaded image in this store and also requires read_files. An empty slug resets to the default slug for the policy type. When slug changes, create_redirect controls whether the old policy URL redirects to the new one and defaults to true; with false, redirects Tringify created earlier toward the old URL are moved to the new URL, so none ends on a missing page. A policy that the consent banner or the checkout footer shows must stay published with readable text; content that is only an image or other media is refused there (POLICY_LOCKED_BY_CONSENT_BANNER, POLICY_LOCKED_BY_CHECKOUT). A successful change increments revision. Unknown or wrongly typed body properties are refused. storefront_url is the canonical absolute URL on the store's primary domain. storefront_path is the domain-independent baseline route; join it to the storefront address you are targeting. Hosted storefront responses apply translated slugs and locale/country prefixes.

Path parameters

Name Type Description
type required string

Policy type: privacy, terms, refund, shipping, cookie, legal_notice, contact_information, or terms_of_sale.

Example: privacy

Headers

Name Type Description
Authorization required string

Bearer Store API token.

Body parameters

Name Type Description
expected_revision required integer

Copy revision from Get policy. A missing or stale revision returns CONTENT_REVISION_CONFLICT (409), even when nothing would change; reload before retrying.

Example: 1
title string

Policy title. Omit to leave it unchanged; when supplied, it must be non-empty after normalization.

Example: Privacy policy
slug string

Slug. Omit to leave it unchanged; send an empty string to reset to the default slug for the policy type.

Example: privacy-policy
content string

HTML content. Omit to leave it unchanged; send null or an empty string, or content with no text and no media, to clear it. Unsafe markup (scripts, frames, event handlers, unsupported links) is removed on save, and the response then lists a warning in data.content_warnings.

Example: <p>How we handle your data.</p>
seo_title string

SEO title. Omit to leave it unchanged; send null or an empty string to clear it.

Example: Privacy policy
seo_description string

SEO description. Omit to leave it unchanged; send null or an empty string to clear it.

Example: How we handle your data.
status string

Policy status: draft or published. Omit to leave it unchanged.

Example: published
robots string

Search visibility: index or noindex. Omit to leave it unchanged. noindex keeps the policy out of search results and the sitemap; it does not restrict who can open it.

Example: index
social_image_id uuid

Image shown when the policy is shared on social media: the id of an uploaded image in this store's Media library. Without one, the store's share image is used, then its logo. Omit to leave it unchanged; send null or an empty string to remove it. A non-empty value requires read_files. Deleting the image from the Media library removes it and sends policies/update.

Example: 8f2a1c2b-9d4e-4a56-b789-0123456789ab
create_redirect boolean

When slug changes, create a redirect from the old policy URL to the new one. Defaults to true. With false, redirects created earlier toward the old URL move to the new URL.

Example: true

Errors

  • 401 UNAUTHORIZED

    The Authorization header is missing.

  • 401 INVALID_TOKEN

    The Authorization header is not Bearer followed by a token, or the token is not in the form Tringify issues.

  • 401 TOKEN_NOT_ACCEPTED

    The token is unknown, expired, revoked or replaced, or its app was uninstalled.

  • 402 SUBSCRIPTION_REQUIRED

    The store does not have an active or trialing subscription.

  • 403 API_VERSION_UNSUPPORTED

    The credential is pinned to an API version that cannot be served.

  • 403 STORE_SUSPENDED

    Tringify has suspended the store. Every request is refused until it is reinstated.

  • 403 STORE_TERMINATED

    Tringify has terminated the store permanently. Every request is refused.

  • 409 CONTENT_REVISION_CONFLICT

    expected_revision is missing or stale, even when nothing would change. Reload before retrying.

  • 400 STORE_API_INVALID_REQUEST_BODY

    The body is not valid JSON or not a JSON object.

  • 400 POLICY_TYPE_INVALID

    Type is not one of the fixed policy types.

  • 400 POLICY_TITLE_REQUIRED

    Title is empty after normalization.

  • 400 POLICY_TITLE_INVALID_CHARS

    Title contains a line break or another unsupported control character.

  • 400 POLICY_TITLE_TOO_LONG

    Title exceeds the Policy contract max length.

  • 400 POLICY_SLUG_INVALID_FORMAT

    Slug is not valid for Policy URLs.

  • 400 POLICY_SLUG_TOO_LONG

    Slug exceeds the Policy contract max length.

  • 400 POLICY_CONTENT_TOO_LONG

    Content exceeds the Policy contract max length.

  • 400 POLICY_SEO_TITLE_TOO_LONG

    SEO title exceeds the Policy contract max length.

  • 400 POLICY_SEO_DESCRIPTION_TOO_LONG

    SEO description exceeds the Policy contract max length.

  • 400 POLICY_STATUS_INVALID

    Status is not one of the allowed values.

  • 400 ROBOTS_INVALID

    Robots is not index or noindex.

  • 400 FILE_REF_INVALID_ID

    social_image_id is not a valid file id.

  • 400 FILE_REF_NOT_IMAGE

    social_image_id is not an image.

  • 400 FILE_REF_MEDIA_LIBRARY_ONLY

    social_image_id is a site asset; choose an image from the Media library.

  • 403 STORE_API_SCOPE_REQUIRED

    A non-empty social_image_id requires read_files in addition to write_pages.

  • 404 FILE_REF_NOT_FOUND

    social_image_id does not reference a file in this store.

  • 404 NOT_FOUND

    The policy row does not exist in this store.

  • 409 TRANSLATION_SOURCE_FIELD_HAS_TRANSLATIONS

    A source field cannot be cleared while it has translations in any locale.

  • 409 POLICY_SLUG_DUPLICATE

    Slug already exists in this store's policies.

  • 409 POLICY_LOCKED_BY_CONSENT_BANNER

    The active consent banner requires its privacy and cookie policies to remain published with readable text. Content that is only an image or other media does not count.

  • 409 POLICY_LOCKED_BY_CHECKOUT

    The checkout footer shows this policy, so it must stay published with readable text; content that is only an image or other media does not count. Remove it from the checkout footer first.

  • 400 STORE_API_BODY_PROPERTY_UNKNOWN

    The body has a property this request does not accept. The message and error.details.properties list the allowed and required properties (nested for each object or list of objects).

  • 400 STORE_API_BODY_PROPERTY_INVALID

    A body property has the wrong type (error.details.expected_type). The message and error.details.properties list the allowed and required properties.

  • 400 STORE_API_QUERY_PARAMETER_UNKNOWN

    The request has a query parameter; this endpoint takes none.

  • 429 RATE_LIMITED

    The request allowance is exhausted. Wait for Retry-After before retrying.

Fields#

Field

Type

Create

Update

Required

Translatable

id

string (UUID)

No

No

No

type

string

No

No

No

title

string

No

Yes

Yes

slug

string

No

Yes

Yes

content

string

No

Yes

Yes

seo_title

string

No

Yes

Yes

seo_description

string

No

Yes

Yes

status

string

No

Yes

No

status_display

string

No

No

No

robots

string

No

Yes

No

social_image_id

string (UUID)

No

Yes

No

create_redirect

boolean

No

Yes

No

revision

integer

No

No

No

expected_revision

integer

No

Yes

update

No

created_at

string (RFC 3339)

No

No

No

updated_at

string (RFC 3339)

No

No

No

created_at_iso

string (RFC 3339)

No

No

No

updated_at_iso

string (RFC 3339)

No

No

No

storefront_url

url

No

No

No

No

storefront_path

string

No

No

No

No

Webhook events#

Subscribe to these events to keep your integration in sync with policies. Each event shows the required Store API scope and store permission, the available payload fields, and an example payload. Subscription setup is validated against those permissions; delivery is always restricted to the subscription's store.

Policy updated

EVENT policies/update App scope: read_pages Staff permission: pages:write

Fired when a store policy is updated. changed_fields names what changed. Policies are never deleted: every store keeps one of each type. A policy update and its translations events can arrive in any order.

Payload fields

Field Type Description
policy object Always present
policy.id string Always present
policy.type string Always present
policy.title string Always present
policy.slug string Always present
policy.content string | null Always present

The policy's sanitized HTML, or null when it has none. Always present.

policy.status string Always present
policy.seo_title string | null Always present

The policy's SEO title, or null when it has none (the storefront then uses the title). Always present.

policy.seo_description string | null Always present

The policy's SEO description, or null when it has none. Always present.

policy.robots string Always present

The policy's search visibility: index, or noindex to keep it out of search results and the sitemap.

policy.social_image_id string | null Always present

The Media library image shown when the policy is shared, or null when none is set (the store's share image, then its logo, is used). Deleting the image from the Media library sets it to null and sends policies/update with changed_fields social_image_id. Always present.

policy.created_at string Always present
policy.updated_at string Always present
changed_fields array Always present

The policy fields this update changed: any of title, slug, content, status, seo_title, seo_description, robots and social_image_id.