Stocks | Lime Financial

This document outlines the appropriate format that the traders must follow while writing the webhook payload for setting up the following types of stocks orders to be executed into Lime Financial.

Let’s get started 🚀

Market Order

The traders can write the webhook payload for setting up Market orders using these three payload fields:

  • Symbol
  • Action
  • Quantity

Symbol

The ticker symbol of the stocks. Lime Financial uses single stock ticker symbols to represent individual stocks. For example, "AAPL", AMZN, and META, etc.

Action

The signal action, indicates the type of trade to be executed. It can be one of the following.

  • Buy: Triggers an action to buy the asset.
  • Sell: Triggers an action to sell the asset.
  • Buy-to-Cover: Triggers an action to buy back and close a previously sold asset (ending a short trade).
  • Sell-Short: Triggers an action to sell borrowed assets with the expectation of buying them back at a lower price.

Quantity

The number of bond contracts to be traded. If this field is omitted, the quantity will be automatically calculated or set to a default value of 1.

EXAMPLE

I. Buy

{
  "symbol": "AAPL"
  "action": "buy",
  "quantity":123
}

II. Sell

{
  "symbol": "AAPL"
  "action": "sell",
  "quantity":123
}

III. Buy-To-Cover

{
  "symbol": "AAPL",
  "action": "buy_to_cover",
  "quantity": 123
}

IV. Sell-Short

{
  "symbol": "AAPL",
  "action": "sell_short",
  "quantity": 123
}

Limit Order

The traders can write the webhook payload for setting up Limit orders using these four payload fields:

  • Symbol
  • Action
  • Quantity
  • Limit_price

Symbol

The ticker symbol of the stocks. Lime Financial uses single stock ticker symbols to represent individual stocks. For example, "AAPL", AMZN, and META, etc.

Action

The signal action, indicates the type of trade to be executed. It can be one of the following.

  • Buy: Triggers an action to buy the asset.
  • Sell: Triggers an action to sell the asset.
  • Buy-to-Cover: Triggers an action to buy back and close a previously sold asset (ending a short trade).
  • Sell-Short: Triggers an action to sell borrowed assets with the expectation of buying them back at a lower price.

Quantity

The number of bond contracts to be traded. If this field is omitted, the quantity will be automatically calculated or set to a default value of 1.

Limit_price

An optional field specifying the execution price for a “buy” or  “sell” trade. If you specify the limit price the trade will be executed at the specified limit price. Or If you choose not to specify a limit price, the trade will be executed at the current market price.

EXAMPLE

I. Buy

{
  "symbol": "AAPL"
  "action": "buy",
  "quantity":123
}

II. Sell

{
  "symbol": "AAPL"
  "action": "sell",
  "quantity":123
}

III. Buy-To-Cover

{
  "symbol": "AAPL",
  "action": "buy_to_cover",
  "quantity": 123
}

IV. Sell-Short

{
  "symbol": "AAPL",
  "action": "sell_short",
  "quantity": 123
}

Stop Order

The traders can write the webhook payload for setting up Stop orders using these four payload fields:

  • Symbol
  • Action
  • Quantity
  • Stop_price

Symbol

The ticker symbol of the stocks. Lime Financial uses single stock ticker symbols to represent individual stocks. For example, "AAPL", AMZN, and META, etc.

Action

The signal action, indicates the type of trade to be executed. It can be one of the following.

  • Buy: Triggers an action to buy the asset.
  • Sell: Triggers an action to sell the asset.
  • Buy-to-Cover: Triggers an action to buy back and close a previously sold asset (ending a short trade).
  • Sell-Short: Triggers an action to sell borrowed assets with the expectation of buying them back at a lower price.

Quantity

The number of bond contracts to be traded. If this field is omitted, the quantity will be automatically calculated or set to a default value of 1.

Stop_price

An optional field specifying the price level at which a stop-loss or stop-limit order should be triggered. It helps limit potential losses by automatically closing the position when the specified price is reached.

EXAMPLE

I. Buy

{
  "symbol": "AAPL",
  "action": "buy",
  "quantity": 123,
  "stop_price": 123.98,
}

II. Sell

{
  "symbol": "AAPL",
  "action": "sell",
  "quantity": 123,
  "stop_price": 123.98,
}

III. Buy-To-Cover

{
  "symbol": "AAPL",
  "action": "buy_to_cover",
  "quantity": 123,
  "stop_price": 123.98,
}

IV. Sell-Short

{
  "symbol": "AAPL",
  "action": "sell_short",
  "quantity": 123,
  "stop_price": 123.98,
}

Stop-Limit Order

The traders can write the webhook payload for setting up Stop-Limit orders using these five payload fields:

  • Symbol
  • Action
  • Quantity
  • Limit_price
  • Stop_price

Symbol

The ticker symbol of the stocks. Lime Financial uses single stock ticker symbols to represent individual stocks. For example, "AAPL", AMZN, and META, etc.

Action

The signal action, indicates the type of trade to be executed. It can be one of the following.

  • Buy: Triggers an action to buy the asset.
  • Sell: Triggers an action to sell the asset.
  • Buy-to-Cover: Triggers an action to buy back and close a previously sold asset (ending a short trade).
  • Sell-Short: Triggers an action to sell borrowed assets with the expectation of buying them back at a lower price.

Quantity

The number of bond contracts to be traded. If this field is omitted, the quantity will be automatically calculated or set to a default value of 1.

Limit_price

An optional field specifying the execution price for a “buy” or  “sell” trade. If you specify the limit price the trade will be executed at the specified limit price. Or If you choose not to specify a limit price, the trade will be executed at the current market price.

Stop_price

An optional field specifying the price level at which a stop-loss or stop-limit order should be triggered. It helps limit potential losses by automatically closing the position when the specified price is reached.

EXAMPLE

I. Buy

{
  "symbol": "AAPL",
  "action": "buy",
  "quantity": 123,
  "limit_price": 123.98,
  "stop_price": 123.98
}

II. Sell

{
  "symbol": "AAPL",
  "action": "sell",
  "quantity": 123,
  "limit_price": 123.98,
  "stop_price": 123.98
}

III. Buy-To-Cover

{
  "symbol": "AAPL",
  "action": "buy_to_cover",
  "quantity": 123,
  "limit_price": 123.98,
  "stop_price": 123.98
}

IV. Sell-Short

{
  "symbol": "AAPL",
  "action": "sell_short",
  "quantity": 123,
  "limit_price": 123.98,
  "stop_price": 123.98
}




Sep 29, 2023

Contact Us

Not finding what you're looking for? Contact Us Directly