Skip to main content

Market Connect

Search Scrips

The Search scrips APIs provide you with the ability to efficiently search for instruments by utilizing relevant keywords.

Method: post

https://connect.thefirstock.com/api/V4/searchScrips

Request details

API Parameters
Parameter Description Example
userId
string
Identifier for the user upon login, unique to each user in the system. AA0013
stext
string
Search Text ITC
jKey
string
Authentication token obtained from the login API d4180daa72ea70885ab0d

Libraries and SDKs

Tabbed Interface
from thefirstock import thefirstock

 searchScrips = thefirstock.firstock_SearchScrips(
 userId="{{userId}}",
 stext="ITC"
 )
curl --location --request POST 'https://connect.thefirstock.com/api/V4/searchScrips' \
 --header 'Content-Type: application/json' \
 --data-raw '{
         "userId": "{{userId}}",
         "stext": "ITC",
         "jKey": "{{jKey}}"
      }'
const Firstock = require("thefirstock");

const firstock = new Firstock(userId: {{userId}});

firstock.searchScripts({ stext: "ITC" }, (err, result) => {
  console.log("Error, ", err);
  console.log("Result: ", result);
});
using thefirstock;

class Program
{
    public static void Main()
    {
        Firstock firstock = new Firstock(userId: {{userId}});
        var result = firstock.searchScripts(stext: "ITC");
    }
}

Success response details

API Parameters
Parameter Description Example
values
String
Describes the status within the
data portion of the response
{ "exchange": "",
"tradingSymbol": "",
"token": "23650",
"companyName": " ",
"instrumentName": "",
"pricePrecision": "",
"lotSize": "",
"tickSize": "" }
status
String (array)
Indicates the result status of
the API operation
success

Response Details: Json Fields of object in values Array

