Indian names API – Identify a caste group or religion Namsor's Indian Names API offers precise insights into the caste group , religion , and state or union territory of residence associated with Indian names. Whether you provide a full name or separate first and last names, our API seamlessly adapts to your data format, ensuring smooth integration into your systems.
By analyzing naming patterns and regional information, this API can classify individuals into one of the four primary caste groups: Scheduled Castes (SC) , Scheduled Tribes (ST) , Other Backward Classes (OBC) , or General . The API also identifies the most probable religion among seven major Indian religions: Hinduism, Islam, Christianity, Sikhism, Buddhism, Jainism , and Parsi . It further determines the likely state or union territory of residence within India. This comprehensive analysis is invaluable for researchers, policymakers, and organizations seeking to understand India's diverse social fabric.
600+ Research contributions
99.99% Names availability
11B billions Names processed
,
Caste Indian Name Caste group from first name (optional) , last name (optional) , state .
{
"script": "LATIN",
"id": "string",
"firstName": "Akash",
"lastName": "Sharma",
"castegroup": "General/High Caste",
"castegroupAlt": "General",
"castegroupTop": [
"General/High Caste", "General", "OBC", "SC", "ST"
],
"score": 11.127678155723578,
"probabilityCalibrated": 0.7031015750163506,
"probabilityAltCalibrated": 0.9535225800378421
}
Caste Indian Name analyzes a first name, last name, and an Indian state or Union territory of residence to determine the person's most likely caste group . Providing both names improves the accuracy of the prediction.
POST GET
Cost: 10 credits per name .Description: Returns the caste from first names, last names and territories of residence.More about: Caste Indian Name HTTP request POST https://v2.namsor.com/NamSorAPIv2/api2/json/castegroupIndianBatch
Request header Property Required Description X-API-KEY
Required Your Namsor's services API key
Request body Name Type Required Description personalNames
Array of objects Required A list of personal full names with their State or Union territory of origin or residence .[{...}]. id
String Optional Provided unique identifier .[{...}]. firstName
String Optional Indian first name, given name, nickname .[{...}]. lastName
String Optional Indian last name, family name, surname .[{...}]. subdivisionIso
String Required Indian state or Union territory (origin or residence), in ISO 3166-2 format .
Response Name Type Description Enumerators personalNames
Array of objects List of submitted full names with their caste group. [{...}]. script
String Name of the script used for the name, in ISO 15924 format. Script [{...}]. id
String Provided unique identifier. [{...}]. firstName
String Provided first name. [{...}]. lastName
String Provided last name. [{...}]. castegroup
String Most likely caste group. Indian caste groups [{...}]. castegroupAlt
String Second most likely caste group. Indian caste groups [{...}]. castegroupTop
Array Top of the most likely caste group, sorted from most likely to least likely. Indian caste groups [{...}]. score
Number Higher implies a more reliable result, score is not normalized. [{...}]. probabilityCalibrated
Number The calibrated probability that castegroup has been guessed correctly. -1 = still calibrating. [{...}]. probabilityAltCalibrated
Number The calibrated probability that castegroup OR castegroupAlt have been guessed correctly. -1 = still calibrating.
Code sample: Shell Java PythonJavaScript JS Caste Indian Name code sample for shell:
curl --request POST \
--url https://v2.namsor.com/NamSorAPIv2/api2/json/castegroupIndianBatch \
--header 'X-API-KEY: your-api-key' \
--header 'Accept: application/json'
--header 'Content-Type: application/json' \
--data '{"personalNames":[{"id":"e630dda5-13b3-42c5-8f1d-648aa8a21c42","firstName":"Akash","lastName":"Sharma","subdivisionIso":"IN-UP"}]}'
Body parameter:
{
"personalNames": [
{
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"firstName": "Akash",
"lastName": "Sharma",
"subdivisionIso": "IN-UP"
}
]
}
The above command returns JSON structured like this:
{
"personalNames": [
{
"script": "LATIN",
"id": "string",
"firstName": "Akash",
"lastName": "Sharma",
"castegroup": "General/High Caste",
"castegroupAlt": "General",
"castegroupTop": ["General/High Caste", "General", "OBC", "SC", "ST"],
"score": 11.127678155723578,
"probabilityCalibrated": 0.7031015750163506,
"probabilityAltCalibrated": 0.9535225800378421
}
]
}
Caste Indian Name code sample for java:
HttpResponse<String> response = Unirest.post("https://v2.namsor.com/NamSorAPIv2/api2/json/castegroupIndianBatch")
.header("X-API-KEY", "your-api-key")
.header("Accept", "application/json")
.header("Content-Type", "application/json")
.body("{\"personalNames\":[{\"id\":\"e630dda5-13b3-42c5-8f1d-648aa8a21c42\",\"firstName\":\"Akash\",\"lastName\":\"Sharma\",\"subdivisionIso\":\"IN-UP\"}]}")
.asString();
Body parameter:
{
"personalNames": [
{
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"firstName": "Akash",
"lastName": "Sharma",
"subdivisionIso": "IN-UP"
}
]
}
The above command returns JSON structured like this:
{
"personalNames": [
{
"script": "LATIN",
"id": "string",
"firstName": "Akash",
"lastName": "Sharma",
"castegroup": "General/High Caste",
"castegroupAlt": "General",
"castegroupTop": ["General/High Caste", "General", "OBC", "SC", "ST"],
"score": 11.127678155723578,
"probabilityCalibrated": 0.7031015750163506,
"probabilityAltCalibrated": 0.9535225800378421
}
]
}
Caste Indian Name code sample for python:
import requests
url = "https://v2.namsor.com/NamSorAPIv2/api2/json/castegroupIndianBatch"
payload = {
"personalNames": [
{
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"firstName": "Akash",
"lastName": "Sharma",
"subdivisionIso": "IN-UP"
}
]
}
headers = {
"X-API-KEY": "your-api-key",
"Accept": "application/json",
"Content-Type": "application/json"
}
response = requests.request("POST", url, json=payload, headers=headers)
print(response.text)
Body parameter:
{
"personalNames": [
{
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"firstName": "Akash",
"lastName": "Sharma",
"subdivisionIso": "IN-UP"
}
]
}
The above command returns JSON structured like this:
{
"personalNames": [
{
"script": "LATIN",
"id": "string",
"firstName": "Akash",
"lastName": "Sharma",
"castegroup": "General/High Caste",
"castegroupAlt": "General",
"castegroupTop": ["General/High Caste", "General", "OBC", "SC", "ST"],
"score": 11.127678155723578,
"probabilityCalibrated": 0.7031015750163506,
"probabilityAltCalibrated": 0.9535225800378421
}
]
}
Caste Indian Name code sample for javascript:
const response = await fetch("https://v2.namsor.com/NamSorAPIv2/api2/json/castegroupIndianBatch", {
"method": "POST",
"headers": {
"X-API-KEY": "your-api-key",
"Accept": "application/json",
"Content-Type": "application/json"
},
"body": JSON.stringify({
"personalNames": [
{
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"firstName": "Akash",
"lastName": "Sharma",
"subdivisionIso": "IN-UP"
}
]
})
});
if (response.ok) {
const data = await response.json(); // Extract JSON data from response
console.log(data); // View data in the console
} else {
console.error("The request failed with status:", response.status, response);
}
Body parameter:
{
"personalNames": [
{
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"firstName": "Akash",
"lastName": "Sharma",
"subdivisionIso": "IN-UP"
}
]
}
The above command returns JSON structured like this:
{
"personalNames": [
{
"script": "LATIN",
"id": "string",
"firstName": "Akash",
"lastName": "Sharma",
"castegroup": "General/High Caste",
"castegroupAlt": "General",
"castegroupTop": ["General/High Caste", "General", "OBC", "SC", "ST"],
"score": 11.127678155723578,
"probabilityCalibrated": 0.7031015750163506,
"probabilityAltCalibrated": 0.9535225800378421
}
]
}
Cost: 10 credits per name .Description: Returns the caste from a first name, a last name and a territory of residence.For requests with a GET method all parameters are required . For more ease in the use of our requests we recommend that you use the POST method.
HTTP request GET https://v2.namsor.com/NamSorAPIv2/api2/json/castegroupIndian/{subdivisionIso}/{firstName}/{lastName}
Request header Property Required Description X-API-KEY
Required Your Namsor's services API key
Request parameters Name Type Required Description firstName
String Required Indian first name, given name, nickname .lastName
String Required Indian last name, family name, surname .subdivisionIso
String Required Indian state or Union territory (origin or residence), in ISO 3166-2 format .
Response Name Type Description Enumerators script
String Name of the script used for the name, in ISO 15924 format. Script id
String Provided unique identifier. firstName
String Provided first name. lastName
String Provided last name. castegroup
String Most likely caste group. Indian caste groups castegroupAlt
String Second most likely caste group. Indian caste groups castegroupTop
Array Top of the most likely caste group, sorted from most likely to least likely. Indian caste groups score
Number Higher implies a more reliable result, score is not normalized. probabilityCalibrated
Number The calibrated probability that castegroup has been guessed correctly. -1 = still calibrating. probabilityAltCalibrated
Number The calibrated probability that castegroup OR castegroupAlt have been guessed correctly. -1 = still calibrating.
Code sample: Shell Java PythonJavaScript JS Caste Indian Name code sample for shell:
curl --request GET \
--url https://v2.namsor.com/NamSorAPIv2/api2/json/castegroupIndian/IN-UP/Akash/Sharma \
--header 'X-API-KEY: your-api-key' \
--header 'Accept: application/json'
The above command returns JSON structured like this:
{
"script": "LATIN",
"id": "string",
"firstName": "Akash",
"lastName": "Sharma",
"castegroup": "General/High Caste",
"castegroupAlt": "General",
"castegroupTop": ["General/High Caste", "General", "OBC", "SC", "ST"],
"score": 11.127678155723578,
"probabilityCalibrated": 0.7031015750163506,
"probabilityAltCalibrated": 0.9535225800378421
}
Caste Indian Name code sample for java:
HttpResponse<String> response = Unirest.get("https://v2.namsor.com/NamSorAPIv2/api2/json/castegroupIndian/IN-UP/Akash/Sharma")
.header("X-API-KEY", "your-api-key")
.header("Accept", "application/json")
.asString();
The above command returns JSON structured like this:
{
"script": "LATIN",
"id": "string",
"firstName": "Akash",
"lastName": "Sharma",
"castegroup": "General/High Caste",
"castegroupAlt": "General",
"castegroupTop": ["General/High Caste", "General", "OBC", "SC", "ST"],
"score": 11.127678155723578,
"probabilityCalibrated": 0.7031015750163506,
"probabilityAltCalibrated": 0.9535225800378421
}
Caste Indian Name code sample for python:
import requests
url = "https://v2.namsor.com/NamSorAPIv2/api2/json/castegroupIndian/IN-UP/Akash/Sharma"
headers = {
"X-API-KEY": "your-api-key",
"Accept": "application/json"
}
response = requests.request("GET", url, headers=headers)
print(response.text)
The above command returns JSON structured like this:
{
"script": "LATIN",
"id": "string",
"firstName": "Akash",
"lastName": "Sharma",
"castegroup": "General/High Caste",
"castegroupAlt": "General",
"castegroupTop": ["General/High Caste", "General", "OBC", "SC", "ST"],
"score": 11.127678155723578,
"probabilityCalibrated": 0.7031015750163506,
"probabilityAltCalibrated": 0.9535225800378421
}
Caste Indian Name code sample for javascript:
const response = await fetch("https://v2.namsor.com/NamSorAPIv2/api2/json/castegroupIndian/IN-UP/Akash/Sharma", {
"method": "GET",
"headers": {
"X-API-KEY": "your-api-key",
"Accept": "application/json"
}
});
if (response.ok) {
const data = await response.json(); // Extract JSON data from response
console.log(data); // View data in the console
} else {
console.error("The request failed with status:", response.status, response);
}
The above command returns JSON structured like this:
{
"script": "LATIN",
"id": "string",
"firstName": "Akash",
"lastName": "Sharma",
"castegroup": "General/High Caste",
"castegroupAlt": "General",
"castegroupTop": ["General/High Caste", "General", "OBC", "SC", "ST"],
"score": 11.127678155723578,
"probabilityCalibrated": 0.7031015750163506,
"probabilityAltCalibrated": 0.9535225800378421
}
Caste Indian Full Name Caste group from full name , state .
{
"script": "LATIN",
"id": "string",
"name": "Akash Sharma",
"score": 7.8984899727105295,
"castegroup": "General/High Caste",
"castegroupAlt": "General",
"castegroupTop": [
"General/High Caste", "General", "OBC", "ST", "SC"
],
"probabilityCalibrated": 0.6400351364066995,
"probabilityAltCalibrated": 0.9559249062835251
}
Caste Indian Full Name analyzes an unsplit Indian full name along with a state or Union territory of residence to identify the person's most likely caste group .
If the first and last name are clearly identifiable, the Caste Indian Name feature will be slightly more accurate.
POST GET
Cost: 10 credits per name .Description: Returns the caste from unsplit Indian full names and territories of residence.More about: Caste Indian Full Name HTTP request POST https://v2.namsor.com/NamSorAPIv2/api2/json/castegroupIndianFullBatch
Request header Property Required Description X-API-KEY
Required Your Namsor's services API key
Request body Name Type Required Description personalNames
Array of objects Required A list of personal full names with their State or Union territory of origin or residence .[{...}]. id
String Optional Provided unique identifier .[{...}]. name
String Required Unsplit Indian full name (first name and last name) .[{...}]. subdivisionIso
String Required Indian state or Union territory (origin or residence), in ISO 3166-2 format .
Response Name Type Description Enumerators personalNames
Array of objects List of submitted full names with their caste group. [{...}]. script
String Name of the script used for the name, in ISO 15924 format. Script [{...}]. id
String Provided unique identifier. [{...}]. name
String Provided full name. [{...}]. score
Number Higher implies a more reliable result, score is not normalized. [{...}]. castegroup
String Most likely caste group. Indian caste groups [{...}]. castegroupAlt
String Second most likely caste group. Indian caste groups [{...}]. castegroupTop
Array Top of the most likely caste group, sorted from most likely to least likely. Indian caste groups [{...}]. probabilityCalibrated
Number The calibrated probability that castegroup has been guessed correctly. -1 = still calibrating. [{...}]. probabilityAltCalibrated
Number The calibrated probability that castegroup OR castegroupAlt have been guessed correctly. -1 = still calibrating.
Code sample: Shell Java PythonJavaScript JS Caste Indian Full Name code sample for shell:
curl --request POST \
--url https://v2.namsor.com/NamSorAPIv2/api2/json/castegroupIndianFullBatch \
--header 'X-API-KEY: your-api-key' \
--header 'Accept: application/json'
--header 'Content-Type: application/json' \
--data '{"personalNames":[{"id":"e630dda5-13b3-42c5-8f1d-648aa8a21c42","name":"Akash Sharma","subdivisionIso":"IN-UP"}]}'
Body parameter:
{
"personalNames": [
{
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"name": "Akash Sharma",
"subdivisionIso": "IN-UP"
}
]
}
The above command returns JSON structured like this:
{
"personalNames": [
{
"script": "LATIN",
"id": "string",
"name": "Akash Sharma",
"score": 7.8984899727105295,
"castegroup": "General/High Caste",
"castegroupAlt": "General",
"castegroupTop": ["General/High Caste", "General", "OBC", "ST", "SC"],
"probabilityCalibrated": 0.6400351364066995,
"probabilityAltCalibrated": 0.9559249062835251
}
]
}
Caste Indian Full Name code sample for java:
HttpResponse<String> response = Unirest.post("https://v2.namsor.com/NamSorAPIv2/api2/json/castegroupIndianFullBatch")
.header("X-API-KEY", "your-api-key")
.header("Accept", "application/json")
.header("Content-Type", "application/json")
.body("{\"personalNames\":[{\"id\":\"e630dda5-13b3-42c5-8f1d-648aa8a21c42\",\"name\":\"Akash Sharma\",\"subdivisionIso\":\"IN-UP\"}]}")
.asString();
Body parameter:
{
"personalNames": [
{
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"name": "Akash Sharma",
"subdivisionIso": "IN-UP"
}
]
}
The above command returns JSON structured like this:
{
"personalNames": [
{
"script": "LATIN",
"id": "string",
"name": "Akash Sharma",
"score": 7.8984899727105295,
"castegroup": "General/High Caste",
"castegroupAlt": "General",
"castegroupTop": ["General/High Caste", "General", "OBC", "ST", "SC"],
"probabilityCalibrated": 0.6400351364066995,
"probabilityAltCalibrated": 0.9559249062835251
}
]
}
Caste Indian Full Name code sample for python:
import requests
url = "https://v2.namsor.com/NamSorAPIv2/api2/json/castegroupIndianFullBatch"
payload = {
"personalNames": [
{
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"name": "Akash Sharma",
"subdivisionIso": "IN-UP"
}
]
}
headers = {
"X-API-KEY": "your-api-key",
"Accept": "application/json",
"Content-Type": "application/json"
}
response = requests.request("POST", url, json=payload, headers=headers)
print(response.text)
Body parameter:
{
"personalNames": [
{
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"name": "Akash Sharma",
"subdivisionIso": "IN-UP"
}
]
}
The above command returns JSON structured like this:
{
"personalNames": [
{
"script": "LATIN",
"id": "string",
"name": "Akash Sharma",
"score": 7.8984899727105295,
"castegroup": "General/High Caste",
"castegroupAlt": "General",
"castegroupTop": ["General/High Caste", "General", "OBC", "ST", "SC"],
"probabilityCalibrated": 0.6400351364066995,
"probabilityAltCalibrated": 0.9559249062835251
}
]
}
Caste Indian Full Name code sample for javascript:
const response = await fetch("https://v2.namsor.com/NamSorAPIv2/api2/json/castegroupIndianFullBatch", {
"method": "POST",
"headers": {
"X-API-KEY": "your-api-key",
"Accept": "application/json",
"Content-Type": "application/json"
},
"body": JSON.stringify({
"personalNames": [
{
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"name": "Akash Sharma",
"subdivisionIso": "IN-UP"
}
]
})
});
if (response.ok) {
const data = await response.json(); // Extract JSON data from response
console.log(data); // View data in the console
} else {
console.error("The request failed with status:", response.status, response);
}
Body parameter:
{
"personalNames": [
{
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"name": "Akash Sharma",
"subdivisionIso": "IN-UP"
}
]
}
The above command returns JSON structured like this:
{
"personalNames": [
{
"script": "LATIN",
"id": "string",
"name": "Akash Sharma",
"score": 7.8984899727105295,
"castegroup": "General/High Caste",
"castegroupAlt": "General",
"castegroupTop": ["General/High Caste", "General", "OBC", "ST", "SC"],
"probabilityCalibrated": 0.6400351364066995,
"probabilityAltCalibrated": 0.9559249062835251
}
]
}
Cost: 10 credits per name .Description: Returns the caste from an unsplit Indian full name and a territory of residence.For requests with a GET method all parameters are required . For more ease in the use of our requests we recommend that you use the POST method.
HTTP request GET https://v2.namsor.com/NamSorAPIv2/api2/json/castegroupIndianFull/{subdivisionIso}/{name}
Request header Property Required Description X-API-KEY
Required Your Namsor's services API key
Request parameters Name Type Required Description name
String Required Unsplit Indian full name (first name and last name) .subdivisionIso
String Required Indian state or Union territory (origin or residence), in ISO 3166-2 format .
Response Name Type Description Enumerators script
String Name of the script used for the name, in ISO 15924 format. Script id
String Provided unique identifier. name
String Provided full name. score
Number Higher implies a more reliable result, score is not normalized. castegroup
String Most likely caste group. Indian caste groups castegroupAlt
String Second most likely caste group. Indian caste groups castegroupTop
Array Top of the most likely caste group, sorted from most likely to least likely. Indian caste groups probabilityCalibrated
Number The calibrated probability that castegroup has been guessed correctly. -1 = still calibrating. probabilityAltCalibrated
Number The calibrated probability that castegroup OR castegroupAlt have been guessed correctly. -1 = still calibrating.
Code sample: Shell Java PythonJavaScript JS Caste Indian Full Name code sample for shell:
curl --request GET \
--url https://v2.namsor.com/NamSorAPIv2/api2/json/castegroupIndianFull/IN-UP/Akash%20Sharma \
--header 'X-API-KEY: your-api-key' \
--header 'Accept: application/json'
The above command returns JSON structured like this:
{
"script": "LATIN",
"id": "string",
"name": "Akash Sharma",
"score": 7.8984899727105295,
"castegroup": "General/High Caste",
"castegroupAlt": "General",
"castegroupTop": ["General/High Caste", "General", "OBC", "ST", "SC"],
"probabilityCalibrated": 0.6400351364066995,
"probabilityAltCalibrated": 0.9559249062835251
}
Caste Indian Full Name code sample for java:
HttpResponse<String> response = Unirest.get("https://v2.namsor.com/NamSorAPIv2/api2/json/castegroupIndianFull/IN-UP/Akash%20Sharma")
.header("X-API-KEY", "your-api-key")
.header("Accept", "application/json")
.asString();
The above command returns JSON structured like this:
{
"script": "LATIN",
"id": "string",
"name": "Akash Sharma",
"score": 7.8984899727105295,
"castegroup": "General/High Caste",
"castegroupAlt": "General",
"castegroupTop": ["General/High Caste", "General", "OBC", "ST", "SC"],
"probabilityCalibrated": 0.6400351364066995,
"probabilityAltCalibrated": 0.9559249062835251
}
Caste Indian Full Name code sample for python:
import requests
url = "https://v2.namsor.com/NamSorAPIv2/api2/json/castegroupIndianFull/IN-UP/Akash%20Sharma"
headers = {
"X-API-KEY": "your-api-key",
"Accept": "application/json"
}
response = requests.request("GET", url, headers=headers)
print(response.text)
The above command returns JSON structured like this:
{
"script": "LATIN",
"id": "string",
"name": "Akash Sharma",
"score": 7.8984899727105295,
"castegroup": "General/High Caste",
"castegroupAlt": "General",
"castegroupTop": ["General/High Caste", "General", "OBC", "ST", "SC"],
"probabilityCalibrated": 0.6400351364066995,
"probabilityAltCalibrated": 0.9559249062835251
}
Caste Indian Full Name code sample for javascript:
const response = await fetch("https://v2.namsor.com/NamSorAPIv2/api2/json/castegroupIndianFull/IN-UP/Akash%20Sharma", {
"method": "GET",
"headers": {
"X-API-KEY": "your-api-key",
"Accept": "application/json"
}
});
if (response.ok) {
const data = await response.json(); // Extract JSON data from response
console.log(data); // View data in the console
} else {
console.error("The request failed with status:", response.status, response);
}
The above command returns JSON structured like this:
{
"script": "LATIN",
"id": "string",
"name": "Akash Sharma",
"score": 7.8984899727105295,
"castegroup": "General/High Caste",
"castegroupAlt": "General",
"castegroupTop": ["General/High Caste", "General", "OBC", "ST", "SC"],
"probabilityCalibrated": 0.6400351364066995,
"probabilityAltCalibrated": 0.9559249062835251
}
Religion Indian Name Religion from first name (optional) , last name (optional) , state .
{
"script": "LATIN",
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"firstName": "Akash",
"lastName": "Sharma",
"religion": "Hinduism",
"religionAlt": "Jain",
"religionsTop": [
"Hinduism", "Jain", "Buddhist", "Christian", "Sikh", "Parsi", "Muslim"
],
"score": 15.842441054636446,
"probabilityCalibrated": 0.8366121598622244,
"probabilityAltCalibrated": 0.9418751496555294
}
Religion Indian Name analyzes a first name, last name, and an Indian state or Union territory of residence to determine the person's most likely religion . Accuracy is improved when both names are provided.
POST GET
Cost: 10 credits per name .Description: Returns religion from Indian first and last names and territories of origin.More about: Religion Indian Name HTTP request POST https://v2.namsor.com/NamSorAPIv2/api2/json/religionIndianBatch
Request header Property Required Description X-API-KEY
Required Your Namsor's services API key
Request body Name Type Required Description personalNames
Array of objects Required A list of personal names with their State or Union territory of origin or residence .[{...}]. id
String Optional Provided unique identifier .[{...}]. firstName
String Optional Indian first name, given name, nickname .[{...}]. lastName
String Optional Indian last name, family name, surname .[{...}]. subdivisionIso
String Required Indian state or Union territory (origin or residence), in ISO 3166-2 format .
Response Name Type Description Enumerators personalNames
Array of objects List of submitted names with their religion. [{...}]. script
String Name of the script used for the name, in ISO 15924 format. Script [{...}]. id
String Provided unique identifier. [{...}]. firstName
String Provided first name. [{...}]. lastName
String Provided last name. [{...}]. religion
String Most likely religion. Religions of India [{...}]. religionAlt
String Second most likely religion. Religions of India [{...}]. religionsTop
Array Top of the most likely religions, sorted from most likely to least likely. Religions of India [{...}]. score
Number Higher implies a more reliable result, score is not normalized. [{...}]. probabilityCalibrated
Number The calibrated probability that religion has been guessed correctly. -1 = still calibrating. [{...}]. probabilityAltCalibrated
Number The calibrated probability that religion OR religionAlt have been guessed correctly. -1 = still calibrating.
Code sample: Shell Java PythonJavaScript JS Religion Indian Name code sample for shell:
curl --request POST \
--url https://v2.namsor.com/NamSorAPIv2/api2/json/religionIndianBatch \
--header 'X-API-KEY: your-api-key' \
--header 'Accept: application/json'
--header 'Content-Type: application/json' \
--data '{"personalNames":[{"id":"e630dda5-13b3-42c5-8f1d-648aa8a21c42","firstName":"Akash","lastName":"Sharma","subdivisionIso":"IN-PB"}]}'
Body parameter:
{
"personalNames": [
{
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"firstName": "Akash",
"lastName": "Sharma",
"subdivisionIso": "IN-PB"
}
]
}
The above command returns JSON structured like this:
{
"personalNames": [
{
"script": "LATIN",
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"firstName": "Akash",
"lastName": "Sharma",
"religion": "Hinduism",
"religionAlt": "Jain",
"religionsTop": ["Hinduism", "Jain", "Buddhist", "Christian", "Sikh", "Parsi", "Muslim"],
"score": 15.842441054636446,
"probabilityCalibrated": 0.8366121598622244,
"probabilityAltCalibrated": 0.9418751496555294
}
]
}
Religion Indian Name code sample for java:
HttpResponse<String> response = Unirest.post("https://v2.namsor.com/NamSorAPIv2/api2/json/religionIndianBatch")
.header("X-API-KEY", "your-api-key")
.header("Accept", "application/json")
.header("Content-Type", "application/json")
.body("{\"personalNames\":[{\"id\":\"e630dda5-13b3-42c5-8f1d-648aa8a21c42\",\"firstName\":\"Akash\",\"lastName\":\"Sharma\",\"subdivisionIso\":\"IN-PB\"}]}")
.asString();
Body parameter:
{
"personalNames": [
{
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"firstName": "Akash",
"lastName": "Sharma",
"subdivisionIso": "IN-PB"
}
]
}
The above command returns JSON structured like this:
{
"personalNames": [
{
"script": "LATIN",
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"firstName": "Akash",
"lastName": "Sharma",
"religion": "Hinduism",
"religionAlt": "Jain",
"religionsTop": ["Hinduism", "Jain", "Buddhist", "Christian", "Sikh", "Parsi", "Muslim"],
"score": 15.842441054636446,
"probabilityCalibrated": 0.8366121598622244,
"probabilityAltCalibrated": 0.9418751496555294
}
]
}
Religion Indian Name code sample for python:
import requests
url = "https://v2.namsor.com/NamSorAPIv2/api2/json/religionIndianBatch"
payload = {
"personalNames": [
{
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"firstName": "Akash",
"lastName": "Sharma",
"subdivisionIso": "IN-PB"
}
]
}
headers = {
"X-API-KEY": "your-api-key",
"Accept": "application/json",
"Content-Type": "application/json"
}
response = requests.request("POST", url, json=payload, headers=headers)
print(response.text)
Body parameter:
{
"personalNames": [
{
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"firstName": "Akash",
"lastName": "Sharma",
"subdivisionIso": "IN-PB"
}
]
}
The above command returns JSON structured like this:
{
"personalNames": [
{
"script": "LATIN",
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"firstName": "Akash",
"lastName": "Sharma",
"religion": "Hinduism",
"religionAlt": "Jain",
"religionsTop": ["Hinduism", "Jain", "Buddhist", "Christian", "Sikh", "Parsi", "Muslim"],
"score": 15.842441054636446,
"probabilityCalibrated": 0.8366121598622244,
"probabilityAltCalibrated": 0.9418751496555294
}
]
}
Religion Indian Name code sample for javascript:
const response = await fetch("https://v2.namsor.com/NamSorAPIv2/api2/json/religionIndianBatch", {
"method": "POST",
"headers": {
"X-API-KEY": "your-api-key",
"Accept": "application/json",
"Content-Type": "application/json"
},
"body": JSON.stringify({
"personalNames": [
{
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"firstName": "Akash",
"lastName": "Sharma",
"subdivisionIso": "IN-PB"
}
]
})
});
if (response.ok) {
const data = await response.json(); // Extract JSON data from response
console.log(data); // View data in the console
} else {
console.error("The request failed with status:", response.status, response);
}
Body parameter:
{
"personalNames": [
{
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"firstName": "Akash",
"lastName": "Sharma",
"subdivisionIso": "IN-PB"
}
]
}
The above command returns JSON structured like this:
{
"personalNames": [
{
"script": "LATIN",
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"firstName": "Akash",
"lastName": "Sharma",
"religion": "Hinduism",
"religionAlt": "Jain",
"religionsTop": ["Hinduism", "Jain", "Buddhist", "Christian", "Sikh", "Parsi", "Muslim"],
"score": 15.842441054636446,
"probabilityCalibrated": 0.8366121598622244,
"probabilityAltCalibrated": 0.9418751496555294
}
]
}
Cost: 10 credits per name .Description: Returns the religion from a first name, a last name and a territory of residence.For requests with a GET method all parameters are required . For more ease in the use of our requests we recommend that you use the POST method.
HTTP request GET https://v2.namsor.com/NamSorAPIv2/api2/json/religionIndian/{subdivisionIso}/{firstName}/{lastName}
Request header Property Required Description X-API-KEY
Required Your Namsor's services API key
Request parameters Name Type Required Description firstName
String Required Indian first name, given name, nickname .lastName
String Required Indian last name, family name, surname .subdivisionIso
String Required Indian state or Union territory (origin or residence), in ISO 3166-2 format .
Response Name Type Description Enumerators script
String Name of the script used for the name, in ISO 15924 format. Script id
String Provided unique identifier. firstName
String Provided first name. lastName
String Provided last name. religion
String Most likely religion. Religions of India religionAlt
String Second most likely religion. Religions of India religionsTop
Array Top of the most likely religions, sorted from most likely to least likely. Religions of India score
Number Higher implies a more reliable result, score is not normalized. probabilityCalibrated
Number The calibrated probability that religion has been guessed correctly. -1 = still calibrating. probabilityAltCalibrated
Number The calibrated probability that religion OR religionAlt have been guessed correctly. -1 = still calibrating.
Code sample: Shell Java PythonJavaScript JS Religion Indian Name code sample for shell:
curl --request GET \
--url https://v2.namsor.com/NamSorAPIv2/api2/json/religionIndian/IN-PB/Akash/Sharma \
--header 'X-API-KEY: your-api-key' \
--header 'Accept: application/json'
The above command returns JSON structured like this:
{
"script": "LATIN",
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"firstName": "Akash",
"lastName": "Sharma",
"religion": "Hinduism",
"religionAlt": "Jain",
"religionsTop": ["Hinduism", "Jain", "Buddhist", "Christian", "Sikh", "Parsi", "Muslim"],
"score": 15.842441054636446,
"probabilityCalibrated": 0.8366121598622244,
"probabilityAltCalibrated": 0.9418751496555294
}
Religion Indian Name code sample for java:
HttpResponse<String> response = Unirest.get("https://v2.namsor.com/NamSorAPIv2/api2/json/religionIndian/IN-PB/Akash/Sharma")
.header("X-API-KEY", "your-api-key")
.header("Accept", "application/json")
.asString();
The above command returns JSON structured like this:
{
"script": "LATIN",
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"firstName": "Akash",
"lastName": "Sharma",
"religion": "Hinduism",
"religionAlt": "Jain",
"religionsTop": ["Hinduism", "Jain", "Buddhist", "Christian", "Sikh", "Parsi", "Muslim"],
"score": 15.842441054636446,
"probabilityCalibrated": 0.8366121598622244,
"probabilityAltCalibrated": 0.9418751496555294
}
Religion Indian Name code sample for python:
import requests
url = "https://v2.namsor.com/NamSorAPIv2/api2/json/religionIndian/IN-PB/Akash/Sharma"
headers = {
"X-API-KEY": "your-api-key",
"Accept": "application/json"
}
response = requests.request("GET", url, headers=headers)
print(response.text)
The above command returns JSON structured like this:
{
"script": "LATIN",
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"firstName": "Akash",
"lastName": "Sharma",
"religion": "Hinduism",
"religionAlt": "Jain",
"religionsTop": ["Hinduism", "Jain", "Buddhist", "Christian", "Sikh", "Parsi", "Muslim"],
"score": 15.842441054636446,
"probabilityCalibrated": 0.8366121598622244,
"probabilityAltCalibrated": 0.9418751496555294
}
Religion Indian Name code sample for javascript:
const response = await fetch("https://v2.namsor.com/NamSorAPIv2/api2/json/religionIndian/IN-PB/Akash/Sharma", {
"method": "GET",
"headers": {
"X-API-KEY": "your-api-key",
"Accept": "application/json"
}
});
if (response.ok) {
const data = await response.json(); // Extract JSON data from response
console.log(data); // View data in the console
} else {
console.error("The request failed with status:", response.status, response);
}
The above command returns JSON structured like this:
{
"script": "LATIN",
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"firstName": "Akash",
"lastName": "Sharma",
"religion": "Hinduism",
"religionAlt": "Jain",
"religionsTop": ["Hinduism", "Jain", "Buddhist", "Christian", "Sikh", "Parsi", "Muslim"],
"score": 15.842441054636446,
"probabilityCalibrated": 0.8366121598622244,
"probabilityAltCalibrated": 0.9418751496555294
}
Religion Indian Full Name Religion from full name , state .
{
"script": "LATIN",
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"name": "Akash Sharma",
"score": 11.205099735191228,
"religion": "Hinduism",
"religionAlt": "Jain",
"religionsTop": [
"Hinduism", "Jain", "Buddhist", "Christian", "Sikh", "Muslim", "Parsi"
],
"probabilityCalibrated": 0.9535569047307475,
"probabilityAltCalibrated": 0.9896944325654494
}
Religion Indian Full Name analyzes an unsplit Indian full name along with a state or Union territory of residence to determine the person's most likely religion .
If the first and last name are clearly identifiable, the Religion Indian Name feature will be slightly more accurate.
POST GET
Cost: 10 credits per name .Description: Returns religion from unsplit Indian full names and territories of origin.More about: Religion Indian Full Name HTTP request POST https://v2.namsor.com/NamSorAPIv2/api2/json/religionIndianFullBatch
Request header Property Required Description X-API-KEY
Required Your Namsor's services API key
Request body Name Type Required Description personalNames
Array of objects Required A list of personal names with their State or Union territory of origin or residence .[{...}]. id
String Optional Provided unique identifier .[{...}]. name
String Required Unsplit Indian full name (first name and last name) .[{...}]. subdivisionIso
String Required Indian state or Union territory (origin or residence), in ISO 3166-2 format .
Response Name Type Description Enumerators personalNames
Array of objects List of submitted names with their religion. [{...}]. script
String Name of the script used for the name, in ISO 15924 format. Script [{...}]. id
String Provided unique identifier. [{...}]. name
String Provided full name. [{...}]. score
Number Higher implies a more reliable result, score is not normalized. [{...}]. religion
String Most likely religion. Religions of India [{...}]. religionAlt
String Second most likely religion. Religions of India [{...}]. religionsTop
Array Top of the most likely religions, sorted from most likely to least likely. Religions of India [{...}]. probabilityCalibrated
Number The calibrated probability that religion has been guessed correctly. -1 = still calibrating. [{...}]. probabilityAltCalibrated
Number The calibrated probability that religion OR religionAlt have been guessed correctly. -1 = still calibrating.
Code sample: Shell Java PythonJavaScript JS Religion Indian Full Name code sample for shell:
curl --request POST \
--url https://v2.namsor.com/NamSorAPIv2/api2/json/religionIndianFullBatch \
--header 'X-API-KEY: your-api-key' \
--header 'Accept: application/json'
--header 'Content-Type: application/json' \
--data '{"personalNames":[{"id":"e630dda5-13b3-42c5-8f1d-648aa8a21c42","name":"Akash Sharma","subdivisionIso":"IN-PB"}]}'
Body parameter:
{
"personalNames": [
{
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"name": "Akash Sharma",
"subdivisionIso": "IN-PB"
}
]
}
The above command returns JSON structured like this:
{
"personalNames": [
{
"script": "LATIN",
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"name": "Akash Sharma",
"score": 11.205099735191228,
"religion": "Hinduism",
"religionAlt": "Jain",
"religionsTop": ["Hinduism", "Jain", "Buddhist", "Christian", "Sikh", "Muslim", "Parsi"],
"probabilityCalibrated": 0.9535569047307475,
"probabilityAltCalibrated": 0.9896944325654494
}
]
}
Religion Indian Full Name code sample for java:
HttpResponse<String> response = Unirest.post("https://v2.namsor.com/NamSorAPIv2/api2/json/religionIndianFullBatch")
.header("X-API-KEY", "your-api-key")
.header("Accept", "application/json")
.header("Content-Type", "application/json")
.body("{\"personalNames\":[{\"id\":\"e630dda5-13b3-42c5-8f1d-648aa8a21c42\",\"name\":\"Akash Sharma\",\"subdivisionIso\":\"IN-PB\"}]}")
.asString();
Body parameter:
{
"personalNames": [
{
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"name": "Akash Sharma",
"subdivisionIso": "IN-PB"
}
]
}
The above command returns JSON structured like this:
{
"personalNames": [
{
"script": "LATIN",
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"name": "Akash Sharma",
"score": 11.205099735191228,
"religion": "Hinduism",
"religionAlt": "Jain",
"religionsTop": ["Hinduism", "Jain", "Buddhist", "Christian", "Sikh", "Muslim", "Parsi"],
"probabilityCalibrated": 0.9535569047307475,
"probabilityAltCalibrated": 0.9896944325654494
}
]
}
Religion Indian Full Name code sample for python:
import requests
url = "https://v2.namsor.com/NamSorAPIv2/api2/json/religionIndianFullBatch"
payload = {
"personalNames": [
{
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"name": "Akash Sharma",
"subdivisionIso": "IN-PB"
}
]
}
headers = {
"X-API-KEY": "your-api-key",
"Accept": "application/json",
"Content-Type": "application/json"
}
response = requests.request("POST", url, json=payload, headers=headers)
print(response.text)
Body parameter:
{
"personalNames": [
{
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"name": "Akash Sharma",
"subdivisionIso": "IN-PB"
}
]
}
The above command returns JSON structured like this:
{
"personalNames": [
{
"script": "LATIN",
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"name": "Akash Sharma",
"score": 11.205099735191228,
"religion": "Hinduism",
"religionAlt": "Jain",
"religionsTop": ["Hinduism", "Jain", "Buddhist", "Christian", "Sikh", "Muslim", "Parsi"],
"probabilityCalibrated": 0.9535569047307475,
"probabilityAltCalibrated": 0.9896944325654494
}
]
}
Religion Indian Full Name code sample for javascript:
const response = await fetch("https://v2.namsor.com/NamSorAPIv2/api2/json/religionIndianFullBatch", {
"method": "POST",
"headers": {
"X-API-KEY": "your-api-key",
"Accept": "application/json",
"Content-Type": "application/json"
},
"body": JSON.stringify({
"personalNames": [
{
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"name": "Akash Sharma",
"subdivisionIso": "IN-PB"
}
]
})
});
if (response.ok) {
const data = await response.json(); // Extract JSON data from response
console.log(data); // View data in the console
} else {
console.error("The request failed with status:", response.status, response);
}
Body parameter:
{
"personalNames": [
{
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"name": "Akash Sharma",
"subdivisionIso": "IN-PB"
}
]
}
The above command returns JSON structured like this:
{
"personalNames": [
{
"script": "LATIN",
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"name": "Akash Sharma",
"score": 11.205099735191228,
"religion": "Hinduism",
"religionAlt": "Jain",
"religionsTop": ["Hinduism", "Jain", "Buddhist", "Christian", "Sikh", "Muslim", "Parsi"],
"probabilityCalibrated": 0.9535569047307475,
"probabilityAltCalibrated": 0.9896944325654494
}
]
}
Cost: 10 credits per name .Description: Returns the religion from an unsplit Indian full name and a territory of residence.For requests with a GET method all parameters are required . For more ease in the use of our requests we recommend that you use the POST method.
HTTP request GET https://v2.namsor.com/NamSorAPIv2/api2/json/religionIndianFull/{subdivisionIso}/{name}
Request header Property Required Description X-API-KEY
Required Your Namsor's services API key
Request parameters Name Type Required Description name
String Required Unsplit Indian full name (first name and last name) .subdivisionIso
String Required Indian state or Union territory (origin or residence), in ISO 3166-2 format .
Response Name Type Description Enumerators script
String Name of the script used for the name, in ISO 15924 format. Script id
String Provided unique identifier. name
String Provided full name. score
Number Higher implies a more reliable result, score is not normalized. religion
String Most likely religion. Religions of India religionAlt
String Second most likely religion. Religions of India religionsTop
Array Top of the most likely religions, sorted from most likely to least likely. Religions of India probabilityCalibrated
Number The calibrated probability that religion has been guessed correctly. -1 = still calibrating. probabilityAltCalibrated
Number The calibrated probability that religion OR religionAlt have been guessed correctly. -1 = still calibrating.
Code sample: Shell Java PythonJavaScript JS Religion Indian Full Name code sample for shell:
curl --request GET \
--url https://v2.namsor.com/NamSorAPIv2/api2/json/religionIndianFull/IN-PB/Akash%20Sharma \
--header 'X-API-KEY: your-api-key' \
--header 'Accept: application/json'
The above command returns JSON structured like this:
{
"script": "LATIN",
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"name": "Akash Sharma",
"score": 11.205099735191228,
"religion": "Hinduism",
"religionAlt": "Jain",
"religionsTop": ["Hinduism", "Jain", "Buddhist", "Christian", "Sikh", "Muslim", "Parsi"],
"probabilityCalibrated": 0.9535569047307475,
"probabilityAltCalibrated": 0.9896944325654494
}
Religion Indian Full Name code sample for java:
HttpResponse<String> response = Unirest.get("https://v2.namsor.com/NamSorAPIv2/api2/json/religionIndianFull/IN-PB/Akash%20Sharma")
.header("X-API-KEY", "your-api-key")
.header("Accept", "application/json")
.asString();
The above command returns JSON structured like this:
{
"script": "LATIN",
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"name": "Akash Sharma",
"score": 11.205099735191228,
"religion": "Hinduism",
"religionAlt": "Jain",
"religionsTop": ["Hinduism", "Jain", "Buddhist", "Christian", "Sikh", "Muslim", "Parsi"],
"probabilityCalibrated": 0.9535569047307475,
"probabilityAltCalibrated": 0.9896944325654494
}
Religion Indian Full Name code sample for python:
import requests
url = "https://v2.namsor.com/NamSorAPIv2/api2/json/religionIndianFull/IN-PB/Akash%20Sharma"
headers = {
"X-API-KEY": "your-api-key",
"Accept": "application/json"
}
response = requests.request("GET", url, headers=headers)
print(response.text)
The above command returns JSON structured like this:
{
"script": "LATIN",
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"name": "Akash Sharma",
"score": 11.205099735191228,
"religion": "Hinduism",
"religionAlt": "Jain",
"religionsTop": ["Hinduism", "Jain", "Buddhist", "Christian", "Sikh", "Muslim", "Parsi"],
"probabilityCalibrated": 0.9535569047307475,
"probabilityAltCalibrated": 0.9896944325654494
}
Religion Indian Full Name code sample for javascript:
const response = await fetch("https://v2.namsor.com/NamSorAPIv2/api2/json/religionIndianFull/IN-PB/Akash%20Sharma", {
"method": "GET",
"headers": {
"X-API-KEY": "your-api-key",
"Accept": "application/json"
}
});
if (response.ok) {
const data = await response.json(); // Extract JSON data from response
console.log(data); // View data in the console
} else {
console.error("The request failed with status:", response.status, response);
}
The above command returns JSON structured like this:
{
"script": "LATIN",
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"name": "Akash Sharma",
"score": 11.205099735191228,
"religion": "Hinduism",
"religionAlt": "Jain",
"religionsTop": ["Hinduism", "Jain", "Buddhist", "Christian", "Sikh", "Muslim", "Parsi"],
"probabilityCalibrated": 0.9535569047307475,
"probabilityAltCalibrated": 0.9896944325654494
}
Subclassification Indian Name Indian State or Union territory from first name (optional) , last name (optional) .
{
"script": "LATIN",
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"firstName": "Jannat",
"lastName": "Rahmani",
"countryIso2": "IN",
"subClassification": "IN-CH",
"subClassificationAlt": "IN-PY",
"subclassificationTop": [
"IN-CH", "IN-PY", "IN-UP", "IN-AN", "IN-RJ", "IN-JH", "IN-KL", "IN-BR", "IN-DL", "IN-UT"
],
"score": 2.5087208339960445,
"probabilityCalibrated": 0.3684249074494664,
"probabilityAltCalibrated": 0.4738687735374875
}
Subclassification Indian Name estimates the most likely State or Union territory of residence (in ISO 3166-2 alpha-2 format) based on a first name, last name, or both. It offers slightly better accuracy than Subclassification Indian Full Name .
POST GET
Precision: Cost: 10 credits per name .Description: Returns the most likely Indian State or Union territory of residence of up to 100 Indian first names and/or last names.More about: Subclassification Indian Name HTTP request POST https://v2.namsor.com/NamSorAPIv2/api2/json/subclassificationIndianBatch
Request header Property Required Description X-API-KEY
Required Your Namsor's services API key
Request body Name Type Required Description personalNames
Array of objects Required A list of personal names .[{...}]. id
String Optional Provided unique identifier .[{...}]. firstName
String Optional First name, given name, nickname .[{...}]. lastName
String Optional Last name, family name, surname .
Response Name Type Description Enumerators personalNames
Array of objects List of submitted names with their most likely geographic subdivision context. [{...}]. script
String Name of the script used for the name, in ISO 15924 format. Script [{...}]. id
String Provided unique identifier. [{...}]. firstName
String Submitted first name. [{...}]. lastName
String Submitted last name. [{...}]. countryIso2
String Most likely country of residence, in ISO 3166-1 alpha-2 format. Country of residence [{...}]. subClassification
String Most likely Indian State or Union territory of residence, in ISO 3166-2 alpha-2 format. Indian subdivision [{...}]. subClassificationAlt
String Second most likely Indian State or Union territory of residence, in ISO 3166-2 alpha-2 format. Indian subdivision [{...}]. subclassificationTop
Array Top 10 most likely Indian State or Union territory of residence, sorted from most likely to least likely. Indian subdivision [{...}]. score
Number Higher implies a more reliable result, score is not normalized. [{...}]. probabilityCalibrated
Number The calibrated probability for subClassification to have been guessed correctly. -1 = still calibrating. [{...}]. probabilityAltCalibrated
Number The calibrated probability for subClassification OR subClassificationAlt to have been guessed correctly. -1 = still calibrating.
Code sample: Shell Java PythonJavaScript JS Subclassification Indian Name code sample for shell:
curl --request POST \
--url https://v2.namsor.com/NamSorAPIv2/api2/json/subclassificationIndianBatch \
--header 'X-API-KEY: your-api-key' \
--header 'Accept: application/json'
--header 'Content-Type: application/json' \
--data '{"personalNames":[{"id":"e630dda5-13b3-42c5-8f1d-648aa8a21c42","firstName":"Jannat","lastName":"Rahmani"}]}'
Body parameter:
{
"personalNames": [
{
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"firstName": "Jannat",
"lastName": "Rahmani"
}
]
}
The above command returns JSON structured like this:
{
"personalNames": [
{
"script": "LATIN",
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"firstName": "Jannat",
"lastName": "Rahmani",
"countryIso2": "IN",
"subClassification": "IN-CH",
"subClassificationAlt": "IN-PY",
"subclassificationTop": ["IN-CH", "IN-PY", "IN-UP", "IN-AN", "IN-RJ", "IN-JH", "IN-KL", "IN-BR", "IN-DL", "IN-UT"],
"score": 2.5087208339960445,
"probabilityCalibrated": 0.3684249074494664,
"probabilityAltCalibrated": 0.4738687735374875
}
]
}
Subclassification Indian Name code sample for java:
HttpResponse<String> response = Unirest.post("https://v2.namsor.com/NamSorAPIv2/api2/json/subclassificationIndianBatch")
.header("X-API-KEY", "your-api-key")
.header("Accept", "application/json")
.header("Content-Type", "application/json")
.body("{\"personalNames\":[{\"id\":\"e630dda5-13b3-42c5-8f1d-648aa8a21c42\",\"firstName\":\"Jannat\",\"lastName\":\"Rahmani\"}]}")
.asString();
Body parameter:
{
"personalNames": [
{
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"firstName": "Jannat",
"lastName": "Rahmani"
}
]
}
The above command returns JSON structured like this:
{
"personalNames": [
{
"script": "LATIN",
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"firstName": "Jannat",
"lastName": "Rahmani",
"countryIso2": "IN",
"subClassification": "IN-CH",
"subClassificationAlt": "IN-PY",
"subclassificationTop": ["IN-CH", "IN-PY", "IN-UP", "IN-AN", "IN-RJ", "IN-JH", "IN-KL", "IN-BR", "IN-DL", "IN-UT"],
"score": 2.5087208339960445,
"probabilityCalibrated": 0.3684249074494664,
"probabilityAltCalibrated": 0.4738687735374875
}
]
}
Subclassification Indian Name code sample for python:
import requests
url = "https://v2.namsor.com/NamSorAPIv2/api2/json/subclassificationIndianBatch"
payload = {
"personalNames": [
{
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"firstName": "Jannat",
"lastName": "Rahmani"
}
]
}
headers = {
"X-API-KEY": "your-api-key",
"Accept": "application/json",
"Content-Type": "application/json"
}
response = requests.request("POST", url, json=payload, headers=headers)
print(response.text)
Body parameter:
{
"personalNames": [
{
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"firstName": "Jannat",
"lastName": "Rahmani"
}
]
}
The above command returns JSON structured like this:
{
"personalNames": [
{
"script": "LATIN",
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"firstName": "Jannat",
"lastName": "Rahmani",
"countryIso2": "IN",
"subClassification": "IN-CH",
"subClassificationAlt": "IN-PY",
"subclassificationTop": ["IN-CH", "IN-PY", "IN-UP", "IN-AN", "IN-RJ", "IN-JH", "IN-KL", "IN-BR", "IN-DL", "IN-UT"],
"score": 2.5087208339960445,
"probabilityCalibrated": 0.3684249074494664,
"probabilityAltCalibrated": 0.4738687735374875
}
]
}
Subclassification Indian Name code sample for javascript:
const response = await fetch("https://v2.namsor.com/NamSorAPIv2/api2/json/subclassificationIndianBatch", {
"method": "POST",
"headers": {
"X-API-KEY": "your-api-key",
"Accept": "application/json",
"Content-Type": "application/json"
},
"body": JSON.stringify({
"personalNames": [
{
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"firstName": "Jannat",
"lastName": "Rahmani"
}
]
})
});
if (response.ok) {
const data = await response.json(); // Extract JSON data from response
console.log(data); // View data in the console
} else {
console.error("The request failed with status:", response.status, response);
}
Body parameter:
{
"personalNames": [
{
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"firstName": "Jannat",
"lastName": "Rahmani"
}
]
}
The above command returns JSON structured like this:
{
"personalNames": [
{
"script": "LATIN",
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"firstName": "Jannat",
"lastName": "Rahmani",
"countryIso2": "IN",
"subClassification": "IN-CH",
"subClassificationAlt": "IN-PY",
"subclassificationTop": ["IN-CH", "IN-PY", "IN-UP", "IN-AN", "IN-RJ", "IN-JH", "IN-KL", "IN-BR", "IN-DL", "IN-UT"],
"score": 2.5087208339960445,
"probabilityCalibrated": 0.3684249074494664,
"probabilityAltCalibrated": 0.4738687735374875
}
]
}
Precision: Cost: 10 credits per name .Description: Returns the most likely Indian State or Union territory of residence from a first name and/or a last name.For requests with a GET method all parameters are required . For more ease in the use of our requests we recommend that you use the POST method.
HTTP request GET https://v2.namsor.com/NamSorAPIv2/api2/json/subclassificationIndian/{firstName}/{lastName}
Request header Property Required Description X-API-KEY
Required Your Namsor's services API key
Request parameters Name Type Required Description firstName
String Required First name, given name, nickname .lastName
String Required Last name, family name, surname .
Response Name Type Description Enumerators script
String Name of the script used for the name, in ISO 15924 format. Script id
String Provided unique identifier. firstName
String Submitted first name. lastName
String Submitted last name. countryIso2
String Most likely country of residence, in ISO 3166-1 alpha-2 format. Country of residence subClassification
String Most likely Indian State or Union territory of residence, in ISO 3166-2 alpha-2 format. Indian subdivision subClassificationAlt
String Second most likely Indian State or Union territory of residence, in ISO 3166-2 alpha-2 format. Indian subdivision subclassificationTop
Array Top 10 most likely Indian State or Union territory of residence, sorted from most likely to least likely. Indian subdivision score
Number Higher implies a more reliable result, score is not normalized. probabilityCalibrated
Number The calibrated probability for subClassification to have been guessed correctly. -1 = still calibrating. probabilityAltCalibrated
Number The calibrated probability for subClassification OR subClassificationAlt to have been guessed correctly. -1 = still calibrating.
Code sample: Shell Java PythonJavaScript JS Subclassification Indian Name code sample for shell:
curl --request GET \
--url https://v2.namsor.com/NamSorAPIv2/api2/json/subclassificationIndian/Jannat/Rahmani \
--header 'X-API-KEY: your-api-key' \
--header 'Accept: application/json'
The above command returns JSON structured like this:
{
"script": "LATIN",
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"firstName": "Jannat",
"lastName": "Rahmani",
"countryIso2": "IN",
"subClassification": "IN-CH",
"subClassificationAlt": "IN-PY",
"subclassificationTop": ["IN-CH", "IN-PY", "IN-UP", "IN-AN", "IN-RJ", "IN-JH", "IN-KL", "IN-BR", "IN-DL", "IN-UT"],
"score": 2.5087208339960445,
"probabilityCalibrated": 0.3684249074494664,
"probabilityAltCalibrated": 0.4738687735374875
}
Subclassification Indian Name code sample for java:
HttpResponse<String> response = Unirest.get("https://v2.namsor.com/NamSorAPIv2/api2/json/subclassificationIndian/Jannat/Rahmani")
.header("X-API-KEY", "your-api-key")
.header("Accept", "application/json")
.asString();
The above command returns JSON structured like this:
{
"script": "LATIN",
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"firstName": "Jannat",
"lastName": "Rahmani",
"countryIso2": "IN",
"subClassification": "IN-CH",
"subClassificationAlt": "IN-PY",
"subclassificationTop": ["IN-CH", "IN-PY", "IN-UP", "IN-AN", "IN-RJ", "IN-JH", "IN-KL", "IN-BR", "IN-DL", "IN-UT"],
"score": 2.5087208339960445,
"probabilityCalibrated": 0.3684249074494664,
"probabilityAltCalibrated": 0.4738687735374875
}
Subclassification Indian Name code sample for python:
import requests
url = "https://v2.namsor.com/NamSorAPIv2/api2/json/subclassificationIndian/Jannat/Rahmani"
headers = {
"X-API-KEY": "your-api-key",
"Accept": "application/json"
}
response = requests.request("GET", url, headers=headers)
print(response.text)
The above command returns JSON structured like this:
{
"script": "LATIN",
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"firstName": "Jannat",
"lastName": "Rahmani",
"countryIso2": "IN",
"subClassification": "IN-CH",
"subClassificationAlt": "IN-PY",
"subclassificationTop": ["IN-CH", "IN-PY", "IN-UP", "IN-AN", "IN-RJ", "IN-JH", "IN-KL", "IN-BR", "IN-DL", "IN-UT"],
"score": 2.5087208339960445,
"probabilityCalibrated": 0.3684249074494664,
"probabilityAltCalibrated": 0.4738687735374875
}
Subclassification Indian Name code sample for javascript:
const response = await fetch("https://v2.namsor.com/NamSorAPIv2/api2/json/subclassificationIndian/Jannat/Rahmani", {
"method": "GET",
"headers": {
"X-API-KEY": "your-api-key",
"Accept": "application/json"
}
});
if (response.ok) {
const data = await response.json(); // Extract JSON data from response
console.log(data); // View data in the console
} else {
console.error("The request failed with status:", response.status, response);
}
The above command returns JSON structured like this:
{
"script": "LATIN",
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"firstName": "Jannat",
"lastName": "Rahmani",
"countryIso2": "IN",
"subClassification": "IN-CH",
"subClassificationAlt": "IN-PY",
"subclassificationTop": ["IN-CH", "IN-PY", "IN-UP", "IN-AN", "IN-RJ", "IN-JH", "IN-KL", "IN-BR", "IN-DL", "IN-UT"],
"score": 2.5087208339960445,
"probabilityCalibrated": 0.3684249074494664,
"probabilityAltCalibrated": 0.4738687735374875
}
Subclassification Indian Full Name Indian State or Union territory from full name .
{
"script": "LATIN",
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"name": "Jannat Rahmani",
"countryIso2": "IN",
"subClassification": "IN-CH",
"subClassificationAlt": "IN-PY",
"subclassificationTop": [
"IN-CH", "IN-PY", "IN-UP", "IN-AN", "IN-RJ", "IN-JH", "IN-KL", "IN-BR", "IN-DL", "IN-UT"
],
"score": 2.5087208339960445,
"probabilityCalibrated": 0.3684249074494664,
"probabilityAltCalibrated": 0.4738687735374875
}
Subclassification Indian Full Name analyzes an unsplit full name (first and last name combined) to determine the person's most likely State or Union territory of residence , returned in ISO 3166-2 alpha-2 format.
POST GET
Precision: Cost: 10 credits per name .Description: Returns the most likely Indian State or Union territory of residence of up to 100 unsplit full names.More about: Subclassification Indian Full Name HTTP request POST https://v2.namsor.com/NamSorAPIv2/api2/json/subclassificationIndianFullBatch
Request header Property Required Description X-API-KEY
Required Your Namsor's services API key
Request body Name Type Required Description personalNames
Array of objects Required A list of personal names .[{...}]. id
String Optional Provided unique identifier .[{...}]. name
String Required Unsplit full name (first name and last name) .
Response Name Type Description Enumerators personalNames
Array of objects List of submitted names with their most likely geographic subdivision context. [{...}]. script
String Name of the script used for the name, in ISO 15924 format. Script [{...}]. id
String Provided unique identifier. [{...}]. name
String Submitted full name. [{...}]. countryIso2
String Most likely country of residence, in ISO 3166-1 alpha-2 format. Country of residence [{...}]. subClassification
String Most likely Indian State or Union territory of residence, in ISO 3166-2 alpha-2 format. Indian subdivision [{...}]. subClassificationAlt
String Second most likely Indian State or Union territory of residence, in ISO 3166-2 alpha-2 format. Indian subdivision [{...}]. subclassificationTop
Array Top 10 most likely Indian State or Union territory of residence, sorted from most likely to least likely. Indian subdivision [{...}]. score
Number Higher implies a more reliable result, score is not normalized. [{...}]. probabilityCalibrated
Number The calibrated probability for subClassification to have been guessed correctly. -1 = still calibrating. [{...}]. probabilityAltCalibrated
Number The calibrated probability for subClassification OR subClassificationAlt to have been guessed correctly. -1 = still calibrating.
Code sample: Shell Java PythonJavaScript JS Subclassification Indian Full Name code sample for shell:
curl --request POST \
--url https://v2.namsor.com/NamSorAPIv2/api2/json/subclassificationIndianFullBatch \
--header 'X-API-KEY: your-api-key' \
--header 'Accept: application/json'
--header 'Content-Type: application/json' \
--data '{"personalNames":[{"id":"e630dda5-13b3-42c5-8f1d-648aa8a21c42","name":"Jannat Rahmani"}]}'
Body parameter:
{
"personalNames": [
{
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"name": "Jannat Rahmani"
}
]
}
The above command returns JSON structured like this:
{
"personalNames": [
{
"script": "LATIN",
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"name": "Jannat Rahmani",
"countryIso2": "IN",
"subClassification": "IN-CH",
"subClassificationAlt": "IN-PY",
"subclassificationTop": ["IN-CH", "IN-PY", "IN-UP", "IN-AN", "IN-RJ", "IN-JH", "IN-KL", "IN-BR", "IN-DL", "IN-UT"],
"score": 2.5087208339960445,
"probabilityCalibrated": 0.3684249074494664,
"probabilityAltCalibrated": 0.4738687735374875
}
]
}
Subclassification Indian Full Name code sample for java:
HttpResponse<String> response = Unirest.post("https://v2.namsor.com/NamSorAPIv2/api2/json/subclassificationIndianFullBatch")
.header("X-API-KEY", "your-api-key")
.header("Accept", "application/json")
.header("Content-Type", "application/json")
.body("{\"personalNames\":[{\"id\":\"e630dda5-13b3-42c5-8f1d-648aa8a21c42\",\"name\":\"Jannat Rahmani\"}]}")
.asString();
Body parameter:
{
"personalNames": [
{
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"name": "Jannat Rahmani"
}
]
}
The above command returns JSON structured like this:
{
"personalNames": [
{
"script": "LATIN",
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"name": "Jannat Rahmani",
"countryIso2": "IN",
"subClassification": "IN-CH",
"subClassificationAlt": "IN-PY",
"subclassificationTop": ["IN-CH", "IN-PY", "IN-UP", "IN-AN", "IN-RJ", "IN-JH", "IN-KL", "IN-BR", "IN-DL", "IN-UT"],
"score": 2.5087208339960445,
"probabilityCalibrated": 0.3684249074494664,
"probabilityAltCalibrated": 0.4738687735374875
}
]
}
Subclassification Indian Full Name code sample for python:
import requests
url = "https://v2.namsor.com/NamSorAPIv2/api2/json/subclassificationIndianFullBatch"
payload = {
"personalNames": [
{
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"name": "Jannat Rahmani"
}
]
}
headers = {
"X-API-KEY": "your-api-key",
"Accept": "application/json",
"Content-Type": "application/json"
}
response = requests.request("POST", url, json=payload, headers=headers)
print(response.text)
Body parameter:
{
"personalNames": [
{
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"name": "Jannat Rahmani"
}
]
}
The above command returns JSON structured like this:
{
"personalNames": [
{
"script": "LATIN",
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"name": "Jannat Rahmani",
"countryIso2": "IN",
"subClassification": "IN-CH",
"subClassificationAlt": "IN-PY",
"subclassificationTop": ["IN-CH", "IN-PY", "IN-UP", "IN-AN", "IN-RJ", "IN-JH", "IN-KL", "IN-BR", "IN-DL", "IN-UT"],
"score": 2.5087208339960445,
"probabilityCalibrated": 0.3684249074494664,
"probabilityAltCalibrated": 0.4738687735374875
}
]
}
Subclassification Indian Full Name code sample for javascript:
const response = await fetch("https://v2.namsor.com/NamSorAPIv2/api2/json/subclassificationIndianFullBatch", {
"method": "POST",
"headers": {
"X-API-KEY": "your-api-key",
"Accept": "application/json",
"Content-Type": "application/json"
},
"body": JSON.stringify({
"personalNames": [
{
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"name": "Jannat Rahmani"
}
]
})
});
if (response.ok) {
const data = await response.json(); // Extract JSON data from response
console.log(data); // View data in the console
} else {
console.error("The request failed with status:", response.status, response);
}
Body parameter:
{
"personalNames": [
{
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"name": "Jannat Rahmani"
}
]
}
The above command returns JSON structured like this:
{
"personalNames": [
{
"script": "LATIN",
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"name": "Jannat Rahmani",
"countryIso2": "IN",
"subClassification": "IN-CH",
"subClassificationAlt": "IN-PY",
"subclassificationTop": ["IN-CH", "IN-PY", "IN-UP", "IN-AN", "IN-RJ", "IN-JH", "IN-KL", "IN-BR", "IN-DL", "IN-UT"],
"score": 2.5087208339960445,
"probabilityCalibrated": 0.3684249074494664,
"probabilityAltCalibrated": 0.4738687735374875
}
]
}
Precision: Cost: 10 credits per name .Description: Returns the most likely Indian State or Union territory of residence of an unsplit full name.For requests with a GET method all parameters are required . For more ease in the use of our requests we recommend that you use the POST method.
HTTP request GET https://v2.namsor.com/NamSorAPIv2/api2/json/subclassificationIndianFull/{name}
Request header Property Required Description X-API-KEY
Required Your Namsor's services API key
Request parameters Name Type Required Description name
String Required Unsplit full name (first name and last name) .
Response Name Type Description Enumerators script
String Name of the script used for the name, in ISO 15924 format. Script id
String Provided unique identifier. name
String Submitted full name. countryIso2
String Most likely country of residence, in ISO 3166-1 alpha-2 format. Country of residence subClassification
String Most likely Indian State or Union territory of residence, in ISO 3166-2 alpha-2 format. Indian subdivision subClassificationAlt
String Second most likely Indian State or Union territory of residence, in ISO 3166-2 alpha-2 format. Indian subdivision subclassificationTop
Array Top 10 most likely Indian State or Union territory of residence, sorted from most likely to least likely. Indian subdivision score
Number Higher implies a more reliable result, score is not normalized. probabilityCalibrated
Number The calibrated probability for subClassification to have been guessed correctly. -1 = still calibrating. probabilityAltCalibrated
Number The calibrated probability for subClassification OR subClassificationAlt to have been guessed correctly. -1 = still calibrating.
Code sample: Shell Java PythonJavaScript JS Subclassification Indian Full Name code sample for shell:
curl --request GET \
--url https://v2.namsor.com/NamSorAPIv2/api2/json/subclassificationIndianFull/Jannat%20Rahmani \
--header 'X-API-KEY: your-api-key' \
--header 'Accept: application/json'
The above command returns JSON structured like this:
{
"script": "LATIN",
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"name": "Jannat Rahmani",
"countryIso2": "IN",
"subClassification": "IN-CH",
"subClassificationAlt": "IN-PY",
"subclassificationTop": ["IN-CH", "IN-PY", "IN-UP", "IN-AN", "IN-RJ", "IN-JH", "IN-KL", "IN-BR", "IN-DL", "IN-UT"],
"score": 2.5087208339960445,
"probabilityCalibrated": 0.3684249074494664,
"probabilityAltCalibrated": 0.4738687735374875
}
Subclassification Indian Full Name code sample for java:
HttpResponse<String> response = Unirest.get("https://v2.namsor.com/NamSorAPIv2/api2/json/subclassificationIndianFull/Jannat%20Rahmani")
.header("X-API-KEY", "your-api-key")
.header("Accept", "application/json")
.asString();
The above command returns JSON structured like this:
{
"script": "LATIN",
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"name": "Jannat Rahmani",
"countryIso2": "IN",
"subClassification": "IN-CH",
"subClassificationAlt": "IN-PY",
"subclassificationTop": ["IN-CH", "IN-PY", "IN-UP", "IN-AN", "IN-RJ", "IN-JH", "IN-KL", "IN-BR", "IN-DL", "IN-UT"],
"score": 2.5087208339960445,
"probabilityCalibrated": 0.3684249074494664,
"probabilityAltCalibrated": 0.4738687735374875
}
Subclassification Indian Full Name code sample for python:
import requests
url = "https://v2.namsor.com/NamSorAPIv2/api2/json/subclassificationIndianFull/Jannat%20Rahmani"
headers = {
"X-API-KEY": "your-api-key",
"Accept": "application/json"
}
response = requests.request("GET", url, headers=headers)
print(response.text)
The above command returns JSON structured like this:
{
"script": "LATIN",
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"name": "Jannat Rahmani",
"countryIso2": "IN",
"subClassification": "IN-CH",
"subClassificationAlt": "IN-PY",
"subclassificationTop": ["IN-CH", "IN-PY", "IN-UP", "IN-AN", "IN-RJ", "IN-JH", "IN-KL", "IN-BR", "IN-DL", "IN-UT"],
"score": 2.5087208339960445,
"probabilityCalibrated": 0.3684249074494664,
"probabilityAltCalibrated": 0.4738687735374875
}
Subclassification Indian Full Name code sample for javascript:
const response = await fetch("https://v2.namsor.com/NamSorAPIv2/api2/json/subclassificationIndianFull/Jannat%20Rahmani", {
"method": "GET",
"headers": {
"X-API-KEY": "your-api-key",
"Accept": "application/json"
}
});
if (response.ok) {
const data = await response.json(); // Extract JSON data from response
console.log(data); // View data in the console
} else {
console.error("The request failed with status:", response.status, response);
}
The above command returns JSON structured like this:
{
"script": "LATIN",
"id": "e630dda5-13b3-42c5-8f1d-648aa8a21c42",
"name": "Jannat Rahmani",
"countryIso2": "IN",
"subClassification": "IN-CH",
"subClassificationAlt": "IN-PY",
"subclassificationTop": ["IN-CH", "IN-PY", "IN-UP", "IN-AN", "IN-RJ", "IN-JH", "IN-KL", "IN-BR", "IN-DL", "IN-UT"],
"score": 2.5087208339960445,
"probabilityCalibrated": 0.3684249074494664,
"probabilityAltCalibrated": 0.4738687735374875
}