WeChat Pay - MagentoAccess to WeChat Pay API: Before use our module, please request WeChat Pay QR...

18
WeChat Pay V1.x for M2 User Guide / SunflowerBiz

Transcript of WeChat Pay - MagentoAccess to WeChat Pay API: Before use our module, please request WeChat Pay QR...

Page 1: WeChat Pay - MagentoAccess to WeChat Pay API: Before use our module, please request WeChat Pay QR Code API , WeChat Official Account Payment API and WeChat H5 Payment API on WeChat

WeChat Pay

V1.x for M2

User Guide / SunflowerBiz

Page 2: WeChat Pay - MagentoAccess to WeChat Pay API: Before use our module, please request WeChat Pay QR Code API , WeChat Official Account Payment API and WeChat H5 Payment API on WeChat

Table of Contents

1. Installation

2. Module setting

3. JSAPI Configuration

4. H5 Configuration

5. WeChat Pay in Front

6. WeChat Payment Process

7. Payment Success

8. Access to WeChat Pay API

9. Notifications

Email: [email protected]

Page 3: WeChat Pay - MagentoAccess to WeChat Pay API: Before use our module, please request WeChat Pay QR Code API , WeChat Official Account Payment API and WeChat H5 Payment API on WeChat

Installation:

From your base Magento2 directory -> app -> code (you may have to createthis directory), create the Sunflowerbiz directory to your app/codedirectory.

From the base Magento2 directory:-Upload the contents of 'Wechat' directory to 'app/code/Sunflowerbiz'directory of your Magento installation-Enable the module running the following commands on the root of yourMagento installation:bin/magento module:enable --clear-static-content Sunflowerbiz_Wechatbin/magento setup:upgrade

--------------------The following commands should work even in windows with the forwardslash swapped for back.

php bin/magento cache:cleanphp bin/magento setup:upgradephp bin/magento setup:di:compilephp bin/magento setup:static-content:deploy

Email: [email protected]

Page 4: WeChat Pay - MagentoAccess to WeChat Pay API: Before use our module, please request WeChat Pay QR Code API , WeChat Official Account Payment API and WeChat H5 Payment API on WeChat

Module Setting:

1. Go to Admin Panel, navigate to STORES and click on Configuration.

Page 5: WeChat Pay - MagentoAccess to WeChat Pay API: Before use our module, please request WeChat Pay QR Code API , WeChat Official Account Payment API and WeChat H5 Payment API on WeChat

2. Expand SALES and choose Payment Methods in the dropdown.

Page 6: WeChat Pay - MagentoAccess to WeChat Pay API: Before use our module, please request WeChat Pay QR Code API , WeChat Official Account Payment API and WeChat H5 Payment API on WeChat

3. Set up WeChat Pay

1) Expand the WeChat section to start the configuration.

2) Fill out the Merchant ID, AppID, AppKey, and AppSecret that WeChatprovides for you.

A) Merchant ID

A1) Log into WeChat Pay Merchant Platform

A2) Enter 微信支付商户号 (WeChat Merchant ID) under 账户信息(Acccount Info)as Merchant ID.

Page 7: WeChat Pay - MagentoAccess to WeChat Pay API: Before use our module, please request WeChat Pay QR Code API , WeChat Official Account Payment API and WeChat H5 Payment API on WeChat

B) AppKey

BI) Scroll down to Account Setting (账户设置) and click API Security (API 安全)

Page 8: WeChat Pay - MagentoAccess to WeChat Pay API: Before use our module, please request WeChat Pay QR Code API , WeChat Official Account Payment API and WeChat H5 Payment API on WeChat

BII) Set API Key

Click Set to create a 32-digit key by your own and enter it as AppKey

C) Configure JSAPI

CI) Click Development Configuration under Product Center

Page 9: WeChat Pay - MagentoAccess to WeChat Pay API: Before use our module, please request WeChat Pay QR Code API , WeChat Official Account Payment API and WeChat H5 Payment API on WeChat

