{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/amazon-bedrock/json-schema/amazon-bedrock-update-abtest-request-schema.json",
  "title": "UpdateABTestRequest",
  "x-generated": "2026-11-11",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/amazon-bedrock-ab-tests-api-openapi.yml#/components/schemas/UpdateABTestRequest",
  "type": "object",
  "properties": {
    "abTestId": {
      "type": "string",
      "description": "The unique identifier of the A/B test to update."
    },
    "clientToken": {
      "type": "string",
      "description": "A unique, case-sensitive identifier to ensure that the API request completes no more than one time. If this token matches a previous request, the service ignores the request, but does not return an error."
    },
    "name": {
      "type": "string",
      "description": "The updated name of the A/B test."
    },
    "description": {
      "type": "string",
      "description": "The updated description of the A/B test."
    },
    "variants": {
      "type": "array",
      "items": {
        "$ref": "#/$defs/Variant"
      },
      "description": "The updated list of variants."
    },
    "gatewayFilter": {
      "$ref": "#/$defs/GatewayFilter"
    },
    "evaluationConfig": {
      "$ref": "#/$defs/ABTestEvaluationConfig"
    },
    "roleArn": {
      "type": "string",
      "description": "The updated IAM role ARN."
    },
    "executionStatus": {
      "type": "string",
      "enum": [
        "PAUSED",
        "RUNNING",
        "STOPPED",
        "NOT_STARTED"
      ],
      "description": "The updated execution status to enable or disable the A/B test."
    }
  },
  "required": [
    "abTestId"
  ],
  "$defs": {
    "ABTestEvaluationConfig": {
      "type": "object",
      "properties": {
        "onlineEvaluationConfigArn": {
          "type": "string",
          "description": "The Amazon Resource Name (ARN) of a single online evaluation configuration to use for both variants."
        },
        "perVariantOnlineEvaluationConfig": {
          "type": "array",
          "items": {
            "$ref": "#/$defs/PerVariantOnlineEvaluationConfig"
          },
          "description": "Per-variant online evaluation configurations, allowing different evaluation settings for each variant."
        }
      },
      "description": "Exactly one member is set."
    },
    "ConfigurationBundleRef": {
      "type": "object",
      "properties": {
        "bundleArn": {
          "type": "string",
          "description": "The Amazon Resource Name (ARN) of the configuration bundle."
        },
        "bundleVersion": {
          "type": "string",
          "description": "The version of the configuration bundle."
        }
      },
      "required": [
        "bundleArn",
        "bundleVersion"
      ]
    },
    "GatewayFilter": {
      "type": "object",
      "properties": {
        "targetPaths": {
          "type": "array",
          "items": {
            "type": "string"
          },
          "description": "A list of target path patterns to include in the A/B test."
        }
      }
    },
    "PerVariantOnlineEvaluationConfig": {
      "type": "object",
      "properties": {
        "name": {
          "type": "string",
          "description": "The name of the variant this evaluation configuration applies to."
        },
        "onlineEvaluationConfigArn": {
          "type": "string",
          "description": "The Amazon Resource Name (ARN) of the online evaluation configuration for this variant."
        }
      },
      "required": [
        "name",
        "onlineEvaluationConfigArn"
      ]
    },
    "TargetRef": {
      "type": "object",
      "properties": {
        "name": {
          "type": "string",
          "description": "The name of the gateway target."
        }
      },
      "required": [
        "name"
      ]
    },
    "Variant": {
      "type": "object",
      "properties": {
        "name": {
          "type": "string",
          "description": "The name of the variant. Must be C for control or T1 for treatment."
        },
        "weight": {
          "type": "integer",
          "description": "The percentage of traffic to route to this variant. Weights across all variants must sum to 100."
        },
        "variantConfiguration": {
          "$ref": "#/$defs/VariantConfiguration"
        }
      },
      "required": [
        "name",
        "weight",
        "variantConfiguration"
      ]
    },
    "VariantConfiguration": {
      "type": "object",
      "properties": {
        "configurationBundle": {
          "$ref": "#/$defs/ConfigurationBundleRef"
        },
        "target": {
          "$ref": "#/$defs/TargetRef"
        }
      }
    }
  }
}