-
Notifications
You must be signed in to change notification settings - Fork 64
Description
hello, i am currently facing an issue when trying to send messages in arabic with the message bird api. it works perfectly fine with other languages but not arabic.
here's a code snippet:
`
import messagebird
import arabic_reshaper
def send_msg(receiver, expiration_date):
if receiver == NULL:
pass
else:
expiration_date = expiration_date[::-1]
text = f"عزيزي العميل ، ينتهي اشتراكك في XXX غدًا بتاريخ {expiration_date}، لتجديده ، يرجى الاتصال بنا."
reshaped_text = arabic_reshaper.reshape(text)
rev_text = reshaped_text[::-1]
client = messagebird.Client("XXXXXXXXX")
message = client.message_create('XXXXXTest',
f'{str(receiver)}',
rev_text,
{ 'reference' : 'Foobar' }
)
`
i tried using arabic reshaper module and when i print the "rev_text" in the terminal it works perfectly fine, meaning that it is shown the way it is expected
but when i receive the message on my phone, there are no arabic characters what so ever, as if they were deleted entirely, meaning i only receive the expiration date and the "XXX" and nothing else. please view the image below to understand what i mean.
