NVIDIA Run:ai Policy API

Policies allow administrators to impose restrictions and set default values for researcher workloads. Restrictions and default values can be placed on CPUs, GPUs, and other resources or entities. For more information, see [Policies](https://run-ai-docs.nvidia.com/saas/platform-management/policies/#introduction).

OpenAPI Specification

runai-policy-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  version: latest
  description: '# Introduction


    The NVIDIA Run:ai Control-Plane API reference is a guide that provides an easy-to-use programming interface for adding various tasks to your application, including workload submission, resource management, and administrative operations.


    NVIDIA Run:ai APIs are accessed using *bearer tokens*. To obtain a token, you need to create a **Service account** through the NVIDIA Run:ai user interface.

    To create a service account, in your UI, go to Access → Service Accounts (for organization-level service accounts) or User settings → Access Keys (for user access keys), and create a new one.


    After you have created a new service account, you will need to assign it access rules.

    To assign access rules to the service account, see [Create access rules](https://run-ai-docs.nvidia.com/saas/infrastructure-setup/authentication/accessrules#create-or-delete-rules).

    Make sure you assign the correct rules to your service account. Use the [Roles](https://run-ai-docs.nvidia.com/saas/infrastructure-setup/authentication/roles) to assign the correct access rules.


    To get your access token, follow the instructions in [Request a token](https://run-ai-docs.nvidia.com/saas/reference/api/rest-auth/#request-an-api-token).

    '
  title: NVIDIA Run:ai Access Keys Policy API
  x-logo:
    url: https://api.redocly.com/registry/raw/runai-xq8/saas/latest/public/runai-logo-api.png
    altText: NVIDIA Run:ai
    href: https://run.ai
  license:
    name: NVIDIA Run:ai
    url: https://www.nvidia.com/en-us/agreements/enterprise-software/nvidia-software-license-agreement/
servers:
- url: https://app.run.ai
security:
- bearerAuth: []
tags:
- name: Policy
  description: "Policies allow administrators to impose restrictions and set default values for researcher workloads. \nRestrictions and default values can be placed on CPUs, GPUs, and other resources or entities. \nFor more information, see [Policies](https://run-ai-docs.nvidia.com/saas/platform-management/policies/#introduction).\n"
paths:
  /api/v2/policy:
    get:
      summary: List policies
      description: Retrieve a list of all the applied policies.
      operationId: list_policies
      tags:
      - Policy
      parameters:
      - $ref: '#/components/parameters/WorkloadType'
      - name: scope
        in: query
        required: false
        description: filter by this scope.
        schema:
          type: string
          enum:
          - tenant
          - cluster
          - department
          - project
      - $ref: '#/components/parameters/FilterByDepartment'
      - $ref: '#/components/parameters/FilterByProject'
      - $ref: '#/components/parameters/FilterByCluster'
      - $ref: '#/components/parameters/IncludeFallbackPolicies'
      responses:
        '200':
          description: Request completed successfully.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PolicyListResponse'
        '401':
          $ref: '#/components/responses/401Unauthorized'
        '403':
          $ref: '#/components/responses/403Forbidden'
        '503':
          $ref: '#/components/responses/503ServiceUnavailable'
  /api/v2/policy/trainings:
    patch:
      summary: Update a training policy.
      description: Use to apply changes to a training policy for a given organizational unit.
      operationId: update_training_policy_v2
      tags:
      - Policy
      parameters:
      - $ref: '#/components/parameters/ValidateOnly'
      - $ref: '#/components/parameters/ApproveClusterDeletion'
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/TrainingPolicyChangeRequestV2'
      responses:
        '200':
          description: Policy applied.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/TrainingPolicyV2'
        '400':
          $ref: '#/components/responses/400BadRequest'
        '401':
          $ref: '#/components/responses/401Unauthorized'
        '403':
          $ref: '#/components/responses/403Forbidden'
        '503':
          $ref: '#/components/responses/503ServiceUnavailable'
    put:
      summary: Overwrite a training policy.
      description: Use to apply a training policy for a given organizational unit.
      operationId: overwrite_training_policy_v2
      tags:
      - Policy
      parameters:
      - $ref: '#/components/parameters/ValidateOnly'
      - $ref: '#/components/parameters/ApproveClusterDeletion'
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/TrainingPolicyOverwriteRequestV2'
      responses:
        '200':
          description: Policy applied.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/TrainingPolicyV2'
        '400':
          $ref: '#/components/responses/400BadRequest'
        '401':
          $ref: '#/components/responses/401Unauthorized'
        '403':
          $ref: '#/components/responses/403Forbidden'
        '503':
          $ref: '#/components/responses/503ServiceUnavailable'
    get:
      summary: Get a training policy.
      description: Retrieve the details of a training policy for a given organizational unit.
      operationId: get_training_policy_v2
      tags:
      - Policy
      parameters:
      - $ref: '#/components/parameters/PolicyScope'
      - $ref: '#/components/parameters/FilterByDepartment'
      - $ref: '#/components/parameters/FilterByProject'
      - $ref: '#/components/parameters/FilterByCluster'
      responses:
        '200':
          description: Request completed successfully.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/TrainingPolicyV2'
        '400':
          $ref: '#/components/responses/400BadRequest'
        '401':
          $ref: '#/components/responses/401Unauthorized'
        '403':
          $ref: '#/components/responses/403Forbidden'
        '404':
          $ref: '#/components/responses/404NotFound'
        '503':
          $ref: '#/components/responses/503ServiceUnavailable'
    delete:
      summary: Delete a training policy.
      description: Use to delete a training policy for a given organizational unit.
      operationId: delete_training_policy
      tags:
      - Policy
      parameters:
      - $ref: '#/components/parameters/PolicyScope'
      - $ref: '#/components/parameters/FilterByDepartment'
      - $ref: '#/components/parameters/FilterByProject'
      - $ref: '#/components/parameters/FilterByCluster'
      - $ref: '#/components/parameters/ApproveClusterDeletion'
      responses:
        '204':
          description: The policy was deleted successfully.
        '400':
          $ref: '#/components/responses/400BadRequest'
        '401':
          $ref: '#/components/responses/401Unauthorized'
        '403':
          $ref: '#/components/responses/403Forbidden'
        '404':
          $ref: '#/components/responses/404NotFound'
        '503':
          $ref: '#/components/responses/503ServiceUnavailable'
  /api/v2/policy/workspaces:
    patch:
      summary: Update a workspace policy.
      description: Use to apply changes to a workspace policy for a given organizational unit.
      operationId: update_workspace_policy_v2
      tags:
      - Policy
      parameters:
      - $ref: '#/components/parameters/ValidateOnly'
      - $ref: '#/components/parameters/ApproveClusterDeletion'
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/WorkspacePolicyChangeRequestV2'
      responses:
        '200':
          description: Policy applied.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WorkspacePolicyV2'
        '400':
          $ref: '#/components/responses/400BadRequest'
        '401':
          $ref: '#/components/responses/401Unauthorized'
        '403':
          $ref: '#/components/responses/403Forbidden'
        '503':
          $ref: '#/components/responses/503ServiceUnavailable'
    put:
      summary: Overwrite a workspace policy.
      description: Ue to apply a workspace policy for a given organizational unit.
      operationId: overwrite_workspace_policy_v2
      tags:
      - Policy
      parameters:
      - $ref: '#/components/parameters/ValidateOnly'
      - $ref: '#/components/parameters/ApproveClusterDeletion'
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/WorkspacePolicyOverwriteRequestV2'
      responses:
        '200':
          description: Policy applied.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WorkspacePolicyV2'
        '400':
          $ref: '#/components/responses/400BadRequest'
        '401':
          $ref: '#/components/responses/401Unauthorized'
        '403':
          $ref: '#/components/responses/403Forbidden'
        '503':
          $ref: '#/components/responses/503ServiceUnavailable'
    get:
      summary: Get a workspace policy.
      description: Retrieve the details of a workspace policy for a given organizational unit.
      operationId: get_workspace_policy_v2
      tags:
      - Policy
      parameters:
      - $ref: '#/components/parameters/PolicyScope'
      - $ref: '#/components/parameters/FilterByDepartment'
      - $ref: '#/components/parameters/FilterByProject'
      - $ref: '#/components/parameters/FilterByCluster'
      responses:
        '200':
          description: Request completed successfully.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WorkspacePolicyV2'
        '400':
          $ref: '#/components/responses/400BadRequest'
        '401':
          $ref: '#/components/responses/401Unauthorized'
        '403':
          $ref: '#/components/responses/403Forbidden'
        '404':
          $ref: '#/components/responses/404NotFound'
        '503':
          $ref: '#/components/responses/503ServiceUnavailable'
    delete:
      summary: Delete a workspace policy.
      description: Use to delete a workspace policy for a given organizational unit.
      operationId: delete_workspace_policy
      tags:
      - Policy
      parameters:
      - $ref: '#/components/parameters/PolicyScope'
      - $ref: '#/components/parameters/FilterByDepartment'
      - $ref: '#/components/parameters/FilterByProject'
      - $ref: '#/components/parameters/FilterByCluster'
      - $ref: '#/components/parameters/ApproveClusterDeletion'
      responses:
        '204':
          description: The policy was deleted successfully.
        '400':
          $ref: '#/components/responses/400BadRequest'
        '401':
          $ref: '#/components/responses/401Unauthorized'
        '403':
          $ref: '#/components/responses/403Forbidden'
        '404':
          $ref: '#/components/responses/404NotFound'
        '503':
          $ref: '#/components/responses/503ServiceUnavailable'
  /api/v2/policy/distributed:
    patch:
      summary: Update a distributed policy.
      description: Use to apply changes to a distributed policy for a given organizational unit.
      operationId: update_distributed_policy_v2
      tags:
      - Policy
      parameters:
      - $ref: '#/components/parameters/ValidateOnly'
      - $ref: '#/components/parameters/ApproveClusterDeletion'
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/DistributedPolicyChangeRequestV2'
      responses:
        '200':
          description: Policy applied.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/DistributedPolicyV2'
        '400':
          $ref: '#/components/responses/400BadRequest'
        '401':
          $ref: '#/components/responses/401Unauthorized'
        '403':
          $ref: '#/components/responses/403Forbidden'
        '503':
          $ref: '#/components/responses/503ServiceUnavailable'
    put:
      summary: Overwrite a distributed policy.
      description: Use to apply a distributed policy for a given organizational unit.
      operationId: overwrite_distributed_policy_v2
      tags:
      - Policy
      parameters:
      - $ref: '#/components/parameters/ValidateOnly'
      - $ref: '#/components/parameters/ApproveClusterDeletion'
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/DistributedPolicyOverwriteRequestV2'
      responses:
        '200':
          description: Policy applied.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/DistributedPolicyV2'
        '400':
          $ref: '#/components/responses/400BadRequest'
        '401':
          $ref: '#/components/responses/401Unauthorized'
        '403':
          $ref: '#/components/responses/403Forbidden'
        '503':
          $ref: '#/components/responses/503ServiceUnavailable'
    get:
      summary: Get a distributed policy.
      description: Retrieve the details of a distributed policy for a given organizational unit.
      operationId: get_distributed_policy_v2
      tags:
      - Policy
      parameters:
      - $ref: '#/components/parameters/PolicyScope'
      - $ref: '#/components/parameters/FilterByDepartment'
      - $ref: '#/components/parameters/FilterByProject'
      - $ref: '#/components/parameters/FilterByCluster'
      responses:
        '200':
          description: Request completed successfully.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/DistributedPolicyV2'
        '400':
          $ref: '#/components/responses/400BadRequest'
        '401':
          $ref: '#/components/responses/401Unauthorized'
        '403':
          $ref: '#/components/responses/403Forbidden'
        '404':
          $ref: '#/components/responses/404NotFound'
        '503':
          $ref: '#/components/responses/503ServiceUnavailable'
    delete:
      summary: Delete a distributed policy.
      description: Use to delete a distributed policy for a given organizational unit.
      operationId: delete_distributed_policy
      tags:
      - Policy
      parameters:
      - $ref: '#/components/parameters/PolicyScope'
      - $ref: '#/components/parameters/FilterByDepartment'
      - $ref: '#/components/parameters/FilterByProject'
      - $ref: '#/components/parameters/FilterByCluster'
      - $ref: '#/components/parameters/ApproveClusterDeletion'
      responses:
        '204':
          description: The policy was deleted successfully.
        '400':
          $ref: '#/components/responses/400BadRequest'
        '401':
          $ref: '#/components/responses/401Unauthorized'
        '403':
          $ref: '#/components/responses/403Forbidden'
        '404':
          $ref: '#/components/responses/404NotFound'
        '503':
          $ref: '#/components/responses/503ServiceUnavailable'
  /api/v2/policy/inferences:
    patch:
      summary: Update an inference policy.
      description: Use to apply changes to an inference policy for a given organizational unit.
      operationId: update_inference_policy_v2
      tags:
      - Policy
      parameters:
      - $ref: '#/components/parameters/ValidateOnly'
      - $ref: '#/components/parameters/ApproveClusterDeletion'
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/InferencePolicyChangeRequestV2'
      responses:
        '200':
          description: Policy applied.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/InferencePolicyV2'
        '400':
          $ref: '#/components/responses/400BadRequest'
        '401':
          $ref: '#/components/responses/401Unauthorized'
        '403':
          $ref: '#/components/responses/403Forbidden'
        '503':
          $ref: '#/components/responses/503ServiceUnavailable'
    put:
      summary: Overwrite an inference policy.
      description: Use to apply an inference policy for a given organizational unit.
      operationId: overwrite_inference_policy_v2
      tags:
      - Policy
      parameters:
      - $ref: '#/components/parameters/ValidateOnly'
      - $ref: '#/components/parameters/ApproveClusterDeletion'
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/InferencePolicyOverwriteRequestV2'
      responses:
        '200':
          description: Policy applied.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/InferencePolicyV2'
        '400':
          $ref: '#/components/responses/400BadRequest'
        '401':
          $ref: '#/components/responses/401Unauthorized'
        '403':
          $ref: '#/components/responses/403Forbidden'
        '503':
          $ref: '#/components/responses/503ServiceUnavailable'
    get:
      summary: Get an inference policy.
      description: Retrieve the details of an inference policy for a given organizational unit.
      operationId: get_inference_policy_v2
      tags:
      - Policy
      parameters:
      - $ref: '#/components/parameters/PolicyScope'
      - $ref: '#/components/parameters/FilterByDepartment'
      - $ref: '#/components/parameters/FilterByProject'
      - $ref: '#/components/parameters/FilterByCluster'
      responses:
        '200':
          description: Request completed successfully.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/InferencePolicyV2'
        '400':
          $ref: '#/components/responses/400BadRequest'
        '401':
          $ref: '#/components/responses/401Unauthorized'
        '403':
          $ref: '#/components/responses/403Forbidden'
        '404':
          $ref: '#/components/responses/404NotFound'
        '503':
          $ref: '#/components/responses/503ServiceUnavailable'
    delete:
      summary: Delete an inference policy.
      description: Use to delete an inference policy for a given organizational unit.
      operationId: delete_inference_policy
      tags:
      - Policy
      parameters:
      - $ref: '#/components/parameters/PolicyScope'
      - $ref: '#/components/parameters/FilterByDepartment'
      - $ref: '#/components/parameters/FilterByProject'
      - $ref: '#/components/parameters/FilterByCluster'
      - $ref: '#/components/parameters/ApproveClusterDeletion'
      responses:
        '204':
          description: The policy was deleted successfully.
        '400':
          $ref: '#/components/responses/400BadRequest'
        '401':
          $ref: '#/components/responses/401Unauthorized'
        '403':
          $ref: '#/components/responses/403Forbidden'
        '404':
          $ref: '#/components/responses/404NotFound'
        '503':
          $ref: '#/components/responses/503ServiceUnavailable'
  /api/v2/policy/distributed-inferences:
    patch:
      summary: Update a distributed inference policy.
      description: Use to apply changes to a distributed inference policy for a given organizational unit.
      operationId: update_distributed_inference_policy_v2
      tags:
      - Policy
      parameters:
      - $ref: '#/components/parameters/ValidateOnly'
      - $ref: '#/components/parameters/ApproveClusterDeletion'
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/DistributedInferencePolicyChangeRequestV2'
      responses:
        '200':
          description: Policy applied.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/DistributedInferencePolicyV2'
        '400':
          $ref: '#/components/responses/400BadRequest'
        '401':
          $ref: '#/components/responses/401Unauthorized'
        '403':
          $ref: '#/components/responses/403Forbidden'
        '503':
          $ref: '#/components/responses/503ServiceUnavailable'
    put:
      summary: Overwrite a distributed inference policy.
      description: Use to apply a distributed inference policy for a given organizational unit.
      operationId: overwrite_distributed_inference_policy_v2
      tags:
      - Policy
      parameters:
      - $ref: '#/components/parameters/ValidateOnly'
      - $ref: '#/components/parameters/ApproveClusterDeletion'
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/DistributedInferencePolicyOverwriteRequestV2'
      responses:
        '200':
          description: Policy applied.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/DistributedInferencePolicyV2'
        '400':
          $ref: '#/components/responses/400BadRequest'
        '401':
          $ref: '#/components/responses/401Unauthorized'
        '403':
          $ref: '#/components/responses/403Forbidden'
        '503':
          $ref: '#/components/responses/503ServiceUnavailable'
    get:
      summary: Get a distributed inference policy.
      description: Retrieve the details of a distributed inference policy for a given organizational unit.
      operationId: get_distributed_inference_policy_v2
      tags:
      - Policy
      parameters:
      - $ref: '#/components/parameters/PolicyScope'
      - $ref: '#/components/parameters/FilterByDepartment'
      - $ref: '#/components/parameters/FilterByProject'
      - $ref: '#/components/parameters/FilterByCluster'
      responses:
        '200':
          description: Request completed successfully.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/DistributedInferencePolicyV2'
        '400':
          $ref: '#/components/responses/400BadRequest'
        '401':
          $ref: '#/components/responses/401Unauthorized'
        '403':
          $ref: '#/components/responses/403Forbidden'
        '404':
          $ref: '#/components/responses/404NotFound'
        '503':
          $ref: '#/components/responses/503ServiceUnavailable'
    delete:
      summary: Delete a distributed inference policy.
      description: Use to delete a distributed inference policy for a given organizational unit.
      operationId: delete_distributed_inference_policy
      tags:
      - Policy
      parameters:
      - $ref: '#/components/parameters/PolicyScope'
      - $ref: '#/components/parameters/FilterByDepartment'
      - $ref: '#/components/parameters/FilterByProject'
      - $ref: '#/components/parameters/FilterByCluster'
      - $ref: '#/components/parameters/ApproveClusterDeletion'
      responses:
        '204':
          description: The policy was deleted successfully.
        '400':
          $ref: '#/components/responses/400BadRequest'
        '401':
          $ref: '#/components/responses/401Unauthorized'
        '403':
          $ref: '#/components/responses/403Forbidden'
        '404':
          $ref: '#/components/responses/404NotFound'
        '503':
          $ref: '#/components/responses/503ServiceUnavailable'
  /api/v2/policy/nim-services:
    patch:
      summary: Update NVIDIA NIM service policy.
      description: Use to apply changes to NVIDIA NIM service policy for a given organizational unit.
      operationId: update_nim_service_policy
      tags:
      - Policy
      parameters:
      - $ref: '#/components/parameters/ValidateOnly'
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/NimServicePolicyChangeRequest'
      responses:
        '200':
          description: Policy applied.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/NimServicePolicy'
        '400':
          $ref: '#/components/responses/400BadRequest'
        '401':
          $ref: '#/components/responses/401Unauthorized'
        '403':
          $ref: '#/components/responses/403Forbidden'
        '503':
          $ref: '#/components/responses/503ServiceUnavailable'
    put:
      summary: Overwrite NVIDIA NIM service policy.
      description: Use to apply NVIDIA NIM service policy for a given organizational unit.
      operationId: overwrite_nim_service_policy
      tags:
      - Policy
      parameters:
      - $ref: '#/components/parameters/ValidateOnly'
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/NimServicePolicyOverwriteRequest'
      responses:
        '200':
          description: Policy applied.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/NimServicePolicy'
        '400':
          $ref: '#/components/responses/400BadRequest'
        '401':
          $ref: '#/components/responses/401Unauthorized'
        '403':
          $ref: '#/components/responses/403Forbidden'
        '503':
          $ref: '#/components/responses/503ServiceUnavailable'
    get:
      summary: Get NVIDIA NIM service policy.
      description: Retrieve the details of NVIDIA NIM service policy for a given organizational unit.
      operationId: get_nim_service_policy
      tags:
      - Policy
      parameters:
      - $ref: '#/components/parameters/PolicyScope'
      - $ref: '#/components/parameters/FilterByDepartment'
      - $ref: '#/components/parameters/FilterByProject'
      - $ref: '#/components/parameters/FilterByCluster'
      responses:
        '200':
          description: Request completed successfully.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/NimServicePolicy'
        '400':
          $ref: '#/components/responses/400BadRequest'
        '401':
          $ref: '#/components/responses/401Unauthorized'
        '403':
          $ref: '#/components/responses/403Forbidden'
        '404':
          $ref: '#/components/responses/404NotFound'
        '503':
          $ref: '#/components/responses/503ServiceUnavailable'
    delete:
      summary: Delete NVIDIA NIM service policy.
      description: Use to delete NVIDIA NIM service policy for a given organizational unit.
      operationId: delete_nim_service_policy
      tags:
      - Policy
      parameters:
      - $ref: '#/components/parameters/PolicyScope'
      - $ref: '#/components/parameters/FilterByDepartment'
      - $ref: '#/components/parameters/FilterByProject'
      - $ref: '#/components/parameters/FilterByCluster'
      responses:
        '204':
          description: The policy was deleted successfully.
        '400':
          $ref: '#/components/responses/400BadRequest'
        '401':
          $ref: '#/components/responses/401Unauthorized'
        '403':
          $ref: '#/components/responses/403Forbidden'
        '404':
          $ref: '#/components/responses/404NotFound'
        '503':
          $ref: '#/components/responses/503ServiceUnavailable'
components:
  schemas:
    MetricThresholdField:
      properties:
        metricThreshold:
          description: The threshold to use with the specified metric for autoscaling. Mandatory if metric is specified
          type:
          - integer
          - 'null'
          format: int32
    DistributedInferenceServingPortProtocol:
      description: The protocol used to access the port.
      type:
      - string
      - 'null'
      enum:
      - http
      default: http
    PodAffinityTypeOptions:
      properties:
        options:
          type:
          - array
          - 'null'
          items:
            required:
            - value
            properties:
              value:
                $ref: '#/components/schemas/PodAffinityType'
              displayed:
                description: Textual description of the value
                type:
                - string
                - 'null'
                pattern: .*
      type: object
    PodAffinityTypeRules:
      allOf:
      - $ref: '#/components/schemas/StringRulesCommon'
      - $ref: '#/components/schemas/PodAffinityTypeOptions'
      type:
      - object
      - 'null'
    TerminationGracePeriod:
      description: Duration in seconds the pod needs to terminate gracefully upon probe failure. The grace period is the duration in seconds after the processes running in the pod are sent a termination signal and the time when the processes are forcibly halted with a kill signal. Set this value longer than the expected cleanup time for your process. Value must be non-negative integer. The value zero indicates stop immediately via the kill signal (no opportunity to shut down).
      format: int64
      type:
      - integer
      - 'null'
      minimum: 0
      example: 20
    PvcRules:
      properties:
        claimName:
          $ref: '#/components/schemas/StringRules'
        path:
          $ref: '#/components/schemas/StringRules'
        readOnly:
          $ref: '#/components/schemas/BooleanRules'
        claimInfo:
          $ref: '#/components/schemas/ClaimInfoRules'
      type:
      - object
      - 'null'
    Label:
      description: Label details to be populated into the container.
      properties:
        name:
          description: The name of the label (mandatory)
          type:
          - string
          - 'null'
          minLength: 1
          maxLength: 63
          example: stage
          pattern: .*
        value:
          description: The value of the label.
          type:
          - string
          - 'null'
          example: initial-research
          pattern: .*
        exclude:
          description: Use 'true' in case the label is defined in defaults of the policy, and you wish to exclude it from the workload.
          type:
          - boolean
          - 'null'
          example: false
      type:
      - object
      - 'null'
    Labels:
      description: Set of labels to populate into the container running the workload.
      type:
      - array
      - 'null'
      items:
        $ref: '#/components/schemas/Label'
    EnvironmentVariablePodFieldReference:
      description: Details of the field-reference and key use to populate the environment variable
      properties:
        path:
          description: The field path resource. (mandatory)
          type:
          - string
          - 'null'
          minLength: 1
          example: metadata.name
          pattern: .*
      type:
      - object
      - 'null'
    SecretFieldsNonUpdatable:
      properties:
        secret:
          description: The name of the Secret resource. (mandatory)
          type:
          - string
          - 'null'
          minLength: 1
      type:
      - object
      - 'null'
    TolerationOperatorRules:
      allOf:
      - $ref: '#/components/schemas/StringRulesCommon'
      - $ref: '#/components/schemas/TolerationOperatorOptions'
      type:
      - object
      - 'null'
    GitInstance:
      allOf:
      - $ref: '#/components/schemas/StorageInstanceName'
      - $ref: '#/components/schemas/GitCommon'
      - $ref: '#/components/schemas/GitPassword'
      - $ref: '#/components/schemas/ExcludeField'
      - type:
        - object
        - 'null'
        properties:
          secretRef:
            $ref: '#/components/schemas/GitSecretRef'
      type:
      - object
      - 'null'
    ProbeRules:
      properties:
        initialDelaySeconds:
          $ref: '#/components/schemas/IntegerRules'
        periodSeconds:
          $ref: '#/components/schemas/IntegerRules'
        timeoutSeconds:
          $ref: '#/components/schemas/IntegerRules'
        successThreshold:
          $ref: '#/components/schemas/IntegerRules'
        failureThreshold:
          $ref: '#/components/schemas/IntegerRules'
        handler:
          $ref: '#/components/schemas/ProbeHandlerRules'
      type:
      - object
      - 'null'
    ServingPortAuthorizationTypeRules:
      allOf:
      - $ref: '#/components/schemas/StringRulesCommon'
      - $ref: '#/components/schemas/ServingPortAuthorizationTypeOptions'
      type:
      - object
      - 'null'
    AutoDeletionTimeAfterPreemption:
      description: Specifies the duration after whi

# --- truncated at 32 KB (230 KB total) ---
# Full source: https://raw.githubusercontent.com/api-evangelist/runai/refs/heads/main/openapi/runai-policy-api-openapi.yml