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

# Retrieve workspace scopes



## OpenAPI

````yaml get /api/v1/workspace/{id}/scopes
openapi: 3.0.0
info:
  title: Oneloop API
  version: 1.0.0
  description: API Key Management
servers:
  - url: https://prod.oneloop.ai
    description: Production server
security:
  - bearerAuth: []
paths:
  /api/v1/workspace/{id}/scopes:
    get:
      summary: Retrieve workspace scopes
      operationId: getWorkspaceScopes
      parameters:
        - schema:
            type: string
            description: The workspace id.
          required: true
          name: id
          in: path
      responses:
        '200':
          description: Workspace scopes
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/RetrieveAllWorkspaceScopesResponse'
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '401':
          description: Unauthorized
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '403':
          description: Forbidden
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
      security:
        - bearerAuth: []
components:
  schemas:
    RetrieveAllWorkspaceScopesResponse:
      type: object
      properties:
        scopes:
          type: array
          items:
            $ref: '#/components/schemas/WorkspaceScope'
      required:
        - scopes
    ErrorResponse:
      type: object
      properties:
        error:
          type: object
          properties:
            code:
              type: number
              minimum: 0
              exclusiveMinimum: true
            message:
              type: string
          required:
            - code
            - message
      required:
        - error
    WorkspaceScope:
      type: object
      properties:
        id:
          type: string
        name:
          type: string
        representation:
          type: string
        description:
          type: string
          nullable: true
        createdAt:
          type: string
        updatedAt:
          type: string
      required:
        - id
        - name
        - representation
        - description
        - createdAt
        - updatedAt
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer

````