1.1.0 • Published 5 years ago

stock-ticker-symbol v1.1.0

Weekly downloads
43
License
MIT
Repository
github
Last release
5 years ago

Nasdaq Stock Ticker Symbols

npm.io npm.io

Utility to lookup and validate NASDAQ Ticker Symbols

lookup takes a symbol and returns the company name if valid, otherwise it returns null.

search returns an array of results with tickers/names matching input or an empty array

searchTicker returns an array of results with tickers matching input or an empty array

searchName returns an array of results with names matching input or an empty array

Install

$ npm install stock-ticker-symbol

Usage

const stocks = require('stock-ticker-symbol');

stocks.lookup('AAPL'); // Apple Inc.;

stocks.lookup('ABCD'); // null;

stocks.search('apple');
// [ { name: 'Apple Hospitality REIT, Inc.', ticker: 'APLE' },
//   { name: 'Apple Inc.', ticker: 'AAPL' },
//   { name: 'Maui Land & Pineapple Company, Inc.', ticker: 'MLP' } ]

stocks.searchTicker('MSFT'); // [ { name: 'Microsoft Corporation', ticker: 'MSFT' } ]

stocks.searchTicker('OMG'); // []

stocks.searchName('alphabet'); // [ { name: 'Alphabet Inc.', ticker: 'GOOGL' } ]

License

MIT

1.1.0

5 years ago

1.0.3

5 years ago

1.0.2

5 years ago

1.0.1

5 years ago

1.0.0

5 years ago

0.0.1

5 years ago