源语言区域不在覆盖范围内

Moses Skoda工程师预计阅读 1 分钟

发生此问题时,API 返回 422 Unprocessable Content。其 type 为 https://lingo.dev/docs/api/errors/pairs-source-locale-not-covered。所有错误的通用结构,请参阅错误和状态码。

无法保存这些词条对。其源语言区域 "pt-BR" 不在引擎默认术语库的覆盖范围(<coverage>)内。请使用覆盖范围内的语言区域,或将此语言区域添加到术语库的源语言区域覆盖范围中。

字段#

除标准成员 type、status、title 和 detail 外,响应体还包含以下字段。detail 文本根据这些字段生成,客户端也可以据此显示自定义文本。

字段类型
sourceLocalestring
coveragestring[]
owner"glossary" | "engine"

示例#

json
{
  "detail": "Cannot save the pairs. Their source locale \"pt-BR\" is not one the engine's default glossary covers (<coverage>). Use one of those locales, or add this one to the glossary's source coverage.",
  "sourceLocale": "pt-BR",
  "coverage": [
    "<coverage>"
  ],
  "owner": "glossary",
  "type": "https://lingo.dev/docs/api/errors/pairs-source-locale-not-covered",
  "status": 422,
  "title": "Source locale not covered"
}

返回此错误的端点#

  • POST /v2/engines/{engineId}/glossary-terms/extract-from-vtt