Blocks

Search blocks

Returns a page of the tenant's blocks, without their content. Use GET /blocks/{id} to get a block's content.

get/blocks

Request

  • Base URL
    https://api5.optimove.net/content/v1
  • URL
    https://api5.optimove.net/content/v1/blocks
  • Auth
    API key in header X-API-KEY

Query parameters

searchstring

Text to search for in the block name, tag name and content. Ignored when shorter than 3 characters.

folderIdstring uuid

Returns only items in this folder.

dateFromstring date-time

Returns only items last updated at or after this time (inclusive). ISO 8601 in UTC, with or without Z, for example 2026-10-01T00:00:00Z. A date without a time means midnight UTC. Can't be later than dateTo.

dateTostring date-time

Returns only items last updated at or before this time (inclusive). ISO 8601 in UTC, with or without Z, for example 2026-10-31T23:59:59Z. A date without a time means midnight UTC at the start of that day, so dateTo=2026-10-31 excludes almost all of October 31. To include the whole day, pass 2026-10-31T23:59:59Z.

skipinteger

Number of items to skip.

takeinteger

Maximum number of items to return.

sortOrder'date-newest' | 'date-oldest' | 'name-asc' | 'name-desc'

Sort order of the results:

  • date-newest: last updated first
  • date-oldest: last updated last
  • name-asc: by name, A to Z
  • name-desc: by name, Z to A

Response

A page of blocks.

totalCountinteger required

Number of blocks that match the search, across all pages.

skipinteger required
takeinteger required
hasMoreboolean required

Whether there are more blocks after this page.

Example response

{
  "items": [
    {
      "tagName": "summer-sale-banner",
      "name": "Summer sale banner",
      "editorType": "html"
    }
  ]
}

Changes

No recorded changes to this operation across all 1 revision of this API.