PATCH
https://www.app.ocoya.com/api/_public/v1/seo/{postId}
Update SEO post
curl --request PATCH \
  --url https://www.app.ocoya.com/api/_public/v1/seo/{postId} \
  --header 'Content-Type: application/json' \
  --header 'X-API-Key: <api-key>' \
  --data '
{
  "title": "<string>",
  "body": "<string>",
  "slug": "how-to-plan-a-content-calendar",
  "excerpt": "<string>",
  "seoTitle": "<string>",
  "metaDescription": "<string>",
  "keyword": "content calendar",
  "tags": [
    "Marketing"
  ],
  "channelIds": [
    "clh49poxf008x8kov4ncbjty9"
  ],
  "cms": {
    "webflow": {
      "status": "draft"
    },
    "framer": {
      "status": "draft"
    },
    "wix": {
      "status": "draft"
    }
  },
  "addChannelIds": [
    "clh49poxf008x8kov4ncbjty9"
  ],
  "thumbnail": {
    "url": "https://example.com/cover.jpg",
    "data": "<string>",
    "generate": true,
    "prompt": "A laptop on a café table with a planner open",
    "aspectRatio": "16:9"
  },
  "scheduledAt": "2024-01-01T00:00:00Z",
  "publishNow": true
}
'
{
  "postGroupId": "cmajvvb9q0003ja5vh0538j6r",
  "status": "DRAFT",
  "scheduledAt": null
}

Authorizations

X-API-Keystringheaderrequired

Your API key. Create one in Ocoya. Authorization: Bearer <key> works too.

Path Parameters

postIdstringrequired

Ocoya post ID.

Example:"cmajvvb9q0003ja5vh0538j6r"

Body

application/json
titlestring

The headline. Every channel's title follows it.

Required string length: 1 - 300
bodystring

The post, in Markdown.

Minimum string length: 1
slugstring

URL slug. Defaults to one made from the title.

Example:"how-to-plan-a-content-calendar"
excerptstring

Short summary shown in blog lists. Defaults to the meta description.

Maximum string length: 500
seoTitlestring

Title for search results. Defaults to the title.

Maximum string length: 120
metaDescriptionstring

Search results summary. Drafted from the introduction when not given.

Maximum string length: 320
keywordstring

The search phrase the post targets. The SEO score checks against it and the brand's keywords.

Maximum string length: 100
Example:"content calendar"
tagsstring[]

Up to 10 tags.

Maximum array length: 10
Example:
[
  "Marketing"
]
channelIdsstring[]

Blog or site channels to publish to: WordPress, DEV, Notion, Webflow, Framer, Wix or Webhook. Get IDs from GET /channels.

Example:
[
  "clh49poxf008x8kov4ncbjty9"
]
cmsobject

Per-CMS settings, applied when the post has a channel on that CMS. Each is live unless set. WordPress and DEV always publish live.

Show child attributesHide child attributes
cms.webflowobject
Show child attributesHide child attributes
cms.webflow.statusenum<string>required

live publishes the item at once, draft keeps it a draft on the site.

Available options: live, draft
Example:"draft"
cms.framerobject
Show child attributesHide child attributes
cms.framer.statusenum<string>required

live publishes the item at once, draft keeps it a draft on the site.

Available options: live, draft
Example:"draft"
cms.wixobject
Show child attributesHide child attributes
cms.wix.statusenum<string>required

live publishes the item at once, draft keeps it a draft on the site.

Available options: live, draft
Example:"draft"
addChannelIdsstring[]

Channels to add, keeping the ones already on the post.

Example:
[
  "clh49poxf008x8kov4ncbjty9"
]
thumbnailobject | null

A new cover image, or null to remove it.

Show child attributesHide child attributes
thumbnail.urlstring

A public image URL. Downloaded and copied to Ocoya.

Example:"https://example.com/cover.jpg"
thumbnail.datastring

An uploaded image: base64, or a data:image/…;base64, URL. At most 4 MB decoded.

thumbnail.generateboolean

true makes an AI thumbnail in the brand's style, as an SEO campaign does. Costs credits.

thumbnail.promptstring

With generate: what the image should show. Defaults to the post itself.

Example:"A laptop on a café table with a planner open"
thumbnail.aspectRatioenum<string>

With generate: 16:9 (default), 1:1 or 4:5.

Available options: 4:5, 1:1, 16:9
Example:"16:9"
scheduledAtstring | null

ISO 8601 datetime to publish at, or null to unschedule.

Example:"2024-01-01T00:00:00Z"
publishNowboolean

Publish at once to every channel.

Response

application/json

Success

postGroupIdstring

ID of the post.

Example:"cmajvvb9q0003ja5vh0538j6r"
statusstring
Example:"DRAFT"
scheduledAtstring | null