# Troubleshooting

## Incoming SMS: Required parameter params['to'] missing

This usually means the app received an SMS webhook without a `From` phone number.

Check:

- Twilio Messaging webhook is set to `POST`.
- Webhook URL is exactly `https://YOUR-PUBLIC-URL/sms/incoming`.
- You are testing by texting the Twilio number from a real phone.
- Manual curl tests include `From=+17345550123`.

## Twilio 401 / 20003 Authentication Error - invalid username

This means Twilio rejected the credentials in `.env`.

Check:

- `TWILIO_ACCOUNT_SID` starts with `AC`.
- `TWILIO_AUTH_TOKEN` is the Auth Token from the same Twilio project as the Account SID.
- You did not use an API Key SID as the Account SID.
- You did not leave placeholder values like `ACxxxxxxxx`.
- You restarted the app after changing `.env`.

Run:

```bash
npm run check-config
```
