Get snippet by ID

The snippet endpoint is usable for Enterprise customers and is used to retrieve the snippets that you can configure in the Makaira backend.

Returns one or more page editor snippets by their IDs. Snippets are reusable content blocks managed in the Makaira Page Editor.

Request

POST /enterprise/snippets

Headers

HeaderValue
Content-Typeapplication/json
X-Makaira-InstanceYour Makaira instance identifier

Request Body

FieldTypeRequiredDescription
snippetIdsarrayYesArray of snippet IDs to retrieve.
constraintsobjectYesMust include query.shop_id and query.language.

Example Request

{
  "snippetIds": ["footer-info", "promo-banner"],
  "constraints": {
    "query.shop_id": "1",
    "query.language": "de"
  }
}

Response

Returns a JSON object keyed by snippet ID, each containing the rendered snippet content.

Body Params
snippetIds
array of strings

The snippet IDs to search for.

snippetIds
constraints
object
Headers
string
required

Makaira Instance ID

Response
200

OK

Language
Credentials
Bearer
URL
LoadingLoading…
Response
Click Try It! to start a request and see the response here!