Features/Integrations

Strapi integration

Connect a Strapi headless CMS and use its collection types as builder data sources with filters, sort and locale.

Enter your Strapi endpoint URL and API token. Divhunt reads the collection types from the Content-Type Builder API and registers each as a data source in the Strapi folder. You can filter with Strapi operators, sort, paginate, populate relations and pass the active site language as Strapi locale.

How it works

  • Settings: API Key (bearer token with read access to all content types), Endpoint (URL), Collections Re-cache button, List of cached collections.
  • Source id 'strapi.<uid>', properties: limit (default 100, capped at 100 per request), page (default 1), id, slug, populate (default '*'), locale (default $language->get('active')->toLowerCase).
  • When limit is 1, populate is set to 'deep'.
  • Operators: $eq, $ne, $lt, $lte, $gt, $gte, $contains, $notContains, $null, $notNull, $startsWith, $endsWith. Relation fields filter on [id].
  • Sort for string and date attributes.
  • Response key get('data').
  • A 'strapi' variable exposes the endpoint (useful to build media URLs).

When to use it

  • Render Strapi blog posts in a Divhunt design
  • Build a multilingual site with Strapi locales

Limitations

  • Max 100 items per request (pageSize)
  • Strapi sources are not cached
  • Only collection types, not single types
  • The content-types call is sent without the Authorization header, so it needs to be reachable on your Strapi
  • populate=deep needs a Strapi deep-populate plugin
  • Read only

Availability

  • Works in Designer.
  • Included in every plan.
  • Limits: pageSize max 100

How to use it.

  1. Install REST API, then Strapi
  2. Enter API key and endpoint
  3. Click Re-cache
  4. Use Source > Strapi in the builder

Questions.

Does it support Strapi i18n?

Related features.

No card needed

Build it today.Pay when it goes live.

Every feature is unmetered while you build. Checkout opens the first time you publish.