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

# Create Session

> Create a new interview session.

This endpoint allows authenticated users to create a new interview session.
It requires an interview_config_id in the request body.
It returns a response containing the unique session ID.

phone_number is optional, but if provided, provide it in E.164 format (e.g. +12025550194)

You can construct a Session URL with the unique_session_id like so:
- Web: https://beta.techinterviewer.ai/?session={unique_session_id}
- Phone: https://beta.techinterviewer.ai/phone?session={unique_session_id} (only use if phone number is provided in the request body)

Raises 400 Bad Request if the interview_config_id is not provided.
Raises 404 Not Found if the interview config does not exist.



## OpenAPI

````yaml post /create_session
openapi: 3.1.0
info:
  title: Core Voice API
  summary: Core Voice API
  description: Core Voice API for Tech Interviewer
  version: 1.0.0
servers:
  - url: https://api.techinterviewer.ai
    description: Production server
  - url: http://localhost:8080
    description: Local development server
security: []
paths:
  /create_session:
    post:
      summary: Create Session
      description: >-
        Create a new interview session.


        This endpoint allows authenticated users to create a new interview
        session.

        It requires an interview_config_id in the request body.

        It returns a response containing the unique session ID.


        phone_number is optional, but if provided, provide it in E.164 format
        (e.g. +12025550194)


        You can construct a Session URL with the unique_session_id like so:

        - Web: https://beta.techinterviewer.ai/?session={unique_session_id}

        - Phone:
        https://beta.techinterviewer.ai/phone?session={unique_session_id} (only
        use if phone number is provided in the request body)


        Raises 400 Bad Request if the interview_config_id is not provided.

        Raises 404 Not Found if the interview config does not exist.
      operationId: create_session_create_session_post
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CreateSessionsRequestBody'
        required: true
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/CreateSessionsResponse'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
      security:
        - HTTPBasic: []
components:
  schemas:
    CreateSessionsRequestBody:
      properties:
        interview_config_id:
          type: string
          title: Interview Config Id
        first_name:
          type: string
          title: First Name
        last_name:
          type: string
          title: Last Name
        email:
          anyOf:
            - type: string
            - type: 'null'
          title: Email
        phone_number:
          anyOf:
            - type: string
            - type: 'null'
          title: Phone Number
        worker_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Worker Id
        shift_id:
          anyOf:
            - type: string
            - type: 'null'
          title: Shift Id
      type: object
      required:
        - interview_config_id
        - first_name
        - last_name
      title: CreateSessionsRequestBody
    CreateSessionsResponse:
      properties:
        unique_session_id:
          type: string
          title: Unique Session Id
      type: object
      required:
        - unique_session_id
      title: CreateSessionsResponse
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          type: array
          title: Location
        msg:
          type: string
          title: Message
        type:
          type: string
          title: Error Type
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError
  securitySchemes:
    HTTPBasic:
      type: http
      scheme: basic

````