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

Add ticker symbol and news search #837

Closed
a0rtega opened this issue Sep 16, 2021 · 1 comment
Closed

Add ticker symbol and news search #837

a0rtega opened this issue Sep 16, 2021 · 1 comment

Comments

@a0rtega
Copy link
Contributor

a0rtega commented Sep 16, 2021

The YF API search endpoint has two functionalities that would be nice to add to yfinance:

  • Search for ticker symbols using the company name or part of it, as well as the exchanges where it is traded. This query is used in the site to autocomplete the search.
  • List the latest news about a company or ticker

The information is easily accessible using the endpoint https://query2.finance.yahoo.com/v1/finance/search?q=apple, see the quotes and news keys of the JSON response.

The basic search above is probably enough, although the endpoint supports many parameters to customize the search. This is a full search query added for reference: https://query2.finance.yahoo.com/v1/finance/search?q=apple&lang=en-US&region=US&quotesCount=6&newsCount=2&listsCount=2&enableFuzzyQuery=false&quotesQueryId=tss_match_phrase_query&multiQuoteQueryId=multi_quote_single_token_query&newsQueryId=news_cie_vespa&enableCb=true&enableNavLinks=true&enableEnhancedTrivialQuery=true&enableResearchReports=true&researchReportsCount=2

Thank you in advance!

@silvavn
Copy link
Collaborator

silvavn commented Oct 15, 2021

Hi @a0rtega those are excellent suggestions and we would be glad to review a push request if you would like to implement i!

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

No branches or pull requests

3 participants