We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 0c2bdf3 commit 299674bCopy full SHA for 299674b
app/routes/sms.tsx
@@ -0,0 +1,13 @@
1
+// https://www.twilio.com/docs/usage/webhooks/messaging-webhooks#incoming-message-webhook
2
+import { type ActionFunctionArgs } from '@remix-run/node'
3
+
4
+export async function action({ request }: ActionFunctionArgs) {
5
+ const body = new URLSearchParams(await request.text())
6
7
+ console.log(Object.fromEntries(body))
8
9
+ return new Response(
10
+ `<?xml version="1.0" encoding="UTF-8"?><Response></Response>`,
11
+ { headers: { 'Content-Type': 'text/xml' } },
12
+ )
13
+}
0 commit comments