twilio-opencode

A lightweight express server to handle Twilio voice and messaging webhooks for prompting Opencode.
git clone https://unitehenry.com/git/twilio-opencode.git
Log | Files | Refs | README | LICENSE

commit ca3b42f1da1e37768d8295daf271cbcbb2eed43f
parent aa7f50c125f69325f05d16752c82930542fbe8c3
Author: Henry Unite <henry@getpoint.io>
Date:   Thu, 26 Feb 2026 09:16:27 -0800

feat: log from

Diffstat:
Mlog.ts | 4++--
Mvoice.ts | 4+++-
2 files changed, 5 insertions(+), 3 deletions(-)

diff --git a/log.ts b/log.ts @@ -1,10 +1,10 @@ type LogLevel = "INFO" | "WARN" | "ERROR"; -export default function log( +export default ( level: LogLevel, message: string, data: Record<string, any> = {}, -): void { +): void => { const time = new Date().toISOString(); const entry = { diff --git a/voice.ts b/voice.ts @@ -17,7 +17,9 @@ export default async (req: Request, res: Response): Promise<void> => { const callId: string = req.body.CallSid; - log("INFO", `Call webhook received`, { callId }); + const from: string = req.body.From; + + log("INFO", `Call webhook received`, { callId, from }); const speechResult: string = req.body.SpeechResult;