There are platforms that allow you to use their code and frameworks to build a chatbot. Or, you can build one from scratch. The time to completion can depend on the complexity of the project and your level of expertise.
How can you build a chatbot?
Further Reading
BLOG
What exactly is an AI chatbot?
BLOG
An comprehensive introduction to chatbots
BLOG
What is chatbot automation?