Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
1.1k views
in Technique[技术] by (71.8m points)

api - Nexmo autoreplay on income sms

Is there any option to auto replay on income SMS or send automatically replay for example "SMS not delivered" or something like that? For example, the app sends some customer SMS and he replays on that number. We do not want to get income SMS from customers on that number because it is a virtual number.


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Reply

0 votes
by (71.8m points)

You would need to set up a webhook that forwards the SMS to an application, and that application can respond with an appropriate error message. Examples on how to process a request can be found at https://developer.nexmo.com/messaging/sms/code-snippets/receiving-an-sms

You can do this in two ways. One is to edit the number directly and set an "Inbound Webhook URL". Log into your dashboard, go to "Numbers", and then click the pencil/edit icon next to the number you are sending from. You can then fill in the URL that is listening for SMS messages under "SMS".

The second option is to set a fallback URL for all SMS messages. This is done by going to your account Settings page, and then filling in the "Inbound messages" box under "Default SMS settings". This URL will then forward any SMS to the webhook URL on any number that does not have a bespoke webhook assigned.


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
OGeek|极客中国-欢迎来到极客的世界,一个免费开放的程序员编程交流平台!开放,进步,分享!让技术改变生活,让极客改变未来! Welcome to OGeek Q&A Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...