Japanese Name Split API: Surname / Given Name Separation

Japanese names lack a standard separator. Torify splits full names using whitespace, a comprehensive surname dictionary, and position heuristics.

Endpoint

GET https://torify.dev/v1/name/split

Parameters

NameTypeRequiredDescriptionExample
name string Yes Japanese full name 山田太郎

Response example

{ "ok": true, "data": { "surname": "山田", "givenName": "太郎" } }

Code examples

curl

curl "https://torify.dev/v1/name/split?name=%E5%B1%B1%E7%94%B0%E5%A4%AA%E9%83%8E"

TypeScript (x402-fetch)

import { wrapFetchWithPayment } from 'x402-fetch';
import { privateKeyToAccount } from 'viem/accounts';

const account = privateKeyToAccount(process.env.PRIVATE_KEY as `0x${string}`);
const fetchWithPayment = wrapFetchWithPayment(fetch, account);

const res = await fetchWithPayment(
  'https://torify.dev/v1/name/split?name=%E5%B1%B1%E7%94%B0%E5%A4%AA%E9%83%8E'
);
const data = await res.json();
console.log(data); // { ok: true, data: { ... } }

Python (requests)

import requests

# Free MCP tier (no auth) or API key (X-API-Key header)
res = requests.get(
    "https://torify.dev/v1/name/split?name=%E5%B1%B1%E7%94%B0%E5%A4%AA%E9%83%8E",
    headers={"X-API-Key": "your_torify_pro_key"}
)
print(res.json())

Related endpoints

← All 39 endpoints

Pricing

$0.02 per call via x402 (USDC on Base). Or use a Pro API key ($49/mo, 10,000 calls/month).