Updated descriptions in schema
This commit is contained in:
parent
316e814248
commit
7b64129cc1
1 changed files with 55 additions and 33 deletions
|
@ -2,30 +2,37 @@
|
||||||
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
"$schema": "https://json-schema.org/draft/2020-12/schema",
|
||||||
"id": "https://toastielab.dev/Emotions-stuff/SupportChild/raw/branch/main/Interviews/interview_template.schema.json",
|
"id": "https://toastielab.dev/Emotions-stuff/SupportChild/raw/branch/main/Interviews/interview_template.schema.json",
|
||||||
"title": "Interview Template",
|
"title": "Interview Template",
|
||||||
"description": "An interview dialog tree template for SupportChild",
|
"description": "An interview dialog tree template for SupportBoi",
|
||||||
"definitions": {
|
"definitions":
|
||||||
"step": {
|
{
|
||||||
|
"step":
|
||||||
|
{
|
||||||
"type": "object",
|
"type": "object",
|
||||||
"title": "Interview Step",
|
"title": "Interview Step",
|
||||||
"description": "Contains a question, error message or end of an interview.",
|
"description": "Contains a question, error message or end of an interview.",
|
||||||
"properties": {
|
"properties":
|
||||||
"heading": {
|
{
|
||||||
|
"heading":
|
||||||
|
{
|
||||||
"type": "string",
|
"type": "string",
|
||||||
"title": "Heading",
|
"title": "Heading",
|
||||||
"description": "The title of the message.",
|
"description": "The title of the message.",
|
||||||
"minLength": 1
|
"minLength": 1
|
||||||
},
|
},
|
||||||
"message": {
|
"message":
|
||||||
|
{
|
||||||
"type": "string",
|
"type": "string",
|
||||||
"title": "Message",
|
"title": "Message",
|
||||||
"description": "The message text.",
|
"description": "The text in the embed message that will be sent to the user when they reach this step.",
|
||||||
"minLength": 1
|
"minLength": 1
|
||||||
},
|
},
|
||||||
"message-type": {
|
"message-type":
|
||||||
|
{
|
||||||
"type": "string",
|
"type": "string",
|
||||||
"title": "Message Type",
|
"title": "Message Type",
|
||||||
"description": "The type of message, decides what the bot will do when the user gets to this step.",
|
"description": "The type of message, decides what the bot will do when the user gets to this step.",
|
||||||
"enum": [
|
"enum":
|
||||||
|
[
|
||||||
"ERROR",
|
"ERROR",
|
||||||
"END_WITH_SUMMARY",
|
"END_WITH_SUMMARY",
|
||||||
"END_WITHOUT_SUMMARY",
|
"END_WITHOUT_SUMMARY",
|
||||||
|
@ -38,11 +45,13 @@
|
||||||
"TEXT_INPUT"
|
"TEXT_INPUT"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"color": {
|
"color":
|
||||||
|
{
|
||||||
"type": "string",
|
"type": "string",
|
||||||
"title": "Color",
|
"title": "Color",
|
||||||
"description": "Colour of the embed message.",
|
"description": "Colour of the message embed. You can either enter a colour name or a hexadecimal RGB value.",
|
||||||
"examples": [
|
"examples":
|
||||||
|
[
|
||||||
"BLACK",
|
"BLACK",
|
||||||
"WHITE",
|
"WHITE",
|
||||||
"GRAY",
|
"GRAY",
|
||||||
|
@ -88,55 +97,65 @@
|
||||||
],
|
],
|
||||||
"minLength": 1
|
"minLength": 1
|
||||||
},
|
},
|
||||||
"steps": {
|
"steps":
|
||||||
|
{
|
||||||
"type": "object",
|
"type": "object",
|
||||||
"title": "Steps",
|
"title": "Steps",
|
||||||
"description": "The possible next steps, the name of the step is matched against the user input using regex, use \".*\" to match anything.",
|
"description": "One or more interview steps. The name of the step is used as a regex match against the user's answer, except for selection boxes and buttons where each step becomes a button or selection option.",
|
||||||
"patternProperties": {
|
"patternProperties":
|
||||||
".*": {
|
{
|
||||||
|
".*":
|
||||||
|
{
|
||||||
"$ref": "#/definitions/step"
|
"$ref": "#/definitions/step"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"summary-field": {
|
"summary-field":
|
||||||
|
{
|
||||||
"type": "string",
|
"type": "string",
|
||||||
"title": "Summary Field",
|
"title": "Summary Field",
|
||||||
"description": "If this interview ends with a summary this will be the name of the answer the user used in this field.",
|
"description": "When an interview ends all previous answers with this property will be put in a summary. If this property is not specified the answer will not be shown in the summary. The value of this property is the name which will be displayed next to the answer in the summary.",
|
||||||
"minLength": 1
|
"minLength": 1
|
||||||
},
|
},
|
||||||
"button-style": {
|
"button-style":
|
||||||
|
{
|
||||||
"type": "string",
|
"type": "string",
|
||||||
"title": "Button Style",
|
"title": "Button Style",
|
||||||
"description": "The style of the button that leads to this step, the step before this one must be a button step for this to work.",
|
"description": "The style of the button that leads to this step. Requires that the parent step is a 'BUTTONS' step.",
|
||||||
"enum": [
|
"enum":
|
||||||
|
[
|
||||||
"PRIMARY",
|
"PRIMARY",
|
||||||
"SECONDARY",
|
"SECONDARY",
|
||||||
"SUCCESS",
|
"SUCCESS",
|
||||||
"DANGER"
|
"DANGER"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"selector-description": {
|
"selector-description":
|
||||||
|
{
|
||||||
"type": "string",
|
"type": "string",
|
||||||
"title": "Selector Description",
|
"title": "Selector Description",
|
||||||
"description": "The description of the selector.",
|
"description": "Description for this option in the parent step's selection box. Requires that the parent step is a 'TEXT_SELECTOR'.",
|
||||||
"minLength": 1
|
"minLength": 1
|
||||||
},
|
},
|
||||||
"selector-placeholder": {
|
"selector-placeholder":
|
||||||
|
{
|
||||||
"type": "string",
|
"type": "string",
|
||||||
"title": "Selector Placeholder",
|
"title": "Selector Placeholder",
|
||||||
"description": "The placeholder shown before an option is selected.",
|
"description": "The placeholder text shown before a value is selected in the selection box. Requires that this step is a TEXT_SELECTOR.",
|
||||||
"minLength": 1
|
"minLength": 1
|
||||||
},
|
},
|
||||||
"max-length": {
|
"max-length":
|
||||||
|
{
|
||||||
"type": "number",
|
"type": "number",
|
||||||
"title": "Max Length",
|
"title": "Max Length",
|
||||||
"description": "The maximum length of the text input.",
|
"description": "The maximum length of the user's response message. Requires that this step is a 'TEXT_INPUT'.",
|
||||||
"maximum": 1024
|
"maximum": 1024
|
||||||
},
|
},
|
||||||
"min-length": {
|
"min-length":
|
||||||
|
{
|
||||||
"type": "number",
|
"type": "number",
|
||||||
"title": "Min Length",
|
"title": "Min Length",
|
||||||
"description": "The minimum length of the text input.",
|
"description": "The minimum length of the user's response message. Requires that this step is a 'TEXT_INPUT'.",
|
||||||
"minimum": 0
|
"minimum": 0
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
@ -145,13 +164,16 @@
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"type": "object",
|
"type": "object",
|
||||||
"properties": {
|
"properties":
|
||||||
"category-id": {
|
{
|
||||||
|
"category-id":
|
||||||
|
{
|
||||||
"type": "string",
|
"type": "string",
|
||||||
"title": "Category ID",
|
"title": "Category ID",
|
||||||
"description": "The category the template applies to. Change this to apply the template to a different category."
|
"description": "The id of the category this template applies to. You can change this and re-upload the template to apply it to a different category."
|
||||||
},
|
},
|
||||||
"interview": {
|
"interview":
|
||||||
|
{
|
||||||
"$ref": "#/definitions/step"
|
"$ref": "#/definitions/step"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
Loading…
Reference in a new issue