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

# Create a workspace API key



## OpenAPI

````yaml /openapi.json post /api/v1/workspaces/{workspace}/api-keys
openapi: 3.0.3
info:
  title: ai-cmo.dev Services API
  version: 1.0.0
servers: []
security: []
paths:
  /api/v1/workspaces/{workspace}/api-keys:
    post:
      summary: Create a workspace API key
      operationId: createApiKey
      parameters:
        - name: workspace
          in: path
          required: true
          schema:
            type: string
            pattern: ^[a-z0-9-]+$
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/ApiKeyCreate'
      responses:
        '201':
          description: New API key secret
      security:
        - cookieAuth: []
components:
  schemas:
    ApiKeyCreate:
      type: object
      properties:
        name:
          type: string
          minLength: 1
          maxLength: 200
        scopes:
          type: array
          items:
            type: string
            enum:
              - workspace:read
              - settings:read
              - settings:write
              - connections:read
              - connections:write
              - connections:test
              - prompts:read
              - prompts:write
              - runs:read
              - runs:write
              - recs:read
              - recs:write
              - reports:read
              - metrics:read
              - chat:read
              - chat:write
              - credits:read
        allowedCidrs:
          type: array
          items:
            type: string
        idempotencyKey:
          type: string
      required:
        - name
      additionalProperties: false
  securitySchemes:
    cookieAuth:
      type: apiKey
      in: cookie
      name: geo.session
      description: Signed HttpOnly browser session cookie

````