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

# Create forum post

> Create a new forum post or comment within an experience. Supports text content, attachments, polls, paywalling, and pinning. Pass experience_id 'public' with a company_id to post to a company's public forum.

Required permissions:
 - `forum:post:create`



## OpenAPI

````yaml https://app.stainless.com/api/spec/documented/whopsdk/openapi.documented.yml post /forum_posts
openapi: 3.1.0
info:
  title: Whop API
  description: >-
    The Whop REST API. Please see
    https://docs.whop.com/developer/api/getting-started for more details.
  termsOfService: https://whop.com/tos-developer-api/
  version: 1.0.0
servers:
  - url: https://api.whop.com/api/v1
    description: Production Whop API
security: []
tags:
  - name: Products
    description: Products
  - name: Plans
    description: Plans
  - name: Payments
    description: Payments
  - name: Refunds
    description: Refunds
  - name: Disputes
    description: Disputes
  - name: Dispute alerts
    description: Dispute alerts
  - name: Resolution center cases
    description: Resolution center cases
  - name: Checkout configurations
    description: Checkout configurations
  - name: Setup intents
    description: Setup intents
  - name: Payment methods
    description: Payment methods
  - name: Invoices
    description: Invoices
  - name: Promo codes
    description: Promo codes
  - name: Card transactions
    description: Card transactions
  - name: Ledger accounts
    description: Ledger accounts
  - name: Transfers
    description: Transfers
  - name: Withdrawals
    description: Withdrawals
  - name: Payout methods
    description: Payout methods
  - name: Verifications
    description: Verifications
  - name: Payout accounts
    description: Payout accounts
  - name: Topups
    description: Topups
  - name: Users
    description: Users
  - name: Companies
    description: Companies
  - name: Authorized users
    description: Authorized users
  - name: Fee markups
    description: Fee markups
  - name: Members
    description: Members
  - name: Memberships
    description: Memberships
  - name: Leads
    description: Leads
  - name: Entries
    description: Entries
  - name: Shipments
    description: Shipments
  - name: Reviews
    description: Reviews
  - name: Company token transactions
    description: Company token transactions
  - name: Affiliates
    description: Affiliates
  - name: Experiences
    description: Experiences
  - name: Forums
    description: Forums
  - name: Forum posts
    description: Forum posts
  - name: Chat channels
    description: Chat channels
  - name: Support channels
    description: Support channels
  - name: Messages
    description: Messages
  - name: Reactions
    description: Reactions
  - name: Dm members
    description: Dm members
  - name: Dm channels
    description: Dm channels
  - name: Notifications
    description: Notifications
  - name: Courses
    description: Courses
  - name: Course chapters
    description: Course chapters
  - name: Course lessons
    description: Course lessons
  - name: Course students
    description: Course students
  - name: Course lesson interactions
    description: Course lesson interactions
  - name: Apps
    description: Apps
  - name: Webhooks
    description: Webhooks
  - name: App builds
    description: App builds
  - name: Access tokens
    description: Access tokens
  - name: Account links
    description: Account links
  - name: Files
    description: Files
  - name: Ai chats
    description: Ai chats
  - name: Bounties
    description: Bounties
  - name: Stats
    description: Stats
  - name: Ad campaigns
    description: Ad campaigns
  - name: Ad groups
    description: Ad groups
  - name: Ads
    description: Ads
  - name: Conversions
    description: Conversions
