Skip to main content

📊 Scrip Basket Margin Template

Scrip Basket Template is used to define the set of scrip along with applicable margin for respective product type which will be mapped to entity for margin calculation and trading. Scrip Basket Functionality to be used to define two major features. One is to define the allowed scrip for specific product and another is to define the preferred margin %.

One or more Scrip Basket Template can be mapped to entity.

⚙️ Template Creation

Scrip Basket Template should be created with the combination of Market Segment, Instrument, Symbol, Series, Contract type, Expiry Date, Strike Price, Option Type, ITM %, OTM %, Product.

Template created here should be allowed to Map in Template Mapping view for entity and users.

Either one or multiple scrip basket template is allowed to map to the user\entity in template mapping window.

System should allow to place the orders only in the scrips which is available in the scrip basket template which is mapped to the user\entity and system should compute the margin as per the margin percentage defined for the scrips in the mapped scrip basket template.

System should have a following set of fields to create, view and fetch Scrip Basket Template.

🔧 Template Controls

📝 Control Name⚙️ Business Logic
Template Name- Control Type: Entry Field + Drop-Down list
- Should allow to enter the Template Name with Alpha Numeric and allowable Special Characters
- Template Name should not be more than length mentioned in API
- Duplicate template name creation should not be allowed
- Should display the list of Template Name on search of Key Name
- System should allow to add\remove\update the scrips under the created template.
- System should fetch and display the available records in the "Scrip Basket Records" gird view as per the template name selected in this field and as per the list of combinations selected in the filter.
- System should allow to create multiple scrip basket template with different template name. Template name should be unique.
- Templates created here should be displayed in the "Template Mapping View" to map with entity \user.
Save- Control Type: Button
- On click of SAVE button, scrip basket rules added for the Template should get saved into the system.
- Popup message should be displayed while on click of SAVE button without entering the template name.
- Popup String should be like "Template Name should not be blank'
- On click of SAVE button, system should validate following conditions: Minimum one scrip basket record should be available while saving the template.
Save As- Control Type: Button
- "SAVE AS" option is used to create the copy of existing template with new template name with a small modification in the records available in the existing template (or) without any modification.
- "Save As" option should get enable while after selecting the template Name in the "product template" dropdown list.
- On Click of "Save As" button- system should popup a child Window with label as: "Product Template" and an entry field to enter the 'New template Name' with "OK" and "CANCEL" options.
- If "OK" is selected, then new template should get saved into the system with all scrip basket rules else if "CANCEL" is selected then Child window should get closed without saving the record.
- System should validate the New template name with the existing templates available, if same name is entered, then system should popup an alert message as "Template Name Already Exists".

📦 Scrip Basket Rule Combination Selections

System should have following drop-down options to set applicable margin at scrip level

