The Entaiwian Text Converter API transforms encoded text into Traditional Chinese characters through a multi-step process:
Loading...
All API endpoints are relative to this base URL.
Convert encoded text to Traditional Chinese characters.
{
"text": "c96y7ap7ji3yji4tj x96xk7",
"for_each": //True or False
}
Field | Type | Required | Description |
---|---|---|---|
text |
string | Yes | Encoded text to convert (max 1000 characters) |
{
"result": "你好世界", //for_each: True -> {'ㄋㄧˇ': [('你', 1), ('擬', 1), ('尼', 0), ('逆', 0), ('泥', 0), ('匿', 0), ('暱', 0), ('霓', 0), ('妮', 0), ('溺', 0)], 'ㄏㄠˇ': [('好', 1), ('毫', 0), ('號', 0), ('豪', 0), ('耗', 0), ('浩', 0), ('嚎', 0), ('皓', 0), ('昊', 0), ('壕', 0)], 'ㄕˋ': [('是', 1), ('市', 1), ('事', 1), ('世', 1), ('視', 1), ('時', 0), ('實', 0), ('使', 0), ('十', 0), ('失', 0)], 'ㄐㄧㄝˋ': [('介', 1), ('借', 1), ('界', 1), ('結', 0), ('解', 0), ('接', 0), ('節', 0), ('階', 0), ('街', 0), ('姐', 0)]}
"order": ['ㄋㄧˇ', 'ㄏㄠˇ', 'ㄕˋ', 'ㄐㄧㄝˋ']
"processing_time": 0.123,
"input_length": 24,
"output_length": 4
}
Field | Type | Description |
---|---|---|
result |
string || for_each: True -> {string: [(string, int)]} | Converted Traditional Chinese text |
order |
[string] | the order of zhuyin |
processing_time |
number | Time taken to process the request (seconds) |
input_length |
integer | Length of input text |
output_length |
integer | Length of converted text |
curl -X POST LOADING.../convert \
-H "Content-Type: application/json" \
-d '{"text": "c96y7ap7ji3yji4tj x96xk7"}'
const response = await fetch('LOADING.../convert', {
method: 'POST',
headers: {
'Content-Type': 'application/json',
},
body: JSON.stringify({
text: 'c96y7ap7ji3yji4tj x96xk7'
})
});
const data = await response.json();
console.log(data.result); // "你好世界"
Check the health status of the API service.
{
"status": "healthy",
"service": "Entaiwian Text Converter API",
"timestamp": 1641234567.89
}
Access this API documentation page.
HTML documentation page (this page)
Status Code | Error Type | Description | Example Response |
---|---|---|---|
400 | Bad Request | Invalid request format or missing fields | {"error": "Missing required field", "details": "Request must include 'text' field"}
|
422 | Unprocessable Entity | Conversion failed due to invalid input format | {"error": "Conversion failed", "details": "Unable to convert the provided text..."}
|
429 | Rate Limit Exceeded | Too many requests from the same IP | {"error": "Rate limit exceeded. Please try again later."} |
500 | Internal Server Error | Unexpected server error during processing | {"error": "Internal conversion error", "details": "...", "processing_time": 0.05}
|
When the rate limit is exceeded, the API will return a 429 Too Many Requests
status
code. Please implement appropriate retry logic with exponential backoff in your applications.
You can test the API using various methods:
Use cURL or similar tools to test API endpoints.
Integrate the API into your applications using HTTP libraries.
Built with Flask and Bootstrap