Rocket.Chat
Rocket.Chat copied to clipboard
LiveChat-Widget adds an extra URL prefix when sending image URL
Description:
I am developing a Rocket.Chat App using the AppEngine. When using the LiveChat-Widget to forward an image or audio from an external source (like botpress), it somehow adds an extra URL prefix. Is there a way to force LiveChat-Widget to not add the prefix?
Steps to reproduce:
- create an IMessageAttachment object with an image URL
- add object as an attachment to IMessageBuilder
- send message to LiveChat
Expected behavior:

- Bot send the Image correctly (I logged in bot account and sent the image and audio manually)
Actual behavior:

- The correct imageUrl is "http://localhost:3001/api/v1/bots/lab/media/see8z47e13k5o43aaovn-cat.png" but sent imageUrl is wrong as you can see in Elements. (I think LiveChat-Widget added "http://localhost:3000" to original Url)

- But as you can see in Rocket.Chat, actually bot sent the image correctly
Server Setup Information:
- Version of Rocket.Chat Server: 4.8.0
- Operating System: Ubuntu 22.04.1 LTS
- Deployment Method: Docker
- Number of Running Instances: 7
- DB Replicaset Oplog: Enabled
- NodeJS Version: 14.18.3
- MongoDB Version: 4.4.14
Client Setup Information
- Desktop App or Browser Version: Chrome 104.0.5112.79 (Official Build) (64-bit)
- Operating System:
Hey, Would love to work, assign it to me. I am pretty new to this project. Can anyone point me out on what folder to look at. Thanks!