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

# List Instructions

> Retrieves all watch instructions (monitoring rules). Each instruction contains the rule name, Watchscript source text, compiled DSL JSON, and metadata.



## OpenAPI

````yaml GET /instructions
openapi: 3.1.0
info:
  title: FinWatch API
  description: >-
    FinWatch REST API for real-time transaction monitoring, rule evaluation, and
    instruction management.
  version: 1.0.0
  contact:
    name: FinWatch Support
    url: https://docs.finwatch.finance
servers:
  - url: http://localhost:8081
    description: Local development server
security: []
tags:
  - name: Transactions
    description: >-
      Inject transactions for evaluation, retrieve transaction details, and
      handle webhook events.
  - name: Instructions
    description: >-
      Create, list, retrieve, and delete monitoring rules written in
      Watchscript.
  - name: Git
    description: Manage rules with Git for version control — status, pull, push, and clone.
paths:
  /instructions:
    get:
      tags:
        - Instructions
      summary: List Instructions
      description: >-
        Retrieves all watch instructions (monitoring rules). Each instruction
        contains the rule name, Watchscript source text, compiled DSL JSON, and
        metadata.
      operationId: listInstructions
      responses:
        '200':
          description: Instructions retrieved successfully
          content:
            application/json:
              schema:
                type: array
                items:
                  $ref: '#/components/schemas/Instruction'
              example:
                - id: 1
                  name: HighValueTransaction
                  text: |-
                    rule HighValueTransaction {
                        description "Review any transaction above $10,000"
                        when amount > 10000
                        then review
                             score   0.5
                             reason  "Amount exceeds threshold"
                    }
                  description: Review any transaction above $10,000
                  dsl_json: '{"name":"HighValueTransaction","when":[...],"then":{...}}'
                  created_at: '2024-01-15T10:00:00Z'
                  updated_at: '2024-01-15T10:00:00Z'
        '500':
          description: Failed to retrieve instructions
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
components:
  schemas:
    Instruction:
      type: object
      properties:
        id:
          type: integer
          description: Unique instruction identifier
        name:
          type: string
          description: Rule name (extracted from Watchscript)
        text:
          type: string
          description: The original Watchscript source text
        description:
          type: string
          description: Human-readable description (extracted from Watchscript)
        dsl_json:
          type: string
          description: Compiled DSL as JSON string (AST representation)
        created_at:
          type: string
          format: date-time
          description: Creation timestamp
        updated_at:
          type: string
          format: date-time
          description: Last update timestamp
    Error:
      type: object
      properties:
        error:
          type: string
          description: Error message
        code:
          type: string
          description: Error code

````