Warning: file_get_contents(/data/phpspider/zhask/data//catemap/2/facebook/9.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Youtube data api 品牌帐户的OAuth访问失败_Youtube Data Api_Google Oauth - Fatal编程技术网

Youtube data api 品牌帐户的OAuth访问失败

Youtube data api 品牌帐户的OAuth访问失败,youtube-data-api,google-oauth,Youtube Data Api,Google Oauth,在同意屏幕中选择品牌频道时,OAuth使用scopes登录youtube失败。与普通主帐户的youtube频道正常工作 scope: "email profile openid https://www.googleapis.com/auth/youtube" config: { client_id: my_client_id, fetch_basic_profile: true, ux_mode: 'popup', response_type: 'permission', a

在同意屏幕中选择品牌频道时,OAuth使用scopes登录youtube失败。与普通主帐户的youtube频道正常工作

scope: "email profile openid https://www.googleapis.com/auth/youtube"
config: {
  client_id: my_client_id,
  fetch_basic_profile: true,
  ux_mode: 'popup',
  response_type: 'permission',
  access_type: 'offline',
  prompt: 'consent'
}

你找到解决办法了吗?
Request https://accounts.google.com/o/oauth2/iframerpc?action=issueToken&response_type=token%20id_token&login_hint=AJDLj6JUa8yxXrhHdWRHIV0S13cANzW1y8OtI22VrYqaEC2i73av3HLVph3WpN9U_HlWSNxCsiYTB2bXOl1-DWQmT0zrdSxGa1JR03gPm3hk1GCjY9-EQsDI5aEH73UEvOOCoqynaOnr&client_id={my_real_token_here}&origin=http%3A%2F%2Flocalhost%3A4000&scope=openid%20profile%20email&ss_domain=http%3A%2F%2Flocalhost%3A4000

Failed with 403, response - { "error" : "invalid_request" } 
gapi.auth2.getAuthInstance()
    .signIn({ ...config, scope })
    .then(res => {
      const token = res.getAuthResponse().access_token

      return token
    })
    .catch((err) => {
      console.log(err) # {type: "tokenFailed", idpId: "google", error: "server_error"} 

      throw new Error()
    })