auto sending mails by server at specific intervals - email

I am looking for some code, which I could send mails out of my website.
I want the user's registered in my website, to be able to automatically send emails at specific time, that's defined by the user. I need a triggering mechanism in asp.NET such that it fires the exact date & time as specified by the user
Any suggestions/approach apart from the above statement is also welcomed.
I have found a solution for the problem, and would kindly request the moderators to delete the post.
Thank you

Asp.Net is not the correct framework to perform scheduled tasks.
You can use Asp.Net for a web interface in which you allow the users to create "tasks", set the timed intervals and even the content of the emails.
BUT - The process which sends the emails should probably be done using a task scheduler...
Here is a post to point you in the right direction...

Related

Is is possible to create a custom messenger bot on Facebook?

I would like to know that we are having a lead generation campaign running on Facebook but few of the times our staff isn't available to answer the query on Facebook messenger, so based on that short-coming I am thinking to devise a mechanism that "If within 1 hour of user's message no one replies to him then an automated BOT message should get sent to him."
Please don't deprecate this question as it is based entirely on knowledge. And if perhaps someone has hints or links on how to achieve this thing then I will really appreciate it.
Thanks.
Some options:
You can query your /conversations edge every X minutes to detect when there is a message from a user which has not been replied to, then you would send the automated message using Send API.
https://developers.facebook.com/docs/graph-api/reference/v10.0/conversation
https://developers.facebook.com/docs/messenger-platform/reference/send-api/
You can use webhook data for incoming messages to create a task that will run at received_time + 60 minutes, find the thread in your conversations edge based on PSID and then check if there has been a reply
Alternatively you can check out Handover Protocol which allows a Page to simultaneously use a Messenger Bot and Live chat agent to handle messaging
https://developers.facebook.com/docs/messenger-platform/handover-protocol/

Keycloak: how to send email to admin upon user registration / how to create a custom execution for sending email

I want to alter the User Registration flow to allow for emailing someone when there is a user registration. For altering the flow, this question provides an example.
However, in my case, there is no execution I could add out of the box to email someone other than the user. How can I go on to create a custom execution for sending email in order to send email to admin upon user registration?
Alternatively, I could start continuously polling the list of all users and diff it. This solution using the python-keycloak would be similar to what is described here but for my case, it seems both inefficient and cumbersome, the cron job would have to run all the time.
Any other way to solve this problem also welcome!
Unfortunately, I suppose this feature is not (yet?) supported
If i get your question correctly, you want to be notified by mail when someone creates an account? if so you can implement that in your code by checking for the keycloak response(200 or 201) after account creation and then you notify the necessary email. You can integrate with sendgrid.

How to send DokuWiki notification mails at certain time?

In our DokuWiki Installation (Release 2018-04-22b "Greebo"), users can subscribe to daily notification mails, which is a core feature of DokuWiki.
For those daily emails, we would like to make sure that they arrive at a certain time.
In the documentation, I did not find anything about a script that could be started (i.e. from a cronjob) to send out mails.
I set up a cronjob calling a freely accesible page in the wiki using curl (no login required for this page). This did not cause emails to be send.
Any hint on how to schedule daily emails to be send at a certain time would be helpful!
Update: I am aware of .../feed.php, which would theoretically allow to get information on wiki events using the RSS feed. This data could be used to send notification mails. However, the RSS feed would need to be generated for every user to respect access right. For this to work, some sort of user credentials - or a copy of the user's access rights - would need to be copied to a place outside of dokuwiki and kept in sync.

Facebook Messenger Bot - How to disable bot and allow human to chat

so this is something I've been trying to think through for about 16 hours. I am coding with PHP / CuRl / etc - the bot works and everything is fine. My current issue is figuring out how to disable the bot and allow a human to begin chatting with the customer/sender.
Has anyone successfully, created a route for this ? I mean it's pretty hard from what I see, you'd have to disable etc etc. A lot of effort for my clients.
Thanks for any input.
Facebook has rolled out a "Handover Protocol" which is supposed to facilitate a combined human/bot Messenger implementation.
https://developers.facebook.com/docs/messenger-platform/handover-protocol
It is a little unclear what actually occurs in step 5:
Pass thread control: At some point in the conversation, a user may choose to do something like interact with a live agent. To handle this, pass thread control from the Primary Receiver to the Secondary Receiver. The Secondary Receiver will receive a messaging_handovers webhook event to notify it that is now controls the conversation.
This doesn't actually disable the bot (as the OP requested), and isn't in the control of the Page owner but rather of the user. It seems FB envisions the user typing something like 'I would like to chat with a human' triggering the bot to pass control...but it would be nice to let the page owner simply put the app in standby and handle the messages herself.
Once you recognize someone wants to speak to a human, set a flag that disables all actions of your bot to on.
Then, have your bot message you, or whoever will respond, that a user ID needs responding to. Have your bot continue to send all messages received from them back to you until you enable the bot again.
Create some sort of way for your bot to interact with you that allows you to send a message to a specific user, and a way to once again enable the bot interaction with the user.
Probably something like "sendMessage104012301230'Hi, sorry you couldn't find [etc]', and enableUser104012301230
There may be a better way, but those are some thoughts on how I'd do it
If you enable messages echo, whenever a human respond using the page, a echo post is sent, and inside entry->messaging->message there's no app_id.
You can use that information to disable bot replies for a certain period, or disable indefinitely until you enabled is with some admin command (that's how I'm doing)
I thought a solution could be to label the message as "unsolved". Another solution could be to have the bot mark the conversation as unread. Does anyone know if it is possibile to add a label to a conversation or mark as unread through API?

poll within the email with mailchimp or campaign monitor, without redirect

Is it possible make a poll - survey directly within the email?
for example: the user receive this email with a poll inside, he click one of the answers and the system take his vote.
so the voting takes place within the email and doesn’t redirect to another page.
I would like to use or mailchimp or campaign monitor, I know that there is some tools that can make this job, but I don't know if it is possible register the vote without a redirect.
Even MailChimp says that trying to poll entirely within the email is a bad idea. They have some simple tools to ask a single question in an email, but those also take users to an external web page too.