From 9eb576b437012a3816388254df2f207d59ef0171 Mon Sep 17 00:00:00 2001 From: WatchMan-Wang <514504765@qq.com> Date: Wed, 13 Nov 2024 17:08:45 +0800 Subject: [PATCH 1/4] docs: Add a description of the insufficient_scope returned by calls to the OAuth Interface. --- cn/docs/sdk/taptap-login/taptap-oauth.mdx | 1 + .../version-v3/sdk/taptap-login/guide/taptap-oauth.mdx | 2 ++ hk/docs/sdk/taptap-login/taptap-oauth.mdx | 2 ++ .../current/sdk/taptap-login/taptap-oauth.mdx | 1 + .../version-v3/sdk/taptap-login/guide/taptap-oauth.mdx | 2 ++ .../version-v3/sdk/taptap-login/guide/taptap-oauth.mdx | 2 ++ 6 files changed, 10 insertions(+) diff --git a/cn/docs/sdk/taptap-login/taptap-oauth.mdx b/cn/docs/sdk/taptap-login/taptap-oauth.mdx index ba35edd76..94a9edea9 100644 --- a/cn/docs/sdk/taptap-login/taptap-oauth.mdx +++ b/cn/docs/sdk/taptap-login/taptap-oauth.mdx @@ -1244,4 +1244,5 @@ curl -s -H"Authorization:${AUTHORIZATION}" "https://${REQUEST_HOST}${REQUEST_URI | forbidden | 用户没有对当前动作的权限,**引导重新身份验证并不能提供任何帮助,而且这个请求也不应该被重复提交** | | not_found | 请求失败,请求所希望得到的资源未被在服务器上发现。**在参数相同的情况下,不应该重复请求** | | server_error | 服务器出现异常情况 **可稍等后重新尝试请求,但需有尝试上限,建议最多 3 次,如一直失败,则中断并告知用户** | +| insufficient_scope | 移动端进行 TapTap 授权使用的授权与服务端调用的 OAuth 接口不匹配导致,例如:移动端授权采用 basic_info 权限而服务端调用 `获取当前账户基础信息` API 时则会返回该异常 | diff --git a/cn/versioned_docs/version-v3/sdk/taptap-login/guide/taptap-oauth.mdx b/cn/versioned_docs/version-v3/sdk/taptap-login/guide/taptap-oauth.mdx index 2fd9dcaa5..74b318732 100644 --- a/cn/versioned_docs/version-v3/sdk/taptap-login/guide/taptap-oauth.mdx +++ b/cn/versioned_docs/version-v3/sdk/taptap-login/guide/taptap-oauth.mdx @@ -1244,4 +1244,6 @@ curl -s -H"Authorization:${AUTHORIZATION}" "https://${REQUEST_HOST}${REQUEST_URI | forbidden | 用户没有对当前动作的权限,**引导重新身份验证并不能提供任何帮助,而且这个请求也不应该被重复提交** | | not_found | 请求失败,请求所希望得到的资源未被在服务器上发现。**在参数相同的情况下,不应该重复请求** | | server_error | 服务器出现异常情况 **可稍等后重新尝试请求,但需有尝试上限,建议最多 3 次,如一直失败,则中断并告知用户** | +| insufficient_scope | 移动端进行 TapTap 授权使用的授权与服务端调用的 OAuth 接口不匹配导致,例如:移动端授权采用 basic_info 权限而服务端调用 `获取当前账户基础信息` API 时则会返回该异常 | + diff --git a/hk/docs/sdk/taptap-login/taptap-oauth.mdx b/hk/docs/sdk/taptap-login/taptap-oauth.mdx index 95661d7ee..307810a05 100644 --- a/hk/docs/sdk/taptap-login/taptap-oauth.mdx +++ b/hk/docs/sdk/taptap-login/taptap-oauth.mdx @@ -1243,4 +1243,6 @@ curl -s -H"Authorization:${AUTHORIZATION}" "https://${REQUEST_HOST}${REQUEST_URI | forbidden | 用户没有对当前动作的权限,**引导重新身份验证并不能提供任何帮助,而且这个请求也不应该被重复提交** | | not_found | 请求失败,请求所希望得到的资源未被在服务器上发现。**在参数相同的情况下,不应该重复请求** | | server_error | 服务器出现异常情况 **可稍等后重新尝试请求,但需有尝试上限,建议最多 3 次,如一直失败,则中断并告知用户** | +| insufficient_scope | 移动端进行 TapTap 授权使用的授权与服务端调用的 OAuth 接口不匹配导致,例如:移动端授权采用 basic_info 权限而服务端调用 `获取当前账户基础信息` API 时则会返回该异常 | + diff --git a/hk/i18n/en/docusaurus-plugin-content-docs/current/sdk/taptap-login/taptap-oauth.mdx b/hk/i18n/en/docusaurus-plugin-content-docs/current/sdk/taptap-login/taptap-oauth.mdx index d1c52aec1..c2a17120a 100644 --- a/hk/i18n/en/docusaurus-plugin-content-docs/current/sdk/taptap-login/taptap-oauth.mdx +++ b/hk/i18n/en/docusaurus-plugin-content-docs/current/sdk/taptap-login/taptap-oauth.mdx @@ -1235,3 +1235,4 @@ curl -s -H"Authorization:${AUTHORIZATION}" "https://${REQUEST_HOST}${REQUEST_URI | forbidden | The user does not have permission for the current action, **guiding re-authentication will not help, and this request should not be resubmitted** | | not_found | The request failed, the requested resource was not found on the server. **Under the same parameters, the request should not be repeated** | | server_error | An exception occurred on the server **Retry the request after a while, but there should be a retry limit, recommended maximum of 3 times, if it keeps failing, interrupt and inform the user** | +| insufficient_scope | The permission used for TapTap authorisation on the mobile side does not match the OAuth interface called by the server side, e.g. if the mobile side uses the basic_info permission for authorisation and the server side calls the `Get Current Account Detailed Information' API, then this exception is returned. | diff --git a/hk/i18n/en/docusaurus-plugin-content-docs/version-v3/sdk/taptap-login/guide/taptap-oauth.mdx b/hk/i18n/en/docusaurus-plugin-content-docs/version-v3/sdk/taptap-login/guide/taptap-oauth.mdx index 0d96a30b5..57c93117e 100644 --- a/hk/i18n/en/docusaurus-plugin-content-docs/version-v3/sdk/taptap-login/guide/taptap-oauth.mdx +++ b/hk/i18n/en/docusaurus-plugin-content-docs/version-v3/sdk/taptap-login/guide/taptap-oauth.mdx @@ -596,3 +596,5 @@ public class Authorization { | forbidden        | User does not have permission to perform this action. **Reauthenticating permission will not provide any help. This request should be not repeated.** | | not_found        | Request failed. The requested resources were not found on the server. **Requests should not be repeated with the same parameters** | | server_error    | The server error has occurred.  **You may retry the request later, but there must be an upper limit (recommended: 3). If the first attempt fails, interrupt and inform the user** |  +| insufficient_scope | The permission used for TapTap authorisation on the mobile side does not match the OAuth interface called by the server side, e.g. if the mobile side uses the basic_info permission for authorisation and the server side calls the `Get Current Account Detailed Information' API, then this exception is returned. | + diff --git a/hk/versioned_docs/version-v3/sdk/taptap-login/guide/taptap-oauth.mdx b/hk/versioned_docs/version-v3/sdk/taptap-login/guide/taptap-oauth.mdx index 11745a1df..cbdd444c0 100644 --- a/hk/versioned_docs/version-v3/sdk/taptap-login/guide/taptap-oauth.mdx +++ b/hk/versioned_docs/version-v3/sdk/taptap-login/guide/taptap-oauth.mdx @@ -1245,4 +1245,6 @@ curl -s -H"Authorization:${AUTHORIZATION}" "https://${REQUEST_HOST}${REQUEST_URI | forbidden | 用户没有对当前动作的权限,**引导重新身份验证并不能提供任何帮助,而且这个请求也不应该被重复提交** | | not_found | 请求失败,请求所希望得到的资源未被在服务器上发现。**在参数相同的情况下,不应该重复请求** | | server_error | 服务器出现异常情况 **可稍等后重新尝试请求,但需有尝试上限,建议最多 3 次,如一直失败,则中断并告知用户** | +| insufficient_scope | 移动端进行 TapTap 授权使用的授权与服务端调用的 OAuth 接口不匹配导致,例如:移动端授权采用 basic_info 权限而服务端调用 `获取当前账户基础信息` API 时则会返回该异常 | + From 47c779fe0ef05a919adf7314fb6fbd72e828b44f Mon Sep 17 00:00:00 2001 From: ShouWang <514504765@qq.com> Date: Wed, 13 Nov 2024 17:44:38 +0800 Subject: [PATCH 2/4] Update taptap-oauth.mdx --- cn/docs/sdk/taptap-login/taptap-oauth.mdx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cn/docs/sdk/taptap-login/taptap-oauth.mdx b/cn/docs/sdk/taptap-login/taptap-oauth.mdx index 94a9edea9..f78ec6287 100644 --- a/cn/docs/sdk/taptap-login/taptap-oauth.mdx +++ b/cn/docs/sdk/taptap-login/taptap-oauth.mdx @@ -1244,5 +1244,5 @@ curl -s -H"Authorization:${AUTHORIZATION}" "https://${REQUEST_HOST}${REQUEST_URI | forbidden | 用户没有对当前动作的权限,**引导重新身份验证并不能提供任何帮助,而且这个请求也不应该被重复提交** | | not_found | 请求失败,请求所希望得到的资源未被在服务器上发现。**在参数相同的情况下,不应该重复请求** | | server_error | 服务器出现异常情况 **可稍等后重新尝试请求,但需有尝试上限,建议最多 3 次,如一直失败,则中断并告知用户** | -| insufficient_scope | 移动端进行 TapTap 授权使用的授权与服务端调用的 OAuth 接口不匹配导致,例如:移动端授权采用 basic_info 权限而服务端调用 `获取当前账户基础信息` API 时则会返回该异常 | +| insufficient_scope | 移动端进行 TapTap 授权使用的授权范围与服务端调用的 OAuth 接口不匹配导致,例如:移动端授权采用 basic_info 权限而服务端调用 `获取当前账户基础信息` API 时则会返回该异常 | From 5ad42737ace39262acce63c8152b97d7f8b5d2b7 Mon Sep 17 00:00:00 2001 From: ShouWang <514504765@qq.com> Date: Wed, 13 Nov 2024 17:45:03 +0800 Subject: [PATCH 3/4] Update taptap-oauth.mdx --- .../version-v3/sdk/taptap-login/guide/taptap-oauth.mdx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/cn/versioned_docs/version-v3/sdk/taptap-login/guide/taptap-oauth.mdx b/cn/versioned_docs/version-v3/sdk/taptap-login/guide/taptap-oauth.mdx index 74b318732..b473b8fdc 100644 --- a/cn/versioned_docs/version-v3/sdk/taptap-login/guide/taptap-oauth.mdx +++ b/cn/versioned_docs/version-v3/sdk/taptap-login/guide/taptap-oauth.mdx @@ -1244,6 +1244,6 @@ curl -s -H"Authorization:${AUTHORIZATION}" "https://${REQUEST_HOST}${REQUEST_URI | forbidden | 用户没有对当前动作的权限,**引导重新身份验证并不能提供任何帮助,而且这个请求也不应该被重复提交** | | not_found | 请求失败,请求所希望得到的资源未被在服务器上发现。**在参数相同的情况下,不应该重复请求** | | server_error | 服务器出现异常情况 **可稍等后重新尝试请求,但需有尝试上限,建议最多 3 次,如一直失败,则中断并告知用户** | -| insufficient_scope | 移动端进行 TapTap 授权使用的授权与服务端调用的 OAuth 接口不匹配导致,例如:移动端授权采用 basic_info 权限而服务端调用 `获取当前账户基础信息` API 时则会返回该异常 | +| insufficient_scope | 移动端进行 TapTap 授权使用的授权范围与服务端调用的 OAuth 接口不匹配导致,例如:移动端授权采用 basic_info 权限而服务端调用 `获取当前账户基础信息` API 时则会返回该异常 | From ed9d5cba558ad0cd06c998da1940fd8de5e87c2a Mon Sep 17 00:00:00 2001 From: ShouWang <514504765@qq.com> Date: Wed, 13 Nov 2024 17:45:28 +0800 Subject: [PATCH 4/4] Update taptap-oauth.mdx --- .../version-v3/sdk/taptap-login/guide/taptap-oauth.mdx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hk/versioned_docs/version-v3/sdk/taptap-login/guide/taptap-oauth.mdx b/hk/versioned_docs/version-v3/sdk/taptap-login/guide/taptap-oauth.mdx index cbdd444c0..5d0ff6635 100644 --- a/hk/versioned_docs/version-v3/sdk/taptap-login/guide/taptap-oauth.mdx +++ b/hk/versioned_docs/version-v3/sdk/taptap-login/guide/taptap-oauth.mdx @@ -1245,6 +1245,6 @@ curl -s -H"Authorization:${AUTHORIZATION}" "https://${REQUEST_HOST}${REQUEST_URI | forbidden | 用户没有对当前动作的权限,**引导重新身份验证并不能提供任何帮助,而且这个请求也不应该被重复提交** | | not_found | 请求失败,请求所希望得到的资源未被在服务器上发现。**在参数相同的情况下,不应该重复请求** | | server_error | 服务器出现异常情况 **可稍等后重新尝试请求,但需有尝试上限,建议最多 3 次,如一直失败,则中断并告知用户** | -| insufficient_scope | 移动端进行 TapTap 授权使用的授权与服务端调用的 OAuth 接口不匹配导致,例如:移动端授权采用 basic_info 权限而服务端调用 `获取当前账户基础信息` API 时则会返回该异常 | +| insufficient_scope | 移动端进行 TapTap 授权使用的授权范围与服务端调用的 OAuth 接口不匹配导致,例如:移动端授权采用 basic_info 权限而服务端调用 `获取当前账户基础信息` API 时则会返回该异常 |