网站无法访问

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

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

无法打开 https://example.com/pricing:域名无法解析。请检查地址是否存在拼写错误,或尝试其他地址。

字段#

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

字段类型
urlstring
reason"NotFound" | "Refused"

示例#

json
{
  "detail": "Couldn't open https://example.com/pricing: its domain does not resolve. Check the address for typos, or try another address.",
  "url": "https://example.com/pricing",
  "reason": "NotFound",
  "type": "https://lingo.dev/docs/api/errors/website-unreachable",
  "status": 422,
  "title": "Website unreachable"
}