Data Integrity System
Clean, validate, and standardize user input at the source
Stop bad data before it enters your database. Normalize text, validate inputs, and moderate content in a single API call.
Get API keyEngine
Data Integrity Engine
Validate, normalize, and safety-check a full set of user inputs in one call. No separate endpoints for each field type.
{
"email": " [email protected] ",
"phone": "004915123456789",
"text": "This is some user-generated content"
}
{
"email": {
"valid": true,
"normalized": "[email protected]",
"disposable": false
},
"phone": {
"valid": true,
"normalized": "+4915123456789",
"country": "DE"
},
"text": {
"is_safe": true,
"toxicity_score": 0.01,
"sentiment": "neutral"
}
}
Bad data compounds silently: bad emails bounce, invalid phones fail, toxic content slips through. The Data Integrity Engine catches and normalizes bad input at the boundary of your product, before it reaches your database or downstream services, without requiring separate calls for each field type.
API Reference
Base URL: https://requiems.xyz
Overview
Use Cases
- Validate and normalize email, phone, and text fields on form submission
- Filter profanity, toxic content, and off-policy text in user-generated content
- Clean and standardize records in bulk import or data migration flows
- Pre-process and validate user input before passing to LLM workflows
- Enforce text quality standards without building custom validation logic
Features
API Endpoints
Batch Input Validate
Validates and scores a batch of up to 50 contact records in a single request. Each record is processed independently β one item failing does not affect others. Returns per-item email, phone, and text validation results with quality scores, normalized values, plus batch-level aggregates including total, valid_count, invalid_count, and average_quality_score.
https://requiems.xyz/v1/systems/input/validate/batch
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
| items | array<object> |
Required | Array of contact records to validate. Each item must include email and phone. Text is optional. Min: 1, Max: 50. |
Try it out
Live DemoRequest
Array of contact records to validate. Each item must include email and phone. Text is optional. Min: 1, Max: 50.
Response Fields
| Field | Type | Description |
|---|---|---|
| results | array<object> |
List of validation results, one per input item. Preserves the original submission order via the index field. |
| results[].index | integer |
Zero-based position of the item in the original request array. |
| results[].email | object |
Email validation result. Null when email was not provided for this item. |
| results[].email.valid | boolean |
True when the email passes syntax and MX validation. |
| results[].email.normalized | string |
Normalized form of the email address. Null when syntax is invalid. |
| results[].email.quality_score | number |
Email quality score from 0.0 to 1.0. Penalized by invalidity, disposable domain, and suggestions. |
| results[].email.disposable | boolean |
True when the email domain is a known disposable or temporary provider. |
| results[].phone | object |
Phone validation result. Null when phone was not provided for this item. |
| results[].phone.valid | boolean |
True when the phone number is valid and dialable. |
| results[].phone.normalized | string |
Normalized phone number in international format. Null when the number is invalid. |
| results[].phone.quality_score | number |
Phone quality score from 0.0 to 1.0. Penalized by invalidity, VoIP, virtual, landline, and unknown type. |
| results[].text | object |
Text analysis result. Null when text was not provided for this item. |
| results[].overall_quality_score | number |
Weighted quality score from 0.0 to 1.0 combining email and phone fields only. Weights are email 0.5 and phone 0.4, adjusted proportionally when one field is absent. Text does not currently contribute to this score β scoring will be enabled once toxicity_score is available from the sentiment service. Returns 0.0 when only text is provided. |
| results[].error | string |
Error message when this item could not be processed due to an unexpected failure, such as a service timeout or malformed input. Null when the item was processed successfully, regardless of whether the fields passed validation or not. |
| total | integer |
Total number of items in the batch. |
| valid_count | integer |
Number of items where all provided fields have valid set to true. |
| invalid_count | integer |
Number of items where at least one provided field has valid set to false, or where processing failed due to a timeout or unexpected error. |
| average_quality_score | number |
Average of overall_quality_score across all successfully processed items. Items that failed due to a timeout or unexpected error are excluded from this average. |
Code Examples
curl -X POST https://requiems.xyz/v1/systems/input/validate/batch \
-H "requiems-api-key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"items": [
{"email": "[email protected]", "phone": "+12015551001"},
{"email": "[email protected]", "phone": "+12015551002"},
{"email": "[email protected]", "phone": "+12015551003"}
]
}'
import requests
response = requests.post(
"https://requiems.xyz/v1/systems/input/validate/batch",
headers={"requiems-api-key": "YOUR_API_KEY"},
json={
"items": [
{"email": "[email protected]", "phone": "+12015551001"},
{"email": "[email protected]", "phone": "+12015551002"},
{"email": "[email protected]", "phone": "+12015551003"}
]
}
)
data = response.json()["data"]
print(f"Total: {data['total']} | Valid: {data['valid_count']} | Invalid: {data['invalid_count']}")
print(f"Average quality score: {data['average_quality_score']}")
for item in data["results"]:
print(f"\n[{item['index']}]")
if item.get("error"):
print(f" Error: {item['error']}")
continue
if item.get("email"):
print(f" Email valid: {item['email']['valid']} | Score: {item['email']['quality_score']}")
if item.get("phone"):
print(f" Phone valid: {item['phone']['valid']} | Score: {item['phone']['quality_score']}")
print(f" Overall quality score: {item['overall_quality_score']}")
const { data } = await fetch('https://requiems.xyz/v1/systems/input/validate/batch', {
method: 'POST',
headers: { 'requiems-api-key': 'YOUR_API_KEY', 'Content-Type': 'application/json' },
body: JSON.stringify({
items: [
{ email: '[email protected]', phone: '+12015551001' },
{ email: '[email protected]', phone: '+12015551002' },
{ email: '[email protected]', phone: '+12015551003' }
]
})
}).then(r => r.json());
console.log(`Total: ${data.total} | Valid: ${data.valid_count} | Invalid: ${data.invalid_count}`);
console.log(`Average quality score: ${data.average_quality_score}`);
for (const item of data.results) {
console.log(`\n[${item.index}]`);
if (item.error) { console.log(` Error: ${item.error}`); continue; }
if (item.email) console.log(` Email valid: ${item.email.valid} | Score: ${item.email.quality_score}`);
if (item.phone) console.log(` Phone valid: ${item.phone.valid} | Score: ${item.phone.quality_score}`);
console.log(` Overall quality score: ${item.overall_quality_score}`);
}
require 'net/http'
require 'json'
uri = URI('https://requiems.xyz/v1/systems/input/validate/batch')
request = Net::HTTP::Post.new(uri)
request['requiems-api-key'] = 'YOUR_API_KEY'
request['Content-Type'] = 'application/json'
request.body = {
items: [
{ email: '[email protected]', phone: '+12015551001' },
{ email: '[email protected]', phone: '+12015551002' },
{ email: '[email protected]', phone: '+12015551003' }
]
}.to_json
response = Net::HTTP.start(uri.hostname, uri.port, use_ssl: true) { |h| h.request(request) }
data = JSON.parse(response.body)['data']
puts "Total: #{data['total']} | Valid: #{data['valid_count']} | Invalid: #{data['invalid_count']}"
puts "Average quality score: #{data['average_quality_score']}"
data['results'].each do |item|
puts "\n[#{item['index']}]"
if item['error']
puts " Error: #{item['error']}"
next
end
puts " Email valid: #{item['email']['valid']} | Score: #{item['email']['quality_score']}" if item['email']
puts " Phone valid: #{item['phone']['valid']} | Score: #{item['phone']['quality_score']}" if item['phone']
puts " Overall quality score: #{item['overall_quality_score']}"
end
Error Responses
validation_failed
The request body is invalid.
unauthorized
Missing or invalid API key.
Input Validate
Validates and scores a single email address, phone number, or text input β or any combination of the three. Returns per-field quality scores, normalized values, risk flags, and an overall quality score for gating or enriching input data.
https://requiems.xyz/v1/systems/input/validate
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
string |
Optional | The email address to validate. At least one of email, phone, or text must be provided. | |
| phone | string |
Optional | The phone number to validate. Must include country code in E.164 format. At least one of email, phone, or text must be provided. |
| text | string |
Optional | The text content to analyze for profanity, toxicity, and sentiment. At least one of email, phone, or text must be provided. |
Try it out
Live DemoRequest
The email address to validate. At least one of email, phone, or text must be provided.
The phone number to validate. Must include country code in E.164 format. At least one of email, phone, or text must be provided.
The text content to analyze for profanity, toxicity, and sentiment. At least one of email, phone, or text must be provided.
Response Fields
| Field | Type | Description |
|---|---|---|
object |
Email validation result. Null when email was not provided. | |
| email.valid | boolean |
True when the email passes syntax and MX validation. |
| email.normalized | string |
Normalized form of the email address. Null when syntax is invalid. |
| email.original | string |
The original email address as provided in the request. |
| email.syntax_valid | boolean |
True when the email address has a valid structure. |
| email.mx_valid | boolean |
True when the email domain has valid MX records. |
| email.disposable | boolean |
True when the email domain is a known disposable or temporary provider. |
| email.suggestion | string |
Suggested correction when a typo is detected in the domain (e.g. gmial.com β gmail.com). Null otherwise. |
| email.flags | array<string> |
Triggered flags. Possible values: email_syntax_invalid, email_mx_invalid, email_disposable, email_has_suggestion. |
| email.quality_score | number |
Email quality score from 0.0 to 1.0. Penalized by invalidity, disposable domain, and suggestions. |
| phone | object |
Phone validation result. Null when phone was not provided. |
| phone.valid | boolean |
True when the phone number is valid and dialable. |
| phone.normalized | string |
Normalized phone number in international format. Null when the number is invalid. |
| phone.country | string |
ISO 3166-1 alpha-2 country code detected from the number (e.g. US, CO). Null when the number is invalid. |
| phone.type | string |
Line type. Null when the number is invalid. Possible values: mobile, landline, voip, toll_free, unknown. |
| phone.carrier | object |
Carrier information. Null when not available. |
| phone.carrier.name | string |
Name of the carrier or operator associated with the number. |
| phone.risk | object |
Risk signals associated with the phone number. Null when the validator could not determine risk information. |
| phone.risk.is_voip | boolean |
True when the number is confirmed as a VoIP line. False when explicitly confirmed as non-VoIP. |
| phone.risk.is_virtual | boolean |
True when the number is confirmed as a virtual number. False when explicitly confirmed as non-virtual. |
| phone.flags | array<string> |
Triggered flags. Possible values: phone_invalid, phone_voip, phone_virtual, phone_unknown_type, phone_landline. |
| phone.quality_score | number |
Phone quality score from 0.0 to 1.0. Penalized by invalidity, VoIP, virtual, landline, and unknown type. |
| text | object |
Text analysis result. Null when text was not provided. |
| text.is_safe | boolean |
False when any moderation flag is triggered. True otherwise. |
| text.toxicity_score | number |
Reserved for future use. Currently always null. |
| text.sentiment | string |
Detected sentiment: positive, negative, or neutral. |
| text.flags | array<string> |
Triggered moderation flags. Possible values: text_profanity. |
| overall_quality_score | number |
Weighted quality score from 0.0 to 1.0 combining email and phone fields only. Weights are email 0.5 and phone 0.4, adjusted proportionally when one field is absent. Text does not currently contribute to this score β scoring will be enabled once toxicity_score is available from the sentiment service. Returns 0.0 when only text is provided. |
Code Examples
curl -X POST https://requiems.xyz/v1/systems/input/validate \
-H "requiems-api-key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{"email": "[email protected]", "phone": "+12015551234", "text": "I just wanted to say that your customer service team was incredibly helpful."}'
import requests
response = requests.post(
"https://requiems.xyz/v1/systems/input/validate",
headers={"requiems-api-key": "YOUR_API_KEY"},
json={
"email": "[email protected]",
"phone": "+12015551234",
"text": "I just wanted to say that your customer service team was incredibly helpful."
}
)
data = response.json()["data"]
if data.get("email"):
print("Email valid:", data["email"]["valid"], "| Score:", data["email"]["quality_score"])
if data.get("phone"):
print("Phone valid:", data["phone"]["valid"], "| Score:", data["phone"]["quality_score"])
if data.get("text"):
print("Text safe:", data["text"]["is_safe"], "| Sentiment:", data["text"]["sentiment"])
print("Overall quality score:", data["overall_quality_score"])
const { data } = await fetch('https://requiems.xyz/v1/systems/input/validate', {
method: 'POST',
headers: { 'requiems-api-key': 'YOUR_API_KEY', 'Content-Type': 'application/json' },
body: JSON.stringify({
email: '[email protected]',
phone: '+12015551234',
text: 'I just wanted to say that your customer service team was incredibly helpful.'
})
}).then(r => r.json());
if (data.email) console.log('Email valid:', data.email.valid, '| Score:', data.email.quality_score);
if (data.phone) console.log('Phone valid:', data.phone.valid, '| Score:', data.phone.quality_score);
if (data.text) console.log('Text safe:', data.text.is_safe, '| Sentiment:', data.text.sentiment);
console.log('Overall quality score:', data.overall_quality_score);
require 'net/http'
require 'json'
uri = URI('https://requiems.xyz/v1/systems/input/validate')
request = Net::HTTP::Post.new(uri)
request['requiems-api-key'] = 'YOUR_API_KEY'
request['Content-Type'] = 'application/json'
request.body = {
email: '[email protected]',
phone: '+12015551234',
text: 'I just wanted to say that your customer service team was incredibly helpful.'
}.to_json
response = Net::HTTP.start(uri.hostname, uri.port, use_ssl: true) { |h| h.request(request) }
data = JSON.parse(response.body)['data']
puts "Email valid: #{data['email']['valid']} | Score: #{data['email']['quality_score']}" if data['email']
puts "Phone valid: #{data['phone']['valid']} | Score: #{data['phone']['quality_score']}" if data['phone']
puts "Text safe: #{data['text']['is_safe']} | Sentiment: #{data['text']['sentiment']}" if data['text']
puts "Overall quality score: #{data['overall_quality_score']}"
Error Responses
validation_failed
All fields (email, phone, text) are absent or empty. At least one must be provided.
unauthorized
Missing or invalid API key.
Moderate Content
Check text for profanity, toxicity, sentiment, and language. Returns per-category flags and an is_safe boolean for gating content.
https://requiems.xyz/v1/systems/content/moderate
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
| text | string |
Required | The text to moderate. Any language. Required. |
| language | string |
Optional | ISO 639-1 language code (e.g. en, de, fr). When provided, language detection is skipped and confidence is set to 1.0. |
Try it out
Live DemoRequest
The text to moderate. Any language. Required.
ISO 639-1 language code (e.g. en, de, fr). When provided, language detection is skipped and confidence is set to 1.0.
Response Fields
| Field | Type | Description |
|---|---|---|
| is_safe | boolean |
False when any moderation category is triggered. True otherwise. |
| toxicity_score | number |
Reserved for future use. Currently always null. |
| sentiment | string |
Detected sentiment: positive, negative, or neutral |
| language | string |
Detected or provided ISO 639-1 language code. Null when detection confidence is 0. |
| language_confidence | number |
Confidence in the detected language from 0.0 to 1.0. 1.0 when language was explicitly provided. |
| flags | array<string> |
Triggered moderation flags. Currently possible: text_profanity |
| categories | object |
Per-category boolean flags: profanity, hate_speech, spam, violence |
Code Examples
curl -X POST https://requiems.xyz/v1/systems/content/moderate \
-H "requiems-api-key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{"text": "This is some user-generated content.", "language": "en"}'
import requests
response = requests.post(
"https://requiems.xyz/v1/systems/content/moderate",
headers={"requiems-api-key": "YOUR_API_KEY"},
json={"text": "This is some user-generated content.", "language": "en"}
)
data = response.json()["data"]
if not data["is_safe"]:
print("Content blocked. Flags:", data["flags"])
print("Categories:", {k: v for k, v in data["categories"].items() if v})
else:
print(f"Safe. Sentiment: {data['sentiment']}")
const { data } = await fetch('https://requiems.xyz/v1/systems/content/moderate', {
method: 'POST',
headers: { 'requiems-api-key': 'YOUR_API_KEY', 'Content-Type': 'application/json' },
body: JSON.stringify({ text: 'This is some user-generated content.', language: 'en' })
}).then(r => r.json());
if (!data.is_safe) {
console.warn('Content blocked:', data.flags);
} else {
console.log('Sentiment:', data.sentiment);
}
require 'net/http'
require 'json'
uri = URI('https://requiems.xyz/v1/systems/content/moderate')
request = Net::HTTP::Post.new(uri)
request['requiems-api-key'] = 'YOUR_API_KEY'
request['Content-Type'] = 'application/json'
request.body = { text: 'This is some user-generated content.', language: 'en' }.to_json
response = Net::HTTP.start(uri.hostname, uri.port, use_ssl: true) { |h| h.request(request) }
data = JSON.parse(response.body)['data']
puts data['is_safe'] ? "Safe. Sentiment: #{data['sentiment']}" : "Blocked: #{data['flags'].inspect}"
Error Responses
validation_failed
text field is missing or empty
unauthorized
Missing or invalid API key
Normalize Text
Apply a composable pipeline of normalization operations to a string. Trim whitespace, fix encoding, normalize unicode, strip HTML, and more β in a single call.
https://requiems.xyz/v1/systems/text/normalize
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
| text | string |
Required | The text to normalize. Required. |
| operations | array<string> |
Required | Ordered list of normalization operations to apply. At least one required. Valid values: trim, lowercase, uppercase, normalize_unicode, collapse_whitespace, strip_html, remove_punctuation |
Try it out
Live DemoRequest
The text to normalize. Required.
Ordered list of normalization operations to apply. At least one required. Valid values: trim, lowercase, uppercase, normalize_unicode, collapse_whitespace, strip_html, remove_punctuation
Response Fields
| Field | Type | Description |
|---|---|---|
| original | string |
The input text as provided |
| normalized | string |
The text after all operations have been applied in order |
| operations | array<string> |
The operations list echoed from the request |
Code Examples
curl -X POST https://requiems.xyz/v1/systems/text/normalize \
-H "requiems-api-key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"text": " Hello, World! ",
"operations": ["trim", "lowercase", "collapse_whitespace"]
}'
import requests
response = requests.post(
"https://requiems.xyz/v1/systems/text/normalize",
headers={"requiems-api-key": "YOUR_API_KEY"},
json={
"text": " Hello, World! ",
"operations": ["trim", "lowercase", "collapse_whitespace"]
}
)
data = response.json()["data"]
print(data["normalized"]) # hello, world!
const { data } = await fetch('https://requiems.xyz/v1/systems/text/normalize', {
method: 'POST',
headers: { 'requiems-api-key': 'YOUR_API_KEY', 'Content-Type': 'application/json' },
body: JSON.stringify({
text: ' Hello, World! ',
operations: ['trim', 'lowercase', 'collapse_whitespace']
})
}).then(r => r.json());
console.log(data.normalized); // hello, world!
require 'net/http'
require 'json'
uri = URI('https://requiems.xyz/v1/systems/text/normalize')
request = Net::HTTP::Post.new(uri)
request['requiems-api-key'] = 'YOUR_API_KEY'
request['Content-Type'] = 'application/json'
request.body = {
text: ' Hello, World! ',
operations: %w[trim lowercase collapse_whitespace]
}.to_json
response = Net::HTTP.start(uri.hostname, uri.port, use_ssl: true) { |h| h.request(request) }
data = JSON.parse(response.body)['data']
puts data['normalized'] # hello, world!
Error Responses
validation_failed
text is empty or operations array is empty or missing
unauthorized
Missing or invalid API key
Domain Trust
Evaluate the trustworthiness of a domain by analyzing DNS records, WHOIS registration data, and MX configuration β in a single call.
https://requiems.xyz/v1/systems/domain/trust/{domain}
Parameters
| Name | Type | Required | Description |
|---|---|---|---|
| domain | string |
Required | The domain name to evaluate for trust. Must be a valid domain format (e.g. github.com). |
Try it out
Live DemoRequest
The domain name to evaluate for trust. Must be a valid domain format (e.g. github.com).
Response Fields
| Field | Type | Description |
|---|---|---|
| domain | string |
The domain name that was evaluated. |
| trust_score | number |
Computed trust score between 0.0 and 1.0. Starts at 1.0 with penalties applied based on domain signals. |
| trust_level | string |
Coarse trust label derived from the score. Possible values are "high" (>= 0.75), "medium" (0.4 - 0.74), or "low" (< 0.4). |
| who_is | object |
WHOIS registration data for the domain. Omitted from the response if WHOIS is unavailable for the TLD or if the domain is not registered. |
| who_is.registrar | string |
The registrar where the domain was registered. |
| who_is.created_at | string |
The date the domain was first registered in RFC3339 format. |
| who_is.expires_at | string |
The date the domain registration expires in RFC3339 format. |
| who_is.age_days | integer |
Number of days since the domain was registered. |
| who_is.status | array<string> |
WHOIS status codes indicating the domain transfer and update permissions. |
| dns | object |
DNS health check results for the domain. Fields default to false if the domain is not registered. |
| dns.has_a_records | boolean |
True if the domain has at least one A record pointing to an IP address. |
| dns.has_mx_records | boolean |
True if the domain has MX records configured for receiving email. |
| dns.has_ns_records | boolean |
True if the domain has NS records indicating it is delegated to a nameserver. |
| dns.available | boolean |
True if the domain is unregistered and available for purchase. When true, trust_score is 0.0 and evaluation stops immediately. |
| mx_records | array<object> |
List of MX records found for the domain. Empty array if none exist or if the domain is not registered. |
| mx_records[].host_name | string |
The hostname of the mail server. |
| mx_records[].priority | integer |
Mail server priority. Lower value means higher priority. |
| flags | array<string> |
List of signal flags raised during evaluation. Possible values are "new_domain", "young_domain", "no_mx", "no_a_records", "no_ns_records", "expiring_soon", "whois_unavailable", "domain_not_registered". Only "domain_not_registered" is returned when the domain is not registered. |
Code Examples
curl -X GET https://requiems.xyz/v1/systems/domain/trust/github.com \
-H "requiems-api-key: YOUR_API_KEY"
import requests
response = requests.get(
"https://requiems.xyz/v1/systems/domain/trust/github.com",
headers={"requiems-api-key": "YOUR_API_KEY"}
)
data = response.json()["data"]
print(f"Domain: {data['domain']}")
print(f"Trust Score: {data['trust_score']} ({data['trust_level']})")
if data["flags"]:
print("Flags:", data["flags"])
else:
print("No issues found.")
if data["who_is"]:
print(f"Registrar: {data['who_is']['registrar']}")
print(f"Age: {data['who_is']['age_days']} days")
const { data } = await fetch('https://requiems.xyz/v1/systems/domain/trust/github.com', {
headers: { 'requiems-api-key': 'YOUR_API_KEY' }
}).then(r => r.json());
console.log(`Domain: ${data.domain}`);
console.log(`Trust Score: ${data.trust_score} (${data.trust_level})`);
if (data.flags.length > 0) {
console.warn('Flags:', data.flags);
} else {
console.log('No issues found.');
}
if (data.who_is) {
console.log(`Registrar: ${data.who_is.registrar}`);
console.log(`Age: ${data.who_is.age_days} days`);
}
require 'net/http'
require 'json'
uri = URI('https://requiems.xyz/v1/systems/domain/trust/github.com')
request = Net::HTTP::Get.new(uri)
request['requiems-api-key'] = 'YOUR_API_KEY'
response = Net::HTTP.start(uri.hostname, uri.port, use_ssl: true) { |h| h.request(request) }
data = JSON.parse(response.body)['data']
puts "Domain: #{data['domain']}"
puts "Trust Score: #{data['trust_score']} (#{data['trust_level']})"
puts data['flags'].empty? ? "No issues found." : "Flags: #{data['flags'].inspect}"
puts "Registrar: #{data['who_is']['registrar']}, Age: #{data['who_is']['age_days']} days" if data['who_is']
Error Responses
Invalid or malformed domain value in the request path.
Frequently Asked Questions
All-in-one backend for SaaS products
Authentication, validation, fraud detection, payments intelligence, and global data, delivered through one unified API.