> ## Documentation Index
> Fetch the complete documentation index at: https://docs.lumisreach.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Create an optimized post

> Make a text post (`format: text`) or a post with one picture (`format: image`) written to perform on the network it is for (`written_for`: `x`, `linkedin` or `instagram`). Unlike a `slideshow` from `POST /v1/videos`, which is written plainly from your sources, the post producer makes it start to finish, the way the dashboard's Create Post > Generate Automatically does: it researches the business, its competitors on that network and the news, recommends five post ideas, picks the strongest, and writes it with the tuned writer, which learns from the posts that did best and worst for accounts like yours and keeps the best of five drafts. It runs in the background (usually a few minutes): this answers `201` with `status: researching`; poll `GET /v1/optimized-posts/{id}` until it is `ready`, then post it with `POST /v1/videos/{video_id}/posts`. It is charged once, when the post is made, like a video (included video credits first, then the prepaid balance): its picture and writing at cost plus 20%, and for `instagram`, reading Instagram for the writer. `price_cents` is the estimate until then. On the API & MCP plan and the Growth Marketing Manager hire it is charged; on Revenue Engine and Custom it is free; other plans get `403 plan_not_included`.



## OpenAPI

````yaml /openapi.json post /v1/optimized-posts
openapi: 3.1.0
info:
  title: LumisReach v1 API
  version: 1.0.0
  description: >-
    Programmatic access to the LumisReach voice platform — calls, numbers,
    caller trust, and brands.
  contact:
    name: LumisReach
    email: founders@lumisreach.com
servers:
  - url: https://api.lumisreach.com/api
security:
  - bearerAuth: []
tags:
  - name: Contacts
  - name: Calls
  - name: Messages
  - name: Emails
  - name: Phone Numbers
  - name: Caller IDs
  - name: Enterprise Registration
  - name: Branded Calling
  - name: Dialer Calls
  - name: SMS
  - name: WebRTC
  - name: Reputation
  - name: Usage
  - name: Account
  - name: Billing
  - name: Documents
  - name: Lincoln AI
  - name: Optimized posts
  - name: Predictions
  - name: Quick Agent Actions
  - name: Sub-entities
  - name: Video schedules
  - name: Videos
