Bentrix Docs
HomePricingDashboard

JavaScript: the trade panel

Every method of client.trading in the JavaScript SDK.

tradePanelShow#

Show the trade panel · tool trade_panel_show

scope: labplan: plussince 1.0.0

Brings the trade panel to a market of a workbench, pinned to it when pin asks, as the chart bar's trade button, F9 and Market Watch's New order do. The panel is the person's; this shows it. Answers the panel's market.

Declaration

client.trading
tradePanelShow(args: { bench: string; symbol: string; pin?: boolean }): Promise<any>

Parameters

NameTypeWhat it is
benchstringrequiredThe workbench's uri.
symbolstringrequiredThe market the panel shows.
pinbooleanoptionalKept on this market whatever chart has the focus.

Returns

Promise<any> — the tool’s answer as a plain object.

What it answers

Answers the panel's market.

Example

await client.trading.tradePanelShow({ bench, symbol: "SYN-DOCS" })

tradeProfile#

Save, load or forget a market's trade profile · tool trade_profile

scope: labplan: plussince 1.0.0

Saves a market's risk, stop and target as its profile, loads it into the trade panel's draft, or forgets it, as the panel's profile menu does; a profile the panel would refuse is refused in its words. Answers the market's profile.

Declaration

client.trading
tradeProfile(args: { action: "save" | "load" | "forget"; symbol: string; reward_ratio?: number; risk_pct?: number; stop_points?: number }): Promise<any>

Parameters

NameTypeWhat it is
action"save" | "load" | "forget"required
symbolstringrequired
reward_rationumberoptionalWith save: the target as a multiple of the stop.
risk_pctnumberoptionalWith save: the risk in percent of the balance.
stop_pointsnumberoptionalWith save: the stop's distance in points.

Returns

Promise<any> — the tool’s answer as a plain object.

What it answers

Answers the market's profile.

Example

await client.trading.tradeProfile({ action: "…", symbol: "SYN-DOCS" })

Bentrix 0.1.382Every number, name and default on these pages is read from the application itself.What is comingWhat changed