Class ChatBotConfiguration


  • @Configuration
    @PropertySource(value="classpath:/META-INF/chatbot.json",
                    factory=JsonLoader.class)
    public class ChatBotConfiguration
    extends Object
    • Field Detail

      • OBJECT_MAPPER

        public static final com.fasterxml.jackson.databind.ObjectMapper OBJECT_MAPPER
      • TYPE_LIST_QUICKREPLY

        public static final com.fasterxml.jackson.core.type.TypeReference<List<QuickReply>> TYPE_LIST_QUICKREPLY
      • TYPE_LIST_CAROUSEL

        public static final com.fasterxml.jackson.core.type.TypeReference<List<Carousel>> TYPE_LIST_CAROUSEL
      • TYPE_LIST_LABELURL

        public static final com.fasterxml.jackson.core.type.TypeReference<List<LabelUrl>> TYPE_LIST_LABELURL
      • TYPE_LIST_GROUPEDBUTTON

        public static final com.fasterxml.jackson.core.type.TypeReference<List<GroupedButton>> TYPE_LIST_GROUPEDBUTTON
    • Constructor Detail

      • ChatBotConfiguration

        public ChatBotConfiguration()
    • Method Detail

      • facebook

        @Bean
        public com.github.messenger4j.Messenger facebook​(@Value("${chatbot.facebook.page}")
                                                         String pageAccessToken,
                                                         @Value("${chatbot.facebook.app}")
                                                         String appSecret,
                                                         @Value("${chatbot.facebook.verify}")
                                                         String verifyToken)
      • assistant

        @Bean
        public com.ibm.watson.assistant.v1.Assistant assistant​(@Value("${chatbot.watson.username}")
                                                               String username,
                                                               @Value("${chatbot.watson.password}")
                                                               String password)