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

# List agent app rules

> Connector rules the agent has authored for itself (which tools it may call on a connector, and when). Read only; rules are created by the agent, not through the API.



## OpenAPI

````yaml get /agents/{agent_id}/app-rules
openapi: 3.0.0
info:
  title: Public API
  version: 1.0.0
servers:
  - url: https://api.gumloop.com/api/v1
security: []
paths:
  /agents/{agent_id}/app-rules:
    get:
      tags:
        - Agents
      summary: List agent app rules
      description: >-
        Connector rules the agent has authored for itself (which tools it may
        call on a connector, and when). Read only; rules are created by the
        agent, not through the API.
      operationId: listAgentAppRules
      parameters:
        - in: path
          name: agent_id
          required: true
          schema:
            type: string
      responses:
        '200':
          description: The agent's rules.
          content:
            application/json:
              schema:
                type: object
                properties:
                  agent_id:
                    type: string
                  app_rules:
                    type: array
                    items:
                      $ref: '#/components/schemas/AgentAppRule'
        '401':
          description: Unauthorized — missing or invalid API key.
        '403':
          description: Forbidden — the caller cannot view app rules on this agent.
        '404':
          description: Agent not found.
      security:
        - bearerAuth: []
      x-codeSamples:
        - lang: bash
          label: cURL
          source: >
            curl
            'https://api.gumloop.com/api/v1/agents/abc123DEFghiJKL/app-rules' \
              -H 'Authorization: Bearer YOUR_ACCESS_TOKEN'
        - lang: python
          label: Python
          source: >
            from gumloop import Gumloop


            client = Gumloop(access_token="YOUR_ACCESS_TOKEN")


            for rule in
            client.agents.list_app_rules("abc123DEFghiJKL").app_rules:
                print(rule.server_id, rule.name)
components:
  schemas:
    AgentAppRule:
      type: object
      description: >-
        A connector rule the agent authored for itself. Read only through the
        API.
      properties:
        id:
          type: string
        name:
          type: string
          nullable: true
        description:
          type: string
          nullable: true
        status:
          type: string
          nullable: true
        server_id:
          type: string
          nullable: true
        config:
          type: object
        priority:
          type: integer
          nullable: true
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: >-
        A personal API key or an [OAuth 2.0](/api-reference/oauth) access token.
        Personal API keys also require the `x-auth-key` header with your user
        ID.

````