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

# Inspect an immutable Library revision



## OpenAPI

````yaml https://raw.githubusercontent.com/agentsfleet/agentsfleet/main/public/openapi.json get /v1/workspaces/{workspace_id}/fleet-libraries/{library_id}/revisions/{revision_id}
openapi: 3.1.0
info:
  title: agentsfleet Control Plane API
  description: API for managing workspaces, fleets, triggers, and runs.
  contact:
    name: agentsfleet
    url: https://agentsfleet.net
  license:
    name: MIT
    identifier: MIT
  version: 1.0.0
servers:
  - url: https://api.agentsfleet.net
    description: Production
security: []
paths:
  /v1/workspaces/{workspace_id}/fleet-libraries/{library_id}/revisions/{revision_id}:
    get:
      tags:
        - Fleet library
      summary: Inspect an immutable Library revision
      operationId: read_library_revision
      parameters:
        - name: workspace_id
          in: path
          description: '`UUIDv7` of the workspace.'
          required: true
          schema:
            type: string
        - name: library_id
          in: path
          description: 'Opaque Library identifier: a platform slug or an owned `UUIDv7`.'
          required: true
          schema:
            type: string
        - name: revision_id
          in: path
          description: '`UUIDv7` of the revision.'
          required: true
          schema:
            type: string
      responses:
        '200':
          description: Immutable content and live readiness
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/RevisionRead'
        '400':
          description: The request could not be read
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/ProblemBody'
        '401':
          description: No credential, or one this route does not accept
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/ProblemBody'
        '403':
          description: The credential is good and lacks the capability this route requires
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/ProblemBody'
        '404':
          description: Library or revision unavailable
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/ProblemBody'
        '429':
          description: The instance is at its ceiling
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/ProblemBody'
        '500':
          description: The daemon failed to answer
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/ProblemBody'
        '503':
          description: A dependency this route needs is unreachable
          content:
            application/problem+json:
              schema:
                $ref: '#/components/schemas/ProblemBody'
      security:
        - BearerAuth: []
