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

# Reply to a Mastodon status

> Reply to a Mastodon status via Posttu's Mastodon REST API (POST /api/v1/mastodon/posts/comments/create) and MCP server.

> [!NOTE]
>
> Looking for a unified API across all platforms? Posttu also provides a centralized [Inbox API](https://docs.posttu.com/api-reference/inbox/overview.md) (`/api/v1/inbox/*`) supporting comments, direct messages, replies, likes, and moderation in a single endpoint.


## OpenAPI

````yaml openapi.json POST /api/v1/mastodon/posts/comments/create
openapi: 3.1.0
info:
  title: Posttu API
  version: 1.0.0
  description: >-
    Posttu V1 REST API — Workflow automation, social-media post management,
    inbox, tags, and calendar.
servers:
  - url: https://posttu.com
    description: Production
security: []
paths:
  /api/v1/mastodon/posts/comments/create:
    post:
      tags:
        - Mastodon
      summary: Reply to a Mastodon status
      description: |-
        Reply to a Mastodon status
        Requires API key scope: `mastodon:write`.
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/MastodonCreateCommentInput'
      responses:
        '200':
          description: Successful response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/MastodonPostCommentCreateResponse'
        '401':
          description: Error response
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
                required:
                  - error
      security:
        - ApiKeyAuth: []
components:
  schemas:
    MastodonCreateCommentInput:
      type: object
      properties:
        channelId:
          type: string
          description: Mastodon channel ID
          example: ch_md123
        instanceUrl:
          type: string
        externalCommentId:
          type: string
          description: Mastodon status ID being replied to
        externalPostId:
          type: string
          description: Mastodon root status ID
        messageData:
          allOf:
            - $ref: '#/components/schemas/CreateComment'
            - description: >-
                Comment body. Mastodon-specific options (sensitive,
                spoiler_text, visibility) live under `messageData.mastodon`
              example:
                message: Great post!
      required:
        - channelId
        - messageData
    MastodonPostCommentCreateResponse:
      type: object
      properties:
        data:
          allOf:
            - $ref: '#/components/schemas/MastodonStatus'
            - type:
                - object
                - 'null'
        success:
          type: boolean
        error:
          type: string
      required:
        - data
        - success
    CreateComment:
      type: object
      properties:
        media:
          type: array
          items:
            type: object
            properties:
              item:
                type: object
                properties:
                  id:
                    type: string
                    description: Media ID from the source
                  source:
                    type: string
                    enum:
                      - ONLYFANS
                      - FANSLY
                      - FANVUE
                      - POSTTU
                    default: POSTTU
                    description: Source of the media.
                  previewId:
                    type:
                      - string
                      - 'null'
                    description: Preview ID
                  coverId:
                    type:
                      - string
                      - 'null'
                    description: Cover ID
                  sourceChannelId:
                    type: string
                    description: >-
                      Source channel ID required when source is not posttu
                      upload or id
                  isPreview:
                    type:
                      - boolean
                      - 'null'
                    description: Is preview image
                  isCover:
                    type:
                      - boolean
                      - 'null'
                    description: Is cover image
                required:
                  - id
              order:
                type: number
                description: Order of the media in the message
                example: 1
            required:
              - item
          description: >-
            Array of media that will be used in this request including preview
            and cover images if any. If the platform is fansly, you must also
            pass media in the fansly.media field if you want to add custom
            permissions or bundle media together, otherwise the default
            permissions will be applied to the media items and will treat this
            as a single bundle of media.
        message:
          type: string
          description: Comment text
          example: Great post!
        fansly:
          type: object
          properties:
            lockedText:
              type: array
              items:
                type: object
                properties:
                  text:
                    type: string
                  permissions:
                    anyOf:
                      - type: array
                        items:
                          type: object
                          properties:
                            id:
                              type: string
                            flags:
                              type: number
                            verificationFlags:
                              type:
                                - number
                                - 'null'
                            metadata:
                              type:
                                - string
                                - 'null'
                            validAfter:
                              type:
                                - number
                                - 'null'
                            validBefore:
                              type:
                                - number
                                - 'null'
                            price:
                              type: number
                              default: 0
                            type:
                              type: number
                              default: 0
                          required:
                            - flags
                      - type: array
                        items:
                          anyOf:
                            - type: object
                              properties:
                                price:
                                  type: number
                                  minimum: 5
                                  default: 5
                                  description: >-
                                    The price to purchase the locked text.
                                    Default value is 5.
                                tipped:
                                  type: number
                                  minimum: 0.5
                                  default: 0.5
                                  description: >-
                                    Limit to users who tipped at least this
                                    amount. Default value is 0.5.
                                following:
                                  type: boolean
                                  description: >-
                                    Grant access to users who are following the
                                    account.
                                subscribed:
                                  type: boolean
                                  description: >-
                                    Grant access to users who are subscribed to
                                    the account. cannot be used with
                                    subscription
                            - type: object
                              additionalProperties:
                                type: object
                                properties:
                                  price:
                                    type: number
                                    minimum: 5
                                    default: 5
                                    description: >-
                                      The price to purchase the locked text.
                                      Default value is 5.
                                  tipped:
                                    type: number
                                    minimum: 0.5
                                    default: 0.5
                                    description: >-
                                      Limit to users who tipped at least this
                                      amount. Default value is 0.5.
                                  following:
                                    type: boolean
                                    description: >-
                                      Grant access to users who are following
                                      the account.
                                  subscribed:
                                    type: boolean
                                    description: >-
                                      Grant access to users who are subscribed
                                      to the account. cannot be used with
                                      subscription
                required:
                  - text
              description: Fansly locked texts
            media:
              type: array
              items:
                type: object
                properties:
                  items:
                    type: array
                    items:
                      type: object
                      properties:
                        id:
                          type: string
                        source:
                          type: string
                          enum:
                            - POSTTU
                            - FANSLY
                            - ONLYFANS
                            - FANVUE
                        previewId:
                          type:
                            - string
                            - 'null'
                          description: >-
                            Preview id of the media, leave blank if not
                            applicable
                        coverId:
                          type:
                            - string
                            - 'null'
                          description: >-
                            Cover id of the media for videos, leave blank if not
                            applicable
                        sourceChannelId:
                          type:
                            - string
                            - 'null'
                          description: >-
                            Source channel id of the media, leave blank if
                            source is posttu
                        isPreview:
                          type:
                            - boolean
                            - 'null'
                          description: Is preview image
                        isCover:
                          type:
                            - boolean
                            - 'null'
                          description: Is cover image
                      required:
                        - id
                        - source
                      description: Array of media
                  order:
                    type: number
                    description: >-
                      Order of the media bundle in the message. The API requires
                      a value; it is filled from the array index when omitted.
                    example: 1
                  permissions:
                    anyOf:
                      - type: array
                        items:
                          type: object
                          properties:
                            id:
                              type: string
                            flags:
                              type: number
                            verificationFlags:
                              type:
                                - number
                                - 'null'
                            metadata:
                              type:
                                - string
                                - 'null'
                            validAfter:
                              type:
                                - number
                                - 'null'
                            validBefore:
                              type:
                                - number
                                - 'null'
                            price:
                              type: number
                              default: 0
                            type:
                              type: number
                              default: 0
                          required:
                            - flags
                      - type: array
                        items:
                          anyOf:
                            - type: object
                              properties:
                                price:
                                  type: number
                                  minimum: 5
                                  default: 5
                                  description: >-
                                    The price to purchase the locked text.
                                    Default value is 5.
                                validAfter:
                                  type:
                                    - number
                                    - 'null'
                                  default: null
                                  description: >-
                                    Avaliable after this date (unix timestamp in
                                    seconds). Default value is null.
                                validBefore:
                                  type:
                                    - number
                                    - 'null'
                                  default: null
                                  description: >-
                                    Avaliable until this date (unix timestamp in
                                    seconds). Default value is null.
                                list:
                                  type: object
                                  properties:
                                    id:
                                      type: string
                                      description: The id of the list.
                                    label:
                                      type: string
                                      description: The name of the list.
                                  required:
                                    - id
                                    - label
                                subscription:
                                  type: object
                                  properties:
                                    id:
                                      type: string
                                      default: ''
                                      description: >-
                                        The id of the subscription level. leave
                                        blank if you want to match any
                                        subscription level defaults to empty
                                        string
                                    name:
                                      type: string
                                      default: ''
                                      description: >-
                                        The name of the subscription level.
                                        leave blank if you want to match any
                                        subscription name defaults to empty
                                        string
                                    before:
                                      type: number
                                      default: 0
                                      description: >-
                                        Limit to users who had an active
                                        subscription before this date. e.g.
                                        1672531200 (unix timestamp in seconds)
                                    after:
                                      type: number
                                      default: 0
                                      description: >-
                                        Limit to users who had an active
                                        subscription after this date. e.g.
                                        1672531200 (unix timestamp in seconds)
                                following:
                                  type: boolean
                                  description: >-
                                    Grant access to users who are following the
                                    account.
                                subscribed:
                                  type: boolean
                                  description: >-
                                    Grant access to users who are subscribed to
                                    the account. cannot be used with
                                    subscription
                              description: >-
                                Used to build media permission for fansly. Can't
                                have both 'subscribed' and 'subscription' in the
                                same object.
                            - type: object
                              additionalProperties:
                                type: object
                                properties:
                                  price:
                                    type: number
                                    minimum: 5
                                    default: 5
                                    description: >-
                                      The price to purchase the locked text.
                                      Default value is 5.
                                  validAfter:
                                    type:
                                      - number
                                      - 'null'
                                    default: null
                                    description: >-
                                      Avaliable after this date (unix timestamp
                                      in seconds). Default value is null.
                                  validBefore:
                                    type:
                                      - number
                                      - 'null'
                                    default: null
                                    description: >-
                                      Avaliable until this date (unix timestamp
                                      in seconds). Default value is null.
                                  list:
                                    type: object
                                    properties:
                                      id:
                                        type: string
                                        description: The id of the list.
                                      label:
                                        type: string
                                        description: The name of the list.
                                    required:
                                      - id
                                      - label
                                  subscription:
                                    type: object
                                    properties:
                                      id:
                                        type: string
                                        default: ''
                                        description: >-
                                          The id of the subscription level. leave
                                          blank if you want to match any
                                          subscription level defaults to empty
                                          string
                                      name:
                                        type: string
                                        default: ''
                                        description: >-
                                          The name of the subscription level.
                                          leave blank if you want to match any
                                          subscription name defaults to empty
                                          string
                                      before:
                                        type: number
                                        default: 0
                                        description: >-
                                          Limit to users who had an active
                                          subscription before this date. e.g.
                                          1672531200 (unix timestamp in seconds)
                                      after:
                                        type: number
                                        default: 0
                                        description: >-
                                          Limit to users who had an active
                                          subscription after this date. e.g.
                                          1672531200 (unix timestamp in seconds)
                                  following:
                                    type: boolean
                                    description: >-
                                      Grant access to users who are following
                                      the account.
                                  subscribed:
                                    type: boolean
                                    description: >-
                                      Grant access to users who are subscribed
                                      to the account. cannot be used with
                                      subscription
                                description: >-
                                  Used to build media permission for fansly.
                                  Can't have both 'subscribed' and
                                  'subscription' in the same object.
                required:
                  - items
              description: >-
                Array of media for fansly. Media placed in items will be bundled
                together.
        onlyfans:
          type: object
          properties:
            price:
              type: number
              description: Message price
              example: 5
            lockedText:
              type: boolean
              default: false
        mastodon:
          type: object
          properties:
            sensitive:
              type: boolean
            spoiler_text:
              type: string
            visibility:
              type: string
              enum:
                - public
                - unlisted
                - private
                - direct
      description: Message payload
      example:
        text: Hello!
    MastodonStatus:
      type: object
      properties:
        id:
          type: string
        created_at:
          type: string
        in_reply_to_id:
          type:
            - string
            - 'null'
        in_reply_to_account_id:
          type:
            - string
            - 'null'
        sensitive:
          type: boolean
        spoiler_text:
          type: string
        visibility:
          type: string
          enum:
            - public
            - unlisted
            - private
            - direct
        language:
          type:
            - string
            - 'null'
        uri:
          type: string
        url:
          type:
            - string
            - 'null'
        replies_count:
          type: number
        reblogs_count:
          type: number
        favourites_count:
          type: number
        edited_at:
          type:
            - string
            - 'null'
        favourited:
          type: boolean
        reblogged:
          type: boolean
        muted:
          type: boolean
        bookmarked:
          type: boolean
        pinned:
          type: boolean
        content:
          type: string
        reblog:
          oneOf:
            - $ref: '#/components/schemas/MastodonStatus'
            - type: 'null'
        account:
          $ref: '#/components/schemas/MastodonAccount'
        media_attachments:
          type: array
          items:
            $ref: '#/components/schemas/MastodonMediaAttachment'
        mentions:
          type: array
          items:
            type: object
            properties:
              id:
                type: string
              username:
                type: string
              url:
                type: string
              acct:
                type: string
            required:
              - id
              - username
              - url
              - acct
        tags:
          type: array
          items:
            type: object
            properties:
              name:
                type: string
              url:
                type: string
            required:
              - name
              - url
        emojis:
          type: array
          items: {}
        card: {}
        poll:
          $ref: '#/components/schemas/MastodonPoll'
        quote:
          oneOf:
            - $ref: '#/components/schemas/MastodonStatus'
            - type: 'null'
      required:
        - id
        - created_at
        - in_reply_to_id
        - in_reply_to_account_id
        - sensitive
        - spoiler_text
        - visibility
        - language
        - uri
        - url
        - replies_count
        - reblogs_count
        - favourites_count
        - edited_at
        - content
        - reblog
        - account
        - media_attachments
        - poll
      additionalProperties: {}
    MastodonAccount:
      type:
        - object
        - 'null'
      properties:
        id:
          type: string
        username:
          type: string
        acct:
          type: string
        display_name:
          type: string
        locked:
          type: boolean
        bot:
          type: boolean
        created_at:
          type: string
        note:
          type: string
        url:
          type: string
        avatar:
          type: string
        avatar_static:
          type: string
        header:
          type: string
        header_static:
          type: string
        followers_count:
          type: number
        following_count:
          type: number
        statuses_count:
          type: number
        last_status_at:
          type:
            - string
            - 'null'
        emojis:
          type: array
          items: {}
        fields:
          type: array
          items:
            type: object
            properties:
              name:
                type: string
              value:
                type: string
              verified_at:
                type:
                  - string
                  - 'null'
            required:
              - name
              - value
              - verified_at
      required:
        - id
        - username
        - acct
        - display_name
        - locked
        - bot
        - created_at
        - note
        - url
        - avatar
        - avatar_static
        - header
        - header_static
        - followers_count
        - following_count
        - statuses_count
        - last_status_at
      additionalProperties: {}
    MastodonMediaAttachment:
      type: object
      properties:
        id:
          type: string
        type:
          type: string
          enum:
            - image
            - video
            - gifv
            - audio
            - unknown
        url:
          type:
            - string
            - 'null'
        preview_url:
          type: string
        remote_url:
          type:
            - string
            - 'null'
        text_url:
          type:
            - string
            - 'null'
        meta:
          type:
            - object
            - 'null'
          properties:
            original:
              type: object
              properties:
                width:
                  type: number
                height:
                  type: number
                size:
                  type: string
                aspect:
                  type: number
                duration:
                  type: number
                bitrate:
                  type: number
            small:
              type: object
              properties:
                width:
                  type: number
                height:
                  type: number
                size:
                  type: string
                aspect:
                  type: number
            focus:
              type: object
              properties:
                x:
                  type: number
                'y':
                  type: number
              required:
                - x
                - 'y'
          additionalProperties: {}
        description:
          type:
            - string
            - 'null'
        blurhash:
          type:
            - string
            - 'null'
      required:
        - id
        - type
        - url
        - preview_url
        - remote_url
        - text_url
        - description
        - blurhash
      additionalProperties: {}
    MastodonPoll:
      type:
        - object
        - 'null'
      properties:
        id:
          type: string
        expires_at:
          type:
            - string
            - 'null'
        expired:
          type: boolean
        multiple:
          type: boolean
        votes_count:
          type: number
        voters_count:
          type:
            - number
            - 'null'
        options:
          type: array
          items:
            type: object
            properties:
              title:
                type: string
              votes_count:
                type:
                  - number
                  - 'null'
            required:
              - title
              - votes_count
        voted:
          type: boolean
        own_votes:
          type: array
          items:
            type: number
        emojis:
          type: array
          items: {}
      required:
        - id
        - expires_at
        - expired
        - multiple
        - votes_count
        - voters_count
        - options
  securitySchemes:
    ApiKeyAuth:
      type: http
      scheme: bearer
      description: 'Pass your API key via the Authorization header: `Bearer <api-key>`'

````

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