paths:
  /v1/optimized-posts:
    post:
      tags:
        - Optimized posts
      summary: Create an optimized post
      description: >-
        Make a text post (`format: text`) or a post with one picture (`format:
        image`) written to perform on the network it is for (`written_for`: `x`,
        `linkedin` or `instagram`). Unlike a `slideshow` from `POST /v1/videos`,
        which is written plainly from your sources, the post producer makes it
        start to finish, the way the dashboard's Create Post > Generate
        Automatically does: it researches the business, its competitors on that
        network and the news, recommends five post ideas, picks the strongest,
        and writes it with the tuned writer, which learns from the posts that
        did best and worst for accounts like yours and keeps the best of five
        drafts. It runs in the background (usually a few minutes): this answers
        `201` with `status: researching`; poll `GET /v1/optimized-posts/{id}`
        until it is `ready`, then post it with `POST
        /v1/videos/{video_id}/posts`. It is charged once, when the post is made,
        like a video (included video credits first, then the prepaid balance):
        its picture and writing at cost plus 20%, and for `instagram`, reading
        Instagram for the writer. `price_cents` is the estimate until then. On
        the API & MCP plan and the Growth Marketing Manager hire it is charged;
        on Revenue Engine and Custom it is free; other plans get `403
        plan_not_included`.
      operationId: v1_optimized_posts_post
      parameters:
        - name: Idempotency-Key
          in: header
          required: false
          description: >-
            A UUID. When present, deduplicates repeat submissions. See
            /api-reference/idempotency.
          schema:
            type: string
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $schema: http://json-schema.org/draft-07/schema#
              type: object
              properties:
                format:
                  default: image
                  description: >-
                    `text` is the words alone (X and LinkedIn); `image` is the
                    words with one picture, drawn by AI unless you send
                    `source_image_urls`. Default `image`: a picture lifts
                    engagement.
                  type: string
                  enum:
                    - text
                    - image
                written_for:
                  description: >-
                    The network the post is written for. Its competitors are
                    studied there, and its writer learns from the posts that did
                    best and worst for accounts like yours on it: the post
                    models' dataset for `x` and `linkedin`, and Instagram
                    itself, read live, for `instagram` (which takes no `text`
                    post). Omit to write one post for X and LinkedIn at once.
                  type: string
                  enum:
                    - x
                    - linkedin
                    - instagram
                brief:
                  description: >-
                    What the post should be about, in a sentence or two: the
                    subject, the audience and the feel.
                  type: string
                  minLength: 1
                  maxLength: 1000
                title:
                  description: Your name for the post. Omit it and one is written.
                  type: string
                  minLength: 1
                  maxLength: 100
                language:
                  description: >-
                    The language the post is written in, as a code (`en`, `es`,
                    `fr`, ...). Default `en`.
                  type: string
                  enum:
                    - en
                    - en-GB
                    - en-AU
                    - es
                    - es-ES
                    - fr
                    - fr-CA
                    - de
                    - it
                    - pt-BR
                    - pt
                    - nl
                    - pl
                    - sv
                    - da
                    - 'no'
                    - fi
                    - cs
                    - el
                    - hu
                    - ro
                    - ru
                    - uk
                    - tr
                    - ar
                    - he
                    - hi
                    - zh
                    - zh-Hant
                    - zh-TW
                    - zh-Hans-TW
                    - yue
                    - yue-Hans
                    - ja
                    - ko
                    - id
                    - ms
                    - fil
                    - vi
                    - th
                source_url:
                  description: >-
                    The business's website. Omit to use the one saved in the
                    workspace's marketing profile.
                  type: string
                  format: uri
                source_text:
                  description: >-
                    A description of the business, product or offer, in your
                    words
                  type: string
                  minLength: 1
                  maxLength: 5000
                source_image_urls:
                  description: >-
                    Images already uploaded to LumisReach; an `image` post uses
                    one of them instead of drawing one
                  maxItems: 10
                  type: array
                  items:
                    type: string
                    format: uri
              required:
                - format
              additionalProperties: false
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                $schema: http://json-schema.org/draft-07/schema#
                type: object
                properties:
                  data:
                    type: object
                    properties:
                      id:
                        type: string
                        format: uuid
                        pattern: >-
                          ^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$
                      status:
                        type: string
                        enum:
                          - researching
                          - writing
                          - producing
                          - ready
                          - failed
                        description: >-
                          `researching` the business, its competitors and the
                          news; `writing` the post ideas and the post;
                          `producing` its picture; `ready` to post; `failed`
                          (see `error`)
                      format:
                        type: string
                        enum:
                          - text
                          - image
                      written_for:
                        anyOf:
                          - type: string
                            enum:
                              - x
                              - linkedin
                              - instagram
                          - type: 'null'
                        description: Null when it is written for X and LinkedIn at once
                      title:
                        type:
                          - string
                          - 'null'
                      text:
                        description: The post's words, with its hashtags, once written
                        type:
                          - string
                          - 'null'
                      image_url:
                        description: An `image` post's picture, once made
                        type:
                          - string
                          - 'null'
                      video_id:
                        anyOf:
                          - type: string
                            format: uuid
                            pattern: >-
                              ^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$
                          - type: 'null'
                        description: >-
                          The post as a video record, once it exists: post it
                          with `POST /v1/videos/{id}/posts` and read every
                          detail with `GET /v1/videos/{id}`
                      price_cents:
                        type: integer
                        minimum: -9007199254740991
                        maximum: 9007199254740991
                        description: >-
                          What it costs: what it was charged once made, an
                          estimate before then
                      price_estimated:
                        type: boolean
                      billed_cents:
                        anyOf:
                          - type: integer
                            minimum: -9007199254740991
                            maximum: 9007199254740991
                          - type: 'null'
                        description: >-
                          What it was charged, once made; 0 on a plan where it
                          is free
                      error:
                        type:
                          - string
                          - 'null'
                      dashboard_url:
                        type: string
                        description: Where to watch the producer work, in the dashboard
                      created_at:
                        type: string
                        format: date-time
                        pattern: >-
                          ^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))T(?:(?:[01]\d|2[0-3]):[0-5]\d:[0-5]\d(?:\.\d+)?(?:Z))$
                      updated_at:
                        type: string
                        format: date-time
                        pattern: >-
                          ^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))T(?:(?:[01]\d|2[0-3]):[0-5]\d:[0-5]\d(?:\.\d+)?(?:Z))$
                    required:
                      - id
                      - status
                      - format
                      - written_for
                      - title
                      - text
                      - image_url
                      - video_id
                      - price_cents
                      - price_estimated
                      - billed_cents
                      - error
                      - dashboard_url
                      - created_at
                      - updated_at
                    additionalProperties: false
                required:
                  - data
                additionalProperties: false
        '400':
          description: Validation error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorEnvelope'
        '401':
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorEnvelope'
        '403':
          description: Forbidden
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorEnvelope'
        '404':
          description: Not found
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorEnvelope'
        '409':
          description: Conflict (incl. idempotency conflicts)
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorEnvelope'
        '429':
          description: Rate limited
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorEnvelope'
components:
  schemas:
    ErrorEnvelope:
      type: object
      properties:
        error:
          type: object
          required:
            - code
            - message
          properties:
            code:
              type: string
            message:
              type: string
            fields:
              type: object
              additionalProperties:
                type: string
            doc_url:
              type: string
              format: uri
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.