Rocket.Chat.Kotlin.SDK icon indicating copy to clipboard operation
Rocket.Chat.Kotlin.SDK copied to clipboard

[NEW] Send Location

Open mohanadrefaai opened this issue 6 years ago • 3 comments

Add feature to send a location specified by Latitude and Longitude

mohanadrefaai avatar May 20 '18 07:05 mohanadrefaai

@mohanadrefaai What's the REST API to send this information?

rafaelks avatar May 21 '18 11:05 rafaelks

@rafaelks I think it is an Attachment type.

luciofm avatar May 21 '18 12:05 luciofm

@rafaelks It is the same API to send message (/api/v1/chat.sendMessage). We just need to add "location" param to the body of the request and the format is like that: "location": { "type": "Point", "coordinates": [ long, lat ] } It will be great also to receive message with location field to map it.

@luciofm No it is not an Attachment type. Location is sent as a separated field AFTER enabling it on the server in Message section, enable GoogleMap.

mohanadrefaai avatar May 21 '18 13:05 mohanadrefaai