object BotRepository
(source)
Advanced bot configuration.
ai.tock.bot.registerAndInstallBot method is the preferred way to start a bot in most use cases.
healthcheckHandler |
healthcheck handler to answer to GET /healthcheck. var healthcheckHandler: (RoutingContext) -> Unit |
requestTimer |
Request timer for connectors. var requestTimer: RequestTimer |
checkBotConfigurations |
Checks that configurations are synchronized with the database. fun checkBotConfigurations(startup: Boolean = false, botConfigurationChanged: Boolean = false): Unit |
findConnectorProvider |
Returns the ConnectorProvider for the specified ConnectorType. fun findConnectorProvider(connectorType: ConnectorType): ConnectorProvider? |
forEachNlpListener |
Calls the specified action for each registered NlpListener. fun forEachNlpListener(action: (NlpListener) -> Unit): Unit |
getController |
Returns the current ConnectorController for a given predicate. fun getController(predicate: (BotApplicationConfiguration) -> Boolean): ConnectorController? |
installBots |
Installs the bot(s). fun installBots(routerHandlers: List<(Router) -> Any?>, createApplicationIfNotExists: Boolean = true, startupLock: Lock? = null): Unit |
notify |
Sends a notification to a connector. A Bus is created and the corresponding story is called. fun |
registerBotAnswerInterceptor |
Registers a new BotAnswerInterceptor. fun registerBotAnswerInterceptor(botAnswerInterceptor: BotAnswerInterceptor): Unit |
registerBotProvider |
Registers a new BotProvider. fun registerBotProvider(bot: BotProvider): Unit |
registerBuiltInStoryDefinitions |
Register built-in story definitions. fun registerBuiltInStoryDefinitions(botProvider: BotProvider): Unit |
registerConnectorService |
fun registerConnectorService(service: ConnectorService): Unit |
registerNlpListener |
Registers a new NlpListener. fun registerNlpListener(listener: NlpListener): Unit |
registerStoryHandlerListener |
Registers a new StoryHandlerListener. fun registerStoryHandlerListener(listener: StoryHandlerListener): Unit |