curl --request POST \
--url https://api.novig.com/nbx/v2/emm/orders/batch \
--header 'Content-Type: application/json' \
--data '
[
{
"outcomeId": "123e4567-e89b-12d3-a456-426614174000",
"price": 0.667,
"qty": 110,
"currency": "CASH",
"tif": "GTC",
"ttl": 2400,
"flags": "ABC12345"
}
]
'import requests
url = "https://api.novig.com/nbx/v2/emm/orders/batch"
payload = [
{
"outcomeId": "123e4567-e89b-12d3-a456-426614174000",
"price": 0.667,
"qty": 110,
"currency": "CASH",
"tif": "GTC",
"ttl": 2400,
"flags": "ABC12345"
}
]
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify([
{
outcomeId: '123e4567-e89b-12d3-a456-426614174000',
price: 0.667,
qty: 110,
currency: 'CASH',
tif: 'GTC',
ttl: 2400,
flags: 'ABC12345'
}
])
};
fetch('https://api.novig.com/nbx/v2/emm/orders/batch', 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.novig.com/nbx/v2/emm/orders/batch",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
[
'outcomeId' => '123e4567-e89b-12d3-a456-426614174000',
'price' => 0.667,
'qty' => 110,
'currency' => 'CASH',
'tif' => 'GTC',
'ttl' => 2400,
'flags' => 'ABC12345'
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);
$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.novig.com/nbx/v2/emm/orders/batch"
payload := strings.NewReader("[\n {\n \"outcomeId\": \"123e4567-e89b-12d3-a456-426614174000\",\n \"price\": 0.667,\n \"qty\": 110,\n \"currency\": \"CASH\",\n \"tif\": \"GTC\",\n \"ttl\": 2400,\n \"flags\": \"ABC12345\"\n }\n]")
req, _ := http.NewRequest("POST", url, payload)
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.post("https://api.novig.com/nbx/v2/emm/orders/batch")
.header("Content-Type", "application/json")
.body("[\n {\n \"outcomeId\": \"123e4567-e89b-12d3-a456-426614174000\",\n \"price\": 0.667,\n \"qty\": 110,\n \"currency\": \"CASH\",\n \"tif\": \"GTC\",\n \"ttl\": 2400,\n \"flags\": \"ABC12345\"\n }\n]")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.novig.com/nbx/v2/emm/orders/batch")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "[\n {\n \"outcomeId\": \"123e4567-e89b-12d3-a456-426614174000\",\n \"price\": 0.667,\n \"qty\": 110,\n \"currency\": \"CASH\",\n \"tif\": \"GTC\",\n \"ttl\": 2400,\n \"flags\": \"ABC12345\"\n }\n]"
response = http.request(request)
puts response.read_bodyPlace order batch
Submit multiple orders (maximum 256) at once to be processed in a batch. This operation does not make guarantees about the successful execution of all orders, it only places each in the matching engine queue.
Rate limit: 32 requests per second.
curl --request POST \
--url https://api.novig.com/nbx/v2/emm/orders/batch \
--header 'Content-Type: application/json' \
--data '
[
{
"outcomeId": "123e4567-e89b-12d3-a456-426614174000",
"price": 0.667,
"qty": 110,
"currency": "CASH",
"tif": "GTC",
"ttl": 2400,
"flags": "ABC12345"
}
]
'import requests
url = "https://api.novig.com/nbx/v2/emm/orders/batch"
payload = [
{
"outcomeId": "123e4567-e89b-12d3-a456-426614174000",
"price": 0.667,
"qty": 110,
"currency": "CASH",
"tif": "GTC",
"ttl": 2400,
"flags": "ABC12345"
}
]
headers = {"Content-Type": "application/json"}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {'Content-Type': 'application/json'},
body: JSON.stringify([
{
outcomeId: '123e4567-e89b-12d3-a456-426614174000',
price: 0.667,
qty: 110,
currency: 'CASH',
tif: 'GTC',
ttl: 2400,
flags: 'ABC12345'
}
])
};
fetch('https://api.novig.com/nbx/v2/emm/orders/batch', 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.novig.com/nbx/v2/emm/orders/batch",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "POST",
CURLOPT_POSTFIELDS => json_encode([
[
'outcomeId' => '123e4567-e89b-12d3-a456-426614174000',
'price' => 0.667,
'qty' => 110,
'currency' => 'CASH',
'tif' => 'GTC',
'ttl' => 2400,
'flags' => 'ABC12345'
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json"
],
]);
$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.novig.com/nbx/v2/emm/orders/batch"
payload := strings.NewReader("[\n {\n \"outcomeId\": \"123e4567-e89b-12d3-a456-426614174000\",\n \"price\": 0.667,\n \"qty\": 110,\n \"currency\": \"CASH\",\n \"tif\": \"GTC\",\n \"ttl\": 2400,\n \"flags\": \"ABC12345\"\n }\n]")
req, _ := http.NewRequest("POST", url, payload)
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.post("https://api.novig.com/nbx/v2/emm/orders/batch")
.header("Content-Type", "application/json")
.body("[\n {\n \"outcomeId\": \"123e4567-e89b-12d3-a456-426614174000\",\n \"price\": 0.667,\n \"qty\": 110,\n \"currency\": \"CASH\",\n \"tif\": \"GTC\",\n \"ttl\": 2400,\n \"flags\": \"ABC12345\"\n }\n]")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.novig.com/nbx/v2/emm/orders/batch")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["Content-Type"] = 'application/json'
request.body = "[\n {\n \"outcomeId\": \"123e4567-e89b-12d3-a456-426614174000\",\n \"price\": 0.667,\n \"qty\": 110,\n \"currency\": \"CASH\",\n \"tif\": \"GTC\",\n \"ttl\": 2400,\n \"flags\": \"ABC12345\"\n }\n]"
response = http.request(request)
puts response.read_bodyBody
The server-generated UUID of the outcome for which the order will increase exposure
"123e4567-e89b-12d3-a456-426614174000"
The price of the order in decimal probability, up to 3 decimal places
0.667
The number of minimal currency units for the order. Note that this must be a positive integer. For CASH orders, 1 unit = 0.01 Novig Cash (e.g., 100 units = 1.00 Cash). For COIN orders, 1 unit = 1 Novig Coin
110
Denomination of the order, i.e. CASH or COIN
"CASH"
GTC, GTT, IOC, FOK, or PO (default is GTC). PO (post only) rejects the order instead of matching it immediately as a taker, so it only ever rests as a maker order.
"GTC"
Time to live for the order (milliseconds) after which the order will be automatically canceled if not totally filled. Required under GTT time-in-force; optional under PO, where it self-expires if provided and otherwise rests until canceled
2400
Custom 8-character string field for storing trader-specified flags or metadata about the order
8"ABC12345"
Response
Orders placed successfully