Skip to content
All docs

Strapi setup

Credential: API token

The Strapi connector writes each article as an entry of a Strapi 5 collection type over the REST API. Strapi Cloud and self-hosted Strapi both work. Entries are drafts by default.

Your Strapi must be on the internet over https. BirchSeek does not connect to private addresses.

Step 1 - create an API token

  1. In the Strapi admin, open Settings → API Tokens and click Create new API Token.

  2. Name it BirchSeek. Set Token duration to Unlimited.

  3. Set Token type to Full access, or use Custom with these permissions:

    Section Permissions
    Your article collection find, findOne, create, update
    Upload find, upload
    Content-type-builder (optional) getContentTypes

    Without getContentTypes, the test cannot check your field names.

  4. Click Save and copy the token.

Step 2 - add an owner field

In the Content-Type Builder, open your article collection, add a Text field named birchseekId, and click Save. Do not show this field on your site.

BirchSeek writes the article id in this field. With it, BirchSeek finds its own entry after a slug change and never overwrites an entry that you wrote. Without it, BirchSeek updates only the entry of its last publish, and an entry with the same slug stops the publish with an error.

Step 3 - connect in BirchSeek

Setting Meaning
Strapi URL The root of your Strapi, for example https://cms.example.com. Not /admin
API token The token from step 1
Collection The plural API id: Content-Type Builder → the collection → Advanced settings
Body field The field for the article
Body field type Rich text (Blocks) or Rich text (Markdown)
Owner field birchseekId from step 2
Entry status Draft (default) or Published

The optional fields:

Role Field type Value
Title Text The article title (title)
Slug Text or UID The article slug
Excerpt Text The meta description
Cover image Media, single The featured image
Tags Text The tags, comma-separated
Author Text The byline
Meta title Text The meta title
Meta description Text The meta description
Publish date Date The publish date
Schema JSON The article’s JSON-LD

Map a slug field, an owner field, or both. Strapi does not accept fields that the collection does not have.

Step 4 - send a test

Send a test reads one entry of the collection. That proves the URL, the token and the plural API id. When the token has getContentTypes, the test also checks each mapped field’s name and type, and lists required fields that BirchSeek does not fill. The test writes nothing.

What BirchSeek writes

  • The body without the title heading. A Blocks body has headings, lists, quotes, code blocks, links and images. Blocks has no tables, so each table row is a paragraph. A Markdown body gets markdown.
  • Images in the media library. BirchSeek uploads the cover and the in-article images, and finds them by name on the next publish. An image that fails links to BirchSeek’s copy.
  • Drafts with status=draft. A new entry is a draft. An update changes only the draft, so a live entry stays as it is until you publish the change. With the status Published, Strapi publishes each write.

The body ends with the ## Sources block. See Sources and citations.

A video is written as a link, because Blocks holds no embeds.

Draft mode needs Draft & Publish on the collection. Without it, every write is live.

Set Public URL template to the address your site gives an entry, for example https://example.com/blog/{slug}. BirchSeek uses it to check that the page is live and to request indexing.

Strapi’s REST API has no scheduling. BirchSeek’s calendar times each write.

Troubleshooting

  • 401: the token is wrong or expired. Create a new one.
  • 403 Forbidden: the token does not have a permission from step 1.
  • 404: check the Strapi URL and the plural API id. Open https://your-strapi/api/your-plural-id in a browser: it must answer.
  • 400 ValidationError: a mapped field does not exist or has the wrong type. The error names the field.