Batch Replace Orders
curl --request POST \
--url https://api.parlayx.com/v1/limitless/orders/replace/batch \
--header 'Content-Type: application/json' \
--header 'PX-Content-Sha256: <px-content-sha256>' \
--header 'PX-Key-Id: <px-key-id>' \
--header 'PX-Signature: <px-signature>' \
--header 'PX-Timestamp: <px-timestamp>' \
--data '
{
"orders": [
{
"orderId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"replacement": {
"marketSlug": "doge-up-or-down-daily-1787500800",
"tokenId": "10999813436902295279687793687143205491693625423224337570276428722503253471600",
"side": "BUY",
"amount": "2",
"timeInForce": {
"type": "FAK"
},
"stpPolicy": "CANCEL_MAKER"
}
}
]
}
'import requests
url = "https://api.parlayx.com/v1/limitless/orders/replace/batch"
payload = { "orders": [
{
"orderId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"replacement": {
"marketSlug": "doge-up-or-down-daily-1787500800",
"tokenId": "10999813436902295279687793687143205491693625423224337570276428722503253471600",
"side": "BUY",
"amount": "2",
"timeInForce": { "type": "FAK" },
"stpPolicy": "CANCEL_MAKER"
}
}
] }
headers = {
"PX-Key-Id": "<px-key-id>",
"PX-Timestamp": "<px-timestamp>",
"PX-Signature": "<px-signature>",
"PX-Content-Sha256": "<px-content-sha256>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {
'PX-Key-Id': '<px-key-id>',
'PX-Timestamp': '<px-timestamp>',
'PX-Signature': '<px-signature>',
'PX-Content-Sha256': '<px-content-sha256>',
'Content-Type': 'application/json'
},
body: JSON.stringify({
orders: [
{
orderId: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
replacement: {
marketSlug: 'doge-up-or-down-daily-1787500800',
tokenId: '10999813436902295279687793687143205491693625423224337570276428722503253471600',
side: 'BUY',
amount: '2',
timeInForce: {type: 'FAK'},
stpPolicy: 'CANCEL_MAKER'
}
}
]
})
};
fetch('https://api.parlayx.com/v1/limitless/orders/replace/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.parlayx.com/v1/limitless/orders/replace/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([
'orders' => [
[
'orderId' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'replacement' => [
'marketSlug' => 'doge-up-or-down-daily-1787500800',
'tokenId' => '10999813436902295279687793687143205491693625423224337570276428722503253471600',
'side' => 'BUY',
'amount' => '2',
'timeInForce' => [
'type' => 'FAK'
],
'stpPolicy' => 'CANCEL_MAKER'
]
]
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"PX-Content-Sha256: <px-content-sha256>",
"PX-Key-Id: <px-key-id>",
"PX-Signature: <px-signature>",
"PX-Timestamp: <px-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.parlayx.com/v1/limitless/orders/replace/batch"
payload := strings.NewReader("{\n \"orders\": [\n {\n \"orderId\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"replacement\": {\n \"marketSlug\": \"doge-up-or-down-daily-1787500800\",\n \"tokenId\": \"10999813436902295279687793687143205491693625423224337570276428722503253471600\",\n \"side\": \"BUY\",\n \"amount\": \"2\",\n \"timeInForce\": {\n \"type\": \"FAK\"\n },\n \"stpPolicy\": \"CANCEL_MAKER\"\n }\n }\n ]\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("PX-Key-Id", "<px-key-id>")
req.Header.Add("PX-Timestamp", "<px-timestamp>")
req.Header.Add("PX-Signature", "<px-signature>")
req.Header.Add("PX-Content-Sha256", "<px-content-sha256>")
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.parlayx.com/v1/limitless/orders/replace/batch")
.header("PX-Key-Id", "<px-key-id>")
.header("PX-Timestamp", "<px-timestamp>")
.header("PX-Signature", "<px-signature>")
.header("PX-Content-Sha256", "<px-content-sha256>")
.header("Content-Type", "application/json")
.body("{\n \"orders\": [\n {\n \"orderId\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"replacement\": {\n \"marketSlug\": \"doge-up-or-down-daily-1787500800\",\n \"tokenId\": \"10999813436902295279687793687143205491693625423224337570276428722503253471600\",\n \"side\": \"BUY\",\n \"amount\": \"2\",\n \"timeInForce\": {\n \"type\": \"FAK\"\n },\n \"stpPolicy\": \"CANCEL_MAKER\"\n }\n }\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.parlayx.com/v1/limitless/orders/replace/batch")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["PX-Key-Id"] = '<px-key-id>'
request["PX-Timestamp"] = '<px-timestamp>'
request["PX-Signature"] = '<px-signature>'
request["PX-Content-Sha256"] = '<px-content-sha256>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"orders\": [\n {\n \"orderId\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"replacement\": {\n \"marketSlug\": \"doge-up-or-down-daily-1787500800\",\n \"tokenId\": \"10999813436902295279687793687143205491693625423224337570276428722503253471600\",\n \"side\": \"BUY\",\n \"amount\": \"2\",\n \"timeInForce\": {\n \"type\": \"FAK\"\n },\n \"stpPolicy\": \"CANCEL_MAKER\"\n }\n }\n ]\n}"
response = http.request(request)
puts response.read_body{
"results": [
{
"orderId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"cancelOutcome": "CANCELLED",
"replacementOutcome": "ACCEPTED",
"replacement": {
"orderId": "3f8b2c9a-2d18-4f7e-9c2a-1b6e1f0c8a4d",
"status": "OPEN"
},
"cancelError": {
"code": "INVALID_REQUEST"
},
"replacementError": {
"code": "INVALID_REQUEST"
}
}
]
}{
"error": {
"code": "INVALID_REQUEST",
"message": "<string>",
"orderId": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
}
}{
"error": {
"code": "UNAUTHORIZED",
"message": "<string>"
}
}{
"error": {
"code": "UNAUTHORIZED",
"message": "<string>"
}
}{
"error": {
"code": "UNAUTHORIZED",
"message": "<string>"
}
}{
"error": {
"code": "INVALID_REQUEST",
"message": "<string>",
"orderId": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
}
}{
"error": {
"code": "UNAUTHORIZED",
"message": "<string>"
}
}Limitless
Batch Replace Orders
Replace up to 2 orders with independent cancel and replacement outcomes.
POST
/
v1
/
limitless
/
orders
/
replace
/
batch
Batch Replace Orders
curl --request POST \
--url https://api.parlayx.com/v1/limitless/orders/replace/batch \
--header 'Content-Type: application/json' \
--header 'PX-Content-Sha256: <px-content-sha256>' \
--header 'PX-Key-Id: <px-key-id>' \
--header 'PX-Signature: <px-signature>' \
--header 'PX-Timestamp: <px-timestamp>' \
--data '
{
"orders": [
{
"orderId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"replacement": {
"marketSlug": "doge-up-or-down-daily-1787500800",
"tokenId": "10999813436902295279687793687143205491693625423224337570276428722503253471600",
"side": "BUY",
"amount": "2",
"timeInForce": {
"type": "FAK"
},
"stpPolicy": "CANCEL_MAKER"
}
}
]
}
'import requests
url = "https://api.parlayx.com/v1/limitless/orders/replace/batch"
payload = { "orders": [
{
"orderId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"replacement": {
"marketSlug": "doge-up-or-down-daily-1787500800",
"tokenId": "10999813436902295279687793687143205491693625423224337570276428722503253471600",
"side": "BUY",
"amount": "2",
"timeInForce": { "type": "FAK" },
"stpPolicy": "CANCEL_MAKER"
}
}
] }
headers = {
"PX-Key-Id": "<px-key-id>",
"PX-Timestamp": "<px-timestamp>",
"PX-Signature": "<px-signature>",
"PX-Content-Sha256": "<px-content-sha256>",
"Content-Type": "application/json"
}
response = requests.post(url, json=payload, headers=headers)
print(response.text)const options = {
method: 'POST',
headers: {
'PX-Key-Id': '<px-key-id>',
'PX-Timestamp': '<px-timestamp>',
'PX-Signature': '<px-signature>',
'PX-Content-Sha256': '<px-content-sha256>',
'Content-Type': 'application/json'
},
body: JSON.stringify({
orders: [
{
orderId: '3c90c3cc-0d44-4b50-8888-8dd25736052a',
replacement: {
marketSlug: 'doge-up-or-down-daily-1787500800',
tokenId: '10999813436902295279687793687143205491693625423224337570276428722503253471600',
side: 'BUY',
amount: '2',
timeInForce: {type: 'FAK'},
stpPolicy: 'CANCEL_MAKER'
}
}
]
})
};
fetch('https://api.parlayx.com/v1/limitless/orders/replace/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.parlayx.com/v1/limitless/orders/replace/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([
'orders' => [
[
'orderId' => '3c90c3cc-0d44-4b50-8888-8dd25736052a',
'replacement' => [
'marketSlug' => 'doge-up-or-down-daily-1787500800',
'tokenId' => '10999813436902295279687793687143205491693625423224337570276428722503253471600',
'side' => 'BUY',
'amount' => '2',
'timeInForce' => [
'type' => 'FAK'
],
'stpPolicy' => 'CANCEL_MAKER'
]
]
]
]),
CURLOPT_HTTPHEADER => [
"Content-Type: application/json",
"PX-Content-Sha256: <px-content-sha256>",
"PX-Key-Id: <px-key-id>",
"PX-Signature: <px-signature>",
"PX-Timestamp: <px-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.parlayx.com/v1/limitless/orders/replace/batch"
payload := strings.NewReader("{\n \"orders\": [\n {\n \"orderId\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"replacement\": {\n \"marketSlug\": \"doge-up-or-down-daily-1787500800\",\n \"tokenId\": \"10999813436902295279687793687143205491693625423224337570276428722503253471600\",\n \"side\": \"BUY\",\n \"amount\": \"2\",\n \"timeInForce\": {\n \"type\": \"FAK\"\n },\n \"stpPolicy\": \"CANCEL_MAKER\"\n }\n }\n ]\n}")
req, _ := http.NewRequest("POST", url, payload)
req.Header.Add("PX-Key-Id", "<px-key-id>")
req.Header.Add("PX-Timestamp", "<px-timestamp>")
req.Header.Add("PX-Signature", "<px-signature>")
req.Header.Add("PX-Content-Sha256", "<px-content-sha256>")
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.parlayx.com/v1/limitless/orders/replace/batch")
.header("PX-Key-Id", "<px-key-id>")
.header("PX-Timestamp", "<px-timestamp>")
.header("PX-Signature", "<px-signature>")
.header("PX-Content-Sha256", "<px-content-sha256>")
.header("Content-Type", "application/json")
.body("{\n \"orders\": [\n {\n \"orderId\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"replacement\": {\n \"marketSlug\": \"doge-up-or-down-daily-1787500800\",\n \"tokenId\": \"10999813436902295279687793687143205491693625423224337570276428722503253471600\",\n \"side\": \"BUY\",\n \"amount\": \"2\",\n \"timeInForce\": {\n \"type\": \"FAK\"\n },\n \"stpPolicy\": \"CANCEL_MAKER\"\n }\n }\n ]\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://api.parlayx.com/v1/limitless/orders/replace/batch")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Post.new(url)
request["PX-Key-Id"] = '<px-key-id>'
request["PX-Timestamp"] = '<px-timestamp>'
request["PX-Signature"] = '<px-signature>'
request["PX-Content-Sha256"] = '<px-content-sha256>'
request["Content-Type"] = 'application/json'
request.body = "{\n \"orders\": [\n {\n \"orderId\": \"3c90c3cc-0d44-4b50-8888-8dd25736052a\",\n \"replacement\": {\n \"marketSlug\": \"doge-up-or-down-daily-1787500800\",\n \"tokenId\": \"10999813436902295279687793687143205491693625423224337570276428722503253471600\",\n \"side\": \"BUY\",\n \"amount\": \"2\",\n \"timeInForce\": {\n \"type\": \"FAK\"\n },\n \"stpPolicy\": \"CANCEL_MAKER\"\n }\n }\n ]\n}"
response = http.request(request)
puts response.read_body{
"results": [
{
"orderId": "3c90c3cc-0d44-4b50-8888-8dd25736052a",
"cancelOutcome": "CANCELLED",
"replacementOutcome": "ACCEPTED",
"replacement": {
"orderId": "3f8b2c9a-2d18-4f7e-9c2a-1b6e1f0c8a4d",
"status": "OPEN"
},
"cancelError": {
"code": "INVALID_REQUEST"
},
"replacementError": {
"code": "INVALID_REQUEST"
}
}
]
}{
"error": {
"code": "INVALID_REQUEST",
"message": "<string>",
"orderId": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
}
}{
"error": {
"code": "UNAUTHORIZED",
"message": "<string>"
}
}{
"error": {
"code": "UNAUTHORIZED",
"message": "<string>"
}
}{
"error": {
"code": "UNAUTHORIZED",
"message": "<string>"
}
}{
"error": {
"code": "INVALID_REQUEST",
"message": "<string>",
"orderId": "3c90c3cc-0d44-4b50-8888-8dd25736052a"
}
}{
"error": {
"code": "UNAUTHORIZED",
"message": "<string>"
}
}Headers
The key id issued for your signing keypair.
Unix seconds at signing, valid within 30 seconds of the server clock.
Ed25519 signature of the request
Hex SHA-256 of the request body, or the SHA-256 of the empty string when there is no body.
Body
application/json
Required array length:
1 - 2 elementsShow child attributes
Show child attributes
Response
Per-order outcomes
Show child attributes
Show child attributes