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

# Create API Key

> Creates a new API key.



## OpenAPI

````yaml https://megastream25-api.closebot.com/swagger/v1/swagger.json post /account/apiKey
openapi: 3.0.1
info:
  title: CloseBot API
  version: v1
servers:
  - url: https://api.closebot.com
    description: CloseBot API Endpoint
security:
  - Key: []
paths:
  /account/apiKey:
    post:
      tags:
        - Account
      summary: Create API Key
      description: Creates a new API key.
      requestBody:
        description: Key name
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CreateApiKeyInput'
          text/json:
            schema:
              $ref: '#/components/schemas/CreateApiKeyInput'
          application/*+json:
            schema:
              $ref: '#/components/schemas/CreateApiKeyInput'
      responses:
        '200':
          description: Success
          content:
            text/plain:
              schema:
                $ref: '#/components/schemas/CreateApiKeyOutput'
            application/json:
              schema:
                $ref: '#/components/schemas/CreateApiKeyOutput'
            text/json:
              schema:
                $ref: '#/components/schemas/CreateApiKeyOutput'
components:
  schemas:
    CreateApiKeyInput:
      type: object
      properties:
        name:
          type: string
          nullable: true
      additionalProperties: false
    CreateApiKeyOutput:
      type: object
      properties:
        id:
          type: string
          nullable: true
        key:
          type: string
          nullable: true
        name:
          type: string
          nullable: true
        createdAt:
          type: string
          format: date-time
        expiresAt:
          type: string
          format: date-time
      additionalProperties: false
  securitySchemes:
    Key:
      type: apiKey
      description: CloseBot API Key Authorization
      name: X-CB-KEY
      in: header

````