Send Intercom Message every time an event occurs? - intercom.js

Hi im trying to send messages through intercom every time an event is sent. Let's say i have a feature in my product which is submitting intercom events every time the user clicks a certain tab. I would like to send a message on every occur of the event. I have already set an auto message in my intercom app, but i´m just able to send the message the first time the event occurs.

According to the interecom support team, auto-messaging is the currently the only way to do it. For now, they do not support advanced/customized triggers like "send the user a welcome message for the first 3 times when he clicks some link"

Related

Reply Markup Keyboard To Enter Text In Field Not Send

I am reading about telegram keyboards for bots (see picture)
From as far i can gather pressing of these button will instantly send the text in the chat.
What i want is the keyboards send the text to the message field.
For example -
if i press 1 ,the message field shows 1 then pressing * and 1 will result in 1*1 which will be sent to bot
What you want is not allowed by Telegram Bot APIs, because as soon as you press a button, it instantly sends a message with the same text.
The only thing you can do is receive every message and put them together. you have also to define a workflow using states, for example

How could I modify the default notifications for my google calendar?

Google by default fires up a notification only 10 mins before. But I want to add more notifications. Like on 30 mins before. One at the time of the event too. Is this possible?
If you refer to the image below, all we see are the notification method. Not even the default value or place to add more reminders? Or is that something available at the event level and not the calendar level?
Yes, it is possible to add more than one notification in one specific event on Google Calendar. To do this, follow these steps below:
Go to your Google Calendar.
Select the event you wanted to have more than one notifications.
Click on Edit event(the pencil icon that you can see on the
upper right of the event selected).
Under Event Details tab, you can see the Add Notification
button.
Click the Add Notification button. On the first drop-down menu,
select the type of notification you want to receive(email or a
pop-up notification message).
To schedule when you want the notification be received/appear,
indicate the specific number of time in the box(or
you can click the up and down arrow as an option), and then
select the unit of time(minutes, hours, days or weeks) you
prefer.
If you want to have another notification/s for one specific event, you
can click the Add Notification button again and do
the same steps from 4-6.
Then click Save.

how to display some message once user starts to compose new email

For Office 365 Outlook Web App, we would like to convert attachments to links once end user uploads them, however we didn't see an attachment notification event at current Outlook Addin.
Another approach we could do is to ask them to use our own buttons for uploading, however we need to guide end user to use our own buttons, could we add some message at top of email body like below once new email message box is displayed?
Somehow based on our research, Outlook Addin only has one event right now which is SendEvent, could someone confirm this? if so, it is rather limited.
To display a custom message use Office.context.mailbox.item.notificationMessages object. For example to add a message to current item the code may looks like ...
Office.context.mailbox.item.notificationMessages.addAsync("information", {
type: "informationalMessage",
message : "My custom message.",
icon : "iconid",
persistent: false
});
Be aware there are a maximum of 5 notifications per message and maximum length of each message text is 150 characters per Office.NotificationMessageDetails interface.
For the secondary question you would need to look at available events in Office.EventType enum. Over here you'll see few events available to Outlook app. One of them you are interested in is AttachmentsChanged which is currently available only in Preview (not released yet, but will be soon).

Intercept OnSend event after attachment reminder

In Outlook Web Add-In, I'm trying to intercept OnSend event which is triggered when sending an email.
I used this example in GitHub which is working fine.
If I include the word "attachment" in the email body and I click Send button, OnSend event is fired for the first time so I can do some processing to email's content. However, after a while, a pop-up modal window shows up with this message:
Attachment reminder
You may have forgotten to attach a file.
with Send and Don't send buttons. If click Send, OnSend event gets fired a second time. This time, It would be useless to repeat the same email processing. So, I'm looking for a way to find out that the second OnSend event is fired after an Attachment reminder.
Is there a way to distinguish between first and second OnSend events?
Thanks for your question, Mhd! This appears to be unintentional behavior, essentially a defect that we will look into fixing. ItemSend event should inter operate with forgotten attachment detection nicely, and should only be raised after the detection happened. In other words, the first event should not be called at all. Is it a problem if you do the processing twice until this issue is resolved?

How can I "undo send" like in Gmail?

How can I undo send, save or delete in Vb like Gmail is using this feature in Messages.
The feature used by Gmail is they are queing the message for 5 secs and if the user clicks on Undo before that 5secs the whole send process is pulled back.
Now what I want is to implement this same in my Vb.net application. Is there any code available to do this. Please help ?
About an "undo send" feature, the most evident way of doing that is to actually not "do" what you want to "undo".
What I mean is :
When a user clicks on "send", you should not really send the message
Instead, you should mark it as "to send in X seconds" -- place it in some queue, for instance
Which means it'll only be sent after X seconds, and not immediatly.
During this X number of seconds, if the user clicks "undo send", you just have to remove that mail from the "waiting queue"
Of course, you cannot "undo send" on a mail which has already been sent : it's gone from your server, and there is nothing you can do anymore about it.
To implement that, you'll need :
Some queue for actions
To place your data into this queue when the user clicks "send"
To have some batch that really sends data that's been in the queue for more than X seconds
To remove the data from the queue when the user clicks "undo send".
The same idea can be applied to "undo delete" :
When a user clicks on "delete", don't physicilly delete the data
Instead, use some boolean flag to indicate that it should be considered as deleted
Then, un-doping that deletion only means de-activating that flag
This can easily be implemented in any language :
Add a is_deleted field on your data
When displaying the data, filter those for which this flag is enabled
When deleting, instead of physically deleting, set this flag
When un-deleting, un-set this flag
The "undo save" can be a bit harder : a solution would be to not keep only one version of the message, but several :
Each time the user clicks "save", you should store a new version of the message
Which means you'll end up, after some time, with many versions of the message
Which will allow you to "come back" to a previous version, restoring it from the history.
This can be done :
adding a new field called like "version" on your data.
each time the user saves, just increment that field, and store a copy of the data
i.e. never actually update any exiting data, but always insert a new version of it.
then, "undo save" only means "get the previous version of the data"