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

# Initialize user session

> Creates a new session for a user with specified MCP servers



## OpenAPI

````yaml https://gist.githubusercontent.com/hillaryke/db4387d90d8a2367c8d3f478f2d48acc/raw/65b07bde29d5ff9b22522b3659db0b103c2d32e4/openapi.json post /sessions/{userId}
openapi: 3.0.0
info:
  title: MCP Hub API
  version: 1.0.0
  description: >-
    A service that manages isolated Model Context Protocol (MCP) server
    instances
servers:
  - url: http://localhost:3000
    description: Development server
security: []
tags: []
paths:
  /sessions/{userId}:
    post:
      tags:
        - Sessions
      summary: Initialize user session
      description: Creates a new session for a user with specified MCP servers
      parameters:
        - name: userId
          in: path
          required: true
          schema:
            type: string
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: 5832ae55-e40f-40a4-91d8-f4fefb2683ce
            example:
              serverConfigs:
                filesystem:
                  command: npx
                  args:
                    - '-y'
                    - '@modelcontextprotocol/server-filesystem'
                    - ./allowed_directory
      responses:
        '200':
          description: Session initialized successfully
          content:
            application/json:
              schema:
                $ref: 1f82be32-606f-4aa7-9ca6-ca1e0a444db0
              example:
                success: true
        '500':
          $ref: '#/components/responses/Error'
          content:
            application/json:
              example:
                error: 'Failed to initialize MCP server: server_name'
components:
  responses:
    Error:
      description: Error response
      content:
        application/json:
          schema:
            type: object
            properties:
              error:
                type: string

````