Kogno
Search…
deep_link
If it's defined, this action block will be executed if the chat was opened through a link that contains a deep-link query string parameter.
The query string parameters are ref for Messenger and start for Telegram.
To learn more, please read the official documentation from Messenger and Telegram.

Platforms

Platform
Supported
Messenger
WhatsApp
Telegram

Example Links

Usage

class MainContext < Conversation
def blocks
deep_link do |value|
@reply.text("You just clicked on a link with the value #{value}!")
end
end
end

value param

This param contains the value passed in the query string, for the example links above, the value is "test"

Routing to Context

A deep-link can be handled by other context different than the default context, simply by passing the name of an existing context as a part of the parameter value:
Messenger: ?ref=context_name_some_value
Telegram: ?start=context_name_some_value
Read more about this in Context Routing chapter.
Last modified 2mo ago
Copy link
On this page
deep_link(&block)
Platforms
Example Links
Usage
value param