curl --request POST \
--url https://github.com/openpx-trade/openpx/v1/orders/create_order \
--header 'Content-Type: application/json' \
--data '
{
"asset_id": "<string>",
"price": 123,
"size": 123,
"order_type": "gtc"
}
'import requests
url = "https://github.com/openpx-trade/openpx/v1/orders/create_order"
payload = {
"asset_id": "<string>",
"price": 123,
"size": 123,
"order_type": "gtc"
}
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({asset_id: '<string>', price: 123, size: 123, order_type: 'gtc'})
};
fetch('https://github.com/openpx-trade/openpx/v1/orders/create_order', 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://github.com/openpx-trade/openpx/v1/orders/create_order",
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([
'asset_id' => '<string>',
'price' => 123,
'size' => 123,
'order_type' => 'gtc'
]),
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://github.com/openpx-trade/openpx/v1/orders/create_order"
payload := strings.NewReader("{\n \"asset_id\": \"<string>\",\n \"price\": 123,\n \"size\": 123,\n \"order_type\": \"gtc\"\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://github.com/openpx-trade/openpx/v1/orders/create_order")
.header("Content-Type", "application/json")
.body("{\n \"asset_id\": \"<string>\",\n \"price\": 123,\n \"size\": 123,\n \"order_type\": \"gtc\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://github.com/openpx-trade/openpx/v1/orders/create_order")
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 \"asset_id\": \"<string>\",\n \"price\": 123,\n \"size\": 123,\n \"order_type\": \"gtc\"\n}"
response = http.request(request)
puts response.read_body{
"created_at": "2023-11-07T05:31:56Z",
"filled": 123,
"id": "<string>",
"market_ticker": "<string>",
"outcome": "<string>",
"price": 123,
"side": "buy",
"size": 123,
"status": "pending",
"fee": null,
"updated_at": null
}{
"kind": "Authentication",
"message": "<string>"
}create_order
Submit a new order.
curl --request POST \
--url https://github.com/openpx-trade/openpx/v1/orders/create_order \
--header 'Content-Type: application/json' \
--data '
{
"asset_id": "<string>",
"price": 123,
"size": 123,
"order_type": "gtc"
}
'import requests
url = "https://github.com/openpx-trade/openpx/v1/orders/create_order"
payload = {
"asset_id": "<string>",
"price": 123,
"size": 123,
"order_type": "gtc"
}
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({asset_id: '<string>', price: 123, size: 123, order_type: 'gtc'})
};
fetch('https://github.com/openpx-trade/openpx/v1/orders/create_order', 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://github.com/openpx-trade/openpx/v1/orders/create_order",
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([
'asset_id' => '<string>',
'price' => 123,
'size' => 123,
'order_type' => 'gtc'
]),
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://github.com/openpx-trade/openpx/v1/orders/create_order"
payload := strings.NewReader("{\n \"asset_id\": \"<string>\",\n \"price\": 123,\n \"size\": 123,\n \"order_type\": \"gtc\"\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://github.com/openpx-trade/openpx/v1/orders/create_order")
.header("Content-Type", "application/json")
.body("{\n \"asset_id\": \"<string>\",\n \"price\": 123,\n \"size\": 123,\n \"order_type\": \"gtc\"\n}")
.asString();require 'uri'
require 'net/http'
url = URI("https://github.com/openpx-trade/openpx/v1/orders/create_order")
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 \"asset_id\": \"<string>\",\n \"price\": 123,\n \"size\": 123,\n \"order_type\": \"gtc\"\n}"
response = http.request(request)
puts response.read_body{
"created_at": "2023-11-07T05:31:56Z",
"filled": 123,
"id": "<string>",
"market_ticker": "<string>",
"outcome": "<string>",
"price": 123,
"side": "buy",
"size": 123,
"status": "pending",
"fee": null,
"updated_at": null
}{
"kind": "Authentication",
"message": "<string>"
}Body
Input for create_order.
The orderable asset — Kalshi market ticker or Polymarket CTF token id (e.g. "KXBTCD-25APR1517").
Outcome to trade. Options: yes, no, or label: "<name>" (Polymarket categorical markets only).
yes, no Limit price as YES probability in (0, 1) (e.g. 0.62).
Order direction. Options: buy, sell.
buy, sell Order size in contracts (e.g. 100.0).
Time-in-force; defaults to gtc (options: gtc, ioc, fok).
gtc, ioc, fok Response
Success.
An order on the unified surface.
Order creation time (UTC) (e.g. "2026-04-25T12:00:00Z").
Cumulative filled size in contracts (e.g. 25.0).
Globally-unique exchange order id (e.g. "a1b2c3d4-...").
Unified market ticker the order belongs to (e.g. "KXBTCD-25APR1517").
Outcome label as published by the exchange (e.g. "Yes", "No", or a categorical label).
Limit price as YES probability in (0, 1) (e.g. 0.62).
Order direction. Options: buy, sell.
buy, sell Order size in contracts (e.g. 100.0).
Order lifecycle state. Options: pending, open, filled, partially_filled, cancelled, rejected.
pending, open, filled, partially_filled, cancelled, rejected Volume-weighted per-contract fee in quote dollars; null on Polymarket and on unfilled orders.
Last update time (UTC); null if untouched since creation.

