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

# Create member

> Add a user to the workspace with specified roles.



## OpenAPI

````yaml post /workspaces/members/{user_id}
openapi: 3.0.0
info:
  title: Mudstack API
  version: 2.41.0
servers:
  - url: https://api.mudstack.com
security: []
tags: []
paths:
  /workspaces/members/{user_id}:
    post:
      tags:
        - Workspace Member
      description: Add a user to the workspace with specified roles.
      parameters:
        - $ref: '#/components/parameters/account_id'
        - $ref: '#/components/parameters/workspace_id'
        - name: user_id
          in: path
          required: true
          schema:
            type: string
        - in: query
          name: roles
          required: true
          schema:
            type: array
            items:
              type: string
      responses:
        '200':
          description: User added to the workspace
      security:
        - Authentication: []
components:
  parameters:
    account_id:
      name: x-account-id
      in: header
      required: true
      schema:
        type: string
        format: uuid
    workspace_id:
      name: x-workspace-id
      in: header
      required: true
      schema:
        type: string
        format: uuid
  securitySchemes:
    Authentication:
      type: http
      scheme: bearer
      bearerFormat: JWT

````