Interface LimitProps<T>

Used Alpaca limit order

interface LimitProps<T> {
    limitPrice: T;
    limitPriceMax?: T;
    limitPriceMin?: T;
    position: T;
    priceType?: PositionHandlerPriceType;
    triggerPrice?: T;
    triggerPriceType?: PositionHandlerPriceType;
    type: limit;
}

Type Parameters

Properties

limitPrice: T

Price for order. If triggerPriceType='custom' then dollars else percentage

limitPriceMax?: T

Maximum value for limitPrice prop. If limitPrice greater than limitPriceMax, then limitPrice value will be replaced on the limitPriceMax

limitPriceMin?: T

Minimum value for limitPrice prop. If limitPrice less than limitPriceMin, then limitPrice value will be replaced on the limitPriceMin

position: T

Percentage of position to use.

Which price to use for calculation.

profit: 'boughtAverage', loss: 'positionAverage'

triggerPrice?: T

Which price activates the rule.

auto calculated.
triggerPriceType?: PositionHandlerPriceType

which price to use for calculation.

profit: 'boughtAverage', loss: 'positionAverage'

type: limit

Type of strategy