docs-mastodon/content/zh-cn/methods/proofs.md
2025-04-06 03:29:30 +08:00

1.7 KiB
Raw Blame History

title description menu aliases
proofs API 方法 供身份提供者使用。
docs
weight name parent identifier
100 proofs methods methods-proofs
/methods/proofs
/api/methods/proofs
/methods/accounts/proofs

{{< hint style="danger" >}} 已弃用
身份证明已在 3.5.0 及更高版本中弃用。 以前,唯一的证明提供者是 Keybase但自从被 Zoom 收购以来Keybase 的开发已经完全停滞。 {{< /hint >}}

查看身份证明{{%removed%}}

GET /api/proofs HTTP/1.1

返回: 由提供者定义的自定义响应
OAuth 公开
版本历史:
2.8.0 - 添加

请求

查询参数
provider
字符串。要查找的身份提供者。目前仅支持 keybase(区分大小写)。
username
字符串。所选身份提供者上的用户名。

响应

200: OK

通过“keybase”provider 查找 username “gargron”

{
  "avatar": "https://files.mastodon.social/accounts/avatars/000/000/001/original/d96d39a0abb45b92.jpg",
  "signatures": [
    {
      "sig_hash": "5cfc20c7018f2beefb42a68836da59a792e55daa4d118498c9b1898de7e845690f",
      "kb_username": "gargron"
    }
  ]
}
404: Not found

未找到 providerusername 的身份证明

{
  "error": "Record not found"
}

另请参考

{{< caption-link url="https://github.com/mastodon/mastodon/pull/17045" caption="删除 Keybase 集成 (#17045)" >}}

{{< translation-status-zh-cn raw_title="proofs API methods" raw_link="/methods/proofs/" last_translation_time="2025-04-06" raw_commit="5e2b739ee193896bea937addc2843146ea0bc870">}}