Orders - Cancel All Orders
curl --request DELETE \
--url https://api.ripio.com/trade/orders/all \
--header 'Content-Type: application/json' \
--header 'authorization: <authorization>' \
--header 'signature: <signature>' \
--header 'timestamp: <timestamp>' \
--data '
{
"pair": "BTC_BRL"
}
'import requests
url = "https://api.ripio.com/trade/orders/all"
payload = { "pair": "BTC_BRL" }
headers = {
"authorization": "<authorization>",
"signature": "<signature>",
"timestamp": "<timestamp>",
"Content-Type": "application/json"
}
response = requests.delete(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'DELETE',
headers: {
authorization: '<authorization>',
signature: '<signature>',
timestamp: '<timestamp>',
'Content-Type': 'application/json'
},
body: JSON.stringify({pair: 'BTC_BRL'})
};
fetch('https://api.ripio.com/trade/orders/all', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.ripio.com/trade/orders/all",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "DELETE",
CURLOPT_POSTFIELDS => json_encode([
'pair' => 'BTC_BRL'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"authorization: <authorization>",
"signature: <signature>",
"timestamp: <timestamp>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.ripio.com/trade/orders/all"
payload := strings.NewReader("{\n \"pair\": \"BTC_BRL\"\n}")
req, _ := http.NewRequest("DELETE", url, payload)
req.Header.Add("authorization", "<authorization>")
req.Header.Add("signature", "<signature>")
req.Header.Add("timestamp", "<timestamp>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.delete("https://api.ripio.com/trade/orders/all")
.header("authorization", "<authorization>")
.header("signature", "<signature>")
.header("timestamp", "<timestamp>")
.header("Content-Type", "application/json")
.body("{\n \"pair\": \"BTC_BRL\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.ripio.com/trade/orders/all")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Delete.new(url)
request["authorization"] = '<authorization>'
request["signature"] = '<signature>'
request["timestamp"] = '<timestamp>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"pair\": \"BTC_BRL\"\n}"
response = http.request(request)
puts response.read_body{
"data": [
{
"order_id": "F6D2661E-4D6F-4770-BBE6-CC063CBA3770",
"pair_code": "BTC_BRL",
"success": true
},
{
"order_id": "7155ED34-9EC4-4733-8B32-1E4319CB662F",
"pair_code": "BTC_BRL",
"success": false
}
],
"error_code": null,
"message": null
}Orders
Cancel All Orders
Cancels all the user’s active orders.
Publishes updates in the following websocket topics: orderbook, balance and order_status.
Authorization
- Requires a valid API key.
- Required API-key permission(s):
- Trading (Write)
DELETE
/
trade
/
orders
/
all
Orders - Cancel All Orders
curl --request DELETE \
--url https://api.ripio.com/trade/orders/all \
--header 'Content-Type: application/json' \
--header 'authorization: <authorization>' \
--header 'signature: <signature>' \
--header 'timestamp: <timestamp>' \
--data '
{
"pair": "BTC_BRL"
}
'import requests
url = "https://api.ripio.com/trade/orders/all"
payload = { "pair": "BTC_BRL" }
headers = {
"authorization": "<authorization>",
"signature": "<signature>",
"timestamp": "<timestamp>",
"Content-Type": "application/json"
}
response = requests.delete(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'DELETE',
headers: {
authorization: '<authorization>',
signature: '<signature>',
timestamp: '<timestamp>',
'Content-Type': 'application/json'
},
body: JSON.stringify({pair: 'BTC_BRL'})
};
fetch('https://api.ripio.com/trade/orders/all', options)
.then(res => res.json())
.then(res => console.log(res))
.catch(err => console.error(err));<?php
$curl = curl_init();
curl_setopt_array($curl, [
CURLOPT_URL => "https://api.ripio.com/trade/orders/all",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "DELETE",
CURLOPT_POSTFIELDS => json_encode([
'pair' => 'BTC_BRL'
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"authorization: <authorization>",
"signature: <signature>",
"timestamp: <timestamp>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"strings"
"net/http"
"io"
)
func main() {
url := "https://api.ripio.com/trade/orders/all"
payload := strings.NewReader("{\n \"pair\": \"BTC_BRL\"\n}")
req, _ := http.NewRequest("DELETE", url, payload)
req.Header.Add("authorization", "<authorization>")
req.Header.Add("signature", "<signature>")
req.Header.Add("timestamp", "<timestamp>")
req.Header.Add("Content-Type", "application/json")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.delete("https://api.ripio.com/trade/orders/all")
.header("authorization", "<authorization>")
.header("signature", "<signature>")
.header("timestamp", "<timestamp>")
.header("Content-Type", "application/json")
.body("{\n \"pair\": \"BTC_BRL\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.ripio.com/trade/orders/all")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Delete.new(url)
request["authorization"] = '<authorization>'
request["signature"] = '<signature>'
request["timestamp"] = '<timestamp>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"pair\": \"BTC_BRL\"\n}"
response = http.request(request)
puts response.read_body{
"data": [
{
"order_id": "F6D2661E-4D6F-4770-BBE6-CC063CBA3770",
"pair_code": "BTC_BRL",
"success": true
},
{
"order_id": "7155ED34-9EC4-4733-8B32-1E4319CB662F",
"pair_code": "BTC_BRL",
"success": false
}
],
"error_code": null,
"message": null
}Headers
The API key as a string.
See the Generating Signature section for more details.
A timestamp in milliseconds. See the Timestamp Security section for more details.
An additional, non-required parameter, that you can send to specify the number of milliseconds after the timestamp for the request to be valid. See the Timestamp Security section for more details.
Body
application/json
Currency pair code
Example:
"BTC_BRL"
Response
200 - application/json
Ok
Show child attributes
Show child attributes
Example:
[
{
"order_id": "F6D2661E-4D6F-4770-BBE6-CC063CBA3770",
"pair_code": "BTC_BRL",
"success": true
},
{
"order_id": "7155ED34-9EC4-4733-8B32-1E4319CB662F",
"pair_code": "BTC_BRL",
"success": false
}
]
Example:
null
Example:
null
⌘I