{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/amazon-bedrock/json-schema/amazon-bedrock-create-automated-reasoning-policy-request-schema.json",
  "title": "CreateAutomatedReasoningPolicyRequest",
  "x-generated": "2026-11-11",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/amazon-bedrock-automated-reasoning-policies-api-openapi.yml#/components/schemas/CreateAutomatedReasoningPolicyRequest",
  "type": "object",
  "properties": {
    "name": {
      "type": "string",
      "description": "A unique name for the Automated Reasoning policy. The name must be between 1 and 63 characters and can contain letters, numbers, hyphens, and underscores."
    },
    "description": {
      "type": "string",
      "description": "A description of the Automated Reasoning policy. Use this to provide context about the policy's purpose and the types of validations it performs."
    },
    "clientRequestToken": {
      "type": "string",
      "description": "A unique, case-sensitive identifier to ensure that the operation completes no more than once. If this token matches a previous request, Amazon Bedrock ignores the request but doesn't return an error."
    },
    "policyDefinition": {
      "$ref": "#/$defs/AutomatedReasoningPolicyDefinition"
    },
    "kmsKeyId": {
      "type": "string",
      "description": "The identifier of the KMS key to use for encrypting the automated reasoning policy and its associated artifacts. If you don't specify a KMS key, Amazon Bedrock uses an KMS managed key for encryption. For enhanced security and control, you can specify a customer managed KMS key."
    },
    "tags": {
      "type": "array",
      "items": {
        "$ref": "#/$defs/Tag"
      },
      "description": "A list of tags to associate with the Automated Reasoning policy. Tags help you organize and manage your policies."
    }
  },
  "required": [
    "name"
  ],
  "$defs": {
    "AutomatedReasoningPolicyDefinition": {
      "type": "object",
      "properties": {
        "version": {
          "type": "string",
          "description": "The version of the policy definition format."
        },
        "types": {
          "type": "array",
          "items": {
            "$ref": "#/$defs/AutomatedReasoningPolicyDefinitionType"
          },
          "description": "The custom user-defined vairable types used in the policy. Types are enum-based variable types that provide additional context beyond the predefined variable types."
        },
        "rules": {
          "type": "array",
          "items": {
            "$ref": "#/$defs/AutomatedReasoningPolicyDefinitionRule"
          },
          "description": "The formal logic rules extracted from the source document. Rules define the logical constraints that determine whether model responses are valid, invalid, or satisfiable."
        },
        "variables": {
          "type": "array",
          "items": {
            "$ref": "#/$defs/AutomatedReasoningPolicyDefinitionVariable"
          },
          "description": "The variables that represent concepts in the policy. Variables can have values assigned when translating natural language into formal logic. Their descriptions are crucial for accurate translation."
        }
      }
    },
    "AutomatedReasoningPolicyDefinitionRule": {
      "type": "object",
      "properties": {
        "id": {
          "type": "string",
          "description": "The unique identifier of the rule within the policy."
        },
        "expression": {
          "type": "string",
          "description": "The formal logic expression of the rule."
        },
        "alternateExpression": {
          "type": "string",
          "description": "The human-readable form of the rule expression, often in natural language or simplified notation."
        }
      },
      "required": [
        "id",
        "expression"
      ]
    },
    "AutomatedReasoningPolicyDefinitionType": {
      "type": "object",
      "properties": {
        "name": {
          "type": "string",
          "description": "The name of the custom type."
        },
        "description": {
          "type": "string",
          "description": "The description of what the custom type represents."
        },
        "values": {
          "type": "array",
          "items": {
            "$ref": "#/$defs/AutomatedReasoningPolicyDefinitionTypeValue"
          },
          "description": "The possible values for this enum-based type, each with its own description."
        }
      },
      "required": [
        "name",
        "values"
      ]
    },
    "AutomatedReasoningPolicyDefinitionTypeValue": {
      "type": "object",
      "properties": {
        "value": {
          "type": "string",
          "description": "The actual value or identifier for this type value."
        },
        "description": {
          "type": "string",
          "description": "A human-readable description explaining what this type value represents and when it should be used."
        }
      },
      "required": [
        "value"
      ]
    },
    "AutomatedReasoningPolicyDefinitionVariable": {
      "type": "object",
      "properties": {
        "name": {
          "type": "string",
          "description": "The name of the variable. Use descriptive names that clearly indicate the concept being represented."
        },
        "type": {
          "type": "string",
          "description": "The data type of the variable. Valid types include bool, int, real, enum, and custom types that you can provide."
        },
        "description": {
          "type": "string",
          "description": "The description of the variable that explains what it represents and how users might refer to it. Clear and comprehensive descriptions are essential for accurate natural language translation."
        }
      },
      "required": [
        "name",
        "type",
        "description"
      ]
    },
    "Tag": {
      "type": "object",
      "properties": {
        "key": {
          "type": "string",
          "description": "Key for the tag."
        },
        "value": {
          "type": "string",
          "description": "Value for the tag."
        }
      },
      "required": [
        "key",
        "value"
      ]
    }
  }
}