Everything you need to integrate the RichAPI API into your product.
Normalize a messy URL or domain string to a clean root domain (e.g. https://www.acme.com/page → acme.com).
/api/v1/clean_domainParameters
| Field | Type | Required | Description |
|---|---|---|---|
messy_url | string | Yes | URL or domain to normalize (e.g. https://www.Example.COM/page?q=1) |
Response fields
| Field | Type | Description |
|---|---|---|
domain | string | Clean root domain (e.g. acme.com) |
Code
curl -X POST https://api.richapi.ai/api/v1/clean_domain \
-H "x-api-key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"messy_url": "https://www.acme.com/about?ref=google"
}'Try it
Sign in to test this endpoint with your API key.
Sign in to tryParse and normalize a phone number to E.164 format with optional country code hint.
/api/v1/normalize_phoneParameters
| Field | Type | Required | Description |
|---|---|---|---|
phone_number | string | Yes | Phone number to normalize (any format) |
country_code | string | No | ISO country code hint (e.g. US) |
Response fields
| Field | Type | Description |
|---|---|---|
e164 | string | Normalized phone number in E.164 format (e.g. +14155551234) |
national | string | Formatted national number (e.g. (415) 555-1234) |
country | string | Detected country code |
valid | boolean | Whether the number is valid |
Code
curl -X POST https://api.richapi.ai/api/v1/normalize_phone \
-H "x-api-key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"country_code": "US",
"phone_number": "(415) 555-1234"
}'Try it
Sign in to test this endpoint with your API key.
Sign in to tryExtract all URLs and email addresses from a block of text.
/api/v1/extract_urls_emailsParameters
| Field | Type | Required | Description |
|---|---|---|---|
text | string | Yes | Text block to extract URLs and emails from |
Response fields
| Field | Type | Description |
|---|---|---|
emails | array | List of email addresses found in the text |
urls | array | List of URLs found in the text |
Code
curl -X POST https://api.richapi.ai/api/v1/extract_urls_emails \
-H "x-api-key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"text": "Contact us at hello@acme.com or visit https://acme.com"
}'Try it
Sign in to test this endpoint with your API key.
Sign in to tryFollow a URL through all redirects and return the final destination URL.
/api/v1/find_redirectParameters
| Field | Type | Required | Description |
|---|---|---|---|
link | string | Yes | URL to follow through all redirects to the final destination |
Response fields
| Field | Type | Description |
|---|---|---|
final_url | string | Final destination URL after all redirects |
redirect_chain | array | List of intermediate URLs in the redirect chain |
status_code | integer | Final HTTP status code |
Code
curl -X POST https://api.richapi.ai/api/v1/find_redirect \
-H "x-api-key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"link": "https://bit.ly/example"
}'Try it
Sign in to test this endpoint with your API key.
Sign in to tryClassify an email address as personal, business, role-based, or disposable.
/api/v1/identify_email_typeParameters
| Field | Type | Required | Description |
|---|---|---|---|
email | string | Yes | Email address to classify |
Response fields
| Field | Type | Description |
|---|---|---|
type | string | Email type: personal, business, role, or disposable |
domain | string | Email domain |
Code
curl -X POST https://api.richapi.ai/api/v1/identify_email_type \
-H "x-api-key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"email": "john.doe@gmail.com"
}'Try it
Sign in to test this endpoint with your API key.
Sign in to tryClean and normalize a company name by removing legal suffixes, extra whitespace, and punctuation.
/api/v1/normalize_companyParameters
| Field | Type | Required | Description |
|---|---|---|---|
company_name | string | Yes | Company name to normalize (e.g. ACME TECHNOLOGIES, INC.) |
normalize_case | boolean | No | Convert to title case (default true) |
Response fields
| Field | Type | Description |
|---|---|---|
normalized | string | Cleaned company name with legal suffixes and punctuation removed |
Code
curl -X POST https://api.richapi.ai/api/v1/normalize_company \
-H "x-api-key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"company_name": "ACME TECHNOLOGIES, INC."
}'Try it
Sign in to test this endpoint with your API key.
Sign in to tryPredict the gender of a person from their first name.
/api/v1/predict_genderParameters
| Field | Type | Required | Description |
|---|---|---|---|
name | string | Yes | First name to predict gender for |
Response fields
| Field | Type | Description |
|---|---|---|
gender | string | Predicted gender: male, female, or unknown |
confidence | number | Confidence score (0-1) |
Code
curl -X POST https://api.richapi.ai/api/v1/predict_gender \
-H "x-api-key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"name": "Jordan"
}'Try it
Sign in to test this endpoint with your API key.
Sign in to tryParse and reformat a date/time string with optional timezone conversion and locale.
/api/v1/format_datetimeParameters
| Field | Type | Required | Description |
|---|---|---|---|
date | string | Yes | Date/time string to parse (ISO 8601 or common formats) |
format | string | No | strftime format string for output (e.g. %B %d, %Y) |
original_timezone | string | No | Timezone of the input date (e.g. UTC) |
new_timezone | string | No | Target timezone for output (e.g. America/New_York) |
locale | string | No | Locale for month/day names (e.g. en, fr) |
Response fields
| Field | Type | Description |
|---|---|---|
formatted | string | Reformatted date/time string |
iso | string | ISO 8601 representation of the parsed date/time |
timezone | string | Timezone used for the output |
Code
curl -X POST https://api.richapi.ai/api/v1/format_datetime \
-H "x-api-key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"date": "2026-04-11T14:30:00Z",
"format": "%B %d, %Y",
"new_timezone": "America/New_York"
}'Try it
Sign in to test this endpoint with your API key.
Sign in to tryURL-encode a string for safe use in query parameters or path segments.
/api/v1/encode_uriParameters
| Field | Type | Required | Description |
|---|---|---|---|
value | string | Yes | String to URL-encode (RFC 3986) |
Response fields
| Field | Type | Description |
|---|---|---|
encoded | string | URL-encoded output string |
Code
curl -X POST https://api.richapi.ai/api/v1/encode_uri \
-H "x-api-key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"value": "hello world & foo=bar"
}'Try it
Sign in to test this endpoint with your API key.
Sign in to tryDiscover and filter URLs from a domain's sitemap by keyword.
/api/v1/find_sitemap_urlsParameters
| Field | Type | Required | Description |
|---|---|---|---|
domain | string | Yes | Domain to discover sitemap URLs from (e.g. stripe.com) |
keywords | string | No | Comma-separated keywords to filter URLs |
exact_match | boolean | No | Match keywords exactly (default false) |
Response fields
| Field | Type | Description |
|---|---|---|
urls | array | Filtered list of sitemap URLs matching the keyword |
total | integer | Total URLs found before filtering |
Code
curl -X POST https://api.richapi.ai/api/v1/find_sitemap_urls \
-H "x-api-key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"domain": "stripe.com",
"keywords": "pricing"
}'Try it
Sign in to test this endpoint with your API key.
Sign in to tryRound-robin distribute leads across a set of assignment labels (e.g. sales reps).
/api/v1/distribute_leadsParameters
| Field | Type | Required | Description |
|---|---|---|---|
assignment_labels | string | No | Comma-separated assignment labels (e.g. Team A,Team B,Team C) |
values_associated_with_labels | string | Yes | Comma-separated values to distribute (e.g. alice@co.com,bob@co.com) |
current_index | integer | No | Starting index for round-robin (default 0) |
Response fields
| Field | Type | Description |
|---|---|---|
assignments | array | List of {label, value} assignment pairs |
next_index | integer | Next index to use for the following batch |
Code
curl -X POST https://api.richapi.ai/api/v1/distribute_leads \
-H "x-api-key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"current_index": 0,
"assignment_labels": "Team A,Team B,Team C",
"values_associated_with_labels": "alice@co.com,bob@co.com,carol@co.com"
}'Try it
Sign in to test this endpoint with your API key.
Sign in to trySplit a delimited string into a clean list, optionally removing empty values.
/api/v1/normalize_listParameters
| Field | Type | Required | Description |
|---|---|---|---|
input | string | Yes | Delimited string to split and deduplicate |
remove_empty_values | boolean | No | Remove empty items after splitting (default false) |
Response fields
| Field | Type | Description |
|---|---|---|
list | array | Resulting list of string items |
Code
curl -X POST https://api.richapi.ai/api/v1/normalize_list \
-H "x-api-key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"input": "apple, Banana, apple, , cherry",
"remove_empty_values": true
}'Try it
Sign in to test this endpoint with your API key.
Sign in to tryStrip and collapse extra whitespace from a string.
/api/v1/remove_whitespaceParameters
| Field | Type | Required | Description |
|---|---|---|---|
input_text | string | Yes | String to strip and collapse whitespace from |
Response fields
| Field | Type | Description |
|---|---|---|
output | string | String with leading/trailing whitespace stripped and internal runs collapsed to a single space |
Code
curl -X POST https://api.richapi.ai/api/v1/remove_whitespace \
-H "x-api-key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"input_text": " hello world "
}'Try it
Sign in to test this endpoint with your API key.
Sign in to tryCount how many times a substring appears in a string, with optional case-insensitive matching.
/api/v1/count_occurrencesParameters
| Field | Type | Required | Description |
|---|---|---|---|
input | string | Yes | Input string to search within |
separator | string | Yes | Substring to count occurrences of |
case_insensitive | boolean | No | Case-insensitive matching (default false) |
limit | integer | No | Max results to return (0 for all, max 1000) |
Response fields
| Field | Type | Description |
|---|---|---|
count | integer | Number of times the separator appears in the input |
Code
curl -X POST https://api.richapi.ai/api/v1/count_occurrences \
-H "x-api-key: YOUR_API_KEY" \
-H "Content-Type: application/json" \
-d '{
"input": "foo bar foo baz",
"separator": "foo"
}'Try it
Sign in to test this endpoint with your API key.
Sign in to try