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

# Create a workspace

> Create a new workspace. Workspaces are collections of projects and tasks. Workspaces can be private or public. Private workspaces are only visible to members of the workspace.



## OpenAPI

````yaml post /teams/{team_slug}/workspaces
openapi: 3.0.3
info:
  title: Orgnise API
  description: >-
    Streamline your work with our all-in-one knowledge, doc, and project
    management system.
  version: 0.0.1
  contact:
    name: Orgnise Support
    email: orgnisehq@gmail.com
    url: http://docs.orgnise.in/api-reference/introduction
  license:
    name: AGPL-3.0 license
    url: https://github.com/Orgnise/webapp/blob/main/LICENSE.md
servers:
  - url: https://api.orgnise.in
    description: Production API
security: []
paths:
  /teams/{team_slug}/workspaces:
    post:
      tags:
        - workspaces
      summary: Create a workspace
      description: >-
        Create a new workspace. Workspaces are collections of projects and
        tasks. Workspaces can be private or public. Private workspaces are only
        visible to members of the workspace.
      operationId: createWorkspace
      parameters:
        - in: path
          name: team_slug
          description: The slug of the team.
          schema:
            type: string
            description: The slug of the team.
          required: true
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/createWorkspaceSchema'
      responses:
        '200':
          description: The created workspace
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WorkspaceSchema'
        '400':
          $ref: '#/components/responses/400'
        '401':
          $ref: '#/components/responses/401'
        '403':
          $ref: '#/components/responses/403'
        '404':
          $ref: '#/components/responses/404'
        '409':
          $ref: '#/components/responses/409'
        '410':
          $ref: '#/components/responses/410'
        '422':
          $ref: '#/components/responses/422'
        '429':
          $ref: '#/components/responses/429'
        '500':
          $ref: '#/components/responses/500'
      security:
        - token: []
