Skip to content
Combination Rule

Add Market Rule

Create a market (combination) rule.

Request parameters

  • Required: name (rule name), market (applicable market).
  • Optional: merge, grey_market_merge (merge switches), items (rule item list).
  • Request fields are derived from the entity returned by "Market Rule Detail".

Result

On success, the rule is created and the response data is an empty object. Retrieve the new rule via the detail or list endpoint.

POSThttps://b-api.longbridge.xyz/billing/add/market/rule

Authorization

AuthorizationstringheaderRequired

Send the Broker ACCESS_TOKEN as Authorization: Bearer <token>.

Request body application/json

namestringrequired

Rule name.

marketstringrequired

Applicable market, e.g. US, HK.

mergestring

Whether to merge billing: 1 merge, 0 do not merge.

grey_market_mergestring

Whether grey-market trades are merged for billing: 1 merge, 0 do not merge.

itemsarray<object>

List of rule items. Each item has order_sources (order source list) and merge_tag.

Child attributes
order_sourcesarray<string>
merge_taginteger

Responses

HTTP 200The request was processed successfully. The response data is an empty object.
Standard response envelopecodemessagedata
dataobjectdata structure

Creation result.

idstring

Id of the newly created market rule.

HTTP 400Bad request. Check the business error code in code and the error details in message.
Standard response envelopecodemessagedata
dataobjectdata structure

No nested fields

HTTP 401The user is not authenticated, or the login session has expired.
Standard response envelopecodemessagedata
dataobjectdata structure

No nested fields

HTTP 403The current account is not authorized to use this feature. Grant the required permission to the account in User Permission.
Standard response envelopecodemessagedata
dataobjectdata structure

No nested fields

HTTP 408The request timed out. Check the business error code in code and the error details in message.
Standard response envelopecodemessagedata
dataobjectdata structure

No nested fields

Whale Docs