Tucsky/aggr

[FEATURE] Allow `Alert notifications` to trigger on a different value than price (volume, liquidation)

oksuzali999 opened this issue ยท 7 comments

First of all, thank you for this beautiful work.
Can an alarm be added to liquidation rates as well as prices? For example, in BTC, can I create a warning with an alarm when there is a liquidation of 250 k up or down? How should I go about doing this.

Hello,

It's impossible to set an Alert to something different than the price now. However, I reckon that it would be indeed useful. I am adding this to the feature backlog.

FYI @Tucsky

lmvdz commented

lmvdz@bcf9e15

converted alertService.ts to allow for indicator-based management/storage of alerts.
Need help from @Tucsky to get the value of the indicator instead of prices from aggregator service in the getValue function.

lmvdz@389b603#diff-aed1a9b5af387801328e5252658e7eb3b99ec2b2f75f1a237fedc4a73ce58935R302

lmvdz commented

Looking into this more, and will need more work than just the alertService.ts.

  • displaying the alert "price" line on the chart will have to be changed to use the indicator's axis.
  • the way of alt clicking on the chart to quickly create an alert for price perhaps shouldn't be changed
  • creating alerts for indicators should probably be done through a dialog.
    • one way would be to add it to the actual indicator script

yes, I realized that I need to concentrate on "alertService.ts". Including "lsell" and "lbuy"... I've been trying to achieve this for a long time. This situation requires experience beyond my coding knowledge and I failed to do so.

raid5 commented

I'm glad to see this being added to the feature backlog, I came here to request the same thing! I would LOVE volume alerts.

Also, maybe close #238 as a dupe since this issue has more context now?

mhakby commented

Any progress on this? If not, can you tell me when it might happen?

Tucsky commented

@mhakby I wouldn't get my hopes up unless someone explicitly said that hes working on it @mhakby

alertService mentioned above is exclusively for server side price alerts, alerts are then grouped by indexes (avg price of the coin accross the different contracts) and range of prices for saving performance which is incompatible with any other type of value.

A way I can think of, is for you to fork this Github project and edit the Prices.vue pane (as it is the closest thing to a screener)
while making use of this.$store.dispatch('app/showNotice', ...) and audioService.playOnce(your alert sound name) to get the info while the app is open

Another way would be to expose some notification helper (display a message, play audio notification) function in the indicator script to let you get notified of any event that your indicator would be aware of, this would only work for the active markets on the chart. This is probably the easiest way and less usefull way

Staying available here or on discord if someone wants to give it a go and try to implement it. Also PR is very much appreciated, as always :)