Skip to content

Docs

create_content

Create content: a card on the board holding one idea that becomes a post per channel. It starts in Idea with an empty original draft, or in Drafting with `masterText` (or the `status` you pass). Next: add_source, update_original, create_post per channel account, then request_schedule or add_to_queue (a human confirms agent requests). Campaigns are free-form labels. `plannedFor` (YYYY-MM-DD, the workspace's time zone) puts the unscheduled draft on that calendar day as a planning aid; `plannedTime` (HH:MM, 24-hour, same zone; needs `plannedFor`) puts it at that time of the day, like the calendar's "+" on a time slot. Neither ever schedules or publishes anything. `url` is the content page: give it to the person. Pipelines that may retry pass `idempotencyKey`: the same key from you in this workspace within 24 hours returns the content the first call created (`replayed: true`) and creates nothing; the same key with different input is refused (`idempotency_conflict`).

Create content: a card on the board holding one idea that becomes a post per channel. It starts in Idea with an empty original draft, or in Drafting with masterText (or the status you pass). Next: add_source, update_original, create_post per channel account, then request_schedule or add_to_queue (a human confirms agent requests). Campaigns are free-form labels. plannedFor (YYYY-MM-DD, the workspace's time zone) puts the unscheduled draft on that calendar day as a planning aid; plannedTime (HH:MM, 24-hour, same zone; needs plannedFor) puts it at that time of the day, like the calendar's "+" on a time slot. Neither ever schedules or publishes anything. url is the content page: give it to the person. Pipelines that may retry pass idempotencyKey: the same key from you in this workspace within 24 hours returns the content the first call created (replayed: true) and creates nothing; the same key with different input is refused (idempotency_conflict).

Access and cost

  • Kind: mutation
  • Scope: workspace
  • Actors: member, agent
  • Credits: Free
  • Requires confirmation: false
  • Accepts idempotency key: true

Input schema

{
  "properties": {
    "workspaceId": {
      "format": "uuid",
      "type": "string"
    },
    "title": {
      "maxLength": 300,
      "minLength": 1,
      "type": "string"
    },
    "status": {
      "enum": [
        "idea",
        "drafting",
        "in_review"
      ],
      "type": "string"
    },
    "campaignLabels": {
      "items": {
        "maxLength": 60,
        "minLength": 1,
        "type": "string"
      },
      "maxItems": 10,
      "type": "array"
    },
    "ownerAccountId": {
      "format": "uuid",
      "type": "string"
    },
    "masterText": {
      "type": "string"
    },
    "plannedFor": {
      "anyOf": [
        {
          "format": "date",
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "plannedTime": {
      "anyOf": [
        {
          "pattern": "^([01]\\d|2[0-3]):[0-5]\\d$",
          "type": "string"
        },
        {
          "type": "null"
        }
      ]
    },
    "idempotencyKey": {
      "description": "Optional. A key you choose for this request (for example your pipeline's job id). Sending the same key again within 24 hours returns what the first call created (`replayed: true`) instead of creating it twice.",
      "maxLength": 200,
      "minLength": 1,
      "type": "string"
    }
  },
  "required": [
    "workspaceId",
    "title"
  ],
  "type": "object"
}

Output schema

{
  "additionalProperties": false,
  "properties": {
    "piece": {
      "additionalProperties": false,
      "properties": {
        "id": {
          "format": "uuid",
          "type": "string"
        },
        "workspaceId": {
          "format": "uuid",
          "type": "string"
        },
        "title": {
          "type": "string"
        },
        "status": {
          "enum": [
            "idea",
            "drafting",
            "in_review",
            "scheduled",
            "published"
          ],
          "type": "string"
        },
        "campaignLabels": {
          "items": {
            "type": "string"
          },
          "type": "array"
        },
        "ownerAccountId": {
          "anyOf": [
            {
              "format": "uuid",
              "type": "string"
            },
            {
              "type": "null"
            }
          ]
        },
        "boardPosition": {
          "type": "string"
        },
        "archivedAt": {
          "anyOf": [
            {
              "format": "date-time",
              "type": "string"
            },
            {
              "type": "null"
            }
          ]
        },
        "createdByAccountId": {
          "anyOf": [
            {
              "format": "uuid",
              "type": "string"
            },
            {
              "type": "null"
            }
          ]
        },
        "createdByAgentClientId": {
          "anyOf": [
            {
              "format": "uuid",
              "type": "string"
            },
            {
              "type": "null"
            }
          ]
        },
        "createdAt": {
          "format": "date-time",
          "type": "string"
        },
        "updatedAt": {
          "format": "date-time",
          "type": "string"
        },
        "signoffRequired": {
          "type": "boolean"
        },
        "plannedFor": {
          "anyOf": [
            {
              "format": "date",
              "type": "string"
            },
            {
              "type": "null"
            }
          ]
        },
        "plannedTime": {
          "anyOf": [
            {
              "pattern": "^([01]\\d|2[0-3]):[0-5]\\d$",
              "type": "string"
            },
            {
              "type": "null"
            }
          ]
        }
      },
      "required": [
        "id",
        "workspaceId",
        "title",
        "status",
        "campaignLabels",
        "ownerAccountId",
        "boardPosition",
        "archivedAt",
        "createdByAccountId",
        "createdByAgentClientId",
        "createdAt",
        "updatedAt",
        "signoffRequired"
      ],
      "type": "object"
    },
    "master": {
      "additionalProperties": false,
      "properties": {
        "pieceId": {
          "format": "uuid",
          "type": "string"
        },
        "workspaceId": {
          "format": "uuid",
          "type": "string"
        },
        "text": {
          "type": "string"
        },
        "media": {
          "items": {
            "additionalProperties": false,
            "properties": {
              "mediaAssetId": {
                "format": "uuid",
                "type": "string"
              },
              "altText": {
                "maxLength": 2000,
                "type": "string"
              }
            },
            "required": [
              "mediaAssetId"
            ],
            "type": "object"
          },
          "type": "array"
        },
        "version": {
          "minimum": 1,
          "type": "integer"
        },
        "updatedByAccountId": {
          "anyOf": [
            {
              "format": "uuid",
              "type": "string"
            },
            {
              "type": "null"
            }
          ]
        },
        "updatedByAgentClientId": {
          "anyOf": [
            {
              "format": "uuid",
              "type": "string"
            },
            {
              "type": "null"
            }
          ]
        },
        "createdAt": {
          "format": "date-time",
          "type": "string"
        },
        "updatedAt": {
          "format": "date-time",
          "type": "string"
        }
      },
      "required": [
        "pieceId",
        "workspaceId",
        "text",
        "media",
        "version",
        "updatedByAccountId",
        "updatedByAgentClientId",
        "createdAt",
        "updatedAt"
      ],
      "type": "object"
    },
    "url": {
      "description": "The content page in heyeveryone. Give it to the person so they can open the draft.",
      "type": "string"
    },
    "replayed": {
      "type": "boolean"
    }
  },
  "required": [
    "piece",
    "master",
    "url",
    "replayed"
  ],
  "type": "object"
}

Errors

[
  "idempotency_conflict"
]

Annotations

{
  "destructiveHint": false,
  "idempotentHint": false,
  "openWorldHint": false,
  "readOnlyHint": false,
  "title": "Create content"
}