On this page

Base URL and conventions

The Broker Integration API uses REST and JSON. The current version is /api/broker/v1. Breaking changes use a new version path.

Production base URL
https://api.lumireone.com/api/broker/v1

Use HTTPS with TLS 1.2 or later. Plain HTTP is rejected. Encode requests as UTF-8 and set Content-Type: application/json for every request with a body.

The paths below are relative to the base URL. :login is the account login number; :ticket identifies an order or position.

Authentication and network access

Send your secret key in the X-Api-Key header on every endpoint. LumireOne issues keys tied to your broker account. A key can read and write only your broker’s accounts.

Placeholder key
X-Api-Key: YOUR_BROKER_API_KEY

Only a SHA-256 hash is stored server-side. The plaintext key is not persisted and cannot be recovered. Keep it securely on your server; never embed it in browser or mobile code or public repositories.

Register the static egress IPv4/IPv6 addresses of your integration servers with LumireOne. Unregistered addresses are rejected at the network edge before authentication.

Quick start

These examples use a placeholder API key and illustrative account data. Account creation writes to the production API. Generated login credentials are returned once in the response.

cURL · Create an account
export LUMIRE_API_KEY='YOUR_BROKER_API_KEY'

curl -X POST https://api.lumireone.com/api/broker/v1/accounts \
  -H "X-Api-Key: $LUMIRE_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"name":"Example Trader","currency":"USD",
       "balance":5000,"leverage":500}' 
Node.js · Server-side fetch
// Run on your server. Set LUMIRE_API_KEY securely in its environment.
const BASE = "https://api.lumireone.com/api/broker/v1";
const response = await fetch(`${BASE}/accounts`, {
  method: "POST",
  headers: {
    "X-Api-Key": process.env.LUMIRE_API_KEY,
    "Content-Type": "application/json"
  },
  body: JSON.stringify({
    name: "Example Trader", currency: "USD",
    balance: 5000, leverage: 500
  })
});
const result = await response.json();
if (!result.success) {
  throw new Error(`${result.error.code}: ${result.error.message}`);
}
// Handle result.data.login and result.data.password securely.
// Do not log credentials.

Accounts and balances

POST/accounts
Create a trading account. Omitted login and password are generated and returned once.
GET/accounts/:login
Read balance, equity, margin, free margin, margin level, leverage and status.
PATCH/accounts/:login
Update name, leverage, group_name or password.
PATCH/accounts/:login/balance
Apply a deposit or withdrawal to the account ledger.
Create-account fieldValue
nameAccount holder name (string).
currencyCurrency string, for example USD.
balanceOpening balance, zero or greater.
leverageInteger from 1 to 2000.
loginOptional string; generated if omitted.
passwordOptional string, minimum 6 characters; generated if omitted.
group_nameOptional trading group string.

Account updates use the same leverage range and password minimum. For balance operations, type is deposit or withdrawal, and amount must be positive. An optional reference_id is your idempotency/reconciliation reference; an optional comment can contain up to 500 characters.

cURL · Balance operation
# Replace ACCOUNT_LOGIN with the intended account login.
ACCOUNT_LOGIN='YOUR_ACCOUNT_LOGIN'
curl -X PATCH \
  "https://api.lumireone.com/api/broker/v1/accounts/$ACCOUNT_LOGIN/balance" \
  -H "X-Api-Key: $LUMIRE_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"type":"deposit","amount":250,"reference_id":"dep-example-001"}' 

Positions and orders

GET/accounts/:login/positions
Read open positions.
GET/accounts/:login/orders/open
Read open orders.
GET/accounts/:login/orders/pending
Read pending orders.
POST/accounts/:login/orders
Place a market or pending order.
PATCH/accounts/:login/orders/:ticket
Modify sl, tp, price or volume. Use null for sl or tp to clear them.
DELETE/accounts/:login/orders/:ticket
Close a position in full, or send a volume for a partial close.
POST/accounts/:login/orders/:ticket/cancel
Cancel a pending order.
Order fieldValue
symbolString, for example EURUSD or XAUUSD.
typemarket, limit, stop or stop_limit.
directionbuy or sell.
volumePositive number of lots.
priceRequired for limit and stop_limit.
stop_priceRequired for stop and stop_limit.
sl / tpOptional numeric stop-loss / take-profit.
commentOptional string, up to 255 characters.
Example body · POST /accounts/:login/orders
{
  "symbol": "XAUUSD",
  "type": "market",
  "direction": "buy",
  "volume": 0.10,
  "sl": 4280.0,
  "tp": 4360.0
}

For a partial close, send a body such as {"volume": 0.05} to the DELETE endpoint. Omit the body to close in full.

Reporting

GET/accounts/:login/history
Read closed-trade history.
GET/accounts/:login/stats
Read account statistics.
GET/accounts/:login/transactions
Read balance transactions.

History and transactions accept ?limit=N, with a default of 50 and a maximum of 500.

Single sign-on

POST/accounts/:login/auto-login
Generate a short-lived, single-use token for the web terminal.
GET/auto-login
Redeem the token for a JWT session pair. Pass it through ?token= or a header.
POST/auto-login/verify-2fa
Complete the 2FA challenge and receive the JWT session pair.

Generate the token from your server and redirect the user to the terminal with it. If the account has 2FA enabled, redemption returns a challenge_token instead of a session.

Example body · POST /auto-login/verify-2fa
{
  "challenge_token": "YOUR_CHALLENGE_TOKEN",
  "totp_code": "123456"
}

The TOTP code above is illustrative; use the user’s current code. Keep the API key on your server throughout this flow.

Responses, limits and errors

Check the boolean success field first. Successful responses include data; errors include error.code for programmatic handling and error.message for display.

Error response
{
  "success": false,
  "error": {
    "code": "VALIDATION_ERROR",
    "message": "amount must be positive"
  }
}

The limit is 300 requests per minute per API key, enforced across the cluster. Read the RateLimit-* headers to back off proactively. Exceeding the limit returns HTTP 429.

Error codeHTTPMeaning
UNAUTHORIZED401Missing or invalid API key.
VALIDATION_ERROR422Body or query validation failed.
NOT_FOUND404Account, order or ticket does not exist.
INVALID_TICKET400Ticket ID is not a valid number.
NO_PRICE_DATA503No live price for the symbol.
MAX_VOLUME400Order volume exceeds the allowed maximum.
RATE_LIMIT_EXCEEDED429The key exceeded 300 requests per minute.

Successful requests return HTTP 200 or 201. Other documented statuses include 400 for bad requests and 500 or 503 for server errors or temporary price-feed unavailability.

Integration support

Request credentials and register server IP addresses through [email protected]. Send technical issues to [email protected]. The portal is app.lumireone.com.

For a failed request, include the UTC timestamp, endpoint, HTTP method and error.code. Never include your full API key.

This summary follows the Broker Integration API guide, version 1.0, June 2026. Endpoints, fields and limits may change under future API versions.