Skip to main content
Astro is the most straightforward integration since it supports static and server-rendered pages natively.

Create the API helper

Create src/lib/thestacc.ts:

Create the blog listing page

Create src/pages/blog/index.astro:
The list endpoint returns metadata only by default (no content), which is exactly what a listing page needs.

Create the blog detail page

Create src/pages/blog/[slug].astro:
The single-blog endpoint always includes the full HTML in content. set:html renders it directly. Style the .blog-content class in your CSS to match your site’s design.

Generate the sitemap

If you use @astrojs/sitemap, the blog pages are automatically included since they’re generated as static routes. For a hand-built sitemap, use the sitemap endpoint described later in this guide.