> ## Documentation Index
> Fetch the complete documentation index at: https://codegeninc-codegen-bot-add-docker-hub-docs-1749227313.mintlify.site/llms.txt
> Use this file to discover all available pages before exploring further.

# Get Agent Run

> Retrieve the status and result of an agent run.

Returns the current status, progress, and any available results for the specified agent run.
The agent run must belong to the specified organization. If the agent run is still in progress,
this endpoint can be polled to check for completion.

Rate limit: 60 requests per 30 seconds.



## OpenAPI

````yaml api-reference/openapi3.json get /v1/organizations/{org_id}/agent/run/{agent_run_id}
openapi: 3.1.0
info:
  title: Developer API
  description: API for application developers
  version: 1.0.0
servers:
  - url: https://api.codegen.com
    description: Codegen API
security: []
paths:
  /v1/organizations/{org_id}/agent/run/{agent_run_id}:
    get:
      tags:
        - agents
        - agents
        - agents
      summary: Get Agent Run
      description: >-
        Retrieve the status and result of an agent run.


        Returns the current status, progress, and any available results for the
        specified agent run.

        The agent run must belong to the specified organization. If the agent
        run is still in progress,

        this endpoint can be polled to check for completion.


        Rate limit: 60 requests per 30 seconds.
      operationId: get_agent_run_v1_organizations__org_id__agent_run__agent_run_id__get
      parameters:
        - name: agent_run_id
          in: path
          required: true
          schema:
            type: integer
            title: Agent Run Id
        - name: org_id
          in: path
          required: true
          schema:
            type: integer
            title: Org Id
        - name: authorization
          in: header
          required: false
          schema:
            title: Authorization
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/AgentRunResponse'
        '403':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PermissionsErrorResponse'
          description: Forbidden
        '404':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/AgentRunNotFoundErrorResponse'
          description: Not Found
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
        '429':
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/APIRateLimitErrorResponse'
          description: Too Many Requests
components:
  schemas:
    AgentRunResponse:
      properties:
        id:
          type: integer
          title: Id
        organization_id:
          type: integer
          title: Organization Id
        status:
          anyOf:
            - type: string
            - type: 'null'
          title: Status
        created_at:
          anyOf:
            - type: string
            - type: 'null'
          title: Created At
        web_url:
          anyOf:
            - type: string
            - type: 'null'
          title: Web Url
        result:
          anyOf:
            - type: string
            - type: 'null'
          title: Result
      type: object
      required:
        - id
        - organization_id
      title: AgentRunResponse
      description: Represents an agent run in API responses
    PermissionsErrorResponse:
      properties:
        message:
          type: string
          title: Message
          default: You do not have access to this organization.
        status_code:
          type: integer
          title: Status Code
          default: 403
      type: object
      title: PermissionsErrorResponse
    AgentRunNotFoundErrorResponse:
      properties:
        message:
          type: string
          title: Message
          default: Agent run not found.
        status_code:
          type: integer
          title: Status Code
          default: 404
      type: object
      title: AgentRunNotFoundErrorResponse
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    APIRateLimitErrorResponse:
      properties:
        message:
          type: string
          title: Message
          default: Rate limit exceeded. Please try again later.
        status_code:
          type: integer
          title: Status Code
          default: 429
      type: object
      title: APIRateLimitErrorResponse
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          type: array
          title: Location
        msg:
          type: string
          title: Message
        type:
          type: string
          title: Error Type
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError

````