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

# Create a world in a namespace



## OpenAPI

````yaml /openapi.yaml post /namespaces/{namespace}/worlds
openapi: 3.0.0
info:
  title: Worlds API
  version: 1.0.0
  description: >
    API for managing and querying RDF-based worlds.


    **Namespaces:** Routes under `/namespaces/{namespace}/...` target a specific
    tenant namespace.

    The path segment `_` is reserved: it expands to the authenticated tenant
    default namespace

    (or the platform namespace when no tenant applies). Shorthand routes under
    `/worlds/...`

    use the default namespace and omit the `/namespaces/...` prefix.
servers:
  - url: https://api.wazoo.dev
    description: API
security:
  - bearerAuth: []
paths:
  /namespaces/{namespace}/worlds:
    parameters:
      - name: namespace
        in: path
        required: true
        schema:
          type: string
        description: Target namespace, or `_` for the caller default namespace.
    post:
      summary: Create a world in a namespace
      operationId: createWorldNamespaced
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/CreateWorldParams'
      responses:
        '201':
          description: Created
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/World'
        '400':
          $ref: '#/components/responses/BadRequest'
        '403':
          $ref: '#/components/responses/Forbidden'
        '409':
          description: Conflict
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
components:
  schemas:
    CreateWorldParams:
      type: object
      properties:
        slug:
          type: string
        namespace:
          type: string
          description: >-
            Optional in body; the path namespace wins for `/namespaces/...`
            routes. The reserved `_` value is rejected here.
        label:
          type: string
        description:
          type: string
          nullable: true
      required:
        - slug
    World:
      type: object
      properties:
        slug:
          type: string
        namespace:
          type: string
          description: Parent namespace for this world in multitenancy contexts.
        label:
          type: string
        description:
          type: string
          nullable: true
        createdAt:
          type: number
        updatedAt:
          type: number
        deletedAt:
          type: number
          nullable: true
      required:
        - slug
        - createdAt
        - updatedAt
    Error:
      type: object
      properties:
        error:
          type: object
          properties:
            message:
              type: string
      required:
        - error
  responses:
    BadRequest:
      description: Bad Request
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    Forbidden:
      description: Forbidden
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer

````