{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://artifacts.apis.io/amazon-q/json-schema/amazon-q-create-subscription-request-schema.json",
  "title": "CreateSubscriptionRequest",
  "x-generated": "2026-11-11",
  "x-method": "derived",
  "x-generator": "derive-json-schema.py",
  "x-source": "openapi/amazon-q-subscriptions-api-openapi.yml#/components/schemas/CreateSubscriptionRequest",
  "type": "object",
  "properties": {
    "applicationId": {
      "type": "string",
      "description": "The identifier of the Amazon Q Business application the subscription should be added to."
    },
    "principal": {
      "$ref": "#/$defs/SubscriptionPrincipal"
    },
    "type": {
      "type": "string",
      "enum": [
        "Q_LITE",
        "Q_BUSINESS"
      ],
      "description": "The type of Amazon Q Business subscription you want to create."
    },
    "clientToken": {
      "type": "string",
      "description": "A token that you provide to identify the request to create a subscription for your Amazon Q Business application."
    }
  },
  "required": [
    "applicationId",
    "principal",
    "type"
  ],
  "$defs": {
    "SubscriptionPrincipal": {
      "type": "object",
      "properties": {
        "user": {
          "type": "string",
          "description": "The identifier of a user in the IAM Identity Center instance connected to the Amazon Q Business application."
        },
        "group": {
          "type": "string",
          "description": "The identifier of a group in the IAM Identity Center instance connected to the Amazon Q Business application."
        }
      },
      "description": "Exactly one member is set."
    }
  }
}