Manage dog walkers

Build an app to manage dog walkers and text them if there is bad weather.

Let's say we're a dog-walking company, and we want to inform our walkers that their walks tomorrow are cancelled due to an incoming snowstorm. We'll build a tool to text our dog-walkers informing them of the news in 5 minutes.

1. Pull in walkers

Let's start with an API request to get all our dog walkers. Make a REST API resource to GET the data from your server. For this demo, we'll use a mock server. Press run (or or ⌘⏎) to preview the request.

We can preview the query results.

Great! You can see list of users under the result key.

Now, let's load this data into a table to make it easier to view. Drag a table component from the right hand side onto the canvas. Set the data value to {{ }} to load the table with the results from our query.

A table loaded with the query data.

We're off to a good start.

2. Send them text messages

Now that we have our walkers loaded into the table, we want to add an action button. Scroll down in the table options, and click the Action toggle. Set the action button text to something like "Text walker".

You can see the button appear in its own column on the table.

Now, let's write a query to connect to this action button. We will use the Twilio Message API to send these texts. Create a new query, and call it sendWalkerMessage. Set the resource to your Twilio integration. Pick the POST Message path from the operation list. You should see a list appear, automatically populated with the request parameters. Set the from number to your Twilio number, and AccountSID to your Twilio account SID. The body is the message you want to send your walker. We can dynamically set the to field to the walker's phone number with JavaScript using our {{}} notation. The expression here is {{ }}.

A preview of the values for our Twilio API request.

That's it! You can test the query out by pressing the Text walker button. It will send your walkers a text!

3. Actually Using it

This tool is now production-ready. If you don't want coworkers bugging you about contacting dog walkers, send them a link to this tool. You can also use the Twilio API to keep track of which users have responded to your texts, and extend your tool to your needs! If you want, you can change permissions Not bad for a few minutes of work.