/v1/meta
Spec
Provalo dal vivo
10 chiamate gratuite al giorno — senza registrazione, senza chiave API. Passa dal gateway oanor.
Funziona. Prendi una chiave API e usala nel tuo progetto.
Ottieni una chiave APIFrammenti di codice
curl "https://api.oanor.com/truncate-api/v1/meta" \ -H "x-oanor-key: oanor_test_..."
await fetch("https://api.oanor.com/truncate-api/v1/meta", {
headers: { "x-oanor-key": "oanor_test_..." }
});
$ch = curl_init("https://api.oanor.com/truncate-api/v1/meta");
curl_setopt($ch, CURLOPT_HTTPHEADER, ["x-oanor-key: oanor_test_..."]);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
$out = curl_exec($ch);
import requests
requests.get(
"https://api.oanor.com/truncate-api/v1/meta",
headers={"x-oanor-key": "oanor_test_..."}
)
Risposta di esempio
Una risposta reale di questo endpoint, acquisita dall'ultimo health check.
{
"data": {
"name": "Truncate API",
"notes": "The ellipsis counts toward the character length. middle keeps the start and end and elides the centre (handy for long paths/IDs). Nothing is stored.",
"version": "v1",
"endpoints": [
{
"path": "/v1/truncate",
"params": {
"text": "the text (required)",
"length": "max characters (default 100)",
"ellipsis": "default …",
"position": "end|start|middle",
"preserve_words": "true/false (default true)"
},
"returns": "the truncated text"
},
{
"path": "/v1/words",
"params": {
"text": "the text (required)",
"words": "max words (default 20)",
"ellipsis": "default …"
},
"returns": "the text cut to N whole words"
},
{
"path": "/v1/meta",
"params": [],
"returns": "this document"
}
],
"description": "Truncate text cleanly. Cut to a maximum number of characters at the end, start or middle, breaking on word boundaries (so words are never chopped in half) and adding an ellipsis — or truncate to a number of whole words. Emoji-safe (counts code points, not bytes). Pure local, no key."
},
"meta": {
"timestamp": "2026-06-03T09:25:09.191Z",
"request_id": "f2ba6b39-048d-4bd8-9aaa-225e2ad2f5b7"
},
"status": "ok",
"message": "Meta",
"success": true
}