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

# Diagnose a workload

> Score a workload across time, agents, systems, authority, and accountability.



## OpenAPI

````yaml /openapi/v1.yaml post /doctor/workload
openapi: 3.1.0
info:
  title: OrgX REST API v1
  version: '1'
  description: >-
    Build accountable work into your product with OrgX REST API v1.


    Create work with one field, attach evidence when it is complete, and keep
    the receipt. Every authenticated request is scoped to the workspace resolved
    from your credential.


    Start with `POST /work`. Human guide:
    https://docs.useorgx.com/docs/api/quickstart
  contact:
    name: OrgX Support
    url: https://useorgx.com/support
    email: support@useorgx.com
  license:
    name: Proprietary
    url: https://useorgx.com/terms
servers:
  - url: https://useorgx.com/api/v1
    description: Production
security: []
tags:
  - name: Work
    description: Create accountable work and complete it with evidence
  - name: Initiatives
    description: Organize related work around an outcome
  - name: Operating processes
    description: Evidence-backed company workflow/process lifecycle
  - name: Operating map
    description: Derived, rebuildable Operating Map projection over the process ledger
  - name: Discovery runs
    description: Wizard and deep-search workflow discovery over connected company sources
  - name: Handoffs
    description: Ledger-backed stage handoffs between operating-process stages
  - name: Events
    description: Replayable, workspace-scoped accepted ledger events
  - name: Projections
    description: Workspace-scoped, rebuildable read projections over OrgX sources
  - name: Episodes
    description: Mission-compatible Episode read adapters
  - name: Receipt validation
    description: Account-free Agent Work Receipt schema discovery and conformance
  - name: Receipt import
    description: Authenticated, workspace-scoped import into the hosted receipt ledger
  - name: Workload diagnosis
    description: >-
      Account-free evaluation of time, agents, systems, authority, and
      accountability boundaries
  - name: Content Studio
    description: >-
      Estimate, showcase, checkout, and payment event operations for Content
      Studio
  - name: Decisions
    description: Raise decisions for human ruling and read their state
  - name: Controllers
    description: Shadow-only domain controller status and reconciliation
  - name: Artifacts
    description: Register produced work against the entity it belongs to
  - name: Launches
    description: Preview and run an initiative launch through its spend gates
  - name: Runs
    description: Control agent runs with pause, resume, cancel, and rollback
  - name: Lifecycle
    description: Pause, resume, retry, or cancel work hierarchy nodes and runs
  - name: Deduplication
    description: Claim durable event fingerprints so duplicate triggers fire once
  - name: Credential
    description: >-
      Resolve the calling credential, the workspaces it reaches, and what it may
      do
  - name: API discovery
    description: Account-free error codes, request schemas, and closed vocabularies for v1
externalDocs:
  description: Human-readable OrgX REST API v1 reference
  url: https://docs.useorgx.com/docs/api/public-api
