Parameters

NameTypeRequiredDescription
brandIdstringYesOcoya brand id from ocoya_list_brands.
promptstringYesWhat the post should be about. Minimum 10 characters.
tonestringNoCaption tone. Defaults to professional. One of professional, friendly, educational, bold, founder_led.
postLengthstringNoCaption length. Defaults to medium. One of short, medium, long, extra_long.
channelIdsstring[]NoChannel ids from ocoya_list_channels to attach to the draft.
generateImagebooleanNoWhether to generate square image media for the draft.
imageCountnumberNoNumber of generated images when generateImage is true. Use 1 for a single image or 2-10 for a carousel.
referenceUrlsstring[]NoOptional image URLs to use as visual references when generateImage is true.
referenceDesignIdsstring[]NoOptional Studio design ids from ocoya_list_studio_templates to use as visual references when generateImage is true.
studioDesignIdstringNoOptional id of the brand’s own Studio design from ocoya_list_studio_designs. The post’s image is then that design, with its text layers written by the AI from the caption, instead of an AI-generated image. Every other layer stays as designed unless set in studioDesignFields. generateImage, imageCount and references are ignored.
studioDesignFieldsobjectNoOptional values for the Studio design’s layers, keyed by field id from ocoya_get_studio_design: an image URL for an image field (a logo, a product photo), a CSS colour for a colour field, or text for a text field, which is then used as given instead of being written by the AI. Only used with studioDesignId.

Request example

{
  "name": "ocoya_create_ai_post",
  "arguments": {
    "brandId": "cmayvq3hk00017apshay5qezu",
    "prompt": "Write a launch post for our new analytics dashboard.",
    "channelIds": ["clh49poxf008x8kov4ncbjty9"]
  }
}

Returns

Returns postGroupId, status and scheduledAt. This tool creates content, which can reach your connected networks once it publishes.