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

# Import sessions

> Bulk-import sessions (contacts). The body must be `{ "sessions": [...] }`. Entries with a `userId` are
upserted onto the existing contact; entries without one create a new guest session. Returns the ids of
the imported sessions.



## OpenAPI

````yaml https://api.gleap.io/api-docs.json post /sessions/importer
openapi: 3.0.0
info:
  title: gleap-server
  version: 14.0.0
  contact: {}
servers:
  - url: https://api.gleap.io/v3
security: []
paths:
  /sessions/importer:
    post:
      tags:
        - Session
      summary: Import sessions
      description: >-
        Bulk-import sessions (contacts). The body must be `{ "sessions": [...]
        }`. Entries with a `userId` are

        upserted onto the existing contact; entries without one create a new
        guest session. Returns the ids of

        the imported sessions.
      operationId: ImportSession
      parameters:
        - in: header
          name: project
          required: true
          schema:
            type: string
      requestBody:
        required: true
        content:
          application/json:
            schema: {}
      responses:
        '200':
          description: Ok
          content:
            application/json:
              schema:
                items:
                  type: string
                type: array
      security:
        - jwt: []
components:
  securitySchemes:
    jwt:
      type: http
      scheme: bearer
      bearerFormat: JWT

````