Protocol Documentation

Table of Contents

mt4mng.proto

Top

AccountCreateReply

FieldTypeLabelDescription
result UserRecord

error Error

AccountCreateRequest

[Example]

{

"id": "",

"name": "",

"group": "",

"login": "",

"password": "",

"enable": "",

"enableChangePassword": "",

"enableReadOnly": "",

"passwordInvestor": "",

"passwordPhone": "",

"country": "",

"city": "",

"state": "",

"zipcode": "",

"address": "",

"leadSource": "",

"phone": "",

"email": "",

"comment": "",

"leverage": "",

"agentAccount": "",

"credit": "",

"userColor": "",

"enableOtp": "False"

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required] Token returned by 'Connect' method [Required]

name string

group string

login int32

optional filter by login

password string

Password.

enable bool

enableChangePassword bool

enableReadOnly bool

passwordInvestor string

passwordPhone string

country string

city string

state string

zipcode string

address string

leadSource string

phone string

email string

comment string

Comment

leverage int32

agentAccount int32

credit double

Set true if credit

userColor int32

enableOtp bool

otpSecret string

AccountDeleteReply

FieldTypeLabelDescription
result string

error Error

AccountDeleteRequest

[Example]

{

"id": "",

"login": ""

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required] Token returned by 'Connect' method [Required]

login int32

optional filter by login

AccountDetailsManyReply

FieldTypeLabelDescription
result UserRecord repeated

error Error

AccountDetailsManyRequest

[Example]

{

"id": "",

"logins": ""

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required] Token returned by 'Connect' method [Required]

logins int32 repeated

Returns all accounts if 'login' parameters not specified

AccountDetailsReply

FieldTypeLabelDescription
result UserRecord

error Error

AccountDetailsRequest

[Example]

{

"id": "",

"login": ""

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required] Token returned by 'Connect' method [Required]

login int32

optional filter by login

AccountSummary

Account summary trading information

FieldTypeLabelDescription
Login int32

Balance

Balance double

Balance

Profit double

Profit

Equity double

Equity

Margin double

Used margin

FreeMargin double

Free margin

AccountUpdateReply

FieldTypeLabelDescription
result UserRecord

error Error

AccountUpdateRequest

[Example]

{

"id": "",

"login": "",

"group": "",

"name": "",

"password": "",

"enable": "",

"enableChangePassword": "",

"enableReadOnly": "",

"passwordInvestor": "",

"passwordPhone": "",

"country": "",

"city": "",

"state": "",

"zipcode": "",

"address": "",

"leadSource": "",

"phone": "",

"email": "",

"comment": "",

"leverage": "",

"balance": "",

"agentAccount": "",

"credit": "",

"userColor": "",

"enableOtp": "False"

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required] Token returned by 'Connect' method [Required]

login int32

optional filter by login [Required]

group string

name string

password string

Password.

enable bool

enableChangePassword bool

enableReadOnly bool

passwordInvestor string

passwordPhone string

country string

city string

state string

zipcode string

address string

leadSource string

phone string

email string

comment string

Comment

leverage int32

balance double

agentAccount int32

credit double

Set true if credit

userColor int32

enableOtp bool

otpSecret string

SendReports int32

AccountsReply

FieldTypeLabelDescription
result int32 repeated

error Error

AccountsRequest

[Example]

{

"id": ""

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required] Token returned by 'Connect' method [Required]

AccountsSummaryReply

FieldTypeLabelDescription
result AccountSummary repeated

error Error

AccountsSummaryRequest

[Example]

{

"id": "demo-token-mt4mng",

"login": "0"

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required] Token returned by 'Connect' method [Required]

login int32

optional filter by login

AdmUsersRequestReply

FieldTypeLabelDescription
result UserRecord repeated

error Error

AdmUsersRequestRequest

[Example]

{

"id": "",

"group": ""

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required]

group string

Byte

FieldTypeLabelDescription
MaxValue Byte

MinValue Byte

CfgRequestAccessReply

FieldTypeLabelDescription
result ConAccess repeated

error Error

CfgRequestAccessRequest

[Example]

{

"id": ""

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required]

CfgRequestBackupReply

FieldTypeLabelDescription
result ConBackup

error Error

CfgRequestBackupRequest

[Example]

{

"id": ""

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required]

CfgRequestCommonReply

FieldTypeLabelDescription
result ConCommon

error Error

CfgRequestCommonRequest

[Example]

{

"id": ""

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required]

CfgRequestDataServerReply

FieldTypeLabelDescription
result ConDataServer repeated

error Error

CfgRequestDataServerRequest

[Example]

{

"id": ""

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required]

CfgRequestFeederReply

FieldTypeLabelDescription
result ConFeeder repeated

error Error

CfgRequestFeederRequest

[Example]

{

"id": ""

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required]

CfgRequestGatewayAccountReply

FieldTypeLabelDescription
result ConGatewayAccount repeated

error Error

CfgRequestGatewayAccountRequest

[Example]

{

"id": ""

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required]

CfgRequestGatewayMarkupReply

FieldTypeLabelDescription
result ConGatewayMarkup repeated

error Error

CfgRequestGatewayMarkupRequest

[Example]

{

"id": ""

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required]

CfgRequestGatewayRuleReply

FieldTypeLabelDescription
result ConGatewayRule repeated

error Error

CfgRequestGatewayRuleRequest

[Example]

{

"id": ""

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required]

CfgRequestGroupReply

FieldTypeLabelDescription
result ConGroup repeated

error Error

CfgRequestGroupRequest

[Example]

{

"id": ""

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required]

CfgRequestHolidayReply

FieldTypeLabelDescription
result ConHoliday repeated

error Error

CfgRequestHolidayRequest

[Example]

{

"id": ""

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required]

CfgRequestLiveUpdateReply

FieldTypeLabelDescription
result ConLiveUpdate repeated

error Error

CfgRequestLiveUpdateRequest

[Example]

{

"id": ""

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required]

CfgRequestManagerReply

FieldTypeLabelDescription
result ConManager repeated

error Error

CfgRequestManagerRequest

[Example]

{

"id": ""

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required]

CfgRequestPluginReply

FieldTypeLabelDescription
result ConPluginParam repeated

error Error

CfgRequestPluginRequest

[Example]

{

"id": ""

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required]

CfgRequestSymbolGroupReply

FieldTypeLabelDescription
result ConSymbolGroup

error Error

CfgRequestSymbolGroupRequest

[Example]

{

"id": ""

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required]

CfgRequestSymbolReply

FieldTypeLabelDescription
result ConSymbol repeated

error Error

CfgRequestSymbolRequest

[Example]

{

"id": ""

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required]

CfgRequestSyncReply

FieldTypeLabelDescription
result ConSync repeated

error Error

CfgRequestSyncRequest

[Example]

{

"id": ""

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required]

CfgRequestTimeReply

FieldTypeLabelDescription
result ConTime

error Error

CfgRequestTimeRequest

[Example]

{

"id": ""

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required]

CfgUpdateGroupReply

FieldTypeLabelDescription
result string

error Error

CfgUpdateGroupRequest

[Example]

{

"id": "",

"group": ""

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required]

group ConGroup

CfgUpdateSymbolGroupReply

FieldTypeLabelDescription
result string

error Error

CfgUpdateSymbolGroupRequest

[Example]

{

"id": "",

"pos": "",

"symbolGroup": ""

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required]

pos int32

symbolGroup ConSymbolGroup

ChangePasswordReply

FieldTypeLabelDescription
result string

error Error

ChangePasswordRequest

[Example]

{

"id": "",

"login": "",

"password": "",

"isInvestor": "False"

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required] Token returned by 'Connect' method [Required]

login int32

optional filter by login [Required]

password string

Password. [Required]

isInvestor bool

Investor or master password

ChartInfo

Request chart history struct

FieldTypeLabelDescription
Symbol string

Symbol

Period int32

Period (PERIOD_*)

Start google.protobuf.Timestamp

Start of sbytet block

End google.protobuf.Timestamp

End of sbytet block

Timesign google.protobuf.Timestamp

Timestamp of existing sbytet base

Mode int32

Request mode

ChartRequestObsoleteReply

FieldTypeLabelDescription
result RateInfoOld repeated

error Error

ChartRequestObsoleteRequest

[Example]

{

"id": "",

"chart": ""

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required]

chart ChartInfo

ChartRequestReply

FieldTypeLabelDescription
result RateInfo repeated

error Error

ChartRequestRequest

[Example]

{

"id": "",

"chart": ""

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required]

chart ChartInfo

ConAccess

Access configuration

FieldTypeLabelDescription
Action int32

Type of action (FW_BLOCK,FW_PERMIT)

From uint32

From, to addresses

To uint32

Comment string

Comment

Reserved int32 repeated

Reserved

ConBackup

Backup configuration

FieldTypeLabelDescription
FullbackupPath string

Path to backup

FullbackupPeriod int32

Full backup's period-BACKUP_1HOUR, BACKUP_4HOURS, BACKUP_1DAY

FullbackupStore int32

Full backup's store time-BU_STORE_1MONTH, BU_STORE_3MONTHS, BU_STORE_6MONTHS,BU_STORE_1YEAR

FullbackupLasttime google.protobuf.Timestamp

Full backup's last execution time

FullbackupShift int32

Full backup timeshift (minutes)

ExternalPath string

Path to external processing directory

ArchivePeriod int32

Period of archive backup-ARC_BACKUP_5MIN, ARC_BACKUP_15MIN, ARC_BACKUP_30MIN, ARC_BACKUP_1HOUR

ArchiveStore int32

Archive backup's store time-ARC_STORE_1WEEK, ARC_STORE_2WEEKS, ARC_STORE_1MONTH, ARC_STORE_3MONTH, ARC_STORE_6MONTH

ArchiveLasttime google.protobuf.Timestamp

Archive backup's last execution time

ExportSecurities string

Comma separated list of exported securities

ExportPath string

Path to export script

ExportPeriod int32

Export period-enumeration EXPORT_1MIN, EXPORT_5MIN, EXPORT_15MIN, EXPORT_30MIN,EXPORT_1HOUR

ExportLasttime google.protobuf.Timestamp

Export's last execution time

WatchRole int32

Server role { WATCH_STAND_ALONE, WATCH_MASTER, WATCH_SLAVE }

WatchPassword string

Slave server password

WatchOpposite string

Opposite server IP address and port

WatchIp int32

Opposite server IP

ArchiveShift int32

Shift of archive backup time (in minutes)

WatchState int32

Watch dog state

WatchFailover int32

Watch dog failover mode

WatchTimeout Byte

Watch dog timeout

WatchLogin int32

Watch dog login

WatchTimestamp google.protobuf.Timestamp

Watch dog timestamp

ConCommon

Common configuration

FieldTypeLabelDescription
Owner string

Name string

Server name

Address uint32

IP address assigned to the server

Port int32

Port

Timeout uint32

Sockets timeout

Typeofdemo int32

Demo-accounts type (DEMO_DISABLED, DEMO_PROLONG, DEMO_FIXED)

Timeofdemo int32

Demo-account living time

Daylightcorrection int32

Allow daylight correction

Internal string

Reserved

TimezoneReal int32

Time zone with day light mode

Timezone int32

Time zone with day light mode

Timesync string

Time synchronization server address

Minclient int32

Minimal authorized client version

Minapi int32

Minimal authorized client version

FeederTimeout uint32

Data feed switch timeout

Keepemails int32

Internal mail keep period

Endhour int32

Endminute int32

OptimizationTime int32

Optimization start time (minutes)

OptimizationLasttime int32

Optimization last time

OptimizationCounter int32

Internal variable

OptimizationUnused int32 repeated

Reserved for future use

Antiflood int32

Enable antiflood control

Floodcontrol int32

Max. antiflood connections

LiveupdateMode int32

LiveUpdate mode (LIVE_UPDATE_NO,LIVE_UPDATE_ALL,LIVE_UPDATE_NO_SERVER)

Lastorder int32

Last order's ticket (read only)

Lastlogin int32

Last account's number (read only)

Lostlogin int32

Lost commission's login (read only)

RolloversMode int32

Rollover mode (ROLLOVER_NORMAL,ROLLOVER_REOPEN_BY_CLOSE_PRICE,ROLLOVER_REOPEN_BY_BID)

PathDatabase string

Path to databases

PathHistory string

Path to history bases

PathLog string

Path to log

OvernightLastDay google.protobuf.Timestamp

Day of last overnight

OvernightLastTime google.protobuf.Timestamp

Time of last overnight

OvernightPrevTime google.protobuf.Timestamp

Time of next to last overnight

OvermonthLastMonth google.protobuf.Timestamp

Month of last report

Adapters string

Network adapters list (read-only)

BindAdresses uint32 repeated

Array of avaible IP addresses

ServerVersion int32

Server version

ServerBuild int32

Server build

WebAdresses uint32 repeated

Web services access list (comma separated IP addresses)

StatementMode int32

Statement generation time (STATEMENT_END_DAY,STATEMENT_START_DAY)

MonthlyStateMode int32

Monthly statement generation day (MONTHLY_STATEMENT_END_MONTH,MONTHLY_STATEMENT_START_MONTH)

Keepticks int32

Ticks keep period

StatementWeekend int32

Generate statements at weekends

LastActivate google.protobuf.Timestamp

Last activation datetime

StopLast google.protobuf.Timestamp

Last stop datetime

StopDelay int32

Last stop delay

StopReason int32

Last stop reason

AccountUrl string

Account allocation URL

Reserved int32 repeated

ConDataServer

Data Servers configuration

FieldTypeLabelDescription
Server string

Server address (server:ip)

Ip uint32

Server IP

Description string

Server description

Isproxy int32

Can server be proxy?

Priority int32

Priority: 0-7 base, 255-idle

Loading uint32

Server loading (uint_MAX-server does not inform its loading)

IpInternal uint32

Internal IP address

Reserved int32 repeated

Reserved

ConFeeder

Datafeed configuration

FieldTypeLabelDescription
Name string

Name

File string

Datafeed filename

Server string

Server address

Login string

Datafeed login

Pass string

Datafeed password

Keywords string

Keywords (news filtration)

Enable int32

Enable feeder

Mode int32

Datafeed mode-enumeration FEED_QUOTES, FEED_NEWS, FEED_QUOTESNEWS

Timeout int32

Max. freeze time (default ~120 sec.)

TimeoutReconnect int32

Reconnect timeout before attemps_sleep connect attempts (default ~ 5 sec)

TimeoutSleep int32

Reconnect timeout after attemps_sleep connect attempts (default ~ 60 sec)

AttempsSleep int32

NewsLangid int32

News language id

Unused int32 repeated

Reserved

ConGatewayAccount

Gateway account configuration

FieldTypeLabelDescription
Enable int32

Enable flag 0 - disabled, 1 - enabled

Name string

Public name

Id int32

Internal id

Type int32

Type (obsolete)

Login int32

STP MT4 login

Address string

MT4 server address

Password string

STP MT4 password

NotifyLogins int32 repeated

List of logins for internal email notification

Flags int32

Flag fields

Reserved int32 repeated

Reserved

ConGatewayMarkup

Gateway markup configuration

FieldTypeLabelDescription
Enable int32

Enable flag 0 - disabled, 1 - enabled

Source string

Source symbol\symbols mask\symbols group name

Symbol string

Local symbol name

AccountName string

Account name (obsolete)

AccountId int32

Account internal id (obsolete)

BidMarkup int32

Bid markup in pips

AskMarkup int32

Ask markup in pips

Reserved int32 repeated

Reserved

ConGatewayRule

Gateway rules configuration

FieldTypeLabelDescription
Enable int32

Enable flag 0 - disabled, 1 - enabled

Name string

Public name

RequestSymbol string

Symbol\symbols mask\symbols group name

RequestGroup string

Group name or group mask

RequestReserved int32 repeated

Reserved

ExeAccountName string

Account name

ExeAccountId int32

Account internal id

ExeMaxDeviation int32

Max. devation

ExeMaxProfitSlippage int32

Max profit slippage in pips

ExeMaxProfitSlippageLots int32

Max profit slippage volume in lots

ExeMaxLosingSlippage int32

Max losing slippage in pips

ExeMaxLosingSlippageLots int32

Max losing slippage volume in lots

ExeAccountPos int32

Account current position

ExeVolumePercent int32

Coverage percentage

ExeFlags int32

Execution flags

ExeReserved int32 repeated

Reserved

ConGroup

Client group configuration

FieldTypeLabelDescription
Group string

Group name

Enable int32

Enable group

Timeout int32

Trade confirmation timeout (seconds)

OtpMode int32

One-time password mode

Company string

Company name

Signature string

Statements signature

SupportPage string

Company support page

SmtpServer string

Statements SMTP server

SmtpLogin string

Statements SMTP login

SmtpPassword string

Statements SMTP password

SupportEmail string

Support email

Templates string

Path to directory with custom templates

Copies int32

Copy statements on support email

Reports int32

Enable statements

DefaultLeverage int32