components:
  schemas:
    RevisionRead:
      type: object
      description: Immutable revision with live contextual readiness.
      required:
        - revision
        - review
      properties:
        review:
          type: object
          description: Current owner/workspace readiness.
        revision:
          $ref: '#/components/schemas/Revision_Value_Value'
          description: Immutable reusable content.
    ProblemBody:
      type: object
      description: The body every refusal carries, under `application/problem+json`.
      required:
        - docs_uri
        - title
        - detail
        - error_code
        - request_id
      properties:
        action_id:
          type:
            - string
            - 'null'
          description: 'On that 409 only: the action the gate held.'
        current_state:
          type:
            - string
            - 'null'
          description: 'On a 409 only: the state that forbade the transition.'
        detail:
          type: string
          description: One sentence on what was refused and why.
        docs_uri:
          type: string
          description: Where the error code is documented.
        error_code:
          type: string
          description: The registry code, stable across releases.
        etag:
          type:
            - string
            - 'null'
          description: >-
            On a 412 only: the resource's current entity tag, to refetch and
            retry.
        gate_id:
          type:
            - string
            - 'null'
          description: 'On an answered approval gate''s 409 only: the gate that was answered.'
        outcome:
          type:
            - string
            - 'null'
          description: 'On that 409 only: the answer that stands.'
        request_id:
          type: string
          description: The request this refusal answers, for support.
        resolved_at:
          type:
            - integer
            - 'null'
          format: int64
          description: 'On that 409 only: when the standing answer was given.'
        resolved_by:
          type:
            - string
            - 'null'
          description: 'On that 409 only: who gave it.'
        title:
          type: string
          description: A short name for the refusal, safe to show a person.
        user_message:
          type:
            - string
            - 'null'
          description: A curated sentence for end users, where the code has one.
    Revision_Value_Value:
      type: object
      description: Immutable reusable setup selected by its revision identifier.
      required:
        - id
        - library_id
        - revision
        - definition
        - canonical_digest
        - requirements
        - policy_semantics
        - created_at
      properties:
        canonical_digest:
          type: string
          description: Canonical content identity.
        created_at:
          type: integer
          format: int64
          description: UTC milliseconds.
        definition:
          $ref: '#/components/schemas/FleetDefinition'
          description: Validated native setup.
        id:
          type: string
          description: Revision `UUIDv7`.
        library_id:
          type: string
          description: Entry `UUIDv7`.
        policy_semantics:
          type: string
          description: Pinned policy meaning.
        requirements:
          type: object
          description: Immutable declarative needs.
        revision:
          type: string
          description: Decimal entry-local revision.
    FleetDefinition:
      type: object
      description: >-
        A complete native fleet setup: its description, instructions and
        configuration.
      required:
        - schema_version
        - description
        - instructions_md
        - config
      properties:
        config:
          $ref: '#/components/schemas/DefinitionConfig'
          description: The fleet's configuration.
        description:
          type: string
          description: >-
            Says what the fleet does, shown wherever it is listed. At most
            32,768

            characters.
          maxLength: 32768
          minLength: 1
        instructions_md:
          type: string
          description: The fleet's instructions, in Markdown, at most 32,768 characters.
          maxLength: 32768
        schema_version:
          type: integer
          format: int32
          description: The Definition format version. Only `1` is accepted.
          maximum: 1
          minimum: 1
      additionalProperties: false
    DefinitionConfig:
      type: object
      description: >-
        The `config` member of a Definition: the fleet's name and its runtime
        settings.
      required:
        - name
        - x-agentsfleet
      properties:
        name:
          type: string
          description: The fleet's name.
          maxLength: 64
          minLength: 1
        x-agentsfleet:
          $ref: '#/components/schemas/DefinitionRuntime'
          description: >-
            Every runtime setting: triggers, tools, credentials, network, budget
            and gates.
      additionalProperties: false
    DefinitionRuntime:
      type: object
      description: The `x-agentsfleet` block, which holds every runtime setting.
      required:
        - tools
        - budget
      properties:
        budget:
          $ref: '#/components/schemas/DefinitionBudget'
          description: The most this fleet may spend.
        context:
          oneOf:
            - type: 'null'
            - $ref: '#/components/schemas/DefinitionContext'
              description: Context-size settings for each run.
        credentials:
          type:
            - array
            - 'null'
          items:
            type: string
            maxLength: 128
            minLength: 1
          description: The workspace secrets this fleet may read, by name.
          maxItems: 64
        gates:
          oneOf:
            - type: 'null'
            - $ref: '#/components/schemas/DefinitionGates'
              description: >-
                Which tool actions need a person's approval, and which repeated
                actions stop a run.
        model:
          type:
            - string
            - 'null'
          description: The model this fleet runs on, passed to the runner unchanged.
          maxLength: 255
        network:
          oneOf:
            - type: 'null'
            - $ref: '#/components/schemas/DefinitionNetwork'
              description: The hosts this fleet may reach.
        repositories:
          type:
            - array
            - 'null'
          items:
            type: string
            maxLength: 255
            minLength: 1
          description: >-
            The repositories this fleet's GitHub credentials may reach, as
            `owner/name`.

            Set together with `repository_access`.
          maxItems: 64
          minItems: 1
        repository_access:
          oneOf:
            - type: 'null'
            - $ref: '#/components/schemas/DefinitionRepositoryAccess'
              description: >-
                How far those credentials reach. Set together with
                `repositories`.
        repository_base:
          type:
            - string
            - 'null'
          description: >-
            The branch every pull request opens against. Required with `write`,
            refused with `read`.
          maxLength: 255
          minLength: 1
        tools:
          type: array
          items:
            type: string
            maxLength: 128
            minLength: 1
          description: >-
            The tools this fleet may call. An empty list means the fleet only
            answers.
          maxItems: 128
        triggers:
          type: array
          items:
            $ref: '#/components/schemas/DefinitionTrigger'
          description: >-
            What may start a run of this fleet besides a message sent to it.
            Omit

            it, or leave it empty, for a fleet that is only ever talked to.
          maxItems: 8
      additionalProperties: false
    DefinitionBudget:
      type: object
      description: Spending limits, each a decimal string of whole nanos.
      required:
        - daily_nanos
      properties:
        daily_nanos:
          type: string
          description: 'The daily limit: a decimal string of whole nanos, greater than zero.'
          maxLength: 19
          minLength: 1
          pattern: ^[0-9]+$
        monthly_nanos:
          type: string
          description: >-
            The monthly limit, in the same form. Omit it to set no monthly
            limit.
          maxLength: 19
          minLength: 1
          pattern: ^[0-9]+$
      additionalProperties: false
    DefinitionContext:
      type: object
      description: Context-size settings for each run.
      properties:
        context_cap_tokens:
          oneOf:
            - type: 'null'
            - $ref: '#/components/schemas/DefinitionContextSetting'
              description: The most tokens a run's assembled context may hold.
        memory_checkpoint_every:
          oneOf:
            - type: 'null'
            - $ref: '#/components/schemas/DefinitionContextSetting'
              description: How often a run saves its memory.
        stage_chunk_threshold:
          type:
            - number
            - 'null'
          format: double
          description: >-
            The fraction of the context, from 0 to 1, at which a stage splits
            into chunks.

            Zero means the runner chooses.
          maximum: 1
          minimum: 0
        tool_window:
          oneOf:
            - type: 'null'
            - $ref: '#/components/schemas/DefinitionContextSetting'
              description: How much of the context tool output may fill.
      additionalProperties: false
    DefinitionGates:
      type: object
      description: Approval and anomaly rules for a fleet's tool actions.
      properties:
        anomaly_rules:
          type:
            - array
            - 'null'
          items:
            $ref: '#/components/schemas/DefinitionAnomalyRule'
          description: The repeated-action patterns that stop a run.
        rules:
          type:
            - array
            - 'null'
          items:
            $ref: '#/components/schemas/DefinitionGateRule'
          description: The tool actions that need a person's approval.
        timeout_ms:
          type:
            - integer
            - 'null'
          format: int64
          description: |-
            How long, in milliseconds, an approval may wait before it lapses.
            An out-of-range value is clamped to the nearest allowed one.
      additionalProperties: false
    DefinitionNetwork:
      type: object
      description: Where a fleet may reach on the network.
      properties:
        allow:
          type:
            - array
            - 'null'
          items:
            type: string
            maxLength: 255
            minLength: 1
          description: >-
            The hosts the fleet may reach. An empty list blocks every outbound
            request.
          maxItems: 64
        read_only:
          type:
            - boolean
            - 'null'
          description: Whether outbound requests are limited to reads.
        read_post_paths:
          type:
            - array
            - 'null'
          items:
            type: string
            maxLength: 255
            minLength: 1
          description: >-
            The request paths that may still send `POST` when `read_only` is
            true.
          maxItems: 64
      additionalProperties: false
    DefinitionRepositoryAccess:
      type: string
      description: How far a fleet's repository credentials reach.
      enum:
        - read
        - write
    DefinitionTrigger:
      oneOf:
        - type: object
          description: Starts on a signed delivery from an external provider.
          required:
            - source
            - type
          properties:
            credential_name:
              type:
                - string
                - 'null'
              description: >-
                A secret name to use instead of the provider's default, so two
                fleets

                on one provider can hold different secrets.
              maxLength: 128
              minLength: 1
            events:
              type:
                - array
                - 'null'
              items:
                type: string
                maxLength: 64
                minLength: 1
              description: The event names that start a run. Omit it to accept every event.
              maxItems: 16
              minItems: 1
            repositories:
              type:
                - array
                - 'null'
              items:
                type: string
                maxLength: 255
                minLength: 1
              description: >-
                The repositories whose deliveries may start a run, as
                `owner/name`.
              maxItems: 64
              minItems: 1
            signature:
              oneOf:
                - type: 'null'
                - $ref: '#/components/schemas/DefinitionWebhookSignature'
                  description: How the delivery proves it came from the provider.
            source:
              type: string
              description: >-
                The provider that sends the delivery, as a lowercase slug: it is
                the

                last segment of the URL the fleet's deliveries are sent to.
              maxLength: 255
              minLength: 1
            type:
              type: string
              enum:
                - webhook
        - type: object
          description: Starts on a schedule.
          required:
            - schedule
            - type
          properties:
            message:
              type:
                - string
                - 'null'
              description: The message each scheduled run receives.
              maxLength: 255
            schedule:
              type: string
              description: The schedule, as a cron expression.
              maxLength: 255
              minLength: 1
            timezone:
              type:
                - string
                - 'null'
              description: The time zone the schedule is read in.
              maxLength: 255
              minLength: 1
            type:
              type: string
              enum:
                - cron
        - type: object
          description: Starts when someone mentions the bot in one chat channel.
          required:
            - source
            - channels
            - type
          properties:
            channels:
              type: array
              items:
                type: string
                maxLength: 32
                minLength: 9
              description: The channel identifier, as a list with exactly one entry.
              maxItems: 1
              minItems: 1
            source:
              type: string
              description: The chat provider.
              maxLength: 255
              minLength: 1
            type:
              type: string
              enum:
                - mention
      description: One way a fleet can start a run. `type` selects the kind.
    DefinitionContextSetting:
      oneOf:
        - type: integer
          format: int32
          description: An explicit value.
          minimum: 0
        - $ref: '#/components/schemas/DefinitionContextAuto'
          description: The word `auto`.
      description: A number, or `auto` to let the runner choose.
    DefinitionAnomalyRule:
      type: object
      description: One repeated-action pattern that stops a run.
      required:
        - pattern
        - threshold_count
        - threshold_window_s
      properties:
        pattern:
          $ref: '#/components/schemas/DefinitionAnomalyPattern'
          description: The pattern to watch for.
        threshold_count:
          type: integer
          format: int32
          description: How many repeats stop the run.
          maximum: 10000
          minimum: 1
        threshold_window_s:
          type: integer
          format: int32
          description: The window, in seconds, the repeats are counted in.
          maximum: 86400
          minimum: 1
      additionalProperties: false
    DefinitionGateRule:
      type: object
      description: One rule for when a tool action needs a person.
      required:
        - tool
        - action
      properties:
        action:
          type: string
          description: The action on that tool.
          maxLength: 128
          minLength: 1
        behavior:
          $ref: '#/components/schemas/DefinitionGateBehavior'
          description: What happens when the rule applies.
        blast_radius:
          type: string
          description: How far an approval reaches, as shown to the person.
          maxLength: 255
        condition:
          type:
            - string
            - 'null'
          description: A condition that narrows when the rule applies.
          maxLength: 255
        gate_kind:
          type: string
          description: The kind of decision the person is asked to make.
          maxLength: 255
        tool:
          type: string
          description: The tool the rule watches.
          maxLength: 128
          minLength: 1
      additionalProperties: false
    DefinitionWebhookSignature:
      type: object
      description: |-
        A Svix-signed webhook: the secret its deliveries are verified with, at
        `/v1/webhooks/svix/{fleet_id}`.
      required:
        - secret_ref
      properties:
        secret_ref:
          type: string
          description: The secret name that holds the Svix signing secret.
          maxLength: 128
          minLength: 1
      additionalProperties: false
    DefinitionContextAuto:
      type: string
      description: The only word a context setting accepts.
      enum:
        - auto
    DefinitionAnomalyPattern:
      type: string
      description: A repeated-action pattern.
      enum:
        - same_action
    DefinitionGateBehavior:
      type: string
      description: What happens when an approval rule applies.
      enum:
        - approve
        - auto_kill
  securitySchemes:
    BearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT
      description: >-
        Obtain a token via the CLI auth flow (POST /v1/auth/sessions) or GitHub
        OAuth

````

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