message.received event to your messaging profile’s webhook, and your Edge Compute function is that webhook. Replying to another Telnyx number is on-net — no 10DLC campaign required.
1. Write the handler
func.toml (see the Quick start):
2. Ship
3. Point a messaging profile at it
Set a messaging profile’s inbound webhook to your function URL, then assign your number to that profile:4. Test on-net
Send from another Telnyx number on your account to your function’s number:GET https://YOUR-FUNC.telnyxcompute.com shows what arrived. The inbound event the function parses looks like:
Only on-net replies skip 10DLC. Receiving is always free. Replying to a Telnyx number is on-net (no campaign). Replying to an off-net number — e.g. a personal mobile — is application-to-person traffic and requires 10DLC registration.
Keyword auto-reply
The handler above echoes every message. To answer commands instead, replace themessages.send call in step 1 with a keyword match: