Technical Difficulty

Hi,

I would like to ask if there are alternatives to Telegram bot features, i.e. can programmatically send high-frequency messages to myself or chat in real-time/near-realtime. The use case is to send me alerts programmatically when something happens that requires my attention.

I have thought about email but it’s simply too slow and could risk the server being marked as spam given the volume I require. Push notification is something I’ve thought about but most services require a hefty fee that I might as well pay for the API traffic instead. The API traffic volume might be considered as DDoS level as the frequency can go quite high.

What are the possible solutions if I already have premium hosting or equivalent?

Thank you all!

I mean you cannot host bots here since InfinityFree is for web hosting, let past that.
VPS gives you more freedom if you can manage things on your own.

3 Likes

Hi Ziverre,

This project is not hosted here, so I didn’t put this in the Hosting Support.
As for the message, it’s part of an integration into the code I write, and that code will report any abnormalities to me.

2 Likes

Ah ok, seems like I misunderstood :slight_smile:
For what reason do you want to implement this? A basic application with time schedules could probably meet your needs depending on what it is.

2 Likes

Hi Ziverre,

There are a lot of things I need attention on and I used to have programmatic connections to statuses across the board, but the recent change at Telegram has voided their trustworthiness in handling these high-ticket process items (I’m not entirely convenient in disclosing the contents specifically, but in general it’s related to security, business and finance - not banking tho).

The real-time factor here is essential as I need to have countermeasures ready immediately per event and quickly record certain data depending on the notification nature. For example, a certain price change on the competitors’ website will result in an auto re-calculation based on costs and profit margins over a certain period of time and a price update to one of my websites will occur automatically.

As some actions may require me to do minor decisions and Telegram bot is the most viable solution at the time with the customizable keyboard and webhook and stuff, now I no longer want these on Telegram and I’m seeking available options, but all in all realtime.

:thinking:

P.S. Price change is one of the very easy ones, something like stock price change or news analytics is far more complex.

2 Likes

I’m a bit lost here, and your question about notifications really sounds like a question about how to setup an entire reaction-like system.

If you are sending to yourself, just use any SMTP provider and tell your client to never mark messages from that sender as spam.

As for the rest of the question(s), can you elaborate on exactly what you are trying to do?

2 Likes

Hi Greenreader9,

This is more of a personal project, so no clients are involved. I did consider the SMTP method however given the delay in email and the volume considered, it is just not feasible.

There are multiple triggers on events, it can be a cron job or webhook, either way it will transform that notification and forward it into a system where it will determine the appropriate actions based on the notification type, and then either do that action for me or have me make easy decisions. Using the above example, the Telegram message comes like “Competitor G has updated their service price to $80 (+$10), update website price to $50 for maintaining margin difference?” and options come in like $50 $60 $70 $80. Once I select a new price, there’ll be a webhook back to the system and update the website price with an SQL (if on the same server) or another API update request to that price application if was on another server.

There are more mission-critical ones that require real-time data, for example, the forex price changed up to a certain attention point and I need to be notified or have the trade executed for me. If that went through email it would be minutes in delay and either I get a boost or a loss.

This is what I used to be able to do, but now that Telegram changed so I no longer want to have information pass through them.

2 Likes

So you don’t just want a notification, you also want to be able to respond to that notification and have a message sent back to the server with your response. Am I understanding that correctly?

2 Likes

What delay? I can get an email in my inbox with 3 seconds of my server sending it out with SMTP. For volume, how much exactly are you planning to send? If its just yourself, most free plans should be more then enough.

2 Likes

Hi Greenreader9,

Yes, I need to have at least web hook responses to the notifications and I need them to be asap.

For my volume, the protocol itself simply isn’t fast enough, it starts to have 1-minute delay after 5k emails. While high-frequency notifications like DDoS notifications are a thing, sending emails would simply mean relaying those traffic to the SMTP which is not quite feasible. Although this sounds a bit strange in the first place if the delay is short enough, it usually can respond very quickly and stop the DDoS within seconds and the situation gets mitigated really quickly via a webhook update to the firewall rules over at Cloudflare.

1 Like

Well, you can use limit, stop limit or other orders.
I am sure there are other OCO that you can use.

1 Like

Hi KangJL,

These are the orders from within a trading system, while the problem at hand concerns getting change notifications to me for supervising these order types. Meanwhile, it is still possible to set the limits from the beginning of the order. However, if the prices change to another interesting point and I would like to make an adjustment, it will be more difficult or subject to higher latency until I find a solution.

I only have to solve the technical part where high-frequency notifications and webhooks are possible.

This is not enough. For HFT, the server need to be situated as close as possible to the exchanges where the orders are running to reduce latency. A simple VPS is not enough. You also need to take the location into consideration

2 Likes

Hi KangJL,

High-frequency trading is not the only thing I am currently concerned about, the actual trade is offset to another server, but still, I have to be notified about certain changes in the market, and other non-trading related things.

With a limited budget allocated to this, I would like to solve the technical part first before proceeding with something wild. At least to get a working replacement against Telegram first would be ideal.

It’s very likely I’ll have to code an API myself to solve this regardless of the potential traffic fees :cry:

If you are a trader, try to focus on your trades.
Outsource other tasks wherever possible

1 Like

Unfortunately, I’m not a full-time trader, and outsourcing tasks isn’t an option at the moment.

I typically use Pushover for this. I’ve used PushBullet in the past too. It does mean you’ll have to install an extra app for it, but both options are either free or pretty cheap, and also provide near instant push notifications. Both have dead simple APIs too.

6 Likes

Hi Admin,

Thanks for sharing, after comparing I think Pushover is more towards what I wanted but having to pay $1k USD each time I hit 500k messages is quite a consideration factor for me. The only thing left to decide is whether I should pay the message fees or just code/copy a push notification thing off the internet with some tweak.

This is 50% of what I’m looking for as I did not plan to receive the notifications from within the webpage (but good to have), but I can see the mechanism is pretty much checking an API for things every few seconds. (There goes the battery life, Oof)

Cheers!

Geesh, how many messages do you expect to send? Pushover has a 10k messages per month free tier, which is plenty for me. If hitting 500k messages per month is a realistic expectation, your use case must be very different than I had expected.

Depending on your use case, maybe Slack could be an alternative? It’s a bit like Discord for businesses, and also has bot support. I think the Slack APIs are not restricted.

7 Likes

I would do ntfy.sh but that’s just me :)))))