I have used same code as mentioned in one of the samples available on Google Chat Documentation https://github.com/googleworkspace/hangouts-chat-samples/blob/master/java/basic-async-bot/src/main/java/com/google/chat/bot/basic/async/Bot.java
But the google chat is first giving the message "BOTNAME not responding" then the reply from the bot. I have even tried to post the message with the thread from previous message as mentioned in the documentation. But still not getting desired result.