intuit oauth 1.0 的 CALLBACK_URL 是什么?

what will be the CALLBACK_URL fir intuit auth1.0?

我想通过使用 quickbooks 和他们提供的 api 从我的 intuit 帐户获取客户的详细信息到我的网站。 我在关注这个 link : Python- quickbooks

到目前为止我所做的是:

def intuit_details(request):
    client = QuickBooks(
        sandbox=True,
        consumer_key=ConsumerKey,
        consumer_secret=ConsumerSecret,
        callback_url="",
        )
    authorize_url = client.get_authorize_url()
    request_token = client.request_token
    request_token_secret = client.request_token_secret
    return HttpResponse('success')

我可能会卡住我的回电 url 并且它是否需要成为我需要定义和做进一步工作的方法。 我已经坚持了4天了。 当我将 localhost 放入回调 url 时,它 return 我 value/tokens/keys 但我想这是错误的方法。

如果有人能指出我正确的方向或帮助我理解我需要做什么。 TIA

OAuth 回调 URL 是您创建的 URL,它接收 Intuit 提供给您的 OAuth 令牌。

基本上,一旦用户通过 Intuit 提供的 UI 授权访问,Intuit 会将他们重定向回您的回调 URL(同样,您创建并指定的 URL) OAuth 访问令牌作为查询字符串附加到它的末尾。

然后您存储 OAuth 凭据,并在未来的 REST API 请求中使用它们。

阅读规范中的所有内容:

并且在 Intuit 的文档中:

这是 Intuit 关于该主题的 copy/paste 文档:

Handling the response

The Intuit OAuth service verifies the signature and consumer key sent in the request. If successful, it returns the access token tuple to the oauth_callback parameter that you specified in the request. A successful response to the request contains the following fields:

Field | Description

oauth_token_secret | The access token secret.

oauth_token | The access token.

所有响应字段返回为 查询参数,如下图:

https://www.mydemoapp.com/oauth-redirect?
oauth_token_secret=[system generated access token secret]&
oauth_token=[system generated access token]

在持久存储中, 保存 OAuth oauth_token、oauth_token_secret 和 realmId, 将它们与当前授权访问的用户相关联。 您的应用程序需要这些值才能对 Quickbooks 进行后续请求 API。一定要加密access token和access token secret 在将它们保存到持久存储之前。