I have a server side Blazor website with an API set up for Twilio. I have Twilio pointing to the correct endpoint, and when I call it in Postman it works. However when I send an SMS in the API is never hit, why is that?
using Twilio.AspNet.Common;namespace Webapp.Services.Controllers.API{ [Route("api/[controller]/[action]")] [ApiController] public class TwilioAPIController { [HttpPost] [AllowAnonymous] public void ReceiveSms(SmsRequest message) { Logger.Log("Received SMS message: " + Newtonsoft.Json.JsonConvert.SerializeObject(message)); } }}For reference, here is the Postman body that is working:
{"MessageSid": "","SmsSid": "","Body": "Hello","MessageStatus": "","OptOutType": "","MessagingServiceSid": "","NumMedia": 0,"ReferralNumMedia": 0,"accountSid": "removed","From": "+11234567890"}