Create a scheduled or draft post

post

Returns the id of the post

Authorizations
Query parameters
workspaceIdstringRequiredExample: cmayvq3hk00017apshay5qezu
Body
one ofOptional
or
or
Responses
201
Created
post
POST /api/_public/v1/post HTTP/1.1
Host: app.ocoya.com
X-API-Key: YOUR_API_KEY
Content-Type: application/json
Accept: */*
Content-Length: 165

{
  "caption": "Happy new year everyone!",
  "mediaUrls": [
    "https://yourmediaurl.com"
  ],
  "socialProfileIds": [
    "clh49poxf008x8kov4ncbjty9"
  ],
  "scheduledAt": "2024-01-01T00:00:00Z"
}

No content

Body parameters explained

Parameter
Type
Required
Information

caption

string

yes (if mediaUrls not provided)

Up to 10,000 characters

mediaUrls

array of strings

yes (if caption not provided)

URL list of the media (must follow URL file limitations)

socialProfileIds

array of strings

no

If no ids provided, creates post as a draft

scheduledAt

string

no

Date of the schedule (must follow Date limitations)

Sample response

{
    "postGroupId": "clg07n1us0002998kbzmp7zc7",
}

Response parameters

Parameter
Type
Description

postGroupId

string

Id of the created post

Last updated