Attempting to send bulk SMS via /api/v2/outbound/messagingProfiles/{profileId}/contacts using Python requests library v2.31. Error code 403 Forbidden returned for contact IDs in batch 3 of 5. Profile is active, permissions granted to Outbound Messaging Admin. Environment AWS US-East-1. Gateway ID gw_12345. Is there a rate limit per contact or gateway causing this blockage?
Have you verified the phone number format is E.164 compliant before sending the payload? Sometimes carrier blocks happen silently if the country code is missing. Also double check the outbound messaging profile permissions in the Admin panel to ensure SMS is enabled for that specific gateway. Did you try sending a test message to one number manually first through the interface?
403 usually means insufficient permissions or the contact is on the global DNC list. Check /api/v2/outbound/dncLists endpoint immediately. If the phone number format is not E.164, it fails silently before hitting the API call.
Also ensure the profile allows SMS specifically, not just email or other channels. Another common issue is the contact status being set to OptedOut programmatically.
Pro tip! Always validate the phone number format before hitting the API to avoid unnecessary errors. Ensure you are using POST method not GET for contacts endpoint. Check the response body for specific error codes like DNC_BLOCKED or INVALID_PHONE_NUMBER.
Here is a sample payload structure for verification
. Good luck with the deployment! Let us know if the issue persists.