节点的 SendPulse API 身份验证凭据
Authentication Credentials with the SendPulse API for Node
我正在使用在 smtp 节点中编写的 SendPulse 客户端库。这是他们 example.js:
的片段
var API_USER_ID="USER_ID"
var API_SECRET="USER_SECRET"
var TOKEN_STORAGE="/tmp/"
sendpulse.init(API_USER_ID,API_SECRET,TOKEN_STORAGE);
我已经尝试使用我创建帐户时使用的电子邮件地址,以及他们在 SMTP 设置页面上给我的密码,分别用于 user_id 和 user_secret。当我 运行 代码时,我收到此错误消息:
{ error: 'invalid_request', error_description: 'The request is
missing a required parameter, includes an invalid parameter value,
includes a parameter more than once, or is otherwise malformed. Check
the "access token" parameter.', message: 'The request is missing a
required parameter, includes an invalid parameter value, includes a
parameter more than once, or is otherwise malformed. Check the "access
token" parameter.', error_code: 1 }
但是,无论您做什么似乎都无关紧要,您总是会收到该错误消息。您可以 运行 sendpulse.ini();
并仍然收到该消息。
我的问题是,使用 SendPulse 节点库的正确凭据是什么? smtp 设置页面也给了我一个 public 键,不知道该怎么做。我注意到这个图书馆已经有一年了,它过时了吗?非常感谢您的帮助。我正处于一个非常大的项目的末尾,这是最后一个障碍。
您需要使用 https://login.sendpulse.com/settings/ 页面中的 "ID" 和 "Secret",转到 "API" 选项卡并启用 "Activate REST API"。
我正在使用在 smtp 节点中编写的 SendPulse 客户端库。这是他们 example.js:
的片段var API_USER_ID="USER_ID"
var API_SECRET="USER_SECRET"
var TOKEN_STORAGE="/tmp/"
sendpulse.init(API_USER_ID,API_SECRET,TOKEN_STORAGE);
我已经尝试使用我创建帐户时使用的电子邮件地址,以及他们在 SMTP 设置页面上给我的密码,分别用于 user_id 和 user_secret。当我 运行 代码时,我收到此错误消息:
{ error: 'invalid_request', error_description: 'The request is missing a required parameter, includes an invalid parameter value, includes a parameter more than once, or is otherwise malformed. Check the "access token" parameter.', message: 'The request is missing a required parameter, includes an invalid parameter value, includes a parameter more than once, or is otherwise malformed. Check the "access token" parameter.', error_code: 1 }
但是,无论您做什么似乎都无关紧要,您总是会收到该错误消息。您可以 运行 sendpulse.ini();
并仍然收到该消息。
我的问题是,使用 SendPulse 节点库的正确凭据是什么? smtp 设置页面也给了我一个 public 键,不知道该怎么做。我注意到这个图书馆已经有一年了,它过时了吗?非常感谢您的帮助。我正处于一个非常大的项目的末尾,这是最后一个障碍。
您需要使用 https://login.sendpulse.com/settings/ 页面中的 "ID" 和 "Secret",转到 "API" 选项卡并启用 "Activate REST API"。