Reference · Tools

Ghost

Manage posts on a Ghost CMS instance via the Content API (read-only) or Admin API (full CRUD).

Action Marketing v1

The Ghost node connects to a Ghost CMS instance and lets you create, update, delete, and list posts through the Admin API, or pull published content through the read-only Content API. Use it to build workflows that auto-publish posts from an external source, sync content across systems, or schedule drafts based on external triggers.

Node type
Action
Parameters
23
Outputs
Output, Error
Credentials
Ghost Admin API , Ghost Content API

Ghost

Manage posts on a Ghost CMS instance.

Overview

The Ghost tool interacts with a Ghost CMS instance. It supports two API sources: the Content API (read-only, for fetching published posts) and the Admin API (full CRUD for creating, reading, updating, and deleting posts). The Content API uses a simple API key as a query parameter, while the Admin API uses JWT-based authentication generated from an admin API key in id:secret format. Supports pagination for listing posts, multiple content formats (HTML, MobileDoc, Lexical), and post metadata including SEO, Open Graph, and Twitter card fields.

Category: Marketing
Tool Name: ghost
Version: 1

Appearance: Icon: si-ghost | Color: #15171A

Node Type

Action — processes input items and produces output

Input / Output

DirectionPort(s)
InputInput
OutputOutput, Error

Credentials

This tool uses Ghost Admin API and Ghost Content API credentials. Configure the one that matches the Source you select — the Content API key for read-only operations, the Admin API key for everything else. See the Credentials Guide for setup instructions.

Resources

ResourceValue
Postpost

Operations

Which operations are available depends on Source, not on the resource — the Content API is read-only, the Admin API can also write. Pick the source first, then the operation.

SourceOperationValueDescription
Content API (contentApi)GetgetGet a post
Content API (contentApi)Get ManygetAllGet many posts
Admin API (adminApi)CreatecreateCreate a post
Admin API (adminApi)DeletedeleteDelete a post
Admin API (adminApi)GetgetGet a post
Admin API (adminApi)Get ManygetAllGet many posts
Admin API (adminApi)UpdateupdateUpdate a post

Parameters

Source and Operation are the two selectors that decide everything else. Source, Operation, By, Identifier, Title, Content and Post ID accept expressions, so they can be driven from the incoming item; values placed inside the Additional Fields, Update Fields and Options collections are sent exactly as typed.

All Operations

ParameterTypeRequiredDefaultDescription
SourceoptionsNocontentApiPick where your data comes from: Content API (read-only) or Admin API (full CRUD).
Options: adminApi, contentApi
Max ConcurrencynumberNo10Maximum number of items to process concurrently (1–100).

Content API: Get

ParameterTypeRequiredDefaultDescription
ByoptionsYesidGet the post either by slug or ID.
Options: id, slug
IdentifierstringYesThe ID or slug of the post to get.
OptionscollectionNo{}Query options for the request.
— Fields (fields)stringNoLimit the fields returned in the response object. E.g. fields=title,url.
— Formats (formats)multiOptionsNo['html']Content formats to return.
Options: html, plaintext

Content API: Get Many

ParameterTypeRequiredDefaultDescription
Return AllbooleanNofalseWhether to return all results or only up to a given limit.
LimitnumberNo50Max number of results to return (1–100). (shown when Return All is false)
OptionscollectionNo{}Query options for the listing.
— Include (include)multiOptionsNo[]Tells the API to return additional data related to the resource.
Options: authors, tags
— Fields (fields)stringNoLimit the fields returned in the response object. E.g. fields=title,url.
— Formats (formats)multiOptionsNo['html']Content format(s) to return. By default only html is returned.
Options: html, plaintext, lexical

Admin API: Create

ParameterTypeRequiredDefaultDescription
TitlestringYesPost’s title.
Content FormatoptionsNohtmlThe format of the post content.
Options: html, mobileDoc, lexical
ContentstringNoThe HTML content of the post to create. (shown when Content Format is html)
Content (JSON)jsonNoMobiledoc is the raw JSON format that Ghost uses to store post contents. Must parse as valid JSON or the item fails. (shown when Content Format is mobileDoc)
Content (JSON)jsonNoLexical is the JSON format returned by the Ghost Default editor. Must parse as valid JSON or the item fails. (shown when Content Format is lexical)
Additional FieldscollectionNo{}Optional properties to set on the new post.
— Authors (authors)stringNoComma-separated list of author IDs. Find author IDs via the Ghost Admin API /users endpoint.
— Canonical URL (canonical_url)stringNoCanonical URL for the post.
— Code Injection Foot (codeinjection_foot)stringNoCode injection snippet for the footer.
— Code Injection Head (codeinjection_head)stringNoCode injection snippet for the header.
— Featured (featured)booleanNofalseWhether the post is featured.
— Meta Description (meta_description)stringNoSEO meta description.
— Meta Title (meta_title)stringNoSEO meta title.
— Open Graph Description (og_description)stringNoOpen Graph description.
— Open Graph Image (og_image)stringNoURL of the image.
— Open Graph Title (og_title)stringNoOpen Graph title.
— Published At (published_at)dateTimeNoRequired when status is “scheduled”.
— Slug (slug)stringNoURL slug for the post.
— Status (status)optionsNodraftPublication state of the post.
Options: draft, published, scheduled
— Tags (tags)stringNoComma-separated list of tag names. Ghost will create tags if they do not exist.
— Twitter Description (twitter_description)stringNoTwitter card description.
— Twitter Image (twitter_image)stringNoURL of the image.
— Twitter Title (twitter_title)stringNoTwitter card title.

