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

# Create a Label

> Create a project-owned label.



## OpenAPI

````yaml post /v1/labels
openapi: 3.0.0
info:
  title: Browserbase API
  description: Browserbase API for 3rd party developers
  version: v1
servers:
  - url: https://api.browserbase.com
    description: Public endpoint
    variables: {}
security:
  - BrowserbaseAuth: []
tags: []
paths:
  /v1/labels:
    post:
      summary: Create a Label
      description: Create a project-owned label.
      operationId: Labels_create
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              properties:
                name:
                  description: >-
                    Label name. Browserbase trims surrounding Unicode whitespace
                    and preserves display capitalization. The trimmed name must
                    contain 1–128 Unicode characters and no NUL characters.
                    Names are unique ignoring case within the project.
                  type: string
              additionalProperties: false
              required:
                - name
      responses:
        '201':
          description: The created label.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Label'
        '400':
          description: Invalid request parameters or label name.
          content:
            application/json:
              schema:
                type: object
                properties:
                  statusCode:
                    description: HTTP status code.
                    type: integer
                  error:
                    description: HTTP error name.
                    type: string
                  message:
                    description: Human-readable error message.
                    type: string
                required:
                  - statusCode
                  - error
                  - message
        '409':
          description: >-
            A label with this name already exists in the project
            (case-insensitive).
          content:
            application/json:
              schema:
                type: object
                properties:
                  statusCode:
                    description: HTTP status code.
                    type: integer
                  error:
                    description: HTTP error name.
                    type: string
                  message:
                    description: Human-readable error message.
                    type: string
                required:
                  - statusCode
                  - error
                  - message
        '422':
          description: Creating this label would exceed the project's label allowance.
          content:
            application/json:
              schema:
                type: object
                properties:
                  statusCode:
                    description: HTTP status code.
                    type: integer
                  error:
                    description: HTTP error name.
                    type: string
                  message:
                    description: Human-readable error message.
                    type: string
                required:
                  - statusCode
                  - error
                  - message
        '429':
          description: Your requests exceed the API rate limit.
          content:
            application/json:
              schema:
                type: object
                properties:
                  statusCode:
                    description: HTTP status code.
                    type: integer
                  error:
                    description: HTTP error name.
                    type: string
                  message:
                    description: Human-readable error message.
                    type: string
                required:
                  - statusCode
                  - error
                  - message
components:
  schemas:
    Label:
      description: A project-owned session label.
      type: object
      properties:
        id:
          description: Stable identifier of the label.
          type: string
          format: uuid
        projectId:
          description: The project that owns the label.
          type: string
          format: uuid
        name:
          description: Display name, unique ignoring case within the project.
          type: string
        createdAt:
          description: UTC timestamp when the label was created.
          type: string
          format: date-time
        updatedAt:
          description: UTC timestamp when the label was last renamed.
          type: string
          format: date-time
      required:
        - id
        - projectId
        - name
        - createdAt
        - updatedAt
  securitySchemes:
    BrowserbaseAuth:
      type: apiKey
      in: header
      name: X-BB-API-Key
      description: Your [Browserbase API Key](https://www.browserbase.com/settings).

````

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