【问题标题】:Consolibyte Quickbooks Connection ProblemConsolibyte Quickbooks 连接问题
【发布时间】:2020-02-27 12:17:29
【问题描述】:

我正在尝试从 Consolibyte "docs/partner_platform/example_app_ipp_v3/index.php" 文件将我的网站(在开发人员模式下,因此 Sandbox True,非 https)连接到 Intuit,但我不断收到以下错误:

哦哦,连接有问题。抱歉,该应用程序没有 连接。请稍后再试,或联系客户支持寻求帮助。

查看错误详细信息(针对开发人员)redirect_uri 查询参数 值无效。确保它在 Redirect URIs 部分中列出 在您的应用程序的键选项卡上并完全匹配。点击这里学习 有关 redirect_uri 查询参数的更多信息。

我已在我的直觉开发人员帐户中将此应用程序的重定向 Uri 设置为 Consolibyte config.php (docs/partner_platform/example_app_ipp_v3/success.php) 中的相同返回 URL,但它仍然无法正常工作。

我做错了吗?我正确地遵循了快速入门指南中的所有内容。

config.php 代码:

$oauth_client_id = '***';
$oauth_client_secret = '***';

// If you're using DEVELOPMENT TOKENS, you MUST USE SANDBOX MODE!!!  If you're in PRODUCTION, then DO NOT use sandbox.
$sandbox = true;     // When you're using development tokens
//$sandbox = false;    // When you're using production tokens

// This is the URL of your OAuth auth handler page
$quickbooks_oauth_url = 'http://www.***.com/quickbooks/docs/partner_platform/example_app_ipp_v3/oauth.php';

// This is the URL to forward the user to after they have connected to IPP/IDS via OAuth
$quickbooks_success_url = 'http://www.***.com/quickbooks/docs/partner_platform/example_app_ipp_v3/success.php';

// This is the menu URL script
$quickbooks_menu_url = 'http://www.***.com/quickbooks/docs/partner_platform/example_app_ipp_v3/menu.php';

// This is a database connection string that will be used to store the OAuth credentials
// $dsn = 'pgsql://username:password@hostname/database';
// $dsn = 'mysql://username:password@hostname/database';
$dsn = 'mysqli://***_intuit:***@localhost/***_quickbooks';

// You should set this to an encryption key specific to your app
$encryption_key = '***';

// Scope required
$scope = 'com.intuit.quickbooks.accounting ';

// The tenant that user is accessing within your own app
$the_tenant = 12345;

【问题讨论】:

  • 能否把config.php的相关栏目和Intuit开发者门户的截图发给我们,确保匹配? Intuit 显然不认为它匹配...
  • 1.发布其余相关的config_oauthv2.php 文件 - all 的 URL。该网址甚至无关紧要。 2. 使用此信息更新您的原始帖子。 3.不要截图代码。是文字。复制/粘贴。
  • 我将代码添加到我的原始帖子中。谢谢!

标签: php quickbooks


【解决方案1】:

您的重定向网址不匹配。

  • 在 Intuit 的控制面板中,它以 success.php 结尾。
  • 在您的配置中,它以oauth.php 结尾。

这两个网址必须完全匹配

另外,请确保您使用的是来自 https://github.com/consolibyte/quickbooks-php 的最新代码 - 如果您使用的是最新代码,您应该有一个 config_oauthv2.php 文件,而不仅仅是 config.php

【讨论】:

  • 现在工作。我将它从成功更改为 oauth 并且可以正常工作:) 谢谢!
猜你喜欢
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 1970-01-01
  • 2014-04-03
  • 1970-01-01
  • 2018-07-20
  • 1970-01-01
  • 1970-01-01
相关资源
最近更新 更多