Create telegram channel in nodejs or angular - angularjs

Is it possible to have a link,a button, or similar on a website that permits to create a new channel?
E.g., when I click on the link, I send a message with my credentials (phone number is enough i tihink, but not sure) that says "create a new channel called foo".
Is that possible (and if, how can I do that)?
I searched in the telegram API but I had no clue..
I also found this but I have no idea how to do what I want.

Related

Is it possible to detect users click emoji on specific channel for specific server?

I think I need some answer from discord api experts.
I'm wondering if someone can detect using bots below logics.
If we enter the server, we will have initial channel. (for example Welcome)
There some rules will be described and we will have emojis like check / symbols for the server.
And after user click, bot can detect the user id and can send direct message to him/her.
Is it possible for the outside guy of the server? (I mean without any discord related api key)
Thanks
Since I don't have exp with this just went through the discord docs, but didn't find proper resources.

Can I create an app or a bot in discord that send messages as it was me?

I want an app/bot that reads the last message that were sent to a specific channel on a server that I participate and depending on the text I want to send a message to that same channel. The thing is, I want to do it in my name, not using a bot id. I know that you can create a bot using your own name and avatar but what I really want is to send a message using my own account. Is that possible? Could not find anything like that in the docs, maybe a missed something?
I do not think you are even allowed to do this so I doubt the discord API would have support for this
Discord Guidelines
"Do not use self-bots or user-bots. Each account must be associated with a human, not a bot. Self-bots put strain on Discord’s infrastructure and our ability to run our services. For more information, you can read our Developer Policies"
However, if you really wanted to do this you could use a macro at the risk of getting your account banned by discord if they found out. You could create a macro in python using the pyautogui module.

creating a link that will open facebook messenger and send a message

i'm creating a registration code for users to a facebook messenger bot i am writing.
instead of asking them to open a chat with my bot, and type in the registration code, i would like to provide them a link that will open their facebook messenger on a chat window with my bot, and send the registration code automatically.
i saw a link that opens the chat window (https://m.facebook.com/messages/compose?ids=USER_ID) but can't get it to send a message too.
if you know how to do that, or have an alternative suggestion, i would appreciate the help.
Check out the new referral webhook-reference. It gives you a way to link users directly to your bot with support for passing arbitrary parameters via the link.
So a possible approach would be:
Make sure your bot is subscribed to the messaging_referral event.
Craft your bot's m.me link to include the registration code in the ref param e.g http://m.me/mybot?ref=REGISTRATION_CODE. if you're interested in security you might consider encrypting the code
Send the link(s) to the user. When the user click's the link, they're directed to your bot on messenger and once they initiate a session with your bot, you'll receive a messaging_referral event at your webhook with a payload similar to
{
"sender":{
"id":"USER_ID"
},
"recipient":{
"id":"PAGE_ID"
},
"timestamp":1458692752478,
"referral": {
"ref": "REGISTRATION_CODE",
"source": "SHORTLINK",
"type": "OPEN_THREAD",
}
}
You can then evaluate the ref value and send your desired feedback to the user.
Every messenger app use it's own link. For facebook https://m.me/XXXXXXXX where XXXXXXXX - page name.
I always use https://msng.link/fb-messenger.html for generation FB link. Better to remember one website and genereate all messengers what you need.

Facebook Messenger: Is it Possible to Initiate Chat With Parameters?

Back in the day Facebook used to let you define URLs that were something like http://facebook.com/send_a_message/user/55/pre_fill/Hi there. When you clicked that link Facebook would open up its Messenger with a "Hi there" message ready to be sent to user 55.
But then Facebook decided that "pre-filling" was bad, and outlawed it across all their APIs. Now there are a bunch of different ways to initiate a Messenger chat session, but they all amount to "start a chat with user 55", not "start a chat with user 55 using some information".
The thing is, I'd like to somehow pass information along with the link. For instance, I might want to have three different links on three different pages, and I want my chatbot to be able to respond differently based on which page the user came from. Since I can't "pre-fill" a message (eg. "Hello, I just came from page A"), I'm wondering if there is any other way to pass auxiliary information.
TLDR
I'm wondering if there's any way I can possibly provide a user with a link that, when they click it, starts up a chat session with my chatbot user, and somehow passes information to it. Using an intermediate proxy (ie. having the link go to my server, and then have my server start the chat somehow) would work, but only if I can associate the information with the user (ie. it doesn't help to know "page A" if I can't associate that with the user once they start chatting).
After researching further it would appear that the answer to my question is no: there is currently no way to pass-along supplemental information.
But here's the good news: when I filed a bug about this (which it turns out I should have filed as a feature request, sorry Facebook) I got a response saying something to the effect of "we couldn't tell you that we are currently developing this, even if we were", which I'm going to optimistically choose to interpret as a sign hope means that this functionality may be coming in the future.

Open Gmail Client With File Already Attached

I see you can send emails with uploaded attachments using the Google Gmail API. However, I want the user to be able to preview the email before sending. It looks like there isn't a way to do this?
So essentially would the only solution be to create my own simple email client, then send the email through the API? Or would using the API even be necessary as in that case I could just use the server's native sendmail client to sent out the email with the user's gmail address as the return address.
I guess using the API, the advantage is the email would appear in the user's SENT folder.
Unfortunately, I don't think there's a live preview that's available in a way you intended. As far as I know, Outlook (for reference) doesn't even have it. What they have is to upload the attachments while the mail is still being drafted.
The best I can think of is once the message will be sent, save it as draft at first and retrieve the mail again on the succeeding page. This will look like a preview that you intended. Once done, you can then finally send the drafted email to the receipients.

Resources