{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/amazon-incident-manager/json-schema/amazon-incident-manager-update-related-items-input-schema.json",
  "title": "UpdateRelatedItemsInput",
  "x-generated": "2026-11-11",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/amazon-incident-manager-update-related-items-api-openapi.yml#/components/schemas/UpdateRelatedItemsInput",
  "type": "object",
  "properties": {
    "clientToken": {
      "type": "string",
      "description": "A token that ensures that a client calls the operation only once with the specified details."
    },
    "incidentRecordArn": {
      "type": "string",
      "description": "The Amazon Resource Name (ARN) of the incident record that contains the related items that you update."
    },
    "relatedItemsUpdate": {
      "$ref": "#/$defs/RelatedItemsUpdate"
    }
  },
  "required": [
    "incidentRecordArn",
    "relatedItemsUpdate"
  ],
  "$defs": {
    "ItemIdentifier": {
      "type": "object",
      "properties": {
        "value": {
          "$ref": "#/$defs/ItemValue"
        },
        "type": {
          "type": "string",
          "description": "The type of related item."
        }
      },
      "required": [
        "value",
        "type"
      ]
    },
    "ItemValue": {
      "type": "object",
      "properties": {
        "arn": {
          "type": "string",
          "description": "The Amazon Resource Name (ARN) of the related item, if the related item is an Amazon resource."
        },
        "url": {
          "type": "string",
          "description": "The URL, if the related item is a non-Amazon Web Services resource."
        },
        "metricDefinition": {
          "type": "string",
          "description": "The metric definition, if the related item is a metric in Amazon CloudWatch."
        },
        "pagerDutyIncidentDetail": {
          "$ref": "#/$defs/PagerDutyIncidentDetail"
        }
      },
      "description": "Exactly one member is set."
    },
    "PagerDutyIncidentDetail": {
      "type": "object",
      "properties": {
        "id": {
          "type": "string",
          "description": "The ID of the incident associated with the PagerDuty service for the response plan."
        },
        "autoResolve": {
          "type": "boolean",
          "description": "Indicates whether to resolve the PagerDuty incident when you resolve the associated Incident Manager incident."
        },
        "secretId": {
          "type": "string",
          "description": "The ID of the Amazon Web Services Secrets Manager secret that stores your PagerDuty key, either a General Access REST API Key or User Token REST API Key, and other user credentials."
        }
      },
      "required": [
        "id"
      ]
    },
    "RelatedItem": {
      "type": "object",
      "properties": {
        "identifier": {
          "$ref": "#/$defs/ItemIdentifier"
        },
        "title": {
          "type": "string",
          "description": "The title of the related item."
        },
        "generatedId": {
          "type": "string",
          "description": "A unique ID for a RelatedItem. Don't specify this parameter when you add a RelatedItem by using the UpdateRelatedItems API action."
        }
      },
      "required": [
        "identifier"
      ]
    },
    "RelatedItemsUpdate": {
      "type": "object",
      "properties": {
        "itemToAdd": {
          "$ref": "#/$defs/RelatedItem"
        },
        "itemToRemove": {
          "$ref": "#/$defs/ItemIdentifier"
        }
      },
      "description": "Exactly one member is set."
    }
  }
}