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

# Discover agent identity and granted or requestable integration APIs

> OAuth authorization or verified active run required. Availability reports connection state, without probing credential health. OAuth integration scopes are integration:{stable UUID}:{revocation epoch}; initial login need not request any integration scopes.

Accepts a scoped bearer token, vendor-verified run identity, or interactive owner session.



## OpenAPI

````yaml /openapi.yaml get /api/v1/agent/reflection
openapi: 3.1.0
info:
  title: Factorize API
  version: 1.0.0
  description: >-
    Versioned Factorize REST API. See the hosted docs for examples and OAuth
    discovery.
  x-dashboard-auth: >-
    Access-token and authorized-client management and trace replay operations
    require an interactive owner session; all other operations accept a suitably
    scoped bearer token or owner session.
servers:
  - url: https://app.factorize.sh
security:
  - bearerAuth: []
paths:
  /api/v1/agent/reflection:
    get:
      tags:
        - agent
      summary: Discover agent identity and granted or requestable integration APIs
      description: >-
        OAuth authorization or verified active run required. Availability
        reports connection state, without probing credential health. OAuth
        integration scopes are integration:{stable UUID}:{revocation epoch};
        initial login need not request any integration scopes.


        Accepts a scoped bearer token, vendor-verified run identity, or
        interactive owner session.
      operationId: get_api_v1_agent_reflection
      responses:
        '200':
          description: Agent reflection
          content:
            application/json:
              schema:
                type: object
                properties:
                  media:
                    type: object
                    properties:
                      frameworkVersion:
                        type: string
                        const: 1.5.2
                      contentTypes:
                        type: array
                        items:
                          type: string
                          enum:
                            - text
                            - image
                      maxUploadBytes:
                        type: integer
                        minimum: -9007199254740991
                        maximum: 9007199254740991
                      maxTurnMediaBytes:
                        type: integer
                        minimum: -9007199254740991
                        maximum: 9007199254740991
                      uploadUrl:
                        type: string
                        format: uri
                      fetchTool:
                        type: string
                        const: fetch_media
                      readTool:
                        type: string
                        const: read_media
                    required:
                      - frameworkVersion
                      - contentTypes
                      - maxUploadBytes
                      - maxTurnMediaBytes
                      - uploadUrl
                      - fetchTool
                      - readTool
                    additionalProperties: false
                  agentHost:
                    type: string
                    enum:
                      - factorize
                      - external
                      - vm
                  current_vm:
                    anyOf:
                      - type: object
                        properties:
                          provider:
                            type: string
                            enum:
                              - exe.dev
                              - fly.io
                          id:
                            type: string
                          runId:
                            type: string
                            format: uuid
                            pattern: >-
                              ^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$
                          status:
                            type: string
                            const: ready
                          cwd:
                            type: string
                          verifiedAt:
                            type: string
                          tool:
                            type: string
                            const: vm_exec
                        required:
                          - provider
                          - id
                          - runId
                          - status
                          - cwd
                          - verifiedAt
                          - tool
                        additionalProperties: false
                      - type: 'null'
                  identity:
                    type: object
                    properties:
                      id:
                        type: string
                        format: uuid
                        pattern: >-
                          ^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$
                      kind:
                        type: string
                        enum:
                          - oauth
                          - run
                    required:
                      - id
                      - kind
                    additionalProperties: false
                  scopes:
                    type: array
                    items:
                      type: string
                  proxy:
                    type: object
                    properties:
                      requestUrl:
                        type: string
                        format: uri
                      readResponseUrl:
                        type: string
                        format: uri
                      requestTool:
                        type: string
                        const: request_api
                      readResponseTool:
                        type: string
                        const: read_api_response
                      authentication:
                        type: string
                    required:
                      - requestUrl
                      - readResponseUrl
                      - requestTool
                      - readResponseTool
                      - authentication
                    additionalProperties: false
                  integrations:
                    type: array
                    items:
                      type: object
                      properties:
                        id:
                          type: string
                          format: uuid
                          pattern: >-
                            ^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$
                        credentialId:
                          type: string
                        name:
                          type: string
                        description:
                          type:
                            - string
                            - 'null'
                        kind:
                          type: string
                          enum:
                            - bearer
                            - github
                            - linear
                            - model
                            - fly
                            - exe
                            - amp
                            - clickup
                            - x
                        policy:
                          type: string
                          enum:
                            - baseline
                            - requestable
                            - disabled
                        available:
                          type: boolean
                        revision:
                          type: integer
                          minimum: -9007199254740991
                          maximum: 9007199254740991
                        requiredScope:
                          type: string
                        access:
                          type: string
                          enum:
                            - granted
                            - requestable
                            - unavailable
                        instructions:
                          type: string
                        requestExample:
                          type: object
                          properties:
                            integration:
                              type: string
                              format: uuid
                              pattern: >-
                                ^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$
                            method:
                              type: string
                              enum:
                                - GET
                                - POST
                            path:
                              type: string
                            headers:
                              type: object
                              propertyNames:
                                type: string
                              additionalProperties:
                                type: string
                            body:
                              type: string
                          required:
                            - integration
                            - method
                            - path
                          additionalProperties: false
                        vmGrantProvider:
                          type: string
                          enum:
                            - exe.dev
                            - fly.io
                      required:
                        - id
                        - credentialId
                        - name
                        - description
                        - kind
                        - policy
                        - available
                        - revision
                        - requiredScope
                        - access
                        - instructions
                        - requestExample
                      additionalProperties: false
                required:
                  - agentHost
                  - current_vm
                  - identity
                  - scopes
                  - proxy
                  - integrations
                additionalProperties: false
        '400':
          $ref: '#/components/responses/Error400'
        '401':
          $ref: '#/components/responses/Error401'
        '403':
          $ref: '#/components/responses/Error403'
        '404':
          $ref: '#/components/responses/Error404'
        '409':
          $ref: '#/components/responses/Error409'
        '429':
          $ref: '#/components/responses/Error429'
        '500':
          $ref: '#/components/responses/Error500'
        '503':
          $ref: '#/components/responses/Error503'
      security:
        - bearerAuth: []
        - vendorRunIdentity: []
          runIdentityHeader: []
        - cookieAuth: []
components:
  responses:
    Error400:
      description: Invalid request
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    Error401:
      description: Invalid or revoked credentials
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    Error403:
      description: Missing scope or required owner session
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    Error404:
      description: Resource not found
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    Error409:
      description: Operation conflict
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    Error429:
      description: Rate limit exceeded
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    Error500:
      description: Internal error
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    Error503:
      description: Service unavailable
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
  schemas:
    Error:
      type: object
      required:
        - error
      properties:
        error:
          type: object
          required:
            - code
            - message
          properties:
            code:
              type: string
            message:
              type: string
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      bearerFormat: OAuth2
    vendorRunIdentity:
      type: http
      scheme: bearer
      bearerFormat: JWT
      description: >-
        Fresh vendor-signed exe.dev WIF or Fly Machine OIDC token matching the
        provisioned active run. Must be combined with X-Factorize-Run-Id; a
        vendor token alone grants no access.
    runIdentityHeader:
      type: apiKey
      in: header
      name: X-Factorize-Run-Id
      description: >-
        Provisioned run UUID. Used only to locate the immutable vendor/VM
        binding; this header is not a credential. Scopes and tenant come from
        the server-side run snapshot.
    cookieAuth:
      type: apiKey
      in: cookie
      name: factorize_session

````

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