paths:
  /doctor/workload:
    post:
      tags:
        - Workload diagnosis
      summary: Diagnose a workload
      description: >-
        Score a workload across time, agents, systems, authority, and
        accountability.
      operationId: diagnoseWorkloadBoundaries
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/WorkloadDiagnosisRequest'
            example:
              schema_version: workload-diagnosis/0.1
              workload:
                name: Review the launch plan
                outcome: Deploy the reviewed change.
                time_horizon: single_turn
                agent_count: 1
                coordination: none
                systems:
                  - category: code_repository
                    access: read
                    side_effect: none
                    data_class: public
                authority:
                  actions:
                    - research
                  approval_policy: not_applicable
                  budget_control: not_applicable
                accountability:
                  evidence: none
                  acceptance: none
                  consequence: low
                  retention: none
      responses:
        '200':
          description: Deterministic workload diagnosis
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/WorkloadDiagnosisResponse'
              example:
                schema_version: workload-diagnosis/0.1
                diagnosis_id: 3a7e2b54-b5b0-4d4e-9a5f-19dbf2f4c021
                recommendation:
                  verdict: needed
                  mode: none
                  summary: Launch plan reviewed with supporting evidence.
                  rationale:
                    - >-
                      The workload has a bounded outcome and an explicit
                      approval boundary.
                  active_boundary_count: 0
                boundaries:
                  time:
                    state: absent
                    score: 0
                    reason: No external system access is required for this boundary.
                  agents:
                    state: absent
                    score: 0
                    reason: No external system access is required for this boundary.
                  systems:
                    state: absent
                    score: 0
                    reason: No external system access is required for this boundary.
                  authority:
                    state: absent
                    score: 0
                    reason: No external system access is required for this boundary.
                  accountability:
                    state: absent
                    score: 0
                    reason: No external system access is required for this boundary.
                missing_capabilities:
                  - id: 2d4b7f66-3a2a-4e9d-9ad1-3b2d1b2e4101
                    boundary: time
                    reason: No external system access is required for this boundary.
                proposed_resources:
                  - resource: launch-planning repository
                    requested_access: read
                    scope_intents:
                      - read launch evidence
                    purpose: >-
                      Coordinate a launch review from proposal through verified
                      completion.
                    credential_input_required: false
                what_remains_local:
                  - item: Open review findings
                    reason: No external system access is required for this boundary.
                risks:
                  - id: 2d4b7f66-3a2a-4e9d-9ad1-3b2d1b2e4101
                    severity: low
                    boundary: time
                    description: Launch plan reviewed with supporting evidence.
                    mitigation: Require explicit approval before proceeding.
                capabilities_after_installation:
                  - review evidence
                human_approvals:
                  - id: 2d4b7f66-3a2a-4e9d-9ad1-3b2d1b2e4101
                    owner_role: workload_owner
                    timing: before_installation
                    decision: Approve the proposed access scope.
                    scope:
                      - launch review
                approval_handoff:
                  kind: none
                  url: >-
                    https://useorgx.com/tasks/7fbb727d-17c4-4bc7-9fc7-60eb15e9314d
                  mutates_state: false
                  carries_sensitive_data: true
                  approval_ids:
                    - approval-launch-review
        '400':
          description: Invalid JSON or workload metadata
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PublicApiError'
        '413':
          description: Request exceeds the 16,384-byte public limit
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PublicApiError'
        '415':
          description: Content-Type is not application/json
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PublicApiError'
        '429':
          description: Public diagnosis rate limit exceeded
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PublicApiError'
        '503':
          description: >-
            Secure workload handoff signing or distributed production rate
            limiting is unavailable
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/PublicApiError'
components:
  schemas:
    WorkloadDiagnosisRequest:
      type: object
      additionalProperties: false
      required:
        - schema_version
        - workload
      properties:
        schema_version:
          type: string
          const: workload-diagnosis/0.1
        workload:
          type: object
          additionalProperties: false
          required:
            - name
            - outcome
            - time_horizon
            - agent_count
            - coordination
            - systems
            - authority
            - accountability
          allOf:
            - if:
                required:
                  - agent_count
                properties:
                  agent_count:
                    const: 1
              then:
                properties:
                  coordination:
                    const: none
            - if:
                required:
                  - authority
                properties:
                  authority:
                    required:
                      - actions
                    properties:
                      actions:
                        contains:
                          const: write_internal_records
              then:
                properties:
                  systems:
                    contains:
                      required:
                        - access
                      properties:
                        access:
                          enum:
                            - write
                            - admin
            - if:
                required:
                  - authority
                properties:
                  authority:
                    required:
                      - actions
                    properties:
                      actions:
                        contains:
                          const: modify_code
              then:
                properties:
                  systems:
                    contains:
                      required:
                        - category
                        - access
                      properties:
                        category:
                          enum:
                            - code_repository
                            - local_files
                        access:
                          enum:
                            - write
                            - admin
            - if:
                required:
                  - authority
                properties:
                  authority:
                    required:
                      - actions
                    properties:
                      actions:
                        contains:
                          const: merge_or_deploy
              then:
                properties:
                  systems:
                    contains:
                      required:
                        - category
                        - access
                      properties:
                        category:
                          enum:
                            - code_repository
                            - cloud_runtime
                        access:
                          enum:
                            - write
                            - admin
            - if:
                required:
                  - authority
                properties:
                  authority:
                    required:
                      - actions
                    properties:
                      actions:
                        contains:
                          const: send_external_message
              then:
                properties:
                  systems:
                    contains:
                      required:
                        - category
                        - access
                      properties:
                        category:
                          enum:
                            - messaging
                            - crm
                            - browser
                            - other
                        access:
                          enum:
                            - write
                            - admin
            - if:
                required:
                  - authority
                properties:
                  authority:
                    required:
                      - actions
                    properties:
                      actions:
                        contains:
                          const: spend_funds
              then:
                properties:
                  systems:
                    contains:
                      required:
                        - category
                        - access
                      properties:
                        category:
                          enum:
                            - finance
                            - browser
                        access:
                          enum:
                            - write
                            - admin
            - if:
                required:
                  - authority
                properties:
                  authority:
                    required:
                      - actions
                    properties:
                      actions:
                        contains:
                          const: create_account
              then:
                properties:
                  systems:
                    contains:
                      required:
                        - category
                        - access
                      properties:
                        category:
                          enum:
                            - identity
                            - browser
                            - other
                        access:
                          enum:
                            - write
                            - admin
            - if:
                required:
                  - authority
                properties:
                  authority:
                    required:
                      - actions
                    properties:
                      actions:
                        contains:
                          const: change_permissions
              then:
                properties:
                  systems:
                    contains:
                      required:
                        - access
                      properties:
                        access:
                          const: admin
            - if:
                required:
                  - authority
                properties:
                  authority:
                    required:
                      - actions
                    properties:
                      actions:
                        contains:
                          const: delete_data
              then:
                properties:
                  systems:
                    contains:
                      required:
                        - category
                        - access
                      properties:
                        category:
                          enum:
                            - code_repository
                            - document_store
                            - crm
                            - database
                            - cloud_runtime
                            - local_files
                            - other
                        access:
                          enum:
                            - write
                            - admin
          properties:
            name:
              type: string
              description: >-
                Trimmed before the 1-to-120-character length check;
                whitespace-only, control-character, and credential-shaped values
                are rejected with 400.
              minLength: 1
              allOf:
                - pattern: \S
                - pattern: ^\s*(?:\S|\S[\s\S]{0,118}\S)\s*$
                - not:
                    pattern: '[\u0000-\u0008\u000b\u000c\u000e-\u001f\u007f]'
                - not:
                    pattern: >-
                      (?:\b(?:[Aa][Pp][Ii][_-]?[Kk][Ee][Yy]|[Aa][Cc][Cc][Ee][Ss][Ss][_-]?[Tt][Oo][Kk][Ee][Nn]|[Rr][Ee][Ff][Rr][Ee][Ss][Hh][_-]?[Tt][Oo][Kk][Ee][Nn]|[Cc][Ll][Ii][Ee][Nn][Tt][_-]?[Ss][Ee][Cc][Rr][Ee][Tt]|[Pp][Aa][Ss][Ss][Ww][Oo][Rr][Dd])\s*[:=]\s*\S+|\b[Bb][Ee][Aa][Rr][Ee][Rr]\s+[A-Za-z0-9._~+/=-]{8,}|\b(?:(?:[Oo][Xx][Kk]_|[Ss][Kk]-|[Gg][Hh][PpOoUuSsRr]_)[A-Za-z0-9_-]{8,}|[Aa][Kk][Ii][Aa][A-Za-z0-9]{16})\b|-----[Bb][Ee][Gg][Ii][Nn]
                      [A-Za-z ]*[Pp][Rr][Ii][Vv][Aa][Tt][Ee]
                      [Kk][Ee][Yy]-----|:\/\/[^\/\s:@]+:[^\/\s@]+@)
                - not:
                    pattern: >-
                      (?:\b[Gg][Ii][Tt][Hh][Uu][Bb]_[Pp][Aa][Tt]_[A-Za-z0-9_]{8,}|\b[Gg][Ll][Pp][Aa][Tt]-[A-Za-z0-9_-]{16,}|\b[Xx][Oo][Xx][BbAaPpRrSs]-[A-Za-z0-9-]{8,}|\b[Ss][Kk]_[Ll][Ii][Vv][Ee]_[A-Za-z0-9_-]{8,}|\b[Rr][Kk]_[Ll][Ii][Vv][Ee]_[A-Za-z0-9_-]{8,}|\b[Nn][Pp][Mm]_[A-Za-z0-9]{8,}|\b[Aa][Ss][Ii][Aa][A-Z0-9]{16}|\b[Dd][Oo][Pp]_[Vv]1_[A-Fa-f0-9]{16,}|\b[Hh][Ff]_[A-Za-z0-9]{20,}|\beyJ[A-Za-z0-9_-]{8,}\.eyJ[A-Za-z0-9_-]{8,}\.[A-Za-z0-9_-]{8,})
            outcome:
              type: string
              description: >-
                Trimmed before the 1-to-500-character length check;
                whitespace-only, control-character, and credential-shaped values
                are rejected with 400.
              minLength: 1
              allOf:
                - pattern: \S
                - pattern: ^\s*(?:\S|\S[\s\S]{0,498}\S)\s*$
                - not:
                    pattern: '[\u0000-\u0008\u000b\u000c\u000e-\u001f\u007f]'
                - not:
                    pattern: >-
                      (?:\b(?:[Aa][Pp][Ii][_-]?[Kk][Ee][Yy]|[Aa][Cc][Cc][Ee][Ss][Ss][_-]?[Tt][Oo][Kk][Ee][Nn]|[Rr][Ee][Ff][Rr][Ee][Ss][Hh][_-]?[Tt][Oo][Kk][Ee][Nn]|[Cc][Ll][Ii][Ee][Nn][Tt][_-]?[Ss][Ee][Cc][Rr][Ee][Tt]|[Pp][Aa][Ss][Ss][Ww][Oo][Rr][Dd])\s*[:=]\s*\S+|\b[Bb][Ee][Aa][Rr][Ee][Rr]\s+[A-Za-z0-9._~+/=-]{8,}|\b(?:(?:[Oo][Xx][Kk]_|[Ss][Kk]-|[Gg][Hh][PpOoUuSsRr]_)[A-Za-z0-9_-]{8,}|[Aa][Kk][Ii][Aa][A-Za-z0-9]{16})\b|-----[Bb][Ee][Gg][Ii][Nn]
                      [A-Za-z ]*[Pp][Rr][Ii][Vv][Aa][Tt][Ee]
                      [Kk][Ee][Yy]-----|:\/\/[^\/\s:@]+:[^\/\s@]+@)
                - not:
                    pattern: >-
                      (?:\b[Gg][Ii][Tt][Hh][Uu][Bb]_[Pp][Aa][Tt]_[A-Za-z0-9_]{8,}|\b[Gg][Ll][Pp][Aa][Tt]-[A-Za-z0-9_-]{16,}|\b[Xx][Oo][Xx][BbAaPpRrSs]-[A-Za-z0-9-]{8,}|\b[Ss][Kk]_[Ll][Ii][Vv][Ee]_[A-Za-z0-9_-]{8,}|\b[Rr][Kk]_[Ll][Ii][Vv][Ee]_[A-Za-z0-9_-]{8,}|\b[Nn][Pp][Mm]_[A-Za-z0-9]{8,}|\b[Aa][Ss][Ii][Aa][A-Z0-9]{16}|\b[Dd][Oo][Pp]_[Vv]1_[A-Fa-f0-9]{16,}|\b[Hh][Ff]_[A-Za-z0-9]{20,}|\beyJ[A-Za-z0-9_-]{8,}\.eyJ[A-Za-z0-9_-]{8,}\.[A-Za-z0-9_-]{8,})
            time_horizon:
              type: string
              enum:
                - single_turn
                - single_session
                - multi_day
                - recurring
                - continuous
            agent_count:
              type: integer
              minimum: 1
              maximum: 64
            coordination:
              type: string
              enum:
                - none
                - handoff
                - parallel
                - hierarchical
            systems:
              type: array
              maxItems: 12
              uniqueItems: true
              description: >-
                Each category may appear at most once; report its highest access
                and consequence.
              allOf:
                - contains:
                    required:
                      - category
                    properties:
                      category:
                        const: code_repository
                  minContains: 0
                  maxContains: 1
                - contains:
                    required:
                      - category
                    properties:
                      category:
                        const: issue_tracker
                  minContains: 0
                  maxContains: 1
                - contains:
                    required:
                      - category
                    properties:
                      category:
                        const: document_store
                  minContains: 0
                  maxContains: 1
                - contains:
                    required:
                      - category
                    properties:
                      category:
                        const: messaging
                  minContains: 0
                  maxContains: 1
                - contains:
                    required:
                      - category
                    properties:
                      category:
                        const: crm
                  minContains: 0
                  maxContains: 1
                - contains:
                    required:
                      - category
                    properties:
                      category:
                        const: database
                  minContains: 0
                  maxContains: 1
                - contains:
                    required:
                      - category
                    properties:
                      category:
                        const: cloud_runtime
                  minContains: 0
                  maxContains: 1
                - contains:
                    required:
                      - category
                    properties:
                      category:
                        const: finance
                  minContains: 0
                  maxContains: 1
                - contains:
                    required:
                      - category
                    properties:
                      category:
                        const: browser
                  minContains: 0
                  maxContains: 1
                - contains:
                    required:
                      - category
                    properties:
                      category:
                        const: local_files
                  minContains: 0
                  maxContains: 1
                - contains:
                    required:
                      - category
                    properties:
                      category:
                        const: identity
                  minContains: 0
                  maxContains: 1
                - contains:
                    required:
                      - category
                    properties:
                      category:
                        const: other
                  minContains: 0
                  maxContains: 1
              items:
                type: object
                additionalProperties: false
                required:
                  - category
                  - access
                  - side_effect
                  - data_class
                properties:
                  category:
                    type: string
                    enum:
                      - code_repository
                      - issue_tracker
                      - document_store
                      - messaging
                      - crm
                      - database
                      - cloud_runtime
                      - finance
                      - browser
                      - local_files
                      - identity
                      - other
                  access:
                    type: string
                    enum:
                      - read
                      - write
                      - admin
                  side_effect:
                    type: string
                    enum:
                      - none
                      - reversible
                      - external
                      - irreversible
                  data_class:
                    type: string
                    enum:
                      - public
                      - internal
                      - confidential
                      - regulated
            authority:
              type: object
              additionalProperties: false
              required:
                - actions
                - approval_policy
                - budget_control
              allOf:
                - if:
                    properties:
                      actions:
                        contains:
                          enum:
                            - write_internal_records
                            - modify_code
                            - merge_or_deploy
                            - send_external_message
                            - spend_funds
                            - create_account
                            - change_permissions
                            - delete_data
                  then:
                    properties:
                      approval_policy:
                        enum:
                          - per_action
                          - sensitive_actions
                          - exceptions_only
                          - undefined
                - if:
                    properties:
                      actions:
                        contains:
                          const: spend_funds
                  then:
                    properties:
                      budget_control:
                        enum:
                          - fixed_limit
                          - dynamic_limit
                          - unbounded
                          - undefined
                  else:
                    properties:
                      budget_control:
                        enum:
                          - not_applicable
                          - undefined
              properties:
                actions:
                  type: array
                  uniqueItems: true
                  maxItems: 11
                  items:
                    type: string
                    enum:
                      - research
                      - draft
                      - read_internal_data
                      - write_internal_records
                      - modify_code
                      - merge_or_deploy
                      - send_external_message
                      - spend_funds
                      - create_account
                      - change_permissions
                      - delete_data
                approval_policy:
                  type: string
                  enum:
                    - not_applicable
                    - per_action
                    - sensitive_actions
                    - exceptions_only
                    - undefined
                budget_control:
                  type: string
                  enum:
                    - not_applicable
                    - fixed_limit
                    - dynamic_limit
                    - unbounded
                    - undefined
            accountability:
              type: object
              additionalProperties: false
              required:
                - evidence
                - acceptance
                - consequence
                - retention
              properties:
                evidence:
                  type: string
                  enum:
                    - none
                    - activity_log
                    - artifact
                    - verified_outcome
                acceptance:
                  type: string
                  enum:
                    - none
                    - agent
                    - human
                    - downstream_system
                consequence:
                  type: string
                  enum:
                    - low
                    - moderate
                    - high
                    - regulated
                retention:
                  type: string
                  enum:
                    - none
                    - short_term
                    - long_term
                    - regulated
    WorkloadDiagnosisResponse:
      type: object
      additionalProperties: false
      required:
        - schema_version
        - diagnosis_id
        - recommendation
        - boundaries
        - missing_capabilities
        - proposed_resources
        - what_remains_local
        - risks
        - capabilities_after_installation
        - human_approvals
        - approval_handoff
      properties:
        schema_version:
          type: string
          const: workload-diagnosis/0.1
        diagnosis_id:
          type: string
          pattern: ^wdg_[a-f0-9]{24}$
        recommendation:
          type: object
          additionalProperties: false
          required:
            - verdict
            - mode
            - summary
            - rationale
            - active_boundary_count
          properties:
            verdict:
              type: string
              enum:
                - needed
                - conditional
                - not_needed
            mode:
              type: string
              enum:
                - none
                - receipt_only
                - governed_workspace
            summary:
              type: string
            rationale:
              type: array
              items:
                type: string
            active_boundary_count:
              type: integer
              minimum: 0
              maximum: 5
        boundaries:
          type: object
          additionalProperties: false
          required:
            - time
            - agents
            - systems
            - authority
            - accountability
          properties:
            time:
              $ref: '#/components/schemas/BoundaryFinding'
            agents:
              $ref: '#/components/schemas/BoundaryFinding'
            systems:
              $ref: '#/components/schemas/BoundaryFinding'
            authority:
              $ref: '#/components/schemas/BoundaryFinding'
            accountability:
              $ref: '#/components/schemas/BoundaryFinding'
        missing_capabilities:
          type: array
          maxItems: 15
          items:
            $ref: '#/components/schemas/MissingCapability'
        proposed_resources:
          type: array
          maxItems: 13
          items:
            $ref: '#/components/schemas/ProposedResource'
        what_remains_local:
          type: array
          minItems: 1
          maxItems: 6
          items:
            $ref: '#/components/schemas/LocalWorkItem'
        risks:
          type: array
          maxItems: 15
          items:
            $ref: '#/components/schemas/WorkloadRisk'
        capabilities_after_installation:
          type: array
          maxItems: 10
          items:
            type: string
            minLength: 1
            maxLength: 300
        human_approvals:
          type: array
          maxItems: 32
          items:
            $ref: '#/components/schemas/HumanApproval'
        approval_handoff:
          type: object
          additionalProperties: false
          required:
            - kind
            - url
            - mutates_state
            - carries_sensitive_data
            - approval_ids
          properties:
            kind:
              type: string
              enum:
                - none
                - browser_review
            url:
              type:
                - string
                - 'null'
              format: uri
            mutates_state:
              type: boolean
              const: false
            carries_sensitive_data:
              type: boolean
              description: >-
                True when an authenticated-encryption protected, short-lived
                browser handoff URL is present; false when no token is emitted.
            approval_ids:
              type: array
              items:
                type: string
    PublicApiError:
      type: object
      required:
        - error
      properties:
        ok:
          type: boolean
        valid:
          type: boolean
        error:
          type: object
          required:
            - code
            - message
          properties:
            code:
              type: string
            message:
              type: string
            issues:
              type: array
              items:
                type: object
    BoundaryFinding:
      type: object
      additionalProperties: false
      required:
        - state
        - score
        - reason
      properties:
        state:
          type: string
          enum:
            - absent
            - present
            - critical
        score:
          type: integer
          minimum: 0
          maximum: 2
        reason:
          type: string
          minLength: 1
          maxLength: 300
    MissingCapability:
      type: object
      additionalProperties: false
      required:
        - id
        - boundary
        - reason
      properties:
        id:
          type: string
          pattern: ^[a-z0-9_]{1,60}$
        boundary:
          type: string
          enum:
            - time
            - agents
            - systems
            - authority
            - accountability
        reason:
          type: string
          minLength: 1
          maxLength: 300
    ProposedResource:
      type: object
      additionalProperties: false
      required:
        - resource
        - requested_access
        - scope_intents
        - purpose
        - credential_input_required
      properties:
        resource:
          type: string
          minLength: 1
          maxLength: 80
        requested_access:
          type: string
          enum:
            - read
            - write
            - admin
        scope_intents:
          type: array
          minItems: 1
          maxItems: 12
          items:
            type: string
            minLength: 1
            maxLength: 80
        purpose:
          type: string
          minLength: 1
          maxLength: 300
        credential_input_required:
          type: boolean
          const: false
    LocalWorkItem:
      type: object
      additionalProperties: false
      required:
        - item
        - reason
      properties:
        item:
          type: string
          minLength: 1
          maxLength: 100
        reason:
          type: string
          minLength: 1
          maxLength: 300
    WorkloadRisk:
      type: object
      additionalProperties: false
      required:
        - id
        - severity
        - boundary
        - description
        - mitigation
      properties:
        id:
          type: string
          pattern: ^[a-z0-9_]{1,60}$
        severity:
          type: string
          enum:
            - low
            - medium
            - high
            - critical
        boundary:
          type: string
          enum:
            - time
            - agents
            - systems
            - authority
            - accountability
        description:
          type: string
          minLength: 1
          maxLength: 300
        mitigation:
          type: string
          minLength: 1
          maxLength: 300
    HumanApproval:
      type: object
      additionalProperties: false
      required:
        - id
        - owner_role
        - timing
        - decision
        - scope
      properties:
        id:
          type: string
          pattern: ^[a-z0-9_-]{1,80}$
        owner_role:
          type: string
          enum:
            - workload_owner
            - system_owner
            - code_owner
            - communications_owner
            - budget_owner
            - identity_admin
            - data_owner
        timing:
          type: string
          enum:
            - before_installation
            - before_first_use
            - per_action
            - when_threshold_exceeded
        decision:
          type: string
          minLength: 1
          maxLength: 300
        scope:
          type: array
          minItems: 1
          maxItems: 16
          items:
            type: string
            minLength: 1
            maxLength: 100

````