Webhook

Webhook可以将服务器和联络人名单事件几乎实时同步。联络人名单的webhooks会将更新数据 发布 在给定的URL中。你可以在联络人名单中选择事件以启动webhook。

如果你还不太了解这是什么,建议你阅读 PBWiki Webhooks 以供参考。


由此开始
  1. 登入Benchmark Email 账户
  2. 点选[联络人群组]索引卷标
  3. 点选欲设置的联络人名单
  4. 在名单操作选项中点选[webhook]

设置webhook
  1. 给定事件发生时发布数据的URL
  2. 选择webhook的触发事件
  3. 点选[Add Webhook]以储存变更
新增webhook之后,你也可以新增新的webhook或更新/删除既有的webhook

联络人名单触发事件

Benchmark Email容许在以下事件发生时触发webhook:

发布数据

一旦选定的事件发生,webhook就会将触发事件的相关数据以HTTP POST形式发布在给定的URL中。
数据会以key / value 配对发布

其下会列出事件的数据



Subscribes
Key Value (sample)
type subscribe Type of the Trigger
fired_at 11/9/2011 12:42:35 PM Time of the event
list_id 999 The List ID (refer to the API)
email test@benchmarkemail.com Email address which was subscribed
optin 1 - If the email was opted in
optin_ip The IP of the opt in email
optin_date The subscription date for the opt in email
First_Name Peter First name (contact attribute)
Last_Name Parker Last name (contact attribute)
Last_Name Parker Last name (contact attribute)
Middle_Name contact attribute
Job_Title contact attribute
Company_Name contact attribute
Address contact attribute
City contact attribute
State contact attribute
Zip contact attribute
Country contact attribute
Cell_Phone contact attribute
Phone contact attribute
Fax contact attribute
Notes contact attribute
Business_Address contact attribute
Business_City contact attribute
Business_State contact attribute
Business_Zip contact attribute
Business_Country contact attribute
Business_Phone contact attribute
Business_Fax contact attribute
Extra_1 contact attribute
Extra_2 contact attribute
Extra_3 contact attribute
Extra_4 contact attribute
Extra_5 contact attribute
Extra_6 contact attribute


Unsubscribes
Key Value (sample)
type unsubscribe Type of the Trigger
fired_at 11/9/2011 12:42:35 PM Time of the event
list_id 999 The List ID (refer to the API)
email test@benchmarkemail.com Email address which was subscribed
action unsub
reason manual
optin 1 - If the email was opted in
optin_ip The IP of the opt in email
optin_date The subscription date for the opt in email
First_Name Peter First name (contact attribute)
Last_Name Parker Last name (contact attribute)
Last_Name Parker Last name (contact attribute)
Middle_Name contact attribute
Job_Title contact attribute
Company_Name contact attribute
Address contact attribute
City contact attribute
State contact attribute
Zip contact attribute
Country contact attribute
Cell_Phone contact attribute
Phone contact attribute
Fax contact attribute
Notes contact attribute
Business_Address contact attribute
Business_City contact attribute
Business_State contact attribute
Business_Zip contact attribute
Business_Country contact attribute
Business_Phone contact attribute
Business_Fax contact attribute
Extra_1 contact attribute
Extra_2 contact attribute
Extra_3 contact attribute
Extra_4 contact attribute
Extra_5 contact attribute
Extra_6 contact attribute


Changes to the profile
Key Value (sample)
type profile Type of the Trigger
fired_at 11/9/2011 12:42:35 PM Time of the event
list_id 999 The List ID (refer to the API)
email test@benchmarkemail.com Email address of the updated record
optin 1 - If the email was opted in
optin_ip The IP of the opt in email
optin_date The subscription date for the opt in email
First_Name Peter First name (contact attribute)
Last_Name Parker Last name (contact attribute)
Last_Name Parker Last name (contact attribute)
Middle_Name contact attribute
Job_Title contact attribute
Company_Name contact attribute
Address contact attribute
City contact attribute
State contact attribute
Zip contact attribute
Country contact attribute
Cell_Phone contact attribute
Phone contact attribute
Fax contact attribute
Notes contact attribute
Business_Address contact attribute
Business_City contact attribute
Business_State contact attribute
Business_Zip contact attribute
Business_Country contact attribute
Business_Phone contact attribute
Business_Fax contact attribute
Extra_1 contact attribute
Extra_2 contact attribute
Extra_3 contact attribute
Extra_4 contact attribute
Extra_5 contact attribute
Extra_6 contact attribute


Cleaning of the email
Key Value (sample)
type cleaned Type of the Trigger
fired_at 11/9/2011 12:42:35 PM Time of the event
list_id 999 The List ID (refer to the API)
email cleaned
reason


Change of the existing email address
Key Value (sample)
type upemail Type of the Trigger
fired_at 11/9/2011 12:42:35 PM Time of the event
list_id 999 The List ID (refer to the API)
old_email test@benchmarkemail.com Email address of the record to be updated
email test123@benchmarkemail.com Updated email address
optin 1 - If the email was opted in
optin_ip The IP of the opt in email
optin_date The subscription date for the opt in email
First_Name Peter First name (contact attribute)
Last_Name Parker Last name (contact attribute)
Last_Name Parker Last name (contact attribute)
Middle_Name contact attribute
Job_Title contact attribute
Company_Name contact attribute
Address contact attribute
City contact attribute
State contact attribute
Zip contact attribute
Country contact attribute
Cell_Phone contact attribute
Phone contact attribute
Fax contact attribute
Notes contact attribute
Business_Address contact attribute
Business_City contact attribute
Business_State contact attribute
Business_Zip contact attribute
Business_Country contact attribute
Business_Phone contact attribute
Business_Fax contact attribute
Extra_1 contact attribute
Extra_2 contact attribute
Extra_3 contact attribute
Extra_4 contact attribute
Extra_5 contact attribute
Extra_6 contact attribute