diff --git a/BotProject/Templates/CSharp/BotProject.csproj b/BotProject/Templates/CSharp/BotProject.csproj index 05398bc44c..3b888c5943 100644 --- a/BotProject/Templates/CSharp/BotProject.csproj +++ b/BotProject/Templates/CSharp/BotProject.csproj @@ -1,6 +1,6 @@  - netcoreapp2.1 + netcoreapp3.1 @@ -13,26 +13,24 @@ Always - + BotProject.ruleset BotProject.ruleset - - - - - - - - - - - - + + + + + + + + + + all diff --git a/BotProject/Templates/CSharp/Program.cs b/BotProject/Templates/CSharp/Program.cs index fd4a5e14f0..01920c40ba 100644 --- a/BotProject/Templates/CSharp/Program.cs +++ b/BotProject/Templates/CSharp/Program.cs @@ -7,6 +7,7 @@ using Microsoft.AspNetCore; using Microsoft.AspNetCore.Hosting; using Microsoft.Extensions.Configuration; +using Microsoft.Extensions.Hosting; namespace Microsoft.Bot.Builder.ComposerBot.Json { diff --git a/BotProject/Templates/CSharp/Schemas/sdk.schema b/BotProject/Templates/CSharp/Schemas/sdk.schema index 0e6b7f0c65..1fafc1696f 100644 --- a/BotProject/Templates/CSharp/Schemas/sdk.schema +++ b/BotProject/Templates/CSharp/Schemas/sdk.schema @@ -10,6 +10,11 @@ "description": "", "$ref": "#/definitions/Microsoft.ActivityTemplate" }, + { + "title": "Microsoft.AdaptiveCardRecognizer", + "description": "Recognizer for detecting the value response from an Adaptive Card.", + "$ref": "#/definitions/Microsoft.AdaptiveCardRecognizer" + }, { "title": "Microsoft.AdaptiveDialog", "description": "Flexible, data driven dialog that can adapt to the conversation.", @@ -20,6 +25,11 @@ "description": "Recognizer which recognizes age.", "$ref": "#/definitions/Microsoft.AgeEntityRecognizer" }, + { + "title": "Microsoft.Ask", + "description": "This is an action which sends an activity to the user when a response is expected", + "$ref": "#/definitions/Microsoft.Ask" + }, { "title": "Microsoft.AttachmentInput", "description": "Collect information - Ask for a file or image.", @@ -30,6 +40,11 @@ "description": "Begin another dialog.", "$ref": "#/definitions/Microsoft.BeginDialog" }, + { + "title": "Microsoft.BreakLoop", + "description": "Stop executing this loop", + "$ref": "#/definitions/Microsoft.BreakLoop" + }, { "title": "Microsoft.CancelAllDialogs", "description": "Cancel all active dialogs. All dialogs in the dialog chain will need a trigger to capture the event configured in this action.", @@ -55,6 +70,16 @@ "description": "Recognizer which recognizes confirmation choices (yes/no).", "$ref": "#/definitions/Microsoft.ConfirmationEntityRecognizer" }, + { + "title": "Microsoft.ContinueLoop", + "description": "Stop executing this template and continue with the next iteration of the loop.", + "$ref": "#/definitions/Microsoft.ContinueLoop" + }, + { + "title": "Microsoft.CrossTrainedRecognizerSet", + "description": "Recognizer for selecting between cross trained recognizers.", + "$ref": "#/definitions/Microsoft.CrossTrainedRecognizerSet" + }, { "title": "Microsoft.CurrencyEntityRecognizer", "description": "Recognizer which recognizes currency.", @@ -75,6 +100,11 @@ "description": "If debugger is attached, stop the execution at this point in the conversation.", "$ref": "#/definitions/Microsoft.DebugBreak" }, + { + "title": "Microsoft.DeleteActivity", + "description": "Delete an activity that was previously sent.", + "$ref": "#/definitions/Microsoft.DeleteActivity" + }, { "title": "Microsoft.DeleteProperties", "description": "Delete multiple properties and any value it holds.", @@ -135,6 +165,21 @@ "description": "Execute actions on each page (collection of items) in an array.", "$ref": "#/definitions/Microsoft.ForeachPage" }, + { + "title": "Microsoft.GetActivityMembers", + "description": "Get the members who are participating in an activity. (BotFrameworkAdapter only)", + "$ref": "#/definitions/Microsoft.GetActivityMembers" + }, + { + "title": "Microsoft.GetConversationMembers", + "description": "Get the members who are participating in an conversation. (BotFrameworkAdapter only)", + "$ref": "#/definitions/Microsoft.GetConversationMembers" + }, + { + "title": "Microsoft.GotoAction", + "description": "Go to an an action by id.", + "$ref": "#/definitions/Microsoft.GotoAction" + }, { "title": "Microsoft.GuidEntityRecognizer", "description": "Recognizer which recognizes guids.", @@ -155,11 +200,6 @@ "description": "Two-way branch the conversation flow based on a condition.", "$ref": "#/definitions/Microsoft.IfCondition" }, - { - "title": "Microsoft.InitProperty", - "description": "Define and initialize a property to be an array or object.", - "$ref": "#/definitions/Microsoft.InitProperty" - }, { "title": "Microsoft.IpEntityRecognizer", "description": "Recognizer which recognizes internet IP patterns (like 192.1.1.1).", @@ -220,6 +260,11 @@ "description": "Actions to perform on receipt of a generic activity.", "$ref": "#/definitions/Microsoft.OnActivity" }, + { + "title": "Microsoft.OnAssignEntity", + "description": "Actions to take when an entity should be assigned to a property.", + "$ref": "#/definitions/Microsoft.OnAssignEntity" + }, { "title": "Microsoft.OnBeginDialog", "description": "Actions to perform when this dialog begins.", @@ -230,6 +275,26 @@ "description": "Actions to perform on cancel dialog event.", "$ref": "#/definitions/Microsoft.OnCancelDialog" }, + { + "title": "Microsoft.OnChooseEntity", + "description": "Actions to be performed when an entity value needs to be resolved.", + "$ref": "#/definitions/Microsoft.OnChooseEntity" + }, + { + "title": "Microsoft.OnChooseIntent", + "description": "Actions to perform on when an intent is ambigious.", + "$ref": "#/definitions/Microsoft.OnChooseIntent" + }, + { + "title": "Microsoft.OnChooseProperty", + "description": "Actions to take when there are multiple possible mappings of entities to properties.", + "$ref": "#/definitions/Microsoft.OnChooseProperty" + }, + { + "title": "Microsoft.OnClearProperty", + "description": "Actions to take when a property needs to be cleared.", + "$ref": "#/definitions/Microsoft.OnClearProperty" + }, { "title": "Microsoft.OnCondition", "description": "Actions to perform when specified condition is true.", @@ -250,6 +315,11 @@ "description": "Actions to perform when a specific dialog event occurs.", "$ref": "#/definitions/Microsoft.OnDialogEvent" }, + { + "title": "Microsoft.OnEndOfActions", + "description": "Actions to take when there are no more actions in the current dialog.", + "$ref": "#/definitions/Microsoft.OnEndOfActions" + }, { "title": "Microsoft.OnEndOfConversationActivity", "description": "Actions to perform on receipt of an activity with type 'EndOfConversation'.", @@ -300,6 +370,11 @@ "description": "Actions to perform on receipt of an activity with type 'MessageUpdate'.", "$ref": "#/definitions/Microsoft.OnMessageUpdateActivity" }, + { + "title": "Microsoft.OnQnAMatch", + "description": "Actions to perform on when an match from QnAMaker is found.", + "$ref": "#/definitions/Microsoft.OnQnAMatch" + }, { "title": "Microsoft.OnRepromptDialog", "description": "Actions to perform when 'RepromptDialog' event occurs.", @@ -335,11 +410,21 @@ "description": "Dialog which uses QnAMAker knowledge base to answer questions.", "$ref": "#/definitions/Microsoft.QnAMakerDialog" }, + { + "title": "Microsoft.QnAMakerRecognizer", + "description": "Recognizer for generating QnAMatch intents from a KB.", + "$ref": "#/definitions/Microsoft.QnAMakerRecognizer" + }, { "title": "Microsoft.RandomSelector", "description": "Select most specific true rule", "$ref": "#/definitions/Microsoft.RandomSelector" }, + { + "title": "Microsoft.RecognizerSet", + "description": "Creates the union of the intents and entities of the recognizers in the set.", + "$ref": "#/definitions/Microsoft.RecognizerSet" + }, { "title": "Microsoft.RegExEntityRecognizer", "description": "Recognizer which recognizes patterns of input based on regex.", @@ -375,6 +460,11 @@ "description": "Set property to a value.", "$ref": "#/definitions/Microsoft.SetProperty" }, + { + "title": "Microsoft.SignOutUser", + "description": "Sign a user out that was logged in previously using OAuthInput.", + "$ref": "#/definitions/Microsoft.SignOutUser" + }, { "title": "Microsoft.StaticActivityTemplate", "description": "This allows you to define a static Activity object", @@ -460,6 +550,11 @@ "description": "Selector for all true events", "$ref": "#/definitions/Microsoft.TrueSelector" }, + { + "title": "Microsoft.UpdateActivity", + "description": "Respond with an activity.", + "$ref": "#/definitions/Microsoft.UpdateActivity" + }, { "title": "Microsoft.UrlEntityRecognizer", "description": "Recognizer which recognizes urls (example: http://bing.com)", @@ -524,6 +619,63 @@ } ] }, + "Microsoft.AdaptiveCardRecognizer": { + "$role": "union(Microsoft.Recognizer)", + "title": "Cross-trained Recognizer Set", + "description": "Recognizer for detecting the value response from an Adaptive Card.", + "type": "object", + "properties": { + "$kind": { + "title": "$kind", + "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", + "type": "string", + "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", + "const": "Microsoft.AdaptiveCardRecognizer" + }, + "$copy": { + "title": "$copy", + "description": "Copy the definition by id from a .dialog file.", + "type": "string", + "pattern": "^(([a-zA-Z][a-zA-Z0-9.]*)?(#[a-zA-Z][a-zA-Z0-9.]*)?)$" + }, + "$id": { + "title": "$id", + "description": "Inline id for reuse of an inline definition", + "type": "string", + "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" + }, + "$designer": { + "title": "$designer", + "type": "object", + "description": "Extra information for the Bot Framework Designer." + }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional unique id using with RecognizerSet." + } + }, + "additionalProperties": false, + "patternProperties": { + "^\\$": { + "type": "string" + } + }, + "anyOf": [ + { + "title": "Reference", + "required": [ + "$copy" + ] + }, + { + "title": "Type", + "required": [ + "$kind" + ] + } + ] + }, "Microsoft.AdaptiveDialog": { "$role": "union(Microsoft.IDialog)", "title": "Adaptive Dialog", @@ -572,10 +724,10 @@ "default": "dialog.result" }, "recognizer": { - "$kind": "Microsoft.IRecognizer", + "$kind": "Microsoft.Recognizer", "title": "Recognizer", - "description": "Language Understanding recognizer that interprets user input into intent and entities.", - "$ref": "#/definitions/Microsoft.IRecognizer" + "description": "Input recognizer that interprets user input into intent and entities.", + "$ref": "#/definitions/Microsoft.Recognizer" }, "generator": { "$kind": "Microsoft.ILanguageGenerator", @@ -597,6 +749,20 @@ "$kind": "Microsoft.ITriggerCondition", "$ref": "#/definitions/Microsoft.ITriggerCondition" } + }, + "schema": { + "anyOf": [ + { + "title": "The schema to be filled in.", + "type": "object", + "additionalProperties": true + }, + { + "type": "string", + "title": "Reference to JSON schema", + "description": "Reference to JSON schema .dialog file." + } + ] } }, "additionalProperties": false, @@ -672,6 +838,108 @@ } ] }, + "Microsoft.Ask": { + "$role": "union(Microsoft.IDialog)", + "title": "Send Activity to Ask a question", + "description": "This is an action which sends an activity to the user when a response is expected", + "type": "object", + "properties": { + "$kind": { + "title": "$kind", + "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", + "type": "string", + "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", + "const": "Microsoft.Ask" + }, + "$copy": { + "title": "$copy", + "description": "Copy the definition by id from a .dialog file.", + "type": "string", + "pattern": "^(([a-zA-Z][a-zA-Z0-9.]*)?(#[a-zA-Z][a-zA-Z0-9.]*)?)$" + }, + "$id": { + "title": "$id", + "description": "Inline id for reuse of an inline definition", + "type": "string", + "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" + }, + "$designer": { + "title": "$designer", + "type": "object", + "description": "Extra information for the Bot Framework Designer." + }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "disabled": { + "$role": "expression", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + }, + "activity": { + "$kind": "Microsoft.IActivityTemplate", + "title": "Activity", + "description": "Activity to send.", + "$ref": "#/definitions/Microsoft.IActivityTemplate" + }, + "expectedProperties": { + "$role": "expression", + "title": "Expected Properties", + "description": "Properties expected to be filled by entities from the user", + "oneOf": [ + { + "type": "array", + "items": { + "type": "string", + "title": "string" + }, + "title": "array" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to array." + } + ] + } + }, + "additionalProperties": false, + "patternProperties": { + "^\\$": { + "type": "string" + } + }, + "anyOf": [ + { + "title": "Reference", + "required": [ + "$copy" + ] + }, + { + "title": "Type", + "required": [ + "$kind" + ] + } + ] + }, "Microsoft.AttachmentInput": { "$role": "union(Microsoft.IDialog)", "title": "Attachment input dialog", @@ -707,6 +975,18 @@ "title": "Id", "description": "Optional id for the dialog" }, + "disabled": { + "$role": "expression", + "type": [ + "boolean", + "string" + ], + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ] + }, "prompt": { "$kind": "Microsoft.IActivityTemplate", "title": "Initial prompt", @@ -744,7 +1024,11 @@ "$ref": "#/definitions/Microsoft.IActivityTemplate" }, "maxTurnCount": { - "type": "integer", + "$role": "expression", + "type": [ + "integer", + "string" + ], "title": "Max turn count", "description": "Maximum number of re-prompt attempts to collect information.", "default": 3, @@ -762,12 +1046,12 @@ ], "items": { "$role": "expression", - "type": "string", - "description": "String must contain an expression." + "type": "string" } }, "property": { "$role": "expression", + "type": "string", "title": "Property", "description": "Property to store collected information. Input will be skipped if property has value (unless 'Always prompt' is true).", "examples": [ @@ -775,32 +1059,49 @@ "user.name", "conversation.issueTitle", "dialog.favColor" - ], - "type": "string" + ] }, "defaultValue": { "$role": "expression", + "type": [ + "object", + "array", + "number", + "integer", + "boolean", + "string" + ], "title": "Default value", "description": "Expression to examine on each turn of the conversation as possible value to the property.", "examples": [ "@userName", "coalesce(@number, @partySize)" - ], - "type": "string" + ] }, "value": { "$role": "expression", + "type": [ + "object", + "array", + "number", + "integer", + "boolean", + "string" + ], "title": "Value", "description": "Gets or sets a value expression which can be used to intialize the input prompt.", "examples": [ "@userName" - ], - "type": "string" + ] }, "alwaysPrompt": { - "type": "boolean", + "$role": "expression", + "type": [ + "boolean", + "string" + ], "title": "Always prompt", - "description": "Collect information even if the specified 'property' is not empty.", + "description": "Collect information even if the specified 'property' is not empty.", "default": false, "examples": [ false @@ -808,15 +1109,19 @@ }, "allowInterruptions": { "$role": "expression", + "type": [ + "boolean", + "string" + ], "title": "Allow Interruptions", "description": "A boolean expression that determines whether the parent should be allowed to interrupt the input.", "default": "true", "examples": [ "true" - ], - "type": "string" + ] }, "outputFormat": { + "$role": "expression", "type": "string", "enum": [ "all", @@ -878,40 +1183,174 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "disabled": { + "$role": "expression", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + }, "dialog": { - "$kind": "Microsoft.IDialog", + "$role": "expression", "title": "Dialog name", "description": "Name of the dialog to call.", "examples": [ "AddToDoDialog" ], - "$ref": "#/definitions/Microsoft.IDialog" + "oneOf": [ + { + "$kind": "Microsoft.IDialog", + "type": "object", + "title": "object", + "$ref": "#/definitions/Microsoft.IDialog" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to object." + } + ] }, "options": { - "type": "object", + "$role": "expression", "title": "Options", "description": "One or more options that are passed to the dialog that is called.", - "additionalProperties": { - "type": "string", - "title": "Options" - } - }, - "includeActivity": { - "type": "boolean", - "title": "Include Activity", - "description": "When set to true, dialog that is called can process the current activity.", - "default": false - }, - "resultProperty": { - "$role": "expression", - "title": "Property", + "oneOf": [ + { + "type": "object", + "additionalProperties": { + "type": "string", + "title": "Options" + }, + "title": "object" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to object." + } + ] + }, + "activityProcessed": { + "$role": "expression", + "title": "Activity Processed", + "description": "When set to false, the dialog that is called can process the current activity.", + "oneOf": [ + { + "type": "boolean", + "default": true, + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + }, + "resultProperty": { + "$role": "expression", + "type": "string", + "title": "Property", "description": "Property to store any value returned by the dialog that is called.", "examples": [ "dialog.userName" - ], + ] + } + }, + "additionalProperties": false, + "patternProperties": { + "^\\$": { "type": "string" } }, + "anyOf": [ + { + "title": "Reference", + "required": [ + "$copy" + ] + }, + { + "title": "Type", + "required": [ + "$kind" + ] + } + ] + }, + "Microsoft.BreakLoop": { + "$role": "union(Microsoft.IDialog)", + "title": "Break Loop", + "description": "Stop executing this loop", + "type": "object", + "properties": { + "$kind": { + "title": "$kind", + "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", + "type": "string", + "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", + "const": "Microsoft.BreakLoop" + }, + "$copy": { + "title": "$copy", + "description": "Copy the definition by id from a .dialog file.", + "type": "string", + "pattern": "^(([a-zA-Z][a-zA-Z0-9.]*)?(#[a-zA-Z][a-zA-Z0-9.]*)?)$" + }, + "$id": { + "title": "$id", + "description": "Inline id for reuse of an inline definition", + "type": "string", + "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" + }, + "$designer": { + "title": "$designer", + "type": "object", + "description": "Extra information for the Bot Framework Designer." + }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "disabled": { + "$role": "expression", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + } + }, "additionalProperties": false, "patternProperties": { "^\\$": { @@ -963,13 +1402,46 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "disabled": { + "$role": "expression", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + }, "eventName": { + "$role": "expression", + "type": "string", "title": "Event name", - "description": "Name of the event to emit.", - "type": "string" + "description": "Name of the event to emit." }, "eventValue": { - "type": "object", + "$role": "expression", + "type": [ + "object", + "array", + "number", + "integer", + "boolean", + "string" + ], "title": "Event value", "description": "Value to emit with the event (optional).", "additionalProperties": true @@ -1031,6 +1503,18 @@ "title": "Id", "description": "Optional id for the dialog" }, + "disabled": { + "$role": "expression", + "type": [ + "boolean", + "string" + ], + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ] + }, "prompt": { "$kind": "Microsoft.IActivityTemplate", "title": "Initial prompt", @@ -1068,7 +1552,11 @@ "$ref": "#/definitions/Microsoft.IActivityTemplate" }, "maxTurnCount": { - "type": "integer", + "$role": "expression", + "type": [ + "integer", + "string" + ], "title": "Max turn count", "description": "Maximum number of re-prompt attempts to collect information.", "default": 3, @@ -1086,12 +1574,12 @@ ], "items": { "$role": "expression", - "type": "string", - "description": "String must contain an expression." + "type": "string" } }, "property": { "$role": "expression", + "type": "string", "title": "Property", "description": "Property to store collected information. Input will be skipped if property has value (unless 'Always prompt' is true).", "examples": [ @@ -1099,32 +1587,49 @@ "user.name", "conversation.issueTitle", "dialog.favColor" - ], - "type": "string" + ] }, "defaultValue": { "$role": "expression", + "type": [ + "object", + "array", + "number", + "integer", + "boolean", + "string" + ], "title": "Default value", "description": "Expression to examine on each turn of the conversation as possible value to the property.", "examples": [ "@userName", "coalesce(@number, @partySize)" - ], - "type": "string" + ] }, "value": { "$role": "expression", + "type": [ + "object", + "array", + "number", + "integer", + "boolean", + "string" + ], "title": "Value", "description": "Gets or sets a value expression which can be used to intialize the input prompt.", "examples": [ "@userName" - ], - "type": "string" + ] }, "alwaysPrompt": { - "type": "boolean", + "$role": "expression", + "type": [ + "boolean", + "string" + ], "title": "Always prompt", - "description": "Collect information even if the specified 'property' is not empty.", + "description": "Collect information even if the specified 'property' is not empty.", "default": false, "examples": [ false @@ -1132,15 +1637,19 @@ }, "allowInterruptions": { "$role": "expression", + "type": [ + "boolean", + "string" + ], "title": "Allow Interruptions", "description": "A boolean expression that determines whether the parent should be allowed to interrupt the input.", "default": "true", "examples": [ "true" - ], - "type": "string" + ] }, "outputFormat": { + "$role": "expression", "type": "string", "enum": [ "value", @@ -1151,19 +1660,17 @@ "default": "value" }, "choices": { - "anyOf": [ - { - "$role": "expression", - "type": "string", - "description": "String must contain an expression." - }, + "$role": "expression", + "oneOf": [ { "type": "array", "items": [ { - "type": "string" + "type": "string", + "title": "string" } - ] + ], + "title": "array" }, { "type": "array", @@ -1187,12 +1694,18 @@ "title": "Synonyms", "description": "List of synonyms to recognize in addition to the value (optional).", "items": { - "type": "string" + "type": "string", + "title": "string" } } } } - ] + ], + "title": "array" + }, + { + "type": "string", + "title": "Expression" } ] }, @@ -1322,8 +1835,17 @@ }, "condition": { "$role": "expression", - "type": "string", - "description": "String must contain an expression." + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] }, "ifTrue": { "$kind": "Microsoft.ITriggerSelector", @@ -1393,6 +1915,18 @@ "title": "Id", "description": "Optional id for the dialog" }, + "disabled": { + "$role": "expression", + "type": [ + "boolean", + "string" + ], + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ] + }, "prompt": { "$kind": "Microsoft.IActivityTemplate", "title": "Initial prompt", @@ -1430,7 +1964,11 @@ "$ref": "#/definitions/Microsoft.IActivityTemplate" }, "maxTurnCount": { - "type": "integer", + "$role": "expression", + "type": [ + "integer", + "string" + ], "title": "Max turn count", "description": "Maximum number of re-prompt attempts to collect information.", "default": 3, @@ -1448,12 +1986,12 @@ ], "items": { "$role": "expression", - "type": "string", - "description": "String must contain an expression." + "type": "string" } }, "property": { "$role": "expression", + "type": "string", "title": "Property", "description": "Property to store collected information. Input will be skipped if property has value (unless 'Always prompt' is true).", "examples": [ @@ -1461,32 +1999,49 @@ "user.name", "conversation.issueTitle", "dialog.favColor" - ], - "type": "string" + ] }, "defaultValue": { "$role": "expression", + "type": [ + "object", + "array", + "number", + "integer", + "boolean", + "string" + ], "title": "Default value", "description": "Expression to examine on each turn of the conversation as possible value to the property.", "examples": [ "@userName", "coalesce(@number, @partySize)" - ], - "type": "string" + ] }, "value": { "$role": "expression", + "type": [ + "object", + "array", + "number", + "integer", + "boolean", + "string" + ], "title": "Value", "description": "Gets or sets a value expression which can be used to intialize the input prompt.", "examples": [ "@userName" - ], - "type": "string" + ] }, "alwaysPrompt": { - "type": "boolean", + "$role": "expression", + "type": [ + "boolean", + "string" + ], "title": "Always prompt", - "description": "Collect information even if the specified 'property' is not empty.", + "description": "Collect information even if the specified 'property' is not empty.", "default": false, "examples": [ false @@ -1494,30 +2049,35 @@ }, "allowInterruptions": { "$role": "expression", + "type": [ + "boolean", + "string" + ], "title": "Allow Interruptions", "description": "A boolean expression that determines whether the parent should be allowed to interrupt the input.", "default": "true", "examples": [ "true" - ], - "type": "string" + ] }, "outputFormat": { "$role": "expression", + "type": "string", "title": "Output format", "description": "Expression to format the confirm output.", "examples": [ - "concat('confirmation:', this.value)" - ], - "type": "string" + "=concat('confirmation:', this.value)" + ] }, "defaultLocale": { + "$role": "expression", "type": "string", "title": "Default locale", "description": "Default locale.", "default": "en-us" }, "style": { + "$role": "expression", "type": "string", "enum": [ "None", @@ -1532,78 +2092,102 @@ "default": "Auto" }, "choiceOptions": { - "type": "object", - "properties": { - "inlineSeparator": { - "type": "string", - "title": "Inline separator", - "description": "Character used to separate individual choices when there are more than 2 choices", - "default": ", " - }, - "inlineOr": { - "type": "string", - "title": "Inline or", - "description": "Separator inserted between the choices when their are only 2 choices", - "default": " or " - }, - "inlineOrMore": { - "type": "string", - "title": "Inline or more", - "description": "Separator inserted between the last 2 choices when their are more than 2 choices.", - "default": ", or " - }, - "includeNumbers": { - "type": "boolean", - "title": "Include numbers", - "description": "If true, inline and list style choices will be prefixed with the index of the choice.", - "default": true - } - } - }, - "confirmChoices": { - "type": "array", - "items": [ + "$role": "expression", + "oneOf": [ { "type": "object", "properties": { - "value": { + "inlineSeparator": { "type": "string", - "title": "Value", - "description": "Value to return when this choice is selected." + "title": "Inline separator", + "description": "Character used to separate individual choices when there are more than 2 choices", + "default": ", " }, - "action": { - "type": "object", - "title": "Action", - "description": "Card action for the choice" + "inlineOr": { + "type": "string", + "title": "Inline or", + "description": "Separator inserted between the choices when their are only 2 choices", + "default": " or " }, - "synonyms": { - "type": "array", - "title": "Synonyms", - "description": "List of synonyms to recognize in addition to the value (optional)", - "items": { - "type": "string" - } + "inlineOrMore": { + "type": "string", + "title": "Inline or more", + "description": "Separator inserted between the last 2 choices when their are more than 2 choices.", + "default": ", or " + }, + "includeNumbers": { + "type": "boolean", + "title": "Include numbers", + "description": "If true, inline and list style choices will be prefixed with the index of the choice.", + "default": true } - } + }, + "title": "object" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to object." } ] - } - }, - "additionalProperties": false, - "patternProperties": { - "^\\$": { - "type": "string" - } - }, - "anyOf": [ - { - "title": "Reference", - "required": [ - "$copy" - ] }, - { - "title": "Type", + "confirmChoices": { + "$role": "expression", + "oneOf": [ + { + "type": "array", + "items": [ + { + "type": "object", + "properties": { + "value": { + "type": "string", + "title": "Value", + "description": "Value to return when this choice is selected." + }, + "action": { + "type": "object", + "title": "Action", + "description": "Card action for the choice" + }, + "synonyms": { + "type": "array", + "title": "Synonyms", + "description": "List of synonyms to recognize in addition to the value (optional)", + "items": { + "type": "string", + "title": "string" + } + } + }, + "title": "object" + } + ], + "title": "array" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to array." + } + ] + } + }, + "additionalProperties": false, + "patternProperties": { + "^\\$": { + "type": "string" + } + }, + "anyOf": [ + { + "title": "Reference", + "required": [ + "$copy" + ] + }, + { + "title": "Type", "required": [ "$kind" ] @@ -1662,6 +2246,149 @@ } ] }, + "Microsoft.ContinueLoop": { + "$role": "union(Microsoft.IDialog)", + "title": "Continune Loop", + "description": "Stop executing this template and continue with the next iteration of the loop.", + "type": "object", + "properties": { + "$kind": { + "title": "$kind", + "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", + "type": "string", + "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", + "const": "Microsoft.ContinueLoop" + }, + "$copy": { + "title": "$copy", + "description": "Copy the definition by id from a .dialog file.", + "type": "string", + "pattern": "^(([a-zA-Z][a-zA-Z0-9.]*)?(#[a-zA-Z][a-zA-Z0-9.]*)?)$" + }, + "$id": { + "title": "$id", + "description": "Inline id for reuse of an inline definition", + "type": "string", + "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" + }, + "$designer": { + "title": "$designer", + "type": "object", + "description": "Extra information for the Bot Framework Designer." + }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "disabled": { + "$role": "expression", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + } + }, + "additionalProperties": false, + "patternProperties": { + "^\\$": { + "type": "string" + } + }, + "anyOf": [ + { + "title": "Reference", + "required": [ + "$copy" + ] + }, + { + "title": "Type", + "required": [ + "$kind" + ] + } + ] + }, + "Microsoft.CrossTrainedRecognizerSet": { + "$role": "union(Microsoft.Recognizer)", + "title": "Cross-trained Recognizer Set", + "description": "Recognizer for selecting between cross trained recognizers.", + "type": "object", + "properties": { + "$kind": { + "title": "$kind", + "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", + "type": "string", + "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", + "const": "Microsoft.CrossTrainedRecognizerSet" + }, + "$copy": { + "title": "$copy", + "description": "Copy the definition by id from a .dialog file.", + "type": "string", + "pattern": "^(([a-zA-Z][a-zA-Z0-9.]*)?(#[a-zA-Z][a-zA-Z0-9.]*)?)$" + }, + "$id": { + "title": "$id", + "description": "Inline id for reuse of an inline definition", + "type": "string", + "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" + }, + "$designer": { + "title": "$designer", + "type": "object", + "description": "Extra information for the Bot Framework Designer." + }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional unique id using with RecognizerSet." + }, + "recognizers": { + "type": "array", + "title": "Recognizers", + "description": "List of Recognizers defined for this set.", + "items": { + "$kind": "Microsoft.Recognizer", + "$ref": "#/definitions/Microsoft.Recognizer" + } + } + }, + "additionalProperties": false, + "patternProperties": { + "^\\$": { + "type": "string" + } + }, + "anyOf": [ + { + "title": "Reference", + "required": [ + "$copy" + ] + }, + { + "title": "Type", + "required": [ + "recognizers", + "$kind" + ] + } + ] + }, "Microsoft.CurrencyEntityRecognizer": { "$role": "union(Microsoft.EntityRecognizers)", "title": "Currency Entity Recognizer", @@ -1801,6 +2528,18 @@ "title": "Id", "description": "Optional id for the dialog" }, + "disabled": { + "$role": "expression", + "type": [ + "boolean", + "string" + ], + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ] + }, "prompt": { "$kind": "Microsoft.IActivityTemplate", "title": "Initial prompt", @@ -1838,7 +2577,11 @@ "$ref": "#/definitions/Microsoft.IActivityTemplate" }, "maxTurnCount": { - "type": "integer", + "$role": "expression", + "type": [ + "integer", + "string" + ], "title": "Max turn count", "description": "Maximum number of re-prompt attempts to collect information.", "default": 3, @@ -1856,12 +2599,12 @@ ], "items": { "$role": "expression", - "type": "string", - "description": "String must contain an expression." + "type": "string" } }, "property": { "$role": "expression", + "type": "string", "title": "Property", "description": "Property to store collected information. Input will be skipped if property has value (unless 'Always prompt' is true).", "examples": [ @@ -1869,32 +2612,49 @@ "user.name", "conversation.issueTitle", "dialog.favColor" - ], - "type": "string" + ] }, "defaultValue": { "$role": "expression", + "type": [ + "object", + "array", + "number", + "integer", + "boolean", + "string" + ], "title": "Default value", "description": "Expression to examine on each turn of the conversation as possible value to the property.", "examples": [ "@userName", "coalesce(@number, @partySize)" - ], - "type": "string" + ] }, "value": { "$role": "expression", + "type": [ + "object", + "array", + "number", + "integer", + "boolean", + "string" + ], "title": "Value", "description": "Gets or sets a value expression which can be used to intialize the input prompt.", "examples": [ "@userName" - ], - "type": "string" + ] }, "alwaysPrompt": { - "type": "boolean", + "$role": "expression", + "type": [ + "boolean", + "string" + ], "title": "Always prompt", - "description": "Collect information even if the specified 'property' is not empty.", + "description": "Collect information even if the specified 'property' is not empty.", "default": false, "examples": [ false @@ -1902,24 +2662,28 @@ }, "allowInterruptions": { "$role": "expression", + "type": [ + "boolean", + "string" + ], "title": "Allow Interruptions", "description": "A boolean expression that determines whether the parent should be allowed to interrupt the input.", "default": "true", "examples": [ "true" - ], - "type": "string" + ] }, "outputFormat": { "$role": "expression", + "type": "string", "title": "Output format", "description": "Expression to format the datetime output.", "examples": [ "this.value[0].Value" - ], - "type": "string" + ] }, "defaultLocale": { + "$role": "expression", "type": "string", "title": "Default locale", "description": "Default locale.", @@ -1976,6 +2740,30 @@ "title": "$designer", "type": "object", "description": "Extra information for the Bot Framework Designer." + }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "disabled": { + "$role": "expression", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] } }, "additionalProperties": false, @@ -1999,10 +2787,10 @@ } ] }, - "Microsoft.DeleteProperties": { + "Microsoft.DeleteActivity": { "$role": "union(Microsoft.IDialog)", - "title": "Delete Properties", - "description": "Delete multiple properties and any value it holds.", + "title": "Delete Activity", + "description": "Delete an activity that was previously sent.", "type": "object", "properties": { "$kind": { @@ -2010,7 +2798,7 @@ "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", "type": "string", "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", - "const": "Microsoft.DeleteProperties" + "const": "Microsoft.DeleteActivity" }, "$copy": { "title": "$copy", @@ -2029,16 +2817,127 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, - "properties": { - "type": "array", - "title": "Properties", - "description": "Properties to delete.", - "items": { - "$role": "expression", - "title": "Property", - "description": "Property to delete.", - "type": "string" - } + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "activityId": { + "$role": "expression", + "type": "string", + "title": "ActivityId", + "description": "expression to an activityId to delete", + "examples": [ + "=$lastActivity" + ] + }, + "disabled": { + "$role": "expression", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + } + }, + "additionalProperties": false, + "patternProperties": { + "^\\$": { + "type": "string" + } + }, + "anyOf": [ + { + "title": "Reference", + "required": [ + "$copy" + ] + }, + { + "title": "Type", + "required": [ + "property", + "value", + "$kind" + ] + } + ] + }, + "Microsoft.DeleteProperties": { + "$role": "union(Microsoft.IDialog)", + "title": "Delete Properties", + "description": "Delete multiple properties and any value it holds.", + "type": "object", + "properties": { + "$kind": { + "title": "$kind", + "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", + "type": "string", + "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", + "const": "Microsoft.DeleteProperties" + }, + "$copy": { + "title": "$copy", + "description": "Copy the definition by id from a .dialog file.", + "type": "string", + "pattern": "^(([a-zA-Z][a-zA-Z0-9.]*)?(#[a-zA-Z][a-zA-Z0-9.]*)?)$" + }, + "$id": { + "title": "$id", + "description": "Inline id for reuse of an inline definition", + "type": "string", + "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" + }, + "$designer": { + "title": "$designer", + "type": "object", + "description": "Extra information for the Bot Framework Designer." + }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "disabled": { + "$role": "expression", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + }, + "properties": { + "type": "array", + "title": "Properties", + "description": "Properties to delete.", + "items": { + "$role": "expression", + "type": "string", + "title": "Property", + "description": "Property to delete." + } } }, "additionalProperties": false, @@ -2093,11 +2992,35 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "disabled": { + "$role": "expression", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + }, "property": { "$role": "expression", + "type": "string", "title": "Property", - "description": "Property to delete.", - "type": "string" + "description": "Property to delete." } }, "additionalProperties": false, @@ -2204,16 +3127,41 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "disabled": { + "$role": "expression", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + }, "changeType": { + "$role": "expression", "type": "string", "title": "Type of change", "description": "Type of change to apply to the current actions.", "enum": [ - "InsertActions", - "InsertActionsBeforeTags", - "AppendActions", - "EndSequence", - "ReplaceSequence" + "insertActions", + "insertActionsBeforeTags", + "appendActions", + "endSequence", + "replaceSequence" ] }, "actions": { @@ -2279,40 +3227,72 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, "changeType": { + "$role": "expression", "type": "string", "title": "Type of change", "description": "Type of change to the array in memory.", "enum": [ - "Push", - "Pop", - "Take", - "Remove", - "Clear" + "push", + "pop", + "take", + "remove", + "clear" + ] + }, + "disabled": { + "$role": "expression", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } ] }, "itemsProperty": { "$role": "expression", + "type": "string", "title": "Items property", - "description": "Property that holds the array to update.", - "type": "string" + "description": "Property that holds the array to update." }, "resultProperty": { "$role": "expression", + "type": "string", "title": "Result Property", - "description": "Property to store the result of this action.", - "type": "string" + "description": "Property to store the result of this action." }, "value": { "$role": "expression", + "type": [ + "object", + "array", + "number", + "integer", + "boolean", + "string" + ], "title": "Value", "description": "New value or expression.", "examples": [ "'milk'", "dialog.favColor", "dialog.favColor == 'red'" - ], - "type": "string" + ] } }, "additionalProperties": false, @@ -2420,41 +3400,79 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, - "eventName": { - "title": "Event name", - "description": "Name of the event to emit.", - "anyOf": [ + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "disabled": { + "$role": "expression", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ], + "oneOf": [ { - "enum": [ - "beginDialog", - "resumeDialog", - "repromptDialog", - "cancelDialog", - "endDialog", - "activityReceived", - "recognizedIntent", - "unknownIntent", - "actionsStarted", - "actionsSaved", - "actionsEnded", - "actionsResumed" - ] + "type": "boolean", + "title": "boolean" }, { - "type": "string" + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." } ] }, + "eventName": { + "$role": "expression", + "type": "string", + "title": "Event name", + "description": "Name of the event to emit.", + "enum": [ + "beginDialog", + "resumeDialog", + "repromptDialog", + "cancelDialog", + "endDialog", + "activityReceived", + "recognizedIntent", + "unknownIntent", + "actionsStarted", + "actionsSaved", + "actionsEnded", + "actionsResumed" + ] + }, "eventValue": { "$role": "expression", + "type": [ + "object", + "array", + "number", + "integer", + "boolean", + "string" + ], "title": "Event value", - "description": "Value to emit with the event (optional).", - "type": "string" + "description": "Value to emit with the event (optional)." }, "bubbleEvent": { - "type": "boolean", + "$role": "expression", "title": "Bubble event", - "description": "If true this event is passed on to parent dialogs." + "description": "If true this event is passed on to parent dialogs.", + "oneOf": [ + { + "type": "boolean", + "default": false, + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] } }, "additionalProperties": false, @@ -2509,15 +3527,46 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "disabled": { + "$role": "expression", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + }, "value": { "$role": "expression", + "type": [ + "object", + "array", + "number", + "integer", + "boolean", + "string" + ], "title": "Value", "description": "Result value returned to the parent dialog.", "examples": [ - "dialog.userName", - "'tomato'" - ], - "type": "string" + "=dialog.userName", + "='tomato'" + ] } }, "additionalProperties": false, @@ -2570,6 +3619,30 @@ "title": "$designer", "type": "object", "description": "Extra information for the Bot Framework Designer." + }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "disabled": { + "$role": "expression", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] } }, "additionalProperties": false, @@ -2688,6 +3761,11 @@ "title": "Microsoft.UrlEntityRecognizer", "description": "Recognizer which recognizes urls (example: http://bing.com)", "$ref": "#/definitions/Microsoft.UrlEntityRecognizer" + }, + { + "type": "string", + "title": "Reference to Microsoft.EntityRecognizers", + "description": "Reference to Microsoft.EntityRecognizers .dialog file." } ] }, @@ -2773,14 +3851,38 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "disabled": { + "$role": "expression", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + }, "itemsProperty": { "$role": "expression", + "type": "string", "title": "Items property", "description": "Property that holds the array.", "examples": [ "user.todoList" - ], - "type": "string" + ] }, "actions": { "type": "array", @@ -2845,15 +3947,39 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, - "itemsProperty": { + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "disabled": { "$role": "expression", - "title": "Items property", - "description": "Property that holds the array.", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", "examples": [ - "user.todoList" + "user.age > 3" ], - "type": "string" - }, + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + }, + "itemsProperty": { + "$role": "expression", + "type": "string", + "title": "Items property", + "description": "Property that holds the array.", + "examples": [ + "user.todoList" + ] + }, "actions": { "type": "array", "title": "Actions", @@ -2864,10 +3990,21 @@ } }, "pageSize": { - "type": "integer", + "$role": "expression", "title": "Page size", "description": "Number of items in each page.", - "default": 10 + "oneOf": [ + { + "type": "integer", + "default": 10, + "title": "integer" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to integer." + } + ] } }, "additionalProperties": false, @@ -2893,6 +4030,250 @@ } ] }, + "Microsoft.GetActivityMembers": { + "$role": "union(Microsoft.IDialog)", + "title": "Get Activity Members", + "description": "Get the members who are participating in an activity. (BotFrameworkAdapter only)", + "type": "object", + "properties": { + "$kind": { + "title": "$kind", + "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", + "type": "string", + "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", + "const": "Microsoft.GetActivityMembers" + }, + "$copy": { + "title": "$copy", + "description": "Copy the definition by id from a .dialog file.", + "type": "string", + "pattern": "^(([a-zA-Z][a-zA-Z0-9.]*)?(#[a-zA-Z][a-zA-Z0-9.]*)?)$" + }, + "$id": { + "title": "$id", + "description": "Inline id for reuse of an inline definition", + "type": "string", + "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" + }, + "$designer": { + "title": "$designer", + "type": "object", + "description": "Extra information for the Bot Framework Designer." + }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "activityId": { + "$role": "expression", + "type": "string", + "title": "ActivityId", + "description": "expression to an activityId to get the members. If none is defined then the current activity id will be used.", + "examples": [ + "$lastActivity" + ] + }, + "disabled": { + "$role": "expression", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + } + }, + "additionalProperties": false, + "patternProperties": { + "^\\$": { + "type": "string" + } + }, + "anyOf": [ + { + "title": "Reference", + "required": [ + "$copy" + ] + }, + { + "title": "Type", + "required": [ + "$kind" + ] + } + ] + }, + "Microsoft.GetConversationMembers": { + "$role": "union(Microsoft.IDialog)", + "title": "Get Converation Members", + "description": "Get the members who are participating in an conversation. (BotFrameworkAdapter only)", + "type": "object", + "properties": { + "$kind": { + "title": "$kind", + "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", + "type": "string", + "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", + "const": "Microsoft.GetConversationMembers" + }, + "$copy": { + "title": "$copy", + "description": "Copy the definition by id from a .dialog file.", + "type": "string", + "pattern": "^(([a-zA-Z][a-zA-Z0-9.]*)?(#[a-zA-Z][a-zA-Z0-9.]*)?)$" + }, + "$id": { + "title": "$id", + "description": "Inline id for reuse of an inline definition", + "type": "string", + "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" + }, + "$designer": { + "title": "$designer", + "type": "object", + "description": "Extra information for the Bot Framework Designer." + }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "disabled": { + "$role": "expression", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + } + }, + "additionalProperties": false, + "patternProperties": { + "^\\$": { + "type": "string" + } + }, + "anyOf": [ + { + "title": "Reference", + "required": [ + "$copy" + ] + }, + { + "title": "Type", + "required": [ + "$kind" + ] + } + ] + }, + "Microsoft.GotoAction": { + "$role": "union(Microsoft.IDialog)", + "title": "Go to Action", + "description": "Go to an an action by id.", + "type": "object", + "properties": { + "$kind": { + "title": "$kind", + "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", + "type": "string", + "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", + "const": "Microsoft.GotoAction" + }, + "$copy": { + "title": "$copy", + "description": "Copy the definition by id from a .dialog file.", + "type": "string", + "pattern": "^(([a-zA-Z][a-zA-Z0-9.]*)?(#[a-zA-Z][a-zA-Z0-9.]*)?)$" + }, + "$id": { + "title": "$id", + "description": "Inline id for reuse of an inline definition", + "type": "string", + "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" + }, + "$designer": { + "title": "$designer", + "type": "object", + "description": "Extra information for the Bot Framework Designer." + }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "disabled": { + "$role": "expression", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + }, + "actionId": { + "$role": "expression", + "type": "string", + "title": "Action Id", + "description": "Action Id to execute next" + } + }, + "additionalProperties": false, + "patternProperties": { + "^\\$": { + "type": "string" + } + }, + "anyOf": [ + { + "title": "Reference", + "required": [ + "$copy" + ] + }, + { + "title": "Type", + "required": [ + "actionId", + "$kind" + ] + } + ] + }, "Microsoft.GuidEntityRecognizer": { "$role": "union(Microsoft.EntityRecognizers)", "title": "Guid Entity Recognizer", @@ -3027,6 +4408,30 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "disabled": { + "$role": "expression", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + }, "method": { "type": "string", "title": "HTTP method", @@ -3044,6 +4449,7 @@ ] }, "url": { + "$role": "expression", "type": "string", "title": "Url", "description": "URL to call (supports data binding).", @@ -3052,28 +4458,40 @@ ] }, "body": { - "type": "object", + "$role": "expression", + "type": [ + "object", + "array", + "number", + "integer", + "boolean", + "string" + ], "title": "Body", "description": "Body to include in the HTTP call (supports data binding).", "additionalProperties": true }, "resultProperty": { "$role": "expression", + "type": "string", "title": "Result property", "description": "Property to store the result of this action. The result includes 4 properties from the http response: statusCode, reasonPhrase, content and headers. If the content is json it will be a deserialized object.", "examples": [ "dialog.contosodata" - ], - "type": "string" + ] }, "headers": { "type": "object", - "additionProperties": true, "title": "Headers", - "description": "One or more headers to include in the request (supports data binding)." - }, - "responseType": { - "type": "string", + "description": "One or more headers to include in the request (supports data binding).", + "additionalProperties": { + "$role": "expression", + "type": "string" + } + }, + "responseType": { + "$role": "expression", + "type": "string", "title": "Response type", "description": "Defines the type of HTTP response. Automatically calls the 'Send a response' action if set to 'Activity' or 'Activities'.", "enum": [ @@ -3139,6 +4557,11 @@ "description": "Flexible, data driven dialog that can adapt to the conversation.", "$ref": "#/definitions/Microsoft.AdaptiveDialog" }, + { + "title": "Microsoft.Ask", + "description": "This is an action which sends an activity to the user when a response is expected", + "$ref": "#/definitions/Microsoft.Ask" + }, { "title": "Microsoft.AttachmentInput", "description": "Collect information - Ask for a file or image.", @@ -3149,6 +4572,11 @@ "description": "Begin another dialog.", "$ref": "#/definitions/Microsoft.BeginDialog" }, + { + "title": "Microsoft.BreakLoop", + "description": "Stop executing this loop", + "$ref": "#/definitions/Microsoft.BreakLoop" + }, { "title": "Microsoft.CancelAllDialogs", "description": "Cancel all active dialogs. All dialogs in the dialog chain will need a trigger to capture the event configured in this action.", @@ -3164,6 +4592,11 @@ "description": "Collect information - Ask for confirmation (yes or no).", "$ref": "#/definitions/Microsoft.ConfirmInput" }, + { + "title": "Microsoft.ContinueLoop", + "description": "Stop executing this template and continue with the next iteration of the loop.", + "$ref": "#/definitions/Microsoft.ContinueLoop" + }, { "title": "Microsoft.DateTimeInput", "description": "Collect information - Ask for date and/ or time", @@ -3174,6 +4607,11 @@ "description": "If debugger is attached, stop the execution at this point in the conversation.", "$ref": "#/definitions/Microsoft.DebugBreak" }, + { + "title": "Microsoft.DeleteActivity", + "description": "Delete an activity that was previously sent.", + "$ref": "#/definitions/Microsoft.DeleteActivity" + }, { "title": "Microsoft.DeleteProperties", "description": "Delete multiple properties and any value it holds.", @@ -3219,6 +4657,21 @@ "description": "Execute actions on each page (collection of items) in an array.", "$ref": "#/definitions/Microsoft.ForeachPage" }, + { + "title": "Microsoft.GetActivityMembers", + "description": "Get the members who are participating in an activity. (BotFrameworkAdapter only)", + "$ref": "#/definitions/Microsoft.GetActivityMembers" + }, + { + "title": "Microsoft.GetConversationMembers", + "description": "Get the members who are participating in an conversation. (BotFrameworkAdapter only)", + "$ref": "#/definitions/Microsoft.GetConversationMembers" + }, + { + "title": "Microsoft.GotoAction", + "description": "Go to an an action by id.", + "$ref": "#/definitions/Microsoft.GotoAction" + }, { "title": "Microsoft.HttpRequest", "description": "Make a HTTP request.", @@ -3229,11 +4682,6 @@ "description": "Two-way branch the conversation flow based on a condition.", "$ref": "#/definitions/Microsoft.IfCondition" }, - { - "title": "Microsoft.InitProperty", - "description": "Define and initialize a property to be an array or object.", - "$ref": "#/definitions/Microsoft.InitProperty" - }, { "title": "Microsoft.LogAction", "description": "Log a message to the host application. Send a TraceActivity to Bot Framework Emulator (optional).", @@ -3279,6 +4727,11 @@ "description": "Set property to a value.", "$ref": "#/definitions/Microsoft.SetProperty" }, + { + "title": "Microsoft.SignOutUser", + "description": "Sign a user out that was logged in previously using OAuthInput.", + "$ref": "#/definitions/Microsoft.SignOutUser" + }, { "title": "Microsoft.SwitchCondition", "description": "Execute different actions based on the value of a property.", @@ -3299,6 +4752,11 @@ "description": "Send a trace activity to the transcript logger and/ or Bot Framework Emulator.", "$ref": "#/definitions/Microsoft.TraceActivity" }, + { + "title": "Microsoft.UpdateActivity", + "description": "Respond with an activity.", + "$ref": "#/definitions/Microsoft.UpdateActivity" + }, { "type": "string", "title": "string" @@ -3316,32 +4774,6 @@ } ] }, - "Microsoft.IRecognizer": { - "title": "Microsoft IRecognizer", - "description": "Union of components which implement the IRecognizer interface", - "$role": "union", - "oneOf": [ - { - "title": "Microsoft.LuisRecognizer", - "description": "LUIS recognizer.", - "$ref": "#/definitions/Microsoft.LuisRecognizer" - }, - { - "title": "Microsoft.MultiLanguageRecognizer", - "description": "Configure one recognizer per language and the specify the language fallback policy.", - "$ref": "#/definitions/Microsoft.MultiLanguageRecognizer" - }, - { - "title": "Microsoft.RegexRecognizer", - "description": "Use regular expressions to recognize intents and entities from user input.", - "$ref": "#/definitions/Microsoft.RegexRecognizer" - }, - { - "type": "string", - "title": "string" - } - ] - }, "Microsoft.ITextTemplate": { "title": "Microsoft TextTemplate", "description": "Union of components which implement the TextTemplate", @@ -3368,6 +4800,11 @@ "description": "Actions to perform on receipt of a generic activity.", "$ref": "#/definitions/Microsoft.OnActivity" }, + { + "title": "Microsoft.OnAssignEntity", + "description": "Actions to take when an entity should be assigned to a property.", + "$ref": "#/definitions/Microsoft.OnAssignEntity" + }, { "title": "Microsoft.OnBeginDialog", "description": "Actions to perform when this dialog begins.", @@ -3378,6 +4815,26 @@ "description": "Actions to perform on cancel dialog event.", "$ref": "#/definitions/Microsoft.OnCancelDialog" }, + { + "title": "Microsoft.OnChooseEntity", + "description": "Actions to be performed when an entity value needs to be resolved.", + "$ref": "#/definitions/Microsoft.OnChooseEntity" + }, + { + "title": "Microsoft.OnChooseIntent", + "description": "Actions to perform on when an intent is ambigious.", + "$ref": "#/definitions/Microsoft.OnChooseIntent" + }, + { + "title": "Microsoft.OnChooseProperty", + "description": "Actions to take when there are multiple possible mappings of entities to properties.", + "$ref": "#/definitions/Microsoft.OnChooseProperty" + }, + { + "title": "Microsoft.OnClearProperty", + "description": "Actions to take when a property needs to be cleared.", + "$ref": "#/definitions/Microsoft.OnClearProperty" + }, { "title": "Microsoft.OnCondition", "description": "Actions to perform when specified condition is true.", @@ -3398,6 +4855,11 @@ "description": "Actions to perform when a specific dialog event occurs.", "$ref": "#/definitions/Microsoft.OnDialogEvent" }, + { + "title": "Microsoft.OnEndOfActions", + "description": "Actions to take when there are no more actions in the current dialog.", + "$ref": "#/definitions/Microsoft.OnEndOfActions" + }, { "title": "Microsoft.OnEndOfConversationActivity", "description": "Actions to perform on receipt of an activity with type 'EndOfConversation'.", @@ -3448,6 +4910,11 @@ "description": "Actions to perform on receipt of an activity with type 'MessageUpdate'.", "$ref": "#/definitions/Microsoft.OnMessageUpdateActivity" }, + { + "title": "Microsoft.OnQnAMatch", + "description": "Actions to perform on when an match from QnAMaker is found.", + "$ref": "#/definitions/Microsoft.OnQnAMatch" + }, { "title": "Microsoft.OnRepromptDialog", "description": "Actions to perform when 'RepromptDialog' event occurs.", @@ -3462,6 +4929,11 @@ "title": "Microsoft.OnUnknownIntent", "description": "Action to perform when user input is unrecognized and if none of the 'on intent recognition' triggers match recognized intent.", "$ref": "#/definitions/Microsoft.OnUnknownIntent" + }, + { + "type": "string", + "title": "Reference to Microsoft.ITriggerCondition", + "description": "Reference to Microsoft.ITriggerCondition .dialog file." } ] }, @@ -3494,6 +4966,11 @@ "title": "Microsoft.TrueSelector", "description": "Selector for all true events", "$ref": "#/definitions/Microsoft.TrueSelector" + }, + { + "type": "string", + "title": "Reference to Microsoft.ITriggerSelector", + "description": "Reference to Microsoft.ITriggerSelector .dialog file." } ] }, @@ -3527,6 +5004,11 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, "condition": { "$role": "expression", "title": "Condition", @@ -3534,7 +5016,36 @@ "examples": [ "user.age > 3" ], - "type": "string" + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + }, + "disabled": { + "$role": "expression", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] }, "actions": { "type": "array", @@ -3578,78 +5089,6 @@ } ] }, - "Microsoft.InitProperty": { - "$role": "union(Microsoft.IDialog)", - "title": "Initialize property", - "description": "Define and initialize a property to be an array or object.", - "type": "object", - "properties": { - "$kind": { - "title": "$kind", - "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", - "type": "string", - "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", - "const": "Microsoft.InitProperty" - }, - "$copy": { - "title": "$copy", - "description": "Copy the definition by id from a .dialog file.", - "type": "string", - "pattern": "^(([a-zA-Z][a-zA-Z0-9.]*)?(#[a-zA-Z][a-zA-Z0-9.]*)?)$" - }, - "$id": { - "title": "$id", - "description": "Inline id for reuse of an inline definition", - "type": "string", - "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" - }, - "$designer": { - "title": "$designer", - "type": "object", - "description": "Extra information for the Bot Framework Designer." - }, - "property": { - "$role": "expression", - "title": "Property", - "description": "Property (named location to store information).", - "examples": [ - "user.age" - ], - "type": "string" - }, - "type": { - "type": "string", - "title": "Type", - "description": "Type of value.", - "enum": [ - "object", - "array" - ] - } - }, - "additionalProperties": false, - "patternProperties": { - "^\\$": { - "type": "string" - } - }, - "anyOf": [ - { - "title": "Reference", - "required": [ - "$copy" - ] - }, - { - "title": "Type", - "required": [ - "property", - "type", - "$kind" - ] - } - ] - }, "Microsoft.IpEntityRecognizer": { "$role": "union(Microsoft.EntityRecognizers)", "title": "Ip Entity Recognizer", @@ -3783,16 +5222,58 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "disabled": { + "$role": "expression", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + }, "text": { + "$role": "expression", "type": "string", "title": "Text", "description": "Information to log." }, + "label": { + "$role": "expression", + "type": "string", + "title": "Label", + "description": "Label for the trace activity (used to identify it in a list of trace activities.)" + }, "traceActivity": { - "type": "boolean", + "$role": "expression", "title": "Send Trace Activity", "description": "If true, automatically sends a TraceActivity (view in Bot Framework Emulator).", - "default": false + "oneOf": [ + { + "type": "boolean", + "default": false, + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] } }, "additionalProperties": false, @@ -3818,7 +5299,7 @@ ] }, "Microsoft.LuisRecognizer": { - "$role": "union(Microsoft.IRecognizer)", + "$role": "union(Microsoft.Recognizer)", "title": "LUIS Recognizer", "description": "LUIS recognizer.", "type": "object", @@ -3848,14 +5329,122 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional unique id using with RecognizerSet. Other recognizers should return 'DeferToRecognizer_{Id}' intent when cross training data for this recognizer." + }, "applicationId": { - "type": "string" + "type": "string", + "title": "LUIS Application ID", + "description": "Application ID for your model from the LUIS service.", + "$role": "expression" }, "endpoint": { - "type": "string" + "type": "string", + "title": "LUIS Endpoint", + "description": "Endpoint to use for LUIS service like https://westus.api.cognitive.microsoft.com.", + "$role": "expression" }, "endpointKey": { - "type": "string" + "type": "string", + "title": "LUIS prediction key", + "description": "LUIS prediction key used to call endpoint.", + "$role": "expression" + }, + "externalEntityRecognizer": { + "title": "External Entity Recognizer", + "description": "Entities recognized by this recognizer will be passed to LUIS as external entities.", + "$kind": "Microsoft.Recognizer", + "$ref": "#/definitions/Microsoft.Recognizer" + }, + "dynamicLists": { + "$role": "expression", + "title": "Dynamic lists", + "description": "Runtime defined entity lists.", + "oneOf": [ + { + "type": "array", + "items": { + "title": "Entity list", + "description": "Lists of canonical values and synonyms for an entity.", + "type": "object", + "properties": { + "entity": { + "title": "Entity", + "description": "Entity to extend with a dynamic list.", + "type": "string" + }, + "list": { + "title": "Dynamic list", + "description": "List of canonical forms and synonyms.", + "type": "array", + "items": { + "type": "object", + "properties": { + "canonicalForm": { + "title": "Canonical form", + "description": "Resolution if any synonym matches.", + "type": "string" + }, + "synonyms": { + "title": "Synonyms", + "description": "List of synonyms for a canonical form.", + "type": "array", + "items": { + "type": "string", + "title": "string" + } + } + }, + "title": "object" + } + } + } + }, + "title": "array" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to array." + } + ] + }, + "predictionOptions": { + "type": "object", + "properties": { + "includeAllIntents": { + "type": "boolean", + "title": "Include all intents", + "description": "True for all intents, false for only top intent." + }, + "includeInstanceData": { + "type": "boolean", + "title": "Include $instance", + "description": "True to include $instance metadata in the LUIS response." + }, + "log": { + "type": "boolean", + "title": "Log utterances", + "description": "True to log utterances on LUIS service." + }, + "preferExternalEntities": { + "type": "boolean", + "title": "Prefer External Entities", + "description": "True to prefer external entities to those generated by LUIS models." + }, + "slot": { + "type": "string", + "title": "Slot", + "description": "Slot to use for talking to LUIS service like production or staging." + }, + "version": { + "type": "string", + "title": "Version", + "description": "LUIS application version to use." + } + } } }, "patternProperties": { @@ -3990,7 +5579,7 @@ ] }, "Microsoft.MultiLanguageRecognizer": { - "$role": "union(Microsoft.IRecognizer)", + "$role": "union(Microsoft.Recognizer)", "title": "Multi-language recognizer", "description": "Configure one recognizer per language and the specify the language fallback policy.", "type": "object", @@ -4019,6 +5608,11 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional unique id using with RecognizerSet. Other recognizers should return 'DeferToRecognizer_{Id}' intent when cross training data for this recognizer." + }, "languagePolicy": { "$kind": "Microsoft.LanguagePolicy", "type": "object", @@ -4029,10 +5623,10 @@ "recognizers": { "type": "object", "title": "Recognizers", - "description": "Map of language -> IRecognizer", + "description": "Map of language -> Recognizer", "additionalProperties": { - "$kind": "Microsoft.IRecognizer", - "$ref": "#/definitions/Microsoft.IRecognizer" + "$kind": "Microsoft.Recognizer", + "$ref": "#/definitions/Microsoft.Recognizer" } } }, @@ -4145,6 +5739,18 @@ "title": "Id", "description": "Optional id for the dialog" }, + "disabled": { + "$role": "expression", + "type": [ + "boolean", + "string" + ], + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ] + }, "prompt": { "$kind": "Microsoft.IActivityTemplate", "title": "Initial prompt", @@ -4182,7 +5788,11 @@ "$ref": "#/definitions/Microsoft.IActivityTemplate" }, "maxTurnCount": { - "type": "integer", + "$role": "expression", + "type": [ + "integer", + "string" + ], "title": "Max turn count", "description": "Maximum number of re-prompt attempts to collect information.", "default": 3, @@ -4200,12 +5810,12 @@ ], "items": { "$role": "expression", - "type": "string", - "description": "String must contain an expression." + "type": "string" } }, "property": { "$role": "expression", + "type": "string", "title": "Property", "description": "Property to store collected information. Input will be skipped if property has value (unless 'Always prompt' is true).", "examples": [ @@ -4213,32 +5823,49 @@ "user.name", "conversation.issueTitle", "dialog.favColor" - ], - "type": "string" + ] }, "defaultValue": { "$role": "expression", + "type": [ + "object", + "array", + "number", + "integer", + "boolean", + "string" + ], "title": "Default value", "description": "Expression to examine on each turn of the conversation as possible value to the property.", "examples": [ "@userName", "coalesce(@number, @partySize)" - ], - "type": "string" + ] }, "value": { "$role": "expression", + "type": [ + "object", + "array", + "number", + "integer", + "boolean", + "string" + ], "title": "Value", "description": "Gets or sets a value expression which can be used to intialize the input prompt.", "examples": [ "@userName" - ], - "type": "string" + ] }, "alwaysPrompt": { - "type": "boolean", + "$role": "expression", + "type": [ + "boolean", + "string" + ], "title": "Always prompt", - "description": "Collect information even if the specified 'property' is not empty.", + "description": "Collect information even if the specified 'property' is not empty.", "default": false, "examples": [ false @@ -4246,24 +5873,29 @@ }, "allowInterruptions": { "$role": "expression", + "type": [ + "boolean", + "string" + ], "title": "Allow Interruptions", "description": "A boolean expression that determines whether the parent should be allowed to interrupt the input.", "default": "true", "examples": [ "true" - ], - "type": "string" + ] }, "outputFormat": { "$role": "expression", + "type": "string", "title": "Output format", "description": "Expression to format the number output.", "examples": [ - "int(this.value)" - ], - "type": "string" + "=this.value", + "=int(this.text)" + ] }, "defaultLocale": { + "$role": "expression", "type": "string", "title": "Default locale", "description": "Default locale.", @@ -4373,44 +6005,795 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, - "connectionName": { - "type": "string", - "title": "Connection name", - "description": "The connection name configured in Azure Web App Bot OAuth settings.", + "connectionName": { + "$role": "expression", + "type": "string", + "title": "Connection name", + "description": "The connection name configured in Azure Web App Bot OAuth settings.", + "examples": [ + "msgraphOAuthConnection" + ] + }, + "disabled": { + "$role": "expression", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + }, + "text": { + "$role": "expression", + "type": "string", + "title": "Text", + "description": "Text shown in the OAuth signin card.", + "examples": [ + "Please sign in. " + ] + }, + "title": { + "$role": "expression", + "type": "string", + "title": "Title", + "description": "Title shown in the OAuth signin card.", + "examples": [ + "Login" + ] + }, + "timeout": { + "$role": "expression", + "title": "Timeout", + "description": "Time out setting for the OAuth signin card.", + "oneOf": [ + { + "type": "integer", + "default": "900000", + "title": "integer" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to integer." + } + ] + }, + "property": { + "$role": "expression", + "type": "string", + "title": "Token property", + "description": "Property to store the OAuth token result.", + "examples": [ + "dialog.token" + ] + }, + "invalidPrompt": { + "$kind": "Microsoft.IActivityTemplate", + "title": "Invalid prompt", + "description": "Message to send if user response is invalid.", + "examples": [ + "Sorry, the login info you provided is not valid." + ], + "$ref": "#/definitions/Microsoft.IActivityTemplate" + }, + "defaultValueResponse": { + "$kind": "Microsoft.IActivityTemplate", + "title": "Default value response", + "description": "Message to send when max turn count (if specified) has been exceeded and the default value is selected as the value.", + "examples": [ + "Login failed." + ], + "$ref": "#/definitions/Microsoft.IActivityTemplate" + }, + "maxTurnCount": { + "$role": "expression", + "title": "Max turn count", + "description": "Maximum number of re-prompt attempts to collect information.", + "examples": [ + 3 + ], + "oneOf": [ + { + "type": "integer", + "default": 3, + "title": "integer" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to integer." + } + ] + }, + "defaultValue": { + "$role": "expression", + "type": [ + "object", + "array", + "number", + "integer", + "boolean", + "string" + ], + "title": "Default value", + "description": "Expression to examine on each turn of the conversation as possible value to the property.", + "examples": [ + "@token" + ] + }, + "allowInterruptions": { + "$role": "expression", + "title": "Allow Interruptions", + "description": "A boolean expression that determines whether the parent should be allowed to interrupt the input.", + "examples": [ + "true" + ], + "oneOf": [ + { + "type": "boolean", + "default": "true", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + } + }, + "additionalProperties": false, + "patternProperties": { + "^\\$": { + "type": "string" + } + }, + "anyOf": [ + { + "title": "Reference", + "required": [ + "$copy" + ] + }, + { + "title": "Type", + "required": [ + "connectionName", + "$kind" + ] + } + ] + }, + "Microsoft.OnActivity": { + "$role": "union(Microsoft.ITriggerCondition)", + "title": "On activity", + "description": "Actions to perform on receipt of a generic activity.", + "type": "object", + "properties": { + "$kind": { + "title": "$kind", + "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", + "type": "string", + "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", + "const": "Microsoft.OnActivity" + }, + "$copy": { + "title": "$copy", + "description": "Copy the definition by id from a .dialog file.", + "type": "string", + "pattern": "^(([a-zA-Z][a-zA-Z0-9.]*)?(#[a-zA-Z][a-zA-Z0-9.]*)?)$" + }, + "$id": { + "title": "$id", + "description": "Inline id for reuse of an inline definition", + "type": "string", + "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" + }, + "$designer": { + "title": "$designer", + "type": "object", + "description": "Extra information for the Bot Framework Designer." + }, + "condition": { + "$role": "expression", + "title": "Condition", + "description": "Condition (expression).", + "examples": [ + "user.vip == true" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + }, + "actions": { + "type": "array", + "description": "Sequence of actions to execute.", + "items": { + "$kind": "Microsoft.IDialog", + "$ref": "#/definitions/Microsoft.IDialog" + } + }, + "priority": { + "title": "priority", + "description": "Priority expression of rule with 0 being the most important", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "integer" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to integer." + } + ] + }, + "runOnce": { + "type": "boolean", + "title": "Run Once", + "description": "True if rule should run once per unique conditions" + }, + "type": { + "type": "string", + "title": "Activity type", + "description": "The Activity.Type to match" + } + }, + "additionalProperties": false, + "patternProperties": { + "^\\$": { + "type": "string" + } + }, + "anyOf": [ + { + "title": "Reference", + "required": [ + "$copy" + ] + }, + { + "title": "Type", + "required": [ + "actions", + "type", + "$kind" + ] + } + ] + }, + "Microsoft.OnAssignEntity": { + "$role": "union(Microsoft.ITriggerCondition)", + "title": "On entity assignment", + "description": "Actions to take when an entity should be assigned to a property.", + "type": "object", + "properties": { + "$kind": { + "title": "$kind", + "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", + "type": "string", + "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", + "const": "Microsoft.OnAssignEntity" + }, + "$copy": { + "title": "$copy", + "description": "Copy the definition by id from a .dialog file.", + "type": "string", + "pattern": "^(([a-zA-Z][a-zA-Z0-9.]*)?(#[a-zA-Z][a-zA-Z0-9.]*)?)$" + }, + "$id": { + "title": "$id", + "description": "Inline id for reuse of an inline definition", + "type": "string", + "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" + }, + "$designer": { + "title": "$designer", + "type": "object", + "description": "Extra information for the Bot Framework Designer." + }, + "condition": { + "$role": "expression", + "title": "Condition", + "description": "Condition (expression).", + "examples": [ + "user.vip == true" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + }, + "actions": { + "type": "array", + "description": "Sequence of actions to execute.", + "items": { + "$kind": "Microsoft.IDialog", + "$ref": "#/definitions/Microsoft.IDialog" + } + }, + "priority": { + "title": "priority", + "description": "Priority expression of rule with 0 being the most important", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "integer" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to integer." + } + ] + }, + "runOnce": { + "type": "boolean", + "title": "Run Once", + "description": "True if rule should run once per unique conditions" + }, + "property": { + "type": "string", + "title": "Property", + "description": "Property that will be set after entity is selected." + }, + "entity": { + "type": "string", + "title": "Entity", + "description": "Entity being put into property" + }, + "operation": { + "type": "string", + "title": "Operation to use for assigning entity" + } + }, + "additionalProperties": false, + "patternProperties": { + "^\\$": { + "type": "string" + } + }, + "anyOf": [ + { + "title": "Reference", + "required": [ + "$copy" + ] + }, + { + "title": "Type", + "required": [ + "actions", + "$kind" + ] + } + ] + }, + "Microsoft.OnBeginDialog": { + "$role": "union(Microsoft.ITriggerCondition)", + "title": "On begin dialog", + "description": "Actions to perform when this dialog begins.", + "type": "object", + "properties": { + "$kind": { + "title": "$kind", + "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", + "type": "string", + "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", + "const": "Microsoft.OnBeginDialog" + }, + "$copy": { + "title": "$copy", + "description": "Copy the definition by id from a .dialog file.", + "type": "string", + "pattern": "^(([a-zA-Z][a-zA-Z0-9.]*)?(#[a-zA-Z][a-zA-Z0-9.]*)?)$" + }, + "$id": { + "title": "$id", + "description": "Inline id for reuse of an inline definition", + "type": "string", + "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" + }, + "$designer": { + "title": "$designer", + "type": "object", + "description": "Extra information for the Bot Framework Designer." + }, + "condition": { + "$role": "expression", + "title": "Condition", + "description": "Condition (expression).", + "examples": [ + "user.vip == true" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + }, + "actions": { + "type": "array", + "description": "Sequence of actions to execute.", + "items": { + "$kind": "Microsoft.IDialog", + "$ref": "#/definitions/Microsoft.IDialog" + } + }, + "priority": { + "title": "priority", + "description": "Priority expression of rule with 0 being the most important", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "integer" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to integer." + } + ] + }, + "runOnce": { + "type": "boolean", + "title": "Run Once", + "description": "True if rule should run once per unique conditions" + } + }, + "additionalProperties": false, + "patternProperties": { + "^\\$": { + "type": "string" + } + }, + "anyOf": [ + { + "title": "Reference", + "required": [ + "$copy" + ] + }, + { + "title": "Type", + "required": [ + "actions", + "$kind" + ] + } + ] + }, + "Microsoft.OnCancelDialog": { + "$role": "union(Microsoft.ITriggerCondition)", + "title": "On cancel dialog", + "description": "Actions to perform on cancel dialog event.", + "type": "object", + "properties": { + "$kind": { + "title": "$kind", + "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", + "type": "string", + "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", + "const": "Microsoft.OnCancelDialog" + }, + "$copy": { + "title": "$copy", + "description": "Copy the definition by id from a .dialog file.", + "type": "string", + "pattern": "^(([a-zA-Z][a-zA-Z0-9.]*)?(#[a-zA-Z][a-zA-Z0-9.]*)?)$" + }, + "$id": { + "title": "$id", + "description": "Inline id for reuse of an inline definition", + "type": "string", + "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" + }, + "$designer": { + "title": "$designer", + "type": "object", + "description": "Extra information for the Bot Framework Designer." + }, + "condition": { + "$role": "expression", + "title": "Condition", + "description": "Condition (expression).", + "examples": [ + "user.vip == true" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + }, + "actions": { + "type": "array", + "description": "Sequence of actions to execute.", + "items": { + "$kind": "Microsoft.IDialog", + "$ref": "#/definitions/Microsoft.IDialog" + } + }, + "priority": { + "title": "priority", + "description": "Priority expression of rule with 0 being the most important", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "integer" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to integer." + } + ] + }, + "runOnce": { + "type": "boolean", + "title": "Run Once", + "description": "True if rule should run once per unique conditions" + } + }, + "additionalProperties": false, + "patternProperties": { + "^\\$": { + "type": "string" + } + }, + "anyOf": [ + { + "title": "Reference", + "required": [ + "$copy" + ] + }, + { + "title": "Type", + "required": [ + "actions", + "$kind" + ] + } + ] + }, + "Microsoft.OnChooseEntity": { + "$role": "union(Microsoft.ITriggerCondition)", + "title": "On choose entity", + "description": "Actions to be performed when an entity value needs to be resolved.", + "type": "object", + "properties": { + "$kind": { + "title": "$kind", + "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", + "type": "string", + "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", + "const": "Microsoft.OnChooseEntity" + }, + "$copy": { + "title": "$copy", + "description": "Copy the definition by id from a .dialog file.", + "type": "string", + "pattern": "^(([a-zA-Z][a-zA-Z0-9.]*)?(#[a-zA-Z][a-zA-Z0-9.]*)?)$" + }, + "$id": { + "title": "$id", + "description": "Inline id for reuse of an inline definition", + "type": "string", + "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" + }, + "$designer": { + "title": "$designer", + "type": "object", + "description": "Extra information for the Bot Framework Designer." + }, + "condition": { + "$role": "expression", + "title": "Condition", + "description": "Condition (expression).", + "examples": [ + "user.vip == true" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + }, + "actions": { + "type": "array", + "description": "Sequence of actions to execute.", + "items": { + "$kind": "Microsoft.IDialog", + "$ref": "#/definitions/Microsoft.IDialog" + } + }, + "priority": { + "title": "priority", + "description": "Priority expression of rule with 0 being the most important", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "integer" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to integer." + } + ] + }, + "runOnce": { + "type": "boolean", + "title": "Run Once", + "description": "True if rule should run once per unique conditions" + }, + "property": { + "type": "string", + "title": "Property to be set", + "description": "Property that will be set after entity is selected." + }, + "entity": { + "type": "string", + "title": "Ambiguous entity", + "description": "Ambiguous entity" + } + }, + "additionalProperties": false, + "patternProperties": { + "^\\$": { + "type": "string" + } + }, + "anyOf": [ + { + "title": "Reference", + "required": [ + "$copy" + ] + }, + { + "title": "Type", + "required": [ + "actions", + "$kind" + ] + } + ] + }, + "Microsoft.OnChooseIntent": { + "$role": "union(Microsoft.ITriggerCondition)", + "title": "On ambigious intent", + "description": "Actions to perform on when an intent is ambigious.", + "type": "object", + "properties": { + "$kind": { + "title": "$kind", + "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", + "type": "string", + "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", + "const": "Microsoft.OnChooseIntent" + }, + "$copy": { + "title": "$copy", + "description": "Copy the definition by id from a .dialog file.", + "type": "string", + "pattern": "^(([a-zA-Z][a-zA-Z0-9.]*)?(#[a-zA-Z][a-zA-Z0-9.]*)?)$" + }, + "$id": { + "title": "$id", + "description": "Inline id for reuse of an inline definition", + "type": "string", + "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" + }, + "$designer": { + "title": "$designer", + "type": "object", + "description": "Extra information for the Bot Framework Designer." + }, + "condition": { + "$role": "expression", + "title": "Condition", + "description": "Condition (expression).", "examples": [ - "msgraphOAuthConnection" + "user.vip == true" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } ] }, - "text": { - "type": "string", - "title": "Text", - "description": "Text shown in the OAuth signin card.", - "examples": [ - "Please sign in. " - ] + "actions": { + "type": "array", + "description": "Sequence of actions to execute.", + "items": { + "$kind": "Microsoft.IDialog", + "$ref": "#/definitions/Microsoft.IDialog" + } }, - "title": { - "type": "string", - "title": "Title", - "description": "Title shown in the OAuth signin card.", - "examples": [ - "Login" + "priority": { + "title": "priority", + "description": "Priority expression of rule with 0 being the most important", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "integer" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to integer." + } ] }, - "timeout": { - "type": "integer", - "title": "Timeout", - "description": "Time out setting for the OAuth signin card.", - "default": "900000" + "runOnce": { + "type": "boolean", + "title": "Run Once", + "description": "True if rule should run once per unique conditions" }, - "tokenProperty": { - "$role": "expression", - "title": "Token property", - "description": "Property to store the OAuth token result.", - "examples": [ - "dialog.token" - ], - "type": "string" + "intents": { + "type": "array", + "title": "Intents", + "description": "Intents that must be in the ChooseIntent result for this condition to trigger.", + "items": { + "type": "string" + } } }, "additionalProperties": false, @@ -4429,16 +6812,16 @@ { "title": "Type", "required": [ - "connectionName", + "actions", "$kind" ] } ] }, - "Microsoft.OnActivity": { + "Microsoft.OnChooseProperty": { "$role": "union(Microsoft.ITriggerCondition)", - "title": "On activity", - "description": "Actions to perform on receipt of a generic activity.", + "title": "On choose property", + "description": "Actions to take when there are multiple possible mappings of entities to properties.", "type": "object", "properties": { "$kind": { @@ -4446,7 +6829,7 @@ "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", "type": "string", "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", - "const": "Microsoft.OnActivity" + "const": "Microsoft.OnChooseProperty" }, "$copy": { "title": "$copy", @@ -4472,7 +6855,17 @@ "examples": [ "user.vip == true" ], - "type": "string" + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] }, "actions": { "type": "array", @@ -4482,10 +6875,49 @@ "$ref": "#/definitions/Microsoft.IDialog" } }, - "type": { + "priority": { + "title": "priority", + "description": "Priority expression of rule with 0 being the most important", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "integer" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to integer." + } + ] + }, + "runOnce": { + "type": "boolean", + "title": "Run Once", + "description": "True if rule should run once per unique conditions" + }, + "entity": { "type": "string", - "title": "Activity type", - "description": "The Activity.Type to match" + "title": "Entity being assigned", + "description": "Entity being assigned to property choice" + }, + "properties": { + "type": "array", + "title": "Possible properties", + "description": "Properties to be chosen between", + "items": { + "type": "string", + "title": "Property name" + } + }, + "entities": { + "type": "array", + "title": "Possible properties", + "description": "Entities being assigned", + "items": { + "type": "string", + "title": "Entity name" + } } }, "additionalProperties": false, @@ -4505,16 +6937,15 @@ "title": "Type", "required": [ "actions", - "type", "$kind" ] } ] }, - "Microsoft.OnBeginDialog": { + "Microsoft.OnClearProperty": { "$role": "union(Microsoft.ITriggerCondition)", - "title": "On begin dialog", - "description": "Actions to perform when this dialog begins.", + "title": "On clear property", + "description": "Actions to take when a property needs to be cleared.", "type": "object", "properties": { "$kind": { @@ -4522,7 +6953,7 @@ "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", "type": "string", "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", - "const": "Microsoft.OnBeginDialog" + "const": "Microsoft.OnClearProperty" }, "$copy": { "title": "$copy", @@ -4548,7 +6979,17 @@ "examples": [ "user.vip == true" ], - "type": "string" + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] }, "actions": { "type": "array", @@ -4557,6 +6998,32 @@ "$kind": "Microsoft.IDialog", "$ref": "#/definitions/Microsoft.IDialog" } + }, + "priority": { + "title": "priority", + "description": "Priority expression of rule with 0 being the most important", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "integer" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to integer." + } + ] + }, + "runOnce": { + "type": "boolean", + "title": "Run Once", + "description": "True if rule should run once per unique conditions" + }, + "property": { + "type": "string", + "title": "Property", + "description": "Property that will be cleared" } }, "additionalProperties": false, @@ -4581,10 +7048,10 @@ } ] }, - "Microsoft.OnCancelDialog": { + "Microsoft.OnCondition": { "$role": "union(Microsoft.ITriggerCondition)", - "title": "On cancel dialog", - "description": "Actions to perform on cancel dialog event.", + "title": "On condition", + "description": "Actions to perform when specified condition is true.", "type": "object", "properties": { "$kind": { @@ -4592,7 +7059,7 @@ "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", "type": "string", "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", - "const": "Microsoft.OnCancelDialog" + "const": "Microsoft.OnCondition" }, "$copy": { "title": "$copy", @@ -4618,7 +7085,17 @@ "examples": [ "user.vip == true" ], - "type": "string" + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] }, "actions": { "type": "array", @@ -4627,6 +7104,27 @@ "$kind": "Microsoft.IDialog", "$ref": "#/definitions/Microsoft.IDialog" } + }, + "priority": { + "title": "priority", + "description": "Priority expression of rule with 0 being the most important", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "integer" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to integer." + } + ] + }, + "runOnce": { + "type": "boolean", + "title": "Run Once", + "description": "True if rule should run once per unique conditions" } }, "additionalProperties": false, @@ -4651,10 +7149,10 @@ } ] }, - "Microsoft.OnCondition": { + "Microsoft.OnConversationUpdateActivity": { "$role": "union(Microsoft.ITriggerCondition)", - "title": "On condition", - "description": "Actions to perform when specified condition is true.", + "title": "On ConversationUpdate activity", + "description": "Actions to perform on receipt of an activity with type 'ConversationUpdate'.", "type": "object", "properties": { "$kind": { @@ -4662,7 +7160,7 @@ "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", "type": "string", "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", - "const": "Microsoft.OnCondition" + "const": "Microsoft.OnConversationUpdateActivity" }, "$copy": { "title": "$copy", @@ -4688,7 +7186,17 @@ "examples": [ "user.vip == true" ], - "type": "string" + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] }, "actions": { "type": "array", @@ -4697,6 +7205,27 @@ "$kind": "Microsoft.IDialog", "$ref": "#/definitions/Microsoft.IDialog" } + }, + "priority": { + "title": "priority", + "description": "Priority expression of rule with 0 being the most important", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "integer" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to integer." + } + ] + }, + "runOnce": { + "type": "boolean", + "title": "Run Once", + "description": "True if rule should run once per unique conditions" } }, "additionalProperties": false, @@ -4721,10 +7250,10 @@ } ] }, - "Microsoft.OnConversationUpdateActivity": { + "Microsoft.OnCustomEvent": { "$role": "union(Microsoft.ITriggerCondition)", - "title": "On ConversationUpdate activity", - "description": "Actions to perform on receipt of an activity with type 'ConversationUpdate'.", + "title": "On custom event", + "description": "Actions to perform when a custom event is detected. Use 'Emit a custom event' action to raise a custom event.", "type": "object", "properties": { "$kind": { @@ -4732,7 +7261,7 @@ "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", "type": "string", "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", - "const": "Microsoft.OnConversationUpdateActivity" + "const": "Microsoft.OnCustomEvent" }, "$copy": { "title": "$copy", @@ -4758,7 +7287,17 @@ "examples": [ "user.vip == true" ], - "type": "string" + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] }, "actions": { "type": "array", @@ -4767,6 +7306,32 @@ "$kind": "Microsoft.IDialog", "$ref": "#/definitions/Microsoft.IDialog" } + }, + "priority": { + "title": "priority", + "description": "Priority expression of rule with 0 being the most important", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "integer" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to integer." + } + ] + }, + "runOnce": { + "type": "boolean", + "title": "Run Once", + "description": "True if rule should run once per unique conditions" + }, + "event": { + "type": "string", + "title": "Custom event name", + "description": "Name of the custom event." } }, "additionalProperties": false, @@ -4786,15 +7351,16 @@ "title": "Type", "required": [ "actions", + "event", "$kind" ] } ] }, - "Microsoft.OnCustomEvent": { + "Microsoft.OnDialogEvent": { "$role": "union(Microsoft.ITriggerCondition)", - "title": "On custom event", - "description": "Actions to perform when a custom event is detected. Use 'Emit a custom event' action to raise a custom event.", + "title": "On dialog event", + "description": "Actions to perform when a specific dialog event occurs.", "type": "object", "properties": { "$kind": { @@ -4802,7 +7368,7 @@ "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", "type": "string", "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", - "const": "Microsoft.OnCustomEvent" + "const": "Microsoft.OnDialogEvent" }, "$copy": { "title": "$copy", @@ -4828,7 +7394,17 @@ "examples": [ "user.vip == true" ], - "type": "string" + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] }, "actions": { "type": "array", @@ -4838,10 +7414,31 @@ "$ref": "#/definitions/Microsoft.IDialog" } }, + "priority": { + "title": "priority", + "description": "Priority expression of rule with 0 being the most important", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "integer" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to integer." + } + ] + }, + "runOnce": { + "type": "boolean", + "title": "Run Once", + "description": "True if rule should run once per unique conditions" + }, "event": { "type": "string", - "title": "Custom event name", - "description": "Name of the custom event." + "title": "Dialog event name", + "description": "Name of dialog event." } }, "additionalProperties": false, @@ -4867,10 +7464,10 @@ } ] }, - "Microsoft.OnDialogEvent": { + "Microsoft.OnEndOfActions": { "$role": "union(Microsoft.ITriggerCondition)", - "title": "On dialog event", - "description": "Actions to perform when a specific dialog event occurs.", + "title": "On end of actions", + "description": "Actions to take when there are no more actions in the current dialog.", "type": "object", "properties": { "$kind": { @@ -4878,7 +7475,7 @@ "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", "type": "string", "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", - "const": "Microsoft.OnDialogEvent" + "const": "Microsoft.OnEndOfActions" }, "$copy": { "title": "$copy", @@ -4904,7 +7501,17 @@ "examples": [ "user.vip == true" ], - "type": "string" + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] }, "actions": { "type": "array", @@ -4914,10 +7521,26 @@ "$ref": "#/definitions/Microsoft.IDialog" } }, - "event": { - "type": "string", - "title": "Dialog event name", - "description": "Name of dialog event." + "priority": { + "title": "priority", + "description": "Priority expression of rule with 0 being the most important", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "integer" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to integer." + } + ] + }, + "runOnce": { + "type": "boolean", + "title": "Run Once", + "description": "True if rule should run once per unique conditions" } }, "additionalProperties": false, @@ -4937,7 +7560,6 @@ "title": "Type", "required": [ "actions", - "event", "$kind" ] } @@ -4980,7 +7602,17 @@ "examples": [ "user.vip == true" ], - "type": "string" + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] }, "actions": { "type": "array", @@ -4989,6 +7621,27 @@ "$kind": "Microsoft.IDialog", "$ref": "#/definitions/Microsoft.IDialog" } + }, + "priority": { + "title": "priority", + "description": "Priority expression of rule with 0 being the most important", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "integer" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to integer." + } + ] + }, + "runOnce": { + "type": "boolean", + "title": "Run Once", + "description": "True if rule should run once per unique conditions" } }, "additionalProperties": false, @@ -5050,7 +7703,17 @@ "examples": [ "user.vip == true" ], - "type": "string" + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] }, "actions": { "type": "array", @@ -5059,6 +7722,27 @@ "$kind": "Microsoft.IDialog", "$ref": "#/definitions/Microsoft.IDialog" } + }, + "priority": { + "title": "priority", + "description": "Priority expression of rule with 0 being the most important", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "integer" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to integer." + } + ] + }, + "runOnce": { + "type": "boolean", + "title": "Run Once", + "description": "True if rule should run once per unique conditions" } }, "additionalProperties": false, @@ -5120,7 +7804,17 @@ "examples": [ "user.vip == true" ], - "type": "string" + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] }, "actions": { "type": "array", @@ -5129,6 +7823,27 @@ "$kind": "Microsoft.IDialog", "$ref": "#/definitions/Microsoft.IDialog" } + }, + "priority": { + "title": "priority", + "description": "Priority expression of rule with 0 being the most important", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "integer" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to integer." + } + ] + }, + "runOnce": { + "type": "boolean", + "title": "Run Once", + "description": "True if rule should run once per unique conditions" } }, "additionalProperties": false, @@ -5190,7 +7905,17 @@ "examples": [ "user.vip == true" ], - "type": "string" + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] }, "actions": { "type": "array", @@ -5199,6 +7924,27 @@ "$kind": "Microsoft.IDialog", "$ref": "#/definitions/Microsoft.IDialog" } + }, + "priority": { + "title": "priority", + "description": "Priority expression of rule with 0 being the most important", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "integer" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to integer." + } + ] + }, + "runOnce": { + "type": "boolean", + "title": "Run Once", + "description": "True if rule should run once per unique conditions" } }, "additionalProperties": false, @@ -5260,7 +8006,17 @@ "examples": [ "user.vip == true" ], - "type": "string" + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] }, "actions": { "type": "array", @@ -5270,6 +8026,27 @@ "$ref": "#/definitions/Microsoft.IDialog" } }, + "priority": { + "title": "priority", + "description": "Priority expression of rule with 0 being the most important", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "integer" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to integer." + } + ] + }, + "runOnce": { + "type": "boolean", + "title": "Run Once", + "description": "True if rule should run once per unique conditions" + }, "intent": { "type": "string", "title": "Intent", @@ -5301,7 +8078,6 @@ "title": "Type", "required": [ "actions", - "intent", "$kind" ] } @@ -5344,7 +8120,17 @@ "examples": [ "user.vip == true" ], - "type": "string" + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] }, "actions": { "type": "array", @@ -5353,6 +8139,27 @@ "$kind": "Microsoft.IDialog", "$ref": "#/definitions/Microsoft.IDialog" } + }, + "priority": { + "title": "priority", + "description": "Priority expression of rule with 0 being the most important", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "integer" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to integer." + } + ] + }, + "runOnce": { + "type": "boolean", + "title": "Run Once", + "description": "True if rule should run once per unique conditions" } }, "additionalProperties": false, @@ -5414,7 +8221,17 @@ "examples": [ "user.vip == true" ], - "type": "string" + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] }, "actions": { "type": "array", @@ -5423,6 +8240,27 @@ "$kind": "Microsoft.IDialog", "$ref": "#/definitions/Microsoft.IDialog" } + }, + "priority": { + "title": "priority", + "description": "Priority expression of rule with 0 being the most important", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "integer" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to integer." + } + ] + }, + "runOnce": { + "type": "boolean", + "title": "Run Once", + "description": "True if rule should run once per unique conditions" } }, "additionalProperties": false, @@ -5484,7 +8322,17 @@ "examples": [ "user.vip == true" ], - "type": "string" + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] }, "actions": { "type": "array", @@ -5493,6 +8341,27 @@ "$kind": "Microsoft.IDialog", "$ref": "#/definitions/Microsoft.IDialog" } + }, + "priority": { + "title": "priority", + "description": "Priority expression of rule with 0 being the most important", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "integer" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to integer." + } + ] + }, + "runOnce": { + "type": "boolean", + "title": "Run Once", + "description": "True if rule should run once per unique conditions" } }, "additionalProperties": false, @@ -5554,7 +8423,17 @@ "examples": [ "user.vip == true" ], - "type": "string" + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] }, "actions": { "type": "array", @@ -5563,6 +8442,27 @@ "$kind": "Microsoft.IDialog", "$ref": "#/definitions/Microsoft.IDialog" } + }, + "priority": { + "title": "priority", + "description": "Priority expression of rule with 0 being the most important", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "integer" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to integer." + } + ] + }, + "runOnce": { + "type": "boolean", + "title": "Run Once", + "description": "True if rule should run once per unique conditions" } }, "additionalProperties": false, @@ -5624,7 +8524,118 @@ "examples": [ "user.vip == true" ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + }, + "actions": { + "type": "array", + "description": "Sequence of actions to execute.", + "items": { + "$kind": "Microsoft.IDialog", + "$ref": "#/definitions/Microsoft.IDialog" + } + }, + "priority": { + "title": "priority", + "description": "Priority expression of rule with 0 being the most important", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "integer" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to integer." + } + ] + }, + "runOnce": { + "type": "boolean", + "title": "Run Once", + "description": "True if rule should run once per unique conditions" + } + }, + "additionalProperties": false, + "patternProperties": { + "^\\$": { "type": "string" + } + }, + "anyOf": [ + { + "title": "Reference", + "required": [ + "$copy" + ] + }, + { + "title": "Type", + "required": [ + "actions", + "$kind" + ] + } + ] + }, + "Microsoft.OnQnAMatch": { + "$role": "union(Microsoft.ITriggerCondition)", + "title": "On QnAMaker Match", + "description": "Actions to perform on when an match from QnAMaker is found.", + "type": "object", + "properties": { + "$kind": { + "title": "$kind", + "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", + "type": "string", + "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", + "const": "Microsoft.OnQnAMatch" + }, + "$copy": { + "title": "$copy", + "description": "Copy the definition by id from a .dialog file.", + "type": "string", + "pattern": "^(([a-zA-Z][a-zA-Z0-9.]*)?(#[a-zA-Z][a-zA-Z0-9.]*)?)$" + }, + "$id": { + "title": "$id", + "description": "Inline id for reuse of an inline definition", + "type": "string", + "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" + }, + "$designer": { + "title": "$designer", + "type": "object", + "description": "Extra information for the Bot Framework Designer." + }, + "condition": { + "$role": "expression", + "title": "Condition", + "description": "Condition (expression).", + "examples": [ + "user.vip == true" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] }, "actions": { "type": "array", @@ -5633,6 +8644,27 @@ "$kind": "Microsoft.IDialog", "$ref": "#/definitions/Microsoft.IDialog" } + }, + "priority": { + "title": "priority", + "description": "Priority expression of rule with 0 being the most important", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "integer" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to integer." + } + ] + }, + "runOnce": { + "type": "boolean", + "title": "Run Once", + "description": "True if rule should run once per unique conditions" } }, "additionalProperties": false, @@ -5694,7 +8726,17 @@ "examples": [ "user.vip == true" ], - "type": "string" + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] }, "actions": { "type": "array", @@ -5703,6 +8745,27 @@ "$kind": "Microsoft.IDialog", "$ref": "#/definitions/Microsoft.IDialog" } + }, + "priority": { + "title": "priority", + "description": "Priority expression of rule with 0 being the most important", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "integer" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to integer." + } + ] + }, + "runOnce": { + "type": "boolean", + "title": "Run Once", + "description": "True if rule should run once per unique conditions" } }, "additionalProperties": false, @@ -5764,7 +8827,17 @@ "examples": [ "user.vip == true" ], - "type": "string" + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] }, "actions": { "type": "array", @@ -5773,6 +8846,27 @@ "$kind": "Microsoft.IDialog", "$ref": "#/definitions/Microsoft.IDialog" } + }, + "priority": { + "title": "priority", + "description": "Priority expression of rule with 0 being the most important", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "integer" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to integer." + } + ] + }, + "runOnce": { + "type": "boolean", + "title": "Run Once", + "description": "True if rule should run once per unique conditions" } }, "additionalProperties": false, @@ -5834,7 +8928,17 @@ "examples": [ "user.vip == true" ], - "type": "string" + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] }, "actions": { "type": "array", @@ -5843,6 +8947,27 @@ "$kind": "Microsoft.IDialog", "$ref": "#/definitions/Microsoft.IDialog" } + }, + "priority": { + "title": "priority", + "description": "Priority expression of rule with 0 being the most important", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "integer" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to integer." + } + ] + }, + "runOnce": { + "type": "boolean", + "title": "Run Once", + "description": "True if rule should run once per unique conditions" } }, "additionalProperties": false, @@ -6056,27 +9181,27 @@ }, "knowledgeBaseId": { "$role": "expression", + "type": "string", "title": "KnowledgeBase Id", "description": "KnowledgeBase Id of your QnA Maker KnowledgeBase.", - "default": "settings.qna.knowledgebaseid", - "type": "string" + "default": "=settings.qna.knowledgebaseid" }, "endpointKey": { "$role": "expression", + "type": "string", "title": "Endpoint Key", "description": "Endpoint key for the QnA Maker KB.", - "default": "settings.qna.endpointkey", - "type": "string" + "default": "=settings.qna.endpointkey" }, "hostname": { "$role": "expression", + "type": "string", "title": "Hostname", "description": "Hostname for your QnA Maker service.", - "default": "settings.qna.hostname", + "default": "=settings.qna.hostname", "examples": [ "https://yourserver.azurewebsites.net/qnamaker" - ], - "type": "string" + ] }, "noAnswer": { "$kind": "Microsoft.IActivityTemplate", @@ -6086,18 +9211,31 @@ "$ref": "#/definitions/Microsoft.IActivityTemplate" }, "threshold": { - "type": "number", + "$role": "expression", "title": "Threshold", "description": "Threshold score to filter results.", - "default": 0.3 + "oneOf": [ + { + "type": "number", + "default": 0.3, + "title": "number" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to number." + } + ] }, "activeLearningCardTitle": { + "$role": "expression", "type": "string", "title": "Active learning card title", "description": "Title for active learning suggestions card.", "default": "Did you mean:" }, "cardNoMatchText": { + "$role": "expression", "type": "string", "title": "Card no match text", "description": "Text for no match option.", @@ -6110,6 +9248,161 @@ "default": "Thanks for the feedback.", "$ref": "#/definitions/Microsoft.IActivityTemplate" }, + "strictFilters": { + "$role": "expression", + "title": "Strict Filters", + "description": "Metadata filters to use when calling the QnA Maker KB.", + "oneOf": [ + { + "type": "array", + "items": { + "type": "object", + "properties": { + "name": { + "type": "string", + "title": "Name", + "maximum": 100 + }, + "value": { + "type": "string", + "title": "Value", + "maximum": 100 + } + }, + "title": "object" + }, + "title": "array" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to array." + } + ] + }, + "top": { + "$role": "expression", + "title": "Top", + "description": "The number of answers you want to retrieve.", + "oneOf": [ + { + "type": "number", + "default": 3, + "title": "number" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to number." + } + ] + }, + "isTest": { + "type": "boolean", + "title": "IsTest", + "description": "True, if pointing to Test environment, else false.", + "default": false + }, + "rankerType": { + "type": "string", + "title": "RankerType", + "description": "Type of Ranker.", + "enum": [ + "Default", + "QuestionOnly", + "AutoSuggestQuestion" + ], + "default": "Default" + } + }, + "patternProperties": { + "^\\$": { + "type": "string" + } + }, + "anyOf": [ + { + "title": "Reference", + "required": [ + "$copy" + ] + }, + { + "title": "Type", + "required": [ + "knowledgeBaseId", + "endpointKey", + "hostname", + "$kind" + ] + } + ] + }, + "Microsoft.QnAMakerRecognizer": { + "$role": "union(Microsoft.Recognizer)", + "title": "QnAMaker Recognizer", + "description": "Recognizer for generating QnAMatch intents from a KB.", + "type": "object", + "properties": { + "$kind": { + "title": "$kind", + "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", + "type": "string", + "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", + "const": "Microsoft.QnAMakerRecognizer" + }, + "$copy": { + "title": "$copy", + "description": "Copy the definition by id from a .dialog file.", + "type": "string", + "pattern": "^(([a-zA-Z][a-zA-Z0-9.]*)?(#[a-zA-Z][a-zA-Z0-9.]*)?)$" + }, + "$id": { + "title": "$id", + "description": "Inline id for reuse of an inline definition", + "type": "string", + "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" + }, + "$designer": { + "title": "$designer", + "type": "object", + "description": "Extra information for the Bot Framework Designer." + }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional unique id using with RecognizerSet." + }, + "knowledgeBaseId": { + "$role": "expression", + "type": "string", + "title": "KnowledgeBase Id", + "description": "KnowledgeBase Id of your QnA Maker KnowledgeBase.", + "default": "settings.qna.knowledgebaseid" + }, + "endpointKey": { + "$role": "expression", + "type": "string", + "title": "Endpoint Key", + "description": "Endpoint key for the QnA Maker KB.", + "default": "settings.qna.endpointkey" + }, + "hostname": { + "$role": "expression", + "type": "string", + "title": "Hostname", + "description": "Hostname for your QnA Maker service.", + "default": "settings.qna.hostname", + "examples": [ + "https://yourserver.azurewebsites.net/qnamaker" + ] + }, + "threshold": { + "type": "number", + "title": "Threshold", + "description": "Threshold score to filter results.", + "default": 0.3 + }, "strictFilters": { "type": "array", "title": "Strict Filters", @@ -6130,13 +9423,84 @@ } } }, - "top": { - "type": "number", - "title": "Top", - "description": "The number of answers you want to retrieve.", - "default": 3 + "top": { + "type": "number", + "title": "Top", + "description": "The number of answers you want to retrieve.", + "default": 3 + }, + "isTest": { + "type": "boolean", + "title": "IsTest", + "description": "True, if pointing to Test environment, else false.", + "default": false + }, + "rankerType": { + "type": "string", + "title": "RankerType", + "description": "Type of Ranker.", + "default": "Default" + } + }, + "additionalProperties": false, + "patternProperties": { + "^\\$": { + "type": "string" + } + }, + "anyOf": [ + { + "title": "Reference", + "required": [ + "$copy" + ] + }, + { + "title": "Type", + "required": [ + "knowledgeBaseId", + "endpointKey", + "hostname", + "$kind" + ] + } + ] + }, + "Microsoft.RandomSelector": { + "$role": "union(Microsoft.ITriggerSelector)", + "title": "Random rule selector", + "description": "Select most specific true rule", + "type": "object", + "properties": { + "$kind": { + "title": "$kind", + "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", + "type": "string", + "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", + "const": "Microsoft.RandomSelector" + }, + "$copy": { + "title": "$copy", + "description": "Copy the definition by id from a .dialog file.", + "type": "string", + "pattern": "^(([a-zA-Z][a-zA-Z0-9.]*)?(#[a-zA-Z][a-zA-Z0-9.]*)?)$" + }, + "$id": { + "title": "$id", + "description": "Inline id for reuse of an inline definition", + "type": "string", + "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" + }, + "$designer": { + "title": "$designer", + "type": "object", + "description": "Extra information for the Bot Framework Designer." + }, + "seed": { + "type": "integer" } }, + "additionalProperties": false, "patternProperties": { "^\\$": { "type": "string" @@ -6152,18 +9516,61 @@ { "title": "Type", "required": [ - "knowledgeBaseId", - "endpointKey", - "hostname", "$kind" ] } ] }, - "Microsoft.RandomSelector": { - "$role": "union(Microsoft.ITriggerSelector)", - "title": "Random rule selector", - "description": "Select most specific true rule", + "Microsoft.Recognizer": { + "title": "Microsoft Recognizer", + "description": "Union of components which implement the Recognizer abstract class", + "$role": "union", + "oneOf": [ + { + "title": "Microsoft.AdaptiveCardRecognizer", + "description": "Recognizer for detecting the value response from an Adaptive Card.", + "$ref": "#/definitions/Microsoft.AdaptiveCardRecognizer" + }, + { + "title": "Microsoft.CrossTrainedRecognizerSet", + "description": "Recognizer for selecting between cross trained recognizers.", + "$ref": "#/definitions/Microsoft.CrossTrainedRecognizerSet" + }, + { + "title": "Microsoft.LuisRecognizer", + "description": "LUIS recognizer.", + "$ref": "#/definitions/Microsoft.LuisRecognizer" + }, + { + "title": "Microsoft.MultiLanguageRecognizer", + "description": "Configure one recognizer per language and the specify the language fallback policy.", + "$ref": "#/definitions/Microsoft.MultiLanguageRecognizer" + }, + { + "title": "Microsoft.QnAMakerRecognizer", + "description": "Recognizer for generating QnAMatch intents from a KB.", + "$ref": "#/definitions/Microsoft.QnAMakerRecognizer" + }, + { + "title": "Microsoft.RecognizerSet", + "description": "Creates the union of the intents and entities of the recognizers in the set.", + "$ref": "#/definitions/Microsoft.RecognizerSet" + }, + { + "title": "Microsoft.RegexRecognizer", + "description": "Use regular expressions to recognize intents and entities from user input.", + "$ref": "#/definitions/Microsoft.RegexRecognizer" + }, + { + "type": "string", + "title": "string" + } + ] + }, + "Microsoft.RecognizerSet": { + "$role": "union(Microsoft.Recognizer)", + "title": "Recognizer Set", + "description": "Creates the union of the intents and entities of the recognizers in the set.", "type": "object", "properties": { "$kind": { @@ -6171,7 +9578,7 @@ "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", "type": "string", "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", - "const": "Microsoft.RandomSelector" + "const": "Microsoft.RecognizerSet" }, "$copy": { "title": "$copy", @@ -6190,8 +9597,19 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, - "seed": { - "type": "integer" + "id": { + "type": "string", + "title": "Id", + "description": "Optional unique id using with RecognizerSet. Other recognizers should return 'DeferToRecognizer_{Id}' intent when cross training data for this recognizer." + }, + "recognizers": { + "type": "array", + "title": "Recognizers", + "description": "List of Recognizers defined for this set.", + "items": { + "$kind": "Microsoft.Recognizer", + "$ref": "#/definitions/Microsoft.Recognizer" + } } }, "additionalProperties": false, @@ -6210,6 +9628,7 @@ { "title": "Type", "required": [ + "recognizers", "$kind" ] } @@ -6280,7 +9699,7 @@ ] }, "Microsoft.RegexRecognizer": { - "$role": "union(Microsoft.IRecognizer)", + "$role": "union(Microsoft.Recognizer)", "title": "Regex recognizer", "description": "Use regular expressions to recognize intents and entities from user input.", "type": "object", @@ -6309,6 +9728,11 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional unique id using with RecognizerSet. Other recognizers should return 'DeferToRecognizer_{Id}' intent when cross training data for this recognizer." + }, "intents": { "type": "array", "title": "RegEx patterns to intents", @@ -6391,20 +9815,66 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "disabled": { + "$role": "expression", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + }, "options": { - "type": "object", + "$role": "expression", "title": "Options", "description": "One or more options that are passed to the dialog that is called.", - "additionalProperties": { - "type": "string", - "title": "Options" - } + "oneOf": [ + { + "type": "object", + "additionalProperties": { + "type": "string", + "title": "Options" + }, + "title": "object" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to object." + } + ] }, - "includeActivity": { - "type": "boolean", - "title": "Include Activity", - "description": "When set to true, dialog that is called can process the current activity.", - "default": false + "activityProcessed": { + "$role": "expression", + "title": "Activity Processed", + "description": "When set to false, the dialog that is called can process the current activity.", + "oneOf": [ + { + "type": "boolean", + "default": true, + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] } }, "additionalProperties": false, @@ -6458,8 +9928,34 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "disabled": { + "$role": "expression", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + }, "dialog": { "$kind": "Microsoft.IDialog", + "$role": "expression", + "type": "string", "title": "Dialog name", "description": "Name of the dialog to call.", "examples": [ @@ -6468,19 +9964,41 @@ "$ref": "#/definitions/Microsoft.IDialog" }, "options": { - "type": "object", + "$role": "expression", "title": "Options", "description": "One or more options that are passed to the dialog that is called.", - "additionalProperties": { - "type": "string", - "title": "Options" - } + "oneOf": [ + { + "type": "object", + "additionalProperties": { + "type": "string", + "title": "Options" + }, + "title": "object" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to object." + } + ] }, - "includeActivity": { - "type": "boolean", - "title": "Include Activity", - "description": "When set to true, dialog that is called can process the current activity.", - "default": false + "activityProcessed": { + "$role": "expression", + "title": "Activity Processed", + "description": "When set to false, the dialog that is called can process the current activity.", + "oneOf": [ + { + "type": "boolean", + "default": true, + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] } }, "additionalProperties": false, @@ -6534,6 +10052,30 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "disabled": { + "$role": "expression", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + }, "activity": { "$kind": "Microsoft.IActivityTemplate", "title": "Activity", @@ -6592,6 +10134,30 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "disabled": { + "$role": "expression", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + }, "assignments": { "type": "array", "title": "Assignments", @@ -6601,26 +10167,137 @@ "properties": { "property": { "$role": "expression", + "type": "string", "title": "Property", "description": "Property (named location to store information).", "examples": [ "user.age" - ], - "type": "string" + ] }, "value": { "$role": "expression", + "type": [ + "object", + "array", + "number", + "integer", + "boolean", + "string" + ], "title": "Value", "description": "New value or expression.", "examples": [ - "'milk'", - "dialog.favColor", - "dialog.favColor == 'red'" - ], - "type": "string" + "='milk'", + "=dialog.favColor", + "=dialog.favColor == 'red'" + ] } } - } + } + } + }, + "additionalProperties": false, + "patternProperties": { + "^\\$": { + "type": "string" + } + }, + "anyOf": [ + { + "title": "Reference", + "required": [ + "$copy" + ] + }, + { + "title": "Type", + "required": [ + "assignments", + "$kind" + ] + } + ] + }, + "Microsoft.SetProperty": { + "$role": "union(Microsoft.IDialog)", + "title": "Set property", + "description": "Set property to a value.", + "type": "object", + "properties": { + "$kind": { + "title": "$kind", + "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", + "type": "string", + "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", + "const": "Microsoft.SetProperty" + }, + "$copy": { + "title": "$copy", + "description": "Copy the definition by id from a .dialog file.", + "type": "string", + "pattern": "^(([a-zA-Z][a-zA-Z0-9.]*)?(#[a-zA-Z][a-zA-Z0-9.]*)?)$" + }, + "$id": { + "title": "$id", + "description": "Inline id for reuse of an inline definition", + "type": "string", + "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" + }, + "$designer": { + "title": "$designer", + "type": "object", + "description": "Extra information for the Bot Framework Designer." + }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "disabled": { + "$role": "expression", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + }, + "property": { + "$role": "expression", + "type": "string", + "title": "Property", + "description": "Property (named location to store information).", + "examples": [ + "user.age" + ] + }, + "value": { + "$role": "expression", + "type": [ + "object", + "array", + "number", + "integer", + "boolean", + "string" + ], + "title": "Value", + "description": "New value or expression.", + "examples": [ + "='milk'", + "=dialog.favColor", + "=dialog.favColor == 'red'" + ] } }, "additionalProperties": false, @@ -6639,16 +10316,17 @@ { "title": "Type", "required": [ - "assignments", + "property", + "value", "$kind" ] } ] }, - "Microsoft.SetProperty": { + "Microsoft.SignOutUser": { "$role": "union(Microsoft.IDialog)", - "title": "Set property", - "description": "Set property to a value.", + "title": "Sign Out User", + "description": "Sign a user out that was logged in previously using OAuthInput.", "type": "object", "properties": { "$kind": { @@ -6656,7 +10334,7 @@ "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", "type": "string", "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", - "const": "Microsoft.SetProperty" + "const": "Microsoft.SignOutUser" }, "$copy": { "title": "$copy", @@ -6675,25 +10353,44 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, - "property": { + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "userId": { "$role": "expression", - "title": "Property", - "description": "Property (named location to store information).", + "type": "string", + "title": "ActivityId", + "description": "expression to an activityId to get the members. If none is defined then the current activity id will be used.", "examples": [ - "user.age" - ], - "type": "string" + "=$lastActivity" + ] }, - "value": { + "connectionName": { "$role": "expression", - "title": "Value", - "description": "New value or expression.", + "type": "string", + "title": "Connection Name", + "description": "Connection name that was used with OAuthInput to log a user in." + }, + "disabled": { + "$role": "expression", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", "examples": [ - "'milk'", - "dialog.favColor", - "dialog.favColor == 'red'" + "user.age > 3" ], - "type": "string" + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] } }, "additionalProperties": false, @@ -6712,8 +10409,6 @@ { "title": "Type", "required": [ - "property", - "value", "$kind" ] } @@ -6807,14 +10502,38 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, "condition": { "$role": "expression", + "type": "string", "title": "Condition", "description": "Property to evaluate.", "examples": [ "user.favColor" + ] + }, + "disabled": { + "$role": "expression", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" ], - "type": "string" + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] }, "cases": { "type": "array", @@ -6829,13 +10548,18 @@ "properties": { "value": { "$role": "expression", + "type": [ + "number", + "integer", + "boolean", + "string" + ], "title": "Value", "description": "Value.", "examples": [ "'red'", "dialog.colors.red" - ], - "type": "string" + ] }, "actions": { "type": "array", @@ -6970,7 +10694,17 @@ "examples": [ "user.age > 10" ], - "type": "string" + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] }, "description": { "type": "string", @@ -7060,7 +10794,17 @@ "examples": [ "user.vip == true" ], - "type": "string" + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] } } }, @@ -7137,7 +10881,17 @@ "examples": [ "user.vip == true" ], - "type": "string" + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] } } }, @@ -7227,7 +10981,17 @@ "examples": [ "user.vip == true" ], - "type": "string" + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] } } }, @@ -7297,6 +11061,11 @@ "title": "Microsoft.Test.UserTyping", "description": "Sends typing activity to the bot.", "$ref": "#/definitions/Microsoft.Test.UserTyping" + }, + { + "type": "string", + "title": "Reference to Microsoft.Test.ITestAction", + "description": "Reference to Microsoft.Test.ITestAction .dialog file." } ] }, @@ -7348,6 +11117,12 @@ "$ref": "#/definitions/Microsoft.Test.ITestAction" } }, + "locale": { + "type": "string", + "title": "Locale", + "description": "Set the locale for the user utterances in the script.", + "default": "en-us" + }, "enableTrace": { "type": "boolean", "title": "Enable Trace Activity", @@ -7721,6 +11496,18 @@ "title": "Id", "description": "Optional id for the dialog" }, + "disabled": { + "$role": "expression", + "type": [ + "boolean", + "string" + ], + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ] + }, "prompt": { "$kind": "Microsoft.IActivityTemplate", "title": "Initial prompt", @@ -7758,7 +11545,11 @@ "$ref": "#/definitions/Microsoft.IActivityTemplate" }, "maxTurnCount": { - "type": "integer", + "$role": "expression", + "type": [ + "integer", + "string" + ], "title": "Max turn count", "description": "Maximum number of re-prompt attempts to collect information.", "default": 3, @@ -7776,12 +11567,12 @@ ], "items": { "$role": "expression", - "type": "string", - "description": "String must contain an expression." + "type": "string" } }, "property": { "$role": "expression", + "type": "string", "title": "Property", "description": "Property to store collected information. Input will be skipped if property has value (unless 'Always prompt' is true).", "examples": [ @@ -7789,32 +11580,49 @@ "user.name", "conversation.issueTitle", "dialog.favColor" - ], - "type": "string" + ] }, "defaultValue": { "$role": "expression", + "type": [ + "object", + "array", + "number", + "integer", + "boolean", + "string" + ], "title": "Default value", "description": "Expression to examine on each turn of the conversation as possible value to the property.", "examples": [ "@userName", "coalesce(@number, @partySize)" - ], - "type": "string" + ] }, "value": { "$role": "expression", + "type": [ + "object", + "array", + "number", + "integer", + "boolean", + "string" + ], "title": "Value", "description": "Gets or sets a value expression which can be used to intialize the input prompt.", "examples": [ "@userName" - ], - "type": "string" + ] }, "alwaysPrompt": { - "type": "boolean", + "$role": "expression", + "type": [ + "boolean", + "string" + ], "title": "Always prompt", - "description": "Collect information even if the specified 'property' is not empty.", + "description": "Collect information even if the specified 'property' is not empty.", "default": false, "examples": [ false @@ -7822,22 +11630,26 @@ }, "allowInterruptions": { "$role": "expression", + "type": [ + "boolean", + "string" + ], "title": "Allow Interruptions", "description": "A boolean expression that determines whether the parent should be allowed to interrupt the input.", "default": "true", "examples": [ "true" - ], - "type": "string" + ] }, "outputFormat": { "$role": "expression", + "type": "string", "title": "Output format", "description": "Expression to format the output.", "examples": [ - "toUpper(this.value)" - ], - "type": "string" + "=toUpper(this.value)", + "@{toUpper(this.value)}" + ] } }, "additionalProperties": false, @@ -7949,21 +11761,60 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "disabled": { + "$role": "expression", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + }, "name": { + "$role": "expression", "type": "string", "title": "Name", "description": "Name of the trace activity" }, + "label": { + "$role": "expression", + "type": "string", + "title": "Label", + "description": "Label for the trace activity (used to identify it in a list of trace activities.)" + }, "valueType": { + "$role": "expression", "type": "string", "title": "Value type", "description": "Type of value" }, "value": { "$role": "expression", + "type": [ + "object", + "array", + "number", + "integer", + "boolean", + "string" + ], "title": "Value", - "description": "Property that holds the value to send as trace activity.", - "type": "string" + "description": "Property that holds the value to send as trace activity." } }, "additionalProperties": false, @@ -8039,6 +11890,97 @@ } ] }, + "Microsoft.UpdateActivity": { + "$role": "union(Microsoft.IDialog)", + "title": "Send an activity", + "description": "Respond with an activity.", + "type": "object", + "properties": { + "$kind": { + "title": "$kind", + "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", + "type": "string", + "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", + "const": "Microsoft.UpdateActivity" + }, + "$copy": { + "title": "$copy", + "description": "Copy the definition by id from a .dialog file.", + "type": "string", + "pattern": "^(([a-zA-Z][a-zA-Z0-9.]*)?(#[a-zA-Z][a-zA-Z0-9.]*)?)$" + }, + "$id": { + "title": "$id", + "description": "Inline id for reuse of an inline definition", + "type": "string", + "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" + }, + "$designer": { + "title": "$designer", + "type": "object", + "description": "Extra information for the Bot Framework Designer." + }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "disabled": { + "$role": "expression", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + }, + "activityId": { + "$role": "expression", + "type": "string", + "title": "Activity Id", + "dDescription": "An string expression with the activity id to update.", + "examples": [ + "=dialog.lastActivityId" + ] + }, + "activity": { + "$kind": "Microsoft.IActivityTemplate", + "title": "Activity", + "description": "Activity to send.", + "$ref": "#/definitions/Microsoft.IActivityTemplate" + } + }, + "additionalProperties": false, + "patternProperties": { + "^\\$": { + "type": "string" + } + }, + "anyOf": [ + { + "title": "Reference", + "required": [ + "$copy" + ] + }, + { + "title": "Type", + "required": [ + "$kind" + ] + } + ] + }, "Microsoft.UrlEntityRecognizer": { "$role": "union(Microsoft.EntityRecognizers)", "title": "Url Entity Recognizer", @@ -8092,4 +12034,4 @@ ] } } -} +} \ No newline at end of file diff --git a/BotProject/Templates/CSharp/Scripts/build_runtime.ps1 b/BotProject/Templates/CSharp/Scripts/build_runtime.ps1 index 0579956909..902d302c47 100644 --- a/BotProject/Templates/CSharp/Scripts/build_runtime.ps1 +++ b/BotProject/Templates/CSharp/Scripts/build_runtime.ps1 @@ -1,9 +1,17 @@ -if ((dotnet --version) -lt 3) { - throw "! dotnet core 3.0 is required, please refer following documents for help. https://dotnet.microsoft.com/download/dotnet-core/3.0" +if ((dotnet --version) -lt '3.1.0') { + throw "! dotnet core 3.1 is required, please refer following documents for help. https://dotnet.microsoft.com/download/dotnet-core/3.1" Break } # This command need dotnet core more than 3.0 dotnet user-secrets init -dotnet build +# Merge all streams into stdout +$result = dotnet build *>&1 +# Evaluate success/failure +if($LASTEXITCODE -ne 0) +{ + # Failed, you can reconstruct stderr strings with: + $ErrorString = $result -join [System.Environment]::NewLine + throw $ErrorString +} diff --git a/BotProject/Templates/CSharp/Scripts/build_runtime.sh b/BotProject/Templates/CSharp/Scripts/build_runtime.sh index 3a87dea815..51e0b0ae12 100644 --- a/BotProject/Templates/CSharp/Scripts/build_runtime.sh +++ b/BotProject/Templates/CSharp/Scripts/build_runtime.sh @@ -1,9 +1,9 @@ versionString=`dotnet --version` -versionNum=`echo $versionString | cut -d . -f 1` -if [[ $versionNum -lt 3 ]] +function version_lt() { test "$(echo "$@" | tr " " "\n" | sort -rV | head -n 1)" != "$1"; } +if version_lt $versionString "3.1.0"; then - echo "! dotnet core 3.0 is required, please refer following documents for help. -https://dotnet.microsoft.com/download/dotnet-core/3.0" + echo "! dotnet core 3.1 is required, please refer following documents for help. +https://dotnet.microsoft.com/download/dotnet-core/3.1" exit 1 else dotnet user-secrets init diff --git a/BotProject/Templates/CSharp/Startup.cs b/BotProject/Templates/CSharp/Startup.cs index 5b0d85f24f..f6b769dd96 100644 --- a/BotProject/Templates/CSharp/Startup.cs +++ b/BotProject/Templates/CSharp/Startup.cs @@ -37,7 +37,7 @@ public Startup(IHostingEnvironment env, IConfiguration configuration) // This method gets called by the runtime. Use this method to add services to the container. public void ConfigureServices(IServiceCollection services) { - services.AddMvc().SetCompatibilityVersion(CompatibilityVersion.Version_2_1); + services.AddMvc(options => options.EnableEndpointRouting = false).SetCompatibilityVersion(CompatibilityVersion.Version_2_1); services.AddSingleton(this.Configuration); diff --git a/BotProject/Templates/CSharp/Tests/Tests.csproj b/BotProject/Templates/CSharp/Tests/Tests.csproj index 968618d2d8..28a2c36621 100644 --- a/BotProject/Templates/CSharp/Tests/Tests.csproj +++ b/BotProject/Templates/CSharp/Tests/Tests.csproj @@ -1,7 +1,7 @@  - netcoreapp2.1 + netcoreapp3.1 false diff --git a/Composer/Dockerfile b/Composer/Dockerfile index b8c9fdfda3..8b891fd187 100644 --- a/Composer/Dockerfile +++ b/Composer/Dockerfile @@ -64,26 +64,17 @@ ENV \ # Add dependencies for disabling invariant mode (set in base image) RUN apk add --no-cache icu-libs -# Install .NET Core 2.1 -ENV DOTNET_SDK_VERSION 2.1.607 +# Install .NET Core SDK 3.1 +ENV DOTNET_SDK_VERSION 3.1.101 RUN wget -O dotnet.tar.gz https://dotnetcli.azureedge.net/dotnet/Sdk/$DOTNET_SDK_VERSION/dotnet-sdk-$DOTNET_SDK_VERSION-linux-musl-x64.tar.gz \ - && dotnet_sha512='61caf6602b8a2aa89769b3e91ddaec963d8ab9f802cd7f6c6da4f02426358712bc2bb0930e7ee3a81d75c7607039543b554cb8ed50e45610655f9e91ed0f2f17' \ + && dotnet_sha512='ce386da8bc07033957fd404909fc230e8ab9e29929675478b90f400a1838223379595a4459056c6c2251ab5c722f80858b9ca536db1a2f6d1670a97094d0fe55' \ && echo "$dotnet_sha512 dotnet.tar.gz" | sha512sum -c - \ && mkdir -p /usr/share/dotnet \ - && tar -C /usr/share/dotnet -xzf dotnet.tar.gz \ + && tar -C /usr/share/dotnet -oxzf dotnet.tar.gz \ && ln -s /usr/share/dotnet/dotnet /usr/bin/dotnet \ && rm dotnet.tar.gz -# Install .NET Core SDK 3.0 -ENV DOTNET_SDK_VERSION 3.0.101 - -RUN wget -O dotnet.tar.gz https://dotnetcli.azureedge.net/dotnet/Sdk/$DOTNET_SDK_VERSION/dotnet-sdk-$DOTNET_SDK_VERSION-linux-musl-x64.tar.gz \ - && dotnet_sha512='98cc98f58187d208bd388f8c71862ea75e50ca25666e265f40a4e7c28082c2784738172e8ae4af7815057f7c57072cbe4fc03301d01738fc1ed5bb5e4d30a363' \ - && echo "$dotnet_sha512 dotnet.tar.gz" | sha512sum -c - \ - && tar -C /usr/share/dotnet -xzf dotnet.tar.gz \ - && rm dotnet.tar.gz - # Enable detection of running in a container ENV DOTNET_RUNNING_IN_CONTAINER=true \ # Set the invariant mode since icu_libs isn't included (see https://github.com/dotnet/announcements/issues/20) diff --git a/Composer/packages/extensions/obiformeditor/src/Form/fields/PromptField/PromptSettings.tsx b/Composer/packages/extensions/obiformeditor/src/Form/fields/PromptField/PromptSettings.tsx index 0afeeb1f95..0afa495733 100644 --- a/Composer/packages/extensions/obiformeditor/src/Form/fields/PromptField/PromptSettings.tsx +++ b/Composer/packages/extensions/obiformeditor/src/Form/fields/PromptField/PromptSettings.tsx @@ -7,7 +7,7 @@ import formatMessage from 'format-message'; import { FieldProps } from '@bfcomposer/react-jsonschema-form'; import { MicrosoftInputDialog } from '@bfc/shared'; -import { TextWidget, CheckboxWidget } from '../../widgets'; +import { TextWidget } from '../../widgets'; import { TwoSettingFields } from './twoSettingFields'; import { field, settingsFields, settingsFieldFull, settingsFieldInline } from './styles'; @@ -47,7 +47,7 @@ export const PromptSettings: React.FC = props => { />
- (value: string) => { - // if the number is a float, we need to convert to a fixed decimal place - // in order to avoid floating point math rounding errors (ex. 1.2000000001) - // ex. if step = 0.01, we fix to 2 decimals - const newValue = type === 'integer' ? getInt(value, step) : getFloat(value, step); - - onChange(newValue); - // need to allow form data to propagate before flushing to state - setTimeout(() => onBlur && onBlur(id, value)); - }; - - const step = type === 'integer' ? 1 : 0.1; - - return ( - <> - {!hideLabel && } - - - ); - } - const sharedProps = { disabled, id, @@ -115,6 +83,38 @@ export function TextWidget(props: ITextWidgetProps) { ); } + if (type === 'integer' || type === 'number') { + const updateValue = (step: number) => (value: string) => { + // if the number is a float, we need to convert to a fixed decimal place + // in order to avoid floating point math rounding errors (ex. 1.2000000001) + // ex. if step = 0.01, we fix to 2 decimals + const newValue = type === 'integer' ? getInt(value, step) : getFloat(value, step); + + onChange(newValue); + // need to allow form data to propagate before flushing to state + setTimeout(() => onBlur && onBlur(id, value)); + }; + + const step = type === 'integer' ? 1 : 0.1; + + return ( + <> + {!hideLabel && } + + + ); + } + return ( <> {!hideLabel && } diff --git a/Composer/packages/lib/indexers/src/dialogUtils/dialogChecker.ts b/Composer/packages/lib/indexers/src/dialogUtils/dialogChecker.ts index a0d67ec67a..bc4c2983e2 100644 --- a/Composer/packages/lib/indexers/src/dialogUtils/dialogChecker.ts +++ b/Composer/packages/lib/indexers/src/dialogUtils/dialogChecker.ts @@ -2,15 +2,13 @@ // Licensed under the MIT License. import get from 'lodash/get'; -import { ExpressionEngine } from 'botframework-expressions'; -import formatMessage from 'format-message'; -import { SDKTypes, FieldNames } from '@bfc/shared'; +import { FieldNames } from '@bfc/shared'; import { Diagnostic } from '../diagnostic'; +import { ExpressionType } from './validation'; import { CheckerFunc } from './types'; - -const ExpressionParser = new ExpressionEngine(); +import { validate } from './validation'; const createPath = (path: string, type: string): string => { const steps = [FieldNames.Events, FieldNames.Actions, FieldNames.ElseActions]; @@ -24,27 +22,7 @@ const createPath = (path: string, type: string): string => { return `${list[0]}${focused}#${type}#${list[1]}`; }; -export const checkExpression = (exp: string, required: boolean, path: string, type: string): Diagnostic | null => { - let message = ''; - if (!exp && required) { - message = formatMessage(`is missing or empty`); - } else { - try { - ExpressionParser.parse(exp); - } catch (error) { - message = `${formatMessage('must be an expression:')} ${error})`; - } - } - if (message) { - const diagnostic = new Diagnostic(message, ''); - diagnostic.path = createPath(path, type); - return diagnostic; - } - - return null; -}; - -function findAllRequiredType(schema: any): { [key: string]: boolean } { +function findAllRequiredProperties(schema: any): { [key: string]: boolean } { if (!schema) return {}; const types = schema.anyOf?.filter(x => x.title === 'Type'); const required = {}; @@ -62,17 +40,38 @@ function findAllRequiredType(schema: any): { [key: string]: boolean } { return required; } +function findAllTypes(schema: any): string[] { + if (!schema) return []; + let types: string[] = []; + if (schema.type) { + if (Array.isArray(schema.type)) { + types = [...types, ...schema.type]; + } else { + types.push(schema.type); + } + } else { + types = schema.oneOf?.filter(item => !!ExpressionType[item.type]).map(item => item.type); + } + + return types; +} + export const IsExpression: CheckerFunc = (path, value, type, schema) => { if (!schema) return []; const diagnostics: Diagnostic[] = []; - const requiredTypes = findAllRequiredType(schema); + const requiredProperties = findAllRequiredProperties(schema); Object.keys(value).forEach(key => { const property = value[key]; if (Array.isArray(property)) { const itemsSchema = get(schema, ['properties', key, 'items'], null); if (itemsSchema?.$role === 'expression') { property.forEach((child, index) => { - const diagnostic = checkExpression(child, !!requiredTypes[key], `${path}.${key}[${index}]`, type); + const diagnostic = validate( + child, + !!requiredProperties[key], + createPath(`${path}.${key}[${index}]`, type), + findAllTypes(itemsSchema) + ); if (diagnostic) diagnostics.push(diagnostic); }); } else if (itemsSchema?.type === 'object') { @@ -82,24 +81,18 @@ export const IsExpression: CheckerFunc = (path, value, type, schema) => { }); } } else if (get(schema.properties[key], '$role') === 'expression') { - const diagnostic = checkExpression(property, !!requiredTypes[key], `${path}.${key}`, type); + const diagnostic = validate( + property, + !!requiredProperties[key], + createPath(`${path}.${key}`, type), + findAllTypes(schema.properties[key]) + ); if (diagnostic) diagnostics.push(diagnostic); } }); return diagnostics; }; -//the type of 'Microsoft.ChoiceInput' has anyof schema in choices -export const checkChoices: CheckerFunc = (path, value, type, schema) => { - const choices = value.choices; - if (typeof choices === 'string') { - const diagnostic = checkExpression(choices, false, `${path}.choices`, type); - if (diagnostic) return [diagnostic]; - } - return null; -}; - export const checkerFuncs: { [type: string]: CheckerFunc[] } = { '.': [IsExpression], //this will check all types - [SDKTypes.ChoiceInput]: [checkChoices], }; diff --git a/Composer/packages/lib/indexers/src/dialogUtils/validation.ts b/Composer/packages/lib/indexers/src/dialogUtils/validation.ts new file mode 100644 index 0000000000..040f04c34a --- /dev/null +++ b/Composer/packages/lib/indexers/src/dialogUtils/validation.ts @@ -0,0 +1,77 @@ +// Copyright (c) Microsoft Corporation. +// Licensed under the MIT License. +import { ExpressionEngine, ReturnType } from 'botframework-expressions'; +import formatMessage from 'format-message'; + +import { Diagnostic } from '../diagnostic'; + +export const ExpressionType = { + number: 'number', + integer: 'integer', + boolean: 'boolean', + string: 'string', +}; + +const ExpressionParser = new ExpressionEngine(); + +const isExpression = (value: string | boolean | number, types: string[]): boolean => { + //StringExpression always assumes string interpolation unless prefixed with =, producing a string + return (typeof value === 'string' && value[0] === '=') || types.length !== 1 || types[0] !== ExpressionType.string; +}; + +//The return type should match the schema type +const checkReturnType = (returnType: ReturnType, types: string[]): string => { + return returnType === ReturnType.Object || + ~types.indexOf(returnType) || + (returnType === ReturnType.Number && ~types.indexOf(ExpressionType.integer)) + ? '' + : formatMessage('the expression type is not match'); +}; + +export const checkExpression = (exp: string | boolean | number, required: boolean, types: string[]): string => { + let message = ''; + if (!exp && required) { + message = formatMessage(`is missing or empty`); + } else { + try { + let returnType: ReturnType; + if (typeof exp === 'boolean') { + returnType = ReturnType.Boolean; + } else if (typeof exp === 'number') { + returnType = ReturnType.Number; + } else { + returnType = ExpressionParser.parse(exp).returnType; + } + message = checkReturnType(returnType, types); + } catch (error) { + message = `${formatMessage('must be an expression:')} ${error})`; + } + } + + return message; +}; + +export const validate = ( + value: string | boolean | number, + required: boolean, + path: string, + types: string[] +): Diagnostic | null => { + //if there is no type do nothing + //if the json type length more than 2, the type assumes string interpolation + if (!types.length || types.length > 2 || !isExpression(value, types)) { + return null; + } + + //remove '=' + if (typeof value === 'string' && value[0] === '=') { + value = value.substring(1); + } + + const message = checkExpression(value, required, types); + if (!message) return null; + + const diagnostic = new Diagnostic(message, ''); + diagnostic.path = path; + return diagnostic; +}; diff --git a/Composer/packages/lib/shared/__tests__/dialogFactory.test.ts b/Composer/packages/lib/shared/__tests__/dialogFactory.test.ts index 843190e6ad..2b3ba98273 100644 --- a/Composer/packages/lib/shared/__tests__/dialogFactory.test.ts +++ b/Composer/packages/lib/shared/__tests__/dialogFactory.test.ts @@ -7,8 +7,8 @@ describe('DialogFactory', () => { describe('#seedDefaults', () => { it('can assign defaults to non-object types', () => { const seed: any = seedDefaults('Microsoft.TextInput'); - expect(seed.maxTurnCount).toBe(3); - expect(seed.alwaysPrompt).toBe(false); + expect(seed.maxTurnCount).toBe('3'); + expect(seed.alwaysPrompt).toBe(undefined); }); it('can assign defaults to object types', () => { diff --git a/Composer/packages/lib/shared/src/appschema.ts b/Composer/packages/lib/shared/src/appschema.ts index 974981de95..5d213744c1 100644 --- a/Composer/packages/lib/shared/src/appschema.ts +++ b/Composer/packages/lib/shared/src/appschema.ts @@ -173,11 +173,12 @@ export const appschema: OBISchema = { $ref: '#/definitions/Microsoft.IActivityTemplate', }, maxTurnCount: { - type: 'integer', + $role: 'expression', + type: 'string', title: 'Max turn count', description: 'Maximum number of re-prompt attempts to collect information.', - default: 3, - examples: [3], + default: '3', + examples: ['3'], }, validations: { type: 'array', @@ -213,11 +214,11 @@ export const appschema: OBISchema = { examples: ['@userName'], }, alwaysPrompt: { - type: 'boolean', + $role: 'expression', + type: 'string', title: 'Always prompt', description: "Collect information even if the specified 'property' is not empty.", - default: false, - examples: [false], + examples: ['false'], }, allowInterruptions: { $role: 'expression', @@ -339,11 +340,12 @@ export const appschema: OBISchema = { $ref: '#/definitions/Microsoft.IActivityTemplate', }, maxTurnCount: { - type: 'integer', + $role: 'expression', + type: 'string', title: 'Max turn count', description: 'Maximum number of re-prompt attempts to collect information.', - default: 3, - examples: [3], + default: '3', + examples: ['3'], }, validations: { type: 'array', @@ -379,11 +381,11 @@ export const appschema: OBISchema = { examples: ['@userName'], }, alwaysPrompt: { - type: 'boolean', + $role: 'expression', + type: 'string', title: 'Always prompt', description: "Collect information even if the specified 'property' is not empty.", - default: false, - examples: [false], + examples: ['false'], }, allowInterruptions: { $role: 'expression', @@ -572,11 +574,12 @@ export const appschema: OBISchema = { $ref: '#/definitions/Microsoft.IActivityTemplate', }, maxTurnCount: { - type: 'integer', + $role: 'expression', + type: 'string', title: 'Max turn count', description: 'Maximum number of re-prompt attempts to collect information.', - default: 3, - examples: [3], + default: '3', + examples: ['3'], }, validations: { type: 'array', @@ -612,11 +615,11 @@ export const appschema: OBISchema = { examples: ['@userName'], }, alwaysPrompt: { - type: 'boolean', + $role: 'expression', + type: 'string', title: 'Always prompt', description: "Collect information even if the specified 'property' is not empty.", - default: false, - examples: [false], + examples: ['false'], }, allowInterruptions: { $role: 'expression', @@ -774,11 +777,12 @@ export const appschema: OBISchema = { $ref: '#/definitions/Microsoft.IActivityTemplate', }, maxTurnCount: { - type: 'integer', + $role: 'expression', + type: 'string', title: 'Max turn count', description: 'Maximum number of re-prompt attempts to collect information.', - default: 3, - examples: [3], + default: '3', + examples: ['3'], }, validations: { type: 'array', @@ -814,11 +818,11 @@ export const appschema: OBISchema = { examples: ['@userName'], }, alwaysPrompt: { - type: 'boolean', + $role: 'expression', + type: 'string', title: 'Always prompt', description: "Collect information even if the specified 'property' is not empty.", - default: false, - examples: [false], + examples: ['false'], }, allowInterruptions: { $role: 'expression', @@ -1873,11 +1877,12 @@ export const appschema: OBISchema = { $ref: '#/definitions/Microsoft.IActivityTemplate', }, maxTurnCount: { - type: 'integer', + $role: 'expression', + type: 'string', title: 'Max turn count', description: 'Maximum number of re-prompt attempts to collect information.', - default: 3, - examples: [3], + default: '3', + examples: ['3'], }, validations: { type: 'array', @@ -1913,11 +1918,11 @@ export const appschema: OBISchema = { examples: ['@userName'], }, alwaysPrompt: { - type: 'boolean', + $role: 'expression', + type: 'string', title: 'Always prompt', description: "Collect information even if the specified 'property' is not empty.", - default: false, - examples: [false], + examples: ['false'], }, allowInterruptions: { $role: 'expression', @@ -2580,28 +2585,27 @@ export const appschema: OBISchema = { $ref: '#/definitions/Microsoft.IActivityTemplate', }, threshold: { - type: 'number', + $role: 'expression', + type: 'string', title: 'Threshold', description: 'Threshold score to filter results.', - default: 0.3, + default: '0.3', }, activeLearningCardTitle: { + $role: 'expression', type: 'string', title: 'Active learning card title', description: 'Title for active learning suggestions card.', - default: 'Did you mean:', }, cardNoMatchText: { + $role: 'expression', type: 'string', title: 'Card no match text', - description: 'Text for no match option.', - default: 'None of the above.', }, cardNoMatchResponse: { $type: 'Microsoft.IActivityTemplate', title: 'Card no match response', description: 'Custom response when no match option was selected.', - default: 'Thanks for the feedback.', $ref: '#/definitions/Microsoft.IActivityTemplate', }, strictFilters: { @@ -2625,10 +2629,11 @@ export const appschema: OBISchema = { }, }, top: { - type: 'number', + role: 'expression', + type: 'string', title: 'Top', description: 'The number of answers you want to retrieve.', - default: 3, + default: '3', }, }, }, @@ -2942,11 +2947,12 @@ export const appschema: OBISchema = { $ref: '#/definitions/Microsoft.IActivityTemplate', }, maxTurnCount: { - type: 'integer', + $role: 'expression', + type: 'string', title: 'Max turn count', description: 'Maximum number of re-prompt attempts to collect information.', - default: 3, - examples: [3], + default: '3', + examples: ['3'], }, validations: { type: 'array', @@ -2982,11 +2988,11 @@ export const appschema: OBISchema = { examples: ['@userName'], }, alwaysPrompt: { - type: 'boolean', + $role: 'expression', + type: 'string', title: 'Always prompt', description: "Collect information even if the specified 'property' is not empty.", - default: false, - examples: [false], + examples: ['false'], }, allowInterruptions: { $role: 'expression', diff --git a/Composer/packages/server/schemas/sdk.schema b/Composer/packages/server/schemas/sdk.schema index 0e6b7f0c65..1fafc1696f 100644 --- a/Composer/packages/server/schemas/sdk.schema +++ b/Composer/packages/server/schemas/sdk.schema @@ -10,6 +10,11 @@ "description": "", "$ref": "#/definitions/Microsoft.ActivityTemplate" }, + { + "title": "Microsoft.AdaptiveCardRecognizer", + "description": "Recognizer for detecting the value response from an Adaptive Card.", + "$ref": "#/definitions/Microsoft.AdaptiveCardRecognizer" + }, { "title": "Microsoft.AdaptiveDialog", "description": "Flexible, data driven dialog that can adapt to the conversation.", @@ -20,6 +25,11 @@ "description": "Recognizer which recognizes age.", "$ref": "#/definitions/Microsoft.AgeEntityRecognizer" }, + { + "title": "Microsoft.Ask", + "description": "This is an action which sends an activity to the user when a response is expected", + "$ref": "#/definitions/Microsoft.Ask" + }, { "title": "Microsoft.AttachmentInput", "description": "Collect information - Ask for a file or image.", @@ -30,6 +40,11 @@ "description": "Begin another dialog.", "$ref": "#/definitions/Microsoft.BeginDialog" }, + { + "title": "Microsoft.BreakLoop", + "description": "Stop executing this loop", + "$ref": "#/definitions/Microsoft.BreakLoop" + }, { "title": "Microsoft.CancelAllDialogs", "description": "Cancel all active dialogs. All dialogs in the dialog chain will need a trigger to capture the event configured in this action.", @@ -55,6 +70,16 @@ "description": "Recognizer which recognizes confirmation choices (yes/no).", "$ref": "#/definitions/Microsoft.ConfirmationEntityRecognizer" }, + { + "title": "Microsoft.ContinueLoop", + "description": "Stop executing this template and continue with the next iteration of the loop.", + "$ref": "#/definitions/Microsoft.ContinueLoop" + }, + { + "title": "Microsoft.CrossTrainedRecognizerSet", + "description": "Recognizer for selecting between cross trained recognizers.", + "$ref": "#/definitions/Microsoft.CrossTrainedRecognizerSet" + }, { "title": "Microsoft.CurrencyEntityRecognizer", "description": "Recognizer which recognizes currency.", @@ -75,6 +100,11 @@ "description": "If debugger is attached, stop the execution at this point in the conversation.", "$ref": "#/definitions/Microsoft.DebugBreak" }, + { + "title": "Microsoft.DeleteActivity", + "description": "Delete an activity that was previously sent.", + "$ref": "#/definitions/Microsoft.DeleteActivity" + }, { "title": "Microsoft.DeleteProperties", "description": "Delete multiple properties and any value it holds.", @@ -135,6 +165,21 @@ "description": "Execute actions on each page (collection of items) in an array.", "$ref": "#/definitions/Microsoft.ForeachPage" }, + { + "title": "Microsoft.GetActivityMembers", + "description": "Get the members who are participating in an activity. (BotFrameworkAdapter only)", + "$ref": "#/definitions/Microsoft.GetActivityMembers" + }, + { + "title": "Microsoft.GetConversationMembers", + "description": "Get the members who are participating in an conversation. (BotFrameworkAdapter only)", + "$ref": "#/definitions/Microsoft.GetConversationMembers" + }, + { + "title": "Microsoft.GotoAction", + "description": "Go to an an action by id.", + "$ref": "#/definitions/Microsoft.GotoAction" + }, { "title": "Microsoft.GuidEntityRecognizer", "description": "Recognizer which recognizes guids.", @@ -155,11 +200,6 @@ "description": "Two-way branch the conversation flow based on a condition.", "$ref": "#/definitions/Microsoft.IfCondition" }, - { - "title": "Microsoft.InitProperty", - "description": "Define and initialize a property to be an array or object.", - "$ref": "#/definitions/Microsoft.InitProperty" - }, { "title": "Microsoft.IpEntityRecognizer", "description": "Recognizer which recognizes internet IP patterns (like 192.1.1.1).", @@ -220,6 +260,11 @@ "description": "Actions to perform on receipt of a generic activity.", "$ref": "#/definitions/Microsoft.OnActivity" }, + { + "title": "Microsoft.OnAssignEntity", + "description": "Actions to take when an entity should be assigned to a property.", + "$ref": "#/definitions/Microsoft.OnAssignEntity" + }, { "title": "Microsoft.OnBeginDialog", "description": "Actions to perform when this dialog begins.", @@ -230,6 +275,26 @@ "description": "Actions to perform on cancel dialog event.", "$ref": "#/definitions/Microsoft.OnCancelDialog" }, + { + "title": "Microsoft.OnChooseEntity", + "description": "Actions to be performed when an entity value needs to be resolved.", + "$ref": "#/definitions/Microsoft.OnChooseEntity" + }, + { + "title": "Microsoft.OnChooseIntent", + "description": "Actions to perform on when an intent is ambigious.", + "$ref": "#/definitions/Microsoft.OnChooseIntent" + }, + { + "title": "Microsoft.OnChooseProperty", + "description": "Actions to take when there are multiple possible mappings of entities to properties.", + "$ref": "#/definitions/Microsoft.OnChooseProperty" + }, + { + "title": "Microsoft.OnClearProperty", + "description": "Actions to take when a property needs to be cleared.", + "$ref": "#/definitions/Microsoft.OnClearProperty" + }, { "title": "Microsoft.OnCondition", "description": "Actions to perform when specified condition is true.", @@ -250,6 +315,11 @@ "description": "Actions to perform when a specific dialog event occurs.", "$ref": "#/definitions/Microsoft.OnDialogEvent" }, + { + "title": "Microsoft.OnEndOfActions", + "description": "Actions to take when there are no more actions in the current dialog.", + "$ref": "#/definitions/Microsoft.OnEndOfActions" + }, { "title": "Microsoft.OnEndOfConversationActivity", "description": "Actions to perform on receipt of an activity with type 'EndOfConversation'.", @@ -300,6 +370,11 @@ "description": "Actions to perform on receipt of an activity with type 'MessageUpdate'.", "$ref": "#/definitions/Microsoft.OnMessageUpdateActivity" }, + { + "title": "Microsoft.OnQnAMatch", + "description": "Actions to perform on when an match from QnAMaker is found.", + "$ref": "#/definitions/Microsoft.OnQnAMatch" + }, { "title": "Microsoft.OnRepromptDialog", "description": "Actions to perform when 'RepromptDialog' event occurs.", @@ -335,11 +410,21 @@ "description": "Dialog which uses QnAMAker knowledge base to answer questions.", "$ref": "#/definitions/Microsoft.QnAMakerDialog" }, + { + "title": "Microsoft.QnAMakerRecognizer", + "description": "Recognizer for generating QnAMatch intents from a KB.", + "$ref": "#/definitions/Microsoft.QnAMakerRecognizer" + }, { "title": "Microsoft.RandomSelector", "description": "Select most specific true rule", "$ref": "#/definitions/Microsoft.RandomSelector" }, + { + "title": "Microsoft.RecognizerSet", + "description": "Creates the union of the intents and entities of the recognizers in the set.", + "$ref": "#/definitions/Microsoft.RecognizerSet" + }, { "title": "Microsoft.RegExEntityRecognizer", "description": "Recognizer which recognizes patterns of input based on regex.", @@ -375,6 +460,11 @@ "description": "Set property to a value.", "$ref": "#/definitions/Microsoft.SetProperty" }, + { + "title": "Microsoft.SignOutUser", + "description": "Sign a user out that was logged in previously using OAuthInput.", + "$ref": "#/definitions/Microsoft.SignOutUser" + }, { "title": "Microsoft.StaticActivityTemplate", "description": "This allows you to define a static Activity object", @@ -460,6 +550,11 @@ "description": "Selector for all true events", "$ref": "#/definitions/Microsoft.TrueSelector" }, + { + "title": "Microsoft.UpdateActivity", + "description": "Respond with an activity.", + "$ref": "#/definitions/Microsoft.UpdateActivity" + }, { "title": "Microsoft.UrlEntityRecognizer", "description": "Recognizer which recognizes urls (example: http://bing.com)", @@ -524,6 +619,63 @@ } ] }, + "Microsoft.AdaptiveCardRecognizer": { + "$role": "union(Microsoft.Recognizer)", + "title": "Cross-trained Recognizer Set", + "description": "Recognizer for detecting the value response from an Adaptive Card.", + "type": "object", + "properties": { + "$kind": { + "title": "$kind", + "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", + "type": "string", + "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", + "const": "Microsoft.AdaptiveCardRecognizer" + }, + "$copy": { + "title": "$copy", + "description": "Copy the definition by id from a .dialog file.", + "type": "string", + "pattern": "^(([a-zA-Z][a-zA-Z0-9.]*)?(#[a-zA-Z][a-zA-Z0-9.]*)?)$" + }, + "$id": { + "title": "$id", + "description": "Inline id for reuse of an inline definition", + "type": "string", + "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" + }, + "$designer": { + "title": "$designer", + "type": "object", + "description": "Extra information for the Bot Framework Designer." + }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional unique id using with RecognizerSet." + } + }, + "additionalProperties": false, + "patternProperties": { + "^\\$": { + "type": "string" + } + }, + "anyOf": [ + { + "title": "Reference", + "required": [ + "$copy" + ] + }, + { + "title": "Type", + "required": [ + "$kind" + ] + } + ] + }, "Microsoft.AdaptiveDialog": { "$role": "union(Microsoft.IDialog)", "title": "Adaptive Dialog", @@ -572,10 +724,10 @@ "default": "dialog.result" }, "recognizer": { - "$kind": "Microsoft.IRecognizer", + "$kind": "Microsoft.Recognizer", "title": "Recognizer", - "description": "Language Understanding recognizer that interprets user input into intent and entities.", - "$ref": "#/definitions/Microsoft.IRecognizer" + "description": "Input recognizer that interprets user input into intent and entities.", + "$ref": "#/definitions/Microsoft.Recognizer" }, "generator": { "$kind": "Microsoft.ILanguageGenerator", @@ -597,6 +749,20 @@ "$kind": "Microsoft.ITriggerCondition", "$ref": "#/definitions/Microsoft.ITriggerCondition" } + }, + "schema": { + "anyOf": [ + { + "title": "The schema to be filled in.", + "type": "object", + "additionalProperties": true + }, + { + "type": "string", + "title": "Reference to JSON schema", + "description": "Reference to JSON schema .dialog file." + } + ] } }, "additionalProperties": false, @@ -672,6 +838,108 @@ } ] }, + "Microsoft.Ask": { + "$role": "union(Microsoft.IDialog)", + "title": "Send Activity to Ask a question", + "description": "This is an action which sends an activity to the user when a response is expected", + "type": "object", + "properties": { + "$kind": { + "title": "$kind", + "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", + "type": "string", + "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", + "const": "Microsoft.Ask" + }, + "$copy": { + "title": "$copy", + "description": "Copy the definition by id from a .dialog file.", + "type": "string", + "pattern": "^(([a-zA-Z][a-zA-Z0-9.]*)?(#[a-zA-Z][a-zA-Z0-9.]*)?)$" + }, + "$id": { + "title": "$id", + "description": "Inline id for reuse of an inline definition", + "type": "string", + "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" + }, + "$designer": { + "title": "$designer", + "type": "object", + "description": "Extra information for the Bot Framework Designer." + }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "disabled": { + "$role": "expression", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + }, + "activity": { + "$kind": "Microsoft.IActivityTemplate", + "title": "Activity", + "description": "Activity to send.", + "$ref": "#/definitions/Microsoft.IActivityTemplate" + }, + "expectedProperties": { + "$role": "expression", + "title": "Expected Properties", + "description": "Properties expected to be filled by entities from the user", + "oneOf": [ + { + "type": "array", + "items": { + "type": "string", + "title": "string" + }, + "title": "array" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to array." + } + ] + } + }, + "additionalProperties": false, + "patternProperties": { + "^\\$": { + "type": "string" + } + }, + "anyOf": [ + { + "title": "Reference", + "required": [ + "$copy" + ] + }, + { + "title": "Type", + "required": [ + "$kind" + ] + } + ] + }, "Microsoft.AttachmentInput": { "$role": "union(Microsoft.IDialog)", "title": "Attachment input dialog", @@ -707,6 +975,18 @@ "title": "Id", "description": "Optional id for the dialog" }, + "disabled": { + "$role": "expression", + "type": [ + "boolean", + "string" + ], + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ] + }, "prompt": { "$kind": "Microsoft.IActivityTemplate", "title": "Initial prompt", @@ -744,7 +1024,11 @@ "$ref": "#/definitions/Microsoft.IActivityTemplate" }, "maxTurnCount": { - "type": "integer", + "$role": "expression", + "type": [ + "integer", + "string" + ], "title": "Max turn count", "description": "Maximum number of re-prompt attempts to collect information.", "default": 3, @@ -762,12 +1046,12 @@ ], "items": { "$role": "expression", - "type": "string", - "description": "String must contain an expression." + "type": "string" } }, "property": { "$role": "expression", + "type": "string", "title": "Property", "description": "Property to store collected information. Input will be skipped if property has value (unless 'Always prompt' is true).", "examples": [ @@ -775,32 +1059,49 @@ "user.name", "conversation.issueTitle", "dialog.favColor" - ], - "type": "string" + ] }, "defaultValue": { "$role": "expression", + "type": [ + "object", + "array", + "number", + "integer", + "boolean", + "string" + ], "title": "Default value", "description": "Expression to examine on each turn of the conversation as possible value to the property.", "examples": [ "@userName", "coalesce(@number, @partySize)" - ], - "type": "string" + ] }, "value": { "$role": "expression", + "type": [ + "object", + "array", + "number", + "integer", + "boolean", + "string" + ], "title": "Value", "description": "Gets or sets a value expression which can be used to intialize the input prompt.", "examples": [ "@userName" - ], - "type": "string" + ] }, "alwaysPrompt": { - "type": "boolean", + "$role": "expression", + "type": [ + "boolean", + "string" + ], "title": "Always prompt", - "description": "Collect information even if the specified 'property' is not empty.", + "description": "Collect information even if the specified 'property' is not empty.", "default": false, "examples": [ false @@ -808,15 +1109,19 @@ }, "allowInterruptions": { "$role": "expression", + "type": [ + "boolean", + "string" + ], "title": "Allow Interruptions", "description": "A boolean expression that determines whether the parent should be allowed to interrupt the input.", "default": "true", "examples": [ "true" - ], - "type": "string" + ] }, "outputFormat": { + "$role": "expression", "type": "string", "enum": [ "all", @@ -878,40 +1183,174 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "disabled": { + "$role": "expression", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + }, "dialog": { - "$kind": "Microsoft.IDialog", + "$role": "expression", "title": "Dialog name", "description": "Name of the dialog to call.", "examples": [ "AddToDoDialog" ], - "$ref": "#/definitions/Microsoft.IDialog" + "oneOf": [ + { + "$kind": "Microsoft.IDialog", + "type": "object", + "title": "object", + "$ref": "#/definitions/Microsoft.IDialog" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to object." + } + ] }, "options": { - "type": "object", + "$role": "expression", "title": "Options", "description": "One or more options that are passed to the dialog that is called.", - "additionalProperties": { - "type": "string", - "title": "Options" - } - }, - "includeActivity": { - "type": "boolean", - "title": "Include Activity", - "description": "When set to true, dialog that is called can process the current activity.", - "default": false - }, - "resultProperty": { - "$role": "expression", - "title": "Property", + "oneOf": [ + { + "type": "object", + "additionalProperties": { + "type": "string", + "title": "Options" + }, + "title": "object" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to object." + } + ] + }, + "activityProcessed": { + "$role": "expression", + "title": "Activity Processed", + "description": "When set to false, the dialog that is called can process the current activity.", + "oneOf": [ + { + "type": "boolean", + "default": true, + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + }, + "resultProperty": { + "$role": "expression", + "type": "string", + "title": "Property", "description": "Property to store any value returned by the dialog that is called.", "examples": [ "dialog.userName" - ], + ] + } + }, + "additionalProperties": false, + "patternProperties": { + "^\\$": { "type": "string" } }, + "anyOf": [ + { + "title": "Reference", + "required": [ + "$copy" + ] + }, + { + "title": "Type", + "required": [ + "$kind" + ] + } + ] + }, + "Microsoft.BreakLoop": { + "$role": "union(Microsoft.IDialog)", + "title": "Break Loop", + "description": "Stop executing this loop", + "type": "object", + "properties": { + "$kind": { + "title": "$kind", + "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", + "type": "string", + "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", + "const": "Microsoft.BreakLoop" + }, + "$copy": { + "title": "$copy", + "description": "Copy the definition by id from a .dialog file.", + "type": "string", + "pattern": "^(([a-zA-Z][a-zA-Z0-9.]*)?(#[a-zA-Z][a-zA-Z0-9.]*)?)$" + }, + "$id": { + "title": "$id", + "description": "Inline id for reuse of an inline definition", + "type": "string", + "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" + }, + "$designer": { + "title": "$designer", + "type": "object", + "description": "Extra information for the Bot Framework Designer." + }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "disabled": { + "$role": "expression", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + } + }, "additionalProperties": false, "patternProperties": { "^\\$": { @@ -963,13 +1402,46 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "disabled": { + "$role": "expression", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + }, "eventName": { + "$role": "expression", + "type": "string", "title": "Event name", - "description": "Name of the event to emit.", - "type": "string" + "description": "Name of the event to emit." }, "eventValue": { - "type": "object", + "$role": "expression", + "type": [ + "object", + "array", + "number", + "integer", + "boolean", + "string" + ], "title": "Event value", "description": "Value to emit with the event (optional).", "additionalProperties": true @@ -1031,6 +1503,18 @@ "title": "Id", "description": "Optional id for the dialog" }, + "disabled": { + "$role": "expression", + "type": [ + "boolean", + "string" + ], + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ] + }, "prompt": { "$kind": "Microsoft.IActivityTemplate", "title": "Initial prompt", @@ -1068,7 +1552,11 @@ "$ref": "#/definitions/Microsoft.IActivityTemplate" }, "maxTurnCount": { - "type": "integer", + "$role": "expression", + "type": [ + "integer", + "string" + ], "title": "Max turn count", "description": "Maximum number of re-prompt attempts to collect information.", "default": 3, @@ -1086,12 +1574,12 @@ ], "items": { "$role": "expression", - "type": "string", - "description": "String must contain an expression." + "type": "string" } }, "property": { "$role": "expression", + "type": "string", "title": "Property", "description": "Property to store collected information. Input will be skipped if property has value (unless 'Always prompt' is true).", "examples": [ @@ -1099,32 +1587,49 @@ "user.name", "conversation.issueTitle", "dialog.favColor" - ], - "type": "string" + ] }, "defaultValue": { "$role": "expression", + "type": [ + "object", + "array", + "number", + "integer", + "boolean", + "string" + ], "title": "Default value", "description": "Expression to examine on each turn of the conversation as possible value to the property.", "examples": [ "@userName", "coalesce(@number, @partySize)" - ], - "type": "string" + ] }, "value": { "$role": "expression", + "type": [ + "object", + "array", + "number", + "integer", + "boolean", + "string" + ], "title": "Value", "description": "Gets or sets a value expression which can be used to intialize the input prompt.", "examples": [ "@userName" - ], - "type": "string" + ] }, "alwaysPrompt": { - "type": "boolean", + "$role": "expression", + "type": [ + "boolean", + "string" + ], "title": "Always prompt", - "description": "Collect information even if the specified 'property' is not empty.", + "description": "Collect information even if the specified 'property' is not empty.", "default": false, "examples": [ false @@ -1132,15 +1637,19 @@ }, "allowInterruptions": { "$role": "expression", + "type": [ + "boolean", + "string" + ], "title": "Allow Interruptions", "description": "A boolean expression that determines whether the parent should be allowed to interrupt the input.", "default": "true", "examples": [ "true" - ], - "type": "string" + ] }, "outputFormat": { + "$role": "expression", "type": "string", "enum": [ "value", @@ -1151,19 +1660,17 @@ "default": "value" }, "choices": { - "anyOf": [ - { - "$role": "expression", - "type": "string", - "description": "String must contain an expression." - }, + "$role": "expression", + "oneOf": [ { "type": "array", "items": [ { - "type": "string" + "type": "string", + "title": "string" } - ] + ], + "title": "array" }, { "type": "array", @@ -1187,12 +1694,18 @@ "title": "Synonyms", "description": "List of synonyms to recognize in addition to the value (optional).", "items": { - "type": "string" + "type": "string", + "title": "string" } } } } - ] + ], + "title": "array" + }, + { + "type": "string", + "title": "Expression" } ] }, @@ -1322,8 +1835,17 @@ }, "condition": { "$role": "expression", - "type": "string", - "description": "String must contain an expression." + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] }, "ifTrue": { "$kind": "Microsoft.ITriggerSelector", @@ -1393,6 +1915,18 @@ "title": "Id", "description": "Optional id for the dialog" }, + "disabled": { + "$role": "expression", + "type": [ + "boolean", + "string" + ], + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ] + }, "prompt": { "$kind": "Microsoft.IActivityTemplate", "title": "Initial prompt", @@ -1430,7 +1964,11 @@ "$ref": "#/definitions/Microsoft.IActivityTemplate" }, "maxTurnCount": { - "type": "integer", + "$role": "expression", + "type": [ + "integer", + "string" + ], "title": "Max turn count", "description": "Maximum number of re-prompt attempts to collect information.", "default": 3, @@ -1448,12 +1986,12 @@ ], "items": { "$role": "expression", - "type": "string", - "description": "String must contain an expression." + "type": "string" } }, "property": { "$role": "expression", + "type": "string", "title": "Property", "description": "Property to store collected information. Input will be skipped if property has value (unless 'Always prompt' is true).", "examples": [ @@ -1461,32 +1999,49 @@ "user.name", "conversation.issueTitle", "dialog.favColor" - ], - "type": "string" + ] }, "defaultValue": { "$role": "expression", + "type": [ + "object", + "array", + "number", + "integer", + "boolean", + "string" + ], "title": "Default value", "description": "Expression to examine on each turn of the conversation as possible value to the property.", "examples": [ "@userName", "coalesce(@number, @partySize)" - ], - "type": "string" + ] }, "value": { "$role": "expression", + "type": [ + "object", + "array", + "number", + "integer", + "boolean", + "string" + ], "title": "Value", "description": "Gets or sets a value expression which can be used to intialize the input prompt.", "examples": [ "@userName" - ], - "type": "string" + ] }, "alwaysPrompt": { - "type": "boolean", + "$role": "expression", + "type": [ + "boolean", + "string" + ], "title": "Always prompt", - "description": "Collect information even if the specified 'property' is not empty.", + "description": "Collect information even if the specified 'property' is not empty.", "default": false, "examples": [ false @@ -1494,30 +2049,35 @@ }, "allowInterruptions": { "$role": "expression", + "type": [ + "boolean", + "string" + ], "title": "Allow Interruptions", "description": "A boolean expression that determines whether the parent should be allowed to interrupt the input.", "default": "true", "examples": [ "true" - ], - "type": "string" + ] }, "outputFormat": { "$role": "expression", + "type": "string", "title": "Output format", "description": "Expression to format the confirm output.", "examples": [ - "concat('confirmation:', this.value)" - ], - "type": "string" + "=concat('confirmation:', this.value)" + ] }, "defaultLocale": { + "$role": "expression", "type": "string", "title": "Default locale", "description": "Default locale.", "default": "en-us" }, "style": { + "$role": "expression", "type": "string", "enum": [ "None", @@ -1532,78 +2092,102 @@ "default": "Auto" }, "choiceOptions": { - "type": "object", - "properties": { - "inlineSeparator": { - "type": "string", - "title": "Inline separator", - "description": "Character used to separate individual choices when there are more than 2 choices", - "default": ", " - }, - "inlineOr": { - "type": "string", - "title": "Inline or", - "description": "Separator inserted between the choices when their are only 2 choices", - "default": " or " - }, - "inlineOrMore": { - "type": "string", - "title": "Inline or more", - "description": "Separator inserted between the last 2 choices when their are more than 2 choices.", - "default": ", or " - }, - "includeNumbers": { - "type": "boolean", - "title": "Include numbers", - "description": "If true, inline and list style choices will be prefixed with the index of the choice.", - "default": true - } - } - }, - "confirmChoices": { - "type": "array", - "items": [ + "$role": "expression", + "oneOf": [ { "type": "object", "properties": { - "value": { + "inlineSeparator": { "type": "string", - "title": "Value", - "description": "Value to return when this choice is selected." + "title": "Inline separator", + "description": "Character used to separate individual choices when there are more than 2 choices", + "default": ", " }, - "action": { - "type": "object", - "title": "Action", - "description": "Card action for the choice" + "inlineOr": { + "type": "string", + "title": "Inline or", + "description": "Separator inserted between the choices when their are only 2 choices", + "default": " or " }, - "synonyms": { - "type": "array", - "title": "Synonyms", - "description": "List of synonyms to recognize in addition to the value (optional)", - "items": { - "type": "string" - } + "inlineOrMore": { + "type": "string", + "title": "Inline or more", + "description": "Separator inserted between the last 2 choices when their are more than 2 choices.", + "default": ", or " + }, + "includeNumbers": { + "type": "boolean", + "title": "Include numbers", + "description": "If true, inline and list style choices will be prefixed with the index of the choice.", + "default": true } - } + }, + "title": "object" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to object." } ] - } - }, - "additionalProperties": false, - "patternProperties": { - "^\\$": { - "type": "string" - } - }, - "anyOf": [ - { - "title": "Reference", - "required": [ - "$copy" - ] }, - { - "title": "Type", + "confirmChoices": { + "$role": "expression", + "oneOf": [ + { + "type": "array", + "items": [ + { + "type": "object", + "properties": { + "value": { + "type": "string", + "title": "Value", + "description": "Value to return when this choice is selected." + }, + "action": { + "type": "object", + "title": "Action", + "description": "Card action for the choice" + }, + "synonyms": { + "type": "array", + "title": "Synonyms", + "description": "List of synonyms to recognize in addition to the value (optional)", + "items": { + "type": "string", + "title": "string" + } + } + }, + "title": "object" + } + ], + "title": "array" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to array." + } + ] + } + }, + "additionalProperties": false, + "patternProperties": { + "^\\$": { + "type": "string" + } + }, + "anyOf": [ + { + "title": "Reference", + "required": [ + "$copy" + ] + }, + { + "title": "Type", "required": [ "$kind" ] @@ -1662,6 +2246,149 @@ } ] }, + "Microsoft.ContinueLoop": { + "$role": "union(Microsoft.IDialog)", + "title": "Continune Loop", + "description": "Stop executing this template and continue with the next iteration of the loop.", + "type": "object", + "properties": { + "$kind": { + "title": "$kind", + "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", + "type": "string", + "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", + "const": "Microsoft.ContinueLoop" + }, + "$copy": { + "title": "$copy", + "description": "Copy the definition by id from a .dialog file.", + "type": "string", + "pattern": "^(([a-zA-Z][a-zA-Z0-9.]*)?(#[a-zA-Z][a-zA-Z0-9.]*)?)$" + }, + "$id": { + "title": "$id", + "description": "Inline id for reuse of an inline definition", + "type": "string", + "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" + }, + "$designer": { + "title": "$designer", + "type": "object", + "description": "Extra information for the Bot Framework Designer." + }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "disabled": { + "$role": "expression", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + } + }, + "additionalProperties": false, + "patternProperties": { + "^\\$": { + "type": "string" + } + }, + "anyOf": [ + { + "title": "Reference", + "required": [ + "$copy" + ] + }, + { + "title": "Type", + "required": [ + "$kind" + ] + } + ] + }, + "Microsoft.CrossTrainedRecognizerSet": { + "$role": "union(Microsoft.Recognizer)", + "title": "Cross-trained Recognizer Set", + "description": "Recognizer for selecting between cross trained recognizers.", + "type": "object", + "properties": { + "$kind": { + "title": "$kind", + "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", + "type": "string", + "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", + "const": "Microsoft.CrossTrainedRecognizerSet" + }, + "$copy": { + "title": "$copy", + "description": "Copy the definition by id from a .dialog file.", + "type": "string", + "pattern": "^(([a-zA-Z][a-zA-Z0-9.]*)?(#[a-zA-Z][a-zA-Z0-9.]*)?)$" + }, + "$id": { + "title": "$id", + "description": "Inline id for reuse of an inline definition", + "type": "string", + "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" + }, + "$designer": { + "title": "$designer", + "type": "object", + "description": "Extra information for the Bot Framework Designer." + }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional unique id using with RecognizerSet." + }, + "recognizers": { + "type": "array", + "title": "Recognizers", + "description": "List of Recognizers defined for this set.", + "items": { + "$kind": "Microsoft.Recognizer", + "$ref": "#/definitions/Microsoft.Recognizer" + } + } + }, + "additionalProperties": false, + "patternProperties": { + "^\\$": { + "type": "string" + } + }, + "anyOf": [ + { + "title": "Reference", + "required": [ + "$copy" + ] + }, + { + "title": "Type", + "required": [ + "recognizers", + "$kind" + ] + } + ] + }, "Microsoft.CurrencyEntityRecognizer": { "$role": "union(Microsoft.EntityRecognizers)", "title": "Currency Entity Recognizer", @@ -1801,6 +2528,18 @@ "title": "Id", "description": "Optional id for the dialog" }, + "disabled": { + "$role": "expression", + "type": [ + "boolean", + "string" + ], + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ] + }, "prompt": { "$kind": "Microsoft.IActivityTemplate", "title": "Initial prompt", @@ -1838,7 +2577,11 @@ "$ref": "#/definitions/Microsoft.IActivityTemplate" }, "maxTurnCount": { - "type": "integer", + "$role": "expression", + "type": [ + "integer", + "string" + ], "title": "Max turn count", "description": "Maximum number of re-prompt attempts to collect information.", "default": 3, @@ -1856,12 +2599,12 @@ ], "items": { "$role": "expression", - "type": "string", - "description": "String must contain an expression." + "type": "string" } }, "property": { "$role": "expression", + "type": "string", "title": "Property", "description": "Property to store collected information. Input will be skipped if property has value (unless 'Always prompt' is true).", "examples": [ @@ -1869,32 +2612,49 @@ "user.name", "conversation.issueTitle", "dialog.favColor" - ], - "type": "string" + ] }, "defaultValue": { "$role": "expression", + "type": [ + "object", + "array", + "number", + "integer", + "boolean", + "string" + ], "title": "Default value", "description": "Expression to examine on each turn of the conversation as possible value to the property.", "examples": [ "@userName", "coalesce(@number, @partySize)" - ], - "type": "string" + ] }, "value": { "$role": "expression", + "type": [ + "object", + "array", + "number", + "integer", + "boolean", + "string" + ], "title": "Value", "description": "Gets or sets a value expression which can be used to intialize the input prompt.", "examples": [ "@userName" - ], - "type": "string" + ] }, "alwaysPrompt": { - "type": "boolean", + "$role": "expression", + "type": [ + "boolean", + "string" + ], "title": "Always prompt", - "description": "Collect information even if the specified 'property' is not empty.", + "description": "Collect information even if the specified 'property' is not empty.", "default": false, "examples": [ false @@ -1902,24 +2662,28 @@ }, "allowInterruptions": { "$role": "expression", + "type": [ + "boolean", + "string" + ], "title": "Allow Interruptions", "description": "A boolean expression that determines whether the parent should be allowed to interrupt the input.", "default": "true", "examples": [ "true" - ], - "type": "string" + ] }, "outputFormat": { "$role": "expression", + "type": "string", "title": "Output format", "description": "Expression to format the datetime output.", "examples": [ "this.value[0].Value" - ], - "type": "string" + ] }, "defaultLocale": { + "$role": "expression", "type": "string", "title": "Default locale", "description": "Default locale.", @@ -1976,6 +2740,30 @@ "title": "$designer", "type": "object", "description": "Extra information for the Bot Framework Designer." + }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "disabled": { + "$role": "expression", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] } }, "additionalProperties": false, @@ -1999,10 +2787,10 @@ } ] }, - "Microsoft.DeleteProperties": { + "Microsoft.DeleteActivity": { "$role": "union(Microsoft.IDialog)", - "title": "Delete Properties", - "description": "Delete multiple properties and any value it holds.", + "title": "Delete Activity", + "description": "Delete an activity that was previously sent.", "type": "object", "properties": { "$kind": { @@ -2010,7 +2798,7 @@ "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", "type": "string", "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", - "const": "Microsoft.DeleteProperties" + "const": "Microsoft.DeleteActivity" }, "$copy": { "title": "$copy", @@ -2029,16 +2817,127 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, - "properties": { - "type": "array", - "title": "Properties", - "description": "Properties to delete.", - "items": { - "$role": "expression", - "title": "Property", - "description": "Property to delete.", - "type": "string" - } + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "activityId": { + "$role": "expression", + "type": "string", + "title": "ActivityId", + "description": "expression to an activityId to delete", + "examples": [ + "=$lastActivity" + ] + }, + "disabled": { + "$role": "expression", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + } + }, + "additionalProperties": false, + "patternProperties": { + "^\\$": { + "type": "string" + } + }, + "anyOf": [ + { + "title": "Reference", + "required": [ + "$copy" + ] + }, + { + "title": "Type", + "required": [ + "property", + "value", + "$kind" + ] + } + ] + }, + "Microsoft.DeleteProperties": { + "$role": "union(Microsoft.IDialog)", + "title": "Delete Properties", + "description": "Delete multiple properties and any value it holds.", + "type": "object", + "properties": { + "$kind": { + "title": "$kind", + "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", + "type": "string", + "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", + "const": "Microsoft.DeleteProperties" + }, + "$copy": { + "title": "$copy", + "description": "Copy the definition by id from a .dialog file.", + "type": "string", + "pattern": "^(([a-zA-Z][a-zA-Z0-9.]*)?(#[a-zA-Z][a-zA-Z0-9.]*)?)$" + }, + "$id": { + "title": "$id", + "description": "Inline id for reuse of an inline definition", + "type": "string", + "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" + }, + "$designer": { + "title": "$designer", + "type": "object", + "description": "Extra information for the Bot Framework Designer." + }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "disabled": { + "$role": "expression", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + }, + "properties": { + "type": "array", + "title": "Properties", + "description": "Properties to delete.", + "items": { + "$role": "expression", + "type": "string", + "title": "Property", + "description": "Property to delete." + } } }, "additionalProperties": false, @@ -2093,11 +2992,35 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "disabled": { + "$role": "expression", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + }, "property": { "$role": "expression", + "type": "string", "title": "Property", - "description": "Property to delete.", - "type": "string" + "description": "Property to delete." } }, "additionalProperties": false, @@ -2204,16 +3127,41 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "disabled": { + "$role": "expression", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + }, "changeType": { + "$role": "expression", "type": "string", "title": "Type of change", "description": "Type of change to apply to the current actions.", "enum": [ - "InsertActions", - "InsertActionsBeforeTags", - "AppendActions", - "EndSequence", - "ReplaceSequence" + "insertActions", + "insertActionsBeforeTags", + "appendActions", + "endSequence", + "replaceSequence" ] }, "actions": { @@ -2279,40 +3227,72 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, "changeType": { + "$role": "expression", "type": "string", "title": "Type of change", "description": "Type of change to the array in memory.", "enum": [ - "Push", - "Pop", - "Take", - "Remove", - "Clear" + "push", + "pop", + "take", + "remove", + "clear" + ] + }, + "disabled": { + "$role": "expression", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } ] }, "itemsProperty": { "$role": "expression", + "type": "string", "title": "Items property", - "description": "Property that holds the array to update.", - "type": "string" + "description": "Property that holds the array to update." }, "resultProperty": { "$role": "expression", + "type": "string", "title": "Result Property", - "description": "Property to store the result of this action.", - "type": "string" + "description": "Property to store the result of this action." }, "value": { "$role": "expression", + "type": [ + "object", + "array", + "number", + "integer", + "boolean", + "string" + ], "title": "Value", "description": "New value or expression.", "examples": [ "'milk'", "dialog.favColor", "dialog.favColor == 'red'" - ], - "type": "string" + ] } }, "additionalProperties": false, @@ -2420,41 +3400,79 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, - "eventName": { - "title": "Event name", - "description": "Name of the event to emit.", - "anyOf": [ + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "disabled": { + "$role": "expression", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ], + "oneOf": [ { - "enum": [ - "beginDialog", - "resumeDialog", - "repromptDialog", - "cancelDialog", - "endDialog", - "activityReceived", - "recognizedIntent", - "unknownIntent", - "actionsStarted", - "actionsSaved", - "actionsEnded", - "actionsResumed" - ] + "type": "boolean", + "title": "boolean" }, { - "type": "string" + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." } ] }, + "eventName": { + "$role": "expression", + "type": "string", + "title": "Event name", + "description": "Name of the event to emit.", + "enum": [ + "beginDialog", + "resumeDialog", + "repromptDialog", + "cancelDialog", + "endDialog", + "activityReceived", + "recognizedIntent", + "unknownIntent", + "actionsStarted", + "actionsSaved", + "actionsEnded", + "actionsResumed" + ] + }, "eventValue": { "$role": "expression", + "type": [ + "object", + "array", + "number", + "integer", + "boolean", + "string" + ], "title": "Event value", - "description": "Value to emit with the event (optional).", - "type": "string" + "description": "Value to emit with the event (optional)." }, "bubbleEvent": { - "type": "boolean", + "$role": "expression", "title": "Bubble event", - "description": "If true this event is passed on to parent dialogs." + "description": "If true this event is passed on to parent dialogs.", + "oneOf": [ + { + "type": "boolean", + "default": false, + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] } }, "additionalProperties": false, @@ -2509,15 +3527,46 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "disabled": { + "$role": "expression", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + }, "value": { "$role": "expression", + "type": [ + "object", + "array", + "number", + "integer", + "boolean", + "string" + ], "title": "Value", "description": "Result value returned to the parent dialog.", "examples": [ - "dialog.userName", - "'tomato'" - ], - "type": "string" + "=dialog.userName", + "='tomato'" + ] } }, "additionalProperties": false, @@ -2570,6 +3619,30 @@ "title": "$designer", "type": "object", "description": "Extra information for the Bot Framework Designer." + }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "disabled": { + "$role": "expression", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] } }, "additionalProperties": false, @@ -2688,6 +3761,11 @@ "title": "Microsoft.UrlEntityRecognizer", "description": "Recognizer which recognizes urls (example: http://bing.com)", "$ref": "#/definitions/Microsoft.UrlEntityRecognizer" + }, + { + "type": "string", + "title": "Reference to Microsoft.EntityRecognizers", + "description": "Reference to Microsoft.EntityRecognizers .dialog file." } ] }, @@ -2773,14 +3851,38 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "disabled": { + "$role": "expression", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + }, "itemsProperty": { "$role": "expression", + "type": "string", "title": "Items property", "description": "Property that holds the array.", "examples": [ "user.todoList" - ], - "type": "string" + ] }, "actions": { "type": "array", @@ -2845,15 +3947,39 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, - "itemsProperty": { + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "disabled": { "$role": "expression", - "title": "Items property", - "description": "Property that holds the array.", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", "examples": [ - "user.todoList" + "user.age > 3" ], - "type": "string" - }, + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + }, + "itemsProperty": { + "$role": "expression", + "type": "string", + "title": "Items property", + "description": "Property that holds the array.", + "examples": [ + "user.todoList" + ] + }, "actions": { "type": "array", "title": "Actions", @@ -2864,10 +3990,21 @@ } }, "pageSize": { - "type": "integer", + "$role": "expression", "title": "Page size", "description": "Number of items in each page.", - "default": 10 + "oneOf": [ + { + "type": "integer", + "default": 10, + "title": "integer" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to integer." + } + ] } }, "additionalProperties": false, @@ -2893,6 +4030,250 @@ } ] }, + "Microsoft.GetActivityMembers": { + "$role": "union(Microsoft.IDialog)", + "title": "Get Activity Members", + "description": "Get the members who are participating in an activity. (BotFrameworkAdapter only)", + "type": "object", + "properties": { + "$kind": { + "title": "$kind", + "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", + "type": "string", + "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", + "const": "Microsoft.GetActivityMembers" + }, + "$copy": { + "title": "$copy", + "description": "Copy the definition by id from a .dialog file.", + "type": "string", + "pattern": "^(([a-zA-Z][a-zA-Z0-9.]*)?(#[a-zA-Z][a-zA-Z0-9.]*)?)$" + }, + "$id": { + "title": "$id", + "description": "Inline id for reuse of an inline definition", + "type": "string", + "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" + }, + "$designer": { + "title": "$designer", + "type": "object", + "description": "Extra information for the Bot Framework Designer." + }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "activityId": { + "$role": "expression", + "type": "string", + "title": "ActivityId", + "description": "expression to an activityId to get the members. If none is defined then the current activity id will be used.", + "examples": [ + "$lastActivity" + ] + }, + "disabled": { + "$role": "expression", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + } + }, + "additionalProperties": false, + "patternProperties": { + "^\\$": { + "type": "string" + } + }, + "anyOf": [ + { + "title": "Reference", + "required": [ + "$copy" + ] + }, + { + "title": "Type", + "required": [ + "$kind" + ] + } + ] + }, + "Microsoft.GetConversationMembers": { + "$role": "union(Microsoft.IDialog)", + "title": "Get Converation Members", + "description": "Get the members who are participating in an conversation. (BotFrameworkAdapter only)", + "type": "object", + "properties": { + "$kind": { + "title": "$kind", + "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", + "type": "string", + "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", + "const": "Microsoft.GetConversationMembers" + }, + "$copy": { + "title": "$copy", + "description": "Copy the definition by id from a .dialog file.", + "type": "string", + "pattern": "^(([a-zA-Z][a-zA-Z0-9.]*)?(#[a-zA-Z][a-zA-Z0-9.]*)?)$" + }, + "$id": { + "title": "$id", + "description": "Inline id for reuse of an inline definition", + "type": "string", + "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" + }, + "$designer": { + "title": "$designer", + "type": "object", + "description": "Extra information for the Bot Framework Designer." + }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "disabled": { + "$role": "expression", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + } + }, + "additionalProperties": false, + "patternProperties": { + "^\\$": { + "type": "string" + } + }, + "anyOf": [ + { + "title": "Reference", + "required": [ + "$copy" + ] + }, + { + "title": "Type", + "required": [ + "$kind" + ] + } + ] + }, + "Microsoft.GotoAction": { + "$role": "union(Microsoft.IDialog)", + "title": "Go to Action", + "description": "Go to an an action by id.", + "type": "object", + "properties": { + "$kind": { + "title": "$kind", + "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", + "type": "string", + "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", + "const": "Microsoft.GotoAction" + }, + "$copy": { + "title": "$copy", + "description": "Copy the definition by id from a .dialog file.", + "type": "string", + "pattern": "^(([a-zA-Z][a-zA-Z0-9.]*)?(#[a-zA-Z][a-zA-Z0-9.]*)?)$" + }, + "$id": { + "title": "$id", + "description": "Inline id for reuse of an inline definition", + "type": "string", + "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" + }, + "$designer": { + "title": "$designer", + "type": "object", + "description": "Extra information for the Bot Framework Designer." + }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "disabled": { + "$role": "expression", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + }, + "actionId": { + "$role": "expression", + "type": "string", + "title": "Action Id", + "description": "Action Id to execute next" + } + }, + "additionalProperties": false, + "patternProperties": { + "^\\$": { + "type": "string" + } + }, + "anyOf": [ + { + "title": "Reference", + "required": [ + "$copy" + ] + }, + { + "title": "Type", + "required": [ + "actionId", + "$kind" + ] + } + ] + }, "Microsoft.GuidEntityRecognizer": { "$role": "union(Microsoft.EntityRecognizers)", "title": "Guid Entity Recognizer", @@ -3027,6 +4408,30 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "disabled": { + "$role": "expression", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + }, "method": { "type": "string", "title": "HTTP method", @@ -3044,6 +4449,7 @@ ] }, "url": { + "$role": "expression", "type": "string", "title": "Url", "description": "URL to call (supports data binding).", @@ -3052,28 +4458,40 @@ ] }, "body": { - "type": "object", + "$role": "expression", + "type": [ + "object", + "array", + "number", + "integer", + "boolean", + "string" + ], "title": "Body", "description": "Body to include in the HTTP call (supports data binding).", "additionalProperties": true }, "resultProperty": { "$role": "expression", + "type": "string", "title": "Result property", "description": "Property to store the result of this action. The result includes 4 properties from the http response: statusCode, reasonPhrase, content and headers. If the content is json it will be a deserialized object.", "examples": [ "dialog.contosodata" - ], - "type": "string" + ] }, "headers": { "type": "object", - "additionProperties": true, "title": "Headers", - "description": "One or more headers to include in the request (supports data binding)." - }, - "responseType": { - "type": "string", + "description": "One or more headers to include in the request (supports data binding).", + "additionalProperties": { + "$role": "expression", + "type": "string" + } + }, + "responseType": { + "$role": "expression", + "type": "string", "title": "Response type", "description": "Defines the type of HTTP response. Automatically calls the 'Send a response' action if set to 'Activity' or 'Activities'.", "enum": [ @@ -3139,6 +4557,11 @@ "description": "Flexible, data driven dialog that can adapt to the conversation.", "$ref": "#/definitions/Microsoft.AdaptiveDialog" }, + { + "title": "Microsoft.Ask", + "description": "This is an action which sends an activity to the user when a response is expected", + "$ref": "#/definitions/Microsoft.Ask" + }, { "title": "Microsoft.AttachmentInput", "description": "Collect information - Ask for a file or image.", @@ -3149,6 +4572,11 @@ "description": "Begin another dialog.", "$ref": "#/definitions/Microsoft.BeginDialog" }, + { + "title": "Microsoft.BreakLoop", + "description": "Stop executing this loop", + "$ref": "#/definitions/Microsoft.BreakLoop" + }, { "title": "Microsoft.CancelAllDialogs", "description": "Cancel all active dialogs. All dialogs in the dialog chain will need a trigger to capture the event configured in this action.", @@ -3164,6 +4592,11 @@ "description": "Collect information - Ask for confirmation (yes or no).", "$ref": "#/definitions/Microsoft.ConfirmInput" }, + { + "title": "Microsoft.ContinueLoop", + "description": "Stop executing this template and continue with the next iteration of the loop.", + "$ref": "#/definitions/Microsoft.ContinueLoop" + }, { "title": "Microsoft.DateTimeInput", "description": "Collect information - Ask for date and/ or time", @@ -3174,6 +4607,11 @@ "description": "If debugger is attached, stop the execution at this point in the conversation.", "$ref": "#/definitions/Microsoft.DebugBreak" }, + { + "title": "Microsoft.DeleteActivity", + "description": "Delete an activity that was previously sent.", + "$ref": "#/definitions/Microsoft.DeleteActivity" + }, { "title": "Microsoft.DeleteProperties", "description": "Delete multiple properties and any value it holds.", @@ -3219,6 +4657,21 @@ "description": "Execute actions on each page (collection of items) in an array.", "$ref": "#/definitions/Microsoft.ForeachPage" }, + { + "title": "Microsoft.GetActivityMembers", + "description": "Get the members who are participating in an activity. (BotFrameworkAdapter only)", + "$ref": "#/definitions/Microsoft.GetActivityMembers" + }, + { + "title": "Microsoft.GetConversationMembers", + "description": "Get the members who are participating in an conversation. (BotFrameworkAdapter only)", + "$ref": "#/definitions/Microsoft.GetConversationMembers" + }, + { + "title": "Microsoft.GotoAction", + "description": "Go to an an action by id.", + "$ref": "#/definitions/Microsoft.GotoAction" + }, { "title": "Microsoft.HttpRequest", "description": "Make a HTTP request.", @@ -3229,11 +4682,6 @@ "description": "Two-way branch the conversation flow based on a condition.", "$ref": "#/definitions/Microsoft.IfCondition" }, - { - "title": "Microsoft.InitProperty", - "description": "Define and initialize a property to be an array or object.", - "$ref": "#/definitions/Microsoft.InitProperty" - }, { "title": "Microsoft.LogAction", "description": "Log a message to the host application. Send a TraceActivity to Bot Framework Emulator (optional).", @@ -3279,6 +4727,11 @@ "description": "Set property to a value.", "$ref": "#/definitions/Microsoft.SetProperty" }, + { + "title": "Microsoft.SignOutUser", + "description": "Sign a user out that was logged in previously using OAuthInput.", + "$ref": "#/definitions/Microsoft.SignOutUser" + }, { "title": "Microsoft.SwitchCondition", "description": "Execute different actions based on the value of a property.", @@ -3299,6 +4752,11 @@ "description": "Send a trace activity to the transcript logger and/ or Bot Framework Emulator.", "$ref": "#/definitions/Microsoft.TraceActivity" }, + { + "title": "Microsoft.UpdateActivity", + "description": "Respond with an activity.", + "$ref": "#/definitions/Microsoft.UpdateActivity" + }, { "type": "string", "title": "string" @@ -3316,32 +4774,6 @@ } ] }, - "Microsoft.IRecognizer": { - "title": "Microsoft IRecognizer", - "description": "Union of components which implement the IRecognizer interface", - "$role": "union", - "oneOf": [ - { - "title": "Microsoft.LuisRecognizer", - "description": "LUIS recognizer.", - "$ref": "#/definitions/Microsoft.LuisRecognizer" - }, - { - "title": "Microsoft.MultiLanguageRecognizer", - "description": "Configure one recognizer per language and the specify the language fallback policy.", - "$ref": "#/definitions/Microsoft.MultiLanguageRecognizer" - }, - { - "title": "Microsoft.RegexRecognizer", - "description": "Use regular expressions to recognize intents and entities from user input.", - "$ref": "#/definitions/Microsoft.RegexRecognizer" - }, - { - "type": "string", - "title": "string" - } - ] - }, "Microsoft.ITextTemplate": { "title": "Microsoft TextTemplate", "description": "Union of components which implement the TextTemplate", @@ -3368,6 +4800,11 @@ "description": "Actions to perform on receipt of a generic activity.", "$ref": "#/definitions/Microsoft.OnActivity" }, + { + "title": "Microsoft.OnAssignEntity", + "description": "Actions to take when an entity should be assigned to a property.", + "$ref": "#/definitions/Microsoft.OnAssignEntity" + }, { "title": "Microsoft.OnBeginDialog", "description": "Actions to perform when this dialog begins.", @@ -3378,6 +4815,26 @@ "description": "Actions to perform on cancel dialog event.", "$ref": "#/definitions/Microsoft.OnCancelDialog" }, + { + "title": "Microsoft.OnChooseEntity", + "description": "Actions to be performed when an entity value needs to be resolved.", + "$ref": "#/definitions/Microsoft.OnChooseEntity" + }, + { + "title": "Microsoft.OnChooseIntent", + "description": "Actions to perform on when an intent is ambigious.", + "$ref": "#/definitions/Microsoft.OnChooseIntent" + }, + { + "title": "Microsoft.OnChooseProperty", + "description": "Actions to take when there are multiple possible mappings of entities to properties.", + "$ref": "#/definitions/Microsoft.OnChooseProperty" + }, + { + "title": "Microsoft.OnClearProperty", + "description": "Actions to take when a property needs to be cleared.", + "$ref": "#/definitions/Microsoft.OnClearProperty" + }, { "title": "Microsoft.OnCondition", "description": "Actions to perform when specified condition is true.", @@ -3398,6 +4855,11 @@ "description": "Actions to perform when a specific dialog event occurs.", "$ref": "#/definitions/Microsoft.OnDialogEvent" }, + { + "title": "Microsoft.OnEndOfActions", + "description": "Actions to take when there are no more actions in the current dialog.", + "$ref": "#/definitions/Microsoft.OnEndOfActions" + }, { "title": "Microsoft.OnEndOfConversationActivity", "description": "Actions to perform on receipt of an activity with type 'EndOfConversation'.", @@ -3448,6 +4910,11 @@ "description": "Actions to perform on receipt of an activity with type 'MessageUpdate'.", "$ref": "#/definitions/Microsoft.OnMessageUpdateActivity" }, + { + "title": "Microsoft.OnQnAMatch", + "description": "Actions to perform on when an match from QnAMaker is found.", + "$ref": "#/definitions/Microsoft.OnQnAMatch" + }, { "title": "Microsoft.OnRepromptDialog", "description": "Actions to perform when 'RepromptDialog' event occurs.", @@ -3462,6 +4929,11 @@ "title": "Microsoft.OnUnknownIntent", "description": "Action to perform when user input is unrecognized and if none of the 'on intent recognition' triggers match recognized intent.", "$ref": "#/definitions/Microsoft.OnUnknownIntent" + }, + { + "type": "string", + "title": "Reference to Microsoft.ITriggerCondition", + "description": "Reference to Microsoft.ITriggerCondition .dialog file." } ] }, @@ -3494,6 +4966,11 @@ "title": "Microsoft.TrueSelector", "description": "Selector for all true events", "$ref": "#/definitions/Microsoft.TrueSelector" + }, + { + "type": "string", + "title": "Reference to Microsoft.ITriggerSelector", + "description": "Reference to Microsoft.ITriggerSelector .dialog file." } ] }, @@ -3527,6 +5004,11 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, "condition": { "$role": "expression", "title": "Condition", @@ -3534,7 +5016,36 @@ "examples": [ "user.age > 3" ], - "type": "string" + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + }, + "disabled": { + "$role": "expression", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] }, "actions": { "type": "array", @@ -3578,78 +5089,6 @@ } ] }, - "Microsoft.InitProperty": { - "$role": "union(Microsoft.IDialog)", - "title": "Initialize property", - "description": "Define and initialize a property to be an array or object.", - "type": "object", - "properties": { - "$kind": { - "title": "$kind", - "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", - "type": "string", - "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", - "const": "Microsoft.InitProperty" - }, - "$copy": { - "title": "$copy", - "description": "Copy the definition by id from a .dialog file.", - "type": "string", - "pattern": "^(([a-zA-Z][a-zA-Z0-9.]*)?(#[a-zA-Z][a-zA-Z0-9.]*)?)$" - }, - "$id": { - "title": "$id", - "description": "Inline id for reuse of an inline definition", - "type": "string", - "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" - }, - "$designer": { - "title": "$designer", - "type": "object", - "description": "Extra information for the Bot Framework Designer." - }, - "property": { - "$role": "expression", - "title": "Property", - "description": "Property (named location to store information).", - "examples": [ - "user.age" - ], - "type": "string" - }, - "type": { - "type": "string", - "title": "Type", - "description": "Type of value.", - "enum": [ - "object", - "array" - ] - } - }, - "additionalProperties": false, - "patternProperties": { - "^\\$": { - "type": "string" - } - }, - "anyOf": [ - { - "title": "Reference", - "required": [ - "$copy" - ] - }, - { - "title": "Type", - "required": [ - "property", - "type", - "$kind" - ] - } - ] - }, "Microsoft.IpEntityRecognizer": { "$role": "union(Microsoft.EntityRecognizers)", "title": "Ip Entity Recognizer", @@ -3783,16 +5222,58 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "disabled": { + "$role": "expression", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + }, "text": { + "$role": "expression", "type": "string", "title": "Text", "description": "Information to log." }, + "label": { + "$role": "expression", + "type": "string", + "title": "Label", + "description": "Label for the trace activity (used to identify it in a list of trace activities.)" + }, "traceActivity": { - "type": "boolean", + "$role": "expression", "title": "Send Trace Activity", "description": "If true, automatically sends a TraceActivity (view in Bot Framework Emulator).", - "default": false + "oneOf": [ + { + "type": "boolean", + "default": false, + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] } }, "additionalProperties": false, @@ -3818,7 +5299,7 @@ ] }, "Microsoft.LuisRecognizer": { - "$role": "union(Microsoft.IRecognizer)", + "$role": "union(Microsoft.Recognizer)", "title": "LUIS Recognizer", "description": "LUIS recognizer.", "type": "object", @@ -3848,14 +5329,122 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional unique id using with RecognizerSet. Other recognizers should return 'DeferToRecognizer_{Id}' intent when cross training data for this recognizer." + }, "applicationId": { - "type": "string" + "type": "string", + "title": "LUIS Application ID", + "description": "Application ID for your model from the LUIS service.", + "$role": "expression" }, "endpoint": { - "type": "string" + "type": "string", + "title": "LUIS Endpoint", + "description": "Endpoint to use for LUIS service like https://westus.api.cognitive.microsoft.com.", + "$role": "expression" }, "endpointKey": { - "type": "string" + "type": "string", + "title": "LUIS prediction key", + "description": "LUIS prediction key used to call endpoint.", + "$role": "expression" + }, + "externalEntityRecognizer": { + "title": "External Entity Recognizer", + "description": "Entities recognized by this recognizer will be passed to LUIS as external entities.", + "$kind": "Microsoft.Recognizer", + "$ref": "#/definitions/Microsoft.Recognizer" + }, + "dynamicLists": { + "$role": "expression", + "title": "Dynamic lists", + "description": "Runtime defined entity lists.", + "oneOf": [ + { + "type": "array", + "items": { + "title": "Entity list", + "description": "Lists of canonical values and synonyms for an entity.", + "type": "object", + "properties": { + "entity": { + "title": "Entity", + "description": "Entity to extend with a dynamic list.", + "type": "string" + }, + "list": { + "title": "Dynamic list", + "description": "List of canonical forms and synonyms.", + "type": "array", + "items": { + "type": "object", + "properties": { + "canonicalForm": { + "title": "Canonical form", + "description": "Resolution if any synonym matches.", + "type": "string" + }, + "synonyms": { + "title": "Synonyms", + "description": "List of synonyms for a canonical form.", + "type": "array", + "items": { + "type": "string", + "title": "string" + } + } + }, + "title": "object" + } + } + } + }, + "title": "array" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to array." + } + ] + }, + "predictionOptions": { + "type": "object", + "properties": { + "includeAllIntents": { + "type": "boolean", + "title": "Include all intents", + "description": "True for all intents, false for only top intent." + }, + "includeInstanceData": { + "type": "boolean", + "title": "Include $instance", + "description": "True to include $instance metadata in the LUIS response." + }, + "log": { + "type": "boolean", + "title": "Log utterances", + "description": "True to log utterances on LUIS service." + }, + "preferExternalEntities": { + "type": "boolean", + "title": "Prefer External Entities", + "description": "True to prefer external entities to those generated by LUIS models." + }, + "slot": { + "type": "string", + "title": "Slot", + "description": "Slot to use for talking to LUIS service like production or staging." + }, + "version": { + "type": "string", + "title": "Version", + "description": "LUIS application version to use." + } + } } }, "patternProperties": { @@ -3990,7 +5579,7 @@ ] }, "Microsoft.MultiLanguageRecognizer": { - "$role": "union(Microsoft.IRecognizer)", + "$role": "union(Microsoft.Recognizer)", "title": "Multi-language recognizer", "description": "Configure one recognizer per language and the specify the language fallback policy.", "type": "object", @@ -4019,6 +5608,11 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional unique id using with RecognizerSet. Other recognizers should return 'DeferToRecognizer_{Id}' intent when cross training data for this recognizer." + }, "languagePolicy": { "$kind": "Microsoft.LanguagePolicy", "type": "object", @@ -4029,10 +5623,10 @@ "recognizers": { "type": "object", "title": "Recognizers", - "description": "Map of language -> IRecognizer", + "description": "Map of language -> Recognizer", "additionalProperties": { - "$kind": "Microsoft.IRecognizer", - "$ref": "#/definitions/Microsoft.IRecognizer" + "$kind": "Microsoft.Recognizer", + "$ref": "#/definitions/Microsoft.Recognizer" } } }, @@ -4145,6 +5739,18 @@ "title": "Id", "description": "Optional id for the dialog" }, + "disabled": { + "$role": "expression", + "type": [ + "boolean", + "string" + ], + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ] + }, "prompt": { "$kind": "Microsoft.IActivityTemplate", "title": "Initial prompt", @@ -4182,7 +5788,11 @@ "$ref": "#/definitions/Microsoft.IActivityTemplate" }, "maxTurnCount": { - "type": "integer", + "$role": "expression", + "type": [ + "integer", + "string" + ], "title": "Max turn count", "description": "Maximum number of re-prompt attempts to collect information.", "default": 3, @@ -4200,12 +5810,12 @@ ], "items": { "$role": "expression", - "type": "string", - "description": "String must contain an expression." + "type": "string" } }, "property": { "$role": "expression", + "type": "string", "title": "Property", "description": "Property to store collected information. Input will be skipped if property has value (unless 'Always prompt' is true).", "examples": [ @@ -4213,32 +5823,49 @@ "user.name", "conversation.issueTitle", "dialog.favColor" - ], - "type": "string" + ] }, "defaultValue": { "$role": "expression", + "type": [ + "object", + "array", + "number", + "integer", + "boolean", + "string" + ], "title": "Default value", "description": "Expression to examine on each turn of the conversation as possible value to the property.", "examples": [ "@userName", "coalesce(@number, @partySize)" - ], - "type": "string" + ] }, "value": { "$role": "expression", + "type": [ + "object", + "array", + "number", + "integer", + "boolean", + "string" + ], "title": "Value", "description": "Gets or sets a value expression which can be used to intialize the input prompt.", "examples": [ "@userName" - ], - "type": "string" + ] }, "alwaysPrompt": { - "type": "boolean", + "$role": "expression", + "type": [ + "boolean", + "string" + ], "title": "Always prompt", - "description": "Collect information even if the specified 'property' is not empty.", + "description": "Collect information even if the specified 'property' is not empty.", "default": false, "examples": [ false @@ -4246,24 +5873,29 @@ }, "allowInterruptions": { "$role": "expression", + "type": [ + "boolean", + "string" + ], "title": "Allow Interruptions", "description": "A boolean expression that determines whether the parent should be allowed to interrupt the input.", "default": "true", "examples": [ "true" - ], - "type": "string" + ] }, "outputFormat": { "$role": "expression", + "type": "string", "title": "Output format", "description": "Expression to format the number output.", "examples": [ - "int(this.value)" - ], - "type": "string" + "=this.value", + "=int(this.text)" + ] }, "defaultLocale": { + "$role": "expression", "type": "string", "title": "Default locale", "description": "Default locale.", @@ -4373,44 +6005,795 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, - "connectionName": { - "type": "string", - "title": "Connection name", - "description": "The connection name configured in Azure Web App Bot OAuth settings.", + "connectionName": { + "$role": "expression", + "type": "string", + "title": "Connection name", + "description": "The connection name configured in Azure Web App Bot OAuth settings.", + "examples": [ + "msgraphOAuthConnection" + ] + }, + "disabled": { + "$role": "expression", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + }, + "text": { + "$role": "expression", + "type": "string", + "title": "Text", + "description": "Text shown in the OAuth signin card.", + "examples": [ + "Please sign in. " + ] + }, + "title": { + "$role": "expression", + "type": "string", + "title": "Title", + "description": "Title shown in the OAuth signin card.", + "examples": [ + "Login" + ] + }, + "timeout": { + "$role": "expression", + "title": "Timeout", + "description": "Time out setting for the OAuth signin card.", + "oneOf": [ + { + "type": "integer", + "default": "900000", + "title": "integer" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to integer." + } + ] + }, + "property": { + "$role": "expression", + "type": "string", + "title": "Token property", + "description": "Property to store the OAuth token result.", + "examples": [ + "dialog.token" + ] + }, + "invalidPrompt": { + "$kind": "Microsoft.IActivityTemplate", + "title": "Invalid prompt", + "description": "Message to send if user response is invalid.", + "examples": [ + "Sorry, the login info you provided is not valid." + ], + "$ref": "#/definitions/Microsoft.IActivityTemplate" + }, + "defaultValueResponse": { + "$kind": "Microsoft.IActivityTemplate", + "title": "Default value response", + "description": "Message to send when max turn count (if specified) has been exceeded and the default value is selected as the value.", + "examples": [ + "Login failed." + ], + "$ref": "#/definitions/Microsoft.IActivityTemplate" + }, + "maxTurnCount": { + "$role": "expression", + "title": "Max turn count", + "description": "Maximum number of re-prompt attempts to collect information.", + "examples": [ + 3 + ], + "oneOf": [ + { + "type": "integer", + "default": 3, + "title": "integer" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to integer." + } + ] + }, + "defaultValue": { + "$role": "expression", + "type": [ + "object", + "array", + "number", + "integer", + "boolean", + "string" + ], + "title": "Default value", + "description": "Expression to examine on each turn of the conversation as possible value to the property.", + "examples": [ + "@token" + ] + }, + "allowInterruptions": { + "$role": "expression", + "title": "Allow Interruptions", + "description": "A boolean expression that determines whether the parent should be allowed to interrupt the input.", + "examples": [ + "true" + ], + "oneOf": [ + { + "type": "boolean", + "default": "true", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + } + }, + "additionalProperties": false, + "patternProperties": { + "^\\$": { + "type": "string" + } + }, + "anyOf": [ + { + "title": "Reference", + "required": [ + "$copy" + ] + }, + { + "title": "Type", + "required": [ + "connectionName", + "$kind" + ] + } + ] + }, + "Microsoft.OnActivity": { + "$role": "union(Microsoft.ITriggerCondition)", + "title": "On activity", + "description": "Actions to perform on receipt of a generic activity.", + "type": "object", + "properties": { + "$kind": { + "title": "$kind", + "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", + "type": "string", + "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", + "const": "Microsoft.OnActivity" + }, + "$copy": { + "title": "$copy", + "description": "Copy the definition by id from a .dialog file.", + "type": "string", + "pattern": "^(([a-zA-Z][a-zA-Z0-9.]*)?(#[a-zA-Z][a-zA-Z0-9.]*)?)$" + }, + "$id": { + "title": "$id", + "description": "Inline id for reuse of an inline definition", + "type": "string", + "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" + }, + "$designer": { + "title": "$designer", + "type": "object", + "description": "Extra information for the Bot Framework Designer." + }, + "condition": { + "$role": "expression", + "title": "Condition", + "description": "Condition (expression).", + "examples": [ + "user.vip == true" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + }, + "actions": { + "type": "array", + "description": "Sequence of actions to execute.", + "items": { + "$kind": "Microsoft.IDialog", + "$ref": "#/definitions/Microsoft.IDialog" + } + }, + "priority": { + "title": "priority", + "description": "Priority expression of rule with 0 being the most important", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "integer" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to integer." + } + ] + }, + "runOnce": { + "type": "boolean", + "title": "Run Once", + "description": "True if rule should run once per unique conditions" + }, + "type": { + "type": "string", + "title": "Activity type", + "description": "The Activity.Type to match" + } + }, + "additionalProperties": false, + "patternProperties": { + "^\\$": { + "type": "string" + } + }, + "anyOf": [ + { + "title": "Reference", + "required": [ + "$copy" + ] + }, + { + "title": "Type", + "required": [ + "actions", + "type", + "$kind" + ] + } + ] + }, + "Microsoft.OnAssignEntity": { + "$role": "union(Microsoft.ITriggerCondition)", + "title": "On entity assignment", + "description": "Actions to take when an entity should be assigned to a property.", + "type": "object", + "properties": { + "$kind": { + "title": "$kind", + "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", + "type": "string", + "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", + "const": "Microsoft.OnAssignEntity" + }, + "$copy": { + "title": "$copy", + "description": "Copy the definition by id from a .dialog file.", + "type": "string", + "pattern": "^(([a-zA-Z][a-zA-Z0-9.]*)?(#[a-zA-Z][a-zA-Z0-9.]*)?)$" + }, + "$id": { + "title": "$id", + "description": "Inline id for reuse of an inline definition", + "type": "string", + "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" + }, + "$designer": { + "title": "$designer", + "type": "object", + "description": "Extra information for the Bot Framework Designer." + }, + "condition": { + "$role": "expression", + "title": "Condition", + "description": "Condition (expression).", + "examples": [ + "user.vip == true" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + }, + "actions": { + "type": "array", + "description": "Sequence of actions to execute.", + "items": { + "$kind": "Microsoft.IDialog", + "$ref": "#/definitions/Microsoft.IDialog" + } + }, + "priority": { + "title": "priority", + "description": "Priority expression of rule with 0 being the most important", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "integer" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to integer." + } + ] + }, + "runOnce": { + "type": "boolean", + "title": "Run Once", + "description": "True if rule should run once per unique conditions" + }, + "property": { + "type": "string", + "title": "Property", + "description": "Property that will be set after entity is selected." + }, + "entity": { + "type": "string", + "title": "Entity", + "description": "Entity being put into property" + }, + "operation": { + "type": "string", + "title": "Operation to use for assigning entity" + } + }, + "additionalProperties": false, + "patternProperties": { + "^\\$": { + "type": "string" + } + }, + "anyOf": [ + { + "title": "Reference", + "required": [ + "$copy" + ] + }, + { + "title": "Type", + "required": [ + "actions", + "$kind" + ] + } + ] + }, + "Microsoft.OnBeginDialog": { + "$role": "union(Microsoft.ITriggerCondition)", + "title": "On begin dialog", + "description": "Actions to perform when this dialog begins.", + "type": "object", + "properties": { + "$kind": { + "title": "$kind", + "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", + "type": "string", + "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", + "const": "Microsoft.OnBeginDialog" + }, + "$copy": { + "title": "$copy", + "description": "Copy the definition by id from a .dialog file.", + "type": "string", + "pattern": "^(([a-zA-Z][a-zA-Z0-9.]*)?(#[a-zA-Z][a-zA-Z0-9.]*)?)$" + }, + "$id": { + "title": "$id", + "description": "Inline id for reuse of an inline definition", + "type": "string", + "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" + }, + "$designer": { + "title": "$designer", + "type": "object", + "description": "Extra information for the Bot Framework Designer." + }, + "condition": { + "$role": "expression", + "title": "Condition", + "description": "Condition (expression).", + "examples": [ + "user.vip == true" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + }, + "actions": { + "type": "array", + "description": "Sequence of actions to execute.", + "items": { + "$kind": "Microsoft.IDialog", + "$ref": "#/definitions/Microsoft.IDialog" + } + }, + "priority": { + "title": "priority", + "description": "Priority expression of rule with 0 being the most important", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "integer" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to integer." + } + ] + }, + "runOnce": { + "type": "boolean", + "title": "Run Once", + "description": "True if rule should run once per unique conditions" + } + }, + "additionalProperties": false, + "patternProperties": { + "^\\$": { + "type": "string" + } + }, + "anyOf": [ + { + "title": "Reference", + "required": [ + "$copy" + ] + }, + { + "title": "Type", + "required": [ + "actions", + "$kind" + ] + } + ] + }, + "Microsoft.OnCancelDialog": { + "$role": "union(Microsoft.ITriggerCondition)", + "title": "On cancel dialog", + "description": "Actions to perform on cancel dialog event.", + "type": "object", + "properties": { + "$kind": { + "title": "$kind", + "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", + "type": "string", + "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", + "const": "Microsoft.OnCancelDialog" + }, + "$copy": { + "title": "$copy", + "description": "Copy the definition by id from a .dialog file.", + "type": "string", + "pattern": "^(([a-zA-Z][a-zA-Z0-9.]*)?(#[a-zA-Z][a-zA-Z0-9.]*)?)$" + }, + "$id": { + "title": "$id", + "description": "Inline id for reuse of an inline definition", + "type": "string", + "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" + }, + "$designer": { + "title": "$designer", + "type": "object", + "description": "Extra information for the Bot Framework Designer." + }, + "condition": { + "$role": "expression", + "title": "Condition", + "description": "Condition (expression).", + "examples": [ + "user.vip == true" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + }, + "actions": { + "type": "array", + "description": "Sequence of actions to execute.", + "items": { + "$kind": "Microsoft.IDialog", + "$ref": "#/definitions/Microsoft.IDialog" + } + }, + "priority": { + "title": "priority", + "description": "Priority expression of rule with 0 being the most important", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "integer" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to integer." + } + ] + }, + "runOnce": { + "type": "boolean", + "title": "Run Once", + "description": "True if rule should run once per unique conditions" + } + }, + "additionalProperties": false, + "patternProperties": { + "^\\$": { + "type": "string" + } + }, + "anyOf": [ + { + "title": "Reference", + "required": [ + "$copy" + ] + }, + { + "title": "Type", + "required": [ + "actions", + "$kind" + ] + } + ] + }, + "Microsoft.OnChooseEntity": { + "$role": "union(Microsoft.ITriggerCondition)", + "title": "On choose entity", + "description": "Actions to be performed when an entity value needs to be resolved.", + "type": "object", + "properties": { + "$kind": { + "title": "$kind", + "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", + "type": "string", + "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", + "const": "Microsoft.OnChooseEntity" + }, + "$copy": { + "title": "$copy", + "description": "Copy the definition by id from a .dialog file.", + "type": "string", + "pattern": "^(([a-zA-Z][a-zA-Z0-9.]*)?(#[a-zA-Z][a-zA-Z0-9.]*)?)$" + }, + "$id": { + "title": "$id", + "description": "Inline id for reuse of an inline definition", + "type": "string", + "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" + }, + "$designer": { + "title": "$designer", + "type": "object", + "description": "Extra information for the Bot Framework Designer." + }, + "condition": { + "$role": "expression", + "title": "Condition", + "description": "Condition (expression).", + "examples": [ + "user.vip == true" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + }, + "actions": { + "type": "array", + "description": "Sequence of actions to execute.", + "items": { + "$kind": "Microsoft.IDialog", + "$ref": "#/definitions/Microsoft.IDialog" + } + }, + "priority": { + "title": "priority", + "description": "Priority expression of rule with 0 being the most important", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "integer" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to integer." + } + ] + }, + "runOnce": { + "type": "boolean", + "title": "Run Once", + "description": "True if rule should run once per unique conditions" + }, + "property": { + "type": "string", + "title": "Property to be set", + "description": "Property that will be set after entity is selected." + }, + "entity": { + "type": "string", + "title": "Ambiguous entity", + "description": "Ambiguous entity" + } + }, + "additionalProperties": false, + "patternProperties": { + "^\\$": { + "type": "string" + } + }, + "anyOf": [ + { + "title": "Reference", + "required": [ + "$copy" + ] + }, + { + "title": "Type", + "required": [ + "actions", + "$kind" + ] + } + ] + }, + "Microsoft.OnChooseIntent": { + "$role": "union(Microsoft.ITriggerCondition)", + "title": "On ambigious intent", + "description": "Actions to perform on when an intent is ambigious.", + "type": "object", + "properties": { + "$kind": { + "title": "$kind", + "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", + "type": "string", + "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", + "const": "Microsoft.OnChooseIntent" + }, + "$copy": { + "title": "$copy", + "description": "Copy the definition by id from a .dialog file.", + "type": "string", + "pattern": "^(([a-zA-Z][a-zA-Z0-9.]*)?(#[a-zA-Z][a-zA-Z0-9.]*)?)$" + }, + "$id": { + "title": "$id", + "description": "Inline id for reuse of an inline definition", + "type": "string", + "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" + }, + "$designer": { + "title": "$designer", + "type": "object", + "description": "Extra information for the Bot Framework Designer." + }, + "condition": { + "$role": "expression", + "title": "Condition", + "description": "Condition (expression).", "examples": [ - "msgraphOAuthConnection" + "user.vip == true" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } ] }, - "text": { - "type": "string", - "title": "Text", - "description": "Text shown in the OAuth signin card.", - "examples": [ - "Please sign in. " - ] + "actions": { + "type": "array", + "description": "Sequence of actions to execute.", + "items": { + "$kind": "Microsoft.IDialog", + "$ref": "#/definitions/Microsoft.IDialog" + } }, - "title": { - "type": "string", - "title": "Title", - "description": "Title shown in the OAuth signin card.", - "examples": [ - "Login" + "priority": { + "title": "priority", + "description": "Priority expression of rule with 0 being the most important", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "integer" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to integer." + } ] }, - "timeout": { - "type": "integer", - "title": "Timeout", - "description": "Time out setting for the OAuth signin card.", - "default": "900000" + "runOnce": { + "type": "boolean", + "title": "Run Once", + "description": "True if rule should run once per unique conditions" }, - "tokenProperty": { - "$role": "expression", - "title": "Token property", - "description": "Property to store the OAuth token result.", - "examples": [ - "dialog.token" - ], - "type": "string" + "intents": { + "type": "array", + "title": "Intents", + "description": "Intents that must be in the ChooseIntent result for this condition to trigger.", + "items": { + "type": "string" + } } }, "additionalProperties": false, @@ -4429,16 +6812,16 @@ { "title": "Type", "required": [ - "connectionName", + "actions", "$kind" ] } ] }, - "Microsoft.OnActivity": { + "Microsoft.OnChooseProperty": { "$role": "union(Microsoft.ITriggerCondition)", - "title": "On activity", - "description": "Actions to perform on receipt of a generic activity.", + "title": "On choose property", + "description": "Actions to take when there are multiple possible mappings of entities to properties.", "type": "object", "properties": { "$kind": { @@ -4446,7 +6829,7 @@ "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", "type": "string", "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", - "const": "Microsoft.OnActivity" + "const": "Microsoft.OnChooseProperty" }, "$copy": { "title": "$copy", @@ -4472,7 +6855,17 @@ "examples": [ "user.vip == true" ], - "type": "string" + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] }, "actions": { "type": "array", @@ -4482,10 +6875,49 @@ "$ref": "#/definitions/Microsoft.IDialog" } }, - "type": { + "priority": { + "title": "priority", + "description": "Priority expression of rule with 0 being the most important", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "integer" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to integer." + } + ] + }, + "runOnce": { + "type": "boolean", + "title": "Run Once", + "description": "True if rule should run once per unique conditions" + }, + "entity": { "type": "string", - "title": "Activity type", - "description": "The Activity.Type to match" + "title": "Entity being assigned", + "description": "Entity being assigned to property choice" + }, + "properties": { + "type": "array", + "title": "Possible properties", + "description": "Properties to be chosen between", + "items": { + "type": "string", + "title": "Property name" + } + }, + "entities": { + "type": "array", + "title": "Possible properties", + "description": "Entities being assigned", + "items": { + "type": "string", + "title": "Entity name" + } } }, "additionalProperties": false, @@ -4505,16 +6937,15 @@ "title": "Type", "required": [ "actions", - "type", "$kind" ] } ] }, - "Microsoft.OnBeginDialog": { + "Microsoft.OnClearProperty": { "$role": "union(Microsoft.ITriggerCondition)", - "title": "On begin dialog", - "description": "Actions to perform when this dialog begins.", + "title": "On clear property", + "description": "Actions to take when a property needs to be cleared.", "type": "object", "properties": { "$kind": { @@ -4522,7 +6953,7 @@ "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", "type": "string", "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", - "const": "Microsoft.OnBeginDialog" + "const": "Microsoft.OnClearProperty" }, "$copy": { "title": "$copy", @@ -4548,7 +6979,17 @@ "examples": [ "user.vip == true" ], - "type": "string" + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] }, "actions": { "type": "array", @@ -4557,6 +6998,32 @@ "$kind": "Microsoft.IDialog", "$ref": "#/definitions/Microsoft.IDialog" } + }, + "priority": { + "title": "priority", + "description": "Priority expression of rule with 0 being the most important", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "integer" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to integer." + } + ] + }, + "runOnce": { + "type": "boolean", + "title": "Run Once", + "description": "True if rule should run once per unique conditions" + }, + "property": { + "type": "string", + "title": "Property", + "description": "Property that will be cleared" } }, "additionalProperties": false, @@ -4581,10 +7048,10 @@ } ] }, - "Microsoft.OnCancelDialog": { + "Microsoft.OnCondition": { "$role": "union(Microsoft.ITriggerCondition)", - "title": "On cancel dialog", - "description": "Actions to perform on cancel dialog event.", + "title": "On condition", + "description": "Actions to perform when specified condition is true.", "type": "object", "properties": { "$kind": { @@ -4592,7 +7059,7 @@ "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", "type": "string", "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", - "const": "Microsoft.OnCancelDialog" + "const": "Microsoft.OnCondition" }, "$copy": { "title": "$copy", @@ -4618,7 +7085,17 @@ "examples": [ "user.vip == true" ], - "type": "string" + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] }, "actions": { "type": "array", @@ -4627,6 +7104,27 @@ "$kind": "Microsoft.IDialog", "$ref": "#/definitions/Microsoft.IDialog" } + }, + "priority": { + "title": "priority", + "description": "Priority expression of rule with 0 being the most important", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "integer" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to integer." + } + ] + }, + "runOnce": { + "type": "boolean", + "title": "Run Once", + "description": "True if rule should run once per unique conditions" } }, "additionalProperties": false, @@ -4651,10 +7149,10 @@ } ] }, - "Microsoft.OnCondition": { + "Microsoft.OnConversationUpdateActivity": { "$role": "union(Microsoft.ITriggerCondition)", - "title": "On condition", - "description": "Actions to perform when specified condition is true.", + "title": "On ConversationUpdate activity", + "description": "Actions to perform on receipt of an activity with type 'ConversationUpdate'.", "type": "object", "properties": { "$kind": { @@ -4662,7 +7160,7 @@ "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", "type": "string", "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", - "const": "Microsoft.OnCondition" + "const": "Microsoft.OnConversationUpdateActivity" }, "$copy": { "title": "$copy", @@ -4688,7 +7186,17 @@ "examples": [ "user.vip == true" ], - "type": "string" + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] }, "actions": { "type": "array", @@ -4697,6 +7205,27 @@ "$kind": "Microsoft.IDialog", "$ref": "#/definitions/Microsoft.IDialog" } + }, + "priority": { + "title": "priority", + "description": "Priority expression of rule with 0 being the most important", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "integer" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to integer." + } + ] + }, + "runOnce": { + "type": "boolean", + "title": "Run Once", + "description": "True if rule should run once per unique conditions" } }, "additionalProperties": false, @@ -4721,10 +7250,10 @@ } ] }, - "Microsoft.OnConversationUpdateActivity": { + "Microsoft.OnCustomEvent": { "$role": "union(Microsoft.ITriggerCondition)", - "title": "On ConversationUpdate activity", - "description": "Actions to perform on receipt of an activity with type 'ConversationUpdate'.", + "title": "On custom event", + "description": "Actions to perform when a custom event is detected. Use 'Emit a custom event' action to raise a custom event.", "type": "object", "properties": { "$kind": { @@ -4732,7 +7261,7 @@ "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", "type": "string", "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", - "const": "Microsoft.OnConversationUpdateActivity" + "const": "Microsoft.OnCustomEvent" }, "$copy": { "title": "$copy", @@ -4758,7 +7287,17 @@ "examples": [ "user.vip == true" ], - "type": "string" + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] }, "actions": { "type": "array", @@ -4767,6 +7306,32 @@ "$kind": "Microsoft.IDialog", "$ref": "#/definitions/Microsoft.IDialog" } + }, + "priority": { + "title": "priority", + "description": "Priority expression of rule with 0 being the most important", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "integer" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to integer." + } + ] + }, + "runOnce": { + "type": "boolean", + "title": "Run Once", + "description": "True if rule should run once per unique conditions" + }, + "event": { + "type": "string", + "title": "Custom event name", + "description": "Name of the custom event." } }, "additionalProperties": false, @@ -4786,15 +7351,16 @@ "title": "Type", "required": [ "actions", + "event", "$kind" ] } ] }, - "Microsoft.OnCustomEvent": { + "Microsoft.OnDialogEvent": { "$role": "union(Microsoft.ITriggerCondition)", - "title": "On custom event", - "description": "Actions to perform when a custom event is detected. Use 'Emit a custom event' action to raise a custom event.", + "title": "On dialog event", + "description": "Actions to perform when a specific dialog event occurs.", "type": "object", "properties": { "$kind": { @@ -4802,7 +7368,7 @@ "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", "type": "string", "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", - "const": "Microsoft.OnCustomEvent" + "const": "Microsoft.OnDialogEvent" }, "$copy": { "title": "$copy", @@ -4828,7 +7394,17 @@ "examples": [ "user.vip == true" ], - "type": "string" + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] }, "actions": { "type": "array", @@ -4838,10 +7414,31 @@ "$ref": "#/definitions/Microsoft.IDialog" } }, + "priority": { + "title": "priority", + "description": "Priority expression of rule with 0 being the most important", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "integer" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to integer." + } + ] + }, + "runOnce": { + "type": "boolean", + "title": "Run Once", + "description": "True if rule should run once per unique conditions" + }, "event": { "type": "string", - "title": "Custom event name", - "description": "Name of the custom event." + "title": "Dialog event name", + "description": "Name of dialog event." } }, "additionalProperties": false, @@ -4867,10 +7464,10 @@ } ] }, - "Microsoft.OnDialogEvent": { + "Microsoft.OnEndOfActions": { "$role": "union(Microsoft.ITriggerCondition)", - "title": "On dialog event", - "description": "Actions to perform when a specific dialog event occurs.", + "title": "On end of actions", + "description": "Actions to take when there are no more actions in the current dialog.", "type": "object", "properties": { "$kind": { @@ -4878,7 +7475,7 @@ "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", "type": "string", "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", - "const": "Microsoft.OnDialogEvent" + "const": "Microsoft.OnEndOfActions" }, "$copy": { "title": "$copy", @@ -4904,7 +7501,17 @@ "examples": [ "user.vip == true" ], - "type": "string" + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] }, "actions": { "type": "array", @@ -4914,10 +7521,26 @@ "$ref": "#/definitions/Microsoft.IDialog" } }, - "event": { - "type": "string", - "title": "Dialog event name", - "description": "Name of dialog event." + "priority": { + "title": "priority", + "description": "Priority expression of rule with 0 being the most important", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "integer" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to integer." + } + ] + }, + "runOnce": { + "type": "boolean", + "title": "Run Once", + "description": "True if rule should run once per unique conditions" } }, "additionalProperties": false, @@ -4937,7 +7560,6 @@ "title": "Type", "required": [ "actions", - "event", "$kind" ] } @@ -4980,7 +7602,17 @@ "examples": [ "user.vip == true" ], - "type": "string" + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] }, "actions": { "type": "array", @@ -4989,6 +7621,27 @@ "$kind": "Microsoft.IDialog", "$ref": "#/definitions/Microsoft.IDialog" } + }, + "priority": { + "title": "priority", + "description": "Priority expression of rule with 0 being the most important", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "integer" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to integer." + } + ] + }, + "runOnce": { + "type": "boolean", + "title": "Run Once", + "description": "True if rule should run once per unique conditions" } }, "additionalProperties": false, @@ -5050,7 +7703,17 @@ "examples": [ "user.vip == true" ], - "type": "string" + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] }, "actions": { "type": "array", @@ -5059,6 +7722,27 @@ "$kind": "Microsoft.IDialog", "$ref": "#/definitions/Microsoft.IDialog" } + }, + "priority": { + "title": "priority", + "description": "Priority expression of rule with 0 being the most important", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "integer" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to integer." + } + ] + }, + "runOnce": { + "type": "boolean", + "title": "Run Once", + "description": "True if rule should run once per unique conditions" } }, "additionalProperties": false, @@ -5120,7 +7804,17 @@ "examples": [ "user.vip == true" ], - "type": "string" + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] }, "actions": { "type": "array", @@ -5129,6 +7823,27 @@ "$kind": "Microsoft.IDialog", "$ref": "#/definitions/Microsoft.IDialog" } + }, + "priority": { + "title": "priority", + "description": "Priority expression of rule with 0 being the most important", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "integer" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to integer." + } + ] + }, + "runOnce": { + "type": "boolean", + "title": "Run Once", + "description": "True if rule should run once per unique conditions" } }, "additionalProperties": false, @@ -5190,7 +7905,17 @@ "examples": [ "user.vip == true" ], - "type": "string" + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] }, "actions": { "type": "array", @@ -5199,6 +7924,27 @@ "$kind": "Microsoft.IDialog", "$ref": "#/definitions/Microsoft.IDialog" } + }, + "priority": { + "title": "priority", + "description": "Priority expression of rule with 0 being the most important", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "integer" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to integer." + } + ] + }, + "runOnce": { + "type": "boolean", + "title": "Run Once", + "description": "True if rule should run once per unique conditions" } }, "additionalProperties": false, @@ -5260,7 +8006,17 @@ "examples": [ "user.vip == true" ], - "type": "string" + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] }, "actions": { "type": "array", @@ -5270,6 +8026,27 @@ "$ref": "#/definitions/Microsoft.IDialog" } }, + "priority": { + "title": "priority", + "description": "Priority expression of rule with 0 being the most important", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "integer" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to integer." + } + ] + }, + "runOnce": { + "type": "boolean", + "title": "Run Once", + "description": "True if rule should run once per unique conditions" + }, "intent": { "type": "string", "title": "Intent", @@ -5301,7 +8078,6 @@ "title": "Type", "required": [ "actions", - "intent", "$kind" ] } @@ -5344,7 +8120,17 @@ "examples": [ "user.vip == true" ], - "type": "string" + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] }, "actions": { "type": "array", @@ -5353,6 +8139,27 @@ "$kind": "Microsoft.IDialog", "$ref": "#/definitions/Microsoft.IDialog" } + }, + "priority": { + "title": "priority", + "description": "Priority expression of rule with 0 being the most important", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "integer" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to integer." + } + ] + }, + "runOnce": { + "type": "boolean", + "title": "Run Once", + "description": "True if rule should run once per unique conditions" } }, "additionalProperties": false, @@ -5414,7 +8221,17 @@ "examples": [ "user.vip == true" ], - "type": "string" + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] }, "actions": { "type": "array", @@ -5423,6 +8240,27 @@ "$kind": "Microsoft.IDialog", "$ref": "#/definitions/Microsoft.IDialog" } + }, + "priority": { + "title": "priority", + "description": "Priority expression of rule with 0 being the most important", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "integer" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to integer." + } + ] + }, + "runOnce": { + "type": "boolean", + "title": "Run Once", + "description": "True if rule should run once per unique conditions" } }, "additionalProperties": false, @@ -5484,7 +8322,17 @@ "examples": [ "user.vip == true" ], - "type": "string" + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] }, "actions": { "type": "array", @@ -5493,6 +8341,27 @@ "$kind": "Microsoft.IDialog", "$ref": "#/definitions/Microsoft.IDialog" } + }, + "priority": { + "title": "priority", + "description": "Priority expression of rule with 0 being the most important", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "integer" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to integer." + } + ] + }, + "runOnce": { + "type": "boolean", + "title": "Run Once", + "description": "True if rule should run once per unique conditions" } }, "additionalProperties": false, @@ -5554,7 +8423,17 @@ "examples": [ "user.vip == true" ], - "type": "string" + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] }, "actions": { "type": "array", @@ -5563,6 +8442,27 @@ "$kind": "Microsoft.IDialog", "$ref": "#/definitions/Microsoft.IDialog" } + }, + "priority": { + "title": "priority", + "description": "Priority expression of rule with 0 being the most important", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "integer" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to integer." + } + ] + }, + "runOnce": { + "type": "boolean", + "title": "Run Once", + "description": "True if rule should run once per unique conditions" } }, "additionalProperties": false, @@ -5624,7 +8524,118 @@ "examples": [ "user.vip == true" ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + }, + "actions": { + "type": "array", + "description": "Sequence of actions to execute.", + "items": { + "$kind": "Microsoft.IDialog", + "$ref": "#/definitions/Microsoft.IDialog" + } + }, + "priority": { + "title": "priority", + "description": "Priority expression of rule with 0 being the most important", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "integer" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to integer." + } + ] + }, + "runOnce": { + "type": "boolean", + "title": "Run Once", + "description": "True if rule should run once per unique conditions" + } + }, + "additionalProperties": false, + "patternProperties": { + "^\\$": { "type": "string" + } + }, + "anyOf": [ + { + "title": "Reference", + "required": [ + "$copy" + ] + }, + { + "title": "Type", + "required": [ + "actions", + "$kind" + ] + } + ] + }, + "Microsoft.OnQnAMatch": { + "$role": "union(Microsoft.ITriggerCondition)", + "title": "On QnAMaker Match", + "description": "Actions to perform on when an match from QnAMaker is found.", + "type": "object", + "properties": { + "$kind": { + "title": "$kind", + "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", + "type": "string", + "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", + "const": "Microsoft.OnQnAMatch" + }, + "$copy": { + "title": "$copy", + "description": "Copy the definition by id from a .dialog file.", + "type": "string", + "pattern": "^(([a-zA-Z][a-zA-Z0-9.]*)?(#[a-zA-Z][a-zA-Z0-9.]*)?)$" + }, + "$id": { + "title": "$id", + "description": "Inline id for reuse of an inline definition", + "type": "string", + "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" + }, + "$designer": { + "title": "$designer", + "type": "object", + "description": "Extra information for the Bot Framework Designer." + }, + "condition": { + "$role": "expression", + "title": "Condition", + "description": "Condition (expression).", + "examples": [ + "user.vip == true" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] }, "actions": { "type": "array", @@ -5633,6 +8644,27 @@ "$kind": "Microsoft.IDialog", "$ref": "#/definitions/Microsoft.IDialog" } + }, + "priority": { + "title": "priority", + "description": "Priority expression of rule with 0 being the most important", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "integer" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to integer." + } + ] + }, + "runOnce": { + "type": "boolean", + "title": "Run Once", + "description": "True if rule should run once per unique conditions" } }, "additionalProperties": false, @@ -5694,7 +8726,17 @@ "examples": [ "user.vip == true" ], - "type": "string" + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] }, "actions": { "type": "array", @@ -5703,6 +8745,27 @@ "$kind": "Microsoft.IDialog", "$ref": "#/definitions/Microsoft.IDialog" } + }, + "priority": { + "title": "priority", + "description": "Priority expression of rule with 0 being the most important", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "integer" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to integer." + } + ] + }, + "runOnce": { + "type": "boolean", + "title": "Run Once", + "description": "True if rule should run once per unique conditions" } }, "additionalProperties": false, @@ -5764,7 +8827,17 @@ "examples": [ "user.vip == true" ], - "type": "string" + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] }, "actions": { "type": "array", @@ -5773,6 +8846,27 @@ "$kind": "Microsoft.IDialog", "$ref": "#/definitions/Microsoft.IDialog" } + }, + "priority": { + "title": "priority", + "description": "Priority expression of rule with 0 being the most important", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "integer" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to integer." + } + ] + }, + "runOnce": { + "type": "boolean", + "title": "Run Once", + "description": "True if rule should run once per unique conditions" } }, "additionalProperties": false, @@ -5834,7 +8928,17 @@ "examples": [ "user.vip == true" ], - "type": "string" + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] }, "actions": { "type": "array", @@ -5843,6 +8947,27 @@ "$kind": "Microsoft.IDialog", "$ref": "#/definitions/Microsoft.IDialog" } + }, + "priority": { + "title": "priority", + "description": "Priority expression of rule with 0 being the most important", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "integer" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to integer." + } + ] + }, + "runOnce": { + "type": "boolean", + "title": "Run Once", + "description": "True if rule should run once per unique conditions" } }, "additionalProperties": false, @@ -6056,27 +9181,27 @@ }, "knowledgeBaseId": { "$role": "expression", + "type": "string", "title": "KnowledgeBase Id", "description": "KnowledgeBase Id of your QnA Maker KnowledgeBase.", - "default": "settings.qna.knowledgebaseid", - "type": "string" + "default": "=settings.qna.knowledgebaseid" }, "endpointKey": { "$role": "expression", + "type": "string", "title": "Endpoint Key", "description": "Endpoint key for the QnA Maker KB.", - "default": "settings.qna.endpointkey", - "type": "string" + "default": "=settings.qna.endpointkey" }, "hostname": { "$role": "expression", + "type": "string", "title": "Hostname", "description": "Hostname for your QnA Maker service.", - "default": "settings.qna.hostname", + "default": "=settings.qna.hostname", "examples": [ "https://yourserver.azurewebsites.net/qnamaker" - ], - "type": "string" + ] }, "noAnswer": { "$kind": "Microsoft.IActivityTemplate", @@ -6086,18 +9211,31 @@ "$ref": "#/definitions/Microsoft.IActivityTemplate" }, "threshold": { - "type": "number", + "$role": "expression", "title": "Threshold", "description": "Threshold score to filter results.", - "default": 0.3 + "oneOf": [ + { + "type": "number", + "default": 0.3, + "title": "number" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to number." + } + ] }, "activeLearningCardTitle": { + "$role": "expression", "type": "string", "title": "Active learning card title", "description": "Title for active learning suggestions card.", "default": "Did you mean:" }, "cardNoMatchText": { + "$role": "expression", "type": "string", "title": "Card no match text", "description": "Text for no match option.", @@ -6110,6 +9248,161 @@ "default": "Thanks for the feedback.", "$ref": "#/definitions/Microsoft.IActivityTemplate" }, + "strictFilters": { + "$role": "expression", + "title": "Strict Filters", + "description": "Metadata filters to use when calling the QnA Maker KB.", + "oneOf": [ + { + "type": "array", + "items": { + "type": "object", + "properties": { + "name": { + "type": "string", + "title": "Name", + "maximum": 100 + }, + "value": { + "type": "string", + "title": "Value", + "maximum": 100 + } + }, + "title": "object" + }, + "title": "array" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to array." + } + ] + }, + "top": { + "$role": "expression", + "title": "Top", + "description": "The number of answers you want to retrieve.", + "oneOf": [ + { + "type": "number", + "default": 3, + "title": "number" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to number." + } + ] + }, + "isTest": { + "type": "boolean", + "title": "IsTest", + "description": "True, if pointing to Test environment, else false.", + "default": false + }, + "rankerType": { + "type": "string", + "title": "RankerType", + "description": "Type of Ranker.", + "enum": [ + "Default", + "QuestionOnly", + "AutoSuggestQuestion" + ], + "default": "Default" + } + }, + "patternProperties": { + "^\\$": { + "type": "string" + } + }, + "anyOf": [ + { + "title": "Reference", + "required": [ + "$copy" + ] + }, + { + "title": "Type", + "required": [ + "knowledgeBaseId", + "endpointKey", + "hostname", + "$kind" + ] + } + ] + }, + "Microsoft.QnAMakerRecognizer": { + "$role": "union(Microsoft.Recognizer)", + "title": "QnAMaker Recognizer", + "description": "Recognizer for generating QnAMatch intents from a KB.", + "type": "object", + "properties": { + "$kind": { + "title": "$kind", + "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", + "type": "string", + "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", + "const": "Microsoft.QnAMakerRecognizer" + }, + "$copy": { + "title": "$copy", + "description": "Copy the definition by id from a .dialog file.", + "type": "string", + "pattern": "^(([a-zA-Z][a-zA-Z0-9.]*)?(#[a-zA-Z][a-zA-Z0-9.]*)?)$" + }, + "$id": { + "title": "$id", + "description": "Inline id for reuse of an inline definition", + "type": "string", + "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" + }, + "$designer": { + "title": "$designer", + "type": "object", + "description": "Extra information for the Bot Framework Designer." + }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional unique id using with RecognizerSet." + }, + "knowledgeBaseId": { + "$role": "expression", + "type": "string", + "title": "KnowledgeBase Id", + "description": "KnowledgeBase Id of your QnA Maker KnowledgeBase.", + "default": "settings.qna.knowledgebaseid" + }, + "endpointKey": { + "$role": "expression", + "type": "string", + "title": "Endpoint Key", + "description": "Endpoint key for the QnA Maker KB.", + "default": "settings.qna.endpointkey" + }, + "hostname": { + "$role": "expression", + "type": "string", + "title": "Hostname", + "description": "Hostname for your QnA Maker service.", + "default": "settings.qna.hostname", + "examples": [ + "https://yourserver.azurewebsites.net/qnamaker" + ] + }, + "threshold": { + "type": "number", + "title": "Threshold", + "description": "Threshold score to filter results.", + "default": 0.3 + }, "strictFilters": { "type": "array", "title": "Strict Filters", @@ -6130,13 +9423,84 @@ } } }, - "top": { - "type": "number", - "title": "Top", - "description": "The number of answers you want to retrieve.", - "default": 3 + "top": { + "type": "number", + "title": "Top", + "description": "The number of answers you want to retrieve.", + "default": 3 + }, + "isTest": { + "type": "boolean", + "title": "IsTest", + "description": "True, if pointing to Test environment, else false.", + "default": false + }, + "rankerType": { + "type": "string", + "title": "RankerType", + "description": "Type of Ranker.", + "default": "Default" + } + }, + "additionalProperties": false, + "patternProperties": { + "^\\$": { + "type": "string" + } + }, + "anyOf": [ + { + "title": "Reference", + "required": [ + "$copy" + ] + }, + { + "title": "Type", + "required": [ + "knowledgeBaseId", + "endpointKey", + "hostname", + "$kind" + ] + } + ] + }, + "Microsoft.RandomSelector": { + "$role": "union(Microsoft.ITriggerSelector)", + "title": "Random rule selector", + "description": "Select most specific true rule", + "type": "object", + "properties": { + "$kind": { + "title": "$kind", + "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", + "type": "string", + "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", + "const": "Microsoft.RandomSelector" + }, + "$copy": { + "title": "$copy", + "description": "Copy the definition by id from a .dialog file.", + "type": "string", + "pattern": "^(([a-zA-Z][a-zA-Z0-9.]*)?(#[a-zA-Z][a-zA-Z0-9.]*)?)$" + }, + "$id": { + "title": "$id", + "description": "Inline id for reuse of an inline definition", + "type": "string", + "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" + }, + "$designer": { + "title": "$designer", + "type": "object", + "description": "Extra information for the Bot Framework Designer." + }, + "seed": { + "type": "integer" } }, + "additionalProperties": false, "patternProperties": { "^\\$": { "type": "string" @@ -6152,18 +9516,61 @@ { "title": "Type", "required": [ - "knowledgeBaseId", - "endpointKey", - "hostname", "$kind" ] } ] }, - "Microsoft.RandomSelector": { - "$role": "union(Microsoft.ITriggerSelector)", - "title": "Random rule selector", - "description": "Select most specific true rule", + "Microsoft.Recognizer": { + "title": "Microsoft Recognizer", + "description": "Union of components which implement the Recognizer abstract class", + "$role": "union", + "oneOf": [ + { + "title": "Microsoft.AdaptiveCardRecognizer", + "description": "Recognizer for detecting the value response from an Adaptive Card.", + "$ref": "#/definitions/Microsoft.AdaptiveCardRecognizer" + }, + { + "title": "Microsoft.CrossTrainedRecognizerSet", + "description": "Recognizer for selecting between cross trained recognizers.", + "$ref": "#/definitions/Microsoft.CrossTrainedRecognizerSet" + }, + { + "title": "Microsoft.LuisRecognizer", + "description": "LUIS recognizer.", + "$ref": "#/definitions/Microsoft.LuisRecognizer" + }, + { + "title": "Microsoft.MultiLanguageRecognizer", + "description": "Configure one recognizer per language and the specify the language fallback policy.", + "$ref": "#/definitions/Microsoft.MultiLanguageRecognizer" + }, + { + "title": "Microsoft.QnAMakerRecognizer", + "description": "Recognizer for generating QnAMatch intents from a KB.", + "$ref": "#/definitions/Microsoft.QnAMakerRecognizer" + }, + { + "title": "Microsoft.RecognizerSet", + "description": "Creates the union of the intents and entities of the recognizers in the set.", + "$ref": "#/definitions/Microsoft.RecognizerSet" + }, + { + "title": "Microsoft.RegexRecognizer", + "description": "Use regular expressions to recognize intents and entities from user input.", + "$ref": "#/definitions/Microsoft.RegexRecognizer" + }, + { + "type": "string", + "title": "string" + } + ] + }, + "Microsoft.RecognizerSet": { + "$role": "union(Microsoft.Recognizer)", + "title": "Recognizer Set", + "description": "Creates the union of the intents and entities of the recognizers in the set.", "type": "object", "properties": { "$kind": { @@ -6171,7 +9578,7 @@ "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", "type": "string", "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", - "const": "Microsoft.RandomSelector" + "const": "Microsoft.RecognizerSet" }, "$copy": { "title": "$copy", @@ -6190,8 +9597,19 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, - "seed": { - "type": "integer" + "id": { + "type": "string", + "title": "Id", + "description": "Optional unique id using with RecognizerSet. Other recognizers should return 'DeferToRecognizer_{Id}' intent when cross training data for this recognizer." + }, + "recognizers": { + "type": "array", + "title": "Recognizers", + "description": "List of Recognizers defined for this set.", + "items": { + "$kind": "Microsoft.Recognizer", + "$ref": "#/definitions/Microsoft.Recognizer" + } } }, "additionalProperties": false, @@ -6210,6 +9628,7 @@ { "title": "Type", "required": [ + "recognizers", "$kind" ] } @@ -6280,7 +9699,7 @@ ] }, "Microsoft.RegexRecognizer": { - "$role": "union(Microsoft.IRecognizer)", + "$role": "union(Microsoft.Recognizer)", "title": "Regex recognizer", "description": "Use regular expressions to recognize intents and entities from user input.", "type": "object", @@ -6309,6 +9728,11 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional unique id using with RecognizerSet. Other recognizers should return 'DeferToRecognizer_{Id}' intent when cross training data for this recognizer." + }, "intents": { "type": "array", "title": "RegEx patterns to intents", @@ -6391,20 +9815,66 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "disabled": { + "$role": "expression", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + }, "options": { - "type": "object", + "$role": "expression", "title": "Options", "description": "One or more options that are passed to the dialog that is called.", - "additionalProperties": { - "type": "string", - "title": "Options" - } + "oneOf": [ + { + "type": "object", + "additionalProperties": { + "type": "string", + "title": "Options" + }, + "title": "object" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to object." + } + ] }, - "includeActivity": { - "type": "boolean", - "title": "Include Activity", - "description": "When set to true, dialog that is called can process the current activity.", - "default": false + "activityProcessed": { + "$role": "expression", + "title": "Activity Processed", + "description": "When set to false, the dialog that is called can process the current activity.", + "oneOf": [ + { + "type": "boolean", + "default": true, + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] } }, "additionalProperties": false, @@ -6458,8 +9928,34 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "disabled": { + "$role": "expression", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + }, "dialog": { "$kind": "Microsoft.IDialog", + "$role": "expression", + "type": "string", "title": "Dialog name", "description": "Name of the dialog to call.", "examples": [ @@ -6468,19 +9964,41 @@ "$ref": "#/definitions/Microsoft.IDialog" }, "options": { - "type": "object", + "$role": "expression", "title": "Options", "description": "One or more options that are passed to the dialog that is called.", - "additionalProperties": { - "type": "string", - "title": "Options" - } + "oneOf": [ + { + "type": "object", + "additionalProperties": { + "type": "string", + "title": "Options" + }, + "title": "object" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to object." + } + ] }, - "includeActivity": { - "type": "boolean", - "title": "Include Activity", - "description": "When set to true, dialog that is called can process the current activity.", - "default": false + "activityProcessed": { + "$role": "expression", + "title": "Activity Processed", + "description": "When set to false, the dialog that is called can process the current activity.", + "oneOf": [ + { + "type": "boolean", + "default": true, + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] } }, "additionalProperties": false, @@ -6534,6 +10052,30 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "disabled": { + "$role": "expression", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + }, "activity": { "$kind": "Microsoft.IActivityTemplate", "title": "Activity", @@ -6592,6 +10134,30 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "disabled": { + "$role": "expression", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + }, "assignments": { "type": "array", "title": "Assignments", @@ -6601,26 +10167,137 @@ "properties": { "property": { "$role": "expression", + "type": "string", "title": "Property", "description": "Property (named location to store information).", "examples": [ "user.age" - ], - "type": "string" + ] }, "value": { "$role": "expression", + "type": [ + "object", + "array", + "number", + "integer", + "boolean", + "string" + ], "title": "Value", "description": "New value or expression.", "examples": [ - "'milk'", - "dialog.favColor", - "dialog.favColor == 'red'" - ], - "type": "string" + "='milk'", + "=dialog.favColor", + "=dialog.favColor == 'red'" + ] } } - } + } + } + }, + "additionalProperties": false, + "patternProperties": { + "^\\$": { + "type": "string" + } + }, + "anyOf": [ + { + "title": "Reference", + "required": [ + "$copy" + ] + }, + { + "title": "Type", + "required": [ + "assignments", + "$kind" + ] + } + ] + }, + "Microsoft.SetProperty": { + "$role": "union(Microsoft.IDialog)", + "title": "Set property", + "description": "Set property to a value.", + "type": "object", + "properties": { + "$kind": { + "title": "$kind", + "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", + "type": "string", + "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", + "const": "Microsoft.SetProperty" + }, + "$copy": { + "title": "$copy", + "description": "Copy the definition by id from a .dialog file.", + "type": "string", + "pattern": "^(([a-zA-Z][a-zA-Z0-9.]*)?(#[a-zA-Z][a-zA-Z0-9.]*)?)$" + }, + "$id": { + "title": "$id", + "description": "Inline id for reuse of an inline definition", + "type": "string", + "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" + }, + "$designer": { + "title": "$designer", + "type": "object", + "description": "Extra information for the Bot Framework Designer." + }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "disabled": { + "$role": "expression", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + }, + "property": { + "$role": "expression", + "type": "string", + "title": "Property", + "description": "Property (named location to store information).", + "examples": [ + "user.age" + ] + }, + "value": { + "$role": "expression", + "type": [ + "object", + "array", + "number", + "integer", + "boolean", + "string" + ], + "title": "Value", + "description": "New value or expression.", + "examples": [ + "='milk'", + "=dialog.favColor", + "=dialog.favColor == 'red'" + ] } }, "additionalProperties": false, @@ -6639,16 +10316,17 @@ { "title": "Type", "required": [ - "assignments", + "property", + "value", "$kind" ] } ] }, - "Microsoft.SetProperty": { + "Microsoft.SignOutUser": { "$role": "union(Microsoft.IDialog)", - "title": "Set property", - "description": "Set property to a value.", + "title": "Sign Out User", + "description": "Sign a user out that was logged in previously using OAuthInput.", "type": "object", "properties": { "$kind": { @@ -6656,7 +10334,7 @@ "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", "type": "string", "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", - "const": "Microsoft.SetProperty" + "const": "Microsoft.SignOutUser" }, "$copy": { "title": "$copy", @@ -6675,25 +10353,44 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, - "property": { + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "userId": { "$role": "expression", - "title": "Property", - "description": "Property (named location to store information).", + "type": "string", + "title": "ActivityId", + "description": "expression to an activityId to get the members. If none is defined then the current activity id will be used.", "examples": [ - "user.age" - ], - "type": "string" + "=$lastActivity" + ] }, - "value": { + "connectionName": { "$role": "expression", - "title": "Value", - "description": "New value or expression.", + "type": "string", + "title": "Connection Name", + "description": "Connection name that was used with OAuthInput to log a user in." + }, + "disabled": { + "$role": "expression", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", "examples": [ - "'milk'", - "dialog.favColor", - "dialog.favColor == 'red'" + "user.age > 3" ], - "type": "string" + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] } }, "additionalProperties": false, @@ -6712,8 +10409,6 @@ { "title": "Type", "required": [ - "property", - "value", "$kind" ] } @@ -6807,14 +10502,38 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, "condition": { "$role": "expression", + "type": "string", "title": "Condition", "description": "Property to evaluate.", "examples": [ "user.favColor" + ] + }, + "disabled": { + "$role": "expression", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" ], - "type": "string" + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] }, "cases": { "type": "array", @@ -6829,13 +10548,18 @@ "properties": { "value": { "$role": "expression", + "type": [ + "number", + "integer", + "boolean", + "string" + ], "title": "Value", "description": "Value.", "examples": [ "'red'", "dialog.colors.red" - ], - "type": "string" + ] }, "actions": { "type": "array", @@ -6970,7 +10694,17 @@ "examples": [ "user.age > 10" ], - "type": "string" + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] }, "description": { "type": "string", @@ -7060,7 +10794,17 @@ "examples": [ "user.vip == true" ], - "type": "string" + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] } } }, @@ -7137,7 +10881,17 @@ "examples": [ "user.vip == true" ], - "type": "string" + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] } } }, @@ -7227,7 +10981,17 @@ "examples": [ "user.vip == true" ], - "type": "string" + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] } } }, @@ -7297,6 +11061,11 @@ "title": "Microsoft.Test.UserTyping", "description": "Sends typing activity to the bot.", "$ref": "#/definitions/Microsoft.Test.UserTyping" + }, + { + "type": "string", + "title": "Reference to Microsoft.Test.ITestAction", + "description": "Reference to Microsoft.Test.ITestAction .dialog file." } ] }, @@ -7348,6 +11117,12 @@ "$ref": "#/definitions/Microsoft.Test.ITestAction" } }, + "locale": { + "type": "string", + "title": "Locale", + "description": "Set the locale for the user utterances in the script.", + "default": "en-us" + }, "enableTrace": { "type": "boolean", "title": "Enable Trace Activity", @@ -7721,6 +11496,18 @@ "title": "Id", "description": "Optional id for the dialog" }, + "disabled": { + "$role": "expression", + "type": [ + "boolean", + "string" + ], + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ] + }, "prompt": { "$kind": "Microsoft.IActivityTemplate", "title": "Initial prompt", @@ -7758,7 +11545,11 @@ "$ref": "#/definitions/Microsoft.IActivityTemplate" }, "maxTurnCount": { - "type": "integer", + "$role": "expression", + "type": [ + "integer", + "string" + ], "title": "Max turn count", "description": "Maximum number of re-prompt attempts to collect information.", "default": 3, @@ -7776,12 +11567,12 @@ ], "items": { "$role": "expression", - "type": "string", - "description": "String must contain an expression." + "type": "string" } }, "property": { "$role": "expression", + "type": "string", "title": "Property", "description": "Property to store collected information. Input will be skipped if property has value (unless 'Always prompt' is true).", "examples": [ @@ -7789,32 +11580,49 @@ "user.name", "conversation.issueTitle", "dialog.favColor" - ], - "type": "string" + ] }, "defaultValue": { "$role": "expression", + "type": [ + "object", + "array", + "number", + "integer", + "boolean", + "string" + ], "title": "Default value", "description": "Expression to examine on each turn of the conversation as possible value to the property.", "examples": [ "@userName", "coalesce(@number, @partySize)" - ], - "type": "string" + ] }, "value": { "$role": "expression", + "type": [ + "object", + "array", + "number", + "integer", + "boolean", + "string" + ], "title": "Value", "description": "Gets or sets a value expression which can be used to intialize the input prompt.", "examples": [ "@userName" - ], - "type": "string" + ] }, "alwaysPrompt": { - "type": "boolean", + "$role": "expression", + "type": [ + "boolean", + "string" + ], "title": "Always prompt", - "description": "Collect information even if the specified 'property' is not empty.", + "description": "Collect information even if the specified 'property' is not empty.", "default": false, "examples": [ false @@ -7822,22 +11630,26 @@ }, "allowInterruptions": { "$role": "expression", + "type": [ + "boolean", + "string" + ], "title": "Allow Interruptions", "description": "A boolean expression that determines whether the parent should be allowed to interrupt the input.", "default": "true", "examples": [ "true" - ], - "type": "string" + ] }, "outputFormat": { "$role": "expression", + "type": "string", "title": "Output format", "description": "Expression to format the output.", "examples": [ - "toUpper(this.value)" - ], - "type": "string" + "=toUpper(this.value)", + "@{toUpper(this.value)}" + ] } }, "additionalProperties": false, @@ -7949,21 +11761,60 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "disabled": { + "$role": "expression", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + }, "name": { + "$role": "expression", "type": "string", "title": "Name", "description": "Name of the trace activity" }, + "label": { + "$role": "expression", + "type": "string", + "title": "Label", + "description": "Label for the trace activity (used to identify it in a list of trace activities.)" + }, "valueType": { + "$role": "expression", "type": "string", "title": "Value type", "description": "Type of value" }, "value": { "$role": "expression", + "type": [ + "object", + "array", + "number", + "integer", + "boolean", + "string" + ], "title": "Value", - "description": "Property that holds the value to send as trace activity.", - "type": "string" + "description": "Property that holds the value to send as trace activity." } }, "additionalProperties": false, @@ -8039,6 +11890,97 @@ } ] }, + "Microsoft.UpdateActivity": { + "$role": "union(Microsoft.IDialog)", + "title": "Send an activity", + "description": "Respond with an activity.", + "type": "object", + "properties": { + "$kind": { + "title": "$kind", + "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", + "type": "string", + "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", + "const": "Microsoft.UpdateActivity" + }, + "$copy": { + "title": "$copy", + "description": "Copy the definition by id from a .dialog file.", + "type": "string", + "pattern": "^(([a-zA-Z][a-zA-Z0-9.]*)?(#[a-zA-Z][a-zA-Z0-9.]*)?)$" + }, + "$id": { + "title": "$id", + "description": "Inline id for reuse of an inline definition", + "type": "string", + "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" + }, + "$designer": { + "title": "$designer", + "type": "object", + "description": "Extra information for the Bot Framework Designer." + }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "disabled": { + "$role": "expression", + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ], + "oneOf": [ + { + "type": "boolean", + "title": "boolean" + }, + { + "type": "string", + "title": "Expression", + "description": "Expression evaluating to boolean." + } + ] + }, + "activityId": { + "$role": "expression", + "type": "string", + "title": "Activity Id", + "dDescription": "An string expression with the activity id to update.", + "examples": [ + "=dialog.lastActivityId" + ] + }, + "activity": { + "$kind": "Microsoft.IActivityTemplate", + "title": "Activity", + "description": "Activity to send.", + "$ref": "#/definitions/Microsoft.IActivityTemplate" + } + }, + "additionalProperties": false, + "patternProperties": { + "^\\$": { + "type": "string" + } + }, + "anyOf": [ + { + "title": "Reference", + "required": [ + "$copy" + ] + }, + { + "title": "Type", + "required": [ + "$kind" + ] + } + ] + }, "Microsoft.UrlEntityRecognizer": { "$role": "union(Microsoft.EntityRecognizers)", "title": "Url Entity Recognizer", @@ -8092,4 +12034,4 @@ ] } } -} +} \ No newline at end of file diff --git a/Composer/packages/server/src/models/connector/csharpBotConnector.ts b/Composer/packages/server/src/models/connector/csharpBotConnector.ts index 860f54bb5b..e77bddcd0d 100644 --- a/Composer/packages/server/src/models/connector/csharpBotConnector.ts +++ b/Composer/packages/server/src/models/connector/csharpBotConnector.ts @@ -7,12 +7,14 @@ import fs from 'fs'; import getPort from 'get-port'; +import envSettings from '../../settings'; import { BotProjectService } from '../../services/project'; import { DialogSetting } from '../bot/interface'; import { Path } from '../../utility/path'; import log from '../../logger'; import AssetService from '../../services/asset'; import { IFileStorage } from '../storage/interface'; +import { currentConfig } from '../environment'; import { BotConfig, BotEnvironments, BotStatus, IBotConnector, IPublishHistory } from './interface'; @@ -150,7 +152,12 @@ export class CSharpBotConnector implements IBotConnector { return new Promise((resolve, reject) => { const runtime = spawn( 'dotnet', - ['bin/Debug/netcoreapp2.1/BotProject.dll', `--urls`, this.endpoint, ...this.getConnectorConfig(config)], + [ + `bin/Debug/${envSettings.runtimeFrameworkVersion}/BotProject.dll`, + `--urls`, + this.endpoint, + ...this.getConnectorConfig(config), + ], { cwd: dir, stdio: ['ignore', 'pipe', 'pipe'], @@ -168,6 +175,7 @@ export class CSharpBotConnector implements IBotConnector { const originPort = urlParse(this.endpoint).port; const port = await getPort({ host: 'localhost', port: parseInt(originPort || '3979') }); this.endpoint = `http://localhost:${port}`; + currentConfig.endpoint = this.endpoint; return `http://localhost:${port}/api/messages`; }; diff --git a/Composer/packages/server/src/settings/env.ts b/Composer/packages/server/src/settings/env.ts index e6de68331b..d5f5508351 100644 --- a/Composer/packages/server/src/settings/env.ts +++ b/Composer/packages/server/src/settings/env.ts @@ -19,3 +19,4 @@ export const botEndpoint = process.env.BOT_ENDPOINT || 'http://localhost:3979'; export const appDataPath = process.env.COMPOSER_APP_DATA || Path.resolve(__dirname, '../../data.json'); export const runtimeFolder = process.env.COMPOSER_RUNTIME_FOLDER || Path.resolve(__dirname, '../../../../../BotProject/Templates'); +export const runtimeFrameworkVersion = process.env.COMPOSER_RUNTIME_VERSION || 'netcoreapp3.1'; diff --git a/Composer/packages/server/src/settings/index.ts b/Composer/packages/server/src/settings/index.ts index 3c2b166d82..1a50f2819d 100644 --- a/Composer/packages/server/src/settings/index.ts +++ b/Composer/packages/server/src/settings/index.ts @@ -8,13 +8,14 @@ import merge from 'lodash/merge'; import log from '../logger'; import { Path } from '../utility/path'; -import { botsFolder, botEndpoint, appDataPath, environment, runtimeFolder } from './env'; +import { botsFolder, botEndpoint, appDataPath, environment, runtimeFolder, runtimeFrameworkVersion } from './env'; interface Settings { botAdminEndpoint: string; botEndpoint: string; assetsLibray: string; runtimeFolder: string; + runtimeFrameworkVersion: string; botsFolder: string; appDataPath: string; } @@ -26,6 +27,7 @@ const envSettings: { [env: string]: Settings } = { assetsLibray: Path.resolve(__dirname, '../../assets'), botsFolder: botsFolder || Path.join(os.homedir(), 'Documents', 'Composer'), runtimeFolder, + runtimeFrameworkVersion, appDataPath, }, };