Use slash commands in Slack with Bot Framework? - telegram-bot

I'm just getting started with the Bot Framework and can't find any reference to supporting slash commands with it? Is this supported for Slack and other clients?

The short answer is "it depends".
The Slack's slash command API is completely separate to the Bot API. You can add an additional api controller and trigger bot conversations from that API. You'll need to connect Slack directly to your bot, not via the Microsoft's middleware. This is actually the same as what you'll do with Slack's native BotKit.
In telegram you can register a custom command using the #BotFather's /setcommands command. After you've registered a custom command the telegramm will show you the select box as soon as you type / in a chat. When you'll invoke a "command" it will be passed to a bot as a regular text message, and you can start the conversation from that point.
For the channels, where the slash commands do exist, but are not extendable (Skype for ex., or in Slack), you can use fake commands by using a space (" /hello") or dot ("./hello") symbols before the slash, and handle these messages as commands.

Related

Dialogflow Account linking breaks the flow

I'm developing a chatbot in Dialogflow for Google Assistant, I made sign-in compulsory(using authorization code flows) in Account Linking Section from Actions on Google using this official documentation, so when I invoke a bot it asks for a sign in if a user not already signed in.
After the sign-in, it breaks the flow, and I need to again invoke my bot as shown in this image.
I want to make this flow continuous, instead of invoking a bot again, it should open the Default Welcome Intent once the linking process finished.
This is my linking setup
PS: I'm using python webhook for processing queries of other intents
but not for Default Welcome Intent.
This is my integration setup
It would be better to use Google Signin to handle Account Linking. It does not break the flow and you can access user profile details in parameters of your intent webhook.
Reference:
https://developers.google.com/actions/identity/google-sign-in
please make sure,
you have entered a valid callback URL.
your backend server(where authentication happens) should redirect to provided callback URL

Telegram bot authentification

A web service that contains all the methods for processing data is stored by Azure. In this case, only my telegram can process this data. Other applications are not allowed. But there is a possibility of expanding the service.
How do I know that the service is used by my telegram bot?
How to authenticate the application.
Well, I tried to use OAuth2.0, but i think it is not correct, because user is already authentificated with telegram, when he use telegram bot. My idea was to send a link to google auththentification in the beginning of bot job. By th way, ok, we know user`s data. May be I can check: Id, login etc. But some hacker can substitute this id
How can I make sure that Webhook requests are coming from Telegram? If
you‘d like to make sure that the Webhook request comes from Telegram,
we recommend using a secret path in the URL you give us, e.g.
www.example.com/your_token. Since nobody else knows your bot’s token,
you can be pretty sure it's us.
Telegram Bot FAQ

Why can't I connect to my bot framework using the end point API

Hello I'm currently trying to set up the bot framework from Microsoft, so I can call this from my REST API.
I created the bot framework using the portal from Microsoft and integrated LUIS into it. This part is not the problem, but when I try to call the end API I get 401 unauthorized with the message "BotAuthenticator failed to authenticate incoming request!". I tried this in Postman and CURL and both give the same response.
I've been searching on the web and saw that you need to pass a bearer token in the header. For this I used the login services from Microsoft and successfully got a token from it.
Even with this token in the header I keep getting the same response. I also tried using the bot emulator from Microsoft with the same Microsoft ID and Password, but here it seems to work.
Am I forgetting something important or do I have to change some settings in order to make this work outside the bot emulator?
You usually talk to your bot through one of the available channels and not directly to the bot implementation. If you want to talk to your bot through a REST API, you would need to use the Direct Line API. Did you enable the Direct Line Channel? Please have a look at the samples here - https://learn.microsoft.com/en-us/azure/bot-service/rest-api/bot-framework-rest-direct-line-3-0-concepts

Add dropbox webhook by code

We're exploring dropbox api reference. Concretly, we're exploring webhook possibilities.
We're not quite to know how to specify a webhook url by code.
We are lokking for a way to add this webhook url avoiding user has to do it manually.
I hope I've explained so well.
It's not possible to programmatically register a Dropbox webhook URI. We'll consider it a feature request.
Developers should register their webhook URI(s) manually via the App Console. Those webhook URIs will stay registered and will be used for all users connected to the app.

Instapaper Simple API : adding links without storing user password?

I'm trying to use Instapaper's Simple API (http://www.instapaper.com/api/simple).
The API terms of use (http://www.instapaper.com/api/terms) says apps should not store user id and password, and I don't want to store them either. However, it seems that the only way to add a link to a user's Instapaper via simple API is to store the username/password (if the user does have a password).
Am I missing something?
The API terms of use state that:
Apps must not store users’ passwords. Passwords may only be collected for the xAuth token acquisition and must be discarded afterward.
Only the full API uses xAuth tokens. The above sentence doesn't apply to the simple API, since it uses Basic HTTP Authentication.
You still "must make reasonable efforts to prevent passwords from being compromised, and must not disclose passwords to any other services or individuals".
If you are using a native Mac application (like Apple’s Mail client or a third-party mail client like Airmail) there isn’t an easy way to save a link to Instapaper without first opening the link in a browser and then using one of Instapaper’s browser extensions to actually save the article.
One workaround that I’ve found to expedite this task is to write a service for OS X which uses Instapaper’s API to save links.
In order to write your own service, first open Apple’s Automator application and create a new Service. Then, drag the Run Shell Script action into the application’s main workflow area.
Make sure the service receives no input, can be used by any application, and that the shell script is set to run python.