Ungültiges Dokument für die Schätzung
Bei diesem Problem antwortet die API mit 422 Unprocessable Content. Der Wert von type ist https://lingo.dev/docs/api/errors/estimate-document-invalid. Unter Fehler und Statuscodes findest du die gemeinsame Struktur aller Fehler.
Für <documentKey> kann keine Schätzung erstellt werden: Der Quelltext lässt sich nicht im Dokumentformat parsen. Korrigiere den Quelltext oder schließe das Dokument von der Schätzung aus.
Felder#
Neben den Standardfeldern type, status, title und detail enthält der Antwortkörper die folgenden Felder. Aus ihnen wird der Text in detail erstellt. So kann ein Client stattdessen einen eigenen Text anzeigen.
| Feld | Typ |
|---|---|
documentKey | string |
reason | "sourceUnparseable" | "previousSourceUnparseable" | "translationUnparseable" | "translationMisaligned" | "translationInvalid" |
locale | string |
Beispiel#
json
{
"detail": "Cannot estimate <documentKey>: its source does not parse in the document's format. Fix the source, or leave it out of the estimate.",
"documentKey": "<documentKey>",
"reason": "sourceUnparseable",
"locale": "pt-BR",
"type": "https://lingo.dev/docs/api/errors/estimate-document-invalid",
"status": 422,
"title": "Estimate document invalid"
}Zurückgegeben von#
POST /v2/organizations/{orgId}/localization/estimates