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

# List Devin Review trigger scopes

> List the account, namespace, and repository scopes an API key can attach Devin Review auto-review triggers to.

Lists the account, namespace, and repository scopes the caller can attach [Devin Review auto-review](https://docs.devinenterprise.com/work-with-devin/devin-review.md#auto-review) triggers to. Use a repository scope's `target` as `repository` when you [create a trigger](https://docs.devinenterprise.com/api-reference/v3/review-triggers/update-review-triggers.md).

## Permissions

Requires a [service user](https://docs.devinenterprise.com/api-reference/v3/service-users/members-service-users.md) or [personal access token](https://docs.devinenterprise.com/api-reference/personal-access-tokens.md) with the `ManageReview` permission in the organization. A personal access token acts as its user. Account-wide `ManageReview` lets the caller manage every scope; organization-level `ManageReview` covers only the repositories that organization can access.

## Behavior

* A namespace scope (`git_organization`) means every repository under it qualifies.
* `search` filters scopes by a case-insensitive substring of the target.
* `status` is `available` when the caller can attach triggers to the scope; any other value says why not, and `next_action` says what would fix it.
* Returns `404` when Review triggers are not enabled for the organization.


## OpenAPI

````yaml v3-openapi.yaml GET /v3beta1/organizations/{org_id}/review-settings/trigger-scopes
openapi: 3.1.0
info:
  description: Devin v3 API with Service User authentication and RBAC
  title: Devin API v3
  version: 3.0.0
servers: []
security:
  - bearerAuth: []
paths:
  /v3beta1/organizations/{org_id}/review-settings/trigger-scopes:
    get:
      tags:
        - review-settings
      summary: List scopes the caller can attach Review triggers to
      description: |-
        Account, namespace and repository scopes this caller may put triggers
        on. A namespace scope means every repository under it qualifies.
        Repository prefix scopes are not available over the API.
      operationId: >-
        handle_list_review_trigger_scopes_v3beta1_organizations__org_id__review_settings_trigger_scopes_get
      parameters:
        - description: 'Organization ID (prefix: org-)'
          in: path
          name: org_id
          required: true
          schema:
            example: org-abc123def456
            title: Org Id
            type: string
        - in: query
          name: after
          required: false
          schema:
            anyOf:
              - type: string
              - type: 'null'
            title: After
        - in: query
          name: first
          required: false
          schema:
            default: 100
            maximum: 200
            minimum: 1
            title: First
            type: integer
        - description: Substring filter.
          in: query
          name: search
          required: false
          schema:
            anyOf:
              - maxLength: 512
                type: string
              - type: 'null'
            description: Substring filter.
            title: Search
      responses:
        '200':
          content:
            application/json:
              schema:
                $ref: >-
                  #/components/schemas/PaginatedResponse_ReviewScopeCapabilityResponse_
          description: Successful Response
        '401':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ProblemDetail'
          description: Unauthorized
        '403':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ProblemDetail'
          description: Forbidden
        '404':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ProblemDetail'
          description: Not Found
        '409':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ProblemDetail'
          description: Conflict
        '410':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ProblemDetail'
          description: Gone
        '422':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ProblemDetail'
          description: Unprocessable Content
        '429':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ProblemDetail'
          description: Too Many Requests
components:
  schemas:
    PaginatedResponse_ReviewScopeCapabilityResponse_:
      properties:
        end_cursor:
          anyOf:
            - type: string
            - type: 'null'
          description: Cursor to fetch the next page, or None if this is the last page.
          title: End Cursor
        has_next_page:
          default: false
          description: Whether there are more items available after this page.
          title: Has Next Page
          type: boolean
        items:
          items:
            $ref: '#/components/schemas/ReviewScopeCapabilityResponse'
          title: Items
          type: array
        total:
          anyOf:
            - type: integer
            - type: 'null'
          description: Optional total count (can be omitted for performance).
          title: Total
      required:
        - items
      title: PaginatedResponse[ReviewScopeCapabilityResponse]
      type: object
    ProblemDetail:
      description: >-
        RFC 9457 application/problem+json error body for the v3 API.


        detail is retained from the legacy {"detail": ...} body for back-compat;
        the

        other members are additive. errors carries field-level validation
        failures

        (422 only).
      properties:
        detail:
          anyOf:
            - type: string
            - type: 'null'
          description: A human-readable explanation specific to this occurrence.
          title: Detail
        error_code:
          anyOf:
            - type: string
            - type: 'null'
          description: >-
            Machine-readable code for blocked-action refusals (e.g.
            "user_frozen", "migrated_session").
          title: Error Code
        errors:
          anyOf:
            - items:
                additionalProperties: true
                type: object
              type: array
            - type: 'null'
          description: Field-level validation errors (422 responses only).
          title: Errors
        instance:
          anyOf:
            - type: string
            - type: 'null'
          description: A URI reference (the request path) for this occurrence.
          title: Instance
        status:
          description: The HTTP status code.
          title: Status
          type: integer
        title:
          description: A short, human-readable summary of the problem type.
          title: Title
          type: string
        type:
          default: about:blank
          description: A URI reference identifying the problem type.
          title: Type
          type: string
      required:
        - title
        - status
      title: ProblemDetail
      type: object
    ReviewScopeCapabilityResponse:
      properties:
        next_action:
          enum:
            - none
            - relink
            - use_github_app
            - grant_app_access
            - request_scope_access
          title: Next Action
          type: string
        scope:
          $ref: '#/components/schemas/ReviewScopeResponse'
        status:
          description: >-
            'available' when the caller can attach triggers to the scope;
            otherwise why not.
          enum:
            - available
            - readonly
            - inaccessible
            - github_pat_unsupported
            - relink_required
            - unsupported
            - broader_grant_required
          title: Status
          type: string
      required:
        - scope
        - status
        - next_action
      title: ReviewScopeCapabilityResponse
      type: object
    ReviewScopeResponse:
      properties:
        kind:
          enum:
            - account
            - user
            - git_organization
            - git_repository
          title: Kind
          type: string
        target:
          anyOf:
            - type: string
            - type: 'null'
          description: >-
            git_repository: the repository name, 'owner/repo' on github.com and
            'host/path' on every other host
            ('gitlab.example.com/group/sub/repo'), percent-encoded per segment.
            git_organization: the namespace in the same form, ending in '/'.
            Null for account and user scopes.
          title: Target
        user_id:
          anyOf:
            - type: string
            - type: 'null'
          title: User Id
      required:
        - kind
        - target
      title: ReviewScopeResponse
      type: object
  securitySchemes:
    bearerAuth:
      description: 'Service User credential (prefix: cog_)'
      scheme: bearer
      type: http

````

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