Skip to content
ShopAssist Docs
APIAPI referenceCatalog Push API

Push Pages

Upsert pages/policies into the knowledge base (external_ref = external_id).

POST/v1/stores/{store_id}/catalog/pages:batchScope catalog:write

Upsert pages/policies into the knowledge base (`external_ref = external_id`).

Parameters

Parameters of Push Pages
NameInTypeDescription
store_idrequiredpathstring
Idempotency-KeyrequiredheaderstringReplays return the original

Request body (PagesBatch)

Request body of Push Pages
FieldTypeDescription
pagesrequiredCatalogPageInput[]CatalogPageInput items (validated individually; invalid items are reported in rejected[])≥ 1 items · ≤ 500 items
pages[].content_htmlstring
pages[].content_textstring
pages[].doc_type"policy" | "page" | "faq"default "page"
pages[].external_idrequiredstring1–128 characters
pages[].localestring2–35 characters · pattern `^[A-Za-z]{2,3}(-[A-Za-z0-9]{2,8})*$`
pages[].policy_typestring≤ 64 characters
pages[].titlerequiredstring1–255 characters
pages[].urlrequiredstringformat uri · ≤ 2048 characters

Example request

curl -X POST "https://api.shopassist.coec.dk/v1/stores/sto_01j8000000e008000000000000/catalog/pages:batch" \
  -H "Authorization: Bearer $SHOPASSIST_API_KEY" \
  -H "Idempotency-Key: $(uuidgen)" \
  -H "Content-Type: application/json" \
  -d '{"pages":[{"content_html":"string","content_text":"string","doc_type":"policy","external_id":"string","locale":"da-DK","policy_type":"string","title":"string","url":"https://shop.example/products/linen-shirt"}]}'

Response 202 (BatchAccepted)

Response of Push Pages
FieldTypeDescription
acceptedrequiredinteger≥ 0
rejectedrequiredItemRejection[]
rejected[].errorrequiredItemError`{ code; message }` of a rejected item.
rejected[].error.coderequired"validation_error" | "currency_mismatch" | "duplicate_external_id" | "too_many_variants" | "url_not_allowed"
rejected[].error.messagerequiredstring
rejected[].indexrequiredinteger≥ 0
sync_run_idrequiredstringpattern `^sync_[0-9a-hjkmnp-tv-z]{26}$`
{
  "accepted": 0,
  "rejected": [
    {
      "error": {
        "code": "validation_error",
        "message": "string"
      },
      "index": 0
    }
  ],
  "sync_run_id": "sync_01j8000000e008000000000000"
}

Errors

Every error uses the error envelope; the code field is stable.

  • 400 Bad Request
  • 401 Unauthorized
  • 403 Forbidden
  • 404 Not Found
  • 409 Conflict
  • 413 Content Too Large
  • 422 Unprocessable Content
  • 429 Too Many Requests

Last updated on