> For the complete documentation index, see [llms.txt](https://support.cregis.com/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://support.cregis.com/cregis-wallet-guide/zh-cn/5.-zhi-fu-yin-qing/wordpress+woocommerce-cha-jian.md).

# WordPress+WooCommerce 插件

## 简介

**什么是 WordPress 及 WooCommerce?**

WordPress 是全球最受欢迎的网站管理系统之一。它是一个开源平台，让任何人都可以在不需要大量技术知识的情况下创建和管理网站。 WooCommerce 是一个免费的 WordPress 电商插件，可以将您的 WordPress 网站转变为功能完整的网上商店。关键区别在于 WordPress 是通用的网站创建平台，而 WooCommerce 专门为电商设计，运行在 WordPress 之上。

**什么是 Cregis Payment** 于 **WooCommerce?**

Cregis Payment 于 WooCommerce 是一个将 Cregis 加密货币的支付网关整合到您的 WooCommerce 商店的插件。此整合可以让您的客户使用加密货币（包括 USDT、USDC、BTC、SOL、ETH、TRX 和 BNB）支付产品费用。

安装和配置完成后，插件会自动处理加密货币收款，将其转换为您偏好的结算货币，实时管理订单状态，并为您的客户提供无缝的结帐体验。该插件还包括处理加密货币支付场景常见的问题，例如超额支付和部分付款。

无需编写代码 – 只需安装插件，输入您的 Cregis 帐号信息，您的商店即可接受加密货币支付。

## 启用要求

设置 Cregis Payment 之前，请确保您已准备好以下项目：

* 运行 5.0 或更高版本的 WordPress 网站，并已安装和启用 WooCommerce 插件（3.0 或更高版本）。
* 您应该在 WooCommerce 商店中至少创建了一个产品。
* 您的网站已安装 SSL 证书以启用 HTTPS，这是加密货币交易必需的安全要求。
* Cregis 商户帐号，您可以按照下一部分的商家设置指南创建。

## 商家设置指南

1. 从[新手入门](https://support.cregis.com/cregis-wallet-guide/zh-cn/gettingstarted/download)下载 Cregis 客户端并创建您的商户帐号。成功创建后，请按照[创建支付引擎](https://support.cregis.com/cregis-wallet-guide/zh-cn/payment_engine/creation)部分提供的每一步指南完成完整的帐号设置。这包括结算钱包配置、API 生成以及选择您接收的加密货币币种。<br>
2. 一个关键步骤是将您的电商平台的伺服器 IP 地址添加到 Cregis 入口网站的 IP 白名单中。如果您的伺服器 IP 地址是静态，您可以在 Cregis Payment 设定中复制您的 IP 地址。然后在 Cregis 客户端导航到 设置 > IP白名单，添加您的伺服器 IP 地址，并保存更改。如果没有正确的 IP 白名单设置，来自您商店的 API 请求将被拒绝。

   <figure><img src="https://2287475285-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FSdMhazXkh30OBfLly0nW%2Fuploads%2Fg3ANpDVaA0tv5Y7ThdYs%2Fimage.png?alt=media&amp;token=bf076e78-3fcf-47de-8fb4-e72dbe6caaf7" alt=""><figcaption></figcaption></figure>

   <figure><img src="https://2287475285-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FSdMhazXkh30OBfLly0nW%2Fuploads%2Ft9PUhHVFATQ3XkDraYBO%2Fimage.png?alt=media&amp;token=666a402d-3b14-4a14-a68c-418cef0ff340" alt=""><figcaption></figcaption></figure>

## 安装和配置插件

1. 登录您的 WordPress 管理后台，导航到 插件 > 添加插件。搜索「Cregis Payment for WooCommerce」并查找由 cregisproduct 创建的插件。点击 立即安装，然后点击 启用 完成安装。

   <figure><img src="https://2287475285-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FSdMhazXkh30OBfLly0nW%2Fuploads%2F9HywXaieXsY2LVoPVzYg%2Fimage.png?alt=media&amp;token=903fa4fd-1ec6-4f36-b91a-0d6ba0b55185" alt=""><figcaption></figcaption></figure>

2. 安装后，您将在左侧菜单中看到 Cregis Payment。点击访问配置页面。您需要从 Cregis 客户端复制 3 个信息：基础 URL、项目 ID 和 API 密钥。这些都可以在 Cregis 客户端的设置中找到。在插件中贴上这些值，然后点击 储存设定。<br>

   <figure><img src="https://2287475285-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FSdMhazXkh30OBfLly0nW%2Fuploads%2FLReTt8ACyXsf08o5ULps%2Fimage.png?alt=media&amp;token=7400fa94-538b-431e-8130-cfd345b7d2cc" alt=""><figcaption></figcaption></figure>

   <figure><img src="https://2287475285-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FSdMhazXkh30OBfLly0nW%2Fuploads%2FU7ienhUZYWlSFHBt9U9d%2Fimage.png?alt=media&amp;token=635fc033-f056-4c63-890d-2191d30250be" alt=""><figcaption></figcaption></figure>

3. 设置所需信息后，您的电商平台上销售的产品将可自动接受加密货币支付。<br>
   1. 订单金额基于您的 WooCommerce 商店货币设置，您可以在 WooCommerce > 设置 > 币种选项 > 货币 找到。（请确保您的货币是我们支持的货币，您可以在[此處](https://developers.cregis.com/zh/payment-engine-supported-currencies/)查阅）

      <figure><img src="https://2287475285-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FSdMhazXkh30OBfLly0nW%2Fuploads%2Fbt2kSlTXrZ4CuSVmQHSd%2Fimage.png?alt=media&amp;token=d913ab04-7a9b-4ea8-ab1b-02dd10ce90fa" alt=""><figcaption></figcaption></figure>

   2. 产品价格是每个产品单独设置，置于 产品 > 全部产品 > \[选择产品] > 促销价格。

      <figure><img src="https://2287475285-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FSdMhazXkh30OBfLly0nW%2Fuploads%2Fx6hf74nKOIz93fDSwskx%2Fimage.png?alt=media&amp;token=9cd019a4-7d70-4c11-abb6-860e4076f4f6" alt=""><figcaption></figcaption></figure>

   3. 如果您的商店货币是 USD 且列出的货币是与 USD 挂钩的稳定币，汇率将为 1:1。否则，您的产品标价与付款人选择的加密货币汇率将基于 CoinMarketCap 的实时汇率。<br>

   4. 付款人的电邮会在结帐时自动提交，并将用于处理超额支付和少额支付的情况。<br>

   5. 付款人可用的支付货币取决于您在 Cregis 客户端配置了哪些加密货币。

      <figure><img src="https://2287475285-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FSdMhazXkh30OBfLly0nW%2Fuploads%2FhKum50bTBcUgmWY94vXX%2Fimage.png?alt=media&amp;token=7295042e-ae96-430d-b890-52543bc518d6" alt=""><figcaption></figcaption></figure>

   6. 在 Web3 支付中，经常会遇到超额支付或部分支付的情况。您可以选择「接受所有不足额付款」来接受所有少付款，并选择「接受所有超额付款」来接受所有多付款。或者，您可以在插件设置中使用百分比配置容忍差，以控制您接受的上限和下限。例如，如果您在 100 美元的订单上设置 2% 的少额支付容差和 5% 的超额支付容差，您将接受 98 美元到 105 美元之间的支付。

      <figure><img src="https://2287475285-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FSdMhazXkh30OBfLly0nW%2Fuploads%2F9RfLyIMKAHxI2TVFfZ8k%2Fimage.png?alt=media&amp;token=33ca1ec4-70bc-41f6-a10f-3b3d120844f4" alt=""><figcaption></figcaption></figure>

   7. 每个支付默认有 60 分钟的有效时间。您可以根据需要调整此设置，最短为 10 分钟，最长为 1440 分钟（24 小时）。&#x20;

      <figure><img src="https://2287475285-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FSdMhazXkh30OBfLly0nW%2Fuploads%2FpdluSd0IYYnd0CjPAMVJ%2Fimage.png?alt=media&amp;token=101b5a28-d783-4937-a327-9a6974fec8f7" alt=""><figcaption></figcaption></figure>

## 结帐流程与库存影响

1. 在您电商平台的结帐页面中，支付选项中将提供一个名为「Cregis Payment」的选项。付款人可以选择此选项并点击 下单。请注意，如果在库存中配置了产品数量（产品 > 所有产品 > 选择一个产品 > 产品数据 部分 > 库存 > 数量），当付款人点击「下单」按钮时，它将根据购物车中的数量自动扣除。

   <figure><img src="https://2287475285-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FSdMhazXkh30OBfLly0nW%2Fuploads%2FfBaS6xfl5J9HpnA7hRwa%2Fimage.png?alt=media&amp;token=49481f8b-7639-4036-98f6-b112b57dbdab" alt=""><figcaption></figcaption></figure>

2. 支付链结是支付的行业标准界面。付款人可以选择他们偏好的加密货币，并按照介面完成支付。有关结帐的详细流程，可参考[支付链结（收银台）](https://support.cregis.com/cregis-wallet-guide/zh-cn/payment_engine/checkout_page?fallback=true)部分。\
   ![](https://2287475285-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FSdMhazXkh30OBfLly0nW%2Fuploads%2FpaYTsfriGXNx8ssrsbGw%2Fimage.png?alt=media\&token=079c7969-7181-4bb7-a076-963a0856201c)<br>

3. 在支付链结完成支付后，将重定向到您的订单状态页面。请注意，根据不同的支付状态，订单状态也会有所不同，可参下下表。

<table><thead><tr><th width="153.4140625">支付状态</th><th width="130.03125">订单状态</th><th>后续操作</th></tr></thead><tbody><tr><td>全额支付</td><td>已完成</td><td>无需操作。</td></tr><tr><td>部分支付</td><td>待处理</td><td>付款人将在订单状态页面看到跳窗，并收到电邮通知，需在 7 天内完成补款。更多信息：<a href="https://support.cregis.com/cregis-wallet-guide/zh-cn/payment_engine/introduction#bu-kuan-liu-cheng">补款流程</a>。</td></tr><tr><td>超额支付</td><td>待处理</td><td>付款人将在订单状态页面看到跳窗，并收到电邮通知，需在 7 天内完成部分退款。更多信息：<a href="https://support.cregis.com/cregis-wallet-guide/zh-cn/payment_engine/introduction#bu-fen-tui-kuan-liu-cheng">部分退款流程</a>。</td></tr><tr><td>支付超时</td><td>已取消</td><td>无需操作。</td></tr></tbody></table>

<figure><img src="https://2287475285-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FSdMhazXkh30OBfLly0nW%2Fuploads%2F7N0jT4oD4txGHZRICZ9s%2Fimage.png?alt=media&amp;token=d1560406-84d8-4185-84d3-f5958897e09c" alt=""><figcaption></figcaption></figure>

<figure><img src="https://2287475285-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FSdMhazXkh30OBfLly0nW%2Fuploads%2FQ1XKmH0bPYXSjCglAxe1%2Fimage.png?alt=media&amp;token=0a8ecc49-7dac-4ad4-a55e-ff8bc76cebde" alt=""><figcaption></figcaption></figure>

4. 如果付款人完成全额退款或付款人未在有效时间内完成支付，库存将自动补货。


---

# 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://support.cregis.com/cregis-wallet-guide/zh-cn/5.-zhi-fu-yin-qing/wordpress+woocommerce-cha-jian.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.
