We built a simple chatbot in a few hours. Here’s how. by@refind

We built a simple chatbot in a few hours. Here’s how.

April 6th 2017 2,294 reads
Read on Terminal Reader
react to story with heart
react to story with light
react to story with boat
react to story with money
image
Refind HackerNoon profile picture

Refind

Bots are all the hype. Chris Messina, an active Refind user and a bot uber-guru, pushed us to build one for ages. One day we finally felt like it: we wanted to test the waters with a simple bot.
image

Why?

Refind is the home for the best links on the web. People use it to discover, save, and read what’s really worth their attention. A bot could send the user a digest of the top 3 links as a daily morning briefing — on the platform and device she hangs out on.

Specs for V1

  • The user can subscribe to a few topics: Design, UX, Programming, etc.
  • Every day, the bot sends the top 3 links — curated by our community of hipsters, hackers, and hustlers — at 8AM (local time).
  • The user could change frequency: daily, three times a week, weekly.

Zero to bot

Within a few hours, we had the bot ready. Here’s a quick rundown of our steps in case you’re new to bots and want to build one yourself:
  1. Wrote down (business) goals in a Google Doc.
  2. Read a few articles about bots in general, from this list: https://refind.com/chrismessina?q=bots
  3. Jotted down a few questions / potential show stoppers (e.g., can a bot send a message to the user days after the first interaction?).
  4. Played with a few bots (first time we ever interacted with a chatbot): MessinaBot, CNN, WSJ, TechCrunch.
  5. Quickly researched platforms: FB Messenger, Slack, iMessage, …
  6. Decided to start with FB Messenger.
  7. Most questions had been answered by now (e.g., on FB, you can send after 24h with the page_messaging_subscription).
  8. Build from scratch or use a developer tool? Scanned FB platform docs, researched a few developer tools.
  9. Decided to go with Chatfuel.
  10. Created a Hello World bot (that was easy!).
  11. Sketched the bot in a Google Doc: onboarding, flow, key messages.
  12. Question: What’s the interface with Refind? API?
  13. Found that RSS is probably the simplest interface to start with.
  14. Found the TechCrunch template on Chatfuel.
  15. Created a new bot using the TechCrunch template on Chatfuel.
  16. Created RSS feeds for popular topics.
  17. Used the W3C validator to validate our feeds.
  18. Used the endpoints in the bot.
  19. Adapted messages.
  20. Published the bot.
  21. Tested one day later: The bot came back to us — on time at 8 AM local — with our digest of top 3 links. Cool!
  22. Made some minor tweaks, improved the flow.
  23. Wrote this post.

Give it a try

https://m.me/refindcom (no Refind account required)

What’s next?

Obviously, this is a very simple bot. If it becomes popular, we’ll extend it with features to save links to Refind or to deal with your reading list.
Send us feedback: [email protected]!
P.S. As a side effect, we also took the first steps towards opening up Refind for developers: https://refind.com/developers
P.P.S. Can you please build a Refind bot for Slack? :)
react to story with heart
react to story with light
react to story with boat
react to story with money
L O A D I N G
. . . comments & more!