bitx-bitcoin-0.2.0.2: A Haskell library for working with the BitX bitcoin exchange.

CopyrightNo Rights Reserved
LicensePublic Domain
MaintainerTebello Thejane <zyxoas+hackage@gmail.com>
StabilityExperimental
Portabilitynon-portable (GHC Extensions)
Safe HaskellNone
LanguageHaskell2010

Network.Bitcoin.BitX.Private.Order

Description

Creating and working with orders

Trading on the market is done by submitting trade orders. After a new order has been created, it is submitted for processing by the order matching engine. The order then either matches against an existing order in the order book and is filled or it rests in the order book until it is stopped.

Synopsis

Documentation

getAllOrders :: BitXAuth -> Maybe CcyPair -> Maybe RequestStatus -> IO (BitXAPIResponse [PrivateOrder]) Source

Returns a list of the most recently placed orders.

If the second parameter is Nothing then this will return orders for all markets, whereas if it is Just cpy for some CcyPair cpy then the results will be specific to that market.

If the third parameter is Nothing then this will return orders in all states, whereas if it is Just COMPLETE or Just PENDING then it will return only completed or pending orders, respectively.

This list is truncated after 100 items.

Perm_R_Orders permission is required.

postOrder :: BitXAuth -> OrderRequest -> IO (BitXAPIResponse OrderID) Source

Create a new order.

Warning! Orders cannot be reversed once they have executed. Please ensure your program has been thoroughly tested before submitting orders.

Perm_W_Orders permission is required.

stopOrder :: BitXAuth -> OrderID -> IO (BitXAPIResponse RequestSuccess) Source

Request to stop an order.

Perm_W_Orders permission is required.

getOrder :: BitXAuth -> OrderID -> IO (BitXAPIResponse PrivateOrderWithTrades) Source

Get an order by its ID

Perm_R_Orders permission is required.