MrHertal / react-native-twilio-phone

Twilio Voice React Native module.
MIT License
153 stars 66 forks source link

Push notification payload #77

Closed vjhameed closed 2 years ago

vjhameed commented 2 years ago

Hey

Great library so far., But could you drop the payload of the fcm push notification. below is what i send but i still keep getting the error saying invalid Twillio voice sdk payload

{"message": "Incoming call from +923180913302", "token": "eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCIsImN0eSI6InR3aWxpby1mcGE7dj0xIn0.eyJqdGkiOiJTSzIzZWMwODM3YmE2MjUxNGQ5MTVmMjAyYTJlZTRlNjhlLTE2NDQ0MzU1NDQiLCJncmFudHMiOnsiaWRlbnRpdHkiOiIrOTIzMTgwOTEzMzAyIiwidm9pY2UiOnsiaW5jb21pbmciOnsiYWxsb3ciOnRydWV9LCJvdXRnb2luZyI6eyJhcHBsaWNhdGlvbl9zaWQiOiJBUDcxN2RmODA5YWI4Mjk4ZTgzODc2MzY5NDZlOTc5MjBkIn19fSwiaWF0IjoxNjQ0NDM1NTQ0LCJleHAiOjE2NDQ0MzkxNDQsImlzcyI6IlNLMjNlYzA4MzdiYTYyNTE0ZDkxNWYyMDJhMmVlNGU2OGUiLCJzdWIiOiJBQzdmYmRmYmU4OTA3M2U3MTY3MWFlNDEwYTU5NWYzODMxIn0.AWEX3XMWb08M-Nlus-qmFwe-EMIF-eFy0GSHrh8s7Uw", "twi_account_sid": "AC7fbdfbe89073e71671ae410a595f3831", "twi_call_sid": "CAacd9b8e1ed21499e0080d19cfd531e88", "twi_from": "+923180913302", "twi_message_id": "", "twi_message_type": "twilio.voice.call", "twi_to": "client:+18664171554"}

vjhameed commented 2 years ago

if you could please help with this that would be really great

MrHertal commented 2 years ago

Hi,

FCM notification is sent by Twilio, you must have something wrong in your Twilio server configuration.

Beware not publishing sensitive information like the token or your Twilio account sid...