From the course: Calling REST APIs with Java

Unlock the full course today

Join today to access over 22,400 courses taught by industry experts or purchase this course individually.

Calling the Twilio API with Feign

Calling the Twilio API with Feign - Java Tutorial

From the course: Calling REST APIs with Java

Start my 1-month free trial

Calling the Twilio API with Feign

- [Instructor] To further explore Twilio and feign, we're going to send ourselves a phone call using the voice API. Now, one important thing to note about Twilio's API is that it doesn't use json. It's going to use form data to send things like phone numbers or the strings for a text message. To support that in Feign, I've had to add another artifact into our palm dot XML file. So here you'll see that I've included the feign form dependency, which is going to allow us to work with form data in feign. Now to get started with feign, we can build a client within the comm dot LinkedIn dot API dot Twilio package. So just open up the new dialogue and we'll create an interface and we'll name that interface Twilio client. Inside of this interface, we're going to create a method that returns void. We're not going to be interested in the response we get back from Twilio. We just want to send the call out. I'm going to name…

Contents