{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://catalog.lintel.tools/schemas/schemastore/swadl/latest.json",
  "description": "SWADL (Symphony Workflow Automation Definition Language) is a language to describe workflows on Symphony.",
  "x-lintel": {
    "source": "https://raw.githubusercontent.com/SymphonyPlatformSolutions/symphony-wdk/master/workflow-language/src/main/resources/swadl-schema-1.0.json",
    "sourceSha256": "06b00c7d6600fc8ba3ab6732cab7f6a588c03c61293f4260bdb708d8c1522053",
    "fileMatch": [
      "*.swadl.yaml",
      "*.swadl.yml"
    ],
    "parsers": [
      "yaml"
    ]
  },
  "type": "object",
  "properties": {
    "id": {
      "type": "string",
      "description": "Workflow's id should start with a letter. It is optional. If no id is provided, the workflow filename is used. Otherwise, it will be generated. The id will appear in logs and audit trails.",
      "pattern": "^[a-zA-Z]+[a-zA-Z0-9][^ ]*$",
      "default": "my-workflow",
      "maxLength": 100
    },
    "properties": {
      "type": "object",
      "description": "Some metadata about the workflow",
      "properties": {
        "publish": {
          "type": [
            "boolean",
            "string"
          ],
          "description": "Should the workflow be published or not, true publish, false otherwise",
          "default": true
        }
      }
    },
    "variables": {
      "type": "object",
      "description": "Variables are accessible and editable within the entire workflow. A map of key: value entries is expected."
    },
    "activities": {
      "type": "array",
      "minLength": 1,
      "description": "A list of activities to be executed by the workflow. By default the execution is sequential but complex logic can be orchestrated with if/else conditions as well as on/activity-completed events.",
      "$comment": "Defined like this to support both validation and autocompletion, even with custom activities. Last item is removed on the fly during validation and replaced by known custom activities.",
      "items": {
        "type": "object",
        "additionalProperties": false,
        "properties": {
          "create-room": {
            "description": "Creates a new chatroom.",
            "x-intellij-html-description": "<html><p>Creates a new chatroom.\n</p><a href=\"https://developers.symphony.com/restapi/reference#create-room-v3\">https://developers.symphony.com/restapi/reference#create-room-v3</a></html>",
            "allOf": [
              {
                "$ref": "#/$defs/basic-activity-inner"
              },
              {
                "$ref": "#/$defs/create-room-inner"
              }
            ]
          },
          "update-room": {
            "description": "Updates the attributes of an existing chat room.",
            "x-intellij-html-description": "<html><p>Updates the attributes of an existing chat room.\n</p><a href=\"https://developers.symphony.com/restapi/reference#update-room-v3\">https://developers.symphony.com/restapi/reference#update-room-v3</a></html>",
            "allOf": [
              {
                "$ref": "#/$defs/basic-activity-inner"
              },
              {
                "$ref": "#/$defs/update-room-inner"
              }
            ]
          },
          "add-room-member": {
            "description": "Adds new members to an existing room.",
            "x-intellij-html-description": "<html><p>Adds a new members to an existing room.\n</p><a href=\"https://developers.symphony.com/restapi/reference#add-member\">https://developers.symphony.com/restapi/reference#add-member</a></html>",
            "allOf": [
              {
                "$ref": "#/$defs/basic-activity-inner"
              },
              {
                "$ref": "#/$defs/add-room-member-inner"
              }
            ]
          },
          "remove-room-member": {
            "description": "Removes members from an existing room.",
            "x-intellij-html-description": "<html><p>Removes members from an existing room.\n</p><a href=\"https://developers.symphony.com/restapi/reference#remove-member\">https://developers.symphony.com/restapi/reference#remove-member</a></html>",
            "allOf": [
              {
                "$ref": "#/$defs/basic-activity-inner"
              },
              {
                "$ref": "#/$defs/remove-room-member-inner"
              }
            ]
          },
          "promote-room-owner": {
            "description": "Promotes user to owner of the chat room.",
            "x-intellij-html-description": "<html><p>Promotes user to owner of the chat room.\n</p><a href=\"https://developers.symphony.com/restapi/reference#promote-owner\">https://developers.symphony.com/restapi/reference#promote-owner</a></html>",
            "allOf": [
              {
                "$ref": "#/$defs/basic-activity-inner"
              },
              {
                "$ref": "#/$defs/promote-room-owner-inner"
              }
            ]
          },
          "demote-room-owner": {
            "description": "Demotes room owner to a participant in the chat room.",
            "x-intellij-html-description": "<html><p>Demotes room owner to a participant in the chat room.</p><a href=\"https://developers.symphony.com/restapi/reference#demote-owner\">https://developers.symphony.com/restapi/reference#demote-owner</a></html>",
            "allOf": [
              {
                "$ref": "#/$defs/basic-activity-inner"
              },
              {
                "$ref": "#/$defs/demote-room-owner-inner"
              }
            ]
          },
          "send-message": {
            "description": "Posts a message to a stream.",
            "x-intellij-html-description": "<html><p>Posts a message to a stream.</p><a href=\"https://developers.symphony.com/restapi/reference#create-message-v4\">https://developers.symphony.com/restapi/reference#create-message-v4</a></html>",
            "allOf": [
              {
                "$ref": "#/$defs/basic-activity-inner"
              },
              {
                "$ref": "#/$defs/send-message-inner"
              }
            ]
          },
          "update-message": {
            "description": "Updates an existing message into a stream.",
            "x-intellij-html-description": "<html><p>Updates an existing message into a stream.</p><a href=\"https://developers.symphony.com/restapi/reference#update-message-v4\">https://developers.symphony.com/restapi/reference#update-message-v4</a></html>",
            "allOf": [
              {
                "$ref": "#/$defs/basic-activity-inner"
              },
              {
                "$ref": "#/$defs/update-message-inner"
              }
            ]
          },
          "pin-message": {
            "description": "Pin an existing message into the stream it belongs to.",
            "x-intellij-html-description": "<html><p>Pin an existing message into the stream it belongs to.<a href=\"https://developers.symphony.com/restapi/reference#update-room-v3\">https://developers.symphony.com/restapi/reference#update-room-v3</a><a href=\"https://developers.symphony.com/restapi/v20.13/reference#update-im\">(https://developers.symphony.com/restapi/v20.13/reference#update-im</a></html>",
            "allOf": [
              {
                "$ref": "#/$defs/basic-activity-inner"
              },
              {
                "$ref": "#/$defs/pin-message-inner"
              }
            ]
          },
          "unpin-message": {
            "description": "Unpin any message (if present) from an existing stream.",
            "x-intellij-html-description": "<html><p>Unpin any message (if present) from an existing stream.</p><a href=\"https://developers.symphony.com/restapi/reference#update-room-v3\">https://developers.symphony.com/restapi/reference#update-room-v3</a><a href=\"https://developers.symphony.com/restapi/v20.13/reference#update-im\">(https://developers.symphony.com/restapi/v20.13/reference#update-im</a></html>",
            "allOf": [
              {
                "$ref": "#/$defs/basic-activity-inner"
              },
              {
                "$ref": "#/$defs/unpin-message-inner"
              }
            ]
          },
          "get-attachment": {
            "description": "Gets one attachment and stores it locally.",
            "x-intellij-html-description": "<html><p>Gets one attachment and stores it locally.</p><a href=\"https://developers.symphony.com/restapi/reference#attachment\">https://developers.symphony.com/restapi/reference#attachment</a></html>",
            "allOf": [
              {
                "$ref": "#/$defs/basic-activity-inner"
              },
              {
                "$ref": "#/$defs/get-attachment-inner"
              }
            ]
          },
          "debug": {
            "description": "Standard debug activity.",
            "x-intellij-html-description": "<html><p>Standard debug activity.</p></html>",
            "type": "object",
            "properties": {
              "id": {
                "description": "Activity's identifier, should be unique across workflow. As it can be used as a variable identifier only alphanumerical characters are allowed.",
                "type": "string",
                "$comment": "variables is forbidden to avoid conflict with variables.output... that would override the workflows variables",
                "pattern": "^(?!variables$)([a-zA-Z][a-zA-Z0-9_]+)$"
              },
              "on": {
                "$ref": "#/$defs/on"
              },
              "if": {
                "description": "Conditional execution of the activity based on a boolean expression.",
                "type": "string"
              },
              "else": {
                "description": "Default execution of the activity when if conditions are used for previous activities.",
                "type": "object"
              },
              "object": {
                "type": [
                  "object",
                  "string"
                ]
              }
            },
            "required": [
              "object"
            ]
          },
          "execute-script": {
            "description": "Executes a Groovy script.",
            "x-intellij-html-description": "<html><p>Executes a Groovy script.</p></html>",
            "allOf": [
              {
                "$ref": "#/$defs/basic-activity-inner"
              },
              {
                "$ref": "#/$defs/execute-script-inner"
              }
            ]
          },
          "execute-request": {
            "description": "Executes an HTTP request.",
            "allOf": [
              {
                "$ref": "#/$defs/basic-activity-inner"
              },
              {
                "$ref": "#/$defs/execute-request-inner"
              }
            ]
          },
          "create-user": {
            "description": "Creates a new end user.",
            "x-intellij-html-description": "<html><p>Creates a new end user.</p><a href=\"https://developers.symphony.com/restapi/reference#create-user-v2\">https://developers.symphony.com/restapi/reference#create-user-v2</a></html>",
            "allOf": [
              {
                "$ref": "#/$defs/basic-activity-inner"
              },
              {
                "$ref": "#/$defs/create-user-inner",
                "required": [
                  "email",
                  "username",
                  "firstname",
                  "lastname",
                  "display-name"
                ]
              }
            ]
          },
          "update-user": {
            "description": "Updates an existing end user.",
            "x-intellij-html-description": "<html><p>Updates an existing end user.</p><a href=\"https://developers.symphony.com/restapi/reference#update-user-v2\">https://developers.symphony.com/restapi/reference#update-user-v2</a></html>",
            "allOf": [
              {
                "$ref": "#/$defs/basic-activity-inner"
              },
              {
                "$ref": "#/$defs/create-user-inner"
              },
              {
                "type": "object",
                "properties": {
                  "user-id": {
                    "$ref": "#/$defs/user-id"
                  }
                },
                "required": [
                  "user-id"
                ]
              }
            ]
          },
          "create-system-user": {
            "description": "Creates a new service user.",
            "x-intellij-html-description": "<html><p>Creates a new service user.</p><a href=\"https://developers.symphony.com/restapi/reference#create-user-v2\">https://developers.symphony.com/restapi/reference#create-user-v2</a></html>",
            "allOf": [
              {
                "$ref": "#/$defs/basic-activity-inner"
              },
              {
                "$ref": "#/$defs/create-system-user-inner",
                "required": [
                  "email",
                  "username",
                  "display-name"
                ]
              }
            ]
          },
          "update-system-user": {
            "description": "Updates an existing service user.",
            "x-intellij-html-description": "<html><p>Updates an existing service user.</p><a href=\"https://developers.symphony.com/restapi/reference#update-user-v2\">https://developers.symphony.com/restapi/reference#update-user-v2</a></html>",
            "allOf": [
              {
                "$ref": "#/$defs/basic-activity-inner"
              },
              {
                "$ref": "#/$defs/create-system-user-inner"
              },
              {
                "type": "object",
                "properties": {
                  "user-id": {
                    "$ref": "#/$defs/user-id"
                  }
                },
                "required": [
                  "user-id"
                ]
              }
            ]
          },
          "add-user-role": {
            "description": "Adds roles to user accounts.",
            "x-intellij-html-description": "<html><p>Adds a role or optional entitleable action to a user’s account.</p><a href=\"https://developers.symphony.com/restapi/reference#add-role\">https://developers.symphony.com/restapi/reference#add-role</a></html>",
            "allOf": [
              {
                "$ref": "#/$defs/basic-activity-inner"
              },
              {
                "$ref": "#/$defs/user-role-inner"
              }
            ]
          },
          "remove-user-role": {
            "description": "Removes roles from user accounts.",
            "x-intellij-html-description": "<html><p>Removes a role or optional entitleable action from a user’s account.</p><a href=\"https://developers.symphony.com/restapi/reference#remove-role\">https://developers.symphony.com/restapi/reference#remove-role</a></html>",
            "allOf": [
              {
                "$ref": "#/$defs/basic-activity-inner"
              },
              {
                "$ref": "#/$defs/user-role-inner"
              }
            ]
          },
          "get-user": {
            "description": "Returns details for a particular user.",
            "x-intellij-html-description": "<html><p>Returns details for a particular user.</p><a href=\"https://developers.symphony.com/restapi/reference#get-user-v2\">https://developers.symphony.com/restapi/reference#get-user-v2</a></html>",
            "type": "object",
            "allOf": [
              {
                "$ref": "#/$defs/basic-activity-inner"
              },
              {
                "$ref": "#/$defs/get-user-inner"
              }
            ]
          },
          "get-users": {
            "description": "Returns a list of users ID, including user metadata.",
            "x-intellij-html-description": "<html><p>Returns a list of users ID, including user metadata.</p><a href=\"https://developers.symphony.com/restapi/reference#users-lookup-v3\">https://developers.symphony.com/restapi/reference#users-lookup-v3</a></html>",
            "type": "object",
            "allOf": [
              {
                "$ref": "#/$defs/basic-activity-inner"
              },
              {
                "$ref": "#/$defs/get-users-inner"
              }
            ]
          },
          "get-stream": {
            "type": "object",
            "description": "Returns information about a particular stream.",
            "x-intellij-html-description": "<htmL><p>Returns information about a particular stream.</p><a href=\"https://developers.symphony.com/restapi/reference#stream-info-v2\">https://developers.symphony.com/restapi/reference#stream-info-v2</a></html",
            "allOf": [
              {
                "$ref": "#/$defs/basic-activity-inner"
              },
              {
                "$ref": "#/$defs/get-stream-inner"
              }
            ]
          },
          "get-room": {
            "type": "object",
            "description": "Returns information about a particular chat room.",
            "x-intellij-html-description": "<html><p>Returns information about a particular chat room.</p><a href=\"https://developers.symphony.com/restapi/reference#room-info-v3\">https://developers.symphony.com/restapi/reference#room-info-v3</a></html>",
            "allOf": [
              {
                "$ref": "#/$defs/basic-activity-inner"
              },
              {
                "$ref": "#/$defs/get-room-inner"
              }
            ]
          },
          "get-message": {
            "type": "object",
            "description": "Returns a message found by id.",
            "x-intellij-html-description": "<html><p>Returns a message found by id.</p><a href=\"https://developers.symphony.com/restapi/reference#get-message-v1\">https://developers.symphony.com/restapi/reference#get-message-v1</html>",
            "allOf": [
              {
                "$ref": "#/$defs/basic-activity-inner"
              },
              {
                "$ref": "#/$defs/get-message-inner"
              }
            ]
          },
          "get-stream-members": {
            "type": "object",
            "description": "Returns a list of all the current members of a stream (IM, MIM, or chatroom).",
            "x-intellij-html-description": "<html><p>Returns a list of all the current members of a stream (IM, MIM, or chatroom).</p><a href=\"https://developers.symphony.com/restapi/reference#stream-members\">https://developers.symphony.com/restapi/reference#stream-members</a></html>",
            "allOf": [
              {
                "$ref": "#/$defs/basic-activity-inner"
              },
              {
                "$ref": "#/$defs/get-stream-members-inner"
              }
            ]
          },
          "get-room-members": {
            "type": "object",
            "description": "Lists the current members of an existing room.",
            "x-intellij-html-description": "<html><p>Lists the current members of an existing room.</p><a href=\"https://developers.symphony.com/restapi/reference#room-members\">https://developers.symphony.com/restapi/reference#room-members</a></html>",
            "allOf": [
              {
                "$ref": "#/$defs/basic-activity-inner"
              },
              {
                "$ref": "#/$defs/get-room-members-inner"
              }
            ]
          },
          "get-user-streams": {
            "type": "object",
            "description": "Returns a list of all the streams of which the requesting user is a member, sorted by creation date (ascending - oldest to newest).",
            "x-intellij-html-description": "<html><p>Returns a list of all the streams of which the requesting user is a member, sorted by creation date (ascending - oldest to newest).</p><a href=\"https://developers.symphony.com/restapi/reference#list-user-streams\">https://developers.symphony.com/restapi/reference#list-user-streams</a></html>",
            "allOf": [
              {
                "$ref": "#/$defs/basic-activity-inner"
              },
              {
                "$ref": "#/$defs/get-user-streams-inner"
              }
            ]
          },
          "get-streams": {
            "type": "object",
            "description": "Returns a list of all the streams (IMs, MIMs, and chatrooms) for the calling user's company, sorted by creation date (ascending – oldest to newest).",
            "x-intellij-html-description": "<html><p>Returns a list of all the streams (IMs, MIMs, and chatrooms) for the calling user's company, sorted by creation date (ascending – oldest to newest).</p><a href\"https://developers.symphony.com/restapi/reference#list-streams-for-enterprise-v2\">https://developers.symphony.com/restapi/reference#list-streams-for-enterprise-v2</a></html>",
            "allOf": [
              {
                "$ref": "#/$defs/basic-activity-inner"
              },
              {
                "$ref": "#/$defs/get-streams-inner"
              }
            ]
          },
          "get-connection": {
            "type": "object",
            "description": "Get one connection status.",
            "x-intellij-html-description": "<html><p>Get one connection status.</p><a href=\"https://developers.symphony.com/restapi/reference#get-connection\">https://developers.symphony.com/restapi/reference#get-connection</a></html>",
            "allOf": [
              {
                "$ref": "#/$defs/basic-activity-inner"
              },
              {
                "$ref": "#/$defs/connection-inner"
              }
            ]
          },
          "create-connection": {
            "type": "object",
            "description": "Send a connection request to another user.",
            "x-intellij-html-description": "<html><p>Send a connection request to another user.</p><a href=\"https://developers.symphony.com/restapi/reference#create-connection\">https://developers.symphony.com/restapi/reference#create-connection</a></html>",
            "allOf": [
              {
                "$ref": "#/$defs/basic-activity-inner"
              },
              {
                "$ref": "#/$defs/connection-inner"
              }
            ]
          },
          "accept-connection": {
            "type": "object",
            "description": "Accept the connection request for a requesting user.",
            "x-intellij-html-description": "<html><p>Accept the connection request for a requesting user.</p><a href=\"https://developers.symphony.com/restapi/reference#accepted-connection\">https://developers.symphony.com/restapi/reference#accepted-connection</a></html>",
            "allOf": [
              {
                "$ref": "#/$defs/basic-activity-inner"
              },
              {
                "$ref": "#/$defs/connection-inner"
              }
            ]
          },
          "reject-connection": {
            "type": "object",
            "description": "Reject the connection request from a requesting user.",
            "x-intellij-html-description": "<html><p>Reject the connection request from a requesting user.</p><a href=\"https://developers.symphony.com/restapi/reference#reject-connection\">https://developers.symphony.com/restapi/reference#reject-connection</a></html>",
            "allOf": [
              {
                "$ref": "#/$defs/basic-activity-inner"
              },
              {
                "$ref": "#/$defs/connection-inner"
              }
            ]
          },
          "remove-connection": {
            "type": "object",
            "description": "Remove a connection with a user.",
            "x-intellij-html-description": "<html><p>Remove a connection with a user.</p><a href=\"https://developers.symphony.com/restapi/reference#remove-connection\">https://developers.symphony.com/restapi/reference#remove-connection</a></html>",
            "allOf": [
              {
                "$ref": "#/$defs/basic-activity-inner"
              },
              {
                "$ref": "#/$defs/connection-inner"
              }
            ]
          },
          "get-rooms": {
            "type": "object",
            "description": "Search for rooms, querying name, description, and specified keywords.",
            "x-intellij-html-description": "<html><p>Search for rooms, querying name, description, and specified keywords.</p><a href=\"https://developers.symphony.com/restapi/reference#search-rooms-v3\">https://developers.symphony.com/restapi/reference#search-rooms-v3</a></html>",
            "allOf": [
              {
                "$ref": "#/$defs/basic-activity-inner"
              },
              {
                "$ref": "#/$defs/get-rooms-inner"
              }
            ]
          },
          "get-messages": {
            "type": "object",
            "description": "Get messages from an existing stream (IM, MIM, or chatroom).\nAdditionally returns any attachments associated with the message.",
            "x-intellij-html-description": "<html><p>Get messages from an existing stream (IM, MIM, or chatroom).\nAdditionally returns any attachments associated with the message.</p><a href=\"https://developers.symphony.com/restapi/reference#messages-v4\">https://developers.symphony.com/restapi/reference#messages-v4</a></html>",
            "allOf": [
              {
                "$ref": "#/$defs/basic-activity-inner"
              },
              {
                "$ref": "#/$defs/get-messages-inner"
              }
            ]
          },
          "get-connections": {
            "type": "object",
            "description": "Get one or multiple connections statuses",
            "x-intellij-html-description": "<html><p>Get one or multiple connections statuses</p><a href=\"https://developers.symphony.com/restapi/reference#list-connections\">https://developers.symphony.com/restapi/reference#list-connections</a></html>",
            "allOf": [
              {
                "$ref": "#/$defs/basic-activity-inner"
              },
              {
                "$ref": "#/$defs/get-connections-inner"
              }
            ]
          },
          "create-group": {
            "type": "object",
            "description": "Create a group (distribution list)",
            "x-intellij-html-description": "<html><p>Create a group (distribution list)</p><a href=\"https://developers.symphony.com/restapi/reference/insertgroup\">https://developers.symphony.com/restapi/reference/insertgroup</a></html>",
            "allOf": [
              {
                "$ref": "#/$defs/basic-activity-inner"
              },
              {
                "$ref": "#/$defs/create-group-inner"
              }
            ],
            "required": [
              "name",
              "owner",
              "members",
              "profile"
            ]
          },
          "update-group": {
            "type": "object",
            "description": "Update a group (distribution list)",
            "x-intellij-html-description": "<html><p>Update a group (distribution list)</p><a href=\"https://developers.symphony.com/restapi/reference/updategroup\">https://developers.symphony.com/restapi/reference/updategroup</a></html>",
            "allOf": [
              {
                "$ref": "#/$defs/basic-activity-inner"
              },
              {
                "$ref": "#/$defs/create-group-inner"
              },
              {
                "type": "object",
                "$ref": "#/$defs/update-group-inner"
              }
            ]
          },
          "get-group": {
            "type": "object",
            "description": "Retrieve a group (distribution list)",
            "x-intellij-html-description": "<html><p>Retrieve a group (distribution list)</p><a href=\"https://developers.symphony.com/restapi/reference/getgroup\">https://developers.symphony.com/restapi/reference/getgroup</a></html>",
            "allOf": [
              {
                "$ref": "#/$defs/basic-activity-inner"
              },
              {
                "$ref": "#/$defs/get-group-inner"
              }
            ]
          },
          "get-groups": {
            "type": "object",
            "description": "Retrieve groups of specified type (distribution list)",
            "x-intellij-html-description": "<html><p>Retrieve groups of specified type (distribution list)</p><a href=\"https://developers.symphony.com/restapi/reference/listgroups\">https://developers.symphony.com/restapi/reference/listgroups</a></html>",
            "allOf": [
              {
                "$ref": "#/$defs/basic-activity-inner"
              },
              {
                "$ref": "#/$defs/get-groups-inner"
              }
            ]
          },
          "add-group-member": {
            "type": "object",
            "description": "Add members to a group (distribution list)",
            "x-intellij-html-description": "<html><p>Add members to a group (distribution list)</p><a href=\"https://developers.symphony.com/restapi/reference/addmembertogroup\">https://developers.symphony.com/restapi/reference/addmembertogroup</a></html>",
            "allOf": [
              {
                "$ref": "#/$defs/basic-activity-inner"
              },
              {
                "$ref": "#/$defs/add-group-member-inner"
              }
            ]
          }
        },
        "maxProperties": 1,
        "minProperties": 1,
        "patternProperties": {
          "^(?!create-room|update-room|add-room-member|remove-room-member|promote-room-owner|demote-room-owner|send-message|update-message|pin-message|unpin-message|debug|execute-script|execute-request|create-user|create-system-user|create-connection|update-user|update-system-user|add-user-role|remove-user-role|remove-connection|reject-connection|accept-connection|get-user|get-users|get-stream|get-room|get-message|get-connection|get-stream-members|get-room-members|get-user-streams|get-streams|get-rooms|get-messages|get-connections)([a-z0-9-]+)$": {
            "$comment": "Match everything that is not an already known activity to allow for custom activities to be used.",
            "$ref": "#/$defs/basic-activity-inner"
          }
        }
      }
    }
  },
  "$defs": {
    "search-user-inner": {
      "type": "object",
      "properties": {
        "local": {
          "type": [
            "boolean",
            "string"
          ],
          "description": "If true then a local DB search will be performed and only local pod users will be returned. If absent or false then a directory search will be performed and users from other pods who are visible to the calling user will also be returned.",
          "default": false
        },
        "active": {
          "type": [
            "boolean",
            "string"
          ],
          "description": "If true, it searches for active users only. If false, it searches for inactive users only. If not set, it searches for all users regardless of their status."
        }
      }
    },
    "on": {
      "description": "Events that can trigger the activity execution.",
      "x-intellij-html-description": "<html><p>Events that can trigger the activity execution.</p><a href=\"https://docs.developers.symphony.com/building-bots-on-symphony/datafeed/real-time-events\">List of real-time events: https://docs.developers.symphony.com/building-bots-on-symphony/datafeed/real-time-events</a></html>",
      "type": "object",
      "allOf": [
        {
          "type": "object",
          "properties": {
            "timeout": {
              "type": "string",
              "description": "Timeout while waiting for form-replied events, expressed as an ISO 8601 duration. Default value is 24 hours.",
              "pattern": "^P(?!$)(\\d+(?:\\.\\d+)?Y)?(\\d+(?:\\.\\d+)?M)?(\\d+(?:\\.\\d+)?W)?(\\d+(?:\\.\\d+)?D)?(T(?=\\d)(\\d+(?:\\.\\d+)?H)?(\\d+(?:\\.\\d+)?M)?(\\d+(?:\\.\\d+)?S)?)?$"
            }
          }
        },
        {
          "oneOf": [
            {
              "$ref": "#/$defs/form-replied-event"
            },
            {
              "$ref": "#/$defs/activity-expired-event"
            },
            {
              "$ref": "#/$defs/activity-completed-event"
            },
            {
              "$ref": "#/$defs/activity-failed-event"
            },
            {
              "$ref": "#/$defs/message-received-event"
            },
            {
              "$ref": "#/$defs/request-received-event"
            },
            {
              "$ref": "#/$defs/message-suppressed-event"
            },
            {
              "$ref": "#/$defs/post-shared-event"
            },
            {
              "$ref": "#/$defs/im-created-event"
            },
            {
              "$ref": "#/$defs/room-created-event"
            },
            {
              "$ref": "#/$defs/room-updated-event"
            },
            {
              "$ref": "#/$defs/room-deactivated-event"
            },
            {
              "$ref": "#/$defs/room-reactivated-event"
            },
            {
              "$ref": "#/$defs/room-member-promoted-to-owner-event"
            },
            {
              "$ref": "#/$defs/room-member-demoted-from-owner-event"
            },
            {
              "$ref": "#/$defs/user-joined-room-event"
            },
            {
              "$ref": "#/$defs/user-left-room-event"
            },
            {
              "$ref": "#/$defs/user-requested-join-room-event"
            },
            {
              "$ref": "#/$defs/connection-requested-event"
            },
            {
              "$ref": "#/$defs/connection-accepted-event"
            },
            {
              "$ref": "#/$defs/timer-fired-event"
            },
            {
              "$ref": "#/$defs/one-of-event"
            },
            {
              "$ref": "#/$defs/all-of-event"
            }
          ]
        }
      ]
    },
    "form-replied-event": {
      "type": "object",
      "properties": {
        "form-replied": {
          "description": "Generated when a user replies to a bot message that contains an interactive form with UX components such as text fields, radio buttons, checkboxes, person selectors and more.",
          "x-intellij-html-description": "<html><p>Generated when a user replies to a bot message that contains an interactive form with UX components such as text fields, radio buttons, checkboxes, person selectors and more. Please refer to <a href=\"https://docs.developers.symphony.com/building-bots-on-symphony/symphony-elements\">Symphony Elements.</p><a href=\"https://docs.developers.symphony.com/building-bots-on-symphony/datafeed/real-time-events#symphony-elements-action\">https://docs.developers.symphony.com/building-bots-on-symphony/datafeed/real-time-events#symphony-elements-action</a></html>",
          "$ref": "#/$defs/form-replied-event-inner"
        }
      },
      "required": [
        "form-replied"
      ]
    },
    "request-received-event": {
      "title": "object",
      "properties": {
        "request-received": {
          "description": "Generated when an HTTP request is received in order to trigger a workflow.",
          "$ref": "#/$defs/request-received-event-inner"
        }
      },
      "required": [
        "request-received"
      ],
      "type": "object"
    },
    "message-received-event": {
      "type": "object",
      "properties": {
        "message-received": {
          "description": "Generated when a message is sent in an IM, MIM, or chatroom of which the workflow bot is a member, including messages sent by the user him/herself.",
          "x-intellij-html-description": "<html><p>Generated when a message is sent in an IM, MIM, or chatroom of which the workflow bot is a member, including messages sent by the user him/herself.</p><a href=\"https://docs.developers.symphony.com/building-bots-on-symphony/datafeed/real-time-events#message-sent\">https://docs.developers.symphony.com/building-bots-on-symphony/datafeed/real-time-events#message-sent</a></html>",
          "$ref": "#/$defs/message-received-event-inner"
        }
      },
      "required": [
        "message-received"
      ]
    },
    "message-suppressed-event": {
      "type": "object",
      "properties": {
        "message-suppressed": {
          "description": "Generated when messages are suppressed.",
          "x-intellij-html-description": "<html><p>Generated when messages are suppressed.</p><a href=\"https://docs.developers.symphony.com/building-bots-on-symphony/datafeed/real-time-events#messages-suppressed\">https://docs.developers.symphony.com/building-bots-on-symphony/datafeed/real-time-events#messages-suppressed</a></html>",
          "$ref": "#/$defs/message-suppressed-event-inner"
        }
      },
      "required": [
        "message-suppressed"
      ]
    },
    "post-shared-event": {
      "type": "object",
      "properties": {
        "post-shared": {
          "description": "Generated when either the workflow bot shares a wall post written by another user or another user shares a wall post written by the workflow bot.",
          "x-intellij-html-description": "<html><p>Generated when either:<li>The workflow bot shares a wall post written by another user.</li><li>Another user shares a wall post written by the workflow bot.</li></p><a href=\"https://docs.developers.symphony.com/building-bots-on-symphony/datafeed/real-time-events#shared-wall-posts\">https://docs.developers.symphony.com/building-bots-on-symphony/datafeed/real-time-events#shared-wall-posts</a></html>",
          "$ref": "#/$defs/post-shared-event-inner"
        }
      },
      "required": [
        "post-shared"
      ]
    },
    "im-created-event": {
      "type": "object",
      "properties": {
        "im-created": {
          "description": "Generated when an IM or MIM is created with the workflow bot as a member, initiated either by the workflow bot or another user.",
          "x-intellij-html-description": "<html><p>Generated when an IM or MIM is created with the workflow bot as a member, initiated either by the workflow bot or another user.</p><a href=\"https://docs.developers.symphony.com/building-bots-on-symphony/datafeed/real-time-events#im-mim-created\">https://docs.developers.symphony.com/building-bots-on-symphony/datafeed/real-time-events#im-mim-created</a></html>",
          "$ref": "#/$defs/im-created-event-inner"
        }
      },
      "required": [
        "im-created"
      ]
    },
    "room-created-event": {
      "type": "object",
      "properties": {
        "room-created": {
          "description": "Generated when a room is created by the workflow bot.",
          "x-intellij-html-description": "<html><p>Generated when a room is created by the workflow bot.</p><a href=\"https://docs.developers.symphony.com/building-bots-on-symphony/datafeed/real-time-events#room-created\">https://docs.developers.symphony.com/building-bots-on-symphony/datafeed/real-time-events#room-created</a></html>",
          "$ref": "#/$defs/room-created-event-inner"
        }
      },
      "required": [
        "room-created"
      ]
    },
    "room-updated-event": {
      "type": "object",
      "properties": {
        "room-updated": {
          "description": "Generated when a room of which the workflow bot is a member is updated, including rooms updated by the user him/herself.",
          "x-intellij-html-description": "<html><p>Generated when a room of which the workflow bot is a member is updated, including rooms updated by the user him/herself.</p><a href=\"https://docs.developers.symphony.com/building-bots-on-symphony/datafeed/real-time-events#room-updated-message\">https://docs.developers.symphony.com/building-bots-on-symphony/datafeed/real-time-events#room-updated-message</a></html>",
          "$ref": "#/$defs/room-updated-event-inner"
        }
      },
      "required": [
        "room-updated"
      ]
    },
    "room-deactivated-event": {
      "type": "object",
      "properties": {
        "room-deactivated": {
          "description": "Generated when a room of which the workflow bot is a member is deactivated, including rooms deactivated by the user him/herself.",
          "x-intellij-html-description": "<html><p>Generated when a room of which the workflow bot is a member is deactivated, including rooms deactivated by the user him/herself.</p><a href=\"https://docs.developers.symphony.com/building-bots-on-symphony/datafeed/real-time-events#room-deactivated-message\">https://docs.developers.symphony.com/building-bots-on-symphony/datafeed/real-time-events#room-deactivated-message</a></html>",
          "$ref": "#/$defs/room-deactivated-event-inner"
        }
      },
      "required": [
        "room-deactivated"
      ]
    },
    "room-reactivated-event": {
      "type": "object",
      "properties": {
        "room-reactivated": {
          "description": "Generated when a room of which the workflow bot is a member is reactivated, including rooms reactivated by the user him/herself.",
          "x-intellij-html-description": "<html><p>Generated when a room of which the workflow bot is a member is reactivated, including rooms reactivated by the user him/herself.</p><a href=\"https://docs.developers.symphony.com/building-bots-on-symphony/datafeed/real-time-events#room-reactivated-message\">https://docs.developers.symphony.com/building-bots-on-symphony/datafeed/real-time-events#room-reactivated-message</a></html>",
          "$ref": "#/$defs/room-reactivated-event-inner"
        }
      },
      "required": [
        "room-reactivated"
      ]
    },
    "room-member-promoted-to-owner-event": {
      "type": "object",
      "properties": {
        "room-member-promoted-to-owner": {
          "description": "Generated when a user is promoted from a participant to an owner of a room of which the workflow bot is a member, including when the user himself is promoted to an owner or promotes another user.",
          "x-intellij-html-description": "<html><p>Generated when a user is promoted from a participant to an owner of a room of which the workflow bot is a member, including when the user himself is promoted to an owner or promotes another user.</p><a href=\"https://docs.developers.symphony.com/building-bots-on-symphony/datafeed/real-time-events#room-member-promoted-to-owner\">https://docs.developers.symphony.com/building-bots-on-symphony/datafeed/real-time-events#room-member-promoted-to-owner</a></html>",
          "$ref": "#/$defs/room-member-promoted-to-owner-event-inner"
        }
      },
      "required": [
        "room-member-promoted-to-owner"
      ]
    },
    "room-member-demoted-from-owner-event": {
      "type": "object",
      "properties": {
        "room-member-demoted-from-owner": {
          "description": "Generated when a user is demoted from an owner to a participant of a room of which the workflow bot is a member, including when the user himself is demoted to a participant or demotes another user.",
          "x-intellij-html-description": "<html><p>Generated when a user is demoted from an owner to a participant of a room of which the workflow bot is a member, including when the user himself is demoted to a participant or demotes another user.</p><a href=\"https://docs.developers.symphony.com/building-bots-on-symphony/datafeed/real-time-events#room-member-demoted-from-owner\">https://docs.developers.symphony.com/building-bots-on-symphony/datafeed/real-time-events#room-member-demoted-from-owner</a></html>",
          "$ref": "#/$defs/room-member-demoted-from-owner-event-inner"
        }
      },
      "required": [
        "room-member-demoted-from-owner"
      ]
    },
    "user-joined-room-event": {
      "type": "object",
      "properties": {
        "user-joined-room": {
          "description": "Generated when a new user joins or is added to a room of which the workflow bot is a member, including when the user himself joins or is added to a room.",
          "x-intellij-html-description": "<html><p>Generated when a new user joins or is added to a room of which the workflow bot is a member, including when the user himself joins or is added to a room.</p><a href=\"https://docs.developers.symphony.com/building-bots-on-symphony/datafeed/real-time-events#user-joined-room\">https://docs.developers.symphony.com/building-bots-on-symphony/datafeed/real-time-events#user-joined-room</a></html>",
          "$ref": "#/$defs/user-joined-room-event-inner"
        }
      },
      "required": [
        "user-joined-room"
      ]
    },
    "user-left-room-event": {
      "type": "object",
      "properties": {
        "user-left-room": {
          "description": "Generated when a user leaves or is removed from a room of which the workflow bot is a member, including when the user himself leaves or is removed from a room.",
          "x-intellij-html-description": "<html><p>Generated when a user leaves or is removed from a room of which the workflow bot is a member, including when the user himself leaves or is removed from a room.</p><a href=\"https://docs.developers.symphony.com/building-bots-on-symphony/datafeed/real-time-events#user-left-room\">https://docs.developers.symphony.com/building-bots-on-symphony/datafeed/real-time-events#user-left-room</a></html>",
          "$ref": "#/$defs/user-left-room-event-inner"
        }
      },
      "required": [
        "user-left-room"
      ]
    },
    "user-requested-join-room-event": {
      "type": "object",
      "properties": {
        "user-requested-join-room": {
          "description": "Generated when a user requests to join a room. Only the user who requested to join the room and the owners of that room will receive this event on their datafeeds.",
          "x-intellij-html-description": "<html><p>Generated when a user requests to join a room. Only the user who requested to join the room and the owners of that room will receive this event on their datafeeds.</p><a href=\"https://docs.developers.symphony.com/building-bots-on-symphony/datafeed/real-time-events#user-requested-to-join-room\">https://docs.developers.symphony.com/building-bots-on-symphony/datafeed/real-time-events#user-requested-to-join-room</a></html>",
          "$ref": "#/$defs/user-requested-join-room-event-inner"
        }
      },
      "required": [
        "user-requested-join-room"
      ]
    },
    "connection-requested-event": {
      "type": "object",
      "properties": {
        "connection-requested": {
          "description": "Generated when a connection request is sent, either by the workflow bot to another user or to the workflow bot by another user.",
          "x-intellij-html-description": "<html><p>Generated when a connection request is sent, either:<li>Sent by the workflow bot to another user.</li><li>Sent to the workflow bot by another user.</li></p><a href=\"https://docs.developers.symphony.com/building-bots-on-symphony/datafeed/real-time-events#connection-requested\">https://docs.developers.symphony.com/building-bots-on-symphony/datafeed/real-time-events#connection-requested</a></html>",
          "$ref": "#/$defs/connection-requested-event-inner"
        }
      },
      "required": [
        "connection-requested"
      ]
    },
    "connection-accepted-event": {
      "type": "object",
      "properties": {
        "connection-accepted": {
          "description": "Generated when a connection request is accepted, either sent by the workflow bot and accepted by another user or sent by another user and accepted by the workflow bot.",
          "x-intellij-html-description": "<html><p>Generated when a connection request is accepted, either:<li>Sent by the workflow bot and accepted by another user.</li><li>Sent by another user and accepted by the workflow bot.</li></p><a href=\"https://docs.developers.symphony.com/building-bots-on-symphony/datafeed/real-time-events#connection-accepted\">https://docs.developers.symphony.com/building-bots-on-symphony/datafeed/real-time-events#connection-accepted</a></html>",
          "$ref": "#/$defs/connection-accepted-event-inner"
        }
      },
      "required": [
        "connection-accepted"
      ]
    },
    "activity-expired-event": {
      "type": "object",
      "properties": {
        "activity-expired": {
          "description": "Generated when the given activity event timeout has expired. Note this is not a Datafeed real-time event.",
          "$ref": "#/$defs/activity-expired-event-inner"
        }
      },
      "required": [
        "activity-expired"
      ]
    },
    "activity-failed-event": {
      "type": "object",
      "properties": {
        "activity-failed": {
          "description": "Generated when the given activity has failed. Note this is not a Datafeed real-time event.",
          "$ref": "#/$defs/activity-failed-event-inner"
        }
      },
      "required": [
        "activity-failed"
      ]
    },
    "activity-completed-event": {
      "type": "object",
      "properties": {
        "activity-completed": {
          "description": "Generated when the given activity is completed. Note this is not a Datafeed real-time event.",
          "x-intellij-html-description": "<html><p>Generated when the given activity is completed. Note this is not a Datafeed real-time event.</p></html>",
          "$ref": "#/$defs/activity-completed-event-inner"
        },
        "if": {
          "type": "string",
          "pattern": "^\\$\\{.*\\}$"
        }
      },
      "required": [
        "activity-completed"
      ]
    },
    "all-of-event": {
      "type": "object",
      "properties": {
        "all-of": {
          "description": "Used to receive all listed events.",
          "x-intellij-html-description": "Used to receive all listed events.",
          "type": "array",
          "items": {
            "anyOf": [
              {
                "$ref": "#/$defs/form-replied-event"
              },
              {
                "$ref": "#/$defs/activity-completed-event"
              },
              {
                "$ref": "#/$defs/activity-failed-event"
              },
              {
                "$ref": "#/$defs/message-received-event"
              },
              {
                "$ref": "#/$defs/request-received-event"
              },
              {
                "$ref": "#/$defs/message-suppressed-event"
              },
              {
                "$ref": "#/$defs/post-shared-event"
              },
              {
                "$ref": "#/$defs/im-created-event"
              },
              {
                "$ref": "#/$defs/room-created-event"
              },
              {
                "$ref": "#/$defs/room-updated-event"
              },
              {
                "$ref": "#/$defs/room-deactivated-event"
              },
              {
                "$ref": "#/$defs/room-reactivated-event"
              },
              {
                "$ref": "#/$defs/room-member-promoted-to-owner-event"
              },
              {
                "$ref": "#/$defs/room-member-demoted-from-owner-event"
              },
              {
                "$ref": "#/$defs/user-joined-room-event"
              },
              {
                "$ref": "#/$defs/user-left-room-event"
              },
              {
                "$ref": "#/$defs/user-requested-join-room-event"
              },
              {
                "$ref": "#/$defs/connection-requested-event"
              },
              {
                "$ref": "#/$defs/connection-accepted-event"
              },
              {
                "$ref": "#/$defs/timer-fired-event"
              }
            ]
          }
        }
      },
      "required": [
        "all-of"
      ],
      "additionalProperties": true
    },
    "one-of-event": {
      "type": "object",
      "properties": {
        "one-of": {
          "description": "Used to receive at least one of the listed events.",
          "x-intellij-html-description": "Used to receive at least one of the listed events.",
          "type": "array",
          "items": {
            "oneOf": [
              {
                "$ref": "#/$defs/form-replied-event"
              },
              {
                "$ref": "#/$defs/activity-expired-event"
              },
              {
                "$ref": "#/$defs/activity-completed-event"
              },
              {
                "$ref": "#/$defs/activity-failed-event"
              },
              {
                "$ref": "#/$defs/message-received-event"
              },
              {
                "$ref": "#/$defs/request-received-event"
              },
              {
                "$ref": "#/$defs/message-suppressed-event"
              },
              {
                "$ref": "#/$defs/post-shared-event"
              },
              {
                "$ref": "#/$defs/im-created-event"
              },
              {
                "$ref": "#/$defs/room-created-event"
              },
              {
                "$ref": "#/$defs/room-updated-event"
              },
              {
                "$ref": "#/$defs/room-deactivated-event"
              },
              {
                "$ref": "#/$defs/room-reactivated-event"
              },
              {
                "$ref": "#/$defs/room-member-promoted-to-owner-event"
              },
              {
                "$ref": "#/$defs/room-member-demoted-from-owner-event"
              },
              {
                "$ref": "#/$defs/user-joined-room-event"
              },
              {
                "$ref": "#/$defs/user-left-room-event"
              },
              {
                "$ref": "#/$defs/user-requested-join-room-event"
              },
              {
                "$ref": "#/$defs/connection-requested-event"
              },
              {
                "$ref": "#/$defs/connection-accepted-event"
              },
              {
                "$ref": "#/$defs/timer-fired-event"
              }
            ]
          }
        }
      },
      "required": [
        "one-of"
      ],
      "additionalProperties": true
    },
    "timer-fired-event": {
      "type": "object",
      "properties": {
        "timer-fired": {
          "description": "Timer based event. It is either triggered at a given point in time using the keyword \"at\" or repeated using the keyword \"repeat\". Note this is not a Datafeed real-time event.",
          "x-intellij-html-description": "<html><p>Timer based event. It is either triggered at: <li>a given point in time using the keyword <i>\"at\"</i>.</li><li>repeated using the keyword <i>\"repeat\"</i>.</li> Note this is not a Datafeed real-time event.</p></html>",
          "$ref": "#/$defs/timer-fired-event-inner"
        }
      },
      "required": [
        "timer-fired"
      ],
      "additionalProperties": false
    },
    "repeat": {
      "properties": {
        "repeat": {
          "description": "ISO 8601 repeating intervals to repeat the current activity.",
          "type": "string",
          "default": "R/PT0.1S"
        }
      },
      "required": [
        "repeat"
      ],
      "type": "object"
    },
    "at": {
      "properties": {
        "at": {
          "description": "ISO 8601 date representing a point in time when the current activity should be executed.",
          "type": "string",
          "default": "2021-08-31T-15:50:00"
        }
      },
      "required": [
        "at"
      ],
      "type": "object"
    },
    "timer-fired-event-inner": {
      "type": "object",
      "oneOf": [
        {
          "$ref": "#/$defs/repeat"
        },
        {
          "$ref": "#/$defs/at"
        }
      ]
    },
    "form-replied-event-inner": {
      "type": "object",
      "properties": {
        "form-id": {
          "description": "Form's id. The id should be the same as activity's one that sent the form.",
          "type": "string"
        },
        "exclusive": {
          "description": "True if only one reply is expected to the form. Default is false",
          "default": false,
          "type": "boolean"
        }
      },
      "required": [
        "form-id"
      ]
    },
    "message-received-event-inner": {
      "type": "object",
      "properties": {
        "content": {
          "description": "Message content to listen to.",
          "type": "string"
        },
        "requires-bot-mention": {
          "description": "If true, the event is only triggered if the bot is mentioned.",
          "type": "boolean",
          "default": false
        },
        "id": {
          "description": "Event's identifier, should be unique across workflow. As it can be used as a variable identifier only alphanumerical characters are allowed.",
          "type": "string",
          "pattern": "^(?!variables$)([a-zA-Z][a-zA-Z0-9_]+)$"
        }
      },
      "additionalProperties": false
    },
    "request-received-event-inner": {
      "type": "object",
      "required": [
        "token"
      ],
      "properties": {
        "token": {
          "description": "Token to authorize incoming http requests.",
          "type": "string",
          "minLength": 1
        },
        "id": {
          "description": "Event's identifier, should be unique across workflow. As it can be used as a variable identifier only alphanumerical characters are allowed.",
          "type": "string",
          "pattern": "^(?!variables$)([a-zA-Z][a-zA-Z0-9_]+)$"
        }
      },
      "additionalProperties": false
    },
    "message-suppressed-event-inner": {
      "type": "object",
      "properties": {}
    },
    "post-shared-event-inner": {
      "type": "object",
      "properties": {}
    },
    "im-created-event-inner": {
      "type": "object",
      "properties": {}
    },
    "room-created-event-inner": {
      "type": "object",
      "properties": {}
    },
    "room-updated-event-inner": {
      "type": "object",
      "properties": {}
    },
    "room-deactivated-event-inner": {
      "type": "object",
      "properties": {}
    },
    "room-reactivated-event-inner": {
      "type": "object",
      "properties": {}
    },
    "room-member-promoted-to-owner-event-inner": {
      "type": "object",
      "properties": {
        "id": {
          "description": "Event's identifier, should be unique across workflow. As it can be used as a variable identifier only alphanumerical characters are allowed.",
          "type": "string",
          "pattern": "^(?!variables$)([a-zA-Z][a-zA-Z0-9_]+)$"
        }
      }
    },
    "room-member-demoted-from-owner-event-inner": {
      "type": "object",
      "properties": {}
    },
    "user-joined-room-event-inner": {
      "type": "object",
      "properties": {
        "id": {
          "description": "Event's identifier, should be unique across workflow. As it can be used as a variable identifier only alphanumerical characters are allowed.",
          "type": "string",
          "pattern": "^(?!variables$)([a-zA-Z][a-zA-Z0-9_]+)$"
        }
      }
    },
    "user-left-room-event-inner": {
      "type": "object",
      "properties": {
        "id": {
          "description": "Event's identifier, should be unique across workflow. As it can be used as a variable identifier only alphanumerical characters are allowed.",
          "type": "string",
          "pattern": "^(?!variables$)([a-zA-Z][a-zA-Z0-9_]+)$"
        }
      }
    },
    "user-requested-join-room-event-inner": {
      "type": "object",
      "properties": {}
    },
    "connection-requested-event-inner": {
      "type": "object",
      "properties": {}
    },
    "connection-accepted-event-inner": {
      "type": "object",
      "properties": {}
    },
    "activity-expired-event-inner": {
      "type": "object",
      "properties": {
        "activity-id": {
          "description": "The expiring activity triggering this event.",
          "$ref": "#/$defs/id"
        }
      },
      "required": [
        "activity-id"
      ]
    },
    "activity-failed-event-inner": {
      "type": "object",
      "properties": {
        "activity-id": {
          "description": "The failing activity triggering this event.",
          "$ref": "#/$defs/id"
        }
      },
      "required": [
        "activity-id"
      ]
    },
    "activity-completed-event-inner": {
      "type": "object",
      "properties": {
        "activity-id": {
          "description": "The completed (without errors) activity triggering this event.",
          "$ref": "#/$defs/id"
        },
        "id": {
          "description": "Event's identifier, should be unique across workflow. As it can be used as a variable identifier only alphanumerical characters are allowed.",
          "type": "string",
          "pattern": "^(?!variables$)([a-zA-Z][a-zA-Z0-9_]+)$"
        }
      },
      "required": [
        "activity-id"
      ]
    },
    "basic-activity-inner": {
      "type": "object",
      "description": "Inner property having common properties for every activity.",
      "properties": {
        "id": {
          "description": "Activity's identifier, should be unique across workflow. As it can be used as a variable identifier only alphanumerical characters are allowed.",
          "type": "string",
          "$comment": "variables is forbidden to avoid conflict with variables.output... that would override the workflows variables",
          "pattern": "^(?!variables$)([a-zA-Z][a-zA-Z0-9_]+)$"
        },
        "on": {
          "$ref": "#/$defs/on"
        },
        "if": {
          "description": "Conditional execution of the activity based on a boolean expression.",
          "type": "string"
        },
        "else": {
          "description": "Default execution of the activity when if conditions are used for previous activities.",
          "type": "object"
        }
      },
      "required": [
        "id"
      ]
    },
    "room-name": {
      "anyOf": [
        {
          "enum": [
            "${ACTIVITY_ID.outputs.room.roomAttributes.name}",
            "${ACTIVITY_ID.outputs.stream.roomAttributes.name}",
            "${variables.VARIABLE_NAME}"
          ]
        },
        {
          "description": "Room's name. Room names will be considered the same if they only differ in capitalization and whitespace. E.g. \"room1\" and \"R O O M 1\" are considered the same. Also, room names must be shorter than 50 characters.",
          "type": "string",
          "maxLength": 50
        }
      ]
    },
    "room-description": {
      "anyOf": [
        {
          "enum": [
            "${ACTIVITY_ID.outputs.room.roomAttributes.description}",
            "${variables.VARIABLE_NAME}"
          ]
        },
        {
          "description": "Room's description.",
          "type": "string"
        }
      ]
    },
    "keywords": {
      "description": "A list of key-value pairs, describing additional properties of the room.",
      "oneOf": [
        {
          "type": "object"
        },
        {
          "type": "string",
          "minLength": 1
        },
        {
          "enum": [
            "${variables.VARIABLE_NAME}"
          ]
        }
      ]
    },
    "members-can-invite": {
      "description": "If true, any chat room participant can add new participants. If false, only owners can add new participants.",
      "type": [
        "boolean",
        "string"
      ],
      "default": false
    },
    "discoverable": {
      "description": "If true, this chat room (name, description and messages) non-participants can search for this room. If false, only participants can search for this room.",
      "type": [
        "boolean",
        "string"
      ],
      "default": false
    },
    "public": {
      "description": "If true, this is a public chatroom. If false, a private chatroom.\nNote: Once this value is set for a room, it is read-only and can’t be updated.",
      "x-intellij-html-description": "<html><p>If true, this is a public chatroom. If false, a private chatroom.<br/><i>Note: Once this value is set for a room, it is read-only and can’t be updated.</i></p></html>",
      "type": [
        "boolean",
        "string"
      ],
      "default": false
    },
    "read-only": {
      "type": [
        "boolean",
        "string"
      ],
      "description": "If true, only stream owners can send messages.\nNote: Once this value is set for a room, it is read-only and can’t be updated.",
      "x-intellij-html-description": "<html><p>If true, only stream owners can send messages.<br/><i>Note: Once this value is set for a room, it is read-only and can’t be updated.</i></p></html>",
      "default": false
    },
    "copy-protected": {
      "type": [
        "boolean",
        "string"
      ],
      "description": "If true, users cannot copy content from this room.\nNote: Once this value is set to true for a room, it is read-only and can’t be updated.",
      "x-intellij-html-description": "<html><p>If true, users cannot copy content from this room.<br/><i>Note: Once this value is set to true for a room, it is read-only and can’t be updated.</i></p></html>",
      "default": false
    },
    "cross-pod": {
      "type": [
        "boolean",
        "string"
      ],
      "description": "If true, this room is a cross-pod room.",
      "default": false
    },
    "view-history": {
      "type": [
        "boolean",
        "string"
      ],
      "description": "If true, new members can view the room chat history of the room.",
      "default": false
    },
    "multilateral-room": {
      "type": [
        "boolean",
        "string"
      ],
      "description": "If true, this is a multilateral room where users belonging to more than 2 companies can be found.",
      "default": false
    },
    "active": {
      "type": [
        "boolean",
        "string"
      ],
      "description": "If false, the room is not active anymore.",
      "default": false
    },
    "sub-type": {
      "type": "string",
      "enum": [
        "EMAIL"
      ]
    },
    "create-room-inner": {
      "type": "object",
      "properties": {
        "room-name": {
          "$ref": "#/$defs/room-name"
        },
        "room-description": {
          "$ref": "#/$defs/room-description"
        },
        "public": {
          "$ref": "#/$defs/public"
        },
        "user-ids": {
          "$ref": "#/$defs/user-ids-inner"
        },
        "keywords": {
          "$ref": "#/$defs/keywords"
        },
        "members-can-invite": {
          "$ref": "#/$defs/members-can-invite"
        },
        "discoverable": {
          "$ref": "#/$defs/discoverable"
        },
        "read-only": {
          "$ref": "#/$defs/read-only"
        },
        "copy-protected": {
          "$ref": "#/$defs/copy-protected"
        },
        "cross-pod": {
          "$ref": "#/$defs/cross-pod"
        },
        "view-history": {
          "$ref": "#/$defs/view-history"
        },
        "multilateral-room": {
          "$ref": "#/$defs/multilateral-room"
        },
        "sub-type": {
          "$ref": "#/$defs/sub-type"
        },
        "obo": {
          "description": "Defines whether the activity will be executed on behalf of a user and the user on whose behalf the call will be made",
          "$ref": "#/$defs/obo-inner"
        }
      },
      "anyOf": [
        {
          "required": [
            "room-name",
            "room-description"
          ]
        },
        {
          "required": [
            "user-ids"
          ]
        }
      ]
    },
    "update-room-inner": {
      "type": "object",
      "required": [
        "stream-id"
      ],
      "properties": {
        "stream-id": {
          "description": "Stream's id to update.",
          "$ref": "#/$defs/stream-id-inner"
        },
        "room-name": {
          "$ref": "#/$defs/room-name"
        },
        "room-description": {
          "$ref": "#/$defs/room-description"
        },
        "keywords": {
          "$ref": "#/$defs/keywords"
        },
        "members-can-invite": {
          "$ref": "#/$defs/members-can-invite"
        },
        "discoverable": {
          "$ref": "#/$defs/discoverable"
        },
        "public": {
          "$ref": "#/$defs/public"
        },
        "read-only": {
          "$ref": "#/$defs/read-only"
        },
        "copy-protected": {
          "$ref": "#/$defs/copy-protected"
        },
        "cross-pod": {
          "$ref": "#/$defs/cross-pod"
        },
        "view-history": {
          "$ref": "#/$defs/view-history"
        },
        "multilateral-room": {
          "$ref": "#/$defs/multilateral-room"
        },
        "active": {
          "$ref": "#/$defs/active"
        },
        "obo": {
          "description": "Defines whether the activity will be executed on behalf of a user and the user on whose behalf the call will be made",
          "$ref": "#/$defs/obo-inner"
        }
      }
    },
    "add-room-member-inner": {
      "type": "object",
      "properties": {
        "stream-id": {
          "description": "Stream id where to add user(s).",
          "$ref": "#/$defs/stream-id-inner"
        },
        "user-ids": {
          "description": "User ids to add to the room.",
          "$ref": "#/$defs/user-ids-inner"
        },
        "obo": {
          "description": "Defines whether the activity will be executed on behalf of a user and the user on whose behalf the call will be made",
          "$ref": "#/$defs/obo-inner"
        }
      },
      "required": [
        "stream-id",
        "user-ids"
      ]
    },
    "remove-room-member-inner": {
      "type": "object",
      "properties": {
        "stream-id": {
          "description": "Stream id where to remove user(s).",
          "$ref": "#/$defs/stream-id-inner"
        },
        "user-ids": {
          "description": "User ids to remove from the room.",
          "$ref": "#/$defs/user-ids-inner"
        },
        "obo": {
          "description": "Defines whether the activity will be executed on behalf of a user and the user on whose behalf the call will be made",
          "$ref": "#/$defs/obo-inner"
        }
      },
      "required": [
        "stream-id",
        "user-ids"
      ]
    },
    "promote-room-owner-inner": {
      "type": "object",
      "properties": {
        "stream-id": {
          "description": "Stream id where to promote user.",
          "$ref": "#/$defs/stream-id-inner"
        },
        "user-ids": {
          "description": "User ids to promote in the room.",
          "$ref": "#/$defs/user-ids-inner"
        },
        "obo": {
          "description": "Defines whether the activity will be executed on behalf of a user and the user on whose behalf the call will be made",
          "$ref": "#/$defs/obo-inner"
        }
      },
      "required": [
        "stream-id",
        "user-ids"
      ]
    },
    "demote-room-owner-inner": {
      "type": "object",
      "properties": {
        "stream-id": {
          "description": "Stream id where to demote user.",
          "$ref": "#/$defs/stream-id-inner"
        },
        "user-ids": {
          "description": "User ids to demote in the room.",
          "$ref": "#/$defs/user-ids-inner"
        },
        "obo": {
          "description": "Defines whether the activity will be executed on behalf of a user and the user on whose behalf the call will be made",
          "$ref": "#/$defs/obo-inner"
        }
      },
      "required": [
        "stream-id",
        "user-ids"
      ]
    },
    "send-message-inner": {
      "type": "object",
      "properties": {
        "to": {
          "description": "The recipient (conversation, IM, MIM or chatroom) in which the message should be posted.",
          "$ref": "#/$defs/to"
        },
        "content": {
          "$ref": "#/$defs/content-inner"
        },
        "data": {
          "description": "Message data, which is a Json string and sent along with message.",
          "type": "string"
        },
        "attachments": {
          "description": "One or more attachments to be sent along with the message.",
          "type": "array",
          "items": {
            "$ref": "#/$defs/attachment"
          }
        },
        "obo": {
          "description": "Defines whether the activity will be executed on behalf of a user and the user on whose behalf the call will be made",
          "$ref": "#/$defs/obo-inner"
        }
      },
      "required": [
        "content"
      ]
    },
    "update-message-inner": {
      "type": "object",
      "properties": {
        "content": {
          "$ref": "#/$defs/content-inner"
        },
        "message-id": {
          "$ref": "#/$defs/message-id-inner"
        },
        "silent": {
          "type": [
            "boolean",
            "string"
          ],
          "description": "If enabled, the new updated message is marked as read, otherwise is unread",
          "default": true
        }
      },
      "required": [
        "content",
        "message-id"
      ]
    },
    "pin-message-inner": {
      "type": "object",
      "properties": {
        "message-id": {
          "$ref": "#/$defs/message-id-inner"
        },
        "obo": {
          "description": "Defines whether the activity will be executed on behalf of a user and the user on whose behalf the call will be made",
          "$ref": "#/$defs/obo-inner"
        }
      },
      "required": [
        "message-id"
      ]
    },
    "unpin-message-inner": {
      "type": "object",
      "properties": {
        "stream-id": {
          "$ref": "#/$defs/stream-id-inner"
        },
        "obo": {
          "description": "Defines whether the activity will be executed on behalf of a user and the user on whose behalf the call will be made",
          "$ref": "#/$defs/obo-inner"
        }
      },
      "required": [
        "stream-id"
      ]
    },
    "get-attachment-inner": {
      "type": "object",
      "properties": {
        "message-id": {
          "$ref": "#/$defs/message-id-inner"
        },
        "attachment-id": {
          "$ref": "#/$defs/single-attachment"
        }
      },
      "required": [
        "message-id",
        "attachment-id"
      ]
    },
    "execute-script-inner": {
      "type": "object",
      "required": [
        "script"
      ],
      "properties": {
        "script": {
          "type": "string",
          "description": "Script to execute (only Groovy is supported)",
          "x-intellij-language-injection": "Groovy"
        }
      }
    },
    "execute-request-inner": {
      "type": "object",
      "properties": {
        "url": {
          "type": "string",
          "description": "Contains the host and the path to be targeted",
          "minLength": 1
        },
        "encode-query-params": {
          "type": [
            "boolean",
            "string"
          ],
          "description": "If enabled, the query parameters will be encoded in application/x-www-form-urlencoded",
          "default": true
        },
        "method": {
          "type": "string",
          "description": "HTTP method to perform",
          "default": "GET",
          "enum": [
            "GET",
            "POST",
            "PUT",
            "DELETE",
            "PATCH",
            "HEAD",
            "OPTIONS"
          ]
        },
        "body": {
          "oneOf": [
            {
              "type": "string",
              "description": "HTTP request body",
              "$comment": "String format is required for all content types except multipart/form-data"
            },
            {
              "type": "object",
              "description": "HTTP request body",
              "$comment": "Object format is required for multipart/form-data content type"
            }
          ]
        },
        "headers": {
          "type": "object",
          "description": "HTTP request headers"
        }
      },
      "required": [
        "url"
      ]
    },
    "email": {
      "description": "Email address, must be unique",
      "$comment": "Variable or email regex is accepted.",
      "anyOf": [
        {
          "enum": [
            "${variables.VARIABLE_NAME}",
            "${ACTIVITY_ID.outputs.user.userAttributes.emailAddress}"
          ]
        },
        {
          "type": "string",
          "pattern": "([$][{].+\\})|(?:[a-z0-9!#$%&'*+/=?^_`{|}~-]+(?:\\.[a-z0-9!#$%&'*+/=?^_`{|}~-]+)*|\"(?:[\\x01-\\x08\\x0b\\x0c\\x0e-\\x1f\\x21\\x23-\\x5b\\x5d-\\x7f]|\\\\[\\x01-\\x09\\x0b\\x0c\\x0e-\\x7f])*\")@(?:(?:[a-z0-9](?:[a-z0-9-]*[a-z0-9])?\\.)+[a-z0-9](?:[a-z0-9-]*[a-z0-9])?|\\[(?:(?:(2(5[0-5]|[0-4][0-9])|1[0-9][0-9]|[1-9]?[0-9]))\\.){3}(?:(2(5[0-5]|[0-4][0-9])|1[0-9][0-9]|[1-9]?[0-9])|[a-z0-9-]*[a-z0-9]:(?:[\\x01-\\x08\\x0b\\x0c\\x0e-\\x1f\\x21-\\x5a\\x53-\\x7f]|\\\\[\\x01-\\x09\\x0b\\x0c\\x0e-\\x7f])+)\\])"
        }
      ]
    },
    "name": {
      "anyOf": [
        {
          "enum": [
            "${variables.VARIABLE_NAME}",
            "${ACTIVITY_ID.outputs.user.userAttributes.firstName}",
            "${ACTIVITY_ID.outputs.user.userAttributes.lastName}",
            "${ACTIVITY_ID.outputs.user.userAttributes.userName}",
            "${ACTIVITY_ID.outputs.user.userAttributes.displayName}"
          ]
        },
        {
          "type": "string",
          "minLength": 1
        }
      ]
    },
    "phoneNumber": {
      "description": "The user's work phone number.",
      "anyOf": [
        {
          "enum": [
            "${variables.VARIABLE_NAME}",
            "${ACTIVITY_ID.outputs.user.userAttributes.workPhoneNumber}",
            "${ACTIVITY_ID.outputs.user.userAttributes.mobilePhoneNumber}",
            "${ACTIVITY_ID.outputs.user.userAttributes.twoFactorAuthPhone}"
          ]
        },
        {
          "type": "string",
          "pattern": "^[0-9]*$|^\\+[0-9]*$"
        }
      ]
    },
    "business": {
      "type": "object",
      "description": "Business information",
      "properties": {
        "company-name": {
          "type": "string",
          "description": "The user's company name.\nIf not specified, it is set with the default company name."
        },
        "department": {
          "type": "string",
          "description": "The user's department."
        },
        "division": {
          "type": "string",
          "description": "The user's division."
        },
        "title": {
          "type": "string",
          "description": "The user's title."
        },
        "location": {
          "type": "string",
          "description": "The user's location."
        },
        "job-function": {
          "type": "string",
          "description": "The user's job function.",
          "enum": [
            "Analyst",
            "Other",
            "Business Development Executive",
            "Corporate Access",
            "Developer",
            "Director",
            "Economist",
            "Portfolio Manager",
            "Project Manager",
            "Research Analyst",
            "Sales",
            "Strategist",
            "Trader"
          ]
        },
        "asset-classes": {
          "description": "The user's asset classes (one or more).",
          "oneOf": [
            {
              "type": "array",
              "uniqueItems": true,
              "items": {
                "type": "string",
                "enum": [
                  "Equities",
                  "Cash Equities",
                  "Securities Lending",
                  "Fixed Income",
                  "Government Bonds",
                  "Prime Brokerage",
                  "Commodities",
                  "Municipal Bonds",
                  "Currencies",
                  "Corporate Bonds"
                ]
              }
            },
            {
              "type": "string",
              "minLength": 1,
              "pattern": "^\\$\\{.*\\}$"
            },
            {
              "enum": [
                "${variables.VARIABLE_NAME}"
              ]
            }
          ]
        },
        "industries": {
          "description": "The user's job industries (one or more).",
          "oneOf": [
            {
              "type": "array",
              "uniqueItems": true,
              "items": {
                "type": "string",
                "enum": [
                  "Healthcare",
                  "Consumer Non-Cyclicals",
                  "Transportation",
                  "Technology",
                  "Real Estate",
                  "Basic Materials",
                  "Financials",
                  "Energy & Utilities",
                  "Conglomerates",
                  "Consumer Cyclicals",
                  "Services"
                ]
              }
            },
            {
              "type": "string",
              "minLength": 1,
              "pattern": "^\\$\\{.*\\}$"
            },
            {
              "enum": [
                "${variables.VARIABLE_NAME}"
              ]
            }
          ]
        },
        "functions": {
          "description": "The user's job functions (one or more).",
          "oneOf": [
            {
              "type": "array",
              "uniqueItems": true,
              "items": {
                "type": "string",
                "enum": [
                  "Collateral",
                  "Confirmation",
                  "Trade Processing",
                  "Pre-Matching",
                  "Margin",
                  "Matching",
                  "Claims Processing",
                  "Middle Office",
                  "Liquidity Management",
                  "Allocation",
                  "Trade Management",
                  "Regulatory Outreach",
                  "Settlements",
                  "Post Trade Management"
                ]
              }
            },
            {
              "type": "string",
              "minLength": 1,
              "pattern": "^\\$\\{.*\\}$"
            },
            {
              "enum": [
                "${variables.VARIABLE_NAME}"
              ]
            }
          ]
        },
        "market-coverages": {
          "description": "The user's market coverage (one or more).",
          "oneOf": [
            {
              "type": "array",
              "uniqueItems": true,
              "items": {
                "type": "string",
                "enum": [
                  "EMEA",
                  "NA",
                  "APAC",
                  "LATAM"
                ]
              }
            },
            {
              "type": "string",
              "minLength": 1,
              "pattern": "^\\$\\{.*\\}$"
            },
            {
              "enum": [
                "${variables.VARIABLE_NAME}"
              ]
            }
          ]
        },
        "responsibilities": {
          "description": "The user's responsibilities (one or more).",
          "oneOf": [
            {
              "type": "array",
              "uniqueItems": true,
              "items": {
                "type": "string",
                "enum": [
                  "BAU",
                  "Escalation"
                ]
              }
            },
            {
              "type": "string",
              "minLength": 1,
              "pattern": "^\\$\\{.*\\}$"
            },
            {
              "enum": [
                "${variables.VARIABLE_NAME}"
              ]
            }
          ]
        },
        "instruments": {
          "description": "The user's instruments (one or more).",
          "oneOf": [
            {
              "type": "array",
              "uniqueItems": true,
              "items": {
                "type": "string",
                "enum": [
                  "Securities",
                  "Fixed Income",
                  "Equities"
                ]
              }
            },
            {
              "type": "string",
              "minLength": 1,
              "pattern": "^\\$\\{.*\\}$"
            },
            {
              "enum": [
                "${variables.VARIABLE_NAME}"
              ]
            }
          ]
        }
      },
      "additionalProperties": false
    },
    "create-user-inner": {
      "type": "object",
      "properties": {
        "email": {
          "description": "Email address, must be unique.",
          "$ref": "#/$defs/email"
        },
        "firstname": {
          "description": "User's first name.",
          "$ref": "#/$defs/name"
        },
        "lastname": {
          "description": "User's last name.",
          "$ref": "#/$defs/name"
        },
        "username": {
          "description": "Unique identifier for the user.",
          "$ref": "#/$defs/name"
        },
        "display-name": {
          "description": "User's display name.",
          "$ref": "#/$defs/name"
        },
        "recommended-language": {
          "type": "string",
          "description": "The recommended language. As an ISO 639-1 code.",
          "default": "en-US"
        },
        "contact": {
          "type": "object",
          "description": "Contact information",
          "properties": {
            "work-phone-number": {
              "description": "User's work phone number.",
              "$ref": "#/$defs/phoneNumber"
            },
            "mobile-phone-number": {
              "description": "User's mobile phone number.",
              "$ref": "#/$defs/phoneNumber"
            },
            "two-factor-auth-number": {
              "description": "User's two factor auth number.",
              "$ref": "#/$defs/phoneNumber"
            },
            "sms-number": {
              "description": "User's sms phone number.",
              "$ref": "#/$defs/phoneNumber"
            }
          },
          "additionalProperties": false
        },
        "business": {
          "description": "User's business information.",
          "$ref": "#/$defs/business"
        },
        "password": {
          "type": "object",
          "description": "User's password. The password object is optional for end-user accounts (NORMAL). For example, if your organization utilizes SSO, you may not want to specify the password.",
          "properties": {
            "hashed-password": {
              "description": "A base64-encoded string. The hashed password. This is the hashed version of the password the user would use to login.",
              "type": "string",
              "minLength": 1
            },
            "hashed-salt": {
              "description": "A base64-encoded string. The salt used for hashing the hPassword.",
              "type": "string",
              "minLength": 1
            },
            "hashed-km-password": {
              "description": "A base64-encoded string. The hashed password to be used for authenticating to the key manager.",
              "type": "string",
              "minLength": 1
            },
            "hashed-km-salt": {
              "description": "A base64-encoded string. The salt used for hashing the khPassword.",
              "type": "string",
              "minLength": 1
            }
          },
          "required": [
            "hashed-password",
            "hashed-salt"
          ],
          "additionalProperties": false
        },
        "roles": {
          "description": "The roles object consists of the following possibilities:\nFor end-user accounts: INDIVIDUAL, ADMINISTRATOR, SUPER_ADMINISTRATOR, L1_SUPPORT, L2_SUPPORT, COMPLIANCE_OFFICER, SUPER_COMPLIANCE_OFFICER\nFor service accounts: INDIVIDUAL, USER_PROVISIONING, SCOPE_MANAGEMENT, CONTENT_MANAGEMENT, MALWARE_SCAN_MANAGER, MALWARE_SCAN_STATE_USER, AUDIT_TRAIL_MANAGEMENT",
          "x-intellij-html-description": "<html><p>The roles object consists of the following possibilities:<li>For end-user accounts: INDIVIDUAL, ADMINISTRATOR, SUPER_ADMINISTRATOR, L1_SUPPORT, L2_SUPPORT, COMPLIANCE_OFFICER, SUPER_COMPLIANCE_OFFICER</li><li>For service accounts: INDIVIDUAL, USER_PROVISIONING, SCOPE_MANAGEMENT, CONTENT_MANAGEMENT, MALWARE_SCAN_MANAGER, MALWARE_SCAN_STATE_USER, AUDIT_TRAIL_MANAGEMENT</li><br/><a href=\"https://developers.symphony.com/restapi/reference#roles-object\">https://developers.symphony.com/restapi/reference#roles-object</a></p></html>",
          "$ref": "#/$defs/roles-inner"
        },
        "entitlements": {
          "description": "User entitlements.",
          "$ref": "#/$defs/entitlements-inner"
        },
        "status": {
          "type": "string",
          "description": "User status: ENABLED or DISABLED.",
          "enum": [
            "ENABLED",
            "DISABLED"
          ]
        }
      }
    },
    "create-system-user-inner": {
      "type": "object",
      "properties": {
        "email": {
          "description": "Email address, must be unique",
          "$ref": "#/$defs/email"
        },
        "username": {
          "description": "User's username.",
          "$ref": "#/$defs/name"
        },
        "display-name": {
          "description": "User's display name.",
          "$ref": "#/$defs/name"
        },
        "business": {
          "description": "User's business information.",
          "$ref": "#/$defs/business"
        },
        "keys": {
          "type": "object",
          "description": "For SYSTEM users, to set up the RSA keys for authentication.",
          "properties": {
            "current": {
              "$ref": "#/$defs/key-inner"
            },
            "previous": {
              "$ref": "#/$defs/key-inner"
            }
          }
        },
        "roles": {
          "description": "The roles object consists of the following possibilities:\nFor end-user accounts: INDIVIDUAL, ADMINISTRATOR, SUPER_ADMINISTRATOR, L1_SUPPORT, L2_SUPPORT, COMPLIANCE_OFFICER, SUPER_COMPLIANCE_OFFICER\nFor service accounts: INDIVIDUAL, USER_PROVISIONING, SCOPE_MANAGEMENT, CONTENT_MANAGEMENT, MALWARE_SCAN_MANAGER, MALWARE_SCAN_STATE_USER, AUDIT_TRAIL_MANAGEMENT",
          "x-intellij-html-description": "<html><p>The roles object consists of the following possibilities:<li>For end-user accounts: INDIVIDUAL, ADMINISTRATOR, SUPER_ADMINISTRATOR, L1_SUPPORT, L2_SUPPORT, COMPLIANCE_OFFICER, SUPER_COMPLIANCE_OFFICER</li><li>For service accounts: INDIVIDUAL, USER_PROVISIONING, SCOPE_MANAGEMENT, CONTENT_MANAGEMENT, MALWARE_SCAN_MANAGER, MALWARE_SCAN_STATE_USER, AUDIT_TRAIL_MANAGEMENT</li><br/><a href=\"https://developers.symphony.com/restapi/reference#roles-object\">https://developers.symphony.com/restapi/reference#roles-object</a></p></html>",
          "$ref": "#/$defs/roles-inner"
        },
        "entitlements": {
          "description": "User entitlements.",
          "$ref": "#/$defs/entitlements-inner"
        },
        "status": {
          "type": "string",
          "description": "User status: ENABLED or DISABLED.",
          "enum": [
            "ENABLED",
            "DISABLED"
          ]
        }
      }
    },
    "key-inner": {
      "type": "object",
      "properties": {
        "action": {
          "description": "A string indicating the action to be performed on the user's RSA.\n\nThe following actions can be performed on the user's active RSA key:\nSAVE\nREVOKE.\n\nThe following actions can be performed onto the user's rotated RSA key:\nREVOKE\nEXTEND.",
          "type": "string",
          "enum": [
            "SAVE",
            "EXTEND",
            "REVOKE"
          ]
        },
        "key": {
          "description": "A string containing the user's RSA public key. The key must be 4096 bits. Only PKCS8 format is allowed.",
          "type": "string",
          "minLength": 1
        },
        "expiration": {
          "description": "An ISO 8601 timestamp containing the RSA key expiration date. This value is only set for rotated keys.",
          "type": "string",
          "minLength": 1
        }
      },
      "additionalProperties": false
    },
    "entitlements-inner": {
      "description": "Feature entitlements to configure for the user.",
      "oneOf": [
        {
          "type": "object",
          "properties": {
            "postReadEnabled": {
              "type": [
                "boolean",
                "string"
              ],
              "description": "Allows the user to read wall posts."
            },
            "postWriteEnabled": {
              "type": [
                "boolean",
                "string"
              ],
              "description": "Allows the user to write wall posts."
            },
            "delegatesEnabled": {
              "type": [
                "boolean",
                "string"
              ],
              "description": "Allows the user to have delegates."
            },
            "isExternalIMEnabled": {
              "type": [
                "boolean",
                "string"
              ],
              "description": "Allows the user to chat in external IM/MIMs."
            },
            "canShareFilesExternally": {
              "type": [
                "boolean",
                "string"
              ],
              "description": "Allows the user to share files externally."
            },
            "canCreatePublicRoom": {
              "type": [
                "boolean",
                "string"
              ],
              "description": "Allows the user to create internal public rooms."
            },
            "canUpdateAvatar": {
              "type": [
                "boolean",
                "string"
              ],
              "description": "Allows the user to edit profile picture."
            },
            "isExternalRoomEnabled": {
              "type": [
                "boolean",
                "string"
              ],
              "description": "Allows the user to chat in private external rooms."
            },
            "canCreatePushedSignals": {
              "type": [
                "boolean",
                "string"
              ],
              "description": "Allows the user to create push signals."
            },
            "canUseCompactMode": {
              "type": [
                "boolean",
                "string"
              ],
              "description": "Enables Lite Mode."
            },
            "mustBeRecorded": {
              "type": [
                "boolean",
                "string"
              ],
              "description": "Must be recorded in meetings."
            },
            "sendFilesEnabled": {
              "type": [
                "boolean",
                "string"
              ],
              "description": "Allows the user to send files internally."
            },
            "canUseInternalAudio": {
              "type": [
                "boolean",
                "string"
              ],
              "description": "Allows the user to use audio in internal Meetings."
            },
            "canUseInternalVideo": {
              "type": [
                "boolean",
                "string"
              ],
              "description": "Allows the user to use video in internal Meetings."
            },
            "canProjectInternalScreenShare": {
              "type": [
                "boolean",
                "string"
              ],
              "description": "Allows the user to share screens in internal Meetings."
            },
            "canViewInternalScreenShare": {
              "type": [
                "boolean",
                "string"
              ],
              "description": "Allows the user to view shared screens in internal Meetings."
            },
            "canCreateMultiLateralRoom": {
              "type": [
                "boolean",
                "string"
              ],
              "description": "Allows the user to create multi-lateral room."
            },
            "canJoinMultiLateralRoom": {
              "type": [
                "boolean",
                "string"
              ],
              "description": "Allows the user to join multi-lateral room."
            },
            "canUseFirehose": {
              "type": [
                "boolean",
                "string"
              ],
              "description": "Allows the user to use Firehose."
            },
            "canUseInternalAudioMobile": {
              "type": [
                "boolean",
                "string"
              ],
              "description": "Allows the user to use audio in internal meetings on mobile."
            },
            "canUseInternalVideoMobile": {
              "type": [
                "boolean",
                "string"
              ],
              "description": "Allows the user to use video in internal meetings on mobile."
            },
            "canProjectInternalScreenShareMobile": {
              "type": [
                "boolean",
                "string"
              ],
              "description": "Allows the user to share screens in internal meetings on mobile."
            },
            "canViewInternalScreenShareMobile": {
              "type": [
                "boolean",
                "string"
              ],
              "description": "Allows the user to view shared screens in internal meetings on mobile."
            },
            "canManageSignalSubscription": {
              "type": [
                "boolean",
                "string"
              ],
              "description": "Allows the user to manage signal subscriptions."
            },
            "canCreateDatahose": {
              "type": [
                "boolean",
                "string"
              ],
              "description": "Can create datahose feeds."
            },
            "canIntegrateEmail": {
              "type": [
                "boolean",
                "string"
              ],
              "description": "Can integrate email service."
            },
            "canReadDatahose": {
              "type": [
                "boolean",
                "string"
              ],
              "description": "Can read from datahose feeds."
            },
            "canSuppressMessage": {
              "type": [
                "boolean",
                "string"
              ],
              "description": "Can suppress own messages."
            },
            "canSwitchToClient20": {
              "type": [
                "boolean",
                "string"
              ],
              "description": "Can switch to Client 2.0 experience."
            },
            "canUpdateRoomHistoryProperty": {
              "type": [
                "boolean",
                "string"
              ],
              "description": "Can Toggle Room's Share History Property."
            },
            "canUseEncryptAPI": {
              "type": [
                "boolean",
                "string"
              ],
              "description": "Allow user to use Agent Encrypt endpoints."
            },
            "enableSwiftSearch": {
              "type": [
                "boolean",
                "string"
              ],
              "description": "Can Use Swift Search."
            },
            "sdaDevtoolsEnabled": {
              "type": [
                "boolean",
                "string"
              ],
              "description": "Enable Developer Tools for SDA."
            },
            "sdaPermissionsFullScreen": {
              "type": [
                "boolean",
                "string"
              ],
              "description": "Enable Full screen access on SDA."
            },
            "sdaPermissionsGeoLocation": {
              "type": [
                "boolean",
                "string"
              ],
              "description": "Enable location access on SDA."
            },
            "sdaPermissionsMedia": {
              "type": [
                "boolean",
                "string"
              ],
              "description": "Enable Media access on SDA."
            },
            "sdaPermissionsMidiSysex": {
              "type": [
                "boolean",
                "string"
              ],
              "description": "Enable access to MIDI Sysex on SDA."
            },
            "sdaPermissionsNotifications": {
              "type": [
                "boolean",
                "string"
              ],
              "description": "Allow notifications on SDA."
            },
            "sdaPermissionsOpenExternalApp": {
              "type": [
                "boolean",
                "string"
              ],
              "description": "Allow Opening External Apps from SDA."
            },
            "sdaPermissionsPointerLock": {
              "type": [
                "boolean",
                "string"
              ],
              "description": "Enable Pointer Lock on SDA."
            }
          }
        },
        {
          "type": "string",
          "minLength": 1
        },
        {
          "enum": [
            "${variables.VARIABLE_NAME}"
          ]
        }
      ]
    },
    "roles-inner": {
      "description": "The roles object consists of the following possibilities:\nFor end-user accounts: INDIVIDUAL, ADMINISTRATOR, SUPER_ADMINISTRATOR, L1_SUPPORT, L2_SUPPORT, COMPLIANCE_OFFICER, SUPER_COMPLIANCE_OFFICER\nFor service accounts: INDIVIDUAL, USER_PROVISIONING, SCOPE_MANAGEMENT, CONTENT_MANAGEMENT, MALWARE_SCAN_MANAGER, MALWARE_SCAN_STATE_USER, AUDIT_TRAIL_MANAGEMENT",
      "x-intellij-html-description": "<html><p>The roles object consists of the following possibilities:<li>For end-user accounts: INDIVIDUAL, ADMINISTRATOR, SUPER_ADMINISTRATOR, L1_SUPPORT, L2_SUPPORT, COMPLIANCE_OFFICER, SUPER_COMPLIANCE_OFFICER</li><li>For service accounts: INDIVIDUAL, USER_PROVISIONING, SCOPE_MANAGEMENT, CONTENT_MANAGEMENT, MALWARE_SCAN_MANAGER, MALWARE_SCAN_STATE_USER, AUDIT_TRAIL_MANAGEMENT</li><br/><a href=\"https://developers.symphony.com/restapi/reference#roles-object\">https://developers.symphony.com/restapi/reference#roles-object</a></p></html>",
      "oneOf": [
        {
          "type": "array",
          "uniqueItems": true,
          "items": {
            "type": "string",
            "enum": [
              "INDIVIDUAL",
              "ADMINISTRATOR",
              "SUPER_ADMINISTRATOR",
              "L1_SUPPORT",
              "L2_SUPPORT",
              "COMPLIANCE_OFFICER",
              "SUPER_COMPLIANCE_OFFICER",
              "USER_PROVISIONING",
              "SCOPE_MANAGEMENT",
              "CONTENT_MANAGEMENT",
              "MALWARE_SCAN_MANAGER",
              "MALWARE_SCAN_STATE_USER",
              "AUDIT_TRAIL_MANAGEMENT",
              "AGENT",
              "CONTENT_EXPORT_SERVICE",
              "SYMPHONY_ADMIN",
              "KEY_MANAGER",
              "EF_POLICY_MANAGEMENT",
              "CEP_VISIBILITY_GROUP_MANAGEMENT"
            ]
          }
        },
        {
          "type": "string",
          "minLength": 1,
          "pattern": "^\\$\\{.*\\}$"
        },
        {
          "enum": [
            "${variables.VARIABLE_NAME}"
          ]
        }
      ]
    },
    "user-role-inner": {
      "type": "object",
      "properties": {
        "user-ids": {
          "description": "Users to add or remove roles from.",
          "oneOf": [
            {
              "type": "array",
              "uniqueItems": true,
              "minItems": 1,
              "items": {
                "type": [
                  "string",
                  "integer"
                ],
                "minLength": 1
              }
            },
            {
              "type": "string",
              "minLength": 1,
              "pattern": "^\\$\\{.*\\}$"
            },
            {
              "enum": [
                "${variables.VARIABLE_NAME}"
              ]
            }
          ]
        },
        "roles": {
          "$ref": "#/$defs/roles-inner"
        }
      },
      "required": [
        "user-ids",
        "roles"
      ]
    },
    "get-user-inner": {
      "type": "object",
      "properties": {
        "user-id": {
          "$ref": "#/$defs/user-id"
        }
      },
      "required": [
        "user-id"
      ]
    },
    "get-users-inner": {
      "type": "object",
      "properties": {
        "user-ids": {
          "$ref": "#/$defs/user-ids-inner"
        },
        "emails": {
          "description": "List of email addresses. Note that for this activity, you can use either the user-ids, the emails or the usernames, but only one at a time, you cannot mix and match them.",
          "oneOf": [
            {
              "type": "array",
              "items": {
                "$ref": "#/$defs/email"
              },
              "minLength": 1
            },
            {
              "type": "string",
              "minLength": 1,
              "pattern": "^\\$\\{.*\\}$"
            },
            {
              "enum": [
                "${variables.VARIABLE_NAME}"
              ]
            }
          ]
        },
        "usernames": {
          "description": "List of usernames. If username is specified, local must be set to true. Note that for this activity, you can use either the user-ids, the emails or the usernames, but only one at a time, you cannot mix and match them.",
          "oneOf": [
            {
              "type": "array",
              "items": {
                "$ref": "#/$defs/name"
              },
              "minLength": 1
            },
            {
              "type": "string",
              "minLength": 1,
              "pattern": "^\\$\\{.*\\}$"
            },
            {
              "enum": [
                "${variables.VARIABLE_NAME}"
              ]
            }
          ]
        },
        "local": {
          "type": [
            "boolean",
            "string"
          ],
          "description": "If true then a local DB search will be performed and only local pod users will be returned. If absent or false then a directory search will be performed and users from other pods who are visible to the calling user will also be returned.",
          "default": false
        },
        "active": {
          "type": [
            "boolean",
            "string"
          ],
          "description": "If true, it searches for active users only. If false, it searches for inactive users only. If not set, it searches for all users regardless of their status."
        },
        "obo": {
          "description": "Defines whether the activity will be executed on behalf of a user and the user on whose behalf the call will be made",
          "$ref": "#/$defs/obo-inner"
        }
      },
      "oneOf": [
        {
          "required": [
            "user-ids"
          ]
        },
        {
          "required": [
            "emails"
          ]
        },
        {
          "required": [
            "usernames"
          ]
        }
      ]
    },
    "get-stream-inner": {
      "properties": {
        "stream-id": {
          "$ref": "#/$defs/stream-id-inner"
        },
        "obo": {
          "description": "Defines whether the activity will be executed on behalf of a user and the user on whose behalf the call will be made",
          "$ref": "#/$defs/obo-inner"
        }
      },
      "required": [
        "stream-id"
      ],
      "type": "object"
    },
    "get-room-inner": {
      "properties": {
        "stream-id": {
          "$ref": "#/$defs/stream-id-inner"
        },
        "obo": {
          "description": "Defines whether the activity will be executed on behalf of a user and the user on whose behalf the call will be made",
          "$ref": "#/$defs/obo-inner"
        }
      },
      "required": [
        "stream-id"
      ],
      "type": "object"
    },
    "connection-inner": {
      "type": "object",
      "properties": {
        "user-id": {
          "$ref": "#/$defs/user-id"
        },
        "obo": {
          "description": "Defines whether the activity will be executed on behalf of a user and the user on whose behalf the call will be made",
          "$ref": "#/$defs/obo-inner"
        }
      },
      "required": [
        "user-id"
      ]
    },
    "get-stream-members-inner": {
      "properties": {
        "stream-id": {
          "description": "Id of the stream for which to return members.",
          "$ref": "#/$defs/stream-id-inner"
        },
        "limit": {
          "$ref": "#/$defs/limit"
        },
        "skip": {
          "$ref": "#/$defs/skip"
        }
      },
      "required": [
        "stream-id"
      ],
      "type": "object"
    },
    "get-room-members-inner": {
      "properties": {
        "stream-id": {
          "description": "Id of the stream for which to return members.",
          "$ref": "#/$defs/stream-id-inner"
        }
      },
      "required": [
        "stream-id"
      ],
      "type": "object"
    },
    "get-user-streams-inner": {
      "properties": {
        "types": {
          "description": "A list of stream types that will be returned. Options are IM (1-1 instant messages), MIM (multiparty instant messages), ROOM (rooms), POST (the user's wall). For more information, see the streamTypes section below.\nIf not specified, all types of streams are returned.",
          "oneOf": [
            {
              "type": "array",
              "items": {
                "type": "string",
                "enum": [
                  "IM",
                  "MIM",
                  "ROOM",
                  "POST"
                ]
              }
            },
            {
              "type": "string",
              "minLength": 1,
              "pattern": "^\\$\\{.*\\}$"
            },
            {
              "enum": [
                "${variables.VARIABLE_NAME}"
              ]
            }
          ]
        },
        "include-inactive-streams": {
          "type": [
            "boolean",
            "string"
          ],
          "description": "Whether to include inactive conversations. A chatroom is inactive if it has been deactivated by an owner or admin. An IM or MIM is inactive if one of the participating users has been deactivated by an admin. If not specified, only active streams are returned."
        },
        "limit": {
          "$ref": "#/$defs/limit"
        },
        "skip": {
          "$ref": "#/$defs/skip"
        },
        "obo": {
          "description": "Defines whether the activity will be executed on behalf of a user and the user on whose behalf the call will be made",
          "$ref": "#/$defs/obo-inner"
        }
      },
      "dependentRequired": {
        "skip": [
          "limit"
        ],
        "limit": [
          "skip"
        ]
      },
      "type": "object"
    },
    "get-message-inner": {
      "properties": {
        "message-id": {
          "description": "The message identifier.",
          "$ref": "#/$defs/message-id-inner"
        }
      },
      "required": [
        "message-id"
      ],
      "type": "object"
    },
    "get-streams-inner": {
      "properties": {
        "types": {
          "description": "A list of stream types that will be returned (IM, MIM, ROOM). If not specified, streams of all types are returned.",
          "oneOf": [
            {
              "type": "array",
              "items": {
                "type": "string",
                "enum": [
                  "IM",
                  "MIM",
                  "ROOM"
                ]
              }
            },
            {
              "type": "string",
              "minLength": 1,
              "pattern": "^\\$\\{.*\\}$"
            },
            {
              "enum": [
                "${variables.VARIABLE_NAME}"
              ]
            }
          ]
        },
        "scope": {
          "type": "string",
          "enum": [
            "INTERNAL",
            "EXTERNAL"
          ],
          "description": "The scope of the stream: INTERNAL (restricted to members of the calling user's company) or EXTERNAL (including members of the calling user's company, as well as another firm). If not specified, returns streams of either scope."
        },
        "origin": {
          "type": "string",
          "enum": [
            "INTERNAL",
            "EXTERNAL"
          ],
          "description": "The origin of the room: INTERNAL (created by a user of the calling user's company) or EXTERNAL (created by a user of another company). If not specified, returns streams of either origin. Only applies to chatrooms with External scope."
        },
        "privacy": {
          "type": "string",
          "enum": [
            "PRIVATE",
            "PUBLIC"
          ],
          "description": "The privacy setting of the room: PRIVATE (members must be added) or PUBLIC (anyone can join). If not specified, returns both private and public rooms. Only applies to chatrooms with internal scope."
        },
        "status": {
          "type": "string",
          "enum": [
            "ACTIVE",
            "INACTIVE"
          ],
          "description": "The status of the room: ACTIVE or INACTIVE. If not specified, both active and inactive streams are returned."
        },
        "start-date": {
          "type": "string",
          "description": "Restricts result set to rooms that have been modified since this date (ISO 8601). When specified along with end-date, enables the developer to specify rooms modified within a given time range."
        },
        "end-date": {
          "type": "string",
          "description": "Restricts result set to rooms that have been modified prior to this date (ISO 8601). When specified along with start-date, enables the developer to specify rooms modified within a given time range."
        },
        "limit": {
          "$ref": "#/$defs/limit"
        },
        "skip": {
          "$ref": "#/$defs/skip"
        }
      }
    },
    "get-rooms-inner": {
      "properties": {
        "query": {
          "description": "The query which is searched for in room name, description, and optionally keywords. Case-insensitive.",
          "type": "string",
          "minLength": 1
        },
        "labels": {
          "description": "A list of room keywords whose values will be queried.",
          "oneOf": [
            {
              "type": "array",
              "items": {
                "type": "string"
              }
            },
            {
              "type": "string",
              "minLength": 1,
              "pattern": "^\\$\\{.*\\}$"
            },
            {
              "enum": [
                "${variables.VARIABLE_NAME}"
              ]
            }
          ]
        },
        "active": {
          "type": [
            "boolean",
            "string"
          ],
          "description": "If true, it restricts the search to active rooms. If false, it restricts the search to inactive rooms. If not specified, it includes both active and inactive rooms. Note that for inactive rooms, only rooms where the calling user is a member will be in the search scope; read the box “Room Search Scope” for further details."
        },
        "private": {
          "type": [
            "boolean",
            "string"
          ],
          "description": "If true, it includes only private rooms in the search results. If false, only public rooms are returned. If not specified, both public and private rooms are returned. Note that for inactive rooms, only discoverable rooms and rooms where the calling user is a member will be in the search scope; read the box “Room Search Scope” for further details."
        },
        "creator-id": {
          "type": [
            "string",
            "number"
          ],
          "description": "If provided, restrict the search to rooms created by the specified user.",
          "minLength": 1
        },
        "owner-id": {
          "type": [
            "string",
            "number"
          ],
          "description": "If provided, restrict the search to rooms owned by the specified user.",
          "minLength": 1
        },
        "member-id": {
          "type": [
            "string",
            "number"
          ],
          "description": "If provided, restrict the search to rooms where the specified user is a member.",
          "minLength": 1
        },
        "sort-order": {
          "type": "string",
          "enum": [
            "BASIC",
            "RELEVANCE"
          ],
          "description": "Sort algorithm to be used. Supports two values: BASIC (legacy algorithm) and RELEVANCE (enhanced algorithm)."
        },
        "limit": {
          "$ref": "#/$defs/limit"
        },
        "skip": {
          "$ref": "#/$defs/skip"
        },
        "obo": {
          "description": "Defines whether the activity will be executed on behalf of a user and the user on whose behalf the call will be made",
          "$ref": "#/$defs/obo-inner"
        }
      },
      "required": [
        "query"
      ],
      "type": "object"
    },
    "get-messages-inner": {
      "type": "object",
      "properties": {
        "stream-id": {
          "description": "Stream identifier.",
          "$ref": "#/$defs/stream-id-inner"
        },
        "since": {
          "description": "Date, in ISO 8601 format, of the earliest possible data of the first message returned.",
          "anyOf": [
            {
              "enum": [
                "${variables.VARIABLE_NAME}"
              ]
            },
            {
              "type": "string",
              "minLength": 1
            }
          ],
          "default": "2021-08-31T15:50:00Z"
        },
        "skip": {
          "$ref": "#/$defs/skip"
        },
        "limit": {
          "$ref": "#/$defs/limit"
        }
      },
      "required": [
        "stream-id",
        "since"
      ]
    },
    "get-connections-inner": {
      "type": "object",
      "properties": {
        "user-ids": {
          "description": "List of user ids that this activity results will be restricted to their connections.",
          "$ref": "#/$defs/user-ids-inner"
        },
        "status": {
          "type": "string",
          "enum": [
            "PENDING_INCOMING",
            "PENDING_OUTGOING",
            "ACCEPTED",
            "REJECTED",
            "ALL"
          ]
        },
        "obo": {
          "description": "Defines whether the activity will be executed on behalf of a user and the user on whose behalf the call will be made",
          "$ref": "#/$defs/obo-inner"
        }
      }
    },
    "create-group-inner": {
      "type": "object",
      "properties": {
        "type": {
          "type": "string",
          "description": "Group type identifier (for instance SDL).",
          "minLength": 1
        },
        "owner": {
          "type": "object",
          "$ref": "#/$defs/group-owner"
        },
        "name": {
          "type": "string",
          "description": "Group's name.",
          "minLength": 1
        },
        "sub-type": {
          "type": "string",
          "description": "The type of the company new groupType.",
          "enum": [
            "COMMUNITY",
            "CHANNEL"
          ]
        },
        "referrer": {
          "type": "string",
          "description": "Symphony, referring company name, referring channel partner name.",
          "minLength": 1
        },
        "members": {
          "type": "array",
          "oneOf": [
            {
              "type": "array",
              "uniqueItems": true,
              "items": {
                "$ref": "#/$defs/group-member"
              }
            },
            {
              "type": "string",
              "minLength": 1,
              "pattern": "^\\$\\{.*\\}$"
            },
            {
              "enum": [
                "${variables.VARIABLE_NAME}"
              ]
            }
          ]
        },
        "profile": {
          "$ref": "#/$defs/group-profile"
        }
      }
    },
    "group-owner": {
      "type": "object",
      "required": [
        "id",
        "type"
      ],
      "properties": {
        "id": {
          "anyOf": [
            {
              "type": [
                "string",
                "integer"
              ],
              "minLength": 1
            },
            {
              "enum": [
                "${variables.VARIABLE_NAME}"
              ]
            }
          ],
          "description": "Owner id if the owner type is tenant (podId) or user (userId), otherwise null."
        },
        "type": {
          "type": "string",
          "default": "TENANT",
          "description": "Owner type. Only TENANT supported now.",
          "enum": [
            "TENANT",
            "PLATFORM",
            "USER"
          ]
        }
      }
    },
    "group-member": {
      "type": "object",
      "required": [
        "user-id",
        "tenant-id"
      ],
      "properties": {
        "user-id": {
          "type": [
            "string",
            "integer"
          ],
          "minLength": 1,
          "minimum": 0,
          "description": "Member's user id."
        },
        "tenant-id": {
          "type": [
            "string",
            "integer"
          ],
          "minLength": 1,
          "minimum": 0,
          "description": "Member's tenant id."
        }
      }
    },
    "group-profile": {
      "type": "object",
      "required": [
        "display-name"
      ],
      "properties": {
        "display-name": {
          "type": "string",
          "description": "The display name in Directory, it is expected to be the same as group name."
        },
        "company-name": {
          "type": "string",
          "description": "The company name is expected to be the same as group company owner."
        },
        "email": {
          "type": "string"
        },
        "mobile": {
          "type": "string"
        },
        "job": {
          "type": "object",
          "properties": {
            "title": {
              "type": "string"
            },
            "role": {
              "type": "string"
            },
            "department": {
              "type": "string"
            },
            "division": {
              "type": "string"
            },
            "phone": {
              "type": "string"
            },
            "city": {
              "type": "string"
            }
          }
        },
        "asset-classes": {
          "description": "The group's asset classes (one or more).",
          "oneOf": [
            {
              "type": "array",
              "uniqueItems": true,
              "items": {
                "type": "string",
                "enum": [
                  "Equities",
                  "Cash Equities",
                  "Securities Lending",
                  "Fixed Income",
                  "Government Bonds",
                  "Prime Brokerage",
                  "Commodities",
                  "Municipal Bonds",
                  "Currencies",
                  "Corporate Bonds"
                ]
              }
            },
            {
              "type": "string",
              "minLength": 1,
              "pattern": "^\\$\\{.*\\}$"
            },
            {
              "enum": [
                "${variables.VARIABLE_NAME}"
              ]
            }
          ]
        },
        "industries": {
          "description": "The group's job industries (one or more).",
          "oneOf": [
            {
              "type": "array",
              "uniqueItems": true,
              "items": {
                "type": "string",
                "enum": [
                  "Healthcare",
                  "Consumer Non-Cyclicals",
                  "Transportation",
                  "Technology",
                  "Real Estate",
                  "Basic Materials",
                  "Financials",
                  "Energy & Utilities",
                  "Conglomerates",
                  "Consumer Cyclicals",
                  "Services"
                ]
              }
            },
            {
              "type": "string",
              "minLength": 1,
              "pattern": "^\\$\\{.*\\}$"
            },
            {
              "enum": [
                "${variables.VARIABLE_NAME}"
              ]
            }
          ]
        },
        "functions": {
          "description": "The group's job functions (one or more).",
          "oneOf": [
            {
              "type": "array",
              "uniqueItems": true,
              "items": {
                "type": "string",
                "enum": [
                  "Collateral",
                  "Confirmation",
                  "Trade Processing",
                  "Pre-Matching",
                  "Margin",
                  "Matching",
                  "Claims Processing",
                  "Middle Office",
                  "Liquidity Management",
                  "Allocation",
                  "Trade Management",
                  "Regulatory Outreach",
                  "Settlements",
                  "Post Trade Management"
                ]
              }
            },
            {
              "type": "string",
              "minLength": 1,
              "pattern": "^\\$\\{.*\\}$"
            },
            {
              "enum": [
                "${variables.VARIABLE_NAME}"
              ]
            }
          ]
        },
        "market-coverages": {
          "description": "The group's market coverage (one or more).",
          "oneOf": [
            {
              "type": "array",
              "uniqueItems": true,
              "items": {
                "type": "string",
                "enum": [
                  "EMEA",
                  "NA",
                  "APAC",
                  "LATAM"
                ]
              }
            },
            {
              "type": "string",
              "minLength": 1,
              "pattern": "^\\$\\{.*\\}$"
            },
            {
              "enum": [
                "${variables.VARIABLE_NAME}"
              ]
            }
          ]
        },
        "responsibilities": {
          "description": "The group's responsibilities (one or more).",
          "oneOf": [
            {
              "type": "array",
              "uniqueItems": true,
              "items": {
                "type": "string",
                "enum": [
                  "BAU",
                  "Escalation"
                ]
              }
            },
            {
              "type": "string",
              "minLength": 1,
              "pattern": "^\\$\\{.*\\}$"
            },
            {
              "enum": [
                "${variables.VARIABLE_NAME}"
              ]
            }
          ]
        },
        "instruments": {
          "description": "The group's instruments (one or more).",
          "oneOf": [
            {
              "type": "array",
              "uniqueItems": true,
              "items": {
                "type": "string",
                "enum": [
                  "Securities",
                  "Fixed Income",
                  "Equities"
                ]
              }
            },
            {
              "type": "string",
              "minLength": 1,
              "pattern": "^\\$\\{.*\\}$"
            },
            {
              "enum": [
                "${variables.VARIABLE_NAME}"
              ]
            }
          ]
        },
        "visibility-restriction": {
          "type": "object",
          "$ref": "#/$defs/tenants-users-list"
        },
        "implicit-connection": {
          "type": "object",
          "$ref": "#/$defs/tenants-users-list"
        },
        "interaction-transfer": {
          "type": "object",
          "$ref": "#/$defs/tenants-users-list"
        }
      }
    },
    "tenants-users-list": {
      "type": "object",
      "properties": {
        "user-ids": {
          "oneOf": [
            {
              "type": "array",
              "uniqueItems": true,
              "items": {
                "type": [
                  "string",
                  "integer"
                ],
                "minLength": 1,
                "minimum": 0
              }
            },
            {
              "type": "string",
              "minLength": 1,
              "pattern": "^\\$\\{.*\\}$"
            },
            {
              "enum": [
                "${variables.VARIABLE_NAME}"
              ]
            }
          ]
        },
        "tenant-ids": {
          "oneOf": [
            {
              "type": "array",
              "uniqueItems": true,
              "items": {
                "type": [
                  "string",
                  "integer"
                ],
                "minLength": 1,
                "minimum": 0
              }
            },
            {
              "type": "string",
              "minLength": 1,
              "pattern": "^\\$\\{.*\\}$"
            },
            {
              "enum": [
                "${variables.VARIABLE_NAME}"
              ]
            }
          ]
        }
      }
    },
    "update-group-inner": {
      "type": "object",
      "required": [
        "group-id"
      ],
      "properties": {
        "group-id": {
          "$ref": "#/$defs/group-id"
        },
        "status": {
          "type": "string",
          "description": "Status flag to distinguish between active and deleted objects. Required to update group fields except the image-path.",
          "enum": [
            "ACTIVE",
            "DELETED"
          ]
        },
        "e-tag": {
          "type": "string",
          "description": "Required to update group fields except the image-path."
        },
        "image-path": {
          "description": "Path to the file to be uploaded as the group's avatar. The path is relative to the workflows folder.",
          "anyOf": [
            {
              "enum": [
                "${variables.VARIABLE_NAME}"
              ]
            },
            {
              "type": "string",
              "minLength": 1
            }
          ]
        }
      }
    },
    "get-group-inner": {
      "type": "object",
      "required": [
        "group-id"
      ],
      "properties": {
        "group-id": {
          "$ref": "#/$defs/group-id"
        }
      }
    },
    "get-groups-inner": {
      "type": "object",
      "required": [
        "type"
      ],
      "properties": {
        "type": {
          "type": "string",
          "minLength": 1,
          "default": "SDL",
          "description": "Group type id."
        },
        "status": {
          "type": "string",
          "description": "Filter by status, active or deleted. If not specified both are returned.",
          "enum": [
            "ACTIVE",
            "DELETED"
          ]
        },
        "before": {
          "type": "string",
          "minLength": 1,
          "description": "NOT SUPPORTED YET, currently ignored. Cursor that points to the start of the current page of data. If not present, the current page is the first page."
        },
        "after": {
          "type": "string",
          "minLength": 1,
          "description": "Cursor that points to the end of the current page of data. If not present, the current page is the last page."
        },
        "limit": {
          "type": [
            "string",
            "integer"
          ],
          "minLength": 1,
          "minimum": 0,
          "description": "Numbers of items to return.",
          "default": 100
        },
        "sort-order": {
          "type": "string",
          "enum": [
            "ASC",
            "DESC"
          ]
        }
      }
    },
    "add-group-member-inner": {
      "type": "object",
      "required": [
        "group-id"
      ],
      "properties": {
        "group-id": {
          "$ref": "#/$defs/group-id"
        },
        "members": {
          "type": "array",
          "oneOf": [
            {
              "type": "array",
              "uniqueItems": true,
              "items": {
                "$ref": "#/$defs/group-member"
              }
            },
            {
              "type": "string",
              "minLength": 1,
              "pattern": "^\\$\\{.*\\}$"
            },
            {
              "enum": [
                "${variables.VARIABLE_NAME}"
              ]
            }
          ]
        }
      }
    },
    "group-id": {
      "anyOf": [
        {
          "type": [
            "string",
            "integer"
          ],
          "minLength": 1
        },
        {
          "enum": [
            "${variables.VARIABLE_NAME}"
          ]
        }
      ],
      "description": "Group's unique identifier."
    },
    "obo-inner": {
      "type": "object",
      "description": "Defines whether the activity will be executed on behalf of a user and the user on whose behalf the call will be made.",
      "properties": {
        "user-id": {
          "$ref": "#/$defs/user-id"
        },
        "username": {
          "$ref": "#/$defs/name"
        }
      },
      "anyOf": [
        {
          "required": [
            "user-id"
          ]
        },
        {
          "required": [
            "username"
          ]
        }
      ]
    },
    "to": {
      "type": "object",
      "oneOf": [
        {
          "$ref": "#/$defs/stream-id"
        },
        {
          "$ref": "#/$defs/stream-ids"
        },
        {
          "$ref": "#/$defs/user-ids"
        }
      ]
    },
    "content-inner": {
      "description": "The content of the message in MessageML format. Must contain at least one space. In case the content is a form, this latter's id should be the same as the activity one.",
      "oneOf": [
        {
          "enum": [
            "${variables.VARIABLE_NAME}",
            "${text(ACTIVITY_ID.outputs.message.message)}",
            "${event.args.NAME}",
            "<mention uid='${ACTIVITY_ID.outputs.user.userSystemInfo.id}'/>",
            "<mention uid='${event.initiator.user.userId}'/>"
          ]
        },
        {
          "type": "object",
          "properties": {
            "template": {
              "type": "string",
              "description": "Inline template message content in string.",
              "minLength": 1
            },
            "template-path": {
              "type": "string",
              "description": "External message template file path.",
              "minLength": 1
            }
          },
          "oneOf": [
            {
              "required": [
                "template"
              ]
            },
            {
              "required": [
                "template-path"
              ]
            }
          ]
        },
        {
          "type": "string",
          "minLength": 0
        }
      ]
    },
    "skip": {
      "description": "Number of elements to be skipped during return - used for pagination.",
      "anyOf": [
        {
          "enum": [
            "${variables.VARIABLE_NAME}"
          ]
        },
        {
          "type": [
            "integer",
            "string"
          ],
          "minimum": 0
        }
      ]
    },
    "limit": {
      "description": "Maximum number of elements to be returned - used for pagination.",
      "anyOf": [
        {
          "enum": [
            "${variables.VARIABLE_NAME}"
          ]
        },
        {
          "type": [
            "integer",
            "string"
          ],
          "maximum": 1000,
          "minimum": 1
        }
      ]
    },
    "id": {
      "type": "string",
      "minLength": 1
    },
    "message-id-inner": {
      "description": "Message identifier. Both safe url and Base64 encoded urls are accepted.",
      "anyOf": [
        {
          "enum": [
            "${variables.VARIABLE_NAME}",
            "${ACTIVITY_ID.outputs.msgId}",
            "${ACTIVITY_ID.outputs.message.messageId}",
            "${ACTIVITY_ID.outputs.message.initialMessageId}"
          ]
        },
        {
          "$ref": "#/$defs/id"
        }
      ]
    },
    "stream-id-inner": {
      "description": "Stream identifier. Both safe url and Base64 encoded urls are accepted.",
      "anyOf": [
        {
          "enum": [
            "${event.source.message.stream.streamId}",
            "${variables.VARIABLE_NAME}",
            "${ACTIVITY_ID.outputs.roomId}",
            "${ACTIVITY_ID.outputs.stream.id}"
          ]
        },
        {
          "$ref": "#/$defs/id"
        }
      ]
    },
    "stream-id": {
      "type": "object",
      "description": "Stream id to sent the message to.",
      "properties": {
        "stream-id": {
          "$ref": "#/$defs/stream-id-inner"
        }
      },
      "required": [
        "stream-id"
      ]
    },
    "stream-ids": {
      "type": "object",
      "description": "Stream ids to sent the message to (blast message).",
      "properties": {
        "stream-ids": {
          "oneOf": [
            {
              "type": "array",
              "minLength": 1,
              "items": {
                "type": "string"
              },
              "uniqueItems": true
            },
            {
              "type": "string",
              "minLength": 1,
              "pattern": "^\\$\\{.*\\}$"
            },
            {
              "enum": [
                "${variables.VARIABLE_NAME}"
              ]
            }
          ]
        }
      },
      "required": [
        "stream-ids"
      ]
    },
    "user-ids-inner": {
      "description": "User identifiers list.",
      "oneOf": [
        {
          "type": "array",
          "items": {
            "$ref": "#/$defs/user-id"
          },
          "minLength": 1,
          "uniqueItems": true
        },
        {
          "type": "string",
          "minLength": 1,
          "pattern": "^\\$\\{.*\\}$"
        },
        {
          "enum": [
            "${variables.VARIABLE_NAME}"
          ]
        }
      ]
    },
    "user-ids": {
      "type": "object",
      "description": "List of user ids.",
      "properties": {
        "user-ids": {
          "$ref": "#/$defs/user-ids-inner"
        }
      },
      "required": [
        "user-ids"
      ]
    },
    "user-id": {
      "description": "User id.",
      "anyOf": [
        {
          "type": [
            "string",
            "integer"
          ],
          "minLength": 1
        },
        {
          "enum": [
            "${ACTIVITY_ID.outputs.user.userSystemInfo.id}",
            "${event.initiator.user.userId}",
            "${event.source.fromUser.userId}",
            "${event.source.toUser.userId}"
          ]
        }
      ]
    },
    "attachment": {
      "type": "object",
      "oneOf": [
        {
          "$ref": "#/$defs/attachment-message"
        },
        {
          "$ref": "#/$defs/attachment-file"
        }
      ]
    },
    "single-attachment": {
      "type": "string",
      "minLength": 1
    },
    "attachment-message": {
      "type": "object",
      "properties": {
        "message-id": {
          "description": "Message id having the attachment to forward. Both url safe and base64 encoded urls are accepted.",
          "$ref": "#/$defs/message-id-inner"
        },
        "attachment-id": {
          "description": "Attachment id to forward. If not set, all attachments in the provided message are forwarded. Both url safe and base64 encoded urls are accepted.",
          "anyOf": [
            {
              "enum": [
                "${variables.VARIABLE_NAME}"
              ]
            },
            {
              "type": "string",
              "minLength": 1
            }
          ]
        }
      },
      "required": [
        "message-id"
      ]
    },
    "attachment-file": {
      "type": "object",
      "required": [
        "content-path"
      ],
      "properties": {
        "content-path": {
          "description": "Path to the file to be attached to the message. The path is relative to the workflows folder.",
          "anyOf": [
            {
              "enum": [
                "${variables.VARIABLE_NAME}"
              ]
            },
            {
              "type": "string",
              "minLength": 1
            }
          ]
        }
      }
    }
  },
  "additionalProperties": false,
  "default": {},
  "required": [
    "id",
    "activities"
  ]
}