🔧 Control Name📝 Business Logic
Market Segment- Control Type: Drop-Down list
- Should display the list of Market Segment available in the system based on the license.
- If license is update with New Segment, same should display here in the Dropdown list.
- "All Equity" option should be available in the dropdown list – "All Equity" refers to clubbing of All Equity Market Segment available in the system
- "All FNO" option should be available in the dropdown list – "All FNO" refers to clubbing of All Derivative Market Segment available in the system
- "All CDS" option should be available in the dropdown list – "All CDS" refers to clubbing of All Currency Market Segments available in the system
- "All COM" option should be available in the Dropdown list – "All COM" refers to clubbing of All Commodity Market Segment available in the system.
- Base exchange should be available incase of interop is OFF and Combined exchange should be available incase of interop is ON for the respective segments in Market Segment field.
Instrument Type- Control Type: Drop-Down list
- Should display the following Instrument type available in the dropdown.
- Future
- Option
Symbol- Control Type: Drop-Down list
- System should populate the list of symbols available for the respective segment and Instrument type selected.
- On entering the Keyword of the symbol name-system should fetch and populate the list of Scrips\Contracts available for the segment selected in "Market Segment" dropdown.
- (i.e.: if Market Segment is selected as "NSE Equity" and on search of 'AC' – system should populate "ACC" and for derivative segment is market segment "NSE Derivative" and on search of "APO"-System should populate "APOLLOHOSP"," APOLLOTYRE")
- For Derivative, Currency and commodity like segments, future and option contracts should get loaded on the same time.
Series- Control Type: Drop-Down list
- This field should get enable only for equity like segments i.e.: when Market Segment is selected as "All, All Equity, NSE Equity, BSE Equity and MSE Equity".
Contract Type- Control Type: Drop-Down list
- This field should get enable for derivative, currency, commodity like segments selected in the "Market Segment" drop-down.
- Drop-down list should contain the items like "Weekly" and "Monthly".
Expiry Date- Control Type: Entry for Date in DD/MM/YYYY format and Calendar Selection
- This field should get enable for derivative, currency, commodity like segments selected in the "Market Segment" drop-down.
- Drop-down should display the list of weekly Expiry Dates available in the system for the selected contract as "Current", "Current+1", "Current+2" till "Current+15"
- "ALL" option Should be available in the List. "ALL" refers to Clubbing of All Expiry Date available for the contract.
Strike Price- Control Type: Drop-Down list.
- This Drop down will have "ALL" option and disabled.
- This field should be mandatory only if Option contract is selected in the scrip combination.
- Send "-1" in strike price in API for "ALL".
- This field should get enable for derivative, currency, commodity like segments selected in the "Market segment drop-down.
Option Type- This field should get enable for derivative, currency, commodity like segments selected in the "Market Segment" drop down.
- Drop-down list should display the list of Option type available in the system (i.e.: CE and PE) for the contract loaded in "Symbol" and "Expiry Date" field.
- By default, field should be blank.
- This field should be mandatory only if Option contract is selected in the scrip combination.
ITM %- Control Type: Entry percentagefield.
- System should allow to enter In The Money Percentage.
- This field is applicable for defining the ITM Percentage for Option Contracts.
OTM %- Control Type: Entry percentagefield.
- System should allow to enter OUT Of Money Percentage.
- This field is applicable for defining the OTM Percentage for Option Contracts.
Product Type- Control Type: Drop-Down list.
- Should display the list of Product types available in the system.
- If New product type is added by the member in the system, then same should be displayed here in the dropdown list.
- Following item should be displayed in the drop-down list-
- Margin
- Delivery
- Intraday
- Carryforward
- Margi-Plus
- Bracket Order

Action Controls

