marketOrder: Place market order

Description Usage Arguments Details Value Note Author(s) See Also Examples

View source: R/marketOrder.R

Description

this function will place your order in to account.

Usage

1
marketOrder(token = "", live = FALSE, figi = "", direction = NULL, lots = NULL)

Arguments

token

token from Tinkoff account

live

live trading - TRUE or sandbox (paper) trading - FALSE (default)

figi

internal tinkoff code for instrument

direction

"Buy" or "Sell"

lots

number of lots to buy

Details

As described by the official Tinkoff Investments documentation. If you want live trading, use sandbox=FALSE with live token

Value

returns a list object containing the information about state of operation.

Note

Not for the faint of heart. All profits and losses related are yours and yours alone. If you don't like it, write it yourself.

Author(s)

Vyacheslav Arbuzov

See Also

limitOrder

Examples

1
2
3
4
5
6
paper_token = 'your_sandbox_token_from_tcs_account'
marketOrder(paper_token,figi='BBG005HLTYH9',direction='Buy',lots=1)

live_token = 'your_live_token_from_tcs_account'
# remember that this command will place limit order in your live account !
marketOrder(live_token,live=TRUE,figi='BBG005HLTYH9',direction='Buy',lots=1)

tcsinvest documentation built on Aug. 17, 2021, 9:08 a.m.