iexcloud: Library for the IEX Trading API

[ bsd3, library, net ] [ Propose Tags ] [ Report a vulnerability ]

Simple library for interacting with the IEX Trading API


[Skip to Readme]

Modules

  • Net
    • IEX
      • Net.IEX.Book
      • Net.IEX.Chart
      • Net.IEX.Company
      • Net.IEX.DelayedQuote
      • Net.IEX.Dividend
      • Net.IEX.Earnings
      • Net.IEX.EffectiveSpread
      • Net.IEX.Financials
      • Net.IEX.IntraDayStats
      • Net.IEX.Market
      • Net.IEX.NewsItem
      • Net.IEX.OHLC
      • Net.IEX.Previous
      • Net.IEX.PriceTime
      • Net.IEX.Quote
      • Net.IEX.RecentStats
      • Net.IEX.RecordStats
      • Net.IEX.Relevant
      • Net.IEX.Split
      • Net.IEX.Stats
      • Net.IEX.TimeSeries
      • Net.IEX.VolumeByVenue
    • Net.Stocks

Downloads

Maintainer's Corner

Package maintainers

For package maintainers and hackage trustees

Candidates

  • No Candidates
Versions [RSS] 0.0.0.1
Dependencies aeson (==1.2.4.0), base (>=4 && <5), bytestring (==0.10.8.2), containers (==0.5.10.2), http-conduit (==2.2.4), semigroups (==0.18.4), unordered-containers (==0.2.8.0) [details]
License BSD-3-Clause
Copyright 2018-2019 David Bouchare, Kristian Sällberg
Author David Bouchare, Kristian Sällberg
Maintainer David Bouchare, Kristian Sällberg
Category Net
Home page https://github.com/ksallberg/iexcloud
Source repo head: git clone https://github.com/ksallberg/iexcloud.git
Uploaded by ksallberg at 2019-07-13T08:53:37Z
Distributions
Downloads 508 total (6 in the last 30 days)
Rating (no votes yet) [estimated by Bayesian average]
Your Rating
  • λ
  • λ
  • λ
Status Docs not available [build log]
All reported builds failed as of 2019-07-13 [all 3 reports]

Readme for iexcloud-0.0.0.1

[back to package description]

Haskell iexcloud client

This project is based on the legacy iex API client stocks

Build Status

Haskell library for the IEX trading API.

Example:

stack build && stack ghci

getQuote :: AuthAndSymbol -> IO (Maybe IEXQuote.Quote)
> getQuote ("pk_myAPItoken", "msft")

Just (Quote {symbol = "MSFT",
             companyName = "Microsoft Corp.",
             primaryExchange = Nothing,
             sector = Nothing,
             calculationPrice = "tops",
             open = 128.9,
             ...
             })

getCompany :: AuthAndSymbol -> IO (Maybe IEXCompany.Company)
> getCompany ("pk_myAPItoken", "aapl")

Just (Company {symbol = "AAPL",
               companyName = "Apple Inc.",
               exchange = "Nasdaq Global Select",
               industry = "Computer Hardware",
               website = "http://www.apple.com",
               description = "Apple Inc is designs ...",
               ceo = "Timothy D. Cook",
               issueType = "cs",
               sector = "Technology"})

getPrice :: AuthAndSymbol -> IO (Maybe Double)
> getPrice ("pk_myAPItoken", "msft")

Just 131.56

Please see the HUnit test for a complete example of all API calls.

How to run test suite

stack test

Contribute

For any problems, comments, or feedback please create an issue here on GitHub.

Attribution

If you redistribute our API data:

Before uploading to hackage

  • Make sure that all dependencies in 'iexcloud.cabal' are version bound. Also:
  1. Hackage is intended to be a permanent record. Therefore uploads cannot be changed or removed.
  2. Only upload things that work, are useful to other people, and that you intend to maintain.
  3. Use cabal gen-bounds to put PVP-compliant version bounds (lower AND upper) on ALL your unique dependencies so your package will still be buildable years down the road. One important thing to note is that you only need to include version bounds once. For example, if you depend on the same package in your library and your test suite, you only need to put the version bounds for that dependency in one place. This keeps the dependency bounds information DRY.
  4. Package candidates CAN be changed, so use them to test things out and get everything right before you publish permanently to the main index.