Default leverage (user don't specify leverage himself)

DefaultDeposit double

Default deposit (user don't specify balance himself)

Maxsecurities int32

Maximum simultaneous securities

Secgroups ConGroupSec repeated

Security group settings

Secmargins ConGroupMargin repeated

Special securities settings

SecmarginsTotal int32

Count of special securities settings

Currency string

Deposit currency

Credit double

Virtual credit

MarginCall int32

Margin call level (percents)

MarginMode int32

Margin mode-MARGIN_DONT_USE,MARGIN_USE_ALL,MARGIN_USE_PROFIT,MARGIN_USE_LOSS

MarginStopout int32

Stop out level

Interestrate double

Annual interest rate (percents)

UseSwap int32

News int32

News mode

Rights int32

Rights bit mask-ALLOW_FLAG_EMAIL

CheckIePrices int32

Check IE prices on requests

Maxpositions int32

Maximum orders and open positions

CloseReopen int32

Partial close mode (if !=0 original position will be fully closed and remain position will be fully reopened)

HedgeProhibited int32

Hedge prohibition flag

CloseFifo int32

Fifo rule

HedgeLargeleg int32

Use large leg margin for hedged positions

UnusedRights int32 repeated

Reserved

SecuritiesHash string

Internal data

MarginType int32

Margin controlling type { MARGIN_TYPE_PERCENT, MARGIN_TYPE_CURRENCY }

ArchivePeriod int32

Inactivity period after which account moves to archive base (in days)

ArchiveMaxBalance int32

Maxumum balance of accounts to move in archive base

StopoutSkipHedged int32

Skip fully hedged accounts when checking for stopout

ArchivePendingPeriod int32

Pendings clean period

NewsLanguages uint32 repeated

LANGID array

NewsLanguagesTotal uint32

News languages total

Reserved int32 repeated

ConGroupMargin

Special securities configurations for client group

FieldTypeLabelDescription
Symbol string

Security

SwapLong double

Swap size for long and short positions

SwapShort double

MarginDivider double

Margin divider

Reserved int32 repeated

ConGroupSec

Security group configuration for client group

FieldTypeLabelDescription
Show int32

Enable show and trade for this group of securites

Trade int32

Clients trade rights-bit mask see TRADE_DENY_NONE,TRADE_DENY_CLOSEBY,TRADE_DENY_MUCLOSEBY

Execution int32

Dealing mode-EXECUTION_MANUAL,EXECUTION_AUTO,EXECUTION_ACTIVITY

CommBase double

Standart commission

CommType int32

Commission type-COMM_TYPE_MONEY,COMM_TYPE_PIPS,COMM_TYPE_PERCENT

CommLots int32

Commission lots mode-COMMISSION_PER_LOT,COMMISSION_PER_DEAL

CommAgent double

Agent commission

CommAgentType int32

Agent commission mode-COMM_TYPE_MONEY, COMM_TYPE_PIPS

SpreadDiff int32

Spread difference in compare with default security spread

LotMin int32

Allowed minimal and maximal lot values

LotMax int32

LotStep int32

Allowed step value (10 lot-1000, 1 lot-100, 0.1 lot-10)

IeDeviation int32

Maximum price deviation in Instant Execution mode

Confirmation int32

Use confirmation in Request mode

TradeRights int32

Clients trade rights-bit mask see TRADE_DENY_NONE,TRADE_DENY_CLOSEBY,TRADE_DENY_MUCLOSEBY

IeQuickMode int32

Do not resend request to the dealer when client uses deviation

AutocloseoutMode int32

Auto close-out method { CLOSE_OUT_NONE, CLOSE_OUT_HIHI, CLOSE_OUT_LOLO, CLOSE_OUT_HILO, CLOSE_OUT_LOHI, CLOSE_OUT_LOHI, CLOSE_OUT_FIFO, CLOSE_OUT_LIFO, CLOSE_OUT_INTRDAY_FIFO }

CommTax double

Commission taxes

CommAgentLots int32

Agent commission per lot/per deal { COMMISSION_PER_LOT,COMMISSION_PER_DEAL }

FreemarginMode int32

"soft" margin check

Reserved int32 repeated

Reserved

Name string

Security group name

Description string

Security group description

ConHoliday

Hollidays configuration

FieldTypeLabelDescription
Year int32

Year

Month int32

Month

Day int32

Day

From int32

To int32

Symbol string

Security name or symbol's group name or "All"

Description string

Description

Enable int32

Enable

Reserved int32 repeated

Reserved

ConLiveUpdate

};

FieldTypeLabelDescription
Company string

Company

Path string

Path to LiveUpdate

Version int32

Version

Build int32

Build

Maxconnect int32

Max. simultaneous connections

Connections int32

Current connections (read only)

Type int32

Type LIVE_UPDATE_*

Enable int32

Enable

Totalfiles int32

Total files count

Files LiveInfoFile repeated

Files' configurations

Reserved int32 repeated

Reserved

ConManager

Manager configuration

FieldTypeLabelDescription
Login int32

Login

Manager int32

Money int32

Online int32

Right to see online users

Riskman int32

Right to use analyzer

Broker int32

Right to deal

Admin int32

Right to server administration

Logs int32

Right to see logs

Reports int32

Right to see reports

Trades int32

Right to add/modify/delete trades

MarketWatch int32

Right to change spread, spread balance, stop levels, execution mode and send quotes

Email int32

Right to send internal mail

UserDetails int32

Right to see clients private data-name,country,address,phone,email etc.

SeeTrades int32

Right to see trades

News int32

Right to send news

Plugins int32

Right to configure plugins

ServerReports int32

Right to receive server reports

Techsupport int32

Right to access to technical support page

Market int32

Right to change spread, spread balance, stop levels, execution mode and send quotes

Notifications int32

Right to push notifications

Unused int32 repeated

Ipfilter int32

Enable IP control

IpFrom uint32

Range of allowed IPs

IpTo uint32

Mailbox string

Name of mailbox for internal mail

Groups string

Comma separated list of managed groups (allowed '*' wildcard)

Secgroups ConManagerSec repeated

Manager rights for security groups

ExpTime uint32

Internal data

Name string

Manager name (read only)

InfoDepth int32

Maximum available data (in days)

Reserved int32 repeated

ConManagerSec

Manager rights for security groups

FieldTypeLabelDescription
Internal int32

Internal data

Enable int32

Enable

MinimumLots int32

Min. lots

MaximumLots int32

Max. lots

Unused int32 repeated

Reserved

ConPlugin

Plugin configuration

FieldTypeLabelDescription
File string

Plugin file name

Info PluginInfo

Plugin description

Enabled int32

Plugin enabled/disabled

Configurable int32

Is plugin configurable

ManagerAccess int32

Plugin can be accessed from manager terminal

Reserved int32 repeated

Reserved

ConPluginParam

};

FieldTypeLabelDescription
Plugin ConPlugin

Plugin configuration

Params PluginCfg

Plugin parameters

Total int32

Total plugin parameters

ConSession

Symbol sessions configurations

FieldTypeLabelDescription
OpenHour int32

OpenMin int32

CloseHour int32

CloseMin int32

Open int32

Internal data

Close int32

Align int32 repeated

Internal data

ConSessions

};

FieldTypeLabelDescription
Quote ConSession repeated

Quote sessions

Trade ConSession repeated

Trade sessions

QuoteOvernight int32

Internal data

TradeOvernight int32

Internal data

Reserved int32 repeated

Reserved

ConSymbol

#define MAX_SYMBOLS 1024

FieldTypeLabelDescription
Symbol string

Name

Description string

Description

Source string

Synonym

Currency string

Currency

Type int32

Security group (see ConSymbolGroup)

Digits int32

Security precision

Trade int32

Trade mode

BackgroundColor int32

Background color

Count int32

Symbols index

CountOriginal int32

Symbols index in market watch

ExternalUnused int32 repeated

Realtime int32

Allow real time quotes

Starting google.protobuf.Timestamp

Trades starting date (UNIX time)

Expiration google.protobuf.Timestamp

Trades end date (UNIX time)

Sessions ConSessions repeated

ProfitMode int32

Profit calculation mode

ProfitReserved int32

Reserved

Filter int32

Filter value

FilterCounter int32

Filtration parameter

FilterLimit double

Max. permissible deviation from last quote (percents)

FilterSmoothing int32

Smoothing

FilterReserved float

Reserved

Logging int32

Enable to log quotes

Spread int32

Spread

SpreadBalance int32

Spread balance

Exemode int32

Execution mode

SwapEnable int32

Enable swaps

SwapType int32

Swap type

SwapLong double

SwapShort double

SwapRollover3days int32

Triple rollover day-0-Monday,1-Tuesday...4-Friday

ContractSize double

Contract size

TickValue double

One tick value

TickSize double

One tick size

StopsLevel int32

Stops deviation value

GtcPendings int32

GTC mode { ORDERS_DAILY, ORDERS_GTC, ORDERS_DAILY_NO_STOPS }

MarginMode int32

Margin calculation mode

MarginInitial double

Initial margin

MarginMaintenance double

Margin maintenance

MarginHedged double

Hedged margin

MarginDivider double

Margin divider

Point double

Point size-(1/(10^digits)

Multiply double

Multiply 10^digits

BidTickvalue double

Tickvalue for bid

AskTickvalue double

Tickvalue for ask

LongOnly int32

Allow only BUY positions

InstantMaxVolume int32

Max. volume for Instant Execution

MarginCurrency string

Currency of margin requirments

FreezeLevel int32

Modification freeze level

MarginHedgedStrong int32

Strong hedged margin mode

ValueDate google.protobuf.Timestamp

Value date

QuotesDelay int32

Quotes delay after session start

SwapOpenprice int32

Use open price at swaps calculation in SWAP_BY_INTEREST mode

SwapVariationMargin int32

Sbytege variation margin on rollover

Unused int32 repeated

Reserved

ConSymbolGroup

Symbol groups

FieldTypeLabelDescription
Name string

Group name

Description string

Group description

ConSync

Synchronization configuration

FieldTypeLabelDescription
Server string

Name (address

Unusedport int32

Port

Login string

For future use-login

Password string

For future use=password

Enable int32

Enable sychronization

Mode int32

Synchronization mode: HB_ADD,HB_UPDATE,HB_INSERT

From google.protobuf.Timestamp

To google.protobuf.Timestamp

Securities string

Symbols list

Timecorrection int32

Time correction in minutes

Reserved int32 repeated

Reserved

ConTime

Time configuration

FieldTypeLabelDescription
Days int32 repeated

Server's accessebility (7 days-24 hours, 0-denied, 1-allowed)

Dayscontrol int32

Internal variable

Reserved int32 repeated

Reserved

ConnectReply

FieldTypeLabelDescription
result string

error Error

ConnectRequest

[Example]

{

"user": "",

"password": "",

"server": ""

}

FieldTypeLabelDescription
user int32

Account number. [Required]

password string

Password. [Required]

server string

Host - ip adddress or dns name with or without port number. [Required]

unsubscribe bool

Unsusbcribe all symbols

DailyReport

Daily report

FieldTypeLabelDescription
Login int32

Login

Ctm google.protobuf.Timestamp

Time

Group string

Group

Bank string

Bank

BalancePrev double

Previous balance

Balance double

Previous balance

Deposit double

Deposit

Credit double

Credit

ProfitClosed double

Closed profit/loss

Profit double

Closed profit/loss

Equity double

Equity

Margin double

Used margin

MarginFree double

Free margin

Next int32

(internal)

Reserved int32 repeated

Reserved

DailyReportsRequestReply

FieldTypeLabelDescription
result DailyReport repeated

error Error

DailyReportsRequestRequest

[Example]

{

"id": "",

"req": ""

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required]

name string

Group name

from string

From

to string

To

logins int32 repeated

Logins array

DealerRequestGetReply

FieldTypeLabelDescription
result RequestInfo

error Error

DealerRequestGetRequest

[Example]

{

"id": ""

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required]

DepositReply

FieldTypeLabelDescription
result string

error Error

DepositRequest

[Example]

{

"id": "",

"login": "",

"amount": "",

"comment": "",

"credit": "False"

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required] Token returned by 'Connect' method [Required]

login int32

optional filter by login [Required]

amount double

Amount [Required]

comment string

Comment [Required]

credit bool

Set true if credit

creditExpiration google.protobuf.Timestamp

Credit expiration time in yyyy-MM-ddTHH:mm:ss format

Error

FieldTypeLabelDescription
code ErrorCode

message string

stackTrace string

EventsReply

FieldTypeLabelDescription
result string

error Error

EventsRequest

[Example]

{

"id": ""

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method Token returned by 'Connect' method [Required]

GetClientsReply

FieldTypeLabelDescription
result string repeated

error Error

GetClientsRequest

GetJournalReply

FieldTypeLabelDescription
result TradeRecord repeated

error Error

GetJournalRequest

[Example]

{

"id": "",

"mode": "0"

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required] Token returned by 'Connect' method [Required]

mode int32

mode standard-0 logins-1 trades-2 errors-3 full-60

to google.protobuf.Timestamp

'To' time in format: yyyy-MM-ddTHH:mm:ss

from google.protobuf.Timestamp

'From' time in format: yyyy-MM-ddTHH:mm:ss

filter string

GroupUpdate

FieldTypeLabelDescription
Group ConGroup

Type TransactionType

GroupsRequestReply

FieldTypeLabelDescription
result ConGroup repeated

error Error

GroupsRequestRequest

[Example]

{

"id": ""

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required]

HealthReply

FieldTypeLabelDescription
result string

error Error

HealthRequest

[Example]

{

"id": ""

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required] Token returned by 'Connect' method [Required]

LiveInfoFile

#define LIVE_FILES_MAX (128)

FieldTypeLabelDescription
File string

File name

Size int32

File size

Hash string

File hash

Reserved int32 repeated

Reserved

MarginLevel

Margin level of the user

FieldTypeLabelDescription
Login int32

User login

Group string

User group

Leverage int32

User leverage

Updated int32

(internal)

Balance double

Balance+credit

Equity double

Equity

Volume int32

Lots

Margin double

Margin requirements

MarginFree double

Free margin

MarginLvl double

Margin level

MarginType int32

Margin controlling type (percent/currency)

LevelType MarginLevelType

Level type(ok/margincall/stopout)

MarginLevelRequestReply

FieldTypeLabelDescription
result MarginLevel

error Error

MarginLevelRequestRequest

[Example]

{

"id": "",

"login": ""

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required]

login int32

OnQuoteReply

FieldTypeLabelDescription
result SymbolInfo

error Error

OnQuoteRequest

[Example]

{

"id": ""

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method Token returned by 'Connect' method [Required]

OnTickValueReply

FieldTypeLabelDescription
result SymbolTickValue

error Error

OnTickValueRequest

[Example]

{

"id": "demo-token-mt4"

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method Token returned by 'Connect' method [Required]

OnUpdateGroupsReply

FieldTypeLabelDescription
result GroupUpdate

error Error

OnUpdateGroupsRequest

[Example]

{

"id": ""

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method Token returned by 'Connect' method [Required]

OnUpdateRequestsReply

FieldTypeLabelDescription
result RequestUpdate

error Error

OnUpdateRequestsRequest

[Example]

{

"id": ""

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method Token returned by 'Connect' method [Required]

OnUpdateSymbolsReply

FieldTypeLabelDescription
result SymbolUpdate

error Error

OnUpdateSymbolsRequest

[Example]

{

"id": ""

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method Token returned by 'Connect' method [Required]

OnUpdateTradesSlimReply

FieldTypeLabelDescription
result TradeUpdate

error Error

OnUpdateTradesSlimRequest

[Example]

{

"id": ""

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method Token returned by 'Connect' method [Required]

OnUpdateUsersReply

FieldTypeLabelDescription
result UserUpdate

error Error

OnUpdateUsersRequest

[Example]

{

"id": ""

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method Token returned by 'Connect' method [Required]

OnUserChangeReply

FieldTypeLabelDescription
result UserGroupChangeResult

error Error

OnUserChangeRequest

[Example]

{

"id": ""

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method Token returned by 'Connect' method [Required]

OnlineRecord

Online user description

FieldTypeLabelDescription
Counter int32

Connections counter

Reserved int32

Reserved

Login int32

User login

Ip uint32

Connection ip address

Group string

User group

OnlineRequestReply

FieldTypeLabelDescription
result OnlineRecord repeated

error Error

OnlineRequestRequest

[Example]

{

"id": ""

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required]

OpenedOrdersReply

FieldTypeLabelDescription
result TradeRecord repeated

error Error

OpenedOrdersRequest

[Example]

{

"id": ""

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required] Token returned by 'Connect' method [Required]

OrderCloseReply

FieldTypeLabelDescription
result TradeRecord

error Error

OrderCloseRequest

[Example]

{

"id": "",

"ticket": "",

"lots": "0",

"price": "0",

"slippage": "0"

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required] Token returned by 'Connect' method [Required]

ticket int32

Order ticket [Required]

lots double

Lots

price double

Price

slippage int32

Slippage

OrderHistoryExReply

FieldTypeLabelDescription
result TradeRecord repeated

error Error

OrderHistoryExRequest

[Example]

{

"id": "",

"login": "",

"from": "1970-01-01T00:00:00",

"to": "2030-01-01T00:00:00"

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required] Token returned by 'Connect' method [Required]

login int32

optional filter by login [Required]

from string

'From' time in format: yyyy-MM-ddTHH:mm:ss

to string

'To' time in format: yyyy-MM-ddTHH:mm:ss

OrderHistoryReply

FieldTypeLabelDescription
result TradeRecord repeated

error Error

OrderHistoryRequest

[Example]

{

"id": "",

"login": ""

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required] Token returned by 'Connect' method [Required]

login int32

optional filter by login [Required]

from google.protobuf.Timestamp

'From' time in format: yyyy-MM-ddTHH:mm:ss

to google.protobuf.Timestamp

'To' time in format: yyyy-MM-ddTHH:mm:ss

OrderProfitReply

FieldTypeLabelDescription
result OrderProfitUpdate

error Error

OrderProfitRequest

[Example]

{

"id": "demo-token-mt4mng"

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required] Token returned by 'Connect' method [Required]

OrderProfitUpdate

Profit update message

FieldTypeLabelDescription
Login int32

Account number

Balance double

Balace

Equity double

Equity

Margin double

User margin

FreeMargin double

Free margin

Profit double

Orders ProfitUpdateOrder repeated

Opened orders

OrderSendReply

FieldTypeLabelDescription
result TradeRecord

error Error

OrderSendRequest

[Example]

{

"id": "",

"login": "",

"symbol": "",

"operation": "",

"lots": "",

"price": "0",

"slippage": "0",

"stoploss": "0",

"takeprofit": "0"

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required] Token returned by 'Connect' method [Required]

login int32

optional filter by login [Required]

symbol string

Symbol [Required]

operation Op

But or sell, market or pending [Required]

lots double

Lots [Required]

price double

Price

slippage int32

Slippage

stoploss double

StopLoss

takeprofit double

TakeProfit

comment string

Comment

expiration google.protobuf.Timestamp

Expiration

PerformanceInfo

Performance information

FieldTypeLabelDescription
Ctm google.protobuf.Timestamp

Users int32

Online users

Cpu int32

Processor loading (%)

Freemem int32

Free memory (Kb)

Network int32

Network activity (Kb/s)

Sockets int32

All open sockets in system

PerformanceRequestReply

FieldTypeLabelDescription
result PerformanceInfo repeated

error Error

PerformanceRequestRequest

[Example]

{

"id": "",

"from": ""

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required]

from int32

PingReply

FieldTypeLabelDescription
result string

error Error

PingRequest

PluginCfg

Plugin configuration parameter

FieldTypeLabelDescription
Name string

Parameter name

Value string

Parameter value

Reserved int32 repeated

Reserved

PluginInfo

Plugin description

FieldTypeLabelDescription
Name string

Plugin name

Version uint32

Plugin version

Copyright string

Plugin copyright

Reserved int32 repeated

Reserved

ProfitUpdateOrder

ProfitUpdate order parameters

FieldTypeLabelDescription
Ticket int32

Ticket

Profit double

Profit

RateInfo

double vol; // volume

FieldTypeLabelDescription
Ctm google.protobuf.Timestamp

Rate time

Open int32

Open price: 11987=119.87

High int32

High,low,close shift from open

Low int32

Close int32

Vol double

Volume

RateInfoOld

Rate the in chart base

FieldTypeLabelDescription
Ctm google.protobuf.Timestamp

Rate time

Open int32

Open price: 11987=119.87

High int32

High,low,close shift from open

Low int32

Close int32

Vol double

Volume

ReportsRequestReply

FieldTypeLabelDescription
result TradeRecord repeated

error Error

ReportsRequestRequest

[Example]

{

"id": "",

"from": "1970-01-01T00:00:00",

"to": "2030-01-01T00:00:00",

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required]

name string

Request group name

from string

From

to string

To

logins int32 repeated

Logins array

RequestInfo

Trade request

FieldTypeLabelDescription
Id int32

Request id

Status Dc

Request status

Time uint32

Request time

Manager int32

Manager processing request (if any)

Login int32

User login

Group string

User group

Balance double

User balance

Credit double

User credit

Prices double repeated

Bid/ask

Trade TradeTransInfo

Trade transaction

GwVolume int32

Gateway order volume

GwOrder int32

Gateway order ticket

GwPrice int32

Gateway order price deviation (pips) from request price

Prev RequestInfo

RequestInfoGetReply

FieldTypeLabelDescription
result RequestInfo

error Error

RequestInfoGetRequest

[Example]

{

"id": "",

"pos": ""

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required]

pos int32

RequestUpdate

FieldTypeLabelDescription
Request RequestInfo

Type TransactionType

RequestsGetReply

FieldTypeLabelDescription
result RequestInfo repeated

error Error

RequestsGetRequest

[Example]

{

"id": ""

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required]

SubscribeManyReply

FieldTypeLabelDescription
result string

error Error

SubscribeManyRequest

[Example]

{

"id": "demo-token-mt4mng"

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required] Token returned by 'Connect' method [Required]

symbol string repeated

Symbol [Required]

SubscribeOrderProfitReply

FieldTypeLabelDescription
result TradeRecord repeated

error Error

SubscribeOrderProfitRequest

[Example]

{

"id": "demo-token-mt4mng"

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required] Token returned by 'Connect' method [Required]

SubscribeReply

FieldTypeLabelDescription
result string

error Error

SubscribeRequest

[Example]

{

"id": "demo-token-mt4mng",

"symbol": "EURUSD"

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required] Token returned by 'Connect' method [Required]

symbol string

Symbol [Required]

SubscribeTickValueReply

FieldTypeLabelDescription
result string

error Error

SubscribeTickValueRequest

[Example]

{

"id": "demo-token-mt4",

"symbol": "EURUSD",

"currency": "USD",

"interval": "0"

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required] Token returned by 'Connect' method [Required]

symbol string

Symbol [Required]

currency string

Account currency for tick value calculation [Required]

interval int32

Minimum interval between events in milliseconds

SymbolGroupsReply

FieldTypeLabelDescription
result ConSymbolGroup repeated

error Error

SymbolGroupsRequest

[Example]

{

"id": ""

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required]

SymbolInfo

Selected symbol information

FieldTypeLabelDescription
Symbol string

Symbol name

Digits int32

Floating point digits

Count int32

Symbol counter

Visible int32

Visibility

Type int32

Symbol type (symbols group index)

Point double

Symbol point=1/pow(10,digits)

Spread int32

Symbol spread

SpreadBalance int32

Spread balance

Direction int32

Direction

Updateflag int32

Update flag

Lasttime google.protobuf.Timestamp

Last tick time

Bid double

Bid, ask

Ask double

High double

High, low

Low double

Commission double

Commission

CommType int32

Commission type

SymbolTickValue

Tick value update

FieldTypeLabelDescription
Symbol string

Symbol

TickValue double

Tick value

TickSize double

Tick size

SymbolUpdate

FieldTypeLabelDescription
Symbol ConSymbol

Type TransactionType

SymbolsByUserGroupReply

FieldTypeLabelDescription
result ConSymbol repeated

error Error

SymbolsByUserGroupRequest

[Example]

{

"id": "demo-token-mt4mng",

"group": "demoforex"

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required] Token returned by 'Connect' method [Required]

group string

TickRecord

Tick record in base

FieldTypeLabelDescription
Ctm google.protobuf.Timestamp

Tick time

Bid double

Bid, ask

Ask double

Datafeed int32

Index if datafeed

Flags int32

TICK_FLAG_* flags

TickRequest

Tick request

FieldTypeLabelDescription
Symbol string

Symbol

From google.protobuf.Timestamp

Start of period

To google.protobuf.Timestamp

End of period

Flags int32

TICK_FLAG_* flags

TicksRequestReply

FieldTypeLabelDescription
result TickRecord repeated

error Error

TicksRequestRequest

[Example]

{

"id": "",

"request": ""

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required]

request TickRequest

TradeRecord

Trade Record

FieldTypeLabelDescription
Order int32

Order ticket

Login int32

Owner's login

Symbol string

Security

Digits int32

Security precision

Cmd Op

Trade command

Volume int32

Volume

OpenTime google.protobuf.Timestamp

Open time

State int32

Reserved

OpenPrice double

Open price

Sl double

Tp double

CloseTime google.protobuf.Timestamp

Close time

GwVolume int32

Gateway order volume

Expiration google.protobuf.Timestamp

Pending order's expiration time

Reason int32

Trade reason

ConvReserv string

Reserved fields

ConvRates double repeated

Convertation rates from profit currency to group deposit currency

Commission double

Commission

CommissionAgent double

Agent commission

Storage double

Order swaps

ClosePrice double

Close price

Profit double

Profit

Taxes double

Taxes

Magic int32

Special value used by client experts

Comment string

Comment

GwOrder int32

Gateway order ticket

Activation int32

Used by MT Manager

GwOpenPrice int32

Gateway order price deviation (pips) from order open price

GwClosePrice int32

Gateway order price deviation (pips) from order close price

MarginRate double

Margin convertation rate (rate of convertation from margin currency to deposit one)

Timestamp google.protobuf.Timestamp

Timestamp

ApiData int32 repeated

For api usage

TradeRecordPositionUpdate

FieldTypeLabelDescription
UpdateAction TransactionType

Order int32

Login int32

Symbol string

Digits int32

Cmd Op

Volume int32

OpenTime google.protobuf.Timestamp

State int32

OpenPrice double

Sl double

Tp double

CloseTime google.protobuf.Timestamp

GwVolume int32

Expiration google.protobuf.Timestamp

Reason int32

ConvReserv string

ConvRates double repeated

Commission double

CommissionAgent double

Storage double

ClosePrice double

Profit double

Taxes double

Magic int32

Comment string

GwOrder int32

Activation int32

GwOpenPrice int32

GwClosePrice int32

MarginRate double

Timestamp google.protobuf.Timestamp

ApiData int32 repeated

TradeRecordRequestReply

FieldTypeLabelDescription
result TradeRecord

error Error

TradeRecordRequestRequest

[Example]

{

"id": "",

"ticket": ""

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required]

ticket int32

TradeRecordsRequestReply

FieldTypeLabelDescription
result TradeRecord repeated

error Error

TradeRecordsRequestRequest

[Example]

{

"id": "",

"tickets": ""

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required]

tickets int32 repeated

TradeTransInfo

Trade transaction

FieldTypeLabelDescription
Type TtPrices

Trade transaction type

Flags int32

Flags

Cmd Op

Trade command

Order int32

Order, order by

Orderby int32

Symbol string

Trade symbol

Volume int32

Trade volume

Price double

Trade price

Sl double

Stoploss, takeprofit

Tp double

IeDeviation int32

Deviation on IE

Comment string

Comment

Expiration google.protobuf.Timestamp

Pending order expiration time

Crc int32

Crc

TradeUpdate

FieldTypeLabelDescription
Trade TradeRecord

Type TransactionType

TradesRequestReply

FieldTypeLabelDescription
result TradeRecord repeated

error Error

TradesRequestRequest

[Example]

{

"id": "",

"login": ""

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required]

login int32

UnsubscribeManyReply

FieldTypeLabelDescription
result string

error Error

UnsubscribeManyRequest

[Example]

{

"id": "demo-token-mt4mng"

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required] Token returned by 'Connect' method [Required]

symbol string repeated

Symbol [Required]

UnsubscribeReply

FieldTypeLabelDescription
result string

error Error

UnsubscribeRequest

[Example]

{

"id": "demo-token-mt4mng",

"symbol": "EURUSD"

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required] Token returned by 'Connect' method [Required]

symbol string

Symbol [Required]

UpdateMarginCallReply

FieldTypeLabelDescription
result MarginLevel repeated

error Error

UpdateMarginCallRequest

[Example]

{

"id": ""

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method Token returned by 'Connect' method [Required]

UpdateTradesReply

FieldTypeLabelDescription
result TradeRecordPositionUpdate

error Error

UpdateTradesRequest

[Example]

{

"id": ""

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method Token returned by 'Connect' method [Required]

UserGroupByLoginReply

FieldTypeLabelDescription
result ConGroup

error Error

UserGroupByLoginRequest

[Example]

{

"id": "demo-token-mt4mng",

"login": "0"

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required] Token returned by 'Connect' method [Required]

login int32

optional filter by login

UserGroupChangeResult

FieldTypeLabelDescription
user UserRecord

type UserChangeType

UserGroupSymbolGroupsReply

FieldTypeLabelDescription
result ConGroupSec repeated

error Error

UserGroupSymbolGroupsRequest

[Example]

{

"id": "demo-token-mt4mng",

"group": "demoforex"

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required] Token returned by 'Connect' method [Required]

group string

UserRecord

#define USER_COLOR_NONE (0xFF000000) // default user color

FieldTypeLabelDescription
Login int32

Login

Group string

Group

Password string

Password

Enable int32

Enable

EnableChangePassword int32

Allow to change password

EnableReadOnly int32

Allow to open/positions (TRUE-may not trade)

EnableOtp int32

Allow to use one-time password

EnableReserved int32 repeated

For future use

PasswordInvestor string

Read-only mode password

PasswordPhone string

Phone password

Name string

Name

Country string

Country

City string

City

State string

State

Zipcode string

Zipcode

Address string

Address

LeadSource string

Lead source

Phone string

Phone

Email string

Email

Comment string

Comment

Id string

SSN (IRD)

Status string

Status

Regdate google.protobuf.Timestamp

Registration date

Lastdate google.protobuf.Timestamp

Last coonection time

Leverage int32

Leverage

AgentAccount int32

Agent account

Timestamp google.protobuf.Timestamp

Timestamp

LastIp int32

Last visit ip

Balance double

Balance

Prevmonthbalance double

Previous month balance

Prevbalance double

Previous day balance

Credit double

Credit

Interestrate double

Accumulated interest rate

Taxes double

Taxes

Prevmonthequity double

Previous month equity

Prevequity double

Previous day equity

Reserved2 double repeated

For future use

OtpSecret string

One-time password secret

SecureReserved string

Secure data reserved

SendReports int32

Enable send reports by email

Mqid uint32

MQ client identificator

UserColor int32

Color got to client (used by MT Manager)

Unused string

For future use

ApiData string

For API usage

UserRecordRequestReply

FieldTypeLabelDescription
result UserRecord

error Error

UserRecordRequestRequest

[Example]

{

"id": "",

"login": ""

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required]

login int32

UserRecordsRequestReply

FieldTypeLabelDescription
result UserRecord repeated

error Error

UserRecordsRequestRequest

[Example]

{

"id": "",

"tickets": ""

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required]

tickets int32 repeated

UserUpdate

FieldTypeLabelDescription
User UserRecord

Type TransactionType

UsersRequestReply

FieldTypeLabelDescription
result UserRecord repeated

error Error

UsersRequestRequest

[Example]

{

"id": ""

}

FieldTypeLabelDescription
id string

Token returned by 'Connect' method [Required]

Dc

trade request status

NameNumberDescription
Dc_Empty 0

Dc_Request 1

Dc_Locked 2

Dc_Answered 3

Dc_Reseted 4

Dc_Canceled 5

ErrorCode

NameNumberDescription
INTERNAL_ERROR 0

COMMON_ERROR 2

INVALID_PARAM 3

SERVER_BUSY 4

OLD_VERSION 5

NO_CONNECT 6

NOT_ENOUGH_RIGHTS 7

TOO_FREQUENT_REQUEST 8

NO_CONNECTION 10

SERVICE_NOT_AVAILABLE 11

TOO_FREQUENT_REQUESTS 12

SECRET_KEY_REQUIRED 13

INVALID_ONETIME_PASSWORD 14

ACCOUNT_DISABLED 64

INVALID_ACCOUNT 65

PUBLIC_KEY_NOT_FOUND 66

TRADE_TIMEOUT 128

INVALID_PRICES 129

INVALID_SL_TP 130

INVALID_VOLUME 131

MARKET_CLOSED 132

TRADE_DISABLED 133

NOT_MONEY 134

PRICE_CHANGED 135

OFF_QUOTES 136

BROKER_BUSY 137

REQUOTE 138

ORDER_LOCKED 139

LONG_POS_ALLOWED 140

TOO_MANY_REQUESTS 141

ORDER_ACCEPTED 142

ORDER_IN_PROCESS 143

REQUEST_CANCELLED 144

MODIFICATIONS_DENIED 145

TRADE_CONTEXT_BUSY 146

EXPIRATION_DISABLED 147

TOO_MANY_ORDERS 148

HEDGE_PROHIBITED 149

RPROHIBITED_FIFO 150

MarginLevelType

NameNumberDescription
MarginLevelType_OK 0

MarginLevelType_MarginCall 1

MarginLevelType_Stopout 2

Op

trade commands

NameNumberDescription
Op_Buy 0

Op_Sell 1

Op_BuyLimit 2

Op_SellLimit 3

Op_BuyStop 4

Op_SellStop 5

Op_Balance 6

Op_Credit 7

TransactionType

Transaction types

NameNumberDescription
TransactionType_Add 0

TransactionType_Delete 1

TransactionType_Update 2

TransactionType_ChangeGRP 3

TtPrices

trade transaction types

NameNumberDescription
TtPrices_Get 0

Prices requets

TtPrices_Requote 1

Requote

TtPrices_TtOrderIeOpen 64

Open order (Instant Execution)

TtPrices_TtOrderReqOpen 65

Open order (Request Execution)

TtPrices_TtOrderMkOpen 66

Open order (Market Execution)

TtPrices_TtOrderPendingOpen 67

Open pending order

TtPrices_TtOrderIeClose 68

Close order (Instant Execution)

TtPrices_TtOrderReqClose 69

Close order (Request Execution)

TtPrices_TtOrderMkClose 70

Close order (Market Execution)

TtPrices_TtOrderModify 71

Modify pending order

TtPrices_TtOrderDelete 72

Delete pending order

TtPrices_TtOrderCloseBy 73

Close order by order

TtPrices_TtOrderCloseAll 74

Close all orders by symbol

TtPrices_TtBrOrderOpen 75

Open order

TtPrices_TtBrOrderClose 76

Close order

TtPrices_TtBrOrderDelete 77

Delete order (ANY OPEN ORDER!!!)

TtPrices_TtBrOrderCloseBy 78

Close order by order

TtPrices_TtBrOrderCloseAll 79

Close all orders by symbol

TtPrices_TtBrOrderModify 80

Modify open price, stoploss, takeprofit etc. of order

TtPrices_TtBrOrderActivate 81

Activate pending order

TtPrices_TtBrOrderComment 82

Modify comment of order

TtPrices_TtBrBalance 83

Balance/credit

UserChangeType

NameNumberDescription
UserChangeType_Group 0

Group

UserChangeType_Password 1

Password

UserChangeType_Enable 2

Enable

UserChangeType_EnableChangePassword 3

Allow to change password

UserChangeType_EnableReadOnly 4

Allow to open/positions (TRUE-may not trade)

UserChangeType_EnableOtp 5

Allow to use one-time password

UserChangeType_PasswordInvestor 6

Read-only mode password

UserChangeType_PasswordPhone 7

Phone password

UserChangeType_Name 8

Name

UserChangeType_Country 9

Country

UserChangeType_City 10

City

UserChangeType_State 11

State

UserChangeType_Zipcode 12

Zipcode

UserChangeType_Address 13

Address

UserChangeType_LeadSource 14

Lead source

UserChangeType_Phone 15

Phone

UserChangeType_Email 16

Email

UserChangeType_Comment 17

Comment

UserChangeType_Id 18

SSN (IRD)

UserChangeType_Status 19

Status

UserChangeType_Regdate 20

Registration date

UserChangeType_Lastdate 21

Last coonection time

UserChangeType_Leverage 22

Leverage

UserChangeType_AgentAccount 23

Agent account

UserChangeType_LastIp 24

Last visit ip

UserChangeType_Balance 25

Balance

UserChangeType_Prevmonthbalance 26

Previous month balance

UserChangeType_Prevbalance 27

Previous day balance

UserChangeType_Credit 28

Credit

UserChangeType_Interestrate 29

Accumulated interest rate

UserChangeType_Taxes 30

Taxes

UserChangeType_Prevmonthequity 31

Previous month equity

UserChangeType_Prevequity 32

Previous day equity

UserChangeType_OtpSecret 33

One-time password secret

UserChangeType_SecureReserved 34

Secure data reserved

UserChangeType_SendReports 35

Enable send reports by email

UserChangeType_Mqid 36

MQ client identificator

UserChangeType_UserColor 37

Color got to client (used by MT Manager)

UserChangeType_UserAdd 38

Add new user

MainController

Method NameRequest TypeResponse TypeDescription
SubscribeTickValue SubscribeTickValueRequest SubscribeTickValueReply

Subscribe symbol for tick value updates <br> [Example] <br> { <br> "id": "demo-token-mt4", <br> "symbol": "EURUSD", <br> "currency": "USD", <br> "interval": "0" <br> }

GetJournal GetJournalRequest GetJournalReply

Server Log journal <br> [Example] <br> { <br> "id": "", <br> "mode": "0" <br> }

ChangePassword ChangePasswordRequest ChangePasswordReply

Change user password <br> [Example] <br> { <br> "id": "", <br> "login": "", <br> "password": "", <br> "isInvestor": "False" <br> }

Health HealthRequest HealthReply

Connection Check <br> [Example] <br> { <br> "id": "" <br> }

Ping PingRequest PingReply

Simple test without parameters

UserGroupByLogin UserGroupByLoginRequest UserGroupByLoginReply

User group by login <br> [Example] <br> { <br> "id": "demo-token-mt4mng", <br> "login": "0" <br> }

SymbolsByUserGroup SymbolsByUserGroupRequest SymbolsByUserGroupReply

Get symbols avaliable for user group <br> [Example] <br> { <br> "id": "demo-token-mt4mng", <br> "group": "demoforex" <br> }

UserGroupSymbolGroups UserGroupSymbolGroupsRequest UserGroupSymbolGroupsReply

Get symbol groups avaliable for user group <br> [Example] <br> { <br> "id": "demo-token-mt4mng", <br> "group": "demoforex" <br> }

AccountsSummary AccountsSummaryRequest AccountsSummaryReply

Accounts Balance, Equity,Profit <br> [Example] <br> { <br> "id": "demo-token-mt4mng", <br> "login": "0" <br> }

Connect ConnectRequest ConnectReply

Connect to account with user, password, host, port. <br> [Example] <br> { <br> "user": "", <br> "password": "", <br> "server": "" <br> }

OrderSend OrderSendRequest OrderSendReply

Send market or pending order <br> [Example] <br> { <br> "id": "", <br> "login": "", <br> "symbol": "", <br> "operation": "", <br> "lots": "", <br> "price": "0", <br> "slippage": "0", <br> "stoploss": "0", <br> "takeprofit": "0" <br> }

OrderClose OrderCloseRequest OrderCloseReply

Close market or pending order <br> [Example] <br> { <br> "id": "", <br> "ticket": "", <br> "lots": "0", <br> "price": "0", <br> "slippage": "0" <br> }

Deposit DepositRequest DepositReply

Deposit/withdraw <br> [Example] <br> { <br> "id": "", <br> "login": "", <br> "amount": "", <br> "comment": "", <br> "credit": "False" <br> }

AccountDetails AccountDetailsRequest AccountDetailsReply

Details of specified account <br> [Example] <br> { <br> "id": "", <br> "login": "" <br> }

AccountDelete AccountDeleteRequest AccountDeleteReply

Delete account <br> [Example] <br> { <br> "id": "", <br> "login": "" <br> }

AccountDetailsMany AccountDetailsManyRequest AccountDetailsManyReply

Details for several accounts, returns all accounts if 'login' parameters not specified <br> [Example] <br> { <br> "id": "", <br> "logins": "" <br> }

AccountsList AccountsRequest AccountsReply

Accounts Balance, Equity,Profit <br> [Example] <br> { <br> "id": "" <br> }

OpenedOrders OpenedOrdersRequest OpenedOrdersReply

Opened orders <br> [Example] <br> { <br> "id": "" <br> }

OrderHistory OrderHistoryRequest OrderHistoryReply

Order history <br> [Example] <br> { <br> "id": "", <br> "login": "" <br> }

OrderHistoryEx OrderHistoryExRequest OrderHistoryExReply

Order history <br> [Example] <br> { <br> "id": "", <br> "login": "", <br> "from": "1970-01-01T00:00:00", <br> "to": "2030-01-01T00:00:00" <br> }

AccountCreate AccountCreateRequest AccountCreateReply

Create account <br> [Example] <br> { <br> "id": "", <br> "name": "", <br> "group": "", <br> "login": "", <br> "password": "", <br> "enable": "", <br> "enableChangePassword": "", <br> "enableReadOnly": "", <br> "passwordInvestor": "", <br> "passwordPhone": "", <br> "country": "", <br> "city": "", <br> "state": "", <br> "zipcode": "", <br> "address": "", <br> "leadSource": "", <br> "phone": "", <br> "email": "", <br> "comment": "", <br> "leverage": "", <br> "agentAccount": "", <br> "credit": "", <br> "userColor": "", <br> "enableOtp": "False" <br> }

AccountUpdate AccountUpdateRequest AccountUpdateReply

Change user settings <br> [Example] <br> { <br> "id": "", <br> "login": "", <br> "group": "", <br> "name": "", <br> "password": "", <br> "enable": "", <br> "enableChangePassword": "", <br> "enableReadOnly": "", <br> "passwordInvestor": "", <br> "passwordPhone": "", <br> "country": "", <br> "city": "", <br> "state": "", <br> "zipcode": "", <br> "address": "", <br> "leadSource": "", <br> "phone": "", <br> "email": "", <br> "comment": "", <br> "leverage": "", <br> "balance": "", <br> "agentAccount": "", <br> "credit": "", <br> "userColor": "", <br> "enableOtp": "False" <br> }

GetClients GetClientsRequest GetClientsReply

Return all active clients

TradesRequest TradesRequestRequest TradesRequestReply

DealerRequestGet DealerRequestGetRequest DealerRequestGetReply

TradeRecordRequest TradeRecordRequestRequest TradeRecordRequestReply

UserRecordRequest UserRecordRequestRequest UserRecordRequestReply

CfgRequestGatewayAccount CfgRequestGatewayAccountRequest CfgRequestGatewayAccountReply

CfgRequestGatewayMarkup CfgRequestGatewayMarkupRequest CfgRequestGatewayMarkupReply

CfgRequestGatewayRule CfgRequestGatewayRuleRequest CfgRequestGatewayRuleReply

GroupsRequest GroupsRequestRequest GroupsRequestReply

SymbolGroups SymbolGroupsRequest SymbolGroupsReply

UsersRequest UsersRequestRequest UsersRequestReply

UserRecordsRequest UserRecordsRequestRequest UserRecordsRequestReply

OnlineRequest OnlineRequestRequest OnlineRequestReply

TradeRecordsRequest TradeRecordsRequestRequest TradeRecordsRequestReply

ReportsRequest ReportsRequestRequest ReportsRequestReply

DailyReportsRequest DailyReportsRequestRequest DailyReportsRequestReply

RequestsGet RequestsGetRequest RequestsGetReply

RequestInfoGet RequestInfoGetRequest RequestInfoGetReply

MarginLevelRequest MarginLevelRequestRequest MarginLevelRequestReply

ChartRequest ChartRequestRequest ChartRequestReply

TicksRequest TicksRequestRequest TicksRequestReply

CfgRequestCommon CfgRequestCommonRequest CfgRequestCommonReply

CfgRequestTime CfgRequestTimeRequest CfgRequestTimeReply

CfgRequestBackup CfgRequestBackupRequest CfgRequestBackupReply

CfgRequestSymbolGroup CfgRequestSymbolGroupRequest CfgRequestSymbolGroupReply

CfgRequestAccess CfgRequestAccessRequest CfgRequestAccessReply

CfgRequestDataServer CfgRequestDataServerRequest CfgRequestDataServerReply

CfgRequestHoliday CfgRequestHolidayRequest CfgRequestHolidayReply

CfgRequestSymbol CfgRequestSymbolRequest CfgRequestSymbolReply

CfgRequestGroup CfgRequestGroupRequest CfgRequestGroupReply

CfgRequestManager CfgRequestManagerRequest CfgRequestManagerReply

CfgRequestFeeder CfgRequestFeederRequest CfgRequestFeederReply

CfgRequestLiveUpdate CfgRequestLiveUpdateRequest CfgRequestLiveUpdateReply

CfgRequestSync CfgRequestSyncRequest CfgRequestSyncReply

CfgRequestPlugin CfgRequestPluginRequest CfgRequestPluginReply

CfgUpdateSymbolGroup CfgUpdateSymbolGroupRequest CfgUpdateSymbolGroupReply

CfgUpdateGroup CfgUpdateGroupRequest CfgUpdateGroupReply

ChartRequestObsolete ChartRequestObsoleteRequest ChartRequestObsoleteReply

PerformanceRequest PerformanceRequestRequest PerformanceRequestReply

AdmUsersRequest AdmUsersRequestRequest AdmUsersRequestReply

SubscribeOrderProfit SubscribeOrderProfitRequest SubscribeOrderProfitReply

Subscribe for order profit updates and get results via /events socket connection <br> [Example] <br> { <br> "id": "demo-token-mt4mng" <br> }

Subscribe SubscribeRequest SubscribeReply

Subscribe for order profit updates and get results via /events socket connection <br> [Example] <br> { <br> "id": "demo-token-mt4mng", <br> "symbol": "EURUSD" <br> }

Unsubscribe UnsubscribeRequest UnsubscribeReply

Unsubscribe symbol for real time quotes and get results via /events or /OnQuote websocket <br> [Example] <br> { <br> "id": "demo-token-mt4mng", <br> "symbol": "EURUSD" <br> }

SubscribeMany SubscribeManyRequest SubscribeManyReply

Subscribe several symbols for real time quotes and get results via /events or /OnQuote websocket <br> [Example] <br> { <br> "id": "demo-token-mt4mng" <br> }

UnsubscribeMany UnsubscribeManyRequest UnsubscribeManyReply

Unsubscribe several symbols for real time quotes and get results via /events or /OnQuote websocket <br> [Example] <br> { <br> "id": "demo-token-mt4mng" <br> }

Streams

Method NameRequest TypeResponse TypeDescription
UpdateMarginCall UpdateMarginCallRequest UpdateMarginCallReply stream

Margin call events. <br> [Example] <br> { <br> "id": "" <br> }

OnQuote OnQuoteRequest OnQuoteReply stream

New quote events. <br> [Example] <br> { <br> "id": "" <br> }

UpdateTrades UpdateTradesRequest UpdateTradesReply stream

Trade events. <br> [Example] <br> { <br> "id": "" <br> }

OnUserChange OnUserChangeRequest OnUserChangeReply stream

User group change. <br> [Example] <br> { <br> "id": "" <br> }

OrderProfit OrderProfitRequest OrderProfitReply stream

Orders profits updates. <br> [Example] <br> { <br> "id": "demo-token-mt4mng" <br> }

OnTickValue OnTickValueRequest OnTickValueReply stream

Real time quotes. <br> [Example] <br> { <br> "id": "demo-token-mt4" <br> }

OnUpdateGroups OnUpdateGroupsRequest OnUpdateGroupsReply stream

Update groups. <br> [Example] <br> { <br> "id": "" <br> }

OnUpdateRequests OnUpdateRequestsRequest OnUpdateRequestsReply stream

Update requests. <br> [Example] <br> { <br> "id": "" <br> }

OnUpdateSymbols OnUpdateSymbolsRequest OnUpdateSymbolsReply stream

Update symbols. <br> [Example] <br> { <br> "id": "" <br> }

OnUpdateUsers OnUpdateUsersRequest OnUpdateUsersReply stream

Update symbols. <br> [Example] <br> { <br> "id": "" <br> }

OnUpdateTradesSlim OnUpdateTradesSlimRequest OnUpdateTradesSlimReply stream

Update trades. <br> [Example] <br> { <br> "id": "" <br> }

Scalar Value Types

.proto TypeNotesC++JavaPythonGoC#PHPRuby
double double double float float64 double float Float
float float float float float32 float float Float
int32 Uses variable-length encoding. Inefficient for encoding negative numbers – if your field is likely to have negative values, use sint32 instead. int32 int int int32 int integer Bignum or Fixnum (as required)
int64 Uses variable-length encoding. Inefficient for encoding negative numbers – if your field is likely to have negative values, use sint64 instead. int64 long int/long int64 long integer/string Bignum
uint32 Uses variable-length encoding. uint32 int int/long uint32 uint integer Bignum or Fixnum (as required)
uint64 Uses variable-length encoding. uint64 long int/long uint64 ulong integer/string Bignum or Fixnum (as required)
sint32 Uses variable-length encoding. Signed int value. These more efficiently encode negative numbers than regular int32s. int32 int int int32 int integer Bignum or Fixnum (as required)
sint64 Uses variable-length encoding. Signed int value. These more efficiently encode negative numbers than regular int64s. int64 long int/long int64 long integer/string Bignum
fixed32 Always four bytes. More efficient than uint32 if values are often greater than 2^28. uint32 int int uint32 uint integer Bignum or Fixnum (as required)
fixed64 Always eight bytes. More efficient than uint64 if values are often greater than 2^56. uint64 long int/long uint64 ulong integer/string Bignum
sfixed32 Always four bytes. int32 int int int32 int integer Bignum or Fixnum (as required)
sfixed64 Always eight bytes. int64 long int/long int64 long integer/string Bignum
bool bool boolean boolean bool bool boolean TrueClass/FalseClass
string A string must always contain UTF-8 encoded or 7-bit ASCII text. string String str/unicode string string string String (UTF-8)
bytes May contain any arbitrary sequence of bytes. string ByteString str []byte ByteString string String (ASCII-8BIT)