{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/amazon-q/json-schema/amazon-q-associate-permission-request-schema.json",
  "title": "AssociatePermissionRequest",
  "x-generated": "2026-11-11",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/amazon-q-policy-api-openapi.yml#/components/schemas/AssociatePermissionRequest",
  "type": "object",
  "properties": {
    "applicationId": {
      "type": "string",
      "description": "The unique identifier of the Amazon Q Business application."
    },
    "statementId": {
      "type": "string",
      "description": "A unique identifier for the policy statement."
    },
    "actions": {
      "type": "array",
      "items": {
        "type": "string"
      },
      "description": "The list of Amazon Q Business actions that the ISV is allowed to perform."
    },
    "conditions": {
      "type": "array",
      "items": {
        "$ref": "#/$defs/PermissionCondition"
      },
      "description": "The conditions that restrict when the permission is effective. These conditions can be used to limit the permission based on specific attributes of the request."
    },
    "principal": {
      "type": "string",
      "description": "The Amazon Resource Name of the IAM role for the ISV that is being granted permission."
    }
  },
  "required": [
    "applicationId",
    "statementId",
    "actions",
    "principal"
  ],
  "$defs": {
    "PermissionCondition": {
      "type": "object",
      "properties": {
        "conditionOperator": {
          "type": "string",
          "enum": [
            "StringEquals"
          ],
          "description": "The operator to use for the condition evaluation. This determines how the condition values are compared."
        },
        "conditionKey": {
          "type": "string",
          "description": "The key for the condition. This identifies the attribute that the condition applies to."
        },
        "conditionValues": {
          "type": "array",
          "items": {
            "type": "string"
          },
          "description": "The values to compare against using the specified condition operator."
        }
      },
      "required": [
        "conditionOperator",
        "conditionKey",
        "conditionValues"
      ]
    }
  }
}