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

# Create bot

> Creates a bot in your account and returns its `id`.



## OpenAPI

````yaml POST /v1/bot
openapi: 3.1.0
info:
  title: WotNot API
  version: 1.0.0
  description: 'WotNot API: Create bot.'
servers:
  - url: https://api.wotnot.io
    description: Production
security:
  - bearerAuth: []
paths:
  /v1/bot:
    post:
      summary: Create bot
      description: Creates a bot in your account and returns its `id`.
      operationId: createBot
      requestBody:
        required: true
        description: The details of the new bot.
        content:
          application/json:
            schema:
              type: object
              required:
                - name
                - template_id
                - channel
              properties:
                name:
                  type: string
                  description: >-
                    The name for the new bot. In the example, `BOT_NAME` stands
                    in for the name you choose.
                  example: BOT_NAME
                template_id:
                  type: integer
                  description: >-
                    The ID of an existing bot to use as the reference for the
                    new one.
                  example: 10234
                channel:
                  type: string
                  description: The channel for the bot, for example `API`.
                  example: API
            example:
              name: BOT_NAME
              template_id: 10234
              channel: API
      responses:
        '200':
          description: Returns `ok` set to `true` and the new bot's `id`.
          content:
            application/json:
              schema:
                type: object
                required:
                  - ok
                  - id
                properties:
                  ok:
                    type: boolean
                    description: '`true` when the request worked. Errors return `false`.'
                    example: true
                  id:
                    type: integer
                    description: The new bot's ID.
                    example: 10587
              example:
                ok: true
                id: 10587
        '400':
          description: Your account has reached its maximum number of bots.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/CodedError'
              example:
                ok: false
                message: Maximum bots limit reached for the account.
                error: MAXIMUM_BOTS_LIMIT_REACHED
                code: MAXIMUM_BOTS_LIMIT_REACHED
components:
  schemas:
    CodedError:
      type: object
      description: An error with a short code that says what went wrong.
      required:
        - ok
        - message
        - error
        - code
      properties:
        ok:
          type: boolean
          description: Always `false` when something went wrong.
          example: false
        message:
          type: string
          description: What went wrong, in plain words.
          example: Please reach out to support to use this feature
        error:
          type: string
          description: >-
            A short error code in capital letters, for example
            `UNAUTHORIZED_FEATURE`. Check this in your code to tell errors
            apart.
          example: UNAUTHORIZED_FEATURE
        code:
          type: string
          description: A code for the result. In these examples it matches `error`.
          example: UNAUTHORIZED_FEATURE
        status:
          type: integer
          description: >-
            The HTTP status code, repeated in the body. Not every error includes
            it.
          example: 401
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: >-
        All of WotNot's APIs use Bearer token authentication. Send your account
        token as `Bearer <token>`. You can find it in Settings > Account
        Settings > Developer. Keep it on your server: anyone who has it can call
        the API as your account.

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.