Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

New Feature: Add price alert for a stock #68

Open
wants to merge 4 commits into
base: master
Choose a base branch
from

Conversation

asifma
Copy link

@asifma asifma commented Aug 29, 2021

addPriceAlert

Add an price alert.

Parameters

  • instrumentId [String][52] The ID of the instrument to add.
  • options [Object][51] Alert options.
    • options.price [Number][54] The target price to receive an alert on.
    • options.validUntil [String][52] A date on the form YYYY-MM-DD. Cancels alert if this date is

@asifma asifma mentioned this pull request Aug 29, 2021
Copy link
Owner

@fhqvst fhqvst left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great! Thanks! Should we add a removePriceAlert too?

@asifma
Copy link
Author

asifma commented Sep 1, 2021

I just haven't had time to look at it yet.

But in order to remove alerts, you need to (per my understanding).

  1. Get alerts for an underlying stock.
  2. If alert(s) exist
  3. Delete alert by alertID that you received in step 2.

So yes, we should probably introduce getPriceAlert & removePriceAlert

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants