# Connect MetaTraderAPI with Open Flow

Source: https://openflow.run/en/integrations/metatraderapi/

[All integrations](https://openflow.run/en/integrations/)

Select a trading session and ask AI to organize the account’s open positions and recent executed deals.

*   [15 actions](https://openflow.run/en/integrations/metatraderapi/#integration-actions)
*   API key
*   Finance
*   Developer tools

[Connect MetaTraderAPI](https://console.openflow.run/connections/metatraderapi)

20,000 free app calls per month (paid services billed separately)

## What you can do

The connection starts and stops MT4 or MT5 sessions and reads account data, positions, pending orders, history, and symbols. It does not place trades.

### Account and trading records

Read account information, equity, margin, positions, pending orders, and historical deals.

## All actions

15 actions

### List Sessions

List all active MetaTraderAPI sessions for the authenticated account.

`metatraderapi.list_sessions`

### Start Session

Start a MetaTraderAPI session connected to an MT4 or MT5 trading account.

`metatraderapi.start_session`

### Stop Session

Stop one active MetaTraderAPI session.

`metatraderapi.stop_session`

### Close All Sessions

Stop all active MetaTraderAPI sessions for the authenticated account.

`metatraderapi.close_all_sessions`

### Get Account Info

Get balance, equity, margin, leverage, currency, and other account information.

`metatraderapi.get_account_info`

### Get Equity

Get the current equity, balance, profit, and currency for a session.

`metatraderapi.get_equity`

### List Deals

List executed deals from the MetaTrader account history.

`metatraderapi.list_deals`

### List History Orders

List historical MetaTrader orders, including canceled and expired orders.

`metatraderapi.list_history_orders`

### Get Margin

Get the current margin and free-margin information for a session.

`metatraderapi.get_margin`

### List Orders

List pending orders for a MetaTraderAPI session.

`metatraderapi.list_orders`

### Ping Session

Ping a MetaTraderAPI session to check whether it is responsive.

`metatraderapi.ping_session`

### List Positions

List current open positions for a MetaTraderAPI session.

`metatraderapi.list_positions`

### Get Session Status

Get the activity, health, and MetaTrader connection status of a session.

`metatraderapi.get_session_status`

### List Symbols

List trading symbols available to a MetaTraderAPI session.

`metatraderapi.list_symbols`

### Get Symbol

Get current prices, spread, contract size, and volume limits for a symbol.

`metatraderapi.get_symbol`

No actions match your search.

## Connect MetaTraderAPI with Open Flow

[Connect MetaTraderAPI](https://console.openflow.run/connections/metatraderapi)

20,000 free app calls per month (paid services billed separately)
