Last active
March 11, 2018 18:32
-
-
Save kmelve/af2a8f8e0a045ce62d731ddb69373505 to your computer and use it in GitHub Desktop.
Intent and fullfillment in Sanity
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| export default { | |
| name: 'fullfillments', | |
| title: 'Fullfillments', | |
| description: 'Short texts that represent this content as chatbot fullfillments', | |
| type: 'array', | |
| of: [ | |
| { | |
| type: 'string' | |
| } | |
| ] | |
| } |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| /* | |
| * Intent schema for Sanity | |
| */ | |
| export default { | |
| name: 'intent', | |
| title: 'Intent', | |
| type: 'document', | |
| fields: [ | |
| { | |
| name: 'title', | |
| type: 'string', | |
| description: | |
| 'Descriptive title that makes this intent easily identifiable', | |
| title: 'Title' | |
| }, | |
| { | |
| name: 'intentName', | |
| type: 'string', | |
| title: 'Name of intent', | |
| description: | |
| 'Maps intent to the chatbot with an identifier. E.g. “displayname” in Dialogflow' | |
| }, | |
| { | |
| name: 'fullfillments', | |
| title: 'Fullfillments', | |
| description: 'Choose the pages that contain answers to this intent', | |
| type: 'array', | |
| of: [ | |
| { | |
| title: 'Short answers from existing content', | |
| type: 'reference', | |
| to: [ | |
| { | |
| type: 'post' | |
| } | |
| ] | |
| } | |
| ] | |
| } | |
| ] | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment