curl --request GET \
--url https://api-uat.dimetrades.com/api/orders \
--header 'Authorization: Bearer <token>' \
--header 'X-API-Key: <api-key>'import requests
url = "https://api-uat.dimetrades.com/api/orders"
headers = {
"Authorization": "Bearer <token>",
"X-API-Key": "<api-key>"
}
response = requests.get(url, headers=headers)
print(response.text)const options = {
method: 'GET',
headers: {Authorization: 'Bearer <token>', 'X-API-Key': '<api-key>'}
};
fetch('https://api-uat.dimetrades.com/api/orders', 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-uat.dimetrades.com/api/orders",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"X-API-Key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api-uat.dimetrades.com/api/orders"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("X-API-Key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api-uat.dimetrades.com/api/orders")
.header("Authorization", "Bearer <token>")
.header("X-API-Key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api-uat.dimetrades.com/api/orders")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
request["X-API-Key"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"data": {
"markets": [
{
"marketId": 83484843,
"isOrderAvailable": true
},
{
"marketId": 83484844,
"isOrderAvailable": false
},
{
"marketId": 83484845,
"isOrderAvailable": false
},
{
"marketId": 83484846,
"isOrderAvailable": true
}
],
"orders": [],
"pagination": {}
},
"errors": []
}List my orders
Returns the authenticated user’s orders, most recent first. Filter by market, status, and converted-order flag.
Two response modes
The response always has markets, orders and pagination; which one is
filled depends on the filter.
-
marketIdsent (or no event filter): the order list.ordersandpaginationare filled andmarketsis[]. -
eventIdsent withoutmarketId: the event’s market availability.marketslists every market of that event as{ marketId, isOrderAvailable }-truewhen the caller has at least one order in that market,falseotherwise.ordersis[]andpaginationis{}. Use it to decide which markets to fetch, then call again withmarketIdfor the orders.status,isConvertedOrderand the date filters apply to the flag too (status=openmarks only markets with resting orders). -
Both
eventIdandmarketIdsent:marketIdwins, you get the order list, restricted to that event. -
status=openis an alias that expands to the two live statuses,openandpartial— i.e. every order with quantity still resting on the book. It does not includepartially_filled, which is terminal. -
status=all(or omitted) returns every status. -
When
isConvertedOrderis set, results default tofilled/partially_filled.
⚠️ Invert the price before displaying a SELL order
Prices here are in the order book’s representation. An order you placed
as a SELL is stored as a BUY of the opposite contract at the complementary
price, flagged by isConvertedOrder: true. To show it back to the user:
if (order.isConvertedOrder) {
displaySide = order.predictionSide === 'yes' ? 'no' : 'yes'; // flip
displayPrice = 100 - order.price; // invert
}
A SELL YES @ 70¢ comes back as predictionSide: "no", price: 30. Render it
without converting and the user sees the wrong side at the wrong price.
Convert: price, predictionSide, averagePrice, sellPrice.
Do not convert: averageBuyPrice (already the real cost basis of the
sold contract), realizedPnl, buyOrderFees, sellOrderFees (dollar
amounts). price is null on market orders — guard the subtraction.
Nothing is converted when isConvertedOrder is false. Full rules and a
worked example: Conventions → Order prices.
clientOrderId is populated asynchronously (once the matching engine’s
acceptance event lands), so it may briefly read null on an order fetched
immediately after submission.
curl --request GET \
--url https://api-uat.dimetrades.com/api/orders \
--header 'Authorization: Bearer <token>' \
--header 'X-API-Key: <api-key>'import requests
url = "https://api-uat.dimetrades.com/api/orders"
headers = {
"Authorization": "Bearer <token>",
"X-API-Key": "<api-key>"
}
response = requests.get(url, headers=headers)
print(response.text)const options = {
method: 'GET',
headers: {Authorization: 'Bearer <token>', 'X-API-Key': '<api-key>'}
};
fetch('https://api-uat.dimetrades.com/api/orders', 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-uat.dimetrades.com/api/orders",
CURLOPT_RETURNTRANSFER => true,
CURLOPT_ENCODING => "",
CURLOPT_MAXREDIRS => 10,
CURLOPT_TIMEOUT => 30,
CURLOPT_HTTP_VERSION => CURL_HTTP_VERSION_1_1,
CURLOPT_CUSTOMREQUEST => "GET",
CURLOPT_HTTPHEADER => [
"Authorization: Bearer <token>",
"X-API-Key: <api-key>"
],
]);
$response = curl_exec($curl);
$err = curl_error($curl);
curl_close($curl);
if ($err) {
echo "cURL Error #:" . $err;
} else {
echo $response;
}package main
import (
"fmt"
"net/http"
"io"
)
func main() {
url := "https://api-uat.dimetrades.com/api/orders"
req, _ := http.NewRequest("GET", url, nil)
req.Header.Add("Authorization", "Bearer <token>")
req.Header.Add("X-API-Key", "<api-key>")
res, _ := http.DefaultClient.Do(req)
defer res.Body.Close()
body, _ := io.ReadAll(res.Body)
fmt.Println(string(body))
}HttpResponse<String> response = Unirest.get("https://api-uat.dimetrades.com/api/orders")
.header("Authorization", "Bearer <token>")
.header("X-API-Key", "<api-key>")
.asString();require 'uri'
require 'net/http'
url = URI("https://api-uat.dimetrades.com/api/orders")
http = Net::HTTP.new(url.host, url.port)
http.use_ssl = true
request = Net::HTTP::Get.new(url)
request["Authorization"] = 'Bearer <token>'
request["X-API-Key"] = '<api-key>'
response = http.request(request)
puts response.read_body{
"data": {
"markets": [
{
"marketId": 83484843,
"isOrderAvailable": true
},
{
"marketId": 83484844,
"isOrderAvailable": false
},
{
"marketId": 83484845,
"isOrderAvailable": false
},
{
"marketId": 83484846,
"isOrderAvailable": true
}
],
"orders": [],
"pagination": {}
},
"errors": []
}Authorizations
The end user's JWT access token, sent as Authorization: Bearer <token>.
Obtain one from POST /partner/customers or POST /partner/customers/login
— both return it as token. It identifies which of your users a call
is made for, and is sent alongside your X-API-Key on every authenticated
endpoint.
Event discovery, categories, subcategories and scores are public and need no token.
ISV / partner credential — public half. Required on every request.
Identifies the integration partner (ISV) making the call. Issued by Dime
Trades when the ISV is onboarded and sent on every /partner/* endpoint:
X-API-Key: dt_pk_live_7f3c9a2e5b18
- On the two partner endpoints that create accounts or issue tokens (
POST /partner/customers,POST /partner/customers/login), it is accompanied byX-API-Secretand is the only authentication — there is no user token yet. - On every other partner endpoint it is sent alongside the user's
Authorization: Bearer <token>: the API key says which platform is calling, the bearer token says which user it is calling for.
Credentials are scoped to one or more brands; using a key with a brandId outside that scope returns 403. Staging and production keys are separate.
The key identifies your platform — treat it as a backend credential.
Query Parameters
1 <= x <= 214748364760497
Return every market of this event with an isOrderAvailable flag for the caller (see Two response modes); orders stays empty. If marketId is also sent, the order list is returned instead, restricted to that event, so a marketId that does not belong to the event returns an empty list.
1 <= x <= 21474836475454
Filter by order status. Accepts any single value of
OrderStatus — open, partial, partially_filled,
filled, canceled, rejected, expired — matched exactly, plus two
aliases:
open— special-cased to mean live orders, expanding toopen+partialrather than matchingopenalone.all(or omitting the parameter) — no status filter.
Validated server-side: anything outside the list below is rejected with
a 400, so a typo or a stale value surfaces as an error instead of an
empty result set. In particular pending_cancel, pending_modify,
stopped, and triggered are not accepted — the first two are
acknowledgement values that are never persisted, and the last two are
legacy enum members no order has ever held.
all, open, partial, partially_filled, filled, canceled, rejected, expired "open"
1-based page number for paginated results.
x >= 1Number of rows per page.
1 <= x <= 100