Reg. Address: #1108, Sector 21-B, Chandigarh – 160022
Head Office: Finvasia Tower, C-214, 4th Floor, Phase 8B, Sector 74, Industrial Focal Point, SAS Nagar (Mohali), Punjab – 160055
Corporate Office: Finvasia Securities Private Limited, 23rd Floor, Sunshine Tower, Plot No. 616, Senapati Bapat Marg, Dadar West, Parel, Mumbai, Maharashtra – 400013, India
NSE Clearing Member: M51912, NSE Member Code: 14846, BSE Member Code: 4043, MCX Member ID: 55135.
SEBI Reg: INZ000176037 (Cash, F&O, CDS, Commodity), AMFI ARN: 103331, CDSL DP ID: 12084300, SEBI Regn : IN-DP-317-2017
Research Analyst SEBI Regn. No. INH000011927
Smart Online Dispute Resolution | Grievances Redressal Mechanism
Overview
The .NET SDK is a wrapper of the Noren API combining REST calls and WebSocket streaming for trading. It targets .NET Standard 2.0, built on Visual Studio 2019, with a dependency on Newtonsoft.Json 9.0.1. The namespace is
NorenRestApiWrapper; the primary class isNorenRestApi.public delegate void OnResponse(NorenResponseMsg Response, bool ok)— rather than returning aTask. Structure your calling code around callbacks, notawait, when integrating this SDK.Installation
NorenRestApiWrapperNorenRestApiClone the repository and reference the project directly, or pull the compiled dependency from the
Depsfolder — there's no NuGet package as of this writing. Example projects are included:Example1,Example2_InlineHandler,Example3_Websocket, andExample4_oauthfor the OAuth flow specifically.Initialization
endPointAppkeyCreate an instance of
NorenRestApito make requests. Every request method takes anOnResponsecallback delegate as its first argument.OAuth & Session Methods
SendgetOAuthURL(oauth_url, client_id)auth_code.SendgetAccessToken(response, endPoint, authCode, secretcode, client_id, uid)auth_codefor an access token via theOnResponsecallback, returning aGetAccessTokenResponsewithaccess_token,susertoken,refresh_token, andactid.SendGetUserDetails(response)SendLogout(response)SetSession(endpoint, uid, pwd, usertoken)Available Functionality
SendGetMWList,SendGetMarketWatch,SendAddMultiScripsToMW,SendDeleteMultiMWScripsSendSearchScrip,SendGetSecurityInfo,GetQuote, time/daily price series,GetOptionChain,GetIndexList,ExchMsg, top-list methodsspan_calculator,get_option_greek,GetBrokerageSendPlaceOrder,SendModifyOrder,SendCancelOrder,SendExitSNOOrder,SendProductConversion,SendGetOrderMargin,SendGetOrderBook,SendGetTradeBook,SendGetOrderHistory,SendGetMultiLegOrderBook,SendGetPositionBook,SendGetHoldings,SendGetLimitsConnect,SubscribeMarketData,UnSubscribeMarketData,SubscribeOrderUpdateOrder types beyond a plain
LMT/SL-LMTbuy/sell are supported here —PlaceOrdercovers Cover Orders (prd = H) and Bracket Orders (prd = B) withblprc/bpprc/trailprcfields, unlike the REST Place Order endpoint documented elsewhere on this site, which rejectsCO/BO. Confirm which product types your account is enabled for before relying on this.Quick Start Example
Best Practices
OnResponse) from the start — retrofitting async/await over a callback-based SDK later is more work than structuring for it up front.NorenResponseMsgin your callback to the specific response type documented for that call (e.g.GetAccessTokenResponse,PlaceOrderResponse) and checkstat == "Ok"before reading any other field.prd = H/B) are supported here but not on the plain REST Place Order endpoint — don't assume feature parity between this SDK and the raw HTTP API when porting code between platforms.Example4_oauthproject in the repository for a complete working OAuth handshake — it's the fastest way to confirm yourendPointandAppkeyare configured correctly before writing your own integration.