> For the complete documentation index, see [llms.txt](https://docs.exoclick.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://docs.exoclick.com/tutorials/zh/jiao-cheng/mei-ti-zhu-jiao-cheng/how-implement-push-notifications.md).

# 推送通知：如何实现推送通知广告位

ExoClick 现已提供推送通知广告格式。在本平台指南中，我们将向您展示如何创建一个推送通知广告位。

## 如何设置推送通知广告位 <a href="#how-to-set-up-a-push-notification-a-d-zone" id="how-to-set-up-a-push-notification-a-d-zone"></a>

{% stepper %}
{% step %}

### 创建广告位

在管理面板中，进入 Publisher 下的‘**网站和广告位**’然后点击‘**新广告位**’。将会出现一个下拉菜单，其中列出了您的网站，请选择您想要启用推送通知的网站。

<figure><img src="https://53980720-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FJ4RqRdVZkeXomdmwHKOL%2Fuploads%2FawVy8VLy3wxBijSM5Dd0%2F9ZLv6VWZZKtRp3NWen9XezKheYG1HLME.png?alt=media&amp;token=891b2955-3998-4061-b74d-bf384f0f736d" alt=""><figcaption></figcaption></figure>

这将打开广告格式选择页面。点击下拉菜单‘**原生**’，选择‘**推送通知**’，然后点击‘**下一步**’。
{% endstep %}

{% step %}

### 选择集成方式

现在您需要决定希望如何收集选择接收推送通知的用户。共有三种选项：

如果在发送推送通知时使用您自己的域名，您可以在两种实现方式中选择。您可以在‘**直接**’和‘**带软性请求提示的直接**’之间选择：

* **直接**：这将在您网站上向用户显示一个选择加入框（直接）。在该框中，用户可以选择‘**允许**’或‘**阻止**’推送通知

<figure><img src="https://53980720-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FJ4RqRdVZkeXomdmwHKOL%2Fuploads%2FhYLIz1YTMbF32U2pAsNy%2FjuPo4Lw4sQLKBy6QBUpvpXBnHrYqp7E3.png?alt=media&amp;token=f87d79b4-9094-4b8a-af26-5deb6209ca84" alt=""><figcaption></figcaption></figure>

* **带软性请求提示的直接**：这是一个两步流程，会在您的网站上连续显示两个选择加入框。第一个（软性请求）会询问用户是否愿意接收推送通知，在该框中用户可以选择‘**不了，谢谢**’或‘**允许。**’如果用户点击允许，将会出现第二个框（直接），用户可以选择‘允许’或‘阻止。’要执行此操作，请选择直接并开启软性请求提示按钮

<figure><img src="https://53980720-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FJ4RqRdVZkeXomdmwHKOL%2Fuploads%2FbGLr22uOfKSHTUvMjg3e%2FCzIvF7jegAREZeQ2MaZ8MCKgmMw3Dk3E.png?alt=media&amp;token=2faf40ea-439d-42c2-a6da-9b09bb5dee1f" alt=""><figcaption></figcaption></figure>

如果使用 ExoClick 的域名，则只有一种实现方式：

* **托管**：这将在您的网站上仅显示软性请求框，询问用户是否愿意接收推送通知，在该框中用户可以选择‘不了，谢谢’或‘允许。’

<figure><img src="https://53980720-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FJ4RqRdVZkeXomdmwHKOL%2Fuploads%2FTxMTWVkibpyZh7eD67vP%2FyqItai6z96gQjz4dJaGJUBfMyFU9kA9a.png?alt=media&amp;token=f93806d1-abfa-4864-84d7-6b069bded7ee" alt=""><figcaption></figcaption></figure>

{% hint style="info" %}
在软性请求框中，如果用户点击‘**不了，谢谢**’框，他将在 2 天后自动再次被定向。如果您实施直接方式，如果用户点击‘阻止’按钮，他将永远不会再次被定向。
{% endhint %}

**使用您自己的域名**：这将带来更高的订阅率，因为您网站的直接用户会主动选择订阅。在发送推送通知时，您的域名会显示在通知框中。

**使用 ExoClick 的域名**：这对发布商有利，因为用户不会将推送通知与发布商关联，而会与 ExoClick 广告网络关联。ExoClick 的域名会显示在推送通知广告中。该方法还允许您将您网站的推送通知与其他网络以及 ExoClick 一起实现。阅读 [这篇博文](https://www.exoclick.com/blog/push-notifications) 以获取详细说明。
{% endstep %}

{% step %}

### 软性请求提示自定义

当“**使用默认值**”复选框被勾选时，您将看到下方设置显示出来。

<figure><img src="https://53980720-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FJ4RqRdVZkeXomdmwHKOL%2Fuploads%2FOzAh4oclTZe2Ac4LLfOu%2FvsDYe0HuBaZmHf7zZk1RC1I6Yo0Cx2NW.png?alt=media&amp;token=0eccbccd-595e-4ac4-92c4-2e1b6f460f94" alt=""><figcaption></figcaption></figure>

当“**使用默认值**”复选框未勾选时，您可以自定义以下设置：

* **位置：** 在这里，您可以选择软性请求提示框在用户屏幕上显示的位置，选项有：
  * **垂直**：顶部、中部、底部
  * **水平**：左侧、中间或右侧
* **延迟**：我们建议将其设置为 5 秒以内，这样用户一到达您的网站就能看到软性请求提示框

您也可以将框中显示的文本从提供的默认文本进行编辑： **行动号召**, **描述**, **确认按钮文本**, **拒绝按钮文本**

{% hint style="info" %}
默认文本托管在 ExoClick 的服务器上，提供 12 种语言：英语、西班牙语、法语、德语、意大利语、葡萄牙语、捷克语、匈牙利语、克罗地亚语、斯洛伐克语、俄语和中文。文本会自动以最终用户浏览器设置的语言显示。如果您输入自己的文本，软性请求提示框将始终显示您输入的语言，而不会触发我们设置的默认语言。
{% endhint %}
{% endstep %}

{% step %}

### 生成广告位代码

一旦您点击‘**创建**’，广告位代码将自动为您生成，以便您可以复制并粘贴到您的网站中。

<figure><img src="https://53980720-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FJ4RqRdVZkeXomdmwHKOL%2Fuploads%2FMR360jLvrbHDNyF3oqtm%2FYpy21cS2ZUJa93hEZzzVpgYgZlClrO5F.png?alt=media&amp;token=e833ef73-92fa-4e68-8c02-de3a59332e65" alt=""><figcaption></figcaption></figure>

{% hint style="warning" %}
您必须将提供的 **worker.js** 文件放在您的网站目录根文件夹中，以确保其正常运行。
{% endhint %}
{% endstep %}

{% step %}

### 统计数据

一旦订阅者选择接收推送通知，最多可能会有 2 小时的延迟，然后他才会收到第一条广告。

之后，订阅者将每 3 小时收到一次推送通知广告，例如，用户在上午 7 点订阅，他会在上午 7 点到 9 点之间收到第一条广告

因此，在查看统计数据时请记住这一点。

{% hint style="warning" %}
推送通知不适用于 Safari 和 Mobile Safari 浏览器，也不适用于任何非 HTTPS 网站。
{% endhint %}

如果您在设置推送通知广告位时遇到任何问题，请联系您的客户经理或客户成功专员 [这里](https://www.exoclick.com/contact/).
{% endstep %}
{% endstepper %}


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://docs.exoclick.com/tutorials/zh/jiao-cheng/mei-ti-zhu-jiao-cheng/how-implement-push-notifications.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