🔧 Control📦 Type📝 Business Logic
AddButton- Control Type: Button
- On Click of Add button, Selected options in the dropdown list like (Market Segment, Instrument name, Symbol, Series, Contract Type, Expiry Date, Strike Price, Option Type should be added to the Scrip Basket grid view
- On Click of "Add", If Same combination record is already available in the system for the template, then system should display an alert Popup Window.
- (i.e. Combination of Segment, instrument, Symbol, Series, Contract type, Expiry Date, Strike Price, Option type and Margin type)
- Message string in popup window should be like "Record already available for Combination in the system- Do you want to replace?" with an option of "YES" and "NO"
- If Admin user selects the option as "YES", then system should delete the Record available in the selected template with the same combination and should add the new record of the selected combination.
- If Admin user selects the Option as "NO", then system should not make any changes to the record available in the template and popup window should get close.
RemarksEntry field- Control Type: Entry field
- Maximum 50 characters should be allowed to enter in the Remarks
- Allow to enter Remarks with Character, numeric and special characters while adding\updating the deposit\limit.
- System should display the last updated remarks as per the template selection.
- Should allow to modify the remarks.

Contract Type, Expiry Date fields should be enable only for Future Segment and respective Instruments.

Contract Type, Expiry Date, Option type, ITM % , OTM % fields should be enable only for Option Segment and respective Instruments.

📊 Scrip Basket View

Scrip basket grid view should have the list of applicable margin rules to set at scrip level.

Following Fields should be displayed in the scrip basket view:

📋 Column Header
Main header (Margin Detail)
Column 1: Margin Type
Column 2: Value

💰 Margin Configuration

📝 Column Name⚙️ Business Logic
Transaction RuleColumn header should be available as "Transaction Rule".
Following Transaction Rules should be available under this Field with Checkbox
- Flat Buy Margin (%)
- Flat Sell Margin (%)
- Addon Buy Margin (%)
- Addon Sell Margin (%)
- Addon Buy Margin (Per Lot)
- Addon Sell Margin (Per Lot)
By default, Checkbox option should be Un-check.
If User Ticks the checkbox, value field against the rule should get enable.
ValueColumn header should be available as "VALUE".
System should allow to enter only Numeric Value in this field. Characters and Special characters should not be allowed.
By default, Value should be 0.00.
Systems should allow to enter the percentage range from 0.00 to 999.99 (Blank should be treated as 0)
Systems should allow to enter the flat value from 0.00 to 9999999.99 (Blank should be treated as 0)
System should allow to modify the value in this field.
System should allow to remove the value from this field, by making it 0.

🔗 Template Mapping

Scrip Basket Margin Template created here will be allowed to Map to the entities like (Client, Dealer, Branch and Member) as well as for users through "Template Mapping" window.

✅ Validations for adding the restriction rules for the users

  1. System should intimate the user with popup message on click of "ADD" button while adding the same combination of record which is already available within the template and the Message string should be like "Records with the same combination is already exist".
  2. System should allow to add the rules with a combination of (Segment, Instrument Scrip/Series wise, Product) separately.
  3. System should allow to Set the margin value for Weekly and Monthly Contract type separately.
  4. System should allow to modify the "Margin Value" of any of the rule available in the template.
  5. Minimum one Record should be available in the scrip basket template grid view to save the record.
  6. System should allow to set margin value for same combination rules of derivative segment with expiry date as Expiry date as "Current", "Current + N" date as well as with Option as "ALL".
  7. System should allow to add the allowed scrips in individual contract wise or underlying wise in the template.
  8. System should allow to place the orders only on the scrip which is mapped to the entity\user
  9. System should allow to set Margin for Multiple Segment under single template.

🎛️ RRT RULE

As per this rule configuration, system should allow order for the Scrips/Contracts only which are part of Scrip Basket Margin

Following are the list of variables for this rule

📝 Variable Name⚙️ Variable Type🔧 Variable Value🔄 Default
Restrict Order which are not part of Scrip Basket-Margin(Allowed)Check-BoxEnable / DisableDisable

This Rule shall be validated for Fresh Order not for square off Order.

If this rule (Restrict Trading other than scrip basket Scrip) is checked then System shall check whether such scrip in which order is placed is part of assigned scrip basket template to the entity for which order is placed. Kindly note that "Multiple Scrip Basket - Margin" Template can be assigned. so scrip available in any of the assigned basket then system shall allow else reject

Case 1 Rule Checked and Scrip Exists in assigned scrip basket- margin

System should pass such order for this rule and proceed for further rule validation

Case 2 Rule Checked and Scrip does not exist in assigned scrip basket - margin

System should reject such order for this rule and generate the log i.e., Rule ID / Template Name/etc.

Case 3 Rule unChecked

System should not execute this rule and proceed for further rule validation

Assume Interop is ON for EQ and FNO segment.

Example For EQ

ASSUMING in Scrip basket Template is having following records

📊 Segment📦 Symbol📈 Series
ALL EQACCEQ
ALL EQTCSEQ

with above example, System shall not allowed to place order in RELIANCE scrip as it is not part of Scrip Basket Margin Template.

🔓 ByPass Basket Scrip

Currently as per scrip basket allowed rule, member is been able to not allowing to trade in certain scrips to a group. However based on business need, if he wants to exclude one scrip for a specific user, we are introducing "Bypass Basket Scrip" concept, in which: -

  • Member will be able to assign 1 scrip per user, in which above mentioned restriction will not happen.
  • Member need to select tradable scrip in the selection. (ExchangeId + Token)
  • Other applicable rules including margin will be validated as usual.
  • This will be available for the day only. The same will be cleaned on BOD.
  • Only one scrip is supported. This can be changed multiple time in a day, as per member's requirement.

"Bypass Basket Scrip" concept. For this in Entity Master UI (Also in EntityDashboard), we will have a scrip selection. In that User can select any scrip which he wants to bypass.

Example:

🔑 Bypass Token📊 Order in NSE EQ📊 Order in BSE EQ
NSE EQ-RelianceBypassAs per rule setting-Order reject
BSE EQ-RelianceAs per rule setting-Order rejectBypass
ALL EQ-RelianceAs per rule setting-Order rejectAs per rule setting-Order reject

Case 1 : In scrip basket margin we have restricted Idea token in EQ

  • when we place order in following scrip we will get rejection.
  • Now if we select idea in bypass basket scrip then order will get passed