2013-10-03 35 views

回答

2

如果你得到一个redirect_uri_mismatch,机会是你已经在redirect_uri进入在Box开发者应用程序控制台中。 SDK已经为您处理这个问题,只需要设置客户端密钥/客户端ID。在应用程序控制台中,将redirect_uri保留为空白,如附图所示,一切都应该很好。 enter image description here

+0

感谢。现在我在Web视图中验证后出现了另一个问题,我的模拟器显示一个白色的屏幕,它没有显示我的视图控制器。 –

+0

页面抛出错误“如果我将字段”redirect_uri“留为空白,则”OAuth2重定向URL必须指定有效的URL并且不得为http://“。 – CopperCash

2

除了你不能把它留下黑色。如果该字段为空白,该页面不会让您保存设置。

0

提供这个问题的答案,以防别人将来遇到同样的问题。

如果发生“Error:redirect_uri_mismatch”,Box建议使用以下格式填写redirect_uri:Box developer page

Find the 'redirect_uri' field in the 'OAuth2 Parameters' section. Make sure it is populated with the expected format: boxsdk-YOUR_CLIENT_ID_HERE://boxsdkoauth2redirect. This is needed for authentication to work in your app. The SDK expects this pattern. Make sure you replace the 'YOUR_CLIENT_ID_HERE' string with your client ID value from the 'client_id' field. The dash ('-') remains.

来源:Box Github page