Rajandran R Creator of OpenAlgo - OpenSource Algo Trading framework for Indian Traders. Telecom Engineer turned Full-time Derivative Trader. Mostly Trading Nifty, Banknifty, High Liquid Stock Derivatives. Trading the Markets Since 2006 onwards. Using Market Profile and Orderflow for more than a decade. Designed and published 100+ open source trading systems on various trading tools. Strongly believe that market understanding and robust trading frameworks are the key to the trading success. Building Algo Platforms, Writing about Markets, Trading System Design, Market Sentiment, Trading Softwares & Trading Nuances since 2007 onwards. Author of Marketcalls.in

PlaceFNOOptionsOrder and PlaceMultiOrder API Launched for Angel Broking – Algomojo Users

3 min read

Two major functionalities rolled out for Angel Broking – Algomojo users to take advantage of Options Order and Basket Orders which helps the quant developers to reduce their coding effort significantly and improve their trading process.

What is PlaceFNOOptionsOrder?

PlaceFNOOptionsOrder is for sending index options orders to send ATM, ITM, OTM Options Orders in Nifty, Bank Nifty , FinNifty)

Here is the sample request and response for PlaceFOOptionsOrder

For detailed information on Algomojo API’s visit the API Documentation section

Endpoint URL : https://anapi.algomojo.com/1.0/PlaceFOOptionsOrder

Request example :

{
    "api_key":"c1997d92a3bb556a67dca7d1446b70",
    "api_secret":"5306433329e81ba41203653417063c",
    "data":
      {
        "stgy_name":"Options",
        "variety":"NORMAL",
        "spot_sym":"BANKNIFTY",
        "expiry_dt":"01JUL21",
        "opt_type":"CE",
        "transactiontype":"BUY",
        "ordertype":"MARKET",
        "quantity":"25",
        "price":"0",
        "triggerprice":"0",
        "producttype":"CARRYFORWARD",
        "strike_int":"100",
        "offset":"10"
      }
}

Response example :

{
    "status":true,
    "message":"SUCCESS",
    "errorcode":"",
    "data":
        {
         "script": "BANKNIFTY01JUL2135200CE",
         "orderid": "210618001112998"
        }
}

Option Offset Control

one can use the offset to select the ATM, ITM,OTM Options.

What is PlaceMultiOrder?

It is a basket order to fire basket orders to single account or to multiple accounts.

Sending Basket Order to Single Account

EndPoint URL : https://anapi.algomojo.com/1.0/PlaceFOOptionsOrder

one can use the following messaging format to send basket orders to the same account


{
    "api_key":"b48e4db30e47326722a388c03eb4ee26",
    "api_secret":"fc3ed44d0914b0e6466f9ff2e3ae003a",
    "data":
      {
          "orders" : 
            [
                {
                "order_refno":"1",
                "user_apikey":"b48e4db30e47326722a388c03eb4ee26",
                "api_secret":"fc3ed44d0914b0e6466f9ff2e3ae003a",
                "stgy_name": "Test Strategy",
                "variety":"NORMAL",
                "tradingsymbol":"SBIN-EQ",
                "symboltoken":"3045",
                "transactiontype":"BUY",
                "exchange":"NSE",
                "ordertype":"MARKET",
                "producttype":"DELIVERY",
                "duration":"DAY",
                "price":"0",
                "squareoff":"0",
                "stoploss":"0",
                "quantity":"1",
                "triggerprice": "0",
                "trailingStopLoss": "0",
                "disclosedquantity":"0"
                },
                {
                "order_refno":"2",
                "strg_name": "Test Strategy",
                "user_apikey":"b48e4db30e47326722a388c03eb4ee26",
                "api_secret":"fc3ed44d0914b0e6466f9ff2e3ae003a",
                "variety":"NORMAL",
                "tradingsymbol":"RELIANCE-EQ",
                "symboltoken":"2885",
                "transactiontype":"SELL",
                "exchange":"NSE",
                "ordertype":"MARKET",
                "producttype":"DELIVERY",
                "duration":"DAY",
                "price":"0",
                "squareoff":"0",
                "stoploss":"0",
                "quantity":"1",
                "triggerprice": "0",
                "trailingStopLoss": "0",
                "disclosedquantity":"0"
                }
            ]
      }
}

