REST API integration
Ghost REST API integration for Draftbit
Fetch published Ghost content
What is Ghost?
Ghost's Content API is designed for public app and website reads. Add your Ghost site domain and content API key to load posts, pages, tags, authors, and settings.
Use Ghost with Draftbit
- Built-in endpoints: List posts, Get post by slug, List pages, List tags, List authors.
- Bind any Ghost endpoint to a screen, list, form, or AI agent action.
- Authentication is configured once per app — secrets stay on the server.
- Add custom request and response transforms without forking Ghost's client library.
Example
ghost-example.ts // Example: fetch from Ghost
// Ghost doesn't require an auth header for this endpoint —
// some providers authenticate via a query param or app-level token.
// Check Ghost's docs for auth requirements on protected endpoints.
const response = await fetch("https://{site_domain}/ghost/api/content/posts/");
const data = await response.json();Use cases
- Drive a blog, news feed, or content section from a headless CMS
- Let non-engineers publish app content without a release
- Localize copy and assets without code changes
Authentication
Add any required auth headers when you connect Ghost in Draftbit. Secrets stay on the server side.
Use Ghost in a Draftbit app today
Start free, connect Ghost in minutes, and ship with AI agents that know how to use it.
Frequently asked questions
What is the Ghost REST integration?
Ghost's Content API is designed for public app and website reads. Add your Ghost site domain and content API key to load posts, pages, tags, authors, and settings.
How do I connect Ghost to a Draftbit app?
Go to Integrations and then REST APIs in your Draftbit app and pick Ghost from the catalog. Fill in any base URL variables, such as a project ID or host, and the endpoints are available across your screens and to the AI agents while you build. The preconfigured calls need no auth header.
Does Ghost require authentication?
The preconfigured Ghost endpoints do not need an auth header. Some providers authenticate with a query parameter or an app-level token, and others are public read-only APIs, so check the Ghost docs before you call a protected endpoint. The preconfigured endpoints include List posts, Get post by slug, List pages, List tags.
What can I build with Ghost and Draftbit?
Most teams use Ghost as a headless CMS for a mobile or web app. You might use Ghost to drive a blog, news feed, or content section from a headless CMS, or to let non-engineers publish app content without a release.