# Google Wallet 卡券入门

Google Wallet 卡券是用户保存在 Google Wallet 应用中的数字卡，例如会员卡、优惠券、礼品卡、活动门票、登机牌和公交票。

通过 Pushwoosh，您可以在控制面板中设计卡券，将其发送给用户，并随时更新卡券。更改会自动同步到每个已保存的设备。

## 您可以使用 Google Wallet 卡券做什么

*   在[卡券构建器](/zh/product/messaging-channels/google-wallet-passes/pass-builder/)中设计卡券
*   与用户分享保存链接或二维码
*   随时更新卡券。Google 会将更改同步到每个已保存的设备
*   通过一次性推送、卡券更新通知或 Customer Journey [向卡券持有人发送消息](/zh/product/messaging-channels/google-wallet-passes/message-pass-holders/)

## 前提条件

*   一个 [Google Pay & Wallet Console](https://pay.google.com/business/console) 发行商帐户
*   一个带有服务帐户密钥的 Google Cloud 项目

## 开始使用 Google Wallet 卡券

在满足[前提条件](#prerequisites)后，请按照以下流程操作：

<Steps>

1.  **在 Pushwoosh 中配置 Google Wallet**

    请您的开发团队将 Google Wallet 连接到您在 Pushwoosh 中的应用程序。

    [如何设置 Google Wallet](/zh/developer/first-steps/connect-messaging-services/android-configuration/android-google-wallet-configuration/)

2.  **设计卡券**

    在 **Campaigns → Wallet Passes** 中打开卡券构建器，选择一种卡券类型，添加您的品牌和字段，并查看实时预览。

    [在卡券构建器中设计 Google Wallet 卡券](/zh/product/messaging-channels/google-wallet-passes/pass-builder/)

3.  **创建卡券**

    当卡券看起来正确时，在[卡券构建器](/zh/product/messaging-channels/google-wallet-passes/pass-builder/#generate-the-pass)中点击 **Generate**。

4.  **将卡券发送给用户**

    从 **All passes** 分享保存链接或二维码。请参阅[通过 Pushwoosh 渠道与用户分享卡券](#share-the-pass-with-users-via-pushwoosh-channels)。要大规模地向每个用户发送卡券，您的开发团队可以使用 [Google Wallet API](/zh/developer/api-reference/google-wallet-api/)。

5.  **更新卡券**

    在 [**All passes**](#view-and-manage-existing-passes) 中，点击卡券上的 **Edit**，或通过 [Google Wallet API](/zh/developer/api-reference/google-wallet-api/) 更新它。当您保存时，Google 会将更新分发到每个保存了该卡券的设备。用户无需再次保存。

6.  **向卡券持有人发送消息**

    一旦用户保存了卡券，您就可以通过一次性推送或自动化的 Customer Journey 联系他们。

    [向 Google Wallet 卡券持有人发送消息](/zh/product/messaging-channels/google-wallet-passes/message-pass-holders/)

</Steps>

## 查看和管理现有卡券

在控制面板中，转到 **Campaigns → Wallet Passes** 并打开 **Google Wallet** 选项卡。**All passes** 表格列出了应用程序的每张卡券，包括卡券名称、样式、其关联的 [User ID](/zh/product/pushwoosh-knowledge-hub/users-userids/)、状态以及上次更新时间。

在卡券列表上，打开操作菜单 (⋮) 以：

*   **Edit：** 更改字段值和标签、颜色、徽标和主图 URL、条形码、链接、位置和有效期。卡券类型在创建后被锁定。当您保存时，每个保存了该卡券的设备都会收到更新。

<Aside type="note" title="卡券更新和通知">
当您保存更改时，卡券会在每个保存了它的设备上更新。如果启用了 **Notify about changed fields**（默认启用），Google 还会向持有人发送 Android 通知。

**会员卡**、**活动门票**和**航班**卡券支持通知。Google 会根据更改的字段自动生成通知文本。对于活动和航班卡券，通知仅在距离开始时间不足 3 小时时触发，并且 Google 将其限制为每张卡券每 24 小时最多 3 次。

要向卡券持有人发送您自己的消息，请参阅[向 Google Wallet 卡券持有人发送消息](/zh/product/messaging-channels/google-wallet-passes/message-pass-holders/)。
</Aside>

*   **Send message：** 打开一次性推送编辑器以向卡券持有人发送消息。有关联系他们的所有方式，请参阅[向 Google Wallet 卡券持有人发送消息](/zh/product/messaging-channels/google-wallet-passes/message-pass-holders/)。
*   **QR code：** 显示一个编码了卡券保存链接的二维码。用户扫描它以将卡券保存到 Google Wallet 并注册其设备以接收更新。
*   **Copy install link：** 复制卡券保存链接以在您的消息渠道中分享。[了解更多](#share-the-pass-with-users-via-pushwoosh-channels)。
*   **Invalidate：** 将活动卡券设置为非活动状态。该卡券将移至用户在 Google Wallet 中的 **Expired passes** 部分。记录保留在 Pushwoosh 中。
*   **Activate：** 将非活动卡券重新设置为活动状态。此选项仅在卡券为非活动状态时出现在操作菜单中。在 Google Wallet 中恢复卡券。
*   **Delete：** 在 Google 中使卡券失效并在 Pushwoosh 中删除其记录。Google 不允许强制删除已保存在设备上的卡券。它会变为无效并移至 **Expired passes**。


## 通过 Pushwoosh 渠道与用户分享卡券

**Add to Google Wallet** 链接是一个常规 URL (`https://pay.google.com/gp/v/save/...`)。在设备上打开它会提示用户将卡券保存到 Google Wallet。您可以在您已经用来联系受众的相同 Pushwoosh 渠道中使用此链接：

*   **Email：** 在[电子邮件编辑器](/zh/product/content/email-content/drag-and-drop-email-editor/)中将链接添加到按钮或文本链接，例如，“添加到 Google Wallet” 的号召性用语。
*   **Push notifications：** 将链接设置为通知的[打开操作](/zh/product/messaging-channels/push-notifications/send-push-notifications/one-time-push/#define-what-happens-when-the-push-is-clicked)，这样点击就会打开卡券。
*   **SMS：** 在 [SMS 内容](/zh/product/messaging-channels/sms/send-sms/send-sms-via-customer-journey/#configure-sms-content)中包含链接。

## 通过 API 管理卡券

卡券构建器所做的一切也可以通过 Google Wallet API 以编程方式实现：创建、更新、列出、获取保存链接、设置状态和删除卡券。

<LinkCard title="Google Wallet API" href="/developer/api-reference/google-wallet-api/" />

## 在用户浏览器中查看卡券持有人

当用户保存您的卡券时，Pushwoosh 会在[用户浏览器](/zh/product/audience-data-and-segmentation/user-explorer/)的 **Devices and platforms** 选项卡上列出它。

1.  转到 **Audience → User Explorer** 并打开用户个人资料。
2.  打开 **Devices and platforms** 选项卡。
3.  在侧边栏中选择 **Google Wallet**。

在平台个人资料上，您可以查看：

*   **Subscription status：** 例如，**SUBSCRIBED**
*   **Platform identifier：** 显示在平台名称下的卡券标识符
*   **Metadata：** **First subscription**、**Timezone** 以及其他可用字段
*   **Tags：** 平台标签，包括您在发行卡券时设置的任何标签

[了解更多](/zh/product/audience-data-and-segmentation/user-explorer/#devices-and-platforms-tab)