API Parameters
Parameter Description Example
exchange
String
The financial exchange where
the security is listed and traded, like
the National Stock Exchange (NSE)
or Bombay Stock Exchange (BSE).
NSE
tradingSymbol
String
The unique symbol or identifier
for the stock or financial
instrument being traded on
the exchange.
MUTHOOTFIN-EQ
token
String
A specific code or token
assigned to the trading instrument
for identification within the
trading system.
23650
pricePrecision
String
The number of decimal places
to which the price of the instrument
is calculated, defining the
smallest price movement.
2
tickSize
String
The minimum price movement of
the instrument on the exchange,
representing the smallest price change.
0.05
lotSize
String
The standard number of units
of the instrument that make up a
single trading lot, representing
the minimum tradable quantity.
1
companyName
String
The full legal name of
the company associated with the
trading symbol.
MUTHOOT FINANCE LTD
instrumentName
String
The type of financial instrument
being traded, such as equity (EQ),
futures, options, etc.
EQ
{
  "status": "success",
  "values": [
      {
          "exchange": "NSE",
          "tradingSymbol": "MUTHOOTFIN-EQ",
          "token": "23650",
          "companyName": "MUTHOOT FINANCE LIMITED",
          "instrumentName": "EQ",
          "pricePrecision": "2",
          "lotSize": "1",
          "tickSize": "0.05"
      },
      {
          "exchange": "NSE",
          "tradingSymbol": "MUTHOOTCAP-EQ",
          "token": "10415",
          "companyName": "MUTHOOT CAP SERV LTD",
          "instrumentName": "EQ",
          "pricePrecision": "2",
          "lotSize": "1",
          "tickSize": "0.05"
      },
      {
          "exchange": "NSE",
          "tradingSymbol": "MURUDCERA-EQ",
          "token": "2313",
          "companyName": "MURUDESHWAR CERAMICS LTD",
          "instrumentName": "EQ",
          "pricePrecision": "2",
          "lotSize": "1",
          "tickSize": "0.05"
      },
      {
          "exchange": "NSE",
          "tradingSymbol": "MUNJALSHOW-EQ",
          "token": "2307",
          "companyName": "MUNJAL SHOWA LTD",
          "instrumentName": "EQ",
          "pricePrecision": "2",
          "lotSize": "1",
          "tickSize": "0.05"
      },
      {
          "exchange": "NSE",
          "tradingSymbol": "MUNJALAU-EQ",
          "token": "13511",
          "companyName": "MUNJAL AUTO IND. LTD.",
          "instrumentName": "EQ",
          "pricePrecision": "2",
          "lotSize": "1",
          "tickSize": "0.05"
      },
      {
          "exchange": "NSE",
          "tradingSymbol": "MUKTAARTS-EQ",
          "token": "8687",
          "companyName": "MUKTA ARTS LIMITED",
          "instrumentName": "EQ",
          "pricePrecision": "2",
          "lotSize": "1",
          "tickSize": "0.05"
      },
      {
          "exchange": "NSE",
          "tradingSymbol": "MUKANDLTD-EQ",
          "token": "11325",
          "companyName": "MUKAND LTD.",
          "instrumentName": "EQ",
          "pricePrecision": "2",
          "lotSize": "1",
          "tickSize": "0.05"
      },
      {
          "exchange": "NSE",
          "tradingSymbol": "MTNL-EQ",
          "token": "2294",
          "companyName": "MAHANAGAR TELEPHONE NIGAM",
          "instrumentName": "EQ",
          "pricePrecision": "2",
          "lotSize": "1",
          "tickSize": "0.05"
      },
      {
          "exchange": "NSE",
          "tradingSymbol": "MTEDUCARE-BE",
          "token": "31413",
          "companyName": "MT EDUCARE LTD",
          "instrumentName": "BE",
          "pricePrecision": "2",
          "lotSize": "1",
          "tickSize": "0.05"
      },
      {
          "exchange": "NSE",
          "tradingSymbol": "MTARTECH-EQ",
          "token": "2709",
          "companyName": "MTAR TECHNOLOGIES LIMITED",
          "instrumentName": "EQ",
          "pricePrecision": "2",
          "lotSize": "1",
          "tickSize": "0.05"
      },
      {
          "exchange": "NSE",
          "tradingSymbol": "MSUMI-EQ",
          "token": "8596",
          "companyName": "MOTHERSON SUMI WRNG IND L",
          "instrumentName": "EQ",
          "pricePrecision": "2",
          "lotSize": "1",
          "tickSize": "0.05"
      },
      {
          "exchange": "NSE",
          "tradingSymbol": "MSTCLTD-EQ",
          "token": "9356",
          "companyName": "MSTC LIMITED",
          "instrumentName": "EQ",
          "pricePrecision": "2",
          "lotSize": "1",
          "tickSize": "0.05"
      },
      {
          "exchange": "NSE",
          "tradingSymbol": "MSPL-EQ",
          "token": "11919",
          "companyName": "MSP STEEL & POWER LTD.",
          "instrumentName": "EQ",
          "pricePrecision": "2",
          "lotSize": "1",
          "tickSize": "0.05"
      },
      {
          "exchange": "NSE",
          "tradingSymbol": "MRPL-EQ",
          "token": "2283",
          "companyName": "MRPL",
          "instrumentName": "EQ",
          "pricePrecision": "2",
          "lotSize": "1",
          "tickSize": "0.05"
      },
      {
          "exchange": "NSE",
          "tradingSymbol": "MRO-TEK-EQ",
          "token": "8998",
          "companyName": "MRO-TEK REALTY LIMITED",
          "instrumentName": "EQ",
          "pricePrecision": "2",
          "lotSize": "1",
          "tickSize": "0.05"
      },
      {
          "exchange": "NSE",
          "tradingSymbol": "MRF-EQ",
          "token": "2277",
          "companyName": "MRF LTD",
          "instrumentName": "EQ",
          "pricePrecision": "2",
          "lotSize": "1",
          "tickSize": "0.05"
      },
      {
          "exchange": "NSE",
          "tradingSymbol": "MPSLTD-EQ",
          "token": "10578",
          "companyName": "MPS LIMITED",
          "instrumentName": "EQ",
          "pricePrecision": "2",
          "lotSize": "1",
          "tickSize": "0.05"
      },
      {
          "exchange": "NSE",
          "tradingSymbol": "MPHASIS-EQ",
          "token": "4503",
          "companyName": "MPHASIS LIMITED",
          "instrumentName": "EQ",
          "pricePrecision": "2",
          "lotSize": "1",
          "tickSize": "0.05"
      },
      {
          "exchange": "NSE",
          "tradingSymbol": "MOVALUE-EQ",
          "token": "10825",
          "companyName": "MOTILALAMC - MOVALUE",
          "instrumentName": "EQ",
          "pricePrecision": "2",
          "lotSize": "1",
          "tickSize": "0.01"
      },
      {
          "exchange": "NSE",
          "tradingSymbol": "MOTOGENFIN-EQ",
          "token": "2268",
          "companyName": "MOTOR & GENERAL FINANCE L",
          "instrumentName": "EQ",
          "pricePrecision": "2",
          "lotSize": "1",
          "tickSize": "0.05"
      },
      {
          "exchange": "NSE",
          "tradingSymbol": "MOTILALOFS-EQ",
          "token": "14947",
          "companyName": "MOTILAL OSWAL FIN LTD",
          "instrumentName": "EQ",
          "pricePrecision": "2",
          "lotSize": "1",
          "tickSize": "0.05"
      },
      {
          "exchange": "NSE",
          "tradingSymbol": "MOTHERSON-EQ",
          "token": "4204",
          "companyName": "SAMVRDHNA MTHRSN INTL LTD",
          "instrumentName": "EQ",
          "pricePrecision": "2",
          "lotSize": "1",
          "tickSize": "0.05"
      },
      {
          "exchange": "NSE",
          "tradingSymbol": "MOREPENLAB-EQ",
          "token": "2259",
          "companyName": "MOREPEN LAB. LTD",
          "instrumentName": "EQ",
          "pricePrecision": "2",
          "lotSize": "1",
          "tickSize": "0.05"
      },
      {
          "exchange": "NSE",
          "tradingSymbol": "MORARJEE-EQ",
          "token": "28877",
          "companyName": "MORARJEE TEXTILES LIMITED",
          "instrumentName": "EQ",
          "pricePrecision": "2",
          "lotSize": "1",
          "tickSize": "0.05"
      },
      {
          "exchange": "NSE",
          "tradingSymbol": "MOQUALITY-EQ",
          "token": "10822",
          "companyName": "MOTILALAMC - MOQUALITY",
          "instrumentName": "EQ",
          "pricePrecision": "2",
          "lotSize": "1",
          "tickSize": "0.01"
      }
  ]
}

Failure response details

API Parameters
Parameter Description Example
status
String
Indicates the result status
of the API operation
failed
code
String
HTTP status code associated
with the error
400
name
String
Specifies the type or category of the
error encountered
BAD_REQUEST
error.field
String
Field in the request that
triggered the error
stext
error.message
String
Detailed message describing
the error
stext cannot be undefined
or NULL
{
  "status": "failed",
  "code": "400",
  "name": "BAD_REQUEST",
  "error": {
      "field": "stext",
      "message": "stext cannot be undefined or NULL"
  }
}