API Documentation

WebSocket

WebSocket provide public updates of the orderbook and the trade history.

The base URI is wss://api.exchange.ripio.com/ws/v2/consumer/non-persistent/public/default/

Topics:

There are two kinds of topics: orderbook and trades which has to be concatenated with the pair. E.g.: The topic for the orderbook of BTC/DAI pair is orderbook_btc_dai and for the trade history trades_btc_dai. There is special topic that notify the user's new trades. This is get in the paylod received when a user succesfully login.

Suscription:

The suscription is a token which identify you as suscriber so the web sockets know which messages was or wasn't deliver. Make sure use the same token to prevent missing updates. Each received message has to be aknowledge so the web socket don't send it again.

var my_suscription = btoa("[email protected]")
var topic = "orderbook_btc_ars"
var ws = new WebSocket("wss://api.exchange.ripio.com/ws/v2/consumer/non-persistent/public/default/" + topic + "/" + my_suscription),
ws.onmessage = function(event) {
    console.log(event.data)
    var ackMsg = {"messageId" : event.data.messageId};
    ws.send(JSON.stringify(ackMsg));
};
ws.onerror = function(event) {console.log(event);}

Public

This end-points do not need authentication.

GET All Rates

https://api.exchange.ripio.com/api/v1/rate/all/

List all rates for all the availables pairs

Headers

Content-Type application/json
Example RequestAll Rates
                        curl --location --request GET "https://api.exchange.ripio.com/api/v1/rate/all/" \
   --header "Content-Type: application/json" \

GET Rate per Pair

https://api.exchange.ripio.com/api/v1/rate/{{pair}}/

Rate per Pair

Headers

Content-Type application/json
Example RequestRate per Pair
                        curl --location --request GET "https://api.exchange.ripio.com/api/v1/rate/{{pair}}/" \
   --header "Content-Type: application/json" \

GET Rates per Country

https://api.exchange.ripio.com/api/v1/rate/all/?country={{country_code}}

Rates per Country

Headers

Content-Type application/json
Example RequestRates per Country
                        curl --location --request GET "https://api.exchange.ripio.com/api/v1/rate/all/?country={{country_code}}" \
   --header "Content-Type: application/json" \

GET Orderbook

https://api.exchange.ripio.com/api/v1/orderbook/{{pair}}/

Get the pair's orderbook

Headers

Content-Type application/json
Example RequestOrderbook
                        curl --location --request GET "https://api.exchange.ripio.com/api/v1/orderbook/{{pair}}/" \
   --header "Content-Type: application/json" \

GET Trade history

https://api.exchange.ripio.com/api/v1/tradehistory/{{pair}}/

Get pair's last trades

Headers

Content-Type application/json
Example RequestTrade history
                        curl --location --request GET "https://api.exchange.ripio.com/api/v1/tradehistory/{{pair}}/" \
   --header "Content-Type: application/json" \

GET List of Pairs

https://api.exchange.ripio.com/api/v1/pair/

List all available pairs and theirs fees

Headers

Content-Type application/json
Example RequestList of Pairs
                        curl --location --request GET "https://api.exchange.ripio.com/api/v1/pair/" \
   --header "Content-Type: application/json" \

GET List of Currencies

https://api.exchange.ripio.com/api/v1/currency/

List of available currencies

Headers

Content-Type application/json
Example RequestList of Currencies
                        curl --location --request GET "https://api.exchange.ripio.com/api/v1/currency/" \
   --header "Content-Type: application/json" \

Private

This end-points do need authentication.

For this endpoints It is required an authentication API key that can be adquire in the API menu of your account.

GET Account's balances

https://api.exchange.ripio.com/api/v1/balances/exchange_balances/

View all the balances of user's account

Headers

Content-Type application/json
Authorization Bearer {{API_KEY}}
Example RequestAccount's balances
                        curl --location --request GET "https://api.exchange.ripio.com/api/v1/balances/exchange_balances/" \
   --header "Content-Type: application/json" \
--header "Authorization: Bearer {{API_KEY}}" \

POST Create an order

https://api.exchange.ripio.com/api/v1/order/{{pair}}/

Create an order

Headers

Content-Type application/json
Authorization Bearer {{API_KEY}}

Body

raw (application/json)
{
"order_type": "LIMIT",
"amount": "0.04",
"limit_price": "10",
"side": "BUY",
}
Example RequestCreate an order
                        curl --location --request POST "https://api.exchange.ripio.com/api/v1/order/{{pair}}/" \
   --header "Content-Type: application/json" \
--header "Authorization: Bearer {{API_KEY}}" \
--data "{ "order_type":"LIMIT", "amount":"0.04", "limit_price":"10", "side":"BUY" }"

POST Cancel an order

https://api.exchange.ripio.com/api/v1/order/{{pair}}/{{order_id}}/cancel/

Cancel an order

Headers

Content-Type application/json
Authorization Bearer {{API_KEY}}
Example RequestCancel an order
                        curl --location --request POST "https://api.exchange.ripio.com/api/v1/order/{{pair}}/{{order_id}}/cancel/" \
   --header "Content-Type: application/json" \
--header "Authorization: Bearer {{API_KEY}}" \

GET User's orders

https://api.exchange.ripio.com/api/v1/order/{{pair}}/

List all user's orders

Headers

Content-Type application/json
Authorization Bearer {{API_KEY}}
Example RequestUser's orders
                        curl --location --request GET "https://api.exchange.ripio.com/api/v1/order/{{pair}}/" \
   --header "Content-Type: application/json" \
--header "Authorization: Bearer {{API_KEY}}" \

GET Order's details

https://api.exchange.ripio.com/api/v1/order/{{pair}}/{{order_id}}/

Order's details

Headers

Content-Type application/json
Authorization Bearer {{API_KEY}}
Example RequestOrder's details
                        curl --location --request GET "https://api.exchange.ripio.com/api/v1/order/{{pair}}/{{order_id}}/" \
   --header "Content-Type: application/json" \
--header "Authorization: Bearer {{API_KEY}}" \

GET User's orders filter per status

https://api.exchange.ripio.com/api/v1/order/{{pair}}/?status=OPEN,PART

User's orders filter per status

Headers

Content-Type application/json
Authorization Bearer {{API_KEY}}
Example RequestUser's orders filter per status
                        curl --location --request GET "https://api.exchange.ripio.com/api/v1/order/{{pair}}/?status=OPEN,PART" \
   --header "Content-Type: application/json" \
--header "Authorization: Bearer {{API_KEY}}" \

GET User's trade history

https://api.exchange.ripio.com/api/v1/trade/{{pair}}/

User's trade history

Headers

Content-Type application/json
Authorization Bearer {{API_KEY}}
Example RequestUser's trade history
                        curl --location --request GET "https://api.exchange.ripio.com/api/v1/trade/{{pair}}/" \
   --header "Content-Type: application/json" \
--header "Authorization: Bearer {{API_KEY}}" \