Payment data processing method, device, computer equipment and storage medium
By analyzing the identification fields and field values in the payment request and determining the target payment method and mode, the problems of single payment methods and single interface specifications in the prior art are solved, and the universality and convenience of payment methods are achieved.
Patent Information
- Application Number
- CN202111390222.5
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-11-19
- Publication Date
- 2025-06-06
- Estimated Expiration
- 2041-11-19
AI Technical Summary
In the prior art, the payment operation method is single, the payment method cannot be customized, and the H5 payment page interface specification is single, which cannot cope with the different payment method needs of different App developers.
By analyzing the payment request on the user interface, obtaining the payment identification field and payment field values, determining the target payment method and payment mode, and completing the payment operation. The specific method includes using a bitmap to represent the payment method and mode, and determining the payment method and mode based on the preset value.
It realizes the universality and convenience of payment methods, allows customization of payment methods and models according to actual needs, and improves the flexibility and efficiency of payment operations.
Smart Images

Figure CN114240424B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the technical field of data analysis, and in particular to a payment data processing method, apparatus, computer equipment, storage medium and computer program product. Background Art
[0002] With the rise of mobile Internet technology, mobile smart payment has also become popular and developed. How to make payments quickly, safely and intelligently has become a key issue.
[0003] Under existing technical conditions, payment operations are generally carried out in H5 (the abbreviation of HyperText Markup Language 5, which is the next-generation standard of the Internet and a language for building and presenting Internet content). The payment method is relatively simple and the payment end cannot customize the payment method. Moreover, the H5 payment page interface specification is simple and rigid, and cannot meet the different payment method requirements of different App developers. Summary of the invention
[0004] Based on this, it is necessary to provide a payment data processing method, apparatus, computer equipment, computer-readable storage medium and computer program product that can improve the versatility of payment methods in response to the above-mentioned technical problems.
[0005] In a first aspect, the present application provides a payment data processing method. The method comprises:
[0006] Respond to the payment operation triggered on the user interface and obtain the corresponding payment request;
[0007] Parsing the payment information carried in the payment request to obtain a payment identification field and a corresponding payment field value; wherein the payment field value is related to a preset payment method and payment mode;
[0008] Parse the payment field value to obtain the payment method and the corresponding payment mode;
[0009] A target payment method is determined from the payment methods, and the payment operation is completed according to the target payment method and the corresponding target payment mode.
[0010] In one embodiment, the payment field value is a bitmap including at least one bit, and parsing the payment field value to obtain the payment method and the corresponding payment mode includes:
[0011] Parsing the payment field value to obtain the bit value of each bit in the bitmap; wherein each bit at each position in the bitmap represents a payment method;
[0012] A payment mode corresponding to the payment method is determined according to the bit value and the preset value.
[0013] In one embodiment, determining the payment mode corresponding to the payment method according to the bit value and the preset value includes any one of the following methods:
[0014] When the bit value is the first preset value, determining that the payment method uses H5 page gateway payment;
[0015] When the value of the bitmap is a second preset value, it is determined that the payment method calls back the SDK class native payment method to pay.
[0016] In one embodiment, completing the payment operation according to the target payment method and the corresponding target payment mode includes:
[0017] When the target payment mode is a callback SDK-class native payment method, generating a payment transaction string for the payment operation;
[0018] By calling back the SDK-type native payment method, the payment transaction string is called back to the payment native end of the target payment method, the numerical resources required to be transferred for the payment operation are transferred, and the payment operation is completed.
[0019] In one embodiment, completing the payment operation according to the target payment method and the corresponding target payment mode includes:
[0020] When the target payment mode is H5 page gateway payment, the numerical resources required to be transferred for the payment operation are transferred through the payment mode of the H5 page gateway payment to complete the payment operation.
[0021] In one embodiment, transferring the numerical resources required to be transferred for the payment operation to complete the payment operation includes:
[0022] Obtaining payment information for the payment operation and verifying it;
[0023] When the verification is passed, the numerical resources required for the payment operation are transferred to complete the payment operation.
[0024] In a second aspect, the present application also provides a payment data processing device. The device comprises:
[0025] An acquisition module, used to respond to a payment operation triggered on the user interface and acquire a corresponding payment request;
[0026] A first parsing module, configured to parse the payment information carried in the payment request to obtain a payment identification field and a corresponding payment field value; wherein the payment field value is related to a preset payment method and a payment processing method;
[0027] A second parsing module, used to parse the payment field value and obtain the payment method and the corresponding payment mode;
[0028] The data processing module is used to determine the target payment method from the payment methods, and complete the payment operation according to the target payment method and the corresponding target payment mode.
[0029] In one embodiment, the second parsing module is further used to parse the payment field value to obtain the bit value of each bit in the bitmap; wherein the bit at each position in the bitmap represents a payment method;
[0030] The device also includes: a determination module, which is used to determine the payment mode corresponding to the payment method according to the bit value and the preset value.
[0031] In one embodiment, the determination module is further used to determine that the payment method uses H5 page gateway payment when the bit value is a first preset value; or
[0032] When the value of the bitmap is a second preset value, it is determined that the payment method calls back the SDK class native payment method to pay.
[0033] In one embodiment, the device further comprises:
[0034] A generation module, used for generating a payment transaction string for the payment operation when the target payment mode is a callback SDK class native payment method;
[0035] The resource transfer module is used to call back the payment transaction string to the payment native end of the target payment method through the callback SDK class native payment method, transfer the numerical resources that need to be transferred for the payment operation, and complete the payment operation.
[0036] In one of the embodiments, the resource transfer module is also used to transfer the numerical resources that need to be transferred for the payment operation through the payment mode of the H5 page gateway payment to complete the payment operation when the target payment mode is the H5 page gateway payment.
[0037] In one embodiment, the device further comprises:
[0038] A verification module, used to obtain payment information of the payment operation and perform verification;
[0039] The resource transfer module is also used to transfer the numerical resources required for the payment operation to complete the payment operation when the verification is passed. In a third aspect, the present application also provides a computer device. The computer device includes a memory and a processor, the memory stores a computer program, and the processor implements the following steps when executing the computer program:
[0040] Respond to the payment operation triggered on the user interface and obtain the corresponding payment request;
[0041] Parsing the payment information carried in the payment request to obtain a payment identification field and a corresponding payment field value; wherein the payment field value is related to a preset payment method and payment mode;
[0042] Parse the payment field value to obtain the payment method and the corresponding payment mode;
[0043] A target payment method is determined from the payment methods, and the payment operation is completed according to the target payment method and the corresponding target payment mode.
[0044] In a fourth aspect, the present application further provides a computer-readable storage medium. The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the following steps are implemented:
[0045] Respond to the payment operation triggered on the user interface and obtain the corresponding payment request;
[0046] Parsing the payment information carried in the payment request to obtain a payment identification field and a corresponding payment field value; wherein the payment field value is related to a preset payment method and payment mode;
[0047] Parse the payment field value to obtain the payment method and the corresponding payment mode;
[0048] A target payment method is determined from the payment methods, and the payment operation is completed according to the target payment method and the corresponding target payment mode.
[0049] In a fifth aspect, the present application further provides a computer program product. The computer program product includes a computer program, and when the computer program is executed by a processor, the following steps are implemented:
[0050] Respond to the payment operation triggered on the user interface and obtain the corresponding payment request;
[0051] Parsing the payment information carried in the payment request to obtain a payment identification field and a corresponding payment field value; wherein the payment field value is related to a preset payment method and payment mode;
[0052] Parse the payment field value to obtain the payment method and the corresponding payment mode;
[0053] A target payment method is determined from the payment methods, and the payment operation is completed according to the target payment method and the corresponding target payment mode.
[0054] The above-mentioned payment data processing method, device, computer equipment, storage medium and computer program product obtain relevant payment field values by pre-setting preset payment methods and payment processing methods, that is, different system methods and payment modes can be set according to actual needs; when a payment request is obtained, the supported payment methods are determined according to the payment identification field and the corresponding field value, and the target payment method is selected from the determined payment methods. The payment operation is completed through the corresponding target payment mode. In other words, payment is achieved through customized payment methods and determining the best payment method according to payment needs, without switching payment interfaces, thereby improving the convenience of payment operations and the versatility of payment methods. BRIEF DESCRIPTION OF THE DRAWINGS
[0055] Figure 1 An application environment diagram of a payment data processing method in one embodiment;
[0056] Figure 2 A schematic diagram of a payment data processing method in one embodiment;
[0057] Figure 3 A schematic diagram of a payment data processing process in one embodiment;
[0058] Figure 4 A schematic flow chart of a payment data processing method in another embodiment;
[0059] Figure 5 It is a structural block diagram of a payment data processing device in one embodiment;
[0060] Figure 6 FIG. 4 is a diagram showing the internal structure of a computer device in one embodiment. DETAILED DESCRIPTION
[0061] In order to make the purpose, technical solution and advantages of the present application more clearly understood, the present application is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application.
[0062] The payment data processing method provided in the embodiment of the present application can be applied to Figure 1In the application environment shown. Among them, the terminal 102 communicates with the server 104 through the network. The data storage system can store the data that the server 104 needs to process. The data storage system can be integrated on the server 104, or it can be placed on the cloud or other network servers. In response to the payment operation triggered on the user interface of the terminal 102, the corresponding payment request is obtained from the server; the payment information carried by the payment request is parsed to obtain the payment identification field and the corresponding payment field value; wherein the payment field value is related to the preset payment method and payment mode; the payment field value is parsed to obtain the payment method and the corresponding payment mode; the target payment method is determined from the payment method, and the payment operation is completed according to the target payment method and the corresponding target payment mode. Among them, the terminal 102 can be, but is not limited to, various personal computers, laptops, smart phones, tablet computers, Internet of Things devices and portable wearable devices. The server 104 can be implemented with an independent server or a server cluster consisting of multiple servers.
[0063] In one embodiment, Figure 2 As shown, a payment data processing method is provided, which is applied to Figure 1 The terminal in is used as an example to illustrate, including the following steps:
[0064] Step 202, respond to the payment operation triggered on the user interface and obtain the corresponding payment request.
[0065] Specifically, the terminal responds to the payment operation triggered by the user in the user interface of the terminal and obtains the corresponding payment request; wherein the payment request carries the payment information related to the business, and the payment information includes the business type corresponding to the payment operation, the payment operation time, the amount of numerical resources to be paid and the recipient of the numerical resources, as well as the payment method and payment mode, etc. The payment request can be but is not limited to an https request, and the request header of the https request (https, Hyper Text Transfer Protocol over Secure Socket Layer is an HTTP channel with security as its goal, which ensures the security of the transmission process through transmission encryption and identity authentication on the basis of HTTP) carries the payment information.
[0066] Step 204, parse the payment information carried in the payment request to obtain the payment identification field and the corresponding payment field value; wherein the payment field value is related to the preset payment method and payment mode.
[0067] Among them, the payment information can be expressed in the form of a string (for example, a payment field); the identification field of the payment information is "PAY_MAP", and the identification field value can be an n-bit bitmap (such as 0001000 or 010000 or 0010000), each bit represents a different payment method (for example, the first bit represents payment method 1, the second bit represents payment method 2, the third bit represents payment method 3, etc.), and the value of each bit represents the payment mode of the payment method (for example, value 0 represents payment mode 1, value 1 represents payment mode 2, and value 3 represents payment mode 3), and different payment field values represent different payment methods; optionally, the number of payment methods and the number of payment modes.
[0068] The preset payment method includes different payment methods, and the payment methods include different parent applications (parent applications include applications, such as instant messaging applications with payment functions and applications for data resource transfer) and sub-applications, such as sub-applications that are mini-programs. Among them, the identification field value can be an n-bit bitmap, the first bit indicates XX payment / account payment; the second bit indicates WeChat; the third bit indicates WeChat mini-program; the fourth bit indicates Alipay; and the fifth bit indicates UnionPay.
[0069] Payment modes include H5 page gateway payment and callback SDK-based native payment method payment. Page gateway payment, i.e., payment gateway, is the interface between the banking financial network system and the Internet network. It is a group of server devices operated by the bank to convert data transmitted on the Internet into internal data of the financial institution, or a designated third party to process merchant payment information and customer payment instructions; H5 page gateway payment refers to jumping from the current client page to the corresponding payment page. Callback SDK-based native payment method payment refers to calling the corresponding interface according to different payment methods, and calling back the native payment method to realize the transfer of numerical resources; the payment mode can realize payment through the call interface provided by the H5 payment page, i.e., the transfer of numerical resources.
[0070] Furthermore, the payment field value (payment method and corresponding payment mode) can be set according to the business requirements and parameter content agreed upon in the interface. The payment method and payment mode can be determined during the development phase based on the payment history data of each user in different business scenarios, by analyzing the historical payment data and obtaining the user's payment habit data.
[0071] Specifically, the terminal parses the payment information carried in the request header of the payment request (for example, http request) to obtain the payment identification field and the corresponding payment field value; for example, the terminal parses the request header of the https request that carries the payment information, namely the identification field "PAY_MAP", to obtain the payment identification field and the corresponding payment field value.
[0072] Step 206, parse the payment field value to obtain the payment method and the corresponding payment mode.
[0073] Specifically, the payment field value is parsed, and the corresponding payment method and payment mode of each payment method are obtained according to the value of each bit in the payment field value, and the obtained payment method and corresponding payment mode are displayed on the user interface; among which, different payment methods support different payment modes. For example, payment method 1 only supports callback SDK class native payment method payment, different payment.
[0074] Step 208, determining a target payment method from the payment methods, and completing the payment operation according to the target payment method and the corresponding target payment mode.
[0075] Among them, determining the target payment method from the payment methods can be determined by responding to the payment method determination operation triggered by the user interface, or it can be determined based on the payment habit data of each user. The payment mode of the target payment method can be the default one, or it can be triggered and selected by the user; completing the payment operation means transferring the numerical resource to the corresponding resource receiving end according to the confirmed payment mode.
[0076] Specifically, in different payment applications, the target payment method is determined from pre-set payment methods. When the payment mode of the target payment method is H5 page gateway payment, the numerical resources required for the payment operation are transferred through the payment mode of H5 page gateway payment to complete the payment operation; when the payment mode of the target payment method is to call back the native payment method of the SDK class, the numerical resources required for the payment operation are transferred by calling back the original payment method to complete the payment operation.
[0077] In the above payment data processing method, the relevant payment field values are obtained by pre-setting the preset payment method and payment processing method, that is, different system methods and payment modes can be set according to actual needs; when a payment request is obtained, the supported payment method is determined according to the payment identification field and the corresponding field value, and the target payment method is selected from the determined payment methods. The payment operation is completed through the corresponding target payment mode. In other words, in different payment applications, payment is achieved through customized payment methods and determining the best payment method according to payment needs, thereby improving the convenience of payment operations and the versatility of payment methods.
[0078] In one embodiment, Figure 3 As shown, a payment data processing step is provided, which is applied to Figure 1 The terminal in is used as an example to illustrate, including the following steps:
[0079] Step 302, respond to the payment operation triggered on the user interface and obtain the corresponding payment request.
[0080] Step 304: parse the payment information carried in the payment request to obtain the payment identification field and the corresponding payment field value.
[0081] Step 306, parse the payment field value to obtain the payment method and the corresponding payment mode.
[0082] The payment field value is a bitmap including at least one bit; the bit value of each bit in the bitmap is obtained by parsing the payment field value; the bit at each position in the bitmap represents a payment method. The payment modes supported by the payment method represented by each bit correspond to different preset values; further, when the bit value is a first preset value (which may be but is not limited to 0), the payment mode used by the payment method is determined to be H5 page gateway payment; when the bitmap value is a second preset value (which may be but is not limited to 1), the payment mode used by the payee is determined to be payment by callback SDK class native payment method.
[0083] Optionally, the following is an example application of payment data processing. The payment request is an https request. Before the terminal application enters the H5 payment page, an identification field "PAY_MAP" is transmitted in the request header of the https request. The identification field represents the payment method. The H5 payment page will select different callbacks according to the value of the PAY_MAP field. The PAY_MAP field value is a 16-bit bitmap, a total of 16-bit bitmaps, 0 means using the H5 page gateway, and 1 means that the SDK class native payment method needs to be called back. Among them, the first bit represents Long Pay / account payment; the second bit represents application 1 (such as WeChat); the third bit represents subroutine 1 (such as WeChat applet); the fourth bit represents application 2 (such as Alipay); the fifth bit represents application 3 (such as UnionPay); the remaining bits are temporarily reserved, and the payment method can be updated according to actual needs. When the bitmap transmits the first preset value 0, the H5 page gateway payment is directly used. When the bitmap transmits the second preset value 1, H5 will encapsulate a payment transaction string and call back to the App native end through the JS method APPPay(). After the native end obtains the payment transaction string, it performs subsequent payment operations. For example, PAY_MAP=0100000000000000 means that when the user selects account payment on the page, the H5 page gateway will jump. When WeChat payment is selected, the APP will be called through JS, and the WeChat SDK payment will be invoked by the APP.
[0084] Step 308, determining a target payment method from the payment methods, and determining a target payment mode of the target payment method.
[0085] Step 310, when the target payment mode is H5 page gateway payment, the numerical resources required for the payment operation are transferred through the H5 page gateway payment payment mode to complete the payment operation.
[0086] For example, after the target payment method is determined, the value corresponding to the target payment method is 0, that is, H5 page gateway payment. H5 page gateway payment is used directly to transfer the numerical resources required for the payment operation to complete the payment operation.
[0087] Step 312: When the target payment mode is to call back the SDK class native payment method, a payment transaction string for the payment operation is generated.
[0088] Among them, the payment transaction string is obtained by encapsulating the business order number corresponding to the payment request, the payment item number, and the encryption string required for payment (parameters agreed upon in the interface) when the payment mode is to callback the native payment method of the SDK class.
[0089] Step 314, by calling back the SDK class native payment method, the payment transaction string is called back to the payment native end of the target payment method, the numerical resources required for the payment operation are transferred, and the payment operation is completed.
[0090] Specifically, when the target payment mode is to call back the SDK class native payment method, a payment transaction string for the payment operation is generated, and the payment transaction string is called back to the payment native end of the target payment method by calling back the SDK class native payment method, and the numerical resources that need to be transferred for the payment operation are transferred to complete the payment operation; for example, after the target payment method is determined, the value corresponding to the target payment method is 1, that is, the SDK class native payment method is called back, and the payment parameters such as the business order number, payment item number and encryption string (parameters agreed in the interface) corresponding to the payment request are encapsulated into a payment transaction string through H5, and called back to the App native end of the target payment method through the JS method APPPay() (for example, when the payment method is mini-program payment, the terminal needs to initiate payment (such as App initiates payment) and transmit payment parameters, and the WeChat mini-program is initiated through native code). After the native end obtains the payment transaction string, it performs subsequent payment operations, that is, transfers the numerical resources that need to be transferred for the payment operation to complete the payment operation.
[0091] In the above payment data processing step, in response to the payment operation triggered by the user interface, the payment information carried in the payment request is parsed, and the payment method and the corresponding payment mode are determined based on the payment identification field and the corresponding payment field value obtained through the analysis. According to business needs, different payment methods can be selected through a unified call on the payment page, and the payment operation is completed by determining the target payment method and target payment mode, which improves the convenience of payment operations and the versatility of payment methods.
[0092] In another embodiment, Figure 4 As shown, a payment data processing method is provided, which is applied to Figure 1 The terminal in is used as an example to illustrate, including the following steps:
[0093] Step 402, respond to the payment operation triggered on the user interface and obtain the corresponding payment request.
[0094] Step 404: parse the payment information carried in the payment request to obtain the payment identification field and the corresponding payment field value.
[0095] The payment field value is related to the preset payment method and payment mode.
[0096] Step 406, parse the payment field value to obtain the bit value of each bit in the bitmap; wherein each bit at each position in the bitmap represents a payment method.
[0097] Step 408, determining the payment mode corresponding to the payment method according to the bit value and the preset value.
[0098] Step 410, when the bit value is the first preset value, determine the payment method to use H5 page gateway payment.
[0099] Step 412, through the payment mode of H5 page gateway payment, transfer the numerical resources required for the payment operation to complete the payment operation.
[0100] Step 414: When the value of the bitmap is the second preset value, the payment method is determined to call back the SDK class native payment method for payment.
[0101] Step 416, generating a payment transaction string for the payment operation.
[0102] Step 418, by calling back the SDK class native payment method, the payment transaction string is called back to the payment native end of the target payment method, the numerical resources required for the payment operation are transferred, and the payment operation is completed.
[0103] Optionally, in one embodiment, before transferring the numerical resources that need to be transferred for the payment operation, the payment information of the payment operation is obtained and verified; when the verification is passed, the numerical resources that need to be transferred for the payment operation are transferred, the payment operation is completed, and the security of the payment is ensured; wherein, the payment information includes verification information for verifying whether the user has payment authority, which can be but is not limited to any one of image information, fingerprint information and string information.
[0104] Optionally, in one embodiment, payment data of each user is obtained, the payment data includes the user's payment habit data, and the payment field value is updated according to the payment habit data, such as adding or deleting payment methods, to increase the diversity of payment methods.
[0105] Optionally, in one embodiment, when the type of numerical resources that need to be transferred for the payment operation is different from the target numerical resource type of the numerical resource recipient, the numerical resources that need to be transferred for the payment operation are converted into numerical resources of the corresponding target numerical resource type according to the corresponding conversion coefficient, and the numerical resources of the numerical resource recipient are updated.
[0106] In this embodiment, in response to a payment operation triggered on the user interface, a corresponding payment request is obtained; the payment information carried in the payment request is parsed to obtain a payment identification field and a corresponding payment field value; wherein the payment field value is related to a preset payment method and a payment mode; the payment field value is parsed to obtain the bit value and preset value of each bit in the bitmap, and the payment mode corresponding to the payment method of each bit is determined, and when the bit value is the first preset value, it is determined that the payment method uses the H5 page gateway payment; through the payment mode of the H5 page gateway payment, the numerical resources that need to be transferred for the payment operation are transferred to complete the payment operation.
[0107] When the value of the bitmap is the second preset value, the payment method is determined to call back the SDK class native payment method to generate a payment transaction string for the payment operation; by calling back the SDK class native payment method, the payment transaction string is called back to the payment native end of the target payment method, the numerical resources required for the payment operation are transferred, and the payment operation is completed. The above payment data processing device can realize that different apps can transmit different PAY_MAP bitmaps through Headers according to business needs and select different payment methods, thereby performing native pull-up payment processing or H5 direct gateway payment, thereby improving the versatility of payment methods.
[0108] It should be understood that, although the various steps in the flowcharts involved in the above-mentioned embodiments are displayed in sequence according to the indication of the arrows, these steps are not necessarily executed in sequence according to the order indicated by the arrows. Unless there is a clear explanation in this article, the execution of these steps does not have a strict order restriction, and these steps can be executed in other orders. Moreover, at least a part of the steps in the flowcharts involved in the above-mentioned embodiments can include multiple steps or multiple stages, and these steps or stages are not necessarily executed at the same time, but can be executed at different times, and the execution order of these steps or stages is not necessarily to be carried out in sequence, but can be executed in turn or alternately with other steps or at least a part of the steps or stages in other steps.
[0109] Based on the same inventive concept, the embodiment of the present application also provides a payment data processing device for implementing the payment data processing method involved above. The implementation scheme for solving the problem provided by the device is similar to the implementation scheme recorded in the above method, so the specific limitations in one or more payment data processing device embodiments provided below can refer to the limitations on the payment data processing method above, and will not be repeated here.
[0110] In one embodiment, Figure 5 As shown, a payment data processing device is provided, including: an acquisition module 502, a first parsing module 504, a second parsing module 506 and a data processing module 508, wherein:
[0111] The acquisition module 502 is used to respond to the payment operation triggered on the user interface and acquire the corresponding payment request.
[0112] The first parsing module 504 is used to parse the payment information carried in the payment request to obtain the payment identification field and the corresponding payment field value; wherein the payment field value is related to the preset payment method and payment processing method.
[0113] The second parsing module 506 is used to parse the payment field value and obtain the payment method and the corresponding payment mode.
[0114] The data processing module 508 is used to transfer the numerical resources that need to be transferred for the payment operation through the corresponding payment mode according to the payment method.
[0115] In the above-mentioned payment data processing device, by pre-setting the preset payment method and payment processing method, the relevant payment field value is obtained, that is, different system methods and payment modes can be set according to actual needs; when a payment request is obtained, the supported payment method is determined according to the payment identification field and the corresponding field value, and the target payment method is selected from the determined payment methods. The payment operation is completed through the corresponding target payment mode, which improves the convenience of payment operations and the versatility of payment methods.
[0116] In another embodiment, a payment data processing device is provided, which includes, in addition to the acquisition module 502, the first parsing module 504, the second parsing module 506 and the data processing module 508, further includes: a determination module, a generation module, a verification module and a resource transfer module, wherein:
[0117] In one embodiment, the second parsing module 506 is further used to parse the payment field value to obtain the bit value of each bit in the bitmap; wherein the bit at each position in the bitmap represents a payment method.
[0118] The determination module is used to determine the payment mode corresponding to the payment method according to the bit value and the preset value.
[0119] In one embodiment, the determination module is further used to determine that the payment method uses H5 page gateway payment when the bit value is a first preset value;
[0120] When the value of the bitmap is the second preset value, the payment method is determined to call back the SDK class native payment method for payment.
[0121] The generation module is used to generate the payment transaction string for the payment operation when the target payment mode is the callback SDK class native payment method.
[0122] The data processing module 508 includes a resource transfer module, which is used to call back the payment transaction string to the payment native end of the target payment method by calling back the SDK class native payment method, transfer the numerical resources that need to be transferred for the payment operation, and complete the payment operation.
[0123] In one embodiment, the resource transfer module is also used to complete the payment operation by transferring the numerical resources required for the payment operation through the payment mode of H5 page gateway payment when the target payment mode is H5 page gateway payment.
[0124] The verification module is used to obtain the payment information of the payment operation and perform verification.
[0125] The resource transfer module is used to transfer the numerical resources required for the payment operation when the verification is passed to complete the payment operation.
[0126] In one embodiment, in response to a payment operation triggered on a user interface, a corresponding payment request is obtained; the payment information carried in the payment request is parsed to obtain a payment identification field and a corresponding payment field value; wherein the payment field value is related to a preset payment method and a payment mode; the payment field value is parsed to obtain the bit value and preset value of each bit in the bitmap, and the payment mode corresponding to the payment method of each bit is determined, and when the bit value is the first preset value, it is determined that the payment method uses H5 page gateway payment; through the payment mode of H5 page gateway payment, the numerical resources that need to be transferred for the payment operation are transferred to complete the payment operation.
[0127] When the value of the bitmap is the second preset value, the payment method is determined to call back the SDK class native payment method to generate a payment transaction string for the payment operation; by calling back the SDK class native payment method, the payment transaction string is called back to the payment native end of the target payment method, the numerical resources required for the payment operation are transferred, and the payment operation is completed. The above payment data processing device can realize that different apps can transmit different PAY_MAP bitmaps through Headers according to business needs and select different payment methods, thereby performing native pull-up payment processing or H5 direct gateway payment, thereby improving the versatility of payment methods.
[0128] In a business application scenario, before the App enters the H5 payment page, a payment identification field "PAY_MAP" transmitted by the request header Headers of the https request is obtained, and the payment field value corresponding to the identification field "PAY_MAP" is parsed to obtain the value of each bitmap. When the value of the corresponding bit of the determined payment method is 0, the H5 page gateway payment is directly used. When the value of the corresponding bit of the determined payment method is 1, H5 will encapsulate a payment transaction string and call back to the native App through the JavaScript function method APPPay(). After the native App obtains the payment transaction string, it transfers the numerical resources that need to be transferred for the payment operation to complete the payment operation; different PAY_MAP bitmaps are transmitted through Headers to select different payment methods, thereby performing native payment processing or H5 direct gateway payment, thereby improving the versatility of payment methods and the convenience of payment.
[0129] Each module in the above-mentioned payment data processing device can be implemented in whole or in part by software, hardware or a combination thereof. Each module can be embedded in or independent of a processor in a computer device in the form of hardware, or can be stored in a memory in a computer device in the form of software, so that the processor can call and execute the operations corresponding to each module above.
[0130] In one embodiment, a computer device is provided. The computer device may be a terminal, and its internal structure diagram may be as follows: Figure 6As shown. The computer device includes a processor, a memory, a communication interface, a display screen and an input device connected through a system bus. Among them, the processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system and a computer program. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The communication interface of the computer device is used to communicate with an external terminal in a wired or wireless manner, and the wireless manner can be achieved through WIFI, a mobile cellular network, NFC (near field communication) or other technologies. When the computer program is executed by the processor, a payment data processing method is implemented. The display screen of the computer device can be a liquid crystal display screen or an electronic ink display screen, and the input device of the computer device can be a touch layer covering the display screen, or a key, trackball or touchpad set on the computer device housing, or an external keyboard, touchpad or mouse, etc.
[0131] Those skilled in the art will understand that Figure 6 The structure shown in the figure is only a block diagram of a part of the structure related to the solution of the present application, and does not constitute a limitation on the computer device to which the solution of the present application is applied. The specific computer device may include more or fewer components than those shown in the figure, or combine certain components, or have a different arrangement of components.
[0132] In one embodiment, a computer device is provided, including a memory and a processor, wherein a computer program is stored in the memory, and when the processor executes the computer program, the following steps are implemented:
[0133] Respond to the payment operation triggered on the user interface and obtain the corresponding payment request;
[0134] Parse the payment information carried in the payment request to obtain a payment identification field and a corresponding payment field value; wherein the payment field value is related to a preset payment method and payment mode;
[0135] Parse the payment field value to obtain the payment method and corresponding payment mode;
[0136] Determine the target payment method from the payment methods, and complete the payment operation according to the target payment method and the corresponding target payment mode.
[0137] In one embodiment, when the processor executes the computer program, the processor further implements the following steps:
[0138] Parse the payment field value to obtain the bit value of each bit in the bitmap; wherein each bit in the bitmap represents a payment method;
[0139] According to the place value and the preset value, the payment mode corresponding to the payment method is determined.
[0140] In one embodiment, when the processor executes the computer program, the processor further implements the following steps:
[0141] When the bit value is the first preset value, the payment method is determined to use H5 page gateway payment;
[0142] When the value of the bitmap is the second preset value, the payment method is determined to call back the SDK class native payment method for payment.
[0143] In one embodiment, when the processor executes the computer program, the processor further implements the following steps:
[0144] When the target payment mode is to call back the SDK class native payment method, generate the payment transaction string for the payment operation;
[0145] By calling back the SDK native payment method, the payment transaction string is called back to the native payment end of the target payment method, the numerical resources that need to be transferred for the payment operation are transferred, and the payment operation is completed.
[0146] In one embodiment, when the processor executes the computer program, the processor further implements the following steps:
[0147] When the target payment mode is H5 page gateway payment, the payment operation is completed by transferring the numerical resources required for the payment operation through the H5 page gateway payment mode.
[0148] In one embodiment, when the processor executes the computer program, the processor further implements the following steps:
[0149] Obtain payment information for payment operations and verify it;
[0150] When the verification is passed, the numerical resources required for the payment operation are transferred to complete the payment operation.
[0151] In one embodiment, a computer readable storage medium is provided, on which a computer program is stored, and when the computer program is executed by a processor, the following steps are implemented:
[0152] Respond to the payment operation triggered on the user interface and obtain the corresponding payment request;
[0153] Parse the payment information carried in the payment request to obtain a payment identification field and a corresponding payment field value; wherein the payment field value is related to a preset payment method and payment mode;
[0154] Parse the payment field value to obtain the payment method and corresponding payment mode;
[0155] Determine the target payment method from the payment methods, and complete the payment operation according to the target payment method and the corresponding target payment mode.
[0156] In one embodiment, when the computer program is executed by a processor, the following steps are also implemented:
[0157] Parse the payment field value to obtain the bit value of each bit in the bitmap; wherein each bit in the bitmap represents a payment method;
[0158] According to the place value and the preset value, the payment mode corresponding to the payment method is determined.
[0159] In one embodiment, when the computer program is executed by a processor, the following steps are also implemented:
[0160] When the bit value is the first preset value, the payment method is determined to use H5 page gateway payment;
[0161] When the value of the bitmap is the second preset value, the payment method is determined to call back the SDK class native payment method for payment.
[0162] In one embodiment, when the computer program is executed by a processor, the following steps are also implemented:
[0163] When the target payment mode is to call back the SDK class native payment method, generate the payment transaction string for the payment operation;
[0164] By calling back the SDK native payment method, the payment transaction string is called back to the native payment end of the target payment method, the numerical resources that need to be transferred for the payment operation are transferred, and the payment operation is completed.
[0165] In one embodiment, when the computer program is executed by a processor, the following steps are also implemented:
[0166] When the target payment mode is H5 page gateway payment, the payment operation is completed by transferring the numerical resources required for the payment operation through the H5 page gateway payment mode.
[0167] In one embodiment, when the computer program is executed by a processor, the following steps are also implemented:
[0168] Obtain payment information for payment operations and verify it;
[0169] When the verification is passed, the numerical resources required for the payment operation are transferred to complete the payment operation.
[0170] In one embodiment, a computer program product is provided, comprising a computer program, which, when executed by a processor, implements the following steps:
[0171] Respond to the payment operation triggered on the user interface and obtain the corresponding payment request;
[0172] Parse the payment information carried in the payment request to obtain a payment identification field and a corresponding payment field value; wherein the payment field value is related to a preset payment method and payment mode;
[0173] Parse the payment field value to obtain the payment method and corresponding payment mode;
[0174] Determine the target payment method from the payment methods, and complete the payment operation according to the target payment method and the corresponding target payment mode.
[0175] In one embodiment, when the computer program is executed by a processor, the following steps are also implemented:
[0176] Parse the payment field value to obtain the bit value of each bit in the bitmap; wherein each bit in the bitmap represents a payment method;
[0177] According to the place value and the preset value, the payment mode corresponding to the payment method is determined.
[0178] In one embodiment, when the computer program is executed by a processor, the following steps are also implemented:
[0179] When the bit value is the first preset value, the payment method is determined to use H5 page gateway payment;
[0180] When the value of the bitmap is the second preset value, the payment method is determined to call back the SDK class native payment method for payment.
[0181] In one embodiment, when the computer program is executed by a processor, the following steps are also implemented:
[0182] When the target payment mode is to call back the SDK class native payment method, generate the payment transaction string for the payment operation;
[0183] By calling back the SDK native payment method, the payment transaction string is called back to the native payment end of the target payment method, the numerical resources that need to be transferred for the payment operation are transferred, and the payment operation is completed.
[0184] In one embodiment, when the computer program is executed by a processor, the following steps are also implemented:
[0185] When the target payment mode is H5 page gateway payment, the payment operation is completed by transferring the numerical resources required for the payment operation through the H5 page gateway payment mode.
[0186] In one embodiment, when the computer program is executed by a processor, the following steps are also implemented:
[0187] Obtain payment information for payment operations and verify it;
[0188] When the verification is passed, the numerical resources required for the payment operation are transferred to complete the payment operation.
[0189] It should be noted that the user information (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for analysis, stored data, displayed data, etc.) involved in this application are all information and data authorized by the user or fully authorized by all parties.
[0190] Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be completed by instructing the relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to the memory, database or other medium used in the embodiments provided in the present application can include at least one of non-volatile and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive random access memory (ReRAM), magnetoresistive random access memory (MRAM), ferroelectric random access memory (FRAM), phase change memory (PCM), graphene memory, etc. Volatile memory can include random access memory (RAM) or external cache memory, etc. As an illustration and not limitation, RAM can be in various forms, such as static random access memory (SRAM) or dynamic random access memory (DRAM). The database involved in each embodiment provided in this application may include at least one of a relational database and a non-relational database. Non-relational databases may include distributed databases based on blockchains, etc., but are not limited to this. The processor involved in each embodiment provided in this application may be a general-purpose processor, a central processing unit, a graphics processor, a digital signal processor, a programmable logic device, a data processing logic device based on quantum computing, etc., but are not limited to this.
[0191] The technical features of the above embodiments may be combined arbitrarily. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.
[0192] The above-described embodiments only express several implementation methods of the present application, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the present application. It should be pointed out that, for a person of ordinary skill in the art, several variations and improvements can be made without departing from the concept of the present application, and these all belong to the protection scope of the present application. Therefore, the protection scope of the present application shall be subject to the attached claims.
Claims
1. A payment data processing method, It is characterized in that The method comprises: Respond to the payment operation triggered on the user interface and obtain the corresponding payment request; Parsing the payment information carried in the payment request to obtain a payment identification field and a corresponding payment field value; wherein the payment field value is related to a preset payment method and payment mode, and the payment field value is a bitmap including at least one bit; Parsing the payment field value to obtain the bit value of each bit in the bitmap; wherein each bit at each position in the bitmap represents a payment method, and the bit value of each bit represents the payment mode of the payment method; When the bit value is a first preset value, it is determined that the payment method uses H5 page gateway payment; or, when the bitmap value is a second preset value, it is determined that the payment method uses callback SDK class native payment method payment; A target payment method is determined from the payment methods, and the payment operation is completed according to the target payment method and the corresponding target payment mode.
2. The method according to claim 1, It is characterized in that The step of completing the payment operation according to the target payment method and the corresponding target payment mode includes: When the target payment mode is a callback SDK-class native payment method, generating a payment transaction string for the payment operation; By calling back the SDK-type native payment method, the payment transaction string is called back to the payment native end of the target payment method, the numerical resources required to be transferred for the payment operation are transferred, and the payment operation is completed.
3. The method according to claim 1, It is characterized in that The step of completing the payment operation according to the target payment method and the corresponding target payment mode includes: When the target payment mode is H5 page gateway payment, the numerical resources required to be transferred for the payment operation are transferred through the payment mode of the H5 page gateway payment to complete the payment operation.
4. The method according to claim 2 or 3, It is characterized in that The transferring of the numerical resources required for the payment operation to complete the payment operation includes: Obtaining payment information for the payment operation and verifying it; When the verification is passed, the numerical resources required for the payment operation are transferred to complete the payment operation.
5. The method according to claim 2 or 3, It is characterized in that The method further comprises: When the type of the numerical resource that needs to be transferred by the payment operation is different from the target numerical resource type of the numerical resource recipient, the numerical resource that needs to be transferred by the payment operation is converted into a numerical resource of the corresponding target numerical resource type according to the corresponding conversion coefficient, and the numerical resource of the numerical resource recipient is updated.
6. The method according to claim 1, It is characterized in that The method further comprises: Obtain payment data of each user, including payment habit data of the user; The payment field value is updated according to the payment habit data.
7. A payment data processing device, It is characterized in that The device comprises: An acquisition module, used to respond to a payment operation triggered on the user interface and acquire a corresponding payment request; A first parsing module, configured to parse the payment information carried in the payment request to obtain a payment identification field and a corresponding payment field value; wherein the payment field value is related to a preset payment method and a payment processing method, and the payment field value is a bitmap including at least one bit; A second parsing module is configured to parse the payment field value to obtain a bit value of each bit in the bitmap; wherein each bit in the bitmap represents a payment method, and the bit value of each bit represents a payment mode of the payment method; A determination module, for determining that the payment method uses H5 page gateway payment when the bit value is a first preset value; or, when the value of the bitmap is a second preset value, determining that the payment method uses callback SDK class native payment method payment; The data processing module is used to determine the target payment method from the payment methods, and complete the payment operation according to the target payment method and the corresponding target payment mode.
8. The device according to claim 7, It is characterized in that The device also includes: A generation module, used for generating a payment transaction string for the payment operation when the target payment mode is a callback SDK class native payment method; The resource transfer module is used to call back the payment transaction string to the payment native end of the target payment method through the callback SDK class native payment method, transfer the numerical resources that need to be transferred for the payment operation, and complete the payment operation.
9. The device according to claim 8, It is characterized in that The resource transfer module is also used to transfer the numerical resources that need to be transferred for the payment operation through the payment mode of the H5 page gateway payment to complete the payment operation when the target payment mode is the H5 page gateway payment.
10. The device according to claim 8 or 9, It is characterized in that The device also includes: A verification module, used to obtain payment information of the payment operation and perform verification; The resource transfer module is also used to transfer the numerical resources required for the payment operation when the verification is passed, so as to complete the payment operation.
11. A computer device comprising a memory and a processor, wherein the memory stores a computer program. It is characterized in that When the processor executes the computer program, the steps of the method according to any one of claims 1 to 6 are implemented.
12. A computer-readable storage medium having a computer program stored thereon, It is characterized in that When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 6 are implemented.
13. A computer program product comprising a computer program, It is characterized in that When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 6 are implemented.
Citation Information
Patent Citations
Code scanning payment method and device for H5 webpage, equipment and storage medium
CN110647697A
Payment method and device, storage medium and electronic equipment
CN112232794A