人工审核路由重叠

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

API 返回 422 Unprocessable Content 时,会报告此问题。其 type 为 https://lingo.dev/docs/api/errors/human-edit-routes-conflict。所有错误的通用结构,请参阅错误和状态码。

人工审核路由覆盖相同的目标,且彼此的覆盖范围均不小于对方:<directory> 上针对 pt-BR 的 <routes> 和 <routes>。请为它们划分不同的语言区域,或将一个列表嵌套在另一个列表中。

字段#

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

字段类型
conflictsobject[]
conflicts[].routesstring[]
conflicts[].directorystring | null
conflicts[].localestring

示例#

json
{
  "detail": "Human review routes cover the same targets with neither narrower: <routes> and <routes> on <directory> for pt-BR. Split their locales or nest one list in the other.",
  "conflicts": [
    {
      "routes": [
        "<routes>",
        "<routes>"
      ],
      "directory": "<directory>",
      "locale": "pt-BR"
    }
  ],
  "type": "https://lingo.dev/docs/api/errors/human-edit-routes-conflict",
  "status": 422,
  "title": "Human review routes overlap"
}

返回此错误的端点#

  • PATCH /v2/engines/{id}
  • POST /v2/organizations/{orgId}/engines
  • POST /v2/organizations/{orgId}/provisioning/jobs