From 465d15851d3e838bc4a8147eee869b672c9f45ba Mon Sep 17 00:00:00 2001 From: Dylan Cutler <13906920+DCtheTall@users.noreply.github.com> Date: Fri, 13 Mar 2020 13:06:53 -0400 Subject: [PATCH] fix: Add method overload to VoiceResponse.prototype.play (#544) --- examples/typescript/example.ts | 1 + lib/twiml/VoiceResponse.d.ts | 6 ++++++ 2 files changed, 7 insertions(+) diff --git a/examples/typescript/example.ts b/examples/typescript/example.ts index 8a6248570a..032250f664 100644 --- a/examples/typescript/example.ts +++ b/examples/typescript/example.ts @@ -129,3 +129,4 @@ promiseMessage.then(messages => { const twiml = new twilio.twiml.VoiceResponse(); twiml.dial({}, '+12345678901'); +twiml.play('https://demo.twilio.com/docs/classic.mp3'); diff --git a/lib/twiml/VoiceResponse.d.ts b/lib/twiml/VoiceResponse.d.ts index 847d309b68..62134388a5 100644 --- a/lib/twiml/VoiceResponse.d.ts +++ b/lib/twiml/VoiceResponse.d.ts @@ -75,6 +75,12 @@ declare class VoiceResponse { * @param url - Media URL */ play(attributes?: VoiceResponse.PlayAttributes, url?: string): void; + /** + * TwiML Verb + * + * @param url - Media URL + */ + play(url?: string): void; /** * Twiml Verb *