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

# List all rules

> Returns a list of the rules your account has access to.
The rules are returned sorted by creation date, with the most recent rule appearing first.



## OpenAPI

````yaml api-reference/api.json get /2025-04/rules
openapi: 3.1.0
info:
  title: PullRule
  version: 0.0.1
servers:
  - url: https://pullrule.com/api
    description: Production
security:
  - http: []
tags:
  - name: Account
  - name: Members
  - name: Pull requests
  - name: Rules
  - name: Users
paths:
  /2025-04/rules:
    get:
      tags:
        - Rules
      summary: List all rules
      description: >-
        Returns a list of the rules your account has access to.

        The rules are returned sorted by creation date, with the most recent
        rule appearing first.
      operationId: v202504.rules.index
      responses:
        '200':
          description: Array of `Rule`
          content:
            application/json:
              schema:
                type: object
                properties:
                  data:
                    type: array
                    items:
                      $ref: '#/components/schemas/Rule'
                required:
                  - data
        '401':
          $ref: '#/components/responses/AuthenticationException'
components:
  schemas:
    Rule:
      type: object
      properties:
        id:
          type: string
          description: Unique identifier for the object.
        name:
          type: string
          description: The name of the rule.
        description:
          type:
            - string
            - 'null'
          description: The description of the rule.
        is_enabled:
          type: boolean
          description: Whether the rule is enabled or not.
        logic:
          type: array
          description: The logic of the rule.
          items:
            $ref: '#/components/schemas/RuleCondition'
        created_at:
          type: integer
          description: >-
            Time at which the object was created. Measured in seconds since the
            Unix epoch.
      required:
        - id
        - name
        - description
        - is_enabled
        - logic
        - created_at
      title: Rule
    RuleCondition:
      type: object
      properties:
        expression:
          type: string
          description: The expression of the rule condition.
        effect:
          type: object
          description: The effect that the rule has when the condition is met.
          properties:
            action:
              type: string
              description: The action that the rule will perform when the condition is met.
            value:
              type: string
              description: The value associated with the action.
          required:
            - action
            - value
      required:
        - expression
        - effect
      title: RuleCondition
  responses:
    AuthenticationException:
      description: Unauthenticated
      content:
        application/json:
          schema:
            type: object
            properties:
              message:
                type: string
                description: Error overview.
            required:
              - message
  securitySchemes:
    http:
      type: http
      scheme: bearer

````