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

# Create a post

> Create a feed post. <h3>OAuth</h3>Required scopes: <code>feed</code>



## OpenAPI

````yaml /assets/openapi.json post /feed/posts/v1
openapi: 3.0.2
info:
  title: Spacebring
  version: 1.0.0
  termsOfService: https://www.spacebring.com/terms
servers:
  - url: https://api.spacebring.com
security: []
paths:
  /feed/posts/v1:
    post:
      tags:
        - Feed
      summary: Create a post
      description: 'Create a feed post. <h3>OAuth</h3>Required scopes: <code>feed</code>'
      operationId: createFeedPost
      parameters:
        - in: header
          name: spacebring-network-id
          schema:
            type: string
            format: uuid
          required: false
          description: >-
            The id of the network. Required when using bearer token
            authentication
      requestBody:
        $ref: '#/components/requestBodies/createFeedPost'
      responses:
        '201':
          description: Created
          content:
            application/json:
              schema:
                type: object
                properties:
                  post:
                    $ref: '#/components/schemas/post'
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/responseError'
      security:
        - OAuth2:
            - feed
components:
  requestBodies:
    createFeedPost:
      content:
        application/json:
          schema:
            type: object
            properties:
              post:
                description: Feed post to create.
                type: object
                properties:
                  locationRef:
                    description: ID of the location where the post is created.
                    type: string
                    format: uuid
                  media:
                    description: Media files to attach to the post.
                    type: array
                    items:
                      type: object
                      properties:
                        key:
                          description: Storage key of the media file.
                          type: string
                      required:
                        - key
                  og:
                    description: Open Graph metadata for link previews.
                    type: object
                    properties:
                      description:
                        description: Open Graph description.
                        nullable: true
                        type: string
                      image:
                        description: Open Graph image URL.
                        nullable: true
                        type: string
                      title:
                        description: Open Graph title.
                        nullable: true
                        type: string
                      type:
                        description: Open Graph type.
                        nullable: true
                        type: string
                      url:
                        description: Open Graph URL.
                        type: string
                        format: uri
                      videoUrl:
                        description: Open Graph video URL.
                        nullable: true
                        type: string
                    required:
                      - url
                  text:
                    description: Post text content.
                    type: string
                required:
                  - locationRef
            required:
              - post
      required: true
  schemas:
    post:
      type: object
      properties:
        comments:
          description: Number of comments on the post.
          type: number
        createDate:
          description: ISO timestamp of when the post was created.
          type: string
          format: date-time
        id:
          description: Unique identifier of the post.
          type: string
          format: uuid
        liked:
          description: Whether the current user has liked the post.
          type: boolean
        likes:
          description: Number of likes on the post.
          type: number
        locale:
          description: Detected language locale of the post text.
          type: string
        locationRef:
          description: ID of the location this post belongs to.
          type: string
          format: uuid
        media:
          description: Media files attached to the post.
          type: array
          items:
            type: object
            properties:
              height:
                description: Image height in pixels.
                type: number
              id:
                description: Unique identifier of the media item.
                type: string
                format: uuid
              key:
                description: Storage key of the media file.
                type: string
              mime:
                description: MIME type of the media file.
                type: string
              url:
                description: Public URL of the media file.
                type: string
              width:
                description: Image width in pixels.
                type: number
            required:
              - height
              - id
              - key
              - mime
              - url
              - width
            additionalProperties: false
        membership:
          description: Membership of the post author.
          type: object
          properties:
            id:
              description: Unique identifier of the membership.
              type: string
              format: uuid
            user:
              description: User associated with the membership.
              type: object
              properties:
                about:
                  description: User bio.
                  nullable: true
                  type: string
                deleteDate:
                  description: ISO timestamp of when the user was deleted.
                  type: string
                  format: date-time
                email:
                  description: User email address.
                  nullable: true
                  type: string
                id:
                  description: Unique identifier of the user.
                  type: string
                  format: uuid
                name:
                  description: User first name.
                  nullable: true
                  type: string
                phoneNumber:
                  description: User phone number.
                  nullable: true
                  type: string
                photoUrl:
                  description: URL of the user's profile photo.
                  nullable: true
                  type: string
                surname:
                  description: User last name.
                  nullable: true
                  type: string
              required:
                - id
              additionalProperties: false
          required:
            - id
          additionalProperties: false
        membershipRef:
          description: ID of the membership that created the post.
          type: string
          format: uuid
        og:
          description: Open Graph metadata for link previews.
          type: object
          properties:
            description:
              description: Open Graph description.
              nullable: true
              type: string
            image:
              description: Open Graph image URL.
              nullable: true
              type: string
            title:
              description: Open Graph title.
              nullable: true
              type: string
            type:
              description: Open Graph type.
              nullable: true
              type: string
            url:
              description: Open Graph URL.
              type: string
            videoUrl:
              description: Open Graph video URL.
              nullable: true
              type: string
          required:
            - url
          additionalProperties: false
        pinned:
          description: Whether the post is pinned.
          type: boolean
        text:
          description: Post text content.
          type: string
        user:
          description: User who created the post.
          type: object
          properties:
            about:
              description: User bio.
              nullable: true
              type: string
            deleteDate:
              description: ISO timestamp of when the user was deleted.
              type: string
              format: date-time
            email:
              description: User email address.
              nullable: true
              type: string
            id:
              description: Unique identifier of the user.
              type: string
              format: uuid
            name:
              description: User first name.
              nullable: true
              type: string
            phoneNumber:
              description: User phone number.
              nullable: true
              type: string
            photoUrl:
              description: URL of the user's profile photo.
              nullable: true
              type: string
            surname:
              description: User last name.
              nullable: true
              type: string
          required:
            - id
          additionalProperties: false
      required:
        - comments
        - createDate
        - id
        - likes
        - locationRef
        - media
        - membership
        - membershipRef
        - pinned
      additionalProperties: false
    responseError:
      type: object
      properties:
        message:
          type: string
        type:
          type: string
  securitySchemes:
    OAuth2:
      type: oauth2
      description: >-
        See our [authentication
        documentation](https://www.spacebring.com/docs/api-reference/authentication#oauth2)
        for how to authorize your requests
      flows:
        authorizationCode:
          authorizationUrl: https://api.spacebring.com/oauth2/authorize
          tokenUrl: https://api.spacebring.com/oauth2/token
          refreshUrl: https://api.spacebring.com/oauth2/token
          scopes:
            benefits.readonly: Read benefits and applications
            benefits: Read and write benefits and applications
            community.readonly: Read community companies and memberships
            community: Read and write community companies and memberships
            events.readonly: Read events and tickets
            events: Read and write events and tickets
            feed.readonly: Read feed posts
            feed: Read and write feed posts
            invoices.readonly: Read invoices
            invoices: Read and write invoices
            locations.readonly: Read locations
            locations: Read and write locations
            plans.readonly: Read plans
            plans: Read and write plans
            resources.readonly: Read resources and bookings
            resources: Read and write resources and bookings
            subscriptions.readonly: Read subscriptions
            subscriptions: Read and write subscriptions
            shop.readonly: Read products and orders
            shop: Read and write products and orders
            support.readonly: Read support tickets
            support: Read and write support tickets
            transactions.readonly: Read transactions
            transactions: Read and write transactions
            visitors.readonly: Read visitors
            visitors: Read and write visitors

````