Response example :

[
    {
        "status": true,
        "message": "SUCCESS",
        "errorcode": "",
        "data": {
            "script": "SBIN-EQ",
            "orderid": "210428001357677"
        }
    },
    {
        "status": true,
        "message": "SUCCESS",
        "errorcode": "",
        "data": {
            "script": "RELIANCE-EQ",
            "orderid": "210428001357678"
        }
    }
]

Sending Order to Multiple Account

EndPoint URL : https://anapi.algomojo.com/1.0/PlaceFOOptionsOrder

one can use the following messaging format to send multi account orders for the same trading instruments

{
    "api_key":"b48e4db30e47326722a388c03eb4ee26",
    "api_secret":"fc3ed44d0914b0e6466f9ff2e3ae003a",
    "data":
      {
          "orders" : 
            [
                {
                "order_refno":"1",
                "user_apikey":"b48e4db30e47326722a388c03eb4ee26",
                "api_secret":"fc3ed44d0914b0e6466f9ff2e3ae003a",
                "stgy_name": "Test Strategy",
                "variety":"NORMAL",
                "tradingsymbol":"SBIN-EQ",
                "symboltoken":"3045",
                "transactiontype":"BUY",
                "exchange":"NSE",
                "ordertype":"MARKET",
                "producttype":"INTRADAY",
                "duration":"DAY",
                "price":"0",
                "squareoff":"0",
                "stoploss":"0",
                "quantity":"1",
                "triggerprice": "0",
                "trailingStopLoss": "0",
                "disclosedquantity":"0"
                },
                {
                "order_refno":"2",
                "strg_name": "Test Strategy",
                "user_apikey":"dfsdf45sdf34g555ssef567jhrt6ssv4",
                "api_secret":"59ff2544sdfhkllwer5559ff2e3ae003a",
                "variety":"NORMAL",
                "tradingsymbol":"SBIN-EQ",
                "symboltoken":"3045",
                "transactiontype":"BUY",
                "exchange":"NSE",
                "ordertype":"MARKET",
                "producttype":"INTRADAY",
                "duration":"DAY",
                "price":"0",
                "squareoff":"0",
                "stoploss":"0",
                "quantity":"1",
                "triggerprice": "0",
                "trailingStopLoss": "0",
                "disclosedquantity":"0"
                }
            ]
      }
}
Rajandran R Creator of OpenAlgo - OpenSource Algo Trading framework for Indian Traders. Telecom Engineer turned Full-time Derivative Trader. Mostly Trading Nifty, Banknifty, High Liquid Stock Derivatives. Trading the Markets Since 2006 onwards. Using Market Profile and Orderflow for more than a decade. Designed and published 100+ open source trading systems on various trading tools. Strongly believe that market understanding and robust trading frameworks are the key to the trading success. Building Algo Platforms, Writing about Markets, Trading System Design, Market Sentiment, Trading Softwares & Trading Nuances since 2007 onwards. Author of Marketcalls.in

Algomojo Platform Now Open to Finvasia (Shoonya) Users

Algomojo, a leading Algotrading platform for DIY traders, is excited to announce that it is now open to Finvasia (Shoonya) users. This partnership aims...
Rajandran R
5 min read

Algomojo Platform Now Open to 5Paisa Users

Algomojo, a leading Algotrading platform for DIY traders, is excited to announce that it is now open to 5Paisa users. This partnership aims to...
Rajandran R
5 min read

Algomojo Platform Now Open to Goodwill Commodities Users

Algomojo, a leading Algotrading platform for DIY traders, is excited to announce that it is now open to Goodwill Commodities users. This partnership aims...
Rajandran R
5 min read

Leave a Reply

Get Notifications, Alerts on Market Updates, Trading Tools, Automation & More