AB1018 : Failed to get symbol details


  • Please find below request and Responses. I loaded instruments couple of seconds back.. Still it showing weird responses.

    Error
    {"status":false,"message":"Failed to get symbol details","errorcode":"AB1018","data":null}

    Request
    {"orderid":null,"variety":"NORMAL","tradingsymbol":"NIFTY03NOV2118250CE","symboltoken":"43477","transactiontype":"SELL","exchange":"NSE","ordertype":"MARKET","producttype":"DELIVERY","duration":"DAY","price":null,"squareoff":"0","stoploss":"0","quantity":"50","triggerprice":"0"}

    Help me where it went wrong.


  • @admin

    Is that update sdk is taking new build from git? if yes, i did same, but still problem exisit.

            SmartApi connect = new SmartApi(api_key, JWTToken, RefreshToken);
    
            OutputBaseClass obj = new OutputBaseClass();
    
            //Login by client code and password
            obj = connect.GenerateSession(Client_code, Password);
            AngelToken agr = obj.TokenResponse;
    
            Console.WriteLine("------GenerateSession call output-------------");
            Console.WriteLine(JsonConvert.SerializeObject(agr));
            Console.WriteLine("----------------------------------------------");
    
            //Get Token
            obj = connect.GenerateToken();
            agr = obj.TokenResponse;
    
            Console.WriteLine("------GenerateToken call output-------------");
            Console.WriteLine(JsonConvert.SerializeObject(agr));
            Console.WriteLine("----------------------------------------------");
    
            //Get Profile
            obj = connect.GetProfile();
            GetProfileResponse gp = obj.GetProfileResponse;
    
            Console.WriteLine("------GetProfile call output-------------");
            Console.WriteLine(JsonConvert.SerializeObject(gp));
            Console.WriteLine("----------------------------------------------");
    
            OrderInfo ord = new OrderInfo();
            ord.variety = AngelBroking.Constants.VARIETY_NORMAL;
            ord.tradingsymbol = "NIFTY11NOV2118100CE";
            ord.symboltoken = "50055";
    
            ord.transactiontype = AngelBroking.Constants.TRANSACTION_TYPE_BUY;
    
            ord.exchange = AngelBroking.Constants.EXCHANGE_NFO;
            ord.ordertype = AngelBroking.Constants.ORDER_TYPE_MARKET;
            ord.producttype = AngelBroking.Constants.PRODUCT_TYPE_CARRYFORWARD;
            ord.duration = AngelBroking.Constants.VALIDITY_DAY.ToString();
            ord.quantity = 50.ToString();
    
            obj = connect.placeOrder(ord);
            OrderResponse Ores = obj.PlaceOrderResponse;
            //LogOut
            obj = connect.LogOut(Client_code);
            LogOutResponse lg = obj.LogOutResponse;
    
            Console.WriteLine("------LogOut call output-------------");
            Console.WriteLine(JsonConvert.SerializeObject(lg));
            Console.WriteLine("----------------------------------------------");
    

    I am gettiung below response.
    {"status":false,"message":"Internal Error","errorcode":"AB2001","data":null}

    Please clarify me, as i am spending decernt time to build algos using Angel, but you API or WebSocket not upto the level of my expectation, i am not sure, whether as i doing wrong or, it your API fault.


  • HI @divakar620 this has been resolved kindly update the .net sdk.


  • @admin .. Could you please clarify ?


  • @admin

    I am usign .Net. here is my Code: i don't see any wrong while comparing it with your reference..

           //Place Order
            OrderInfo ord = new OrderInfo();
            ord.variety = AngelBroking.Constants.VARIETY_NORMAL;
            ord.tradingsymbol ="NIFTY03NOV2118250CE"
            ord.symboltoken = "43477";
            ord.transactiontype = AngelBroking.Constants.TRANSACTION_TYPE_SELL;
            ord.exchange = AngelBroking.Constants.EXCHANGE_NFO;
            ord.ordertype = AngelBroking.Constants.ORDER_TYPE_MARKET;
            ord.producttype = AngelBroking.Constants.PRODUCT_TYPE_CARRYFORWARD;
            ord.duration = AngelBroking.Constants.VALIDITY_DAY.ToString();
            ord.quantity = quantity.ToString();
            obj = connect.placeOrder(ord);
            OrderResponse Ores = obj.PlaceOrderResponse;
    

    Help me to find my problem..
    Question 2
    Also, I have 2nd Question as to hold WebSocket message, do we have any model from MessageEventArgs ?

    static void WriteResult(object sender, MessageEventArgs e)
    {

            dynamic d = JsonConvert.DeserializeObject<dynamic>(e.Message);
            Console.WriteLine("Tick Received : " + e.Message);
        }


  • @admin
    Now Getting Different Error
    Corrected Request
    {"orderid":null,"variety":"NORMAL","tradingsymbol":"NIFTY03NOV2117950PE","symboltoken":"43341","transactiontype":"SELL","exchange":"NFO","ordertype":"MARKET","producttype":"CARRYFORWARD","duration":"DAY","price":null,"squareoff":"0","stoploss":"0","quantity":"50","triggerprice":"0"}

    New Error:
    {"status":false,"message":"Internal Error","errorcode":"AB2001","data":null}


  • Now Getting Different Error
    Corrected Request
    {"orderid":null,"variety":"NORMAL","tradingsymbol":"NIFTY03NOV2117950PE","symboltoken":"43341","transactiontype":"SELL","exchange":"NFO","ordertype":"MARKET","producttype":"CARRYFORWARD","duration":"DAY","price":null,"squareoff":"0","stoploss":"0","quantity":"50","triggerprice":"0"}

    New Error:
    {"status":false,"message":"Internal Error","errorcode":"AB2001","data":null}


  • HI @divakar620 Pass exchange as NFO.