CII) Set JSAPI Authorization Catalog under Payment Configuration

CIII) Click Add Enter: http or https://your site domain/wechat/process/redirect/

---------------------------------------------------------------------------------------------- Go to WeChat Official Accounts Platform---------------------------------------------------------------------------------

D) AppID and AppSecret

DI) Log into WeChat Official Accounts Platform

DII) Scroll down to Development and click Basic Configuration

Page 10: WeChat Pay - MagentoAccess to WeChat Pay API: Before use our module, please request WeChat Pay QR Code API , WeChat Official Account Payment API and WeChat H5 Payment API on WeChat

DIII) Enter Developer ID as AppID and Developer Password as AppSecret.

E) Configure Webpage Authorization Domain

EI) Click Function Setting at the top right corner under Account.

Page 11: WeChat Pay - MagentoAccess to WeChat Pay API: Before use our module, please request WeChat Pay QR Code API , WeChat Official Account Payment API and WeChat H5 Payment API on WeChat

EII) Configure Webpage Authorization Domain under WeChat OfficialAccounts Configuration.

Page 12: WeChat Pay - MagentoAccess to WeChat Pay API: Before use our module, please request WeChat Pay QR Code API , WeChat Official Account Payment API and WeChat H5 Payment API on WeChat

EIII) Click Set button

EIV) Download the txt file and upload to your Magento site root.

◦ It require a filing domain and doesn't support IP address, portnumber or short-chain domain name.

Page 13: WeChat Pay - MagentoAccess to WeChat Pay API: Before use our module, please request WeChat Pay QR Code API , WeChat Official Account Payment API and WeChat H5 Payment API on WeChat

F) Enable JSAPI/H5 and Log

Select Yes to enable JSAPI and H5 Pay. Select Yes to enable transaction log. Choose order status name when WeChat accepts payment.

Page 14: WeChat Pay - MagentoAccess to WeChat Pay API: Before use our module, please request WeChat Pay QR Code API , WeChat Official Account Payment API and WeChat H5 Payment API on WeChat

Front Page:

After the configuration, a customer will see Wechat Pay as a payment methodunder Review & Payment.

Page 15: WeChat Pay - MagentoAccess to WeChat Pay API: Before use our module, please request WeChat Pay QR Code API , WeChat Official Account Payment API and WeChat H5 Payment API on WeChat

WeChat Pay QR Code API

After selecting to pay with WeChat, it will auto generate a QR code for the customersto scan with their phone.

WeChat Pay JSAPI When a customer tries to checkout in WeChat browser, it will auto call WeChat PayApp to complete the payment.

H5 Payment APIIf a customer opens HTML5 pages using non-wechat browsers, it will auto callwechat app to complete the payment.

Page 16: WeChat Pay - MagentoAccess to WeChat Pay API: Before use our module, please request WeChat Pay QR Code API , WeChat Official Account Payment API and WeChat H5 Payment API on WeChat

Payment Success

After the payment, customers will go to the payment success page.

Page 17: WeChat Pay - MagentoAccess to WeChat Pay API: Before use our module, please request WeChat Pay QR Code API , WeChat Official Account Payment API and WeChat H5 Payment API on WeChat

Access to WeChat Pay API:

Please request WeChat Pay QR Code API , WeChat Official Account PaymentAPI and WeChat H5 Payment API on WeChat official site to get necessaryinfo to configure in our module setting page.

Step 1: Request ‘WeChat Official Account’: https://mp.weixin.qq.com/ Step 2: Request ‘WeChat Pay Merchant Account’Step 3: Sign Online Agreement

Read More info

Page 18: WeChat Pay - MagentoAccess to WeChat Pay API: Before use our module, please request WeChat Pay QR Code API , WeChat Official Account Payment API and WeChat H5 Payment API on WeChat

Notifications

1. Support Magento 2.x

2. Support Magento Community and Enterprise.

Email: [email protected]