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

# List user namespaces

> Retrieve namespaces for a specific user. Use 'self' for the current user.



## OpenAPI

````yaml /api-reference/openapi.yml get /schema/{user}/namespaces
openapi: 3.0.3
info:
  title: DataLinks
  version: 2.2.3
servers:
  - url: https://api.datalinks.com/api/v1
    description: production server
security:
  - bearerAuth: []
  - openId:
      - implicit
paths:
  /schema/{user}/namespaces:
    get:
      tags:
        - schema
        - namespaces
      summary: List user namespaces
      description: >-
        Retrieve namespaces for a specific user. Use 'self' for the current
        user.
      operationId: listUserNamespaces
      parameters:
        - name: user
          in: path
          description: Username or 'self' for the current user.
          required: true
          schema:
            type: string
          example: self
      responses:
        '200':
          $ref: '#/components/responses/ListOfNamespaces'
        '401':
          $ref: '#/components/responses/Unauthorized'
        '404':
          description: The user was not found.
components:
  responses:
    ListOfNamespaces:
      description: Returns a list of namespaces accessible to the user.
      content:
        application/json:
          schema:
            type: array
            items:
              $ref: '#/components/schemas/ApiNamespace'
    Unauthorized:
      description: >-
        Unauthorized. This error occurs if the authentication token is missing
        or invalid.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
  schemas:
    ApiNamespace:
      required:
        - name
        - owner
      type: object
      properties:
        name:
          type: string
          description: The name of the namespace.
          example: cinematography
        owner:
          type: string
          description: Username of the namespace owner.
          example: datalinks
    ErrorResponse:
      required:
        - error_code
        - message
      type: object
      properties:
        error_code:
          type: string
          example: UNAUTHORIZED
        error_message:
          type: string
          example: ''
        message:
          type: string
          example: Missing authentication token
        sub_errors:
          type: array
          items:
            required:
              - code
              - message
            type: object
            properties:
              code:
                type: string
              message:
                type: string
  securitySchemes:
    bearerAuth:
      type: http
      description: >
        Use a Bearer token for authentication. Submit the token using the
        `Authorization`

        header: `Authorization: Bearer <token>`.
      scheme: bearer
    openId:
      type: oauth2
      flows:
        implicit:
          authorizationUrl: >-
            https://login.datalinks.com/realms/datalinks-realm/protocol/openid-connect/auth
          scopes:
            openid: openid

````