2013-02-21 119 views
1

我在我的网站上集成AWeber但我发现问题并且必须说文档不太清楚。集成AWeber问题

<?php 
require_once('aweber_api/aweber_api.php'); 

$consumerKey = '***'; # put your credentials here 
$consumerSecret = '***'; # put your credentials here 
$accessKey  = '***'; # put your credentials here 
$accessSecret = '***'; # put your credentials here 
$account_id  = '***'; # put the Account ID here 
$list_id  = '***'; # put the List ID here 

$aweber = new AWeberAPI($consumerKey, $consumerSecret); 

但我不知道,我从哪里得到aweber_api/aweber_api.php$consumerKey$consumerSecret$accessKey$list_id$account_id$accessSecret。我在AWeber.com上做了帐户,在那里我找不到这些凭据。

回答

1

当您注册开发者帐户和“创建和应用”时,消费者密钥和秘密由https://labs.aweber.com网站发布。然后使用这两个值的API库启动授权过程(遵循OAuth 1.0a标准)。该过程将为您提供访问密钥和秘密。

最后,你使用这些2对键让自己的应用在每次请求数据时进行身份验证的API:

  • 消费者密钥和消费者秘密确定您的应用程序
  • 快捷键和访问秘密说给API,一旦应用程序验证自身“我登录到这个特定AWeber帐户”

,您可以使用库来获取帐户ID和任何你想要的列表中适当的名单ID访问。

AWeber有一个很好的教程,包括示例代码,可以引导您了解他们的OAuth的过程在这里:

https://labs.aweber.com/getting_started/private#private_connect_oauth

0

您需要在Aweber上创建一个开发者帐户才能获取这些帐户。

转到:https://labs.aweber.com/

然后创建一个应用程序来获取这些值。