{ "$schema": "https://json-schema.org/draft/2020-12/schema", "$id": "https://raw.githubusercontent.com/api-evangelist/moment/main/json-schema/moment-event-data-schema.json", "title": "Event Data", "x-generated": "2026-10-14", "x-method": "derived", "x-generator": "derive-json-schema.py", "x-source": "openapi/moment-orders-api-openapi.yml#/components/schemas/EventData", "type": "object", "oneOf": [ { "$ref": "#/$defs/RequestEvent" }, { "$ref": "#/$defs/RejectEvent" }, { "$ref": "#/$defs/ApproveEvent" }, { "$ref": "#/$defs/CancelEvent" }, { "$ref": "#/$defs/ExecutionEvent" }, { "$ref": "#/$defs/AllocationCreateEvent" }, { "$ref": "#/$defs/AllocationRejectEvent" }, { "$ref": "#/$defs/AllocationApproveEvent" }, { "$ref": "#/$defs/AllocationCancelEvent" }, { "$ref": "#/$defs/AllocationCalculateEvent" }, { "$ref": "#/$defs/AllocationSubmitEvent" }, { "$ref": "#/$defs/AllocationFailEvent" }, { "$ref": "#/$defs/CancelRequestEvent" }, { "$ref": "#/$defs/CancelRejectEvent" }, { "$ref": "#/$defs/CancelAllocationRequestEvent" }, { "$ref": "#/$defs/CancelAllocationRejectEvent" }, { "$ref": "#/$defs/FlaggedForReviewEvent" }, { "$ref": "#/$defs/ManualApproveRequestEvent" }, { "$ref": "#/$defs/ManualApproveFailureEvent" }, { "$ref": "#/$defs/ManualRejectRequestEvent" }, { "$ref": "#/$defs/ManualRejectFailureEvent" }, { "$ref": "#/$defs/ExternalTradeReportRequestEvent" }, { "$ref": "#/$defs/ExternalTradeReportRejectEvent" }, { "$ref": "#/$defs/ExecutionOrderRequestEvent" }, { "$ref": "#/$defs/ExecutionOrderRejectEvent" }, { "$ref": "#/$defs/ExecutionOrderCreateEvent" }, { "$ref": "#/$defs/ExecutionOrderCancelRequestEvent" }, { "$ref": "#/$defs/ExecutionOrderCancelRejectEvent" }, { "$ref": "#/$defs/ExecutionOrderCancelEvent" }, { "$ref": "#/$defs/RFQCreateEvent" } ], "$defs": { "AccountAllocationDetails": { "description": "The account allocation details specify the amount of the order that was allocated to a specific account.", "type": "object", "properties": { "account_id": { "$ref": "#/$defs/AccountID" }, "accrued_interest": { "description": "The pro-rated coupon payment that will be either paid or received when the trade is settled. Expressed in USD.", "type": "number" }, "actual_amount": { "$ref": "#/$defs/OrderSize" }, "client_account_allocation_id": { "description": "Client-provided unique ID for the account allocation; for example, to cross-reference with an internal system. Values must be unique within the trading day.", "type": "string" }, "fill_price": { "$ref": "#/$defs/LimitPrice" }, "net_money": { "description": "Actual cash flow of the order.", "type": "number" }, "pre_fee_net_money": { "description": "Net money of the order before fees are applied.", "type": "number" }, "requested_amount": { "$ref": "#/$defs/OrderSize" }, "venue_execution_id": { "description": "The identifier for the trade as provided by the venue.", "type": "string" }, "venue_mpid": { "description": "The Market Participant Identifier (MPID) of the venue where the trade was executed.", "type": "string" } }, "title": "Account Allocation Details" }, "AccountAllocationRequest": { "description": "The account allocation request specifies the amount of the order to allocate to a specific account.\nNote that requested_amount values must be a multiple of the par size of the bond.", "type": "object", "properties": { "account_configuration": { "$ref": "#/$defs/AccountConfiguration" }, "account_id": { "$ref": "#/$defs/AccountID" }, "client_account_allocation_id": { "description": "Client-provided unique ID for the account allocation; for example, to cross-reference with an internal system. Values must be unique within the trading day.", "type": "string" }, "custodian_id": { "description": "The ID of the custodian for the account allocation.", "type": "string" }, "requested_amount": { "$ref": "#/$defs/OrderSize" } }, "title": "Account Allocation Request" }, "AccountConfiguration": { "title": "Account Configuration", "type": "object", "description": "Account configuration for the allocation", "properties": { "prime_brokerage_enabled": { "type": "boolean", "description": "Whether the prime brokerage is enabled for the account.", "x-go-type-skip-optional-pointer": true }, "household_id": { "type": "string", "description": "The ID of the household for the account.", "x-go-type-skip-optional-pointer": true, "x-go-name": "HouseholdID" }, "manager_id": { "type": "string", "description": "The accounts-service platform advisor for the account: an\naccount group, not a person. The person credited with the trade\nis iar.\n", "x-go-type-skip-optional-pointer": true, "x-go-name": "ManagerID" }, "custodian_advisor_id": { "description": "The custodian's own identifier for the manager_id account group at\nthis custodian: the rep code. Stored as sent.\n", "type": "string", "x-go-type-skip-optional-pointer": true, "x-go-name": "CustodianAdvisorID" }, "custodian_id": { "$ref": "#/$defs/CustodianID" }, "booking_type": { "allOf": [ { "$ref": "#/$defs/BookingType" } ], "x-go-type-skip-optional-pointer": true }, "custodian_tax_lot_id": { "description": "The tax lot ID assigned by the custodian. Deprecated, use lot_instruction.custodian_tax_lot_id instead.", "type": "string", "deprecated": true }, "is_discretionary": { "description": "Whether the introducing broker exercised discretion on behalf of the end client on this particular order.", "type": "boolean" }, "is_solicited": { "description": "Whether the order was solicited. Must be unset if the order is discretionary.", "type": "boolean" }, "is_natural_person": { "description": "Whether the account is held by a natural person rather than a\nlegal entity. Omit when the holder cannot be classified, as a\ntrust or an estate may not be. An attestation control can be\nlimited to the accounts this is true of.\n", "type": "boolean" }, "lot_instruction": { "$ref": "#/$defs/LotInstruction" }, "iar": { "allOf": [ { "$ref": "#/$defs/InvestmentAdvisorRepresentative" } ], "x-go-name": "IAR" } } }, "AccountID": { "type": "string", "title": "AccountID", "description": "Unique ID of user account" }, "AggressivenessLevel": { "title": "Aggressiveness Level", "type": "string", "description": "Execution aggressiveness for a custodian algo. Required by some custodians (e.g. Fidelity);\nignored by custodians without an equivalent concept (e.g. Schwab).", "enum": [ "passive", "neutral", "aggressive" ], "x-enumNames": [ "AggressivenessLevelPassive", "AggressivenessLevelNeutral", "AggressivenessLevelAggressive" ] }, "AlgoParameters": { "title": "Algo Parameters", "type": "object", "description": "Execution parameters for custodian algos. Exactly one of `twap`, `vwap`, `pov`, or `is` must be set.\nOnly supported on the custodian protocol with the manual strategy. Fields or values not accepted\nby a given custodian are rejected downstream.", "properties": { "twap": { "$ref": "#/$defs/TwapParameters" }, "vwap": { "$ref": "#/$defs/VwapParameters" }, "pov": { "$ref": "#/$defs/PovParameters" }, "is": { "$ref": "#/$defs/IsParameters" } } }, "AllOrNone": { "description": "If set to true, the entire order quantity will be filled or none at all. There will be no partial fills.", "type": "boolean", "default": false, "title": "All or None", "x-go-type-skip-optional-pointer": true }, "AllocationAccountRequest": { "title": "Allocation Account Request", "type": "object", "description": "The account allocation request specifies the amount of the order to allocate to a specific account.\nNote that requested_amount values must be a multiple of the par size of the bond.", "required": [ "client_account_allocation_id", "account_id", "requested_amount" ], "properties": { "client_account_allocation_id": { "type": "string", "description": "Client-provided unique ID for the account allocation; for example, to cross-reference with an internal system. Values must be unique within the trading day.", "x-go-name": "ClientAccountAllocationID" }, "account_id": { "type": "string", "description": "Unique ID of user account", "x-go-name": "AccountID" }, "requested_amount": { "$ref": "#/$defs/OrderSize" }, "account_configuration": { "$ref": "#/$defs/AccountConfiguration" }, "moment_sleeve_id": { "type": "string", "description": "The Moment internal ID of the sleeve to allocate the order to.", "x-go-name": "MomentSleeveID" }, "order_received_at": { "type": "string", "format": "date-time", "description": "When the end client confirmed the order for this account." }, "order_received_by": { "description": "Who took that confirmation, by Moment user reference or by name.", "allOf": [ { "$ref": "#/$defs/InvestmentAdvisorRepresentative" } ] } } }, "AllocationApproveEvent": { "type": "object", "properties": { "event": { "$ref": "#/$defs/AllocationApproveEventEventPayload" }, "event_id": { "$ref": "#/$defs/EventID" }, "msg_number": { "$ref": "#/$defs/MsgNumber" }, "msg_type": { "type": "string", "enum": [ "allocation_update" ] }, "summary": { "$ref": "#/$defs/AllocationSummary" } }, "title": "Allocation Approve Event" }, "AllocationApproveEventEventPayload": { "type": "object", "properties": { "allocation_id": { "$ref": "#/$defs/AllocationID" }, "client_allocation_id": { "$ref": "#/$defs/ClientAllocationID" }, "event_type": { "type": "string", "enum": [ "allocation_approve" ], "x-enum-varnames": [ "EventTypeAllocationApprove" ] }, "time": { "type": "string", "format": "date-time" } } }, "AllocationCalculateEvent": { "type": "object", "properties": { "event": { "$ref": "#/$defs/AllocationCalculateEventEventPayload" }, "event_id": { "$ref": "#/$defs/EventID" }, "msg_number": { "$ref": "#/$defs/MsgNumber" }, "msg_type": { "type": "string", "enum": [ "allocation_update" ] }, "summary": { "$ref": "#/$defs/AllocationSummary" } }, "title": "Allocation Calculate Event" }, "AllocationCalculateEventEventPayload": { "type": "object", "properties": { "account_allocations": { "type": "array", "items": { "$ref": "#/$defs/AccountAllocationDetails" } }, "allocation_id": { "$ref": "#/$defs/AllocationID" }, "allocation_strategy": { "$ref": "#/$defs/AllocationStrategy" }, "client_allocation_id": { "$ref": "#/$defs/ClientAllocationID" }, "client_order_id": { "type": "string" }, "custodian_id": { "type": "string" }, "event_type": { "type": "string", "enum": [ "allocation_calculate" ], "x-enum-varnames": [ "EventTypeAllocationCalculate" ] }, "ib_id": { "type": "string" }, "order_id": { "type": "string" }, "risk_group_id": { "type": "string" }, "time": { "type": "string", "format": "date-time" }, "trades": { "type": "array", "items": { "$ref": "#/$defs/AllocationTrade" } } } }, "AllocationCancelEvent": { "type": "object", "properties": { "event": { "$ref": "#/$defs/AllocationCancelEventEventPayload" }, "event_id": { "$ref": "#/$defs/EventID" }, "msg_number": { "$ref": "#/$defs/MsgNumber" }, "msg_type": { "type": "string", "enum": [ "allocation_update" ] }, "summary": { "$ref": "#/$defs/AllocationSummary" } }, "title": "Allocation Cancel Event" }, "AllocationCancelEventEventPayload": { "type": "object", "properties": { "allocation_id": { "$ref": "#/$defs/AllocationID" }, "client_allocation_id": { "$ref": "#/$defs/ClientAllocationID" }, "code": { "type": "number" }, "event_type": { "type": "string", "enum": [ "allocation_cancel" ], "x-enum-varnames": [ "EventTypeAllocationCancel" ] }, "reason": { "type": "string" }, "time": { "type": "string", "format": "date-time" } } }, "AllocationCreateEvent": { "type": "object", "properties": { "event": { "$ref": "#/$defs/AllocationCreateEventEventPayload" }, "event_id": { "$ref": "#/$defs/EventID" }, "msg_number": { "$ref": "#/$defs/MsgNumber" }, "msg_type": { "type": "string", "enum": [ "allocation_update" ] }, "summary": { "$ref": "#/$defs/AllocationSummary" } }, "title": "Allocation Create Event" }, "AllocationCreateEventEventPayload": { "type": "object", "properties": { "allocation_id": { "$ref": "#/$defs/AllocationID" }, "allocation_strategy": { "$ref": "#/$defs/AllocationStrategy" }, "client_allocation_id": { "$ref": "#/$defs/ClientAllocationID" }, "client_order_id": { "type": "string" }, "custodian_id": { "type": "string" }, "event_type": { "type": "string", "enum": [ "allocation_create" ], "x-enum-varnames": [ "EventTypeAllocationCreate" ] }, "ib_id": { "$ref": "#/$defs/IntroducingBrokerID" }, "order_id": { "type": "string" }, "risk_group_id": { "type": "string" }, "time": { "type": "string", "format": "date-time" } } }, "AllocationFailEvent": { "type": "object", "properties": { "event": { "$ref": "#/$defs/AllocationFailEventEventPayload" }, "event_id": { "$ref": "#/$defs/EventID" }, "msg_number": { "$ref": "#/$defs/MsgNumber" }, "msg_type": { "type": "string", "enum": [ "allocation_update" ] }, "summary": { "$ref": "#/$defs/AllocationSummary" } }, "title": "Allocation Fail Event" }, "AllocationFailEventEventPayload": { "type": "object", "properties": { "allocation_id": { "$ref": "#/$defs/AllocationID" }, "client_allocation_id": { "$ref": "#/$defs/ClientAllocationID" }, "code": { "description": "The error code for the failure.", "type": "number" }, "event_type": { "type": "string", "enum": [ "allocation_fail" ], "x-enum-varnames": null }, "reason": { "description": "The reason for the failure.", "type": "string" }, "time": { "type": "string", "format": "date-time" } } }, "AllocationID": { "description": "Unique, Moment-generated ID for the allocation.", "type": "string", "title": "Allocation ID" }, "AllocationRejectEvent": { "type": "object", "properties": { "event": { "$ref": "#/$defs/AllocationRejectEventEventPayload" }, "event_id": { "$ref": "#/$defs/EventID" }, "msg_number": { "$ref": "#/$defs/MsgNumber" }, "msg_type": { "type": "string", "enum": [ "allocation_update" ] }, "summary": { "$ref": "#/$defs/AllocationSummary" } }, "title": "Allocation Reject Event" }, "AllocationRejectEventEventPayload": { "type": "object", "properties": { "allocation_id": { "$ref": "#/$defs/AllocationID" }, "client_allocation_id": { "$ref": "#/$defs/ClientAllocationID" }, "code": { "type": "number" }, "event_type": { "type": "string", "enum": [ "allocation_reject" ], "x-enum-varnames": [ "EventTypeAllocationReject" ] }, "reason": { "type": "string" }, "time": { "type": "string", "format": "date-time" } } }, "AllocationRequest": { "title": "Allocation Request", "type": "object", "required": [ "strategy", "client_allocation_id", "account_allocations" ], "properties": { "strategy": { "type": "string", "enum": [ "fifo_without_averaging", "fifo_with_averaging", "pro_rata_with_averaging" ], "description": "Strategy for allocation. Determines how the block's filled quantity is distributed across requested accounts.\n- `fifo_without_averaging`: allocates on a first-in, first-out basis without averaging; preserves individual trade prices per allocation.\n- `fifo_with_averaging`: allocates first-in, first-out and applies the block's average fill price to each allocation.\n- `pro_rata_with_averaging`: allocates pro-rata across requested accounts and applies the block's average fill price. Typically used for equity and ETF block orders.\n\n**RIA accounts must use `fifo_without_averaging`.** The averaging\nstrategies (`fifo_with_averaging`, `pro_rata_with_averaging`) require a\nprincipal/averaging trading account to average executions before they are\nbooked to client accounts. RIAs trade in an agency capacity and must report\nthe actual street-execution prices and quantities to their custodian (e.g.\nSchwab), so each allocation has to match a real executed trade. Because there\nis no averaging account to absorb the difference, averaged allocation is not\navailable to RIAs — only the non-averaging FIFO strategy, which preserves the\ntrue per-trade execution prices, is supported.\n" }, "client_allocation_id": { "type": "string", "description": "Client-provided ID for the allocation", "x-go-name": "ClientAllocationID" }, "account_allocations": { "type": "array", "description": "Account allocations for an individual order", "items": { "$ref": "#/$defs/AllocationAccountRequest" } } } }, "AllocationStatus": { "type": "string", "enum": [ "created", "approved", "rejected", "calculated", "submitted", "failed", "canceled" ], "title": "Allocation Status", "x-enum-varnames": [ "AllocationStatusCreated", "AllocationStatusApproved", "AllocationStatusRejected", "AllocationStatusCalculated", "AllocationStatusSubmitted", "AllocationStatusFailed", "AllocationStatusCanceled" ] }, "AllocationStrategy": { "description": "The allocation strategy to use for the order. The allocation strategy must be valid for the custodian and determines how the order is allocated across multiple accounts.\n-\t`fifo_without_averaging`\n Allocates the filled quantity on a first-in, first-out basis (FIFO) without averaging; maintaining the individual trade prices for each allocation.\n-\t`fifo_with_averaging`\n Allocates the filled quantity on a first-in, first-out basis (FIFO) and applies the block's average fill price to each allocation.\n-\t`pro_rata_with_averaging`\n Allocates the filled quantity pro-rata across requested accounts and applies the block's average fill price to each allocation. Typically used for equity and ETF block orders.", "type": "string", "enum": [ "fifo_without_averaging", "fifo_with_averaging", "pro_rata_with_averaging" ], "title": "Allocation Strategy" }, "AllocationSubmitEvent": { "type": "object", "properties": { "event": { "$ref": "#/$defs/AllocationSubmitEventEventPayload" }, "event_id": { "$ref": "#/$defs/EventID" }, "msg_number": { "$ref": "#/$defs/MsgNumber" }, "msg_type": { "type": "string", "enum": [ "allocation_update" ] }, "summary": { "$ref": "#/$defs/AllocationSummary" } }, "title": "Allocation Submit Event" }, "AllocationSubmitEventEventPayload": { "type": "object", "properties": { "allocation_id": { "$ref": "#/$defs/AllocationID" }, "client_allocation_id": { "$ref": "#/$defs/ClientAllocationID" }, "custodian_id": { "type": "string" }, "event_type": { "type": "string", "enum": [ "allocation_submit" ], "x-enum-varnames": [ "EventTypeAllocationSubmit" ] }, "time": { "type": "string", "format": "date-time" } } }, "AllocationSummary": { "type": "object", "properties": { "account_allocations": { "type": "array", "items": { "$ref": "#/$defs/AccountAllocationDetails" } }, "account_requests": { "type": "array", "items": { "$ref": "#/$defs/AccountAllocationRequest" } }, "calculated_at": { "description": "The time at which the allocation was calculated.", "type": [ "string", "null" ], "format": "date-time" }, "client_allocation_id": { "$ref": "#/$defs/ClientAllocationID" }, "client_order_id": { "$ref": "#/$defs/ClientOrderID" }, "custodian_id": { "$ref": "#/$defs/CustodianID" }, "ib_id": { "$ref": "#/$defs/IntroducingBrokerID" }, "id": { "$ref": "#/$defs/AllocationID" }, "order_id": { "$ref": "#/$defs/OrderID" }, "risk_group_id": { "description": "The risk group ID used for this allocation.", "type": "string" }, "status": { "$ref": "#/$defs/AllocationStatus" }, "strategy": { "$ref": "#/$defs/AllocationStrategy" }, "submitted_at": { "description": "The time at which the allocation was submitted to the custodian for booking.", "type": [ "string", "null" ], "format": "date-time" }, "trades": { "type": "array", "items": { "$ref": "#/$defs/AllocationTrade" } } }, "title": "Allocation Summary" }, "AllocationTrade": { "type": "object", "properties": { "accrued_interest": { "description": "The pro-rated coupon payment that will be either paid or received when the trade is settled. Expressed in USD.", "type": "number" }, "amount": { "$ref": "#/$defs/OrderSize" }, "net_money": { "description": "Actual cash flow of the order.", "type": "number" }, "pre_fee_net_money": { "description": "Net money of the order before fees are applied.", "type": "number" }, "price": { "$ref": "#/$defs/LimitPrice" }, "venue_execution_id": { "description": "The identifier for the trade as provided by the venue.", "type": "string" }, "venue_mpid": { "description": "The Market Participant Identifier (MPID) of the venue where the trade was executed.", "type": "string" } }, "title": "Allocation Trade" }, "Annotation": { "description": "Client-provided custom metadata for the order.", "type": "string", "maxLength": 1024, "title": "annotation" }, "ApproveEvent": { "type": "object", "properties": { "event": { "$ref": "#/$defs/ApproveEventEventPayload" }, "event_id": { "$ref": "#/$defs/EventID" }, "msg_number": { "$ref": "#/$defs/MsgNumber" }, "msg_type": { "type": "string", "enum": [ "order_update" ] }, "order": { "$ref": "#/$defs/Order" } }, "title": "Approve Event" }, "ApproveEventEventPayload": { "type": "object", "properties": { "client_order_id": { "type": "string" }, "event_type": { "type": "string", "enum": [ "approve" ], "x-enum-varnames": [ "EventTypeApprove" ] }, "order_id": { "type": "string" }, "time": { "type": "string", "format": "date-time" } } }, "BookingType": { "type": "string", "title": "BookingType", "description": "The booking type for the account.", "enum": [ "cash", "margin" ], "x-enumNames": [ "BookingTypeCash", "BookingTypeMargin" ] }, "CancelAllocationRejectEvent": { "type": "object", "properties": { "event": { "$ref": "#/$defs/CancelAllocationRejectEventEventPayload" }, "event_id": { "$ref": "#/$defs/EventID" }, "msg_number": { "$ref": "#/$defs/MsgNumber" }, "msg_type": { "type": "string", "enum": [ "system_update" ] } }, "title": "Cancel Allocation Reject Event" }, "CancelAllocationRejectEventEventPayload": { "type": "object", "properties": { "allocation_id": { "$ref": "#/$defs/AllocationID" }, "cancel_reject_code": { "type": "number" }, "cancel_reject_reason": { "type": "string" }, "cancel_request_id": { "type": "string" }, "event_type": { "type": "string", "enum": [ "cancel_allocation_reject" ], "x-enum-varnames": [ "EventTypeCancelAllocationReject" ] }, "order_id": { "description": "The ID of the parent order.", "type": "string" }, "time": { "type": "string", "format": "date-time" } } }, "CancelAllocationRequestEvent": { "type": "object", "properties": { "event": { "$ref": "#/$defs/CancelAllocationRequestEventEventPayload" }, "event_id": { "$ref": "#/$defs/EventID" }, "msg_number": { "$ref": "#/$defs/MsgNumber" }, "msg_type": { "type": "string", "enum": [ "system_update" ] } }, "title": "Cancel Allocation Request Event" }, "CancelAllocationRequestEventEventPayload": { "type": "object", "properties": { "allocation_id": { "$ref": "#/$defs/AllocationID" }, "cancel_request_id": { "type": "string" }, "event_type": { "type": "string", "enum": [ "cancel_allocation_request" ], "x-enum-varnames": [ "EventTypeCancelAllocationRequest" ] }, "order_id": { "description": "The ID of the parent order.", "type": "string" }, "source": { "type": "string" }, "time": { "type": "string", "format": "date-time" } } }, "CancelEvent": { "type": "object", "properties": { "event": { "$ref": "#/$defs/CancelEventEventPayload" }, "event_id": { "$ref": "#/$defs/EventID" }, "msg_number": { "$ref": "#/$defs/MsgNumber" }, "msg_type": { "type": "string", "enum": [ "order_update" ] }, "order": { "$ref": "#/$defs/Order" } }, "title": "Cancel Event" }, "CancelEventEventPayload": { "type": "object", "properties": { "cancel_code": { "type": "number" }, "cancel_reason": { "type": "string" }, "client_order_id": { "type": "string" }, "event_type": { "type": "string", "enum": [ "cancel" ], "x-enum-varnames": [ "EventTypeCancel" ] }, "order_id": { "type": "string" }, "time": { "type": "string", "format": "date-time" } } }, "CancelRejectEvent": { "type": "object", "properties": { "event": { "$ref": "#/$defs/CancelRejectEventEventPayload" }, "event_id": { "$ref": "#/$defs/EventID" }, "msg_number": { "$ref": "#/$defs/MsgNumber" }, "msg_type": { "type": "string", "enum": [ "system_update" ] } }, "title": "Cancel Reject Event" }, "CancelRejectEventEventPayload": { "type": "object", "properties": { "cancel_reject_code": { "type": "number" }, "cancel_reject_reason": { "type": "string" }, "cancel_request_id": { "type": "string" }, "event_type": { "type": "string", "enum": [ "cancel_reject" ], "x-enum-varnames": [ "EventTypeCancelReject" ] }, "order_id": { "type": "string" }, "risk_group_id": { "type": "string" }, "time": { "type": "string", "format": "date-time" } } }, "CancelRequestEvent": { "type": "object", "properties": { "event": { "$ref": "#/$defs/CancelRequestEventEventPayload" }, "event_id": { "$ref": "#/$defs/EventID" }, "msg_number": { "$ref": "#/$defs/MsgNumber" }, "msg_type": { "type": "string", "enum": [ "system_update" ] } }, "title": "Cancel Request Event" }, "CancelRequestEventEventPayload": { "type": "object", "properties": { "cancel_request_id": { "type": "string" }, "event_type": { "type": "string", "enum": [ "cancel_request" ], "x-enum-varnames": [ "EventTypeCancelRequest" ] }, "order_id": { "type": "string" }, "risk_group_id": { "type": "string" }, "source": { "type": "string" }, "time": { "type": "string", "format": "date-time" } } }, "ClientAllocationID": { "type": "string", "title": "Client Allocation ID", "description": "Client-provided unique ID for the allocation; for example, to cross-reference with an internal system. Values must be unique within the trading day." }, "ClientOrderID": { "type": "string", "title": "Client Order ID", "description": "Client-provided unique ID for the order; for example, to cross-reference with an internal system. Must be unique within the trading day, otherwise duplicate orders will be rejected during pre-trade checks." }, "CounterExpiryTime": { "description": "The time until which the counter is valid.", "type": "string", "format": "date-time" }, "CustodianID": { "type": "string", "description": "The Moment-provided ID of the custodian for the order. Custodians must be enabled per risk group.", "title": "Custodian ID", "x-go-type-skip-optional-pointer": true, "x-go-name": "CustodianID" }, "Decimal": { "title": "Decimal", "oneOf": [ { "type": "number" }, { "type": "string" } ], "description": "Decimal number.", "x-go-type": "decimal.Decimal", "x-go-type-import": { "path": "github.com/shopspring/decimal" } }, "EventID": { "description": "A unique identifier for the event.", "type": "string", "title": "Event ID" }, "ExecutionCriteria": { "type": "object", "title": "Execution Criteria", "required": [ "min_wait_time", "min_number_quotes" ], "properties": { "min_wait_time": { "type": "string", "format": "duration", "description": "Minimum wait time for the execution order." }, "min_number_quotes": { "type": "integer", "description": "Minimum number of quotes required on the side of the order, before execution can proceed. If the protocol is `request_for_quote`, this is the minimum number of RFQ quotes required. If the protocol is `limit_order_book`, this is the minimum number of LOB quotes required." }, "max_transaction_cost_dollar": { "type": "string", "description": "Maximum transaction cost in dollars. Max buy price = estimated price * par value + maxDollar, Min sell price = estimated price * par value - maxDollar. Ex. a value of `5` would mean the transaction cost must be within $5 of the instrument's estimated price in dollars, meaning when buying a bond with a estimated price of $100 and a par value of $1000, the transaction cost must be below $1005." }, "max_transaction_cost_percent": { "type": "string", "description": "Maximum transaction cost in percent. Max buy price = estimated price * (1 + maxPct / 100), Min sell price = estimated price * (1 - maxPct / 100). Ex. a value of `5` would mean the transaction cost must be within 5% of the instrument's estimated price in percent, meaning when buying a bond with a estimated price of $100, the transaction cost must be below $105." }, "max_transaction_cost_yield": { "type": "string", "description": "Maximum transaction cost in yield. Max buy yield = estimated ytw - maxYTW, Max sell yield = estimated ytw + maxYTW. Ex. a value of `0.5` would mean the transaction cost must be within 50 bps of the instrument's estimated yield, meaning when buying a bond with an estimated yield to worst of 1.5%, the transaction cost must be above 1.0%." } } }, "ExecutionEvent": { "type": "object", "properties": { "event": { "$ref": "#/$defs/ExecutionEventEventPayload" }, "event_id": { "$ref": "#/$defs/EventID" }, "msg_number": { "$ref": "#/$defs/MsgNumber" }, "msg_type": { "type": "string", "enum": [ "order_update" ] }, "order": { "$ref": "#/$defs/Order" } }, "title": "Execution Event" }, "ExecutionEventEventPayload": { "type": "object", "properties": { "accrued_interest": { "type": "number" }, "amount": { "$ref": "#/$defs/OrderSize" }, "client_order_id": { "type": "string" }, "counterparty": { "description": "The market participant identifier (MPID)", "type": "string" }, "counterparty_clearing_firm": { "description": "The National Securities Clearing Corporation (NSCC) id", "type": "string" }, "event_type": { "type": "string", "enum": [ "execution" ], "x-enum-varnames": [ "EventTypeExecution" ] }, "execution_order_id": { "$ref": "#/$defs/ExecutionOrderID" }, "net_money": { "type": "number" }, "order_id": { "type": "string" }, "pre_fee_net_money": { "type": "number" }, "pre_fee_price": { "$ref": "#/$defs/LimitPrice" }, "price": { "$ref": "#/$defs/LimitPrice" }, "settlement_date": { "type": "string", "format": "date" }, "time": { "type": "string", "format": "date-time" }, "trade_date": { "type": "string", "format": "date" }, "venue": { "type": "string" }, "venue_execution_id": { "type": "string" }, "ytm": { "type": [ "number", "null" ] }, "ytw": { "type": [ "number", "null" ] } } }, "ExecutionInstruction": { "title": "Execution Instruction", "type": "object", "description": "Instructions for the EMS on how to execute the order.", "required": [ "client_execution_order_id", "protocol", "strategy", "quantity" ], "properties": { "client_execution_order_id": { "type": "string", "description": "The client-provided ID for the execution order." }, "protocol": { "$ref": "#/$defs/Protocol" }, "strategy": { "$ref": "#/$defs/Strategy" }, "quantity": { "$ref": "#/$defs/OrderSize" }, "limit_price": { "$ref": "#/$defs/LimitPrice" }, "rfq_metadata": { "$ref": "#/$defs/RFQMetadata" }, "suppress_pmp_check": { "type": "boolean", "description": "Flag to toggle if the Prevailing Market Price (PMP) check should be suppressed for the execution order.", "default": false, "x-go-type-skip-optional-pointer": true }, "venue_trader_info": { "type": "array", "description": "A list of venue trader info for the execution order.", "items": { "$ref": "#/$defs/VenueTraderInfo" }, "x-go-type-skip-optional-pointer": true }, "rfq_protocol_parameters": { "type": "array", "description": "A list of RFQ protocol parameters for the execution order.", "items": { "$ref": "#/$defs/RFQProtocolParameters" }, "x-go-type-skip-optional-pointer": true }, "execution_criteria": { "$ref": "#/$defs/ExecutionCriteria" }, "exit_criteria": { "$ref": "#/$defs/ExitCriteria" }, "venue_mpid": { "type": "string", "description": "MPID of the venue to trade on." }, "skip_lob_quotes": { "type": "boolean", "description": "Only for auto-RFQ orders, flag to determine whether to skip matching against the limit order book quotes and only match against RFQ quotes. Must be set if the protocol is `request_for_quote` and the strategy is `auto_ex`.", "default": false, "x-go-type-skip-optional-pointer": true }, "all_or_none": { "type": "boolean", "description": "Flag to indicate whether the order should be executed as an all-or-none order. If set to true, the order will only be executed if the entire quantity can be filled.", "x-go-type-skip-optional-pointer": true }, "trader_profile": { "$ref": "#/$defs/TraderIDs", "description": "The trader assigned to this execution instruction.", "nullable": true }, "ruleset_metadata": { "$ref": "#/$defs/RulesetMetadata", "description": "Metadata about the ruleset that auto generated the order.", "nullable": true }, "is_counter": { "type": "boolean", "description": "Flag to indicate if the order is a counter", "default": false, "x-go-type-skip-optional-pointer": true }, "counter_expires_after": { "type": [ "string", "null" ], "description": "Duration in seconds until which the counter is valid" }, "external_trade_report": { "$ref": "#/$defs/ExternalTradeReport" }, "quotes_snapshot": { "$ref": "#/$defs/QuotesSnapshot" }, "algo_parameters": { "$ref": "#/$defs/AlgoParameters" }, "time_in_force": { "description": "Time in force for the execution instruction. Acceptable values are `day`, `good_till_date`, `at_the_opening`, and `at_the_close`. Absence is interpreted as `day`.", "allOf": [ { "$ref": "#/$defs/TimeInForce" } ], "nullable": true, "x-go-type-skip-optional-pointer": true } } }, "ExecutionOrderCancelEvent": { "type": "object", "properties": { "event": { "$ref": "#/$defs/ExecutionOrderCancelEventEventPayload" }, "event_id": { "$ref": "#/$defs/EventID" }, "msg_number": { "$ref": "#/$defs/MsgNumber" }, "msg_type": { "type": "string", "enum": [ "order_update" ] }, "order": { "$ref": "#/$defs/Order" } }, "title": "Execution Order Cancel Event" }, "ExecutionOrderCancelEventEventPayload": { "type": "object", "properties": { "cancel_code": { "type": "number" }, "cancel_reason": { "type": "string" }, "client_execution_order_id": { "type": "string" }, "event_type": { "type": "string", "enum": [ "execution_order_cancel" ], "x-enum-varnames": [ "EventTypeExecutionOrderCancel" ] }, "execution_order_id": { "$ref": "#/$defs/ExecutionOrderID" }, "time": { "type": "string", "format": "date-time" } } }, "ExecutionOrderCancelRejectEvent": { "description": "Emitted when the system rejects a cancellation request (e.g. because the execution order\nis not in a cancelable state).\n", "type": "object", "properties": { "event": { "$ref": "#/$defs/ExecutionOrderCancelRejectEventEventPayload" }, "event_id": { "$ref": "#/$defs/EventID" }, "msg_number": { "$ref": "#/$defs/MsgNumber" }, "msg_type": { "type": "string", "enum": [ "system_update" ] } }, "title": "Cancel Execution Order Reject Event" }, "ExecutionOrderCancelRejectEventEventPayload": { "description": "Details of the rejection.", "type": "object", "properties": { "event_type": { "type": "string", "enum": [ "execution_order_cancel_reject" ], "x-enum-varnames": [ "EventTypeExecutionOrderCancelReject" ] }, "execution_order_cancel_request_id": { "description": "The ID of the cancel request.", "type": "string" }, "execution_order_id": { "$ref": "#/$defs/ExecutionOrderID" }, "order_id": { "description": "The ID of the parent order.", "type": "string" }, "reason": { "description": "The reason for the rejection.", "type": "string" }, "time": { "description": "The time when the failure occurred.", "type": "string", "format": "date-time" } } }, "ExecutionOrderCancelRequestEvent": { "description": "Sent when a request to cancel an execution order is received. This system update\nacknowledges the request. If the request is accepted, an order_update event\n(ExecutionOrderCancel) will follow; if rejected, a failure event\n(ExecutionOrderCancelRejectEvent) is sent.\n", "type": "object", "properties": { "event": { "$ref": "#/$defs/ExecutionOrderCancelRequestEventEventPayload" }, "event_id": { "$ref": "#/$defs/EventID" }, "msg_number": { "$ref": "#/$defs/MsgNumber" }, "msg_type": { "type": "string", "enum": [ "system_update" ] } }, "title": "Cancel Execution Order Request Event" }, "ExecutionOrderCancelRequestEventEventPayload": { "description": "Details of the cancel execution order request.", "type": "object", "properties": { "event_type": { "type": "string", "enum": [ "execution_order_cancel_request" ], "x-enum-varnames": [ "EventTypeExecutionOrderCancelRequest" ] }, "execution_order_cancel_request_id": { "description": "The ID of the cancel request.", "type": "string" }, "execution_order_id": { "$ref": "#/$defs/ExecutionOrderID" }, "order_id": { "description": "The ID of the parent order.", "type": "string" }, "time": { "description": "The time when the cancellation request was received.", "type": "string", "format": "date-time" } } }, "ExecutionOrderCreateEvent": { "type": "object", "properties": { "event": { "$ref": "#/$defs/ExecutionOrderCreateEventEventPayload" }, "event_id": { "$ref": "#/$defs/EventID" }, "msg_number": { "$ref": "#/$defs/MsgNumber" }, "msg_type": { "type": "string", "enum": [ "order_update" ] }, "order": { "$ref": "#/$defs/Order" } }, "title": "Execution Order Create Event" }, "ExecutionOrderCreateEventEventPayload": { "type": "object", "properties": { "amount": { "$ref": "#/$defs/OrderSize" }, "client_execution_order_id": { "description": "Idempotency key for the execution order request.", "type": "string" }, "event_type": { "type": "string", "enum": [ "execution_order_create" ], "x-enum-varnames": [ "EventTypeExecutionOrderCreate" ] }, "execution_order_id": { "$ref": "#/$defs/ExecutionOrderID" }, "limit_price": { "$ref": "#/$defs/LimitPrice" }, "protocol": { "$ref": "#/$defs/Protocol" }, "rfq": { "$ref": "#/$defs/OrderRFQ" }, "strategy": { "$ref": "#/$defs/Strategy" }, "suppress_pmp_check": { "$ref": "#/$defs/SuppressPMPCheck" }, "time": { "type": "string", "format": "date-time" } }, "required": [ "client_execution_order_id" ] }, "ExecutionOrderID": { "description": "The unique ID of the execution order.", "type": "string" }, "ExecutionOrderRejectEvent": { "description": "Emitted when the system rejects the request to create an execution order due to issues such as invalid\ninput or a non-existent order.\n", "type": "object", "properties": { "event": { "$ref": "#/$defs/ExecutionOrderRejectEventEventPayload" }, "event_id": { "$ref": "#/$defs/EventID" }, "msg_number": { "$ref": "#/$defs/MsgNumber" }, "msg_type": { "type": "string", "enum": [ "system_update" ] } }, "title": "Execution Order Reject Event" }, "ExecutionOrderRejectEventEventPayload": { "description": "Details of the rejection.", "type": "object", "properties": { "client_execution_order_id": { "description": "The client-provided execution order ID.", "type": "string" }, "event_type": { "type": "string", "enum": [ "execution_order_reject" ], "x-enum-varnames": [ "EventTypeExecutionOrderReject" ] }, "execution_order_id": { "$ref": "#/$defs/ExecutionOrderID" }, "order_id": { "description": "The ID of the parent order.", "type": "string" }, "reason": { "description": "The reason for the rejection.", "type": "string" }, "time": { "description": "The time when the failure occurred.", "type": "string", "format": "date-time" } } }, "ExecutionOrderRequestEvent": { "description": "Sent when a request to create an execution order is received. This system update\nacknowledges the request. If the request is accepted, an order_update event\n(ExecutionOrderCreate) will follow; if rejected, a failure event\n(ExecutionOrderRejectEvent) is sent.\n", "type": "object", "properties": { "event": { "$ref": "#/$defs/ExecutionOrderRequestEventEventPayload" }, "event_id": { "$ref": "#/$defs/EventID" }, "msg_number": { "$ref": "#/$defs/MsgNumber" }, "msg_type": { "type": "string", "enum": [ "system_update" ] } }, "title": "Execution Order Request Event" }, "ExecutionOrderRequestEventEventPayload": { "description": "Details of the execution order request.", "type": "object", "properties": { "amount": { "$ref": "#/$defs/OrderSize" }, "client_execution_order_id": { "description": "Idempotency key for the execution order request.", "type": "string" }, "event_type": { "type": "string", "enum": [ "execution_order_request" ], "x-enum-varnames": [ "EventTypeExecutionOrderRequest" ] }, "execution_order_id": { "$ref": "#/$defs/ExecutionOrderID" }, "order_id": { "description": "The ID of the parent order.", "type": "string" }, "rfq": { "$ref": "#/$defs/OrderRFQ" }, "time": { "description": "The time when the request was received.", "type": "string", "format": "date-time" } } }, "ExitCriteria": { "type": "object", "title": "Exit Criteria", "required": [ "timeout" ], "properties": { "timeout": { "type": "string", "format": "duration", "description": "Timeout for the execution order." } } }, "ExtendedHours": { "description": "Deprecated. The value provided here is ignored — acceptance hours are\ndetermined by the instrument's asset class: fixed income orders are\naccepted from 7:30 am to 5:30 pm ET, orders for other asset classes\nfrom 7:30 am to 4:00 pm ET. The field is kept for backwards\ncompatibility and will be removed in a future release.\n", "type": "boolean", "default": false, "deprecated": true, "x-go-type-skip-optional-pointer": true }, "ExternalTradeReport": { "type": "object", "properties": { "amount": { "$ref": "#/$defs/OrderSize" }, "annotation": { "description": "Optional annotation for the trade.", "type": [ "string", "null" ] }, "bypass_street_side_leg": { "description": "Flag to bypass street side leg. If true, we will not send the street side to the custodian.", "type": "boolean", "default": false, "x-go-type-skip-optional-pointer": true }, "bypass_trade_booking": { "description": "Flag to bypass trade booking. If true, the trade will not be booked in the system.", "type": "boolean" }, "client_external_trade_report_id": { "description": "The client-provided idempotency key.", "type": "string" }, "counterparty_clearing_firm_id": { "description": "DTC ID of the counterparty's clearing firm.", "type": "string", "x-go-type-skip-optional-pointer": true }, "counterparty_id": { "description": "MPID of the counterparty involved in the street trade.", "type": "string", "x-go-type-skip-optional-pointer": true }, "execution_id": { "description": "Trade ID. Often times this will be the ID of the execution made at an external venue.", "type": "string" }, "external_trade_report_id": { "description": "Optional external trade report ID. If provided, this ID will be used instead of auto-generating one.\nMust start with 'etr_' followed by a valid ULID.\nIf not provided, the system will generate a unique ID automatically.\n", "type": "string" }, "price": { "description": "The trade price. For mutual funds, if not provided, the backend will use the parent order's estimated price (NAV).", "type": [ "number", "null" ], "format": "double" }, "settle_date": { "description": "The settlement date for the trade.", "type": "string", "format": "date-time" }, "snapshot_id": { "description": "Optional quote snapshot ID. If provided, this snapshot ID will be used instead of creating a new one.", "type": "string" }, "trade_time": { "description": "The timestamp when the trade occurred.", "type": "string", "format": "date-time" } }, "required": [ "client_external_trade_report_id", "amount", "trade_time", "settle_date", "bypass_trade_booking" ], "title": "External Trade Report" }, "ExternalTradeReportID": { "description": "The ID of the external trade report generated by Moment.", "type": "string" }, "ExternalTradeReportRejectEvent": { "description": "Emitted when the system fails to book an external trade due to issues such as invalid trade\ndetails or errors with the external broker.\n", "type": "object", "properties": { "event": { "$ref": "#/$defs/ExternalTradeReportRejectEventEventPayload" }, "event_id": { "$ref": "#/$defs/EventID" }, "msg_number": { "$ref": "#/$defs/MsgNumber" }, "msg_type": { "type": "string", "enum": [ "system_update" ] } }, "title": "External Trade Report Reject Event" }, "ExternalTradeReportRejectEventEventPayload": { "description": "Details of the failure.", "type": "object", "properties": { "client_external_trade_report_id": { "description": "The client-provided idempotency key.", "type": "string" }, "event_type": { "type": "string", "enum": [ "external_trade_report_reject" ], "x-enum-varnames": [ "EventTypeExternalTradeReportReject" ] }, "external_trade_report_id": { "$ref": "#/$defs/ExternalTradeReportID" }, "order_id": { "description": "The ID of the order.", "type": "string" }, "reason": { "description": "The reason for the rejection.", "type": "string" }, "time": { "description": "The time when the failure occurred.", "type": "string", "format": "date-time" } } }, "ExternalTradeReportRequestEvent": { "description": "Sent when a request to report an external trade is received. This system update acknowledges the request.\nIf the request is accepted, an order_update event of execution will follow; if rejected, a system update of type external_trade_report_reject is sent.\n", "type": "object", "properties": { "event": { "$ref": "#/$defs/ExternalTradeReportRequestEventEventPayload" }, "event_id": { "$ref": "#/$defs/EventID" }, "msg_number": { "$ref": "#/$defs/MsgNumber" }, "msg_type": { "type": "string", "enum": [ "system_update" ] } }, "title": "External Trade Report Request Event" }, "ExternalTradeReportRequestEventEventPayload": { "description": "Details of the external trade report request.", "type": "object", "properties": { "amount": { "$ref": "#/$defs/OrderSize" }, "annotation": { "description": "Optional annotation for the trade.", "type": [ "string", "null" ] }, "bypass_trade_booking": { "description": "Flag to bypass trade booking.", "type": [ "boolean", "null" ] }, "client_external_trade_report_id": { "description": "The client-provided idempotency key.", "type": "string" }, "counterparty_clearing_firm_id": { "description": "NSCC ID of the counterparty's clearing firm.", "type": "string" }, "counterparty_id": { "description": "MPID of the counterparty involved in the street trade.", "type": "string" }, "event_type": { "type": "string", "enum": [ "external_trade_report_request" ], "x-enum-varnames": [ "EventTypeExternalTradeReportRequest" ] }, "execution_id": { "description": "Trade ID. Often times this will be the ID of the execution made at an external venue.", "type": "string" }, "external_trade_report_id": { "$ref": "#/$defs/ExternalTradeReportID" }, "order_id": { "description": "The ID of the order.", "type": "string" }, "price": { "description": "The trade price.", "type": "number" }, "settle_date": { "description": "The settlement date for the trade.", "type": "string", "format": "date-time" }, "time": { "type": "string", "format": "date-time" }, "trade_time": { "description": "The timestamp when the trade occurred.", "type": "string", "format": "date-time" } } }, "Fee": { "title": "Fee", "type": "object", "description": "The fee to apply to the order.", "properties": { "fee_type": { "$ref": "#/$defs/FeeType" }, "fee_amount_type": { "$ref": "#/$defs/FeeAmountType" }, "recipient_id": { "type": "string", "description": "Unique ID of the recipient of the fee.", "x-go-name": "RecipientID", "x-go-type-skip-optional-pointer": true }, "recipient_type": { "$ref": "#/$defs/RecipientType" }, "fee_amount": { "description": "Fee amount to apply to the order.", "$ref": "#/$defs/Decimal" }, "max_fee_amount": { "description": "Maximum fee amount to apply to the order.", "$ref": "#/$defs/NullableDecimal" }, "max_fee_amount_type": { "$ref": "#/$defs/FeeAmountType" }, "fee_name": { "type": "string", "description": "Optional name for the fee, for easier identification." } }, "required": [ "fee_type", "fee_amount_type", "fee_amount" ] }, "FeeAmountType": { "title": "Fee Amount Type", "type": "string", "description": "The method used to calculate the fee amount. Supported types include:\n\n- `percentage_of_par`: Fee as a percentage of par value.\n Example: `0.10` = 10 basis points of par value.\n\n- `percentage_of_market_value`: Fee as a percentage of the quote price (market value).\n Example: `1` = 1% of market value.\n\n- `yield_bps`: Fee expressed in yield terms, in basis points.\n Example: `100` = 100 basis points of yield.\n\n- `percentage_of_concession`: Fee applies to concession based quoting mechanism, especially for new issue CDs.\n Example: `50` = 50 percent of all concession from the dealer.\n", "enum": [ "percentage_of_par", "percentage_of_market_value", "yield_bps", "percentage_of_concession" ], "x-enumNames": [ "FeeAmountTypePercentageOfPar", "FeeAmountTypePercentageOfMarketValue", "FeeAmountTypeYieldBps", "FeeAmountTypePercentageOfConcession" ] }, "FeeType": { "title": "Fee Type", "type": "string", "description": "The type of fee to apply to the order. Valid values are \"markup\", \"commission\", and \"sales_credit\".", "enum": [ "markup", "commission", "sales_credit" ], "x-enumNames": [ "FeeTypeMarkup", "FeeTypeCommission", "FeeTypeSalesCredit" ] }, "FlaggedForReviewEvent": { "description": "This event is sent when an order is flagged for review. It is used to notify the client that the order has been flagged and is pending review.", "type": "object", "properties": { "event": { "$ref": "#/$defs/FlaggedForReviewEventEventPayload" }, "event_id": { "$ref": "#/$defs/EventID" }, "msg_number": { "$ref": "#/$defs/MsgNumber" }, "msg_type": { "type": "string", "enum": [ "order_update" ] }, "order": { "$ref": "#/$defs/Order" } }, "title": "Flagged For Review Event" }, "FlaggedForReviewEventEventPayload": { "type": "object", "properties": { "client_order_id": { "$ref": "#/$defs/ClientOrderID" }, "event_type": { "type": "string", "enum": [ "flagged_for_review" ], "x-enum-varnames": [ "EventTypeFlaggedForReview" ] }, "failed_controls": { "type": "array", "items": { "type": "object", "properties": { "control_message": { "description": "The message of the control that failed.", "type": "string" } } } }, "order_id": { "description": "The ID of the order that was flagged.", "type": "string" }, "time": { "type": "string", "format": "date-time" } } }, "GroupMember": { "title": "Group Member", "type": "object", "description": "A group member for an order", "required": [ "moment_order_id" ], "properties": { "moment_order_id": { "type": "string", "description": "The ID of the order in the group", "x-go-name": "MomentOrderID" } } }, "InstrumentID": { "description": "Instrument CUSIP or ISIN", "type": "string", "title": "Instrument ID" }, "IntroducingBrokerID": { "description": "The ID of the introducing broker placing the order. If not specified, the organization associated with the API key will be used.", "type": "string" }, "InvestmentAdvisorRepresentative": { "title": "Investment Advisor Representative", "type": "object", "description": "The representative credited with this account's participation in the\norder. Accounts in one block order can name different representatives.\nA Moment user is sent as moment_user_id; name and email resolve from\nthe user directory when read. A person with no Moment login is sent\nby name, with email when known. When both are set, moment_user_id is\nalways preferred.\n", "properties": { "moment_user_id": { "description": "The Moment user who is the representative.", "type": "string", "x-go-type-skip-optional-pointer": true, "x-go-name": "MomentUserID" }, "name": { "description": "The representative's display name.", "type": "string", "x-go-type-skip-optional-pointer": true }, "email": { "description": "The representative's email.", "type": "string", "x-go-type-skip-optional-pointer": true } } }, "IsParameters": { "title": "IS Parameters", "type": "object", "description": "Parameters for an implementation-shortfall (arrival price) algo. The algo balances market\nimpact against timing risk to minimize slippage versus the arrival price, working more or\nless aggressively based on the aggressiveness level. Order type and limit price are carried\non the order itself, not in these parameters.", "properties": { "start_time": { "type": "string", "format": "date-time", "description": "Start of the absolute window to work the order." }, "end_time": { "type": "string", "format": "date-time", "description": "End of the absolute window to work the order." }, "would": { "$ref": "#/$defs/WouldParameters" }, "participate_opening_auction": { "type": "boolean", "description": "Whether the algo should participate in the opening auction.", "default": false, "x-go-type-skip-optional-pointer": true }, "participate_closing_auction": { "type": "boolean", "description": "Whether the algo should participate in the closing auction.", "default": false, "x-go-type-skip-optional-pointer": true }, "aggressiveness": { "$ref": "#/$defs/AggressivenessLevel" }, "max_participation_percent": { "type": [ "integer", "null" ], "format": "int64", "description": "Hard ceiling on participation of market volume, as a percent (e.g. 20 = 20%)." } } }, "LimitPrice": { "title": "Limit Price", "description": "The Percentage Price is represented as a percentage of par. For a typical $1,000 par value bond, a percentage price of $90 values the bond at $900. This is a clean price, which does not include accrued interest. Accepts a JSON number or a decimal string.", "x-go-type": "PriceValue", "oneOf": [ { "type": [ "number", "null" ], "minimum": 0 }, { "type": "string" } ] }, "LotInstruction": { "title": "Lot Instruction", "type": "object", "description": "Identifies a specific tax lot so the booking gateway can emit lot-level\nVSP instructions to custodians. Buy-side flows leave it unset; when set,\nall three fields are populated from the same lot record.\n", "properties": { "custodian_tax_lot_id": { "description": "The tax lot ID assigned by the custodian.", "type": "string", "x-go-type-skip-optional-pointer": true }, "lot_trade_date": { "description": "Trade date of the tax lot, YYYYMMDD.", "type": "integer", "format": "int32", "x-go-type-skip-optional-pointer": true }, "lot_purchase_price": { "description": "Per-unit purchase price of the tax lot, decimal string.", "type": "string", "x-go-type-skip-optional-pointer": true } } }, "ManualApproveFailureEvent": { "type": "object", "properties": { "event": { "$ref": "#/$defs/ManualApproveFailureEventEventPayload" }, "event_id": { "$ref": "#/$defs/EventID" }, "msg_number": { "$ref": "#/$defs/MsgNumber" }, "msg_type": { "type": "string", "enum": [ "system_update" ] } }, "title": "Manual Approve Failure Event" }, "ManualApproveFailureEventEventPayload": { "type": "object", "properties": { "event_type": { "type": "string", "enum": [ "manual_approve_fail" ], "x-enum-varnames": [ "EventTypeManualApproveFail" ] }, "manual_approve_id": { "description": "The ID of the manual approval request.", "type": "string" }, "order_id": { "description": "The ID of the order.", "type": "string" }, "reason": { "description": "The reason for the failure.", "type": "string" }, "time": { "type": "string", "format": "date-time" } } }, "ManualApproveRequestEvent": { "description": "This event is sent when a request to approve an order is received.\nIt is used to acknowledge the request. If the request is rejected, the client\nwill receive a `ManualApproveFailureEvent` as a `system_update`. If the request\nis accepted, the client will receive an `Approve` event as an `order_update`.", "type": "object", "properties": { "event": { "$ref": "#/$defs/ManualApproveRequestEventEventPayload" }, "event_id": { "$ref": "#/$defs/EventID" }, "msg_number": { "$ref": "#/$defs/MsgNumber" }, "msg_type": { "type": "string", "enum": [ "system_update" ] } }, "title": "Manual Approve Request Event" }, "ManualApproveRequestEventEventPayload": { "type": "object", "properties": { "annotation": { "description": "The annotation to be added to the order for the approval.", "type": "string" }, "client_manual_approve_id": { "description": "The client-provided ID of the manual approval request.", "type": "string" }, "event_type": { "type": "string", "enum": [ "manual_approve_request" ], "x-enum-varnames": [ "EventTypeManualApproveRequest" ] }, "manual_approve_id": { "description": "The ID of the manual approval request.", "type": "string" }, "order_id": { "description": "The ID of the order to be approved.", "type": "string" }, "time": { "type": "string", "format": "date-time" } } }, "ManualRejectFailureEvent": { "type": "object", "properties": { "event": { "$ref": "#/$defs/ManualRejectFailureEventEventPayload" }, "event_id": { "$ref": "#/$defs/EventID" }, "msg_number": { "$ref": "#/$defs/MsgNumber" }, "msg_type": { "type": "string", "enum": [ "system_update" ] } }, "title": "Manual Reject Failure Event" }, "ManualRejectFailureEventEventPayload": { "type": "object", "properties": { "event_type": { "type": "string", "enum": [ "manual_reject_fail" ], "x-enum-varnames": [ "EventTypeManualRejectFail" ] }, "manual_reject_id": { "description": "The ID of the manual reject request.", "type": "string" }, "order_id": { "description": "The ID of the order.", "type": "string" }, "reason": { "description": "The reason for the failure.", "type": "string" }, "time": { "type": "string", "format": "date-time" } } }, "ManualRejectRequestEvent": { "description": "This event is sent when a request to reject an order is received.\nIt is used to acknowledge the request. If the request is rejected, the client\nwill receive a `ManualRejectFailureEvent` as a `system_update`. If the request\nis accepted, the client will receive a `Reject` event as an `order_update`.", "type": "object", "properties": { "event": { "$ref": "#/$defs/ManualRejectRequestEventEventPayload" }, "event_id": { "$ref": "#/$defs/EventID" }, "msg_number": { "$ref": "#/$defs/MsgNumber" }, "msg_type": { "type": "string", "enum": [ "system_update" ] } }, "title": "Manual Reject Request Event" }, "ManualRejectRequestEventEventPayload": { "type": "object", "properties": { "annotation": { "description": "The annotation to be added to the order for the rejection.", "type": "string" }, "client_manual_reject_id": { "description": "The client-provided ID of the manual reject request.", "type": "string" }, "event_type": { "type": "string", "enum": [ "manual_reject_request" ], "x-enum-varnames": [ "EventTypeManualRejectRequest" ] }, "manual_reject_id": { "description": "The ID of the manual reject request.", "type": "string" }, "order_id": { "description": "The ID of the order to be rejected.", "type": "string" }, "time": { "type": "string", "format": "date-time" } } }, "MsgNumber": { "description": "The `msg_number` for the event, as per the [Real-Time Orders API](https://docs.moment.com/reference/real-time-orders-api#message-playback). This is a string representation of a 64-bit unsigned integer `YYYYMMDDxxxxxxxxxx` where the `x`'s are an incrementing index starting at `0000000000`.", "type": "string", "title": "Message Number" }, "NullableDecimal": { "title": "Nullable Decimal", "oneOf": [ { "type": "number" }, { "type": "string" } ], "description": "Nullable Decimal number.", "nullable": true, "x-go-type": "decimal.Decimal", "x-go-type-import": { "path": "github.com/shopspring/decimal" } }, "OfferingID": { "description": "The ID of the new-issue offering this order is placed against. Required for `ioi` orders; ignored for all other order types.", "type": "string", "title": "Offering ID" }, "Order": { "description": "Each order has a unique identifier generated by Moment. The ID will be returned when an order is placed and can be used to check the status of the order via the `GET /v1/trading/order/{id}/` endpoint. Updates on open orders at Moment will also be sent over the real-time API, which is the recommended method of maintaining order state.", "type": "object", "properties": { "account_booking_type": { "description": "Deprecated, will be removed soon. Use account_configuration.booking_type instead.", "allOf": [ { "$ref": "#/$defs/BookingType" } ], "deprecated": true, "x-go-type-skip-optional-pointer": true }, "account_configuration": { "$ref": "#/$defs/AccountConfiguration" }, "account_id": { "description": "Unique ID of user account", "type": [ "string", "null" ], "x-go-type-skip-optional-pointer": true }, "all_or_none": { "$ref": "#/$defs/AllOrNone" }, "allocations": { "description": "Allocations for the order", "$ref": "#/$defs/AllocationRequest", "nullable": true }, "amount": { "$ref": "#/$defs/OrderSize" }, "annotation": { "$ref": "#/$defs/Annotation" }, "booking_instructions": { "description": "Client-provided information to configure trade booking for the order, as a map from string to string. Passing a multi-layer JSON map or something other than \"string\":\"string\" key-value pairs will result in an error. The specific contents of this field should be determined in conjunction with the back-office integration.", "type": "object", "additionalProperties": { "type": "string" }, "title": "booking_instructions", "x-go-type-skip-optional-pointer": true }, "bypass_auto_execution": { "description": "Flag to indicate if auto execution rules should be bypassed", "type": "boolean", "default": false, "x-go-type-skip-optional-pointer": true }, "client_order_id": { "$ref": "#/$defs/ClientOrderID" }, "counter_expiry_time": { "description": "The time until which the counter is valid", "$ref": "#/$defs/CounterExpiryTime", "nullable": true }, "custodian_id": { "description": "The Moment-provided custodian ID that the corresponding account belongs to.\n\nFor organizations with CTM enabled, this field should be left empty for both single and block fixed-income orders.\nFor brokerages firms, `custodian_id` and `account_id` are both required to identify the inventory account.\nFor RIAs, this field is optional as each account allocation has its own custodian_id field.\n\nWhen available, it is recommended to populate this field.", "type": "string", "title": "Custodian ID", "x-go-name": "CustodianID", "x-go-type-skip-optional-pointer": true }, "execution_instructions": { "description": "A list of execution instructions for the order", "type": "array", "items": { "$ref": "#/$defs/ExecutionInstruction" }, "x-go-type-skip-optional-pointer": true }, "expire_date": { "description": "Date of order expiration (last day the order can trade), always expressed in terms of the local market date. The maximum expire_date is 90 calendar days out. If the expire_date does not fall on a trading day, the next trading day is automatically selected.", "type": [ "integer", "null" ], "format": "int64" }, "explicit_cancelation_required": { "description": "Deprecated. The value provided here is ignored — orders are always\ntreated as if explicit cancellation is required. The field is kept\nfor backwards compatibility and will be removed in a future release.\n", "type": "boolean", "default": false, "deprecated": true, "x-go-type-skip-optional-pointer": true }, "extended_hours": { "$ref": "#/$defs/ExtendedHours" }, "fees": { "description": "Custom fees to be applied to the order. If provided, this list overrides the default fees defined in the system.\n\nFor each fee recipient based on the trade structure, a separate fee object should be included.\nFor example, in a trade flow like:\n\n Street <-> Executing Broker <-> Introducing Broker <-> Customer\n\nwhere both brokers are charging fees, you would specify:\n\n \"fees\": [\n {\n \"fee_type\": \"markup\",\n \"fee_amount_type\": \"percentage_of_par\",\n \"fee_amount\": 0.01,\n \"recipient\": \"\"\n },\n {\n \"fee_type\": \"markup\",\n \"fee_amount_type\": \"percentage_of_par\",\n \"fee_amount\": 0.05,\n \"recipient\": \"\"\n }\n ]\n", "type": "array", "items": { "$ref": "#/$defs/Fee" }, "x-go-type-skip-optional-pointer": true }, "for_block_trade": { "description": "Flag to indicate if the order is for a block trade, used for post order allocation", "type": [ "boolean", "null" ] }, "group_members": { "description": "List of group members for the order", "type": "array", "items": { "$ref": "#/$defs/GroupMember" }, "x-go-type-skip-optional-pointer": true }, "ib_id": { "description": "The introducing broker ID to use for this specific order. If not specified, will use the introducing broker ID from the bulk request.", "$ref": "#/$defs/IntroducingBrokerID", "nullable": true }, "instrument_id": { "$ref": "#/$defs/InstrumentID" }, "is_counter": { "description": "Flag to indicate if the order is a counter", "type": "boolean", "default": false, "x-go-type-skip-optional-pointer": true }, "is_group_order": { "description": "Flag to indicate if the order is a group order", "type": "boolean", "default": false, "x-go-type-skip-optional-pointer": true }, "limit_price": { "$ref": "#/$defs/LimitPrice" }, "liquidate_fund_position": { "description": "Flag to instruct the custodian to sell the entire position rather than just the quantity on the order. Fund sells only and notional. The notional dollar value should be the current notional value of the position.", "type": "boolean", "default": false, "x-go-type-skip-optional-pointer": true }, "metadata": { "description": "Custom metadata for the order. This can be used to store additional information about the order that is not covered by the other fields. The keys and values are both strings.", "type": [ "object", "null" ], "additionalProperties": { "type": "string" }, "x-go-type-skip-optional-pointer": true }, "offering_id": { "$ref": "#/$defs/OfferingID" }, "order_rfq_ids": { "description": "A list of existing RFQ IDs to associate with this order.", "type": "array", "items": { "type": "string" } }, "review_reason": { "description": "Reason for why the order requires review. Only applicable when review_required is true.", "type": "string", "default": "", "x-go-type-skip-optional-pointer": true }, "review_required": { "description": "Flag to indicate if the order requires manual review before execution.", "type": "boolean", "default": false, "x-go-type-skip-optional-pointer": true }, "risk_group_id": { "description": "The risk group ID to use for this specific order. If not specified, will use the risk group ID from the bulk request.", "$ref": "#/$defs/RiskGroupID", "nullable": true }, "settlement_date": { "description": "The targeted settlement date for the order in the format of YYYYMMDD, like 20090101", "type": [ "integer", "null" ], "format": "int64" }, "side": { "$ref": "#/$defs/OrderSide" }, "time_in_force": { "description": "Time in force for the order. Acceptable values are `day` and `good_till_date`. Absence is interpreted as `day`.", "allOf": [ { "$ref": "#/$defs/TimeInForce" } ], "nullable": true, "x-go-type-skip-optional-pointer": true }, "type": { "$ref": "#/$defs/OrderType" } }, "required": [ "instrument_id", "amount", "side", "type", "client_order_id" ], "title": "Order Request" }, "OrderID": { "description": "Unique, Moment-generated ID for the order.", "type": "string", "title": "Order ID" }, "OrderRFQ": { "type": "object", "title": "Order RFQ", "description": "Contains the required information about the RFQ that prompted the order.", "required": [ "id", "contra_quote_id" ], "properties": { "id": { "type": "string", "description": "The ID of the RFQ that initiated the order request." }, "contra_quote_id": { "type": "string", "title": "Contra Quote ID", "description": "The ID of the quote that is being traded against." } } }, "OrderSide": { "type": "string", "enum": [ "buy", "sell" ], "title": "OrderSide", "description": "Represents which side this order is on:\n\n- buy\n- sell" }, "OrderSize": { "type": "object", "title": "Amount", "description": "The Amount of an order with a specified `type` indicating how the amount is represented.\n- **Par:** Represents the order size in face value (e.g., a corporate bond with a $1,000 face value).\n- **Notional:** Represents the order size in notional dollar value.\n- **Shares:** Represents the order size in number of shares (for equities).", "properties": { "value": { "type": "number", "x-go-type": "float64" }, "type": { "type": "string", "enum": [ "par", "notional", "shares" ], "default": "par", "x-enumNames": [ "SizeTypePar", "SizeTypeNotional", "SizeTypeShares" ] } }, "required": [ "value", "type" ] }, "OrderType": { "type": "string", "enum": [ "limit", "rfq_response", "market", "advisor_bw", "quote_wanted", "ioi" ], "x-enumNames": [ "OrderTypeLimit", "OrderTypeRFQResponse", "OrderTypeMarket", "OrderTypeAdvisorBW", "OrderTypeQuoteWanted", "OrderTypeIOI" ], "default": "limit", "description": "Represents the types of orders Moment currently supports.\n\n- limit\n- rfq_response\n- market\n- advisor_bw\n- quote_wanted\n- ioi", "title": "OrderType" }, "PovParameters": { "title": "POV Parameters", "type": "object", "description": "Parameters for a percentage-of-volume (POV) algo. The algo participates in the market at a\ntarget percentage of the traded volume, speeding up or slowing down as market volume changes\nrather than working to a fixed time schedule.", "required": [ "target_participation_percent" ], "properties": { "target_participation_percent": { "type": "integer", "format": "int64", "description": "Target participation rate of market volume, as a percent (e.g. 20 = 20%)." }, "max_participation_percent": { "type": [ "integer", "null" ], "format": "int64", "description": "Hard ceiling on participation, distinct from the target percent." }, "start_time": { "type": "string", "format": "date-time", "description": "Start of the absolute window to work the order." }, "end_time": { "type": "string", "format": "date-time", "description": "End of the absolute window to work the order." }, "would": { "$ref": "#/$defs/WouldParameters" }, "participate_opening_auction": { "type": "boolean", "description": "Whether the algo should participate in the opening auction.", "default": false, "x-go-type-skip-optional-pointer": true }, "participate_closing_auction": { "type": "boolean", "description": "Whether the algo should participate in the closing auction.", "default": false, "x-go-type-skip-optional-pointer": true }, "aggressiveness": { "$ref": "#/$defs/AggressivenessLevel" } } }, "Price": { "title": "Price", "type": "object", "description": "Price value with type specification for different pricing methods.", "required": [ "value", "type" ], "properties": { "value": { "$ref": "#/$defs/Decimal" }, "type": { "$ref": "#/$defs/PriceValueType" }, "benchmark_isin": { "type": [ "string", "null" ], "description": "The ISIN of the benchmark security, required when type is 'spread'." } } }, "PriceValueType": { "title": "Price Value Type", "type": "string", "description": "The method used to represent the price value.", "enum": [ "percent", "discount_yield", "spread", "money_market_yield", "per_share" ], "x-enumNames": [ "PriceValueTypePercent", "PriceValueTypeDiscountYield", "PriceValueTypeSpread", "PriceValueTypeMMYield", "PriceValueTypePerShare" ], "default": "percent" }, "Protocol": { "title": "Protocol", "type": "string", "description": "The protocol used for the execution order.", "enum": [ "limit_order_book", "request_for_quote", "external", "group", "custodian" ], "x-enumNames": [ "ProtocolLimitOrderBook", "ProtocolRequestForQuote", "ProtocolExternal", "ProtocolGroup", "ProtocolCustodian" ] }, "QuotesSnapshot": { "type": "object", "required": [ "isin", "bids", "asks", "organization_id" ], "properties": { "isin": { "type": "string" }, "organization_id": { "type": "string" }, "bids": { "type": "array", "items": { "$ref": "#/$defs/SnapshotQuote" } }, "asks": { "type": "array", "items": { "$ref": "#/$defs/SnapshotQuote" } } } }, "RFQCreateEvent": { "type": "object", "properties": { "event": { "$ref": "#/$defs/RFQCreateEventEventPayload" }, "event_id": { "$ref": "#/$defs/EventID" }, "msg_number": { "$ref": "#/$defs/MsgNumber" }, "msg_type": { "type": "string", "enum": [ "order_update" ] }, "order": { "$ref": "#/$defs/Order" } }, "title": "RFQ Create Event" }, "RFQCreateEventEventPayload": { "type": "object", "properties": { "event_type": { "type": "string", "enum": [ "rfq_create" ], "x-enum-varnames": [ "EventTypeRFQCreate" ] }, "order_id": { "$ref": "#/$defs/OrderID" }, "rfq_id": { "description": "The ID of the RFQ created on the order.", "type": "string" }, "time": { "type": "string", "format": "date-time" } } }, "RFQMetadata": { "type": "object", "title": "RFQ Metadata", "description": "Metadata related to the RFQ.", "properties": { "moment_rfq_id": { "type": "string", "description": "The ID of the RFQ.", "x-go-type-skip-optional-pointer": true }, "contra_quote_id": { "type": "string", "description": "The ID of the contra quote for the RFQ.", "x-go-type-skip-optional-pointer": true } } }, "RFQProtocolParameters": { "type": "object", "title": "RFQ Protocol Parameters", "required": [ "venue_mpid", "type", "disclosure" ], "properties": { "venue_mpid": { "type": "string", "description": "The MPID of the venue." }, "type": { "type": "string", "description": "The type of the RFQ.", "enum": [ "bin", "asap" ] }, "disclosure": { "type": "string", "description": "The disclosure for the RFQ. Currently, only `disclosed` is supported.", "enum": [ "disclosed", "anonymous" ] }, "due_after": { "type": "string", "format": "duration", "description": "Specifies how duration following RFQ creation, after which the RFQ becomes due." }, "subject_after": { "type": "string", "format": "duration", "description": "Specifies the duration following the due time (or submission time if no due time is defined) during which quotes are considered subject." }, "expire_after": { "type": "string", "format": "duration", "description": "Specifies the duration following the latest of due time, subject time, or submission time, after which the RFQ expires." } } }, "RecipientType": { "title": "Recipient Type", "type": "string", "description": "The type of recipient for the fee.", "enum": [ "executing_broker", "introducing_broker", "advisor", "customer" ], "x-enumNames": [ "RecipientTypeExecutingBroker", "RecipientTypeIntroducingBroker", "RecipientTypeAdvisor", "RecipientTypeCustomer" ] }, "RejectEvent": { "type": "object", "properties": { "event": { "$ref": "#/$defs/RejectEventEventPayload" }, "event_id": { "$ref": "#/$defs/EventID" }, "msg_number": { "$ref": "#/$defs/MsgNumber" }, "msg_type": { "type": "string", "enum": [ "order_update" ] }, "order": { "$ref": "#/$defs/Order" } }, "title": "Reject Event" }, "RejectEventEventPayload": { "type": "object", "properties": { "client_order_id": { "type": "string" }, "event_type": { "type": "string", "enum": [ "reject" ], "x-enum-varnames": [ "EventTypeReject" ] }, "order_id": { "type": "string" }, "reject_code": { "type": "number" }, "reject_reason": { "type": "string" }, "time": { "type": "string", "format": "date-time" } } }, "RequestEvent": { "type": "object", "properties": { "event": { "$ref": "#/$defs/RequestEventEventPayload" }, "event_id": { "$ref": "#/$defs/EventID" }, "msg_number": { "$ref": "#/$defs/MsgNumber" }, "msg_type": { "description": "The type of message.", "type": "string", "enum": [ "order_update" ] }, "order": { "$ref": "#/$defs/Order" } }, "title": "Request Event" }, "RequestEventEventPayload": { "type": "object", "properties": { "account_id": { "$ref": "#/$defs/AccountID" }, "amount": { "$ref": "#/$defs/OrderSize" }, "annotation": { "$ref": "#/$defs/annotation" }, "client_order_id": { "type": "string" }, "cusip": { "type": "string" }, "event_type": { "type": "string", "enum": [ "request" ], "x-enum-varnames": [ "EventTypeRequest" ] }, "extended_hours": { "type": "boolean", "deprecated": true }, "isin": { "type": "string" }, "limit_price": { "$ref": "#/$defs/LimitPrice" }, "order_id": { "type": "string" }, "risk_group_id": { "type": "string" }, "side": { "$ref": "#/$defs/OrderSide" }, "time": { "type": "string", "format": "date-time" }, "type": { "$ref": "#/$defs/OrderType" } } }, "RiskGroupID": { "description": "The risk group ID to use for this order. If not specified, the default risk group for the organization will be used. The risk group must belong to the organization specified by ib_id. Orders for which the risk group does not belong to the specified organization will be rejected with \"invalid risk group id.\"", "type": "string" }, "RulesetMetadata": { "type": "object", "title": "Ruleset Metadata", "description": "Metadata about the ruleset that auto generated the order.", "required": [ "proposal_id", "tree_version_id" ], "properties": { "proposal_id": { "type": "string", "description": "The ID of the proposal." }, "tree_version_id": { "type": "string", "description": "The version ID of the ruleset that auto generated the order." } } }, "SnapshotQuote": { "type": "object", "properties": { "yield_to_maturity": { "type": "number", "format": "double", "description": "Deprecated: not mapped to domain model, will be removed. Use post_fee_ytm instead.", "deprecated": true }, "yield_to_worst": { "type": "number", "format": "double", "description": "Deprecated: not mapped to domain model, will be removed. Use post_fee_ytw instead.", "deprecated": true }, "size": { "type": "integer" }, "min_size": { "type": "integer" }, "venue_mpid": { "type": "string" }, "spread_benchmark_isin": { "type": [ "string", "null" ] }, "spread_to_benchmark_bps": { "type": [ "string", "null" ] }, "min_balance_remaining": { "type": [ "integer", "null" ] }, "min_increment": { "type": [ "integer", "null" ] }, "source": { "type": "string", "enum": [ "LOB", "RFQ" ] }, "pre_fee_price": { "type": "number", "format": "double" }, "post_fee_price": { "type": "number", "format": "double" }, "pre_fee_ytw": { "type": "number", "format": "double", "description": "Pre-fee yield to worst (street price, no fees)." }, "post_fee_ytw": { "type": "number", "format": "double", "description": "Post-fee yield to worst (inclusive of Moment fees)." }, "pre_fee_ytm": { "type": "number", "format": "double", "description": "Pre-fee yield to maturity (street price, no fees)." }, "post_fee_ytm": { "type": "number", "format": "double", "description": "Post-fee yield to maturity (inclusive of Moment fees)." }, "pre_fee_spread_bps": { "type": [ "number", "null" ], "format": "double" }, "post_fee_spread_bps": { "type": [ "number", "null" ], "format": "double" }, "side": { "type": "string", "enum": [ "bid", "ask" ] }, "disabled": { "type": "boolean" }, "rfq_quote_status": { "type": "string" }, "rfq_id": { "type": "string" }, "venue_quote_id": { "type": "string" }, "settlement_date": { "type": "integer", "format": "int64" } }, "required": [ "size", "min_size", "venue_mpid", "source", "pre_fee_price", "post_fee_price", "pre_fee_ytm", "pre_fee_ytw", "post_fee_ytm", "post_fee_ytw", "side", "disabled", "settlement_date" ] }, "Strategy": { "title": "Strategy", "type": "string", "description": "The strategy used for the execution order.", "enum": [ "smart_order_routing", "manual", "report", "auto_ex" ], "x-enumNames": [ "StrategySmartOrderRouting", "StrategyManual", "StrategyReport", "StrategyAutoEx" ] }, "SuppressPMPCheck": { "description": "If set to true, any potential PMP violations will be suppressed.", "type": "boolean", "default": false, "title": "Suppress PMP Check" }, "TimeInForce": { "title": "Time In Force", "type": "string", "description": "Specifies how long the order remains in effect. Absence of this field is interpreted as DAY.", "enum": [ "day", "good_till_date", "at_the_opening", "at_the_close" ], "x-enumNames": [ "Day", "GoodTillDate", "AtTheOpening", "AtTheClose" ] }, "TraderIDs": { "title": "Trader IDs", "type": "object", "description": "the IDs of a trader", "required": [ "user_id" ], "properties": { "user_id": { "type": "string", "description": "the Moment ID for this user", "x-go-name": "UserID" }, "bloomberg_id": { "type": "string", "description": "the registered Bloomberg ID for this user", "x-go-name": "BloombergID", "x-go-type-skip-optional-pointer": true } } }, "TwapParameters": { "title": "TWAP Parameters", "type": "object", "description": "Parameters for a time-weighted average price (TWAP) algo. The algo slices the order into\nsmaller pieces and works them evenly over the specified time window, aiming to match the\ntime-weighted average price of the instrument over that window.", "properties": { "start_time": { "type": "string", "format": "date-time", "description": "Start of the absolute window to work the order." }, "end_time": { "type": "string", "format": "date-time", "description": "End of the absolute window to work the order." }, "would": { "$ref": "#/$defs/WouldParameters" }, "participate_opening_auction": { "type": "boolean", "description": "Whether the algo should participate in the opening auction.", "default": false, "x-go-type-skip-optional-pointer": true }, "participate_closing_auction": { "type": "boolean", "description": "Whether the algo should participate in the closing auction.", "default": false, "x-go-type-skip-optional-pointer": true }, "aggressiveness": { "$ref": "#/$defs/AggressivenessLevel" }, "max_participation_percent": { "type": [ "integer", "null" ], "format": "int64", "description": "Hard ceiling on participation of market volume, as a percent (e.g. 20 = 20%)." } } }, "VenueTraderInfo": { "title": "Venue Trader Info", "type": "object", "required": [ "venue_mpid", "custodian_id", "venue_trader_id", "custodian_account_at_venue" ], "properties": { "venue_mpid": { "type": "string", "description": "The MPID of the venue.", "x-go-name": "VenueMPID" }, "custodian_id": { "type": "string", "description": "The ID of the custodian for the venue trader info.", "x-go-name": "CustodianID" }, "venue_trader_id": { "type": "string", "description": "The ID of the venue trader.", "x-go-name": "VenueTraderID" }, "custodian_account_at_venue": { "type": "string", "description": "The ID of the custodian account for the venue trader." } } }, "VwapParameters": { "title": "VWAP Parameters", "type": "object", "description": "Parameters for a volume-weighted average price (VWAP) algo. The algo works the order in\nproportion to the expected market volume profile over the specified time window, aiming to\nmatch the volume-weighted average price of the instrument over that window.", "properties": { "start_time": { "type": "string", "format": "date-time", "description": "Start of the absolute window to work the order." }, "end_time": { "type": "string", "format": "date-time", "description": "End of the absolute window to work the order." }, "would": { "$ref": "#/$defs/WouldParameters" }, "participate_opening_auction": { "type": "boolean", "description": "Whether the algo should participate in the opening auction.", "default": false, "x-go-type-skip-optional-pointer": true }, "participate_closing_auction": { "type": "boolean", "description": "Whether the algo should participate in the closing auction.", "default": false, "x-go-type-skip-optional-pointer": true }, "aggressiveness": { "$ref": "#/$defs/AggressivenessLevel" }, "max_participation_percent": { "type": [ "integer", "null" ], "format": "int64", "description": "Hard ceiling on participation of market volume, as a percent (e.g. 20 = 20%)." } } }, "WouldParameters": { "title": "Would Parameters", "type": "object", "description": "Models the \"I-Would\" trigger: a price at which the algo becomes aggressive / completes.", "properties": { "price": { "$ref": "#/$defs/Price" }, "trigger_quantity": { "$ref": "#/$defs/OrderSize" }, "trigger_percent": { "type": [ "integer", "null" ], "format": "int64", "description": "Percentage of the order quantity to complete when the trigger price is reached." } } }, "annotation": { "type": "string", "title": "annotation", "description": "Client-provided custom metadata for the order.", "maxLength": 10240 } } }