Admin API: Delete

ParameterTypeRequiredDefaultDescription
Post IDstringYesThe ID of the post to delete.

Admin API: Get

ParameterTypeRequiredDefaultDescription
ByoptionsYesidGet the post either by slug or ID.
Options: id, slug
IdentifierstringYesThe ID or slug of the post to get.
OptionscollectionNo{}Query options for the request.
— Fields (fields)stringNoLimit the fields returned in the response object. E.g. fields=title,url.
— Formats (formats)multiOptionsNo['mobiledoc']Content formats to return.
Options: html, mobiledoc, lexical

Admin API: Get Many

ParameterTypeRequiredDefaultDescription
Return AllbooleanNofalseWhether to return all results or only up to a given limit.
LimitnumberNo50Max number of results to return (1–100). (shown when Return All is false)
OptionscollectionNo{}Query options for the listing.
— Include (include)multiOptionsNo[]Tells the API to return additional data related to the resource.
Options: authors, tags
— Fields (fields)stringNoLimit the fields returned in the response object. E.g. fields=title,url.
— Formats (formats)multiOptionsNo['mobiledoc']Content formats to return.
Options: html, mobiledoc, lexical

Admin API: Update

ParameterTypeRequiredDefaultDescription
Post IDstringYesThe ID of the post to update.
Content FormatoptionsNohtmlThe format of the post content. It decides which content field below is used.
Options: html, mobileDoc, lexical
Update FieldscollectionNo{}Fields to change. Only the fields you add are sent.
— Authors (authors)stringNoComma-separated list of author IDs. Find author IDs via the Ghost Admin API /users endpoint.
— Canonical URL (canonical_url)stringNoCanonical URL for the post.
— Code Injection Foot (codeinjection_foot)stringNoCode injection snippet for the footer.
— Code Injection Head (codeinjection_head)stringNoCode injection snippet for the header.
— Content (content)stringNoHTML content of the post. (shown when Content Format is html)
— Content (JSON) (contentJson)jsonNoMobiledoc JSON content of the post. (shown when Content Format is mobileDoc)
— Content (JSON) (contentJson)jsonNoLexical JSON content of the post. (shown when Content Format is lexical)
— Featured (featured)booleanNofalseWhether the post is featured.
— Meta Description (meta_description)stringNoSEO meta description.
— Meta Title (meta_title)stringNoSEO meta title.
— Open Graph Description (og_description)stringNoOpen Graph description.
— Open Graph Image (og_image)stringNoURL of the image.
— Open Graph Title (og_title)stringNoOpen Graph title.
— Published At (published_at)dateTimeNoRequired when status is “scheduled”.
— Slug (slug)stringNoURL slug for the post.
— Status (status)optionsNodraftPublication state of the post.
Options: draft, published, scheduled
— Tags (tags)stringNoComma-separated list of tag names. Ghost will create tags if they do not exist.
— Title (title)stringNoPost’s title.
— Twitter Description (twitter_description)stringNoTwitter card description.
— Twitter Image (twitter_image)stringNoURL of the image.
— Twitter Title (twitter_title)stringNoTwitter card title.

Output Data

The post returned by Ghost is merged onto the input item’s JSON at the top level — the fields the item already carried survive, and a post field with the same name overwrites the item’s value. Downstream nodes address the post directly ({{ $json.id }}, {{ $json.title }}). Binary data on the input item is forwarded unchanged.

OperationOutput
Get Many (either source)One output item per post returned. Return All keeps paging until Ghost runs out of posts, so this can be a large fan-out from a single input item.
Get, Create, Update (either source)One output item carrying the post.
DeleteOne output item carrying id and deleted: true — Ghost returns no body for a delete.

When a request comes back with no posts, the input item is still passed through unchanged, so an empty result is an item with no post fields on it rather than a missing item. Check for id before treating the branch as a hit.

Usage Examples

  • Get all published posts from Ghost blog
  • Create a new draft post on Ghost
  • Update an existing Ghost post with new content
  • Delete a Ghost post by ID
  • Fetch a post by slug from Ghost Content API

Example Configuration

Create an HTML post as a draft:

{
  "type": "ghost",
  "parameters": {
    "source": "adminApi",
    "resource": "post",
    "operation": "create",
    "title": "{{ $json.title }}",
    "contentFormat": "html",
    "content": "<h1>{{ $json.title }}</h1><p>{{ $json.body }}</p>",
    "additionalFields": {
      "slug": "my-new-blog-post",
      "status": "draft",
      "meta_description": "A great blog post about something interesting",
      "featured": false,
      "tags": "technology,blog"
    }
  }
}

