-
Notifications
You must be signed in to change notification settings - Fork 0
Sessions
Greenbot tracks Bot sessions. When a person texts into the bot for the first time, a session is created. During the session, Greenbot will keep a record of all of the messages to and from the bot. Also, if the bot collects structured data, it can save that in the session as well. For instance, bash bots can provide data to save by emitting a valid JSON string to stdout. (These JSON strings are not sent to the far end, they are simply recorded as part of the session). When the bot exits, the session is completed, and notifications happen.
Sessions are defined between two endpoints - the near and far end participants. Each participant is identified by a network handle - a combination of the network name and an endpoint identifier. Examples are twitter::@howethomas or nexmo::15085551212. When a session starts, it's always between these two unique identifiers. You cannot have more than one simultaneous session between any unique endpoints.