From 306febe4d1a371adb2851bef87abb4f963499778 Mon Sep 17 00:00:00 2001 From: m5r Date: Fri, 13 Aug 2021 23:56:07 +0800 Subject: [PATCH] rename webhook route for calls --- app/onboarding/api/queue/set-twilio-webhooks.ts | 4 ++-- app/phone-calls/api/webhook/{incoming-call.ts => call.ts} | 0 2 files changed, 2 insertions(+), 2 deletions(-) rename app/phone-calls/api/webhook/{incoming-call.ts => call.ts} (100%) diff --git a/app/onboarding/api/queue/set-twilio-webhooks.ts b/app/onboarding/api/queue/set-twilio-webhooks.ts index d91edb9..561f128 100644 --- a/app/onboarding/api/queue/set-twilio-webhooks.ts +++ b/app/onboarding/api/queue/set-twilio-webhooks.ts @@ -61,7 +61,7 @@ async function getTwimlApplication( friendlyName: "Shellphone", smsUrl: `https://${serverRuntimeConfig.app.baseUrl}/api/webhook/incoming-message`, smsMethod: "POST", - voiceUrl: `https://${serverRuntimeConfig.app.baseUrl}/api/webhook/incoming-call`, + voiceUrl: `https://${serverRuntimeConfig.app.baseUrl}/api/webhook/call`, voiceMethod: "POST", }); } @@ -70,7 +70,7 @@ async function updateTwimlApplication(twilioClient: twilio.Twilio, twimlAppSid: await twilioClient.applications.get(twimlAppSid).update({ smsUrl: `https://${serverRuntimeConfig.app.baseUrl}/api/webhook/incoming-message`, smsMethod: "POST", - voiceUrl: `https://${serverRuntimeConfig.app.baseUrl}/api/webhook/incoming-call`, + voiceUrl: `https://${serverRuntimeConfig.app.baseUrl}/api/webhook/call`, voiceMethod: "POST", }); diff --git a/app/phone-calls/api/webhook/incoming-call.ts b/app/phone-calls/api/webhook/call.ts similarity index 100% rename from app/phone-calls/api/webhook/incoming-call.ts rename to app/phone-calls/api/webhook/call.ts