Java Development WeChat payment (Card Payment)

Source: Internet
Author: User

Java Development payment (Card Payment)

 

 

Download and decompress

 

To get the jar package above, you don't have to worry about it. This is what we need. Yes, if you want to see the source code of this jar. This can also be found.

Continue, of course, as long as this jar is still not enough, the following third-party jar is required

You don't need to find them one by one. You can download them from my resources.

 

Focus on implementing payment

First, initialize some parameters.

 

There are no problems with the parameters. Certificate description

The. p12 path is used in the certificate path.

 

Then we will initiate a swipe payment request.

We need to instantiate this class first. This constructor contains some parameters for initiating payment.

Last call

Finally, a string is returned by TX.

Payment successful return_code return SUCCESS

Now it's over. Thank you!

 

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.