Create a post from Mobiledoc JSON, scheduled for a fixed time:

{
  "type": "ghost",
  "parameters": {
    "source": "adminApi",
    "resource": "post",
    "operation": "create",
    "title": "Mobile Doc Post",
    "contentFormat": "mobileDoc",
    "content": "{\"version\":\"0.3.1\",\"atoms\":[],\"cards\":[],\"markups\":[],\"sections\":[[1,\"p\",[[0,[],0,\"This is a mobile doc post.\"]]]]}",
    "additionalFields": {
      "slug": "mobile-doc-post",
      "status": "scheduled",
      "published_at": "2026-01-01T12:00:00Z"
    }
  }
}

Read one published post by ID through the Content API:

{
  "type": "ghost",
  "parameters": {
    "source": "contentApi",
    "resource": "post",
    "operation": "get",
    "by": "id",
    "identifier": "{{ $json.postId }}",
    "options": {
      "fields": "id,title,slug,html,published_at",
      "formats": ["html"]
    }
  }
}

Read a post by slug:

{
  "type": "ghost",
  "parameters": {
    "source": "contentApi",
    "resource": "post",
    "operation": "get",
    "by": "slug",
    "identifier": "my-new-blog-post",
    "options": {
      "formats": ["html", "plaintext"]
    }
  }
}

List the ten most recent posts with their tags and authors:

{
  "type": "ghost",
  "parameters": {
    "source": "adminApi",
    "resource": "post",
    "operation": "getAll",
    "returnAll": false,
    "limit": 10,
    "options": {
      "include": ["tags", "authors"],
      "fields": "id,title,slug,status,published_at",
      "formats": ["html", "mobiledoc"]
    }
  }
}

Publish an existing draft:

{
  "type": "ghost",
  "parameters": {
    "source": "adminApi",
    "resource": "post",
    "operation": "update",
    "postId": "{{ $json.id }}",
    "contentFormat": "html",
    "updateFields": {
      "title": "Updated Post Title",
      "content": "<h1>Updated Content</h1><p>This post has been updated.</p>",
      "status": "published",
      "meta_title": "Updated Meta Title",
      "featured": true
    }
  }
}

Delete a post:

{
  "type": "ghost",
  "parameters": {
    "source": "adminApi",
    "resource": "post",
    "operation": "delete",
    "postId": "{{ $json.id }}"
  }
}

Error Handling

ModeBehavior
stopHalts workflow on first error
continueSkips failed items, passes successful ones through
errorPortRoutes failed items to Error output port

Tips

Manages posts on a Ghost CMS instance via Content API (read) or Admin API (CRUD) with JWT authentication.

  • Source picks the credential too. Content API operations authenticate with the Content API key, Admin API operations with the Admin API key, so the credential you have configured has to match the source you selected.
  • Update replaces the content field it is told to. Content Format decides which of the content fields inside Update Fields is sent, and on HTML the field is always sent — leaving it empty on an HTML update blanks the post body. Set Content Format to match the editor format the post already uses.
  • Updates are collision-safe. Before writing, the node reads the post’s current timestamp and sends it back with the change, so a post edited elsewhere in the meantime is rejected rather than silently overwritten.
  • Scheduling needs a date. Setting Status to scheduled without Published At fails the item.
  • Tags are created on demand. Tag names that do not exist yet are created by Ghost; author values must be existing author IDs.

Frequently asked questions

Do I need one credential or two — and which one should I set up?

It depends on what you need to do. The Content API credential (a simple API key) only supports reading published posts. The Admin API credential (an id:secret key pair used to generate a JWT) supports full create, read, update, and delete operations. Set up only the credential that matches the operations you intend to run — the node will reject the operation if the credential type doesn't match the selected source.

I'm updating a post's body but the content keeps getting wiped — what's happening?

The Content Format setting controls which content field is written during an update. If you choose HTML, the HTML field is always sent — even if you leave it blank — which will blank the post body. Make sure Content Format matches the format the post was originally written in (HTML, MobileDoc, or Lexical), and always provide the content value explicitly rather than leaving it empty.

Can two workflows update the same post at the same time without corrupting it?

The node is collision-safe. Before writing an update, it reads the post's current timestamp and sends it back with the change. If another process has edited the post in the meantime and changed that timestamp, Ghost will reject the update rather than silently overwrite the newer version. You'll receive an error on the Error output that you can handle in your workflow.

How do I schedule a post to publish at a future time?

Set Status to 'scheduled' and provide a value for the Published At field. Omitting Published At when using the scheduled status will cause the operation to fail. Make sure the datetime you supply is in the future relative to your Ghost instance's timezone.

Can I assign new tags to a post, or do they have to exist in Ghost already?

Tags are created on demand — if you supply a tag name that doesn't exist yet in Ghost, Ghost will create it automatically when the post is saved. Authors work differently: you must supply an existing author ID. Passing an unrecognized author value will not create a new author and will result in an error.

Build with the Ghost node

Drop it into a workflow, wire it to an agent, or call it on a schedule. You'll need Ghost Admin API credentials first.

Open BusyBot

Last updated . Spotted something wrong? Tell us.