Content API
Use PageHub as a headless CMS. Every collection is a JSON endpoint.
- Search, sort, filters and pagination
- Public collections read without a key, private ones need one
- A typed client from
/api/v1/content/openapi.json
// Any framework, any host
const res = await fetch(
"https://pagehub.dev/api/v1/content/SITE_ID/posts?limit=10&sort=newest"
);
const { data, meta } = await res.json();
// data: [{ id, title, slug, image, metadata }]
// meta: { page, limit, count, totalCount, totalPages, hasMore }