将事件自动添加到 Google 日历
Getting events automatically added to Google Calendar
我创建了一个网站来管理我 运行 的即兴喜剧研讨会。我希望确认电子邮件自动将活动添加到 Google 日历。
我在电子邮件中包含的标记已在
以下是我发送的电子邮件的完整原始来源。它已在 https://www.google.com/webmasters/markup-tester/
得到验证
我正在使用
"reservationStatus": "http://schema.org/Confirmed"
这是在 Google 文档中指定的。我最初使用状态 "ReservationConfirmed" 而不是 "Confirmed" 因为那是 schema.org 似乎使用的(他们没有 'Confirmed')。
但是 'ReservationConfirmed' 或 'Confirmed' 都没有被添加。
我添加了票务信息,TicketToken 指向正确的二维码。
我添加了 "performer" 信息(我,作为老师),这是 Google 电子邮件标记验证器建议的。
我还通过向自己发送电子邮件(即从 whines@gmail.com 到 whines@gmail.com)对此进行了测试,这应该绕过将电子邮件列入白名单的需要。
Delivered-To: whines@gmail.com
Received: by 10.107.197.133 with SMTP id v127csp1379143iof;
Thu, 21 Dec 2017 10:53:10 -0800 (PST)
X-Google-Smtp-Source: ACJfBoszCK5Q3Br9bFDOI7ucImZ8NGhK8yMVSfgRYzXWXmUjnZqrdWeFZtfiZgGGBqNTLHO6E66y
X-Received: by 10.107.199.131 with SMTP id x125mr14553462iof.70.1513882390523;
Thu, 21 Dec 2017 10:53:10 -0800 (PST)
ARC-Seal: i=1; a=rsa-sha256; t=1513882390; cv=none;
d=google.com; s=arc-20160816;
b=mB5G7WFlPlD0EJjxARc9/MRoHHqtadwu83hRH6c6nIddN/4vwoNR3ASv+zr/5ER9RU
Ys70NMGAZodF0lkVU40jByhV7rGiKA5h61kcC+JK2iR8X3QBBA/qcpxYDtwITAkQrqNc
1+HEJ+kM3zboFJo8P1tUJYjKuucIRC+iQm/cLGYahf00vgIY+qeMbPXGmrKWMCR0Nl2l
DItwZy25XrI54wO0joGt5zj1Gmxk2vPWX4Z7Y3PJsqUzc9sEZzHE7W68Ul2XKNS65CYO
vgWwYXNuDYXeRM8kUIiEg9WuPv/Azzdj6clMDcwGLkXW5B3k76p4gNzr2uB4F6uZHJqu
5gqA==
ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816;
h=charset:mime-version:to:subject:reply-to:from:dkim-signature
:message-id:date:arc-authentication-results;
bh=dg0XGyowjh3py1SdZvxdclmUyhBEczAui/9SQr8hI6w=;
b=n6Ej7Hv7uLnf3K61YP/6JhTBsMs/1JpwwS5dL+4XDHKOfgWfdkJW6nUaKrtyQimhk9
vAmaVzJmNn9KdHH+31SeTACGHsX4aMwD0cgttIeNFL/HLTmucNWuzyGHW2I2Vt4ppsWt
UI3NDAsc1LgkVw7E/MGo+z3IwGabYK9QIUNIg29uC9GK72cPhFonKoYzB+z4LrjG94xm
w4NcWLu/rtciQy21YoertS1ahvGy0kPlMmv71mc6hW1Jt1HiEvpThMQag9y4Is8t9go/
nJjkQvTYfxDFk4y/k6GEa1gbvuUEOsjtFELLxK6gcnCruMeUr9HPOdRfC8RLIEFg0Zjj
d8+Q==
ARC-Authentication-Results: i=1; mx.google.com;
dkim=pass header.i=@willhines.net header.s=default header.b=L6X46Jgh;
spf=pass (google.com: domain of will@willhines.net designates 72.52.242.236 as permitted sender) smtp.mailfrom=will@willhines.net
Return-Path: <will@willhines.net>
Received: from rocket-mail.gnservers.com ([72.52.242.236])
by mx.google.com with ESMTPS id v9si13875880iog.60.2017.12.21.10.53.10
for <whines@gmail.com>
(version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128);
Thu, 21 Dec 2017 10:53:10 -0800 (PST)
Received-SPF: pass (google.com: domain of will@willhines.net designates 72.52.242.236 as permitted sender) client-ip=72.52.242.236;
Authentication-Results: mx.google.com;
dkim=pass header.i=@willhines.net header.s=default header.b=L6X46Jgh;
spf=pass (google.com: domain of will@willhines.net designates 72.52.242.236 as permitted sender) smtp.mailfrom=will@willhines.net
Date: Thu, 21 Dec 2017 10:53:10 -0800 (PST)
Message-Id: <5a3c0316.09de6b0a.6ed26.bfe7SMTPIN_ADDED_MISSING@mx.google.com>
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed;
d=willhines.net; s=default; h=Content-Type:MIME-Version:To:Subject:Reply-To:
From:Sender:Date:Message-ID:Cc:Content-Transfer-Encoding:Content-ID:
Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc
:Resent-Message-ID:In-Reply-To:References:List-Id:List-Help:List-Unsubscribe:
List-Subscribe:List-Post:List-Owner:List-Archive;
bh=dg0XGyowjh3py1SdZvxdclmUyhBEczAui/9SQr8hI6w=; b=L6X46Jgh23/qgj8FXWHGGxiPKD
uYRAMfjpclaKE6Z6uWLHrdU2KWvyeqtYF+P4tFwp83oNWqOV9cOfc1NmzAgKkUXojH4ek02MW3HgX
HP5jVNrlDuQfbQooA1HIMjAgSGlY5KONujfIpZiV9h0N0PhiqiWpdXtzjMebpTP1PR8WmVchEYFNh
6Bbl+ZLfEFqugo9SFvQtQWdUqKd2h+eNT6+/WH3lf/nowNpnOS0PZcLCXrWFllmlwpkjc23LDAcyP
UV9pizZtTqxbXpgCy2pEZUTYfX4aiqVJ5+E291QQlVLrl0YhCTOrXmD8nSntqXpABVRKB4QyWsdBq
ZdJ93biA==;
Received: from static-205-185-62-122.earthlinkbusiness.net ([205.185.62.122]:60727 helo=localhost)
by rocket.gnservers.com with esmtpsa (TLSv1.2:ECDHE-RSA-AES128-GCM-SHA256:128)
(Exim 4.89_1)
(envelope-from <will@willhines.net>)
id 1eS5xu-0007m4-0b
for whines@gmail.com; Thu, 21 Dec 2017 13:53:10 -0500
From: will@willhines.net
Reply-To: will@willhines.net
Subject: ENROLLED: test - Mon Dec 25 - 11:00am-5pm
To: whines@gmail.com
MIME-Version: 1.0
Content-Type: text/html
charset: iso-8859-1
X-AntiAbuse: This header was added to track abuse, please include it with any abuse report
X-AntiAbuse: Primary Hostname - rocket.gnservers.com
X-AntiAbuse: Original Domain - gmail.com
X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12]
X-AntiAbuse: Sender Address Domain - willhines.net
X-Get-Message-Sender-Via: rocket.gnservers.com: authenticated_id: will@willhines.net
X-Authenticated-Sender: rocket.gnservers.com: will@willhines.net
X-Source:
X-Source-Args:
X-Source-Dir:
<script type="application/ld+json">
{
"@context": "http://schema.org",
"@type": "EventReservation",
"reservationNumber": "wbhwk794",
"reservationStatus": "http://schema.org/Confirmed",
"underName": {
"@type": "Person",
"name": "Will Hines"
},
"reservationFor": {
"@type": "EducationEvent",
"name": "test",
"startDate": "2017-12-25 11:00:00",
"endDate": "2017-12-25 17:00:00",
"performer": {
"@type": "Person",
"name": "Will Hines",
"image": "http://willhines.net/home_files/wh_clay_med.jpg"
},
"location": {
"@type": "Place",
"name": "The Complex",
"address": {
"@type": "PostalAddress",
"streetAddress": "6476 Santa Monica Blvd",
"addressLocality": "Los Angeles",
"addressRegion": "CA",
"postalCode": "90038",
"addressCountry": "US"
}
}
},
"ticketToken": "http://www.willhines.net/practices/code.php?wid=52&key=9ef66eb1f8166930&v=winfo",
"ticketNumber": "1",
"numSeats": "1",
"modifiedTime": "2017-12-21 10:53:05",
"modifyReservationUrl": "http://willhines.net/practices/index.php?wid=52"
}
</script>
<p>You are ENROLLED in test - Mon Dec 25 - 11:00am-5pm. </p>
<p>To DROP, click here:
http://localhost:8888/practices/index.php?key=9ef66eb1f8166930&ac=drop&wid=52<br><br>Pay in person or venmo. On the day of the workshop is fine.<br>Venmo link:
http://venmo.com/willhines?txn=pay&share=friends&amount=10¬e=improv%20workshop</p>
<p>Full info:</p>
<p><b>Title:</b> test<br>
<b>When:</b> Mon Dec 25 - 11:00am-5pm<br>
<b>Where:</b> The Complex 6476 Santa Monica Blvd Los Angeles CA 90038<br>
<b>Cost:</b> 10</p>
<b>Description:</b> </p>
<p>Thanks!</p>
<p>-Will Hines<br>
HQ: 1948 Hillhurst Ave. Los Angeles, CA 90027</p>
万一其他人遇到这个,我"solved"它。轻微的架构错误,而且我必须使用 Google.
注册我的电子邮件
1) 当 Google 文档与 schema.org 上的内容不同时,请遵循 Google 文档。对我来说,这意味着将 reservationFor @type 定义为 "Event" 而不是 "EducationEvent"
2) 您需要使用 google 注册您的电子邮件,如下所述:Registering With Google
否则,只有按照 Apps Script Quickstart.
中所述,通过 script.google.com 进行测试才会有效
文档说您可以通过从同一地址发送电子邮件和向同一地址发送电子邮件来避免注册测试,但我无法让它工作。
3) 此外,这可能是显而易见的,但我让我的 PHP 代码连接(通过 PEAR 的邮件)到我拥有帐户的 SMTP 服务器。这确保我的电子邮件具有有效的 DKIM/SPF 信息。
我创建了一个网站来管理我 运行 的即兴喜剧研讨会。我希望确认电子邮件自动将活动添加到 Google 日历。
我在电子邮件中包含的标记已在 以下是我发送的电子邮件的完整原始来源。它已在 https://www.google.com/webmasters/markup-tester/
得到验证我正在使用 "reservationStatus": "http://schema.org/Confirmed" 这是在 Google 文档中指定的。我最初使用状态 "ReservationConfirmed" 而不是 "Confirmed" 因为那是 schema.org 似乎使用的(他们没有 'Confirmed')。
但是 'ReservationConfirmed' 或 'Confirmed' 都没有被添加。
我添加了票务信息,TicketToken 指向正确的二维码。 我添加了 "performer" 信息(我,作为老师),这是 Google 电子邮件标记验证器建议的。
我还通过向自己发送电子邮件(即从 whines@gmail.com 到 whines@gmail.com)对此进行了测试,这应该绕过将电子邮件列入白名单的需要。
Delivered-To: whines@gmail.com
Received: by 10.107.197.133 with SMTP id v127csp1379143iof;
Thu, 21 Dec 2017 10:53:10 -0800 (PST)
X-Google-Smtp-Source: ACJfBoszCK5Q3Br9bFDOI7ucImZ8NGhK8yMVSfgRYzXWXmUjnZqrdWeFZtfiZgGGBqNTLHO6E66y
X-Received: by 10.107.199.131 with SMTP id x125mr14553462iof.70.1513882390523;
Thu, 21 Dec 2017 10:53:10 -0800 (PST)
ARC-Seal: i=1; a=rsa-sha256; t=1513882390; cv=none;
d=google.com; s=arc-20160816;
b=mB5G7WFlPlD0EJjxARc9/MRoHHqtadwu83hRH6c6nIddN/4vwoNR3ASv+zr/5ER9RU
Ys70NMGAZodF0lkVU40jByhV7rGiKA5h61kcC+JK2iR8X3QBBA/qcpxYDtwITAkQrqNc
1+HEJ+kM3zboFJo8P1tUJYjKuucIRC+iQm/cLGYahf00vgIY+qeMbPXGmrKWMCR0Nl2l
DItwZy25XrI54wO0joGt5zj1Gmxk2vPWX4Z7Y3PJsqUzc9sEZzHE7W68Ul2XKNS65CYO
vgWwYXNuDYXeRM8kUIiEg9WuPv/Azzdj6clMDcwGLkXW5B3k76p4gNzr2uB4F6uZHJqu
5gqA==
ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816;
h=charset:mime-version:to:subject:reply-to:from:dkim-signature
:message-id:date:arc-authentication-results;
bh=dg0XGyowjh3py1SdZvxdclmUyhBEczAui/9SQr8hI6w=;
b=n6Ej7Hv7uLnf3K61YP/6JhTBsMs/1JpwwS5dL+4XDHKOfgWfdkJW6nUaKrtyQimhk9
vAmaVzJmNn9KdHH+31SeTACGHsX4aMwD0cgttIeNFL/HLTmucNWuzyGHW2I2Vt4ppsWt
UI3NDAsc1LgkVw7E/MGo+z3IwGabYK9QIUNIg29uC9GK72cPhFonKoYzB+z4LrjG94xm
w4NcWLu/rtciQy21YoertS1ahvGy0kPlMmv71mc6hW1Jt1HiEvpThMQag9y4Is8t9go/
nJjkQvTYfxDFk4y/k6GEa1gbvuUEOsjtFELLxK6gcnCruMeUr9HPOdRfC8RLIEFg0Zjj
d8+Q==
ARC-Authentication-Results: i=1; mx.google.com;
dkim=pass header.i=@willhines.net header.s=default header.b=L6X46Jgh;
spf=pass (google.com: domain of will@willhines.net designates 72.52.242.236 as permitted sender) smtp.mailfrom=will@willhines.net
Return-Path: <will@willhines.net>
Received: from rocket-mail.gnservers.com ([72.52.242.236])
by mx.google.com with ESMTPS id v9si13875880iog.60.2017.12.21.10.53.10
for <whines@gmail.com>
(version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128);
Thu, 21 Dec 2017 10:53:10 -0800 (PST)
Received-SPF: pass (google.com: domain of will@willhines.net designates 72.52.242.236 as permitted sender) client-ip=72.52.242.236;
Authentication-Results: mx.google.com;
dkim=pass header.i=@willhines.net header.s=default header.b=L6X46Jgh;
spf=pass (google.com: domain of will@willhines.net designates 72.52.242.236 as permitted sender) smtp.mailfrom=will@willhines.net
Date: Thu, 21 Dec 2017 10:53:10 -0800 (PST)
Message-Id: <5a3c0316.09de6b0a.6ed26.bfe7SMTPIN_ADDED_MISSING@mx.google.com>
DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed;
d=willhines.net; s=default; h=Content-Type:MIME-Version:To:Subject:Reply-To:
From:Sender:Date:Message-ID:Cc:Content-Transfer-Encoding:Content-ID:
Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc
:Resent-Message-ID:In-Reply-To:References:List-Id:List-Help:List-Unsubscribe:
List-Subscribe:List-Post:List-Owner:List-Archive;
bh=dg0XGyowjh3py1SdZvxdclmUyhBEczAui/9SQr8hI6w=; b=L6X46Jgh23/qgj8FXWHGGxiPKD
uYRAMfjpclaKE6Z6uWLHrdU2KWvyeqtYF+P4tFwp83oNWqOV9cOfc1NmzAgKkUXojH4ek02MW3HgX
HP5jVNrlDuQfbQooA1HIMjAgSGlY5KONujfIpZiV9h0N0PhiqiWpdXtzjMebpTP1PR8WmVchEYFNh
6Bbl+ZLfEFqugo9SFvQtQWdUqKd2h+eNT6+/WH3lf/nowNpnOS0PZcLCXrWFllmlwpkjc23LDAcyP
UV9pizZtTqxbXpgCy2pEZUTYfX4aiqVJ5+E291QQlVLrl0YhCTOrXmD8nSntqXpABVRKB4QyWsdBq
ZdJ93biA==;
Received: from static-205-185-62-122.earthlinkbusiness.net ([205.185.62.122]:60727 helo=localhost)
by rocket.gnservers.com with esmtpsa (TLSv1.2:ECDHE-RSA-AES128-GCM-SHA256:128)
(Exim 4.89_1)
(envelope-from <will@willhines.net>)
id 1eS5xu-0007m4-0b
for whines@gmail.com; Thu, 21 Dec 2017 13:53:10 -0500
From: will@willhines.net
Reply-To: will@willhines.net
Subject: ENROLLED: test - Mon Dec 25 - 11:00am-5pm
To: whines@gmail.com
MIME-Version: 1.0
Content-Type: text/html
charset: iso-8859-1
X-AntiAbuse: This header was added to track abuse, please include it with any abuse report
X-AntiAbuse: Primary Hostname - rocket.gnservers.com
X-AntiAbuse: Original Domain - gmail.com
X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12]
X-AntiAbuse: Sender Address Domain - willhines.net
X-Get-Message-Sender-Via: rocket.gnservers.com: authenticated_id: will@willhines.net
X-Authenticated-Sender: rocket.gnservers.com: will@willhines.net
X-Source:
X-Source-Args:
X-Source-Dir:
<script type="application/ld+json">
{
"@context": "http://schema.org",
"@type": "EventReservation",
"reservationNumber": "wbhwk794",
"reservationStatus": "http://schema.org/Confirmed",
"underName": {
"@type": "Person",
"name": "Will Hines"
},
"reservationFor": {
"@type": "EducationEvent",
"name": "test",
"startDate": "2017-12-25 11:00:00",
"endDate": "2017-12-25 17:00:00",
"performer": {
"@type": "Person",
"name": "Will Hines",
"image": "http://willhines.net/home_files/wh_clay_med.jpg"
},
"location": {
"@type": "Place",
"name": "The Complex",
"address": {
"@type": "PostalAddress",
"streetAddress": "6476 Santa Monica Blvd",
"addressLocality": "Los Angeles",
"addressRegion": "CA",
"postalCode": "90038",
"addressCountry": "US"
}
}
},
"ticketToken": "http://www.willhines.net/practices/code.php?wid=52&key=9ef66eb1f8166930&v=winfo",
"ticketNumber": "1",
"numSeats": "1",
"modifiedTime": "2017-12-21 10:53:05",
"modifyReservationUrl": "http://willhines.net/practices/index.php?wid=52"
}
</script>
<p>You are ENROLLED in test - Mon Dec 25 - 11:00am-5pm. </p>
<p>To DROP, click here:
http://localhost:8888/practices/index.php?key=9ef66eb1f8166930&ac=drop&wid=52<br><br>Pay in person or venmo. On the day of the workshop is fine.<br>Venmo link:
http://venmo.com/willhines?txn=pay&share=friends&amount=10¬e=improv%20workshop</p>
<p>Full info:</p>
<p><b>Title:</b> test<br>
<b>When:</b> Mon Dec 25 - 11:00am-5pm<br>
<b>Where:</b> The Complex 6476 Santa Monica Blvd Los Angeles CA 90038<br>
<b>Cost:</b> 10</p>
<b>Description:</b> </p>
<p>Thanks!</p>
<p>-Will Hines<br>
HQ: 1948 Hillhurst Ave. Los Angeles, CA 90027</p>
万一其他人遇到这个,我"solved"它。轻微的架构错误,而且我必须使用 Google.
注册我的电子邮件1) 当 Google 文档与 schema.org 上的内容不同时,请遵循 Google 文档。对我来说,这意味着将 reservationFor @type 定义为 "Event" 而不是 "EducationEvent"
2) 您需要使用 google 注册您的电子邮件,如下所述:Registering With Google
否则,只有按照 Apps Script Quickstart.
中所述,通过 script.google.com 进行测试才会有效文档说您可以通过从同一地址发送电子邮件和向同一地址发送电子邮件来避免注册测试,但我无法让它工作。
3) 此外,这可能是显而易见的,但我让我的 PHP 代码连接(通过 PEAR 的邮件)到我拥有帐户的 SMTP 服务器。这确保我的电子邮件具有有效的 DKIM/SPF 信息。