telegram

Gateway from Telegram messenger into flespi acts as a Telegram bot that receives text and location messages from users and delivers them into a flespi channel. There is a command to the channel to send text message back to user from bot.

Please read detailed instructions on how to create and use this channel.

flespi team created @WialonHostingBot  for demo purposes that you may use to forward location and text messages to Wialon Hosting in 1 click. To receive messages into Wialon units create the unit of flespi gateway type and enter the unique ID given by the bot. With this protocol you can create similar channels and configure them the way you want.

Below is the list of parameters that can appear in the messages received by the channel via telegram protocol. In most parameters, the name consists of tags split by dots: tag1.tag2.tag3.tag4... Each tag defines a certain area of an application, e.g. any parameter that contains mileage data has the 'mileage' tag in the name and any parameter related to fuel control contains the 'fuel' tag. By default JSON fields of the message received by a channel via this protocol can only contain the below-specified parameters. Any additional parameter will be prefixed by the "custom" tag, e.g. "custom.unspecified-name".

Name Type Unit Description
channel.id number ID of channel that received message
chat.id integer User's chat identifier
device.id number ID of device that received message
device.name number Name of device that reveiced message
device.type.id number ID of device type of device that recevied message
driver.message string Driver text message content
ident string Device unique identificator and optional password
image.bin.jpeg string Image binary data in JPEG format, base64 encoded
position.latitude number degrees Latitude coordinate value
position.longitude number degrees Longitude coordinate value
protocol.id number ID of protocol
server.timestamp number seconds Timestamp when server received message
timestamp number seconds Message timestamp

Below is the list of commands that can be sent to devices to change their configuration or to send signals to various outputs. When sending a command you can specify the transport type defining how the command will be delivered - the address parameter can take values connection (via network connection once the device goes online), sms (via SMS message), push (via PUSH notification). A comprehensive format of each command with all possible parameter values, parameter types, default values, etc. can be found in the REST API documentation in your flespi.io account.

Title Name Description Properties
Send a message to the user message Send a text message to the user, using bot api https://core.telegram.org/bots/api#sendmessage text: Message text to send

parse_mode: Telegram's parse_mode parameter
Simple message
{"text":"Hello, flespi user!"}
Message with Markdown
{"text":"Hello, *flespi* `user`!","parse_mode":"Markdown"}
No results found.