prosper-0.1.1: Bindings to the Prosper marketplace API

Safe HaskellNone
LanguageHaskell2010

Prosper

Contents

Description

These are bindings to the Prosper marketplace API. The documentation for the API can be seen at https://api.prosper.com/.

Synopsis

Commands

invest :: User -> Money -> Listing -> IO InvestResponse Source

An investment request. This requires a User, an amount of Money, and a Listing.

account :: User -> IO Account Source

Request Account information from Prosper

allListings :: User -> IO (Vector Listing) Source

Send a request to the Listings end-point at Prosper

notes :: User -> IO (Vector Note) Source

Request notes for a Prosper user

listingFromNote :: User -> Note -> IO (Maybe Listing) Source

Given a Note, look up the associated Listing by the ListingId

data AccountException Source

Used as a hack around the 500 Critical Exception error

User

data User Source

User info for Prosper data

Constructors

User 

Fields

username :: !ByteString

Username for Prosper

password :: !ByteString

Password for Prosper

Instances

Account

data Account Source

A data structure for holding account information for Prosper

Constructors

Account 

Fields

availableCash :: !Money

Available cash for investing

pendingInvestments :: !Money

Amount of money invested that is pending origination

totPrincipalRecvdOnActiveNotes :: !Money

Total principal payments received on active notes

totalInvestedOnActiveNotes :: !Money

Total amount invested

outstandingPrincipalActiveNotes :: !Money

Total principal outstanding on active notes

totalAccountValue :: !Money

Total dollars held in investible cash, pending orders in the market, outstanding principal

pendingInvestmentsSecondaryMkt :: !Money

Investments on Folio

pendingQuickInvestOrders :: !Money

Prosper Quick Invests

Instances

Eq Account 
Show Account 
FromJSON Account

Parser for account info

Located at api/Account

emptyAccount :: Account Source

An empty account. All values are zero.

Listing

data Listing Source

Constructors

Listing 

Fields

listingId :: !Int
 
status :: !Status
 
rating :: !Rating

Letter score assigned by Prosper

score :: !(Maybe Int)

Prosper score

category :: !Category

The reason for the loan (e.g. Auto, Student, etc)

amountRemaining :: !Money
 
offer :: !Offer

Contract data

credit :: !Credit

Credit data

Instances

Eq Listing

Two Listings are equivalent if their listingIds are equal

Show Listing 
FromJSON Listing

Parse a Listing from JSON

data Offer Source

Data related to the listing's offer and contract terms

Constructors

Offer 

Fields

requestAmount :: !Money
 
rate :: !Double

Interest rate for the borrower

termInMonths :: !Int

Integer number of months

yield :: !Double
 
effectiveYield :: !Double
 
apr :: !Double

APR for the borrower

Instances

data Credit Source

Data related to the credibility of the listing

Instances

data Rating Source

Prosper ratings, AA is the most credible. HR is the least credible.

Constructors

HR 
E 
D 
C 
B 
A 
AA 

Note

Invest

data InvestStatus Source

Status of an invest request

data InvestResponse Source

JSON response to an invest request

Instances

Types