{
  "type": "record",
  "Aspect": {
    "name": "corpGroupSettings"
  },
  "name": "CorpGroupSettings",
  "namespace": "com.linkedin.pegasus2avro.identity",
  "fields": [
    {
      "type": [
        "null",
        {
          "type": "record",
          "name": "NotificationSettings",
          "namespace": "com.linkedin.pegasus2avro.event.notification.settings",
          "fields": [
            {
              "type": {
                "type": "array",
                "items": {
                  "type": "enum",
                  "symbolDocs": {
                    "EMAIL": "Email target type.",
                    "SLACK": "Slack target type.",
                    "TEAMS": "Microsoft Teams target type."
                  },
                  "name": "NotificationSinkType",
                  "namespace": "com.linkedin.pegasus2avro.event.notification",
                  "symbols": [
                    "SLACK",
                    "EMAIL",
                    "TEAMS"
                  ],
                  "doc": "A type of sink / platform to send a notification to."
                }
              },
              "name": "sinkTypes",
              "doc": "Sink types that notifications are sent to. This is a top-level on/off switch."
            },
            {
              "type": [
                "null",
                {
                  "type": "record",
                  "name": "SlackNotificationSettings",
                  "namespace": "com.linkedin.pegasus2avro.event.notification.settings",
                  "fields": [
                    {
                      "type": [
                        "null",
                        {
                          "type": "record",
                          "name": "SlackUser",
                          "namespace": "com.linkedin.pegasus2avro.settings.global",
                          "fields": [
                            {
                              "Searchable": {
                                "fieldType": "KEYWORD",
                                "queryByDefault": false
                              },
                              "type": [
                                "null",
                                "string"
                              ],
                              "name": "slackUserId",
                              "default": null,
                              "doc": "The Slack user ID (Slack member UUID).\nThis is the primary identifier used for Slack messaging via DM.\nSearchable to enable lookup of DataHub users by their Slack ID."
                            },
                            {
                              "type": [
                                "null",
                                "string"
                              ],
                              "name": "email",
                              "default": null,
                              "doc": "The user's email address (fallback identifier).\nUsed when Slack user ID is not available or for email-based user resolution."
                            },
                            {
                              "type": [
                                "null",
                                "string"
                              ],
                              "name": "displayName",
                              "default": null,
                              "doc": "The user's display name (cached value, may be stale).\nRetrieved from Slack API and cached for performance."
                            },
                            {
                              "type": [
                                "null",
                                "long"
                              ],
                              "name": "lastUpdated",
                              "default": null,
                              "doc": "The timestamp when the cached display name was last updated.\nUsed for TTL-based cache invalidation (milliseconds since epoch)."
                            }
                          ],
                          "doc": "Slack user information with cached display name and multiple ID support.\nFollows the same caching pattern as TeamsUser for consistency."
                        }
                      ],
                      "name": "user",
                      "default": null,
                      "doc": "Optional structured user information with cached metadata.\nSupports Slack user ID with cached display name and email."
                    },
                    {
                      "deprecated": true,
                      "type": [
                        "null",
                        "string"
                      ],
                      "name": "userHandle",
                      "default": null,
                      "doc": "Optional user handle (deprecated - use 'user' field instead).\nKept for backward compatibility with existing implementations."
                    },
                    {
                      "type": [
                        "null",
                        {
                          "type": "array",
                          "items": "string"
                        }
                      ],
                      "name": "channels",
                      "default": null,
                      "doc": "Optional list of channels to send notifications to"
                    }
                  ],
                  "doc": "Slack Notification settings for an actor."
                }
              ],
              "name": "slackSettings",
              "default": null,
              "doc": "Slack Notification Settings"
            },
            {
              "type": [
                "null",
                {
                  "type": "record",
                  "name": "EmailNotificationSettings",
                  "namespace": "com.linkedin.pegasus2avro.event.notification.settings",
                  "fields": [
                    {
                      "type": "string",
                      "name": "email",
                      "doc": "Optional user or group email address"
                    }
                  ],
                  "doc": "Email Notification settings for an actor."
                }
              ],
              "name": "emailSettings",
              "default": null,
              "doc": "Email Notification Settings"
            },
            {
              "type": [
                "null",
                {
                  "type": "record",
                  "name": "TeamsNotificationSettings",
                  "namespace": "com.linkedin.pegasus2avro.event.notification.settings",
                  "fields": [
                    {
                      "type": [
                        "null",
                        {
                          "type": "record",
                          "name": "TeamsUser",
                          "namespace": "com.linkedin.pegasus2avro.settings.global",
                          "fields": [
                            {
                              "type": [
                                "null",
                                "string"
                              ],
                              "name": "teamsUserId",
                              "default": null,
                              "doc": "The Teams user ID (internal Teams identifier).\nThis is the primary identifier used for Teams messaging."
                            },
                            {
                              "Searchable": {
                                "fieldType": "KEYWORD",
                                "queryByDefault": false
                              },
                              "type": [
                                "null",
                                "string"
                              ],
                              "name": "azureUserId",
                              "default": null,
                              "doc": "The Azure AD user ID (Azure Active Directory object ID).\nThis is the primary identifier for Azure AD operations and Microsoft Graph API calls."
                            },
                            {
                              "type": [
                                "null",
                                "string"
                              ],
                              "name": "email",
                              "default": null,
                              "doc": "The user's email address (fallback identifier).\nUsed when other IDs are not available or for email-based user resolution."
                            },
                            {
                              "type": [
                                "null",
                                "string"
                              ],
                              "name": "displayName",
                              "default": null,
                              "doc": "The user's display name (cached value, may be stale).\nRetrieved from Microsoft Graph API and cached for performance."
                            },
                            {
                              "type": [
                                "null",
                                "long"
                              ],
                              "name": "lastUpdated",
                              "default": null,
                              "doc": "The timestamp when the cached display name was last updated.\nUsed for TTL-based cache invalidation (milliseconds since epoch)."
                            }
                          ],
                          "doc": "Teams user information with cached display name and multiple ID support.\nFollows the same caching pattern as TeamsChannel for consistency."
                        }
                      ],
                      "name": "user",
                      "default": null,
                      "doc": "Optional structured user information with cached metadata.\nSupports both Azure AD user ID and Teams user ID with cached display name."
                    },
                    {
                      "type": [
                        "null",
                        {
                          "type": "array",
                          "items": {
                            "type": "record",
                            "name": "TeamsChannel",
                            "namespace": "com.linkedin.pegasus2avro.settings.global",
                            "fields": [
                              {
                                "type": "string",
                                "name": "id",
                                "doc": "The Teams channel ID (internal Teams identifier)."
                              },
                              {
                                "type": [
                                  "null",
                                  "string"
                                ],
                                "name": "name",
                                "default": null,
                                "doc": "The Teams channel display name (cached value, may be stale)."
                              },
                              {
                                "type": [
                                  "null",
                                  "long"
                                ],
                                "name": "lastUpdated",
                                "default": null,
                                "doc": "The timestamp when the cached name was last updated.\nUsed for TTL-based cache invalidation."
                              }
                            ],
                            "doc": "Teams channel information with cached display name."
                          }
                        }
                      ],
                      "name": "channels",
                      "default": null,
                      "doc": "Optional list of structured channels with cached metadata"
                    }
                  ],
                  "doc": "Microsoft Teams Notification settings for an actor."
                }
              ],
              "name": "teamsSettings",
              "default": null,
              "doc": "Microsoft Teams Notification Settings"
            },
            {
              "type": [
                "null",
                {
                  "type": "map",
                  "values": {
                    "type": "record",
                    "name": "NotificationSetting",
                    "namespace": "com.linkedin.pegasus2avro.settings",
                    "fields": [
                      {
                        "type": {
                          "type": "enum",
                          "symbolDocs": {
                            "DISABLED": "Setting is disabled.",
                            "ENABLED": "Setting is enabled."
                          },
                          "name": "NotificationSettingValue",
                          "namespace": "com.linkedin.pegasus2avro.settings",
                          "symbols": [
                            "ENABLED",
                            "DISABLED"
                          ]
                        },
                        "name": "value",
                        "doc": "Integrations between DataHub & other platforms."
                      },
                      {
                        "type": [
                          "null",
                          {
                            "type": "map",
                            "values": "string"
                          }
                        ],
                        "name": "params",
                        "default": null,
                        "doc": "Custom set of setting parameters.\nCurrently used to store sink enabled / disabled settings.\nE.g. slack.enabled = true, email.enabled = false"
                      }
                    ]
                  }
                }
              ],
              "name": "settings",
              "default": null,
              "doc": "User or Group Notification Scenario Settings.\n\nA map of notification scenario type to the settings associated with it.\nFor a list of all scenario types to notify on, check out NotificationScenarioType enum."
            }
          ],
          "doc": "Notification settings for an actor or subscription."
        }
      ],
      "name": "notificationSettings",
      "default": null,
      "doc": "Notification settings for a group"
    }
  ],
  "doc": "Settings that a group can customize through the DataHub UI"
}