Make your first API request
Create a key, select an API contract, send a request, and understand the response.
Your first API call
Log in to Dashboard, choose a plan or pack and create an API key. Keys are shown once. Store yours in a secret manager or environment variable, outside source code.
Production base URL: https://api.shinrai.innovius.io
curl https://api.shinrai.innovius.io/v1/analyze \
-H "Authorization: Bearer $SHINRAI_API_KEY" \
-H "Content-Type: application/json" \
-d '{"text":"Emma Weber, emma@example.com","tier":"standard"}'
Example output (simulated)
Simulated JSON excerpt for the command above. Your detections, replacement values and balance may differ.
{
"results": [
{
"entities": [
{
"text": "Emma Weber",
"type": "PERSON",
"startIndex": 0,
"endIndex": 10,
"confidence": 0.98
},
{
"text": "emma@example.com",
"type": "EMAIL",
"startIndex": 12,
"endIndex": 28,
"confidence": 1.0
}
]
}
],
"usage": {
"records": 1,
"weighted_records": 1.0,
"tier": "standard",
"balance_after": 9999.0
}
}The response contains detected entities and their offsets, plus usage.weighted_records and the remaining balance. This short Standard request uses one record. Entity predictions and replacement names depend on the model and input.
Use your preferred client
curl https://api.shinrai.innovius.io/v1/analyze \
-H "Authorization: Bearer $SHINRAI_API_KEY" \
-H 'Content-Type: application/json' \
-d '{"text":"Emma Weber, emma@example.com"}'import os, requests
response = requests.post(
"https://api.shinrai.innovius.io/v1/analyze",
headers={"Authorization": f"Bearer {os.environ['SHINRAI_API_KEY']}"},
json={"text": "Emma Weber, emma@example.com"},
)
response.raise_for_status()
print(response.json())const response = await fetch("https://api.shinrai.innovius.io/v1/analyze", {
method: "POST",
headers: { Authorization: `Bearer ${process.env.SHINRAI_API_KEY}`, "Content-Type": "application/json" },
body: JSON.stringify({ text: "Emma Weber, emma@example.com" }),
});
if (!response.ok) throw new Error(`ShinrAI HTTP ${response.status}`);
console.log(await response.json());