https://github.com/frederickgeek8/lyql
📈 Free realtime stock data. Streamed straight from Yahoo.
https://github.com/frederickgeek8/lyql
data data-mining finance realtime stocks stream stream-api yahoo
Last synced: about 1 month ago
JSON representation
📈 Free realtime stock data. Streamed straight from Yahoo.
- Host: GitHub
- URL: https://github.com/frederickgeek8/lyql
- Owner: FrederickGeek8
- License: other
- Created: 2016-12-29T18:31:32.000Z (over 9 years ago)
- Default Branch: master
- Last Pushed: 2017-05-25T17:14:42.000Z (almost 9 years ago)
- Last Synced: 2026-01-24T18:54:23.883Z (3 months ago)
- Topics: data, data-mining, finance, realtime, stocks, stream, stream-api, yahoo
- Language: JavaScript
- Homepage:
- Size: 19.5 KB
- Stars: 6
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE.md
Awesome Lists containing this project
README
# LYQL
**Disclaimer: I am in no way affiliated with Yahoo. This tool likely violates Yahoo Terms and Conditions by using non-public API's. Use *only* for personal use. I am not liable for misuse of this program or any effects it may have.**
## Super simple to use
LYQL is a tool for achieving truly realtime, free stock prices direct from Yahoo. LYQL is designed to be a simple, intuitive library solution that can be used both in the browser and on a server.
```javascript
var LYQL = require('lyql');
var options = {
"Stocks": ["GOOG", "AAPL", "JPYUSD=X"],
// Price, Change, and Volume
"Parameters": ["l84", "p43", "v53"]
};
var test = new LYQL(options, function(data){
console.log(data);
});
test.start();
```
## Request Parameters
* **a00:** Ask
* **a50:** Ask Size
* **b00:** Bid
* **b60:** Bid Size
* **c10:** Change
* **c63:** Change Realtime
* **c64:** *Disputed* Change Realtime After Hours
* **c85:** Change Realtime After Hours
* **c86:** Percent Change Realtime After Hours
* **g53:** Day Low
* **h53:** Day High
* **j10:** Market Cap
* **l10:** Price
* **l84:** Price Realtime
* **l86:** Price Realtime After Hours
* **p20:** Percent Change
* **p43:** Percent Change Realtime
* **p44:** Percent Change Realtime After Hours
* **t53:** *Disputed* Timestamp for Commodities
* **t54:** *Disputed* Timestamp for Stocks
* **v53:** Volume
## Installation
`npm install LYQL`
## Commands
```javascript
new LYQL(options, function(data) {
// ...
});
```
Creates an instance of LYQL that calls a given function whenever new data has been streamed from Yahoo.
`options` should be an object in the format
```javascript
var options = {
"Stocks": ["GOOG", "AAPL", "JPYUSD=X"],
// Price, Change, and Volume
"Parameters": ["l84", "p43", "v53"]
};
```
In order to start, stop, and restart LYQL instances, one of the following commands can be executed on an LYQL instance.
```javascript
LYQL.start();
LYQL.stop();
LYQL.restart();
```
In order to add or remove a stock from a LYQL instance, one of the following commands can be executed.
```javascript
LYQL.addStock(ticker);
LYQL.removeStock(ticker);
```
In order to add or remove a request parameter from a LYQL instance, one of the following can be run.
```javascript
LYQL.addParameter(parameter);
LYQL.removeParameter(parameter);
```
## TODO
- [ ] Write documentation / code comments.
- [ ] Add simple mode
- [x] Modularize so that it can be used within other use cases.
- [x] Add Browser support (Browserify)