Executions API
Aquanow provides execution services to end users by leveraging our aggregated market data, liquidity, and execution algorithms.
There are several differences with V2 endpoints. Firstly, the data is encapsulated in a data
payload. Secondly, there now exists a pagination
object that, if applicable, will hold a startsAfter
token. You can use the startsAfter
token as a query parameter to query successive data, until startsAfter
is null, signifying that you have reached the end of the pagination.
if startsAfter
is a string while there is no data in the payload, it means there is more data to be fetched, even if it seems to be returning an empty array. Do not stop calling until the startsAfter
token has an empty string (""). Do not rely on the data received to determine if you should keep fetching.
Get or query orders
GET
https://api.aquanow.io/trades/v2/order
To view example requests for this endpoint, visit Aquanow's Postman documentation.
NOTE: The limit for this endpoint is a maximum payload of 5 mb. For larger payloads, use the v2 endpoint or change the time range parameters to query for less results.
Query Parameters
-
-
Query all orders if no query parameters are provided.
orderId
String
Query by order ID.
accountId
String
Query orders by account.
startTime/endTime
Number
Query by time range, requires both startTime and endTime.
expirationStartTime/expirationEndTime
Number
Query by expiration time range, requires both expirationStartTime and expirationEndTime.
openOrders=true
Bool
Query for open orders
startsAfter
String
Pagination token used to fetch extra data
usernameRef
String
Query by usernameRef
Headers
x-api-key*
String
{{x-api-key}}
API Auth Key
x-signature*
String
32c92660f65cbb78d0eaf9a4361fb6b0a2cb8bb4c40f531e9974a0afc12d9a328b5ff621w544d242ee9ba1dfa799c85a
Signature created using your API secret
x-nonce*
String
1657731573930
Timestamp in millisecond
Returns an OrdersV2Object.
Endpoint to initiate an LIMIT/GTC/GTD request to Aquanow.
POST
https://api.aquanow.io/trades/v2/order
NOTE: Either deliverQuantity or receiveQuantity must be specified. If both are specified, receiveQuantity will be considered for sell orders, and deliverQuantity will be considered for buy orders.
If order is not filled, the request will return a 200 response with receiveQuantity and deliverQuantity set to 0.
To view example requests for this endpoint, visit Aquanow's Postman documentation.
Headers
x-api-key*
String
{{x-api-key}}
API Auth Key
x-signature*
String
49c6260c194f4d7ed5cb917dc70b9821673246b2abc1cf28f05df6a75fd24181e00f8e57b321d15ae45db58b3bffe27a
Signature created using your API secret
x-nonce*
Number
1618307861949
Timestamp in millisecond
Content-Type*
String
application/json
Request Body
strategy*
String
"LIMIT"
, "GTC"
or "GTD"
accountId*
String
Identifier for account the order will be applied to.
ticker*
String
e.g., BTC-CAD
Currency pair
tradeSide*
String
"buy"
or "sell"
priceLimit*
String
Limit price of a ticker symbol, determined by tradeSide
and deliverQuantity
/receiveQuantity
deliverQuantity*
String
NOTE: specify either deliverQuantity
or receiveQuantity
.
Quantity of currency delivered by user based on the ticker and tradeSide.
For example, if ticker is BTC-USD and tradeSide is buy, then the delivered currency is USD. If tradeSide is sell, the delivered currency is BTC.
receiveQuantity*
String
NOTE: specify either deliverQuantity
or receiveQuantity
.
Quantity of currency received by user based on the ticker and tradeSide.
For example, if ticker is BTC-USD and tradeSide is buy, then the received currency is BTC. If tradeSide is sell, the received currency is USD.
expirationTime*
Number
NOTE: only required for GTD orders.
e.g., 1669972404350
Expiration time in milliseconds of when the pre-existing order will expire. Expiration time must be within 90 days of order creation.
usernameRef*
String
A new reference string for sub-accounts. Must be less than 64 characters, cannot contain special characters.
Returns an ExecutionsObject.
Last updated