paths:
  /forum_posts:
    post:
      tags:
        - Forum posts
      summary: Create forum post
      description: >-
        Create a new forum post or comment within an experience. Supports text
        content, attachments, polls, paywalling, and pinning. Pass experience_id
        'public' with a company_id to post to a company's public forum.


        Required permissions:
         - `forum:post:create`
      operationId: createForumPost
      parameters: []
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                company_id:
                  type:
                    - string
                    - 'null'
                  description: >-
                    The unique identifier of the company whose public forum to
                    post in. Required when experience_id is 'public'. For
                    example, 'biz_xxxxx'.
                  example: biz_xxxxxxxxxxxxxx
                experience_id:
                  type: string
                  description: >-
                    The unique identifier of the experience to create this post
                    in. For example, 'exp_xxxxx'. Pass 'public' along with
                    company_id to automatically use the company's public forum.
                  example: exp_xxxxxxxxxxxxxx
                content:
                  type:
                    - string
                    - 'null'
                  description: >-
                    The main body of the post in Markdown format. For example,
                    'Check out this **update**'. Hidden if the post is paywalled
                    and the viewer has not purchased access.
                rich_content:
                  type:
                    - string
                    - 'null'
                  description: >-
                    The rich content of the post in Tiptap JSON format. When
                    provided, takes priority over the markdown content field for
                    rendering.
                title:
                  type:
                    - string
                    - 'null'
                  description: >-
                    The title of the post, displayed prominently at the top.
                    Required for paywalled posts as it remains visible to
                    non-purchasers.
                attachments:
                  type:
                    - array
                    - 'null'
                  items:
                    type: object
                    properties:
                      id:
                        type: string
                        description: The ID of an existing file object.
                    required:
                      - id
                    description: Input for an attachment
                    title: FileInputWithId
                  description: >-
                    A list of file attachments to include with the post, such as
                    images or videos.
                poll:
                  type:
                    - object
                    - 'null'
                  properties:
                    options:
                      type: array
                      items:
                        type: object
                        properties:
                          id:
                            type: string
                            description: >-
                              Sequential ID for the poll option (starting from
                              '1')
                          text:
                            type: string
                            description: The text of the poll option
                        required:
                          - id
                          - text
                        description: Input type for a single poll option
                      description: >-
                        The options for the poll. Must have sequential IDs
                        starting from 1
                  required:
                    - options
                  description: >-
                    A poll to attach to this post, allowing members to vote on
                    options.
                parent_id:
                  type:
                    - string
                    - 'null'
                  description: >-
                    The unique identifier of the parent post to comment on. Omit
                    this field to create a top-level post.
                pinned:
                  type:
                    - boolean
                    - 'null'
                  description: Whether this post should be pinned to the top of the forum.
                paywall_amount:
                  type:
                    - number
                    - 'null'
                  description: >-
                    The price to unlock this post in the specified paywall
                    currency. For example, 5.00 for $5.00. When set, users must
                    purchase access to view the post content.
                  example: 6.9
                paywall_currency:
                  oneOf:
                    - $ref: '#/components/schemas/Currencies'
                    - type: 'null'
                  description: >-
                    The currency for the paywall price on this post. When set
                    along with paywall_amount, users must purchase access to
                    view the post content.
                is_mention:
                  type:
                    - boolean
                    - 'null'
                  description: >-
                    Whether to send this post as a mention notification to all
                    users in the experience who have mentions enabled.
                visibility:
                  oneOf:
                    - $ref: '#/components/schemas/ForumPostVisibilityTypes'
                    - type: 'null'
                  description: >-
                    Controls who can see this forum post, such as members only
                    or public.
              required:
                - experience_id
              description: Parameters for CreateForumPostV2
      responses:
        '200':
          description: A successful response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ForumPost'
        '400':
          description: Bad request
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: object
                    properties:
                      type:
                        type: string
                      message:
                        type: string
                      code:
                        type:
                          - string
                          - 'null'
                        description: >-
                          A short string indicating the specific error code,
                          e.g. 'parameter_missing', 'parameter_invalid',
                          'invalid_json'
                      param:
                        type:
                          - string
                          - 'null'
                        description: The parameter that caused the error, if applicable
                    required:
                      - type
                      - message
                required:
                  - error
              example:
                error:
                  type: invalid_request_error
                  code: parameter_missing
                  message: 'Missing required parameter: amount.'
                  param: amount
        '401':
          description: Unauthorized
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: object
                    properties:
                      type:
                        type: string
                      message:
                        type: string
                      code:
                        type:
                          - string
                          - 'null'
                        description: >-
                          A short string indicating the specific error code,
                          e.g. 'parameter_missing', 'parameter_invalid',
                          'invalid_json'
                      param:
                        type:
                          - string
                          - 'null'
                        description: The parameter that caused the error, if applicable
                    required:
                      - type
                      - message
                required:
                  - error
              example:
                error:
                  type: unauthorized
                  message: Invalid or missing API key
        '403':
          description: Forbidden
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: object
                    properties:
                      type:
                        type: string
                      message:
                        type: string
                      code:
                        type:
                          - string
                          - 'null'
                        description: >-
                          A short string indicating the specific error code,
                          e.g. 'parameter_missing', 'parameter_invalid',
                          'invalid_json'
                      param:
                        type:
                          - string
                          - 'null'
                        description: The parameter that caused the error, if applicable
                    required:
                      - type
                      - message
                required:
                  - error
              example:
                error:
                  type: forbidden
                  message: You do not have permission to access this resource
        '404':
          description: Not found
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: object
                    properties:
                      type:
                        type: string
                      message:
                        type: string
                      code:
                        type:
                          - string
                          - 'null'
                        description: >-
                          A short string indicating the specific error code,
                          e.g. 'parameter_missing', 'parameter_invalid',
                          'invalid_json'
                      param:
                        type:
                          - string
                          - 'null'
                        description: The parameter that caused the error, if applicable
                    required:
                      - type
                      - message
                required:
                  - error
              example:
                error:
                  type: not_found
                  message: Resource not found
        '422':
          description: Verification required
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: object
                    properties:
                      type:
                        type: string
                      message:
                        type: string
                      code:
                        type:
                          - string
                          - 'null'
                        description: >-
                          A short string indicating the specific error code,
                          e.g. 'parameter_missing', 'parameter_invalid',
                          'invalid_json'
                      param:
                        type:
                          - string
                          - 'null'
                        description: The parameter that caused the error, if applicable
                    required:
                      - type
                      - message
                required:
                  - error
              example:
                error: null
        '500':
          description: Internal server error
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: object
                    properties:
                      type:
                        type: string
                      message:
                        type: string
                      code:
                        type:
                          - string
                          - 'null'
                        description: >-
                          A short string indicating the specific error code,
                          e.g. 'parameter_missing', 'parameter_invalid',
                          'invalid_json'
                      param:
                        type:
                          - string
                          - 'null'
                        description: The parameter that caused the error, if applicable
                    required:
                      - type
                      - message
                required:
                  - error
              example:
                error:
                  type: internal_server_error
                  message: An unexpected error occurred
      security:
        - bearerAuth:
            - forum:post:create
      x-codeSamples:
        - lang: JavaScript
          source: >-
            import Whop from '@whop/sdk';


            const client = new Whop({
              apiKey: process.env['WHOP_API_KEY'], // This is the default and can be omitted
            });


            const forumPost = await client.forumPosts.create({ experience_id:
            'exp_xxxxxxxxxxxxxx' });


            console.log(forumPost.id);
        - lang: Python
          source: |-
            import os
            from whop_sdk import Whop

            client = Whop(
                api_key=os.environ.get("WHOP_API_KEY"),  # This is the default and can be omitted
            )
            forum_post = client.forum_posts.create(
                experience_id="exp_xxxxxxxxxxxxxx",
            )
            print(forum_post.id)
        - lang: Ruby
          source: >-
            require "whop_sdk"


            whop = WhopSDK::Client.new(api_key: "My API Key")


            forum_post = whop.forum_posts.create(experience_id:
            "exp_xxxxxxxxxxxxxx")


            puts(forum_post)
components:
  schemas:
    Currencies:
      type: string
      enum:
        - usd
        - sgd
        - inr
        - aud
        - brl
        - cad
        - dkk
        - eur
        - nok
        - gbp
        - sek
        - chf
        - hkd
        - huf
        - jpy
        - mxn
        - myr
        - pln
        - czk
        - nzd
        - aed
        - eth
        - ape
        - cop
        - ron
        - thb
        - bgn
        - idr
        - dop
        - php
        - try
        - krw
        - twd
        - vnd
        - pkr
        - clp
        - uyu
        - ars
        - zar
        - dzd
        - tnd
        - mad
        - kes
        - kwd
        - jod
        - all
        - xcd
        - amd
        - bsd
        - bhd
        - bob
        - bam
        - khr
        - crc
        - xof
        - egp
        - etb
        - gmd
        - ghs
        - gtq
        - gyd
        - ils
        - jmd
        - mop
        - mga
        - mur
        - mdl
        - mnt
        - nad
        - ngn
        - mkd
        - omr
        - pyg
        - pen
        - qar
        - rwf
        - sar
        - rsd
        - lkr
        - tzs
        - ttd
        - uzs
        - rub
        - btc
        - cny
        - usdt
        - kzt
      description: The available currencies on the platform
    ForumPostVisibilityTypes:
      type: string
      enum:
        - members_only
        - globally_visible
      description: The visibility types for forum posts
    ForumPost:
      type: object
      properties:
        id:
          type: string
          description: >-
            Represents a unique identifier that is Base64 obfuscated. It is
            often used to refetch an object or as key for a cache. The ID type
            appears in a JSON response as a String; however, it is not intended
            to be human-readable. When expected as an input type, any string
            (such as `"VXNlci0xMA=="`) or integer (such as `4`) input value will
            be accepted as an ID.
        title:
          type:
            - string
            - 'null'
          description: The headline of the forum post. Null if the post has no title.
          example: Weekly Market Analysis - February 2025
        content:
          type:
            - string
            - 'null'
          description: >-
            The body of the forum post in Markdown format. Null if the post is
            paywalled and the current user does not have access.
          example: |-
            ## My Strategy

            Here are the key steps...
        created_at:
          type: string
          format: date-time
          description: The time this post was created, as a Unix timestamp.
          example: '2023-12-01T05:00:00.401Z'
        updated_at:
          type: string
          format: date-time
          description: The time this post was last updated, as a Unix timestamp.
          example: '2023-12-01T05:00:00.401Z'
        is_edited:
          type: boolean
          description: Whether this post has been edited after its initial creation.
        is_poster_admin:
          type: boolean
          description: >-
            Whether the author of this post is an admin of the company that owns
            the forum.
        is_pinned:
          type: boolean
          description: Whether this post is pinned to the top of the forum feed.
        parent_id:
          type:
            - string
            - 'null'
          description: >-
            The unique identifier of the parent post. Null if this is a
            top-level post.
        user:
          type: object
          properties:
            id:
              type: string
              description: The unique identifier for the user.
              example: user_xxxxxxxxxxxxx
            username:
              type: string
              description: The user's unique username shown on their public profile.
              example: johndoe42
            name:
              type:
                - string
                - 'null'
              description: The user's display name shown on their public profile.
              example: John Doe
          required:
            - id
            - username
            - name
          description: The user who authored this forum post.
        attachments:
          type: array
          items:
            type: object
            properties:
              id:
                type: string
                description: >-
                  Represents a unique identifier that is Base64 obfuscated. It
                  is often used to refetch an object or as key for a cache. The
                  ID type appears in a JSON response as a String; however, it is
                  not intended to be human-readable. When expected as an input
                  type, any string (such as `"VXNlci0xMA=="`) or integer (such
                  as `4`) input value will be accepted as an ID.
              filename:
                type:
                  - string
                  - 'null'
                description: >-
                  The original filename of the uploaded attachment, including
                  its file extension.
                example: document.pdf
              content_type:
                type:
                  - string
                  - 'null'
                description: >-
                  The MIME type of the uploaded file (e.g., image/jpeg,
                  video/mp4, audio/mpeg).
                example: image/jpeg
              url:
                type:
                  - string
                  - 'null'
                description: >-
                  A pre-optimized URL for rendering this attachment on the
                  client. This should be used for displaying attachments in
                  apps.
                example: https://media.whop.com/abc123/optimized.jpg
            required:
              - id
              - filename
              - content_type
              - url
            description: Represents an image attachment
          description: >-
            All file attachments on this post, such as images, documents, and
            videos.
        view_count:
          type:
            - integer
            - 'null'
          description: The total number of times this post has been viewed by users.
          example: 42
        like_count:
          type:
            - integer
            - 'null'
          description: The total number of like reactions this post has received.
          example: 42
        comment_count:
          type: integer
          description: The total number of direct comments on this post.
          example: 42
      required:
        - id
        - title
        - content
        - created_at
        - updated_at
        - is_edited
        - is_poster_admin
        - is_pinned
        - parent_id
        - user
        - attachments
        - view_count
        - like_count
        - comment_count
      description: >-
        A post or comment in a forum feed, supporting rich text, attachments,
        polls, and reactions.
  securitySchemes:
    bearerAuth:
      type: http
      description: >-
        A company API key, company scoped JWT, app API key, or user OAuth token.
        You must prepend your key/token with the word 'Bearer', which will look
        like `Bearer ***************************`
      scheme: bearer
      bearerFormat: auth-scheme

````