Show / Hide Table of Contents

Class LimitOrder

A limit order is an order to buy or sell at a specified price or better.

Inheritance
System.Object
OrderBase
SimpleOrderBase
LimitOrder
Inherited Members
SimpleOrderBase.TakeProfit(Decimal)
SimpleOrderBase.StopLoss(Decimal)
SimpleOrderBase.StopLoss(Decimal, Decimal)
SimpleOrderBase.Bracket(Decimal, Decimal)
SimpleOrderBase.Bracket(Decimal, Decimal, Decimal)
OrderBase.Symbol
OrderBase.Quantity
OrderBase.Side
OrderBase.Type
OrderBase.Duration
OrderBase.ClientOrderId
OrderBase.ExtendedHours
OrderBase.PositionIntent
System.Object.Equals(System.Object)
System.Object.Equals(System.Object, System.Object)
System.Object.GetHashCode()
System.Object.GetType()
System.Object.MemberwiseClone()
System.Object.ReferenceEquals(System.Object, System.Object)
System.Object.ToString()
Namespace: Alpaca.Markets
Assembly: Alpaca.Markets.dll
Syntax
public sealed class LimitOrder : SimpleOrderBase
Remarks

See Alpaca Order Documentation for more information.

Properties

| Improve this Doc View Source

LimitPrice

Gets or sets the new order limit price.

Declaration
public Decimal LimitPrice { get; }
Property Value
Type Description
Decimal

Methods

| Improve this Doc View Source

Buy(String, OrderQuantity, Decimal)

Creates new buy market order using specified symbol and quantity.

Declaration
public static LimitOrder Buy(String symbol, OrderQuantity quantity, Decimal limitPrice)
Parameters
Type Name Description
String symbol

Order asset symbol.

Alpaca.Markets.OrderQuantity quantity

Order quantity.

Decimal limitPrice

Order limit price.

Returns
Type Description
LimitOrder

The new LimitOrder object instance.

| Improve this Doc View Source

OneCancelsOther(Decimal)

Creates a new instance of the OneCancelsOtherOrder order from the current order.

Declaration
public OneCancelsOtherOrder OneCancelsOther(Decimal stopLossStopPrice)
Parameters
Type Name Description
Decimal stopLossStopPrice

Stop loss order stop price.

Returns
Type Description
OneCancelsOtherOrder

New advanced order representing pair of original order and stop loss order.

| Improve this Doc View Source

OneCancelsOther(Decimal, Decimal)

Creates a new instance of the OneCancelsOtherOrder order from the current order.

Declaration
public OneCancelsOtherOrder OneCancelsOther(Decimal stopLossStopPrice, Decimal stopLossLimitPrice)
Parameters
Type Name Description
Decimal stopLossStopPrice

Stop loss order stop price.

Decimal stopLossLimitPrice

Stop loss order limit price.

Returns
Type Description
OneCancelsOtherOrder

New advanced order representing pair of original order and stop loss order.

| Improve this Doc View Source

Sell(String, OrderQuantity, Decimal)

Creates new sell market order using specified symbol and quantity.

Declaration
public static LimitOrder Sell(String symbol, OrderQuantity quantity, Decimal limitPrice)
Parameters
Type Name Description
String symbol

Order asset symbol.

Alpaca.Markets.OrderQuantity quantity

Order quantity.

Decimal limitPrice

Order limit price.

Returns
Type Description
LimitOrder

The new LimitOrder object instance.

Extension Methods

OrderBaseExtensions.WithDuration<TOrder>(TOrder, TimeInForce)
OrderBaseExtensions.WithClientOrderId<TOrder>(TOrder, String)
OrderBaseExtensions.WithExtendedHours<TOrder>(TOrder, Boolean)
OrderBaseExtensions.WithPositionIntent<TOrder>(TOrder, PositionIntent)
  • Improve this Doc
  • View Source
In This Article
Back to top Generated by DocFX