components:
  schemas:
    createWorkspaceSchema:
      type: object
      properties:
        name:
          type: string
          minLength: 1
          maxLength: 32
          description: The name of the workspace.
        description:
          type: string
          maxLength: 120
          default: ''
          description: The description of the workspace.
        visibility:
          $ref: '#/components/schemas/visibility'
        defaultAccess:
          $ref: '#/components/schemas/defaultAccess'
      required:
        - name
      title: Create Workspace
      description: >-
        Create a new workspace. Workspaces are collections of projects and
        tasks. Workspaces can be private or public. Private workspaces are only
        visible to members of the workspace.
      example:
        name: Engineering Workspace
        description: A workspace for the engineering team.
        visibility: public
        defaultAccess: full
    WorkspaceSchema:
      type: object
      properties:
        _id:
          type: string
          description: The unique ID of the workspace.
        name:
          type: string
          description: The name of the workspace.
        description:
          type: string
          maxLength: 120
          default: ''
          description: The description of the workspace.
        defaultAccess:
          $ref: '#/components/schemas/defaultAccess'
        meta:
          type: object
          properties:
            title:
              type: string
              description: The title of the workspace.
            description:
              type: string
              description: The description of the workspace.
            slug:
              type: string
              description: The slug of the workspace.
          required:
            - title
            - description
            - slug
          description: The meta of the workspace.
        Visibility:
          $ref: '#/components/schemas/visibility'
        createdAt:
          type: string
          description: The date and time when the workspace was created.
        updatedAt:
          type: string
          description: The date and time when the workspace was last updated.
      required:
        - _id
        - name
        - description
        - defaultAccess
        - meta
        - Visibility
        - createdAt
        - updatedAt
      title: workspace
      description: >-
        A workspace is a collection of projects and tasks. Workspaces can be
        private or public. Private workspaces are only visible to members of the
        workspace.
    visibility:
      default: public
      description: >-
        The visibility of the workspace. Private workspaces are only visible to
        members of the workspace.
      example: public
    defaultAccess:
      type: string
      enum:
        - full
        - read-only
      default: full
      description: >-
        The default access level of the workspace. Full access allows members to
        perform all actions in the workspace. Read access allows members to view
        the workspace but not make changes.
      example: full
  responses:
    '400':
      description: >-
        The server cannot or will not process the request due to something that
        is perceived to be a client error (e.g., malformed request syntax,
        invalid request message framing, or deceptive request routing).
      content:
        application/json:
          schema:
            x-speakeasy-name-override: BadRequest
            type: object
            properties:
              error:
                type: object
                properties:
                  code:
                    type: string
                    enum:
                      - bad_request
                    description: A short code indicating the error code returned.
                    example: bad_request
                  message:
                    type: string
                    description: A human readable explanation of what went wrong.
                    example: The requested resource was not found.
                  doc_url:
                    type: string
                    description: >-
                      A link to our documentation with more details about this
                      error code
                    example: https://docs.orgnise.in/api-reference/errors#bad_request
                required:
                  - code
                  - message
            required:
              - error
    '401':
      description: >-
        Although the HTTP standard specifies "unauthorized", semantically this
        response means "unauthenticated". That is, the client must authenticate
        itself to get the requested response.
      content:
        application/json:
          schema:
            x-speakeasy-name-override: Unauthorized
            type: object
            properties:
              error:
                type: object
                properties:
                  code:
                    type: string
                    enum:
                      - unauthorized
                    description: A short code indicating the error code returned.
                    example: unauthorized
                  message:
                    type: string
                    description: A human readable explanation of what went wrong.
                    example: The requested resource was not found.
                  doc_url:
                    type: string
                    description: >-
                      A link to our documentation with more details about this
                      error code
                    example: https://docs.orgnise.in/api-reference/errors#unauthorized
                required:
                  - code
                  - message
            required:
              - error
    '403':
      description: >-
        The client does not have access rights to the content; that is, it is
        unauthorized, so the server is refusing to give the requested resource.
        Unlike 401 Unauthorized, the client's identity is known to the server.
      content:
        application/json:
          schema:
            x-speakeasy-name-override: Forbidden
            type: object
            properties:
              error:
                type: object
                properties:
                  code:
                    type: string
                    enum:
                      - forbidden
                    description: A short code indicating the error code returned.
                    example: forbidden
                  message:
                    type: string
                    description: A human readable explanation of what went wrong.
                    example: The requested resource was not found.
                  doc_url:
                    type: string
                    description: >-
                      A link to our documentation with more details about this
                      error code
                    example: https://docs.orgnise.in/api-reference/errors#forbidden
                required:
                  - code
                  - message
            required:
              - error
    '404':
      description: The server cannot find the requested resource.
      content:
        application/json:
          schema:
            x-speakeasy-name-override: NotFound
            type: object
            properties:
              error:
                type: object
                properties:
                  code:
                    type: string
                    enum:
                      - not_found
                    description: A short code indicating the error code returned.
                    example: not_found
                  message:
                    type: string
                    description: A human readable explanation of what went wrong.
                    example: The requested resource was not found.
                  doc_url:
                    type: string
                    description: >-
                      A link to our documentation with more details about this
                      error code
                    example: https://docs.orgnise.in/api-reference/errors#not_found
                required:
                  - code
                  - message
            required:
              - error
    '409':
      description: >-
        This response is sent when a request conflicts with the current state of
        the server.
      content:
        application/json:
          schema:
            x-speakeasy-name-override: Conflict
            type: object
            properties:
              error:
                type: object
                properties:
                  code:
                    type: string
                    enum:
                      - conflict
                    description: A short code indicating the error code returned.
                    example: conflict
                  message:
                    type: string
                    description: A human readable explanation of what went wrong.
                    example: The requested resource was not found.
                  doc_url:
                    type: string
                    description: >-
                      A link to our documentation with more details about this
                      error code
                    example: https://docs.orgnise.in/api-reference/errors#conflict
                required:
                  - code
                  - message
            required:
              - error
    '410':
      description: >-
        This response is sent when the requested content has been permanently
        deleted from server, with no forwarding address.
      content:
        application/json:
          schema:
            x-speakeasy-name-override: InviteExpired
            type: object
            properties:
              error:
                type: object
                properties:
                  code:
                    type: string
                    enum:
                      - invite_expired
                    description: A short code indicating the error code returned.
                    example: invite_expired
                  message:
                    type: string
                    description: A human readable explanation of what went wrong.
                    example: The requested resource was not found.
                  doc_url:
                    type: string
                    description: >-
                      A link to our documentation with more details about this
                      error code
                    example: >-
                      https://docs.orgnise.in/api-reference/errors#invite_expired
                required:
                  - code
                  - message
            required:
              - error
    '422':
      description: >-
        The request was well-formed but was unable to be followed due to
        semantic errors.
      content:
        application/json:
          schema:
            x-speakeasy-name-override: UnprocessableEntity
            type: object
            properties:
              error:
                type: object
                properties:
                  code:
                    type: string
                    enum:
                      - unprocessable_entity
                    description: A short code indicating the error code returned.
                    example: unprocessable_entity
                  message:
                    type: string
                    description: A human readable explanation of what went wrong.
                    example: The requested resource was not found.
                  doc_url:
                    type: string
                    description: >-
                      A link to our documentation with more details about this
                      error code
                    example: >-
                      https://docs.orgnise.in/api-reference/errors#unprocessable_entity
                required:
                  - code
                  - message
            required:
              - error
    '429':
      description: >-
        The user has sent too many requests in a given amount of time ("rate
        limiting")
      content:
        application/json:
          schema:
            x-speakeasy-name-override: RateLimitExceeded
            type: object
            properties:
              error:
                type: object
                properties:
                  code:
                    type: string
                    enum:
                      - rate_limit_exceeded
                    description: A short code indicating the error code returned.
                    example: rate_limit_exceeded
                  message:
                    type: string
                    description: A human readable explanation of what went wrong.
                    example: The requested resource was not found.
                  doc_url:
                    type: string
                    description: >-
                      A link to our documentation with more details about this
                      error code
                    example: >-
                      https://docs.orgnise.in/api-reference/errors#rate_limit_exceeded
                required:
                  - code
                  - message
            required:
              - error
    '500':
      description: The server has encountered a situation it does not know how to handle.
      content:
        application/json:
          schema:
            x-speakeasy-name-override: InternalServerError
            type: object
            properties:
              error:
                type: object
                properties:
                  code:
                    type: string
                    enum:
                      - internal_server_error
                    description: A short code indicating the error code returned.
                    example: internal_server_error
                  message:
                    type: string
                    description: A human readable explanation of what went wrong.
                    example: The requested resource was not found.
                  doc_url:
                    type: string
                    description: >-
                      A link to our documentation with more details about this
                      error code
                    example: >-
                      https://docs.orgnise.in/api-reference/errors#internal_server_error
                required:
                  - code
                  - message
            required:
              - error
  securitySchemes:
    token:
      type: http
      description: Default authentication mechanism
      scheme: bearer

````