Forum Discussion

surionah's avatar
surionah
Copper Contributor
Aug 03, 2021

Send images using Chat SDK

Is it possible to send images as messages using the Chat SDK of azure communication services? As far as I read it only supports messages as strings, and they have a limit of 28,5K characters approximately, so I tried to send images as Base64 but the result strings have more than the supported maximum characters, so I get the next error:

Failed at getting messages, Error:  RestError: {
  "CommunicationError": {
    "Code": "BadRequest",
    "Message": "Message size exceeded.",
    "Details": []
  }
}

Any help would be really appreciated

  • Hi surionah!

     

    Thanks for your interest in Azure Communication Services! As of now, it's not possible to send images directly in chat but you can send a URL that points to your image. Let us know if you are running into any other issues!

Resources