Order data acquisition method, system and device, to-be-reconciliated platform and storage medium
By automatically generating order acquisition codes, the problem of rewriting codes when adding new payment methods in the existing technology is solved, and the efficiency of order data acquisition and code maintenance flexibility is improved.
Patent Information
- Application Number
- CN202510303812.1
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-03-14
- Publication Date
- 2025-06-20
AI Technical Summary
When the existing technology adds a newly supported payment method to the shopping platform, it is necessary to rewrite the code to obtain the corresponding order data, resulting in the inefficient acquisition of order data.
By obtaining the platform identity of the payment platform that currently needs to obtain order data and filling it in a preset code template, the order acquisition code is generated, thereby automatically generating a request for obtaining order data without rewriting the code.
It improves the efficiency of order data acquisition, reduces the difficulty of code maintenance when supporting new payment methods, and can quickly adapt to changes in payment methods.
Smart Images

Figure CN120181965A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the technical field of electronic payment, and particularly to an order data acquisition method, system, device, platform to be reconciled, and storage medium. Background Art
[0002] In the scenario of online shopping, when a user places an order on a shopping platform, the user can select a target payment method to be used from the payment methods supported by the shopping platform. The shopping platform will send the user's order data to the payment center, and the payment center will forward the order data to the target payment platform that provides the target payment method. Obviously, the user's order data can be recorded both locally on the shopping platform and in the payment center. To ensure the security of funds, the shopping platform can obtain the order data from the payment center, and then reconcile the recorded order data with the obtained order data, that is, reconcile with the payment center, to identify abnormal orders with problems such as duplicate payment and incorrect payment.
[0003] In the related art, for each payment method supported by the shopping platform, technicians can write code based on the identifier of the payment method. By running the written code, the shopping platform can generate a request indicating the payment method and send the request to the payment center. After receiving the request, the payment center can search for the order data paid through this payment method from the recorded order data, and then send the found order data to the shopping platform.
[0004] It can be seen that when the shopping platform newly supports a payment method, technicians need to write code based on the identifier of the newly added payment method, and only then can they obtain the order data paid through the newly added payment method from the payment center based on the newly written code. Obviously, this will result in low efficiency in obtaining order data. Summary of the Invention
[0005] The purpose of the embodiments of the present invention is to provide an order data acquisition method, system, device, platform to be reconciled, and storage medium to improve the efficiency of obtaining order data. The specific technical solutions are as follows:
[0006] In the first aspect of the present invention, first, an order data acquisition method is provided. The method is applied to a platform to be reconciled for providing an order placement service in a server, and the method includes:
[0007] Obtain the platform identifier of the payment platform for which order data needs to be obtained currently as the current platform identifier to be filled in;
[0008] Fill the current platform identifier to be filled into a preset code template to obtain the current order acquisition code; wherein, the code template is used for: generating an order acquisition request for obtaining order data, and sending the generated order acquisition request to the payment center;
[0009] Run the current order acquisition code to generate an order acquisition request for obtaining the current order data, and send the currently generated order acquisition request to the payment center, so that the payment center sends the current order data to the platform to be reconciled based on the received order acquisition request; wherein, the current order data is: order data paid through the payment platform for which the order data needs to be obtained currently;
[0010] Receive the current order data sent by the payment center.
[0011] Optionally, obtaining the platform identifier of the payment platform for which the order data needs to be obtained currently as the current platform identifier to be filled includes: determining the current platform identifier to be filled according to the recording order of the platform identifiers of each payment platform currently supported by the platform to be reconciled; after receiving the current order data sent by the payment center, the method further includes: returning to execute the step of determining the current platform identifier to be filled according to the recording order of the platform identifiers of each payment platform currently supported by the platform to be reconciled until the order data of each payment platform currently supported by the platform to be reconciled is obtained.
[0012] Optionally, the method further includes: when receiving a modification instruction for the recording order, modifying the recording order according to the modification method carried in the modification instruction; wherein, the modification method includes at least one of the following: adding a platform identifier to the recording order, deleting a specified platform identifier in the recording order, and adjusting the order of the platform identifiers in the recording order.
[0013] Optionally, obtaining the platform identifier of the payment platform for which the order data needs to be obtained currently as the current platform identifier to be filled includes: when receiving an order acquisition instruction carrying a preset acquisition period, obtaining the platform identifier of the payment platform for which the order data needs to be obtained currently as the current platform identifier to be filled every time the preset acquisition period is reached.
[0014] Optionally, filling the currently to-be-filled platform identifier into a preset code template to obtain the current order acquisition code includes: filling the currently to-be-filled platform identifier and a default time period into the preset code template to obtain the current order acquisition code; the default time period is the time period between the time when the order data for payment through the payment platform from which the current order data needs to be acquired was last acquired and the current time; running the current order acquisition code to generate an order acquisition request for acquiring the current order data and sending the currently generated order acquisition request to the payment center, so that the payment center sends the current order data to the to-be-reconciled platform based on the received order acquisition request, includes: running the current order acquisition code to generate an order acquisition request for acquiring the current order data within the default time period and sending the currently generated order acquisition request to the payment center, so that the payment center sends the current order data within the default time period to the to-be-reconciled platform based on the received order acquisition request.
[0015] Optionally, filling the currently to-be-filled platform identifier into a preset code template to obtain the current order acquisition code includes: filling the currently to-be-filled platform identifier and the identifier of the currently recorded interface into the preset code template to obtain the current order acquisition code; running the current order acquisition code to generate an order acquisition request for acquiring the current order data and sending the currently generated order acquisition request to the payment center, so that the payment center sends the current order data to the to-be-reconciled platform based on the received order acquisition request, includes: running the current order acquisition code to generate an order acquisition request for acquiring the current order data and sending the currently generated order acquisition request to the payment center through the interface indicated by the identifier of the currently recorded interface, so that the payment center sends the current order data to the to-be-reconciled platform based on the received order acquisition request.
[0016] Optionally, an order data records the order number and order amount of an order; after receiving the current order data sent by the payment center, the method further includes: for each payment platform that receives the order data from the payment center, searching, from the order data locally recorded by the pending reconciliation platform, for the pending reconciliation order data paid through this payment platform; for each pending reconciliation order data, determining whether there is pending comparison order data in the order data of this payment platform received, where the recorded order number is the same as the order number recorded in this pending reconciliation order data; in the case where there is no such pending comparison order data, determining that this pending reconciliation order data is abnormal; in the case where there is such pending comparison order data, determining whether the order amount recorded in the pending comparison order data is the same as the order amount recorded in this pending reconciliation order data; if the order amount recorded in the pending comparison order data is not the same as the order amount recorded in this pending reconciliation order data, determining that this pending reconciliation order data is abnormal; if the order amount recorded in the pending comparison order data is the same as the order amount recorded in this pending reconciliation order data, determining that this pending reconciliation order data is not abnormal.
[0017] In a second aspect of the implementation of the present invention, there is also provided an order data acquisition system, and the order data acquisition system includes a pending reconciliation platform and a payment center for providing order placement services in the server, where:
[0018] The pending reconciliation platform is used to execute the order data acquisition method described in any one of the first aspects above;
[0019] The payment center is used to send order data to the pending reconciliation platform based on the received order acquisition request sent by the pending reconciliation platform.
[0020] In a third aspect of the implementation of the present invention, there is also provided an order data acquisition device, and the device is applied to a pending reconciliation platform for providing order placement services in the server, and the device includes:
[0021] A first identifier acquisition module, configured to acquire the platform identifier of the payment platform that currently needs to acquire order data as the currently to-be-filled platform identifier;
[0022] A code acquisition module, configured to fill the currently to-be-filled platform identifier into a preset code template to obtain the current order acquisition code; where the code template is used to: generate an order acquisition request for acquiring order data and send the generated order acquisition request to the payment center;
[0023] The code running module is used to run the current order acquisition code to generate an order acquisition request for acquiring the current order data, and send the currently generated order acquisition request to the payment center, so that the payment center sends the current order data to the reconciliation platform based on the received order acquisition request; wherein, the current order data is: the order data paid through the payment platform for which the order data needs to be acquired currently.
[0024] The receiving module is used to receive the current order data sent by the payment center.
[0025] Optionally, the first identifier acquisition module is specifically configured to determine the currently to-be-filled platform identifier according to the recording order of the platform identifiers of each payment platform currently supported by the reconciliation platform.
[0026] The device further includes: a second identifier acquisition module, which is configured to, after the receiving module executes the step of receiving the current order data sent by the payment center, return to execute the step of determining the currently to-be-filled platform identifier according to the recording order of the platform identifiers of each payment platform currently supported by the reconciliation platform until the order data of each payment platform currently supported by the reconciliation platform is acquired.
[0027] Optionally, the device further includes: an adjustment module, which is configured to, when receiving a modification instruction for the recording order, modify the recording order according to the modification method carried in the modification instruction; wherein, the modification method includes at least one of the following: adding a platform identifier to the recording order, deleting a specified platform identifier in the recording order, and adjusting the order of the platform identifiers in the recording order.
[0028] Optionally, the first identifier acquisition module is specifically configured to, when receiving an order acquisition instruction carrying a preset acquisition period, acquire the platform identifier of the payment platform for which the order data needs to be acquired currently at each time the preset acquisition period is reached, as the currently to-be-filled platform identifier.
[0029] Optionally, the code acquisition module is specifically configured to fill the currently to-be-filled platform identifier and the default time period into a preset code template to obtain the current order acquisition code; the default time period is: the time period between the moment when the order data paid through the payment platform for which the order data needs to be acquired currently was acquired last time and the current moment; the code running module is specifically configured to run the current order acquisition code to generate an order acquisition request for acquiring the current order data within the default time period, and send the currently generated order acquisition request to the payment center, so that the payment center sends the current order data within the default time period to the reconciliation platform based on the received order acquisition request.
[0030] Optionally, the code acquisition module is specifically configured to fill the current platform identifier to be filled and the identifier of the currently recorded interface into a preset code template to obtain the current order acquisition code; the code running module is specifically configured to run the current order acquisition code to generate an order acquisition request for obtaining the current order data, and send the currently generated order acquisition request to the payment center through the interface indicated by the identifier of the currently recorded interface, so that the payment center sends the current order data to the platform to be reconciled based on the received order acquisition request.
[0031] Optionally, an order data records the order number and order amount of an order; the apparatus further includes: a reconciliation module, configured to, after the receiving module executes receiving the current order data sent by the payment center, for each payment platform that receives the order data from the payment center, search in the order data locally recorded by the platform to be reconciled for the order data to be reconciled that is paid through this payment platform; for each order data to be reconciled, determine whether there is order data to be compared whose recorded order number is the same as the order number recorded in the order data of this payment platform received; in the case where there is no such order data to be compared, determine that the order data to be reconciled is abnormal; in the case where there is such order data to be compared, determine whether the order amount recorded in the order data to be compared is the same as the order amount recorded in the order data to be reconciled; if the order amount recorded in the order data to be compared is not the same as the order amount recorded in the order data to be reconciled, determine that the order data to be reconciled is abnormal; if the order amount recorded in the order data to be compared is the same as the order amount recorded in the order data to be reconciled, determine that the order data to be reconciled is not abnormal.
[0032] In a fourth aspect of the embodiments of the present invention, there is provided a platform to be reconciled, including a processor, a communication interface, a memory, and a communication bus, where the processor, the communication interface, and the memory communicate with each other through the communication bus; the memory is used for storing a computer program; the processor is configured to, when executing the program stored on the memory, implement the order data acquisition method according to any one of the first aspects above.
[0033] In yet another aspect of the embodiments of the present invention, there is also provided a computer-readable storage medium, where the computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, it implements the order data acquisition method according to any one of the above.
[0034] In yet another aspect of the embodiments of the present invention, there is also provided a computer program product including instructions, and when it runs on a computer, it causes the computer to execute the order data acquisition method according to any one of the above.
[0035] In the order data acquisition method provided by an embodiment of the present invention, a reconciliation platform in a server that provides an order placement service obtains a platform identifier of a payment platform that currently needs to obtain order data as the current platform identifier to be filled in; fills the current platform identifier to be filled in into a preset code template to obtain a current order acquisition code; the code template is used for: generating an order acquisition request for obtaining order data and sending the generated order acquisition request to a payment center; running the current order acquisition code to generate an order acquisition request for obtaining the current order data and sending the currently generated order acquisition request to the payment center, so that the payment center sends the current order data to the reconciliation platform based on the received order acquisition request; the current order data is: order data paid through the payment platform that currently needs to obtain order data; receives the current order data sent by the payment center.
[0036] Based on the above processing, after the reconciliation platform in the server that provides the order placement service obtains the current platform identifier to be filled in of the payment platform that currently needs to obtain order data, it fills the current platform identifier to be filled in into the preset code template to obtain the current order acquisition code; obtains the current order data from the payment center by running the current order acquisition code. Obviously, when the payment methods supported by the reconciliation platform change, that is, when the payment platform that needs to obtain order data changes, only the platform identifier that can be obtained needs to be changed, and then the corresponding order acquisition code can be automatically generated based on the obtained platform identifier without having to rewrite the code, which can improve the order data acquisition efficiency. BRIEF DESCRIPTION OF THE DRAWINGS
[0037] In order to more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the following will briefly introduce the drawings required for the description of the embodiments or the prior art.
[0038] Figure 1 It is the first flowchart of the order data acquisition method provided by an embodiment of the present invention;
[0039] Figure 2 It is the second flowchart of the order data acquisition method provided by an embodiment of the present invention;
[0040] Figure 3 It is the third flowchart of the order data acquisition method provided by an embodiment of the present invention;
[0041] Figure 4 It is a structural diagram of an order data acquisition device provided by an embodiment of the present invention;
[0042] Figure 5 It is a structural diagram of a reconciliation platform provided by an embodiment of the present invention. DETAILED DESCRIPTION OF THE EMBODIMENTS
[0043] Next, the technical solutions in the embodiments of the present invention will be described in conjunction with the accompanying drawings in the embodiments of the present invention.
[0044] In the scenario of online shopping, when a user places an order on a shopping platform, the user can select a target payment method to be used from the payment methods supported by the shopping platform for payment. The shopping platform will send the user's order data to the payment center, and the payment center will forward the order data to the target payment platform that provides the target payment method. Obviously, the order data can be recorded both locally on the shopping platform and in the payment center. To ensure the security of funds, the shopping platform (i.e., the platform to be reconciled in the subsequent embodiments) can reconcile with the payment center to identify abnormal orders with problems such as duplicate payments and incorrect payments. In the related art, for each payment method supported by the shopping platform, technicians can write code based on the identifier of the payment method; based on the code written by the technicians, order data for payments made through the payment method can be obtained from the payment center. For example, for payment method 1 supported by shopping platform A, the platform identifier of payment platform 1 that provides payment method 1 is: mall_A. The technician writes code 1 based on the identifier "mall_A", runs code 1, and shopping platform A generates and sends request 1 carrying the identifier "mall_A" to the payment center; after receiving request 1, the payment center searches the recorded order data for the order data corresponding to the identifier "mall_A" (i.e., the order data for payments made through payment method 1), and then sends the found order data to shopping platform A.
[0045] It can be seen that when the shopping platform newly supports a payment method, the technician needs to write code based on the identifier of the newly added payment method, and only then can the order data for payments made through the newly added payment method be obtained from the payment center based on the newly written code. For example, if shopping platform A newly supports payment method 2, and the platform identifier of payment platform 2 that provides payment method 2 is: mall_A_plus, then the technician needs to write code 2 based on the identifier "mall_A_plus", run code 2, and shopping platform A generates and sends request 2 carrying the identifier "mall_A_plus" to the payment center. In this way, the payment center can subsequently send the order data for payments made through payment method 2 to shopping platform A based on request 2. Obviously, this will result in low efficiency in obtaining order data.
[0046] To solve the above problems, an embodiment of the present invention provides an order data acquisition method, which is applied to a reconciliation platform in a server for providing order placement services, that is, the reconciliation platform can support users' order placement operations. For example, if a user can purchase products on a mall platform, the mall platform can be the reconciliation platform; if a user can purchase video viewing permissions on a video platform, the video platform can also be the reconciliation platform. The present invention does not limit the specific type of the reconciliation platform.
[0047] The reconciliation platform obtains the platform identifier of the payment platform that currently needs to obtain order data as the current to-be-filled platform identifier. After that, the current to-be-filled platform identifier can be filled into a preset code template to obtain the current order acquisition code. The code template is used to: generate an order acquisition request for obtaining order data and send the generated order acquisition request to the payment center. Correspondingly, by running the current order acquisition code, the reconciliation platform can generate an order acquisition request for obtaining the current order data and send the currently generated order acquisition request to the payment center. The payment center can send the current order data to the reconciliation platform based on the received order acquisition request. The current order data is: the order data paid through the payment platform that currently needs to obtain order data. Furthermore, the reconciliation platform can receive the current order data sent by the payment center. In this way, the reconciliation platform obtains the order data that currently needs to be obtained from the payment center. Obviously, when the payment methods supported by the reconciliation platform change, that is, when the payment platform that needs to obtain order data changes, the reconciliation platform only needs to change the platform identifier that can be obtained, and then it can automatically generate the corresponding order acquisition code based on the obtained platform identifier without rewriting the code, which can improve the efficiency of order data acquisition.
[0048] See Figure 1 , Figure 1 which is the first flowchart of the order data acquisition method provided by an embodiment of the present invention. The order data acquisition method is applied to a reconciliation platform in a server for providing order placement services. The method may include the following steps:
[0049] S101: Obtain the platform identifier of the payment platform that currently needs to obtain order data as the current to-be-filled platform identifier.
[0050] S102: Fill the current to-be-filled platform identifier into a preset code template to obtain the current order acquisition code.
[0051] Among them, the code template is used to: generate an order acquisition request for obtaining order data and send the generated order acquisition request to the payment center.
[0052] S103: Run the current order acquisition code to generate an order acquisition request for obtaining the current order data, and send the currently generated order acquisition request to the payment center, so that the payment center sends the current order data to the platform to be reconciled based on the received order acquisition request.
[0053] Among them, the current order data is: the order data paid through the payment platform that currently needs to obtain order data.
[0054] S104: Receive the current order data sent by the payment center.
[0055] Based on the order data acquisition method provided in the embodiments of the present invention, after the platform to be reconciled in the server for providing the order placement service obtains the current platform identifier to be filled in of the payment platform that currently needs to obtain order data, it fills the current platform identifier to be filled in into a preset code template to obtain the current order acquisition code; by running the current order acquisition code, the current order data is obtained from the payment center. Obviously, when the payment methods supported by the platform to be reconciled change, that is, when the payment platform that needs to obtain order data changes, only the platform identifier that can be obtained needs to be changed, and then the corresponding order acquisition code can be automatically generated based on the obtained platform identifier, without having to rewrite the code, which can improve the order data acquisition efficiency.
[0056] Regarding step S101, the platform to be reconciled can support multiple payment methods, that is, when a user places an order on the platform to be reconciled, the user can select any payment platform from multiple payment platforms for payment. For each payment platform, the order data of this payment platform is: the order data when the user makes a payment through this payment platform when placing an order on the platform to be reconciled.
[0057] In some embodiments, for each payment platform, the platform identifier of this payment platform can indicate this payment platform and the platform to be reconciled. For example, the platform identifier of this payment platform can be: the identifier assigned by the payment center to this payment platform when the platform to be reconciled supports this payment platform. For example, for payment platform 1 supported by shopping platform A, the identifier assigned by the payment center to payment platform 1 can be: mall_A_1.
[0058] In some embodiments, for each payment platform, the platform identifier of this payment platform can indicate this payment platform but not the platform to be reconciled. For example, the identifier of payment platform 1 supported by shopping platform A can be: pay_1. Subsequently, the payment center can obtain the platform identifier of the platform to be reconciled based on the order acquisition request sent by the platform to be reconciled. For example, the platform to be reconciled can encapsulate the order acquisition request and the platform identifier of the platform to be reconciled into a request message and then send the request message to the payment center.
[0059] When it is necessary to obtain order data of a payment platform, the reconciliation platform to be reconciled can obtain the platform identifier of the payment platform for which order data needs to be obtained currently. The payment platform for which order data needs to be obtained currently is hereinafter referred to as the target payment platform; the platform identifier of the target payment platform is hereinafter referred to as the target platform identifier.
[0060] In one implementation, a technician can input an order acquisition instruction carrying the target platform identifier to the reconciliation platform to be reconciled. The reconciliation platform to be reconciled can extract the target platform identifier carried in the order acquisition instruction.
[0061] It can be understood that the number of target platform identifiers carried in the order acquisition instruction can be one or multiple. The present invention does not limit this.
[0062] There are also various ways for a technician to input an order acquisition instruction to the reconciliation platform to be reconciled. For example, for the convenience of the technician's operation, an operation interface can be displayed on the display interface of the reconciliation platform to be reconciled. The technician can input an order acquisition instruction to the reconciliation platform to be reconciled by clicking the order acquisition button provided in the operation interface.
[0063] In the case where the technician does not indicate the payment platform, the target platform identifier carried in the order acquisition instruction can be the platform identifiers of each payment platform supported by the reconciliation platform to be reconciled.
[0064] In the case where the technician indicates the payment platform, the target platform identifier carried in the order acquisition instruction is the platform identifier of the payment platform indicated by the technician. For example, an input box for the platform identifier can be provided in the operation interface, and the technician inputs the target platform identifier in this input box; or, the platform identifiers of each payment platform supported by the reconciliation platform to be reconciled can also be displayed in the operation interface, and the technician can select the target platform identifier of the target payment platform for which order data needs to be obtained currently among the platform identifiers displayed in the operation interface.
[0065] Obviously, in the actual scenario, there are more ways for a technician to input an order acquisition instruction carrying the target platform identifier to the reconciliation platform to be reconciled than this. The present invention does not limit the specific way for a technician to input an order acquisition instruction carrying the target platform identifier to the reconciliation platform to be reconciled.
[0066] In another implementation, the reconciliation platform to be reconciled can periodically obtain order data from the payment center, that is, the reconciliation platform to be reconciled can periodically obtain the target platform identifier. For the specific way for the reconciliation platform to be reconciled to periodically obtain the target platform identifier, refer to the detailed introduction in the subsequent embodiments.
[0067] Regarding step S102, the local reconciliation platform can store pre-written code templates. The code templates can be codes written by technicians in accordance with the writing methods specified by programming syntax and can be called through interfaces. Obviously, in the present invention, technicians only need to write the code templates, and there is no need to write codes for each payment platform.
[0068] The code templates can include multiple platform identifier filling positions where platform identifiers are not filled in. Filling in the platform identifier in the code template, that is, filling in the platform identifier at the platform identifier filling position in the code template, makes the code template filled with the platform identifier become a complete and runnable code. After filling in the platform identifier in the code template, running the code template filled with the platform identifier can achieve: generating an order acquisition request for acquiring order data of the payment platform indicated by the filled platform identifier, and sending the generated order acquisition request to the payment center.
[0069] It can be understood that when the target platform identifier is one, that is, when the current platform identifier to be filled in is one, the reconciliation platform fills the target platform identifier into the code template to obtain the current order acquisition code.
[0070] When the target platform identifiers are multiple, for example, when a technician selects multiple platform identifiers in the operation interface, the reconciliation platform can fill in the multiple target platform identifiers into the code template in a specified order. For example, the specified order can be the selection order of the technician. Correspondingly, after the reconciliation platform fills in the target platform identifier into the code template each time to obtain the order acquisition code, it can run the obtained order acquisition code to obtain the order data of the payment platform indicated by the currently filled target platform identifier. Obviously, the order acquisition code obtained by filling in the target platform identifier into the code template this time is the current order acquisition code.
[0071] Regarding steps S103 and S104, after the reconciliation platform obtains the current order acquisition code, it can run the current order acquisition code. For example, a compilation tool for running codes can be installed in the reconciliation platform, and the current order acquisition code is compiled in the compilation tool to run the current order acquisition code. Running the current order acquisition code means generating an order acquisition request for acquiring the current order data and sending the currently generated order acquisition request to the payment center. The currently generated order acquisition request can carry the current platform identifier to be filled in.
[0072] In some embodiments, for each order data recorded by the payment center, the payment center can correspondingly record the platform identifier of the payment platform used when completing the order data, and the platform identifier of the platform where the order data is placed.
[0073] At this time, when the platform identifier of a payment platform can indicate the payment platform and the platform to be reconciled, the payment center can extract the currently to-be-filled platform identifier carried in the received order acquisition request from the received order acquisition request. Then, according to the currently to-be-filled platform identifier extracted, the payment center can determine the target payment platform and the platform to be reconciled indicated by the currently to-be-filled platform identifier. Then, according to the platform identifier of the determined target payment platform and the platform identifier of the platform to be reconciled, the payment center can search for the order data that is placed an order on the platform to be reconciled and paid through the target payment platform from the recorded order data, that is, the current order data is found.
[0074] When the platform identifier of a payment platform can indicate the payment platform but does not indicate the platform to be reconciled, the payment center can obtain the platform identifier of the platform to be reconciled based on the order acquisition request sent by the platform to be reconciled. Exemplarily, if the platform to be reconciled encapsulates the currently generated order acquisition request and the platform identifier of the platform to be reconciled into a request message and then sends the request message to the payment center. Then the payment center can extract the platform identifier of the platform to be reconciled and the currently generated order acquisition request from the request message. According to the platform identifier of the platform to be reconciled extracted and the platform identifier of the payment platform carried in the currently generated order acquisition request, the payment center can search for the current order data from the recorded order data.
[0075] In some embodiments, when the platform to be reconciled supports a payment platform, the payment center can assign an identifier to the payment platform. The assigned identifier can indicate the platform to be reconciled and the payment platform. For each order data recorded by the payment center, the payment center can correspondingly record the identifier assigned to the payment platform to which the order data belongs.
[0076] At this time, when the platform identifier of a payment platform can indicate the payment platform and the platform to be reconciled, that is, when the platform identifier is the identifier assigned by the payment center to the payment platform, after the payment center extracts the currently to-be-filled platform identifier from the received order acquisition request, it can search for the order data whose corresponding recorded identifier is the currently to-be-filled platform identifier from the recorded order data, that is, the current order data is found.
[0077] In the case where the platform identifier of a payment platform can indicate the payment platform but not the platform to be reconciled, the payment center can obtain the platform identifier of the platform to be reconciled based on the order acquisition request sent by the platform to be reconciled. According to the platform identifier of the platform to be reconciled and the platform identifier of the payment platform carried in the received order acquisition request, the payment center can determine the identifier assigned by the payment center to the payment platform when the platform to be reconciled supports the payment platform. Then, from the recorded order data, search for the order data corresponding to the currently to-be-filled platform identifier, that is, the current order data is found.
[0078] After the payment center finds the current order data, it can send the current order data to the platform to be reconciled. For example, the payment center can send the current order data to the platform to be reconciled in sequence according to the order placement time corresponding to the current order data.
[0079] Alternatively, in order to improve the efficiency of sending order data to the platform to be reconciled, the payment center can make the current order data into a compressed package according to the specified compression method, and then send the compressed package to the platform to be reconciled. For example, the specified compression method can be: create a new folder and name the folder according to the preset naming method; after copying the current order data into the folder, use the zip (compression) method to compress the folder. For example, the preset naming method can be: name according to the naming format of "acquisition time - platform identifier - file format". For example, the naming of the compressed package can be "2024-01-01_mall_A_pay.csv.zip".
[0080] Correspondingly, after the shopping platform A obtains the compressed package sent by the payment center, it decompresses the compressed package according to the decompression method corresponding to the specified compression method to obtain the order data in the compressed package.
[0081] It can be understood that in the case where there are multiple payment platforms currently supported by the platform to be reconciled, the platform to be reconciled can decompress each compressed package after obtaining the compressed packages corresponding to each payment platform to obtain the order data of each payment platform; or, the platform to be reconciled can also decompress the obtained compressed package after obtaining the compressed package of each payment platform to obtain the order data of the payment platform.
[0082] In some embodiments, on the basis of Figure 1 referring to Figure 2 step S101 may include the following steps:
[0083] S1011: Determine the currently to-be-filled platform identifier according to the recorded order of the platform identifiers of each payment platform currently supported by the platform to be reconciled.
[0084] Correspondingly, after step S104, the method may further include the following steps:
[0085] S105: Return to execute the step of determining the current platform identifier to be filled in according to the record order of the platform identifiers of each payment platform currently supported by the reconciliation platform to be reconciled, until the order data of each payment platform currently supported by the reconciliation platform to be reconciled is obtained.
[0086] In the case where it is necessary to obtain the order data of each payment platform currently supported by the reconciliation platform to be reconciled, in order to obtain the order data of each payment platform, the reconciliation platform to be reconciled may traverse the platform identifiers of each payment platform currently supported by the reconciliation platform to be reconciled to sequentially obtain the order data of each payment platform currently supported by the reconciliation platform to be reconciled.
[0087] Specifically, the reconciliation platform to be reconciled may locally record the platform identifiers of each payment platform currently supported by the reconciliation platform to be reconciled. Then, the reconciliation platform to be reconciled may determine the current platform identifier to be filled in according to the record order of the above-mentioned platform identifiers currently recorded; based on the current platform identifier to be filled in, obtain the order data of the payment platform indicated by the current platform identifier to be filled in from the payment center; and then continue to determine the current platform identifier to be filled in according to the above record order. And so on, until the reconciliation platform to be reconciled obtains the order data of each payment platform currently supported by the reconciliation platform to be reconciled.
[0088] Exemplarily, the platform identifiers of each payment platform currently supported by the reconciliation platform A may be recorded in a data table, as shown in Table 1:
[0089] Table 1
[0090]
[0091] Among them, the business party is the payment platform that provides the corresponding payment method. For example, the "a payment business party" is the "payment platform that provides the a payment method", and the business party may also be recorded as partner (partner). The status of the business party may indicate whether the reconciliation platform A currently supports the business party. When the status of the business party is valid, the reconciliation platform A currently supports the payment party; when the status of the business party is invalid, the reconciliation platform A currently does not support the payment party. Based on Table 1, it can be seen that the payment platforms currently supported by the reconciliation platform A include: the a payment business party, the b payment business party, and the d payment business party. That is, when a user places an order on the reconciliation platform A, the user can select the payment method to be used from the a payment method, the b payment method, and the d payment method. The record order of the platform identifiers of each payment platform currently supported by the reconciliation platform A is: "mall_A", "mall_A_plus", "A_D".
[0092] Take the first platform identifier in the above record order, i.e., "mall_A", as the current platform identifier to be filled in. Fill the current platform identifier to be filled in into the code template to obtain the current order acquisition code; run the current order acquisition code to obtain the current order data from the payment center. In this way, the order data of Party A of Payment a is obtained. Then, take the next platform identifier in the record order, i.e., "mall_A_plus", as the current platform identifier to be filled in. Furthermore, obtain the current order data from the payment center based on the current platform identifier to be filled in. In this way, the order data of Party B of Payment b is obtained. Then, take the next platform identifier in the record order, i.e., "A_D", as the current platform identifier to be filled in. Furthermore, obtain the current order data from the payment center based on the current platform identifier to be filled in. In this way, the order data of Party D of Payment d is obtained. And so on until the platform to be reconciled obtains the order data of each payment platform currently supported by the platform to be reconciled. Since Payment c is not currently supported by the platform to be reconciled, that is, it is not necessary to take the platform identifier of Party C of Payment c, i.e., "A_C_pay", as the current platform identifier to be filled in.
[0093] Based on the above processing, the platform to be reconciled can traverse the platform identifiers of each payment platform currently supported by the platform to be reconciled and obtain the order data of each payment platform in turn until the order data of each payment platform currently supported by the platform to be reconciled is obtained. In this way, the probability that the order data of the payment platforms currently supported by the platform to be reconciled is not obtained can be reduced to obtain the order data of each payment platform currently supported by the platform to be reconciled.
[0094] In some embodiments, the method may further include the following steps: when a modification instruction for the record order is received, modify the record order according to the modification method carried in the modification instruction. The modification method includes at least one of the following: adding a platform identifier to the record order, deleting a specified platform identifier in the record order, and adjusting the order of the platform identifiers in the record order.
[0095] When the payment platforms currently supported by the platform to be reconciled change, the platform to be reconciled may receive a modification instruction for the record order. As in the foregoing example, an input box for the modification instruction may also be provided in the operation interface, and a technician may enter the modification instruction in the input box. For example, a technician may enter the platform identifier of the payment platform newly supported by the platform to be reconciled in the input box. Or, when the platform identifiers of each payment platform currently supported by the platform to be reconciled are recorded in a data table, a technician may also modify the data recorded in the data table. When the data recorded in the data table is changed, the platform to be reconciled receives the modification instruction; the modification method of the data recorded in the data table by the technician is the modification method carried in the modification instruction.
[0096] It can be understood that in an actual application scenario, the platform to be reconciled can add supported payment platforms or no longer support historically supported payment platforms; when obtaining orders from the payment center, the order data acquisition order of each payment platform can also be adjusted according to business requirements. Therefore, the modification method for the record order can indicate the above-mentioned various methods.
[0097] Specifically, when the platform to be reconciled adds a supported payment platform, the modification method includes adding a platform identifier to the record order. At this time, the modification instruction carries the platform identifier to be added. After receiving the modification instruction, the platform to be reconciled can add the platform identifier carried in the modification instruction to the record order, for example, adding the platform identifier to the end of the record order.
[0098] In some embodiments, the modification method can also indicate the record order corresponding to the platform identifier to be added. For example, if the platform to be reconciled newly supports Payment Platform 1 and needs to obtain the order data of Payment Platform 1 first, the modification method can indicate that the platform identifier of Payment Platform 1 should be recorded first. Correspondingly, after receiving the modification instruction, the platform to be reconciled can directly add the platform identifier of Payment Platform 1 to the front of the record order.
[0099] When the platform to be reconciled no longer supports a historically supported payment platform, the modification method includes deleting the specified platform identifier from the record order. At this time, the modification instruction also carries the specified platform identifier. After receiving the modification instruction, the platform to be reconciled can remove the specified platform identifier from the record order.
[0100] In some embodiments, when the platform identifiers of each payment platform currently supported by the platform to be reconciled are recorded in a data table and the status of each payment platform is also recorded in the data table, adding a platform identifier to the record order and removing the specified platform identifier can modify the status of the payment platforms recorded in the data table. Then, technicians only need to perform a simple status modification operation, such as changing "1" to "0", to update the record order, which can further improve the order acquisition efficiency.
[0101] When it is necessary to adjust the order data acquisition order of each payment platform, the modification method includes adjusting the order of the platform identifiers in the record order. At this time, the modification instruction can carry the platform identifier whose order is to be adjusted and the adjusted order of the platform identifier. After receiving the modification instruction, the platform to be reconciled can determine the platform identifier carried in the modification instruction from the record order, and then move the determined platform identifier to the position carried in the modification instruction.
[0102] Based on the above processing, when a modification instruction for the record order is received, the platform to be reconciled can update the record order. Subsequently, obtaining order data according to the updated record order means obtaining order data according to the payment platforms currently supported by the platform to be reconciled. This can reduce the probability that the order data of the payment platforms currently supported by the platform to be reconciled is not obtained, so as to obtain the order data of each payment platform currently supported by the platform to be reconciled; it can also reduce the probability that the order data of the payment platforms currently not supported by the platform to be reconciled is obtained, reduce the amount of data to be processed by the payment center, and make the payment center return the order data to be obtained more efficiently, that is, it can improve the efficiency of obtaining order data.
[0103] In some embodiments, step S1011 may include the following steps: when an order acquisition instruction carrying a preset acquisition period is received, at each time the preset acquisition period is reached, obtain the platform identifier of the payment platform for which order data needs to be obtained currently, as the current platform identifier to be filled in.
[0104] In the actual scenario, in order to ensure the security of funds, the platform to be reconciled usually obtains order data from the payment center periodically. The preset acquisition period can be determined according to actual needs. For example, the platform to be reconciled can obtain order data from the payment center at a specified time every day, such as the specified time can be five o'clock every day. Correspondingly, the preset acquisition period is one day. Obviously, if the technician needs to manually input the platform identifier to the platform to be reconciled every time order data is obtained, it will increase the labor cost. Therefore, in order to reduce the cost, the technician can input an order acquisition instruction carrying a preset acquisition period to the platform to be reconciled. Furthermore, at each time the preset acquisition period is reached, the platform to be reconciled can automatically obtain the platform identifier of the payment platform for which order data needs to be obtained currently, as the current platform identifier to be filled in; then based on the order data acquisition method provided by the present invention, obtain order data from the platform to be reconciled. That is, the platform to be reconciled obtains order data from the payment center periodically, which is convenient for unified management and verification of the obtained order data.
[0105] In some embodiments, after receiving the currently generated order acquisition request, the payment center can search for all order data that is placed an order on the platform to be reconciled and paid through the target payment platform. All the searched order data is the current order data.
[0106] In some embodiments, in order to reduce the probability of repeatedly obtaining order data, the currently generated order acquisition request sent by the platform to be reconciled to the payment center may also carry the time period of the order data to be obtained. For example, the code template may also include multiple time filling positions without filled time periods. After filling in the time in the time filling positions, the code template becomes a complete and runnable code.
[0107] In one implementation, an input box for a time period can also be provided in the operation interface, and technicians can enter a specified time period in the input box. Subsequently, the reconciliation platform can fill the specified time period entered by the technician into the time filling position to obtain a complete and executable code. Subsequently, the code is run to generate an order acquisition request for obtaining current order data within the specified time period; the currently generated order acquisition request is sent to the payment center, and the payment center sends the current order data within the specified time period to the reconciliation platform based on the received order acquisition request.
[0108] In another implementation, step S102 may include the following steps: filling the currently to-be-filled platform identifier and the default time period into the code template to obtain the current order acquisition code; wherein, the default time period is: the time period between the moment when the order data for payment through the payment platform for which order data needs to be obtained currently was last obtained and the current moment.
[0109] Correspondingly, step S103 may include the following steps: running the current order acquisition code to generate an order acquisition request for obtaining current order data within the default time period, and sending the currently generated order acquisition request to the payment center, so that the payment center sends the current order data within the default time period to the reconciliation platform based on the received order acquisition request.
[0110] For each payment platform for which order data needs to be obtained currently, the reconciliation platform can use the time period between the moment when the order data corresponding to the payment platform was last obtained and the current moment as the default time period for the payment platform. Or, in the case where the reconciliation platform periodically requests order data from the payment center, the reconciliation platform can use the time period between the moment when the last preset acquisition cycle was reached and the current moment as the default time period. Or, in the case where technicians can enter a specified time period, the default time period can be the time period between the moment when the technician enters the specified time period and the current moment; it can also be the time period between the end moment of the specified time period and the current moment. Obviously, the situations that may occur in the actual scenario are not limited to this, and the present invention does not limit the specific acquisition method of the default time period.
[0111] The reconciliation platform can fill the currently to-be-filled platform identifier into the platform identifier filling position and fill the default time period into the time filling position, that is, obtain a complete and executable code, that is, the current order acquisition code.
[0112] Run the current order acquisition code, and the reconciliation platform can generate a current order acquisition request for obtaining the current order data within the default time period. The current order data within the default time period is: within the default time period, the order data paid through the payment platform for which the order data needs to be obtained currently.
[0113] After the payment center receives the current order acquisition code, it can search for the current order data within the default time period from the recorded order data, and then send the current order data within the default time period to the reconciliation platform.
[0114] Based on the above processing, the reconciliation platform can obtain the order data within a certain time period only from the payment center, which can reduce the amount of data to be processed by the payment center, making the payment center return the order data to be obtained more efficiently, that is, it can improve the efficiency of obtaining order data. And it can reduce the probability that the reconciliation platform repeatedly obtains order data, so that the subsequent reconciliation platform does not need to perform repeated processing on the repeated order data, reducing the resource consumption of the reconciliation platform.
[0115] In some embodiments, step S102 may include the following steps: Fill the current platform identifier to be filled and the identifier of the currently recorded interface into the code template to obtain the current order acquisition code.
[0116] Correspondingly, step S103 may include the following steps: Run the current order acquisition code to generate an order acquisition request for obtaining the current order data, and send the currently generated order acquisition request to the payment center through the interface indicated by the identifier of the currently recorded interface, so that the payment center sends the current order data to the reconciliation platform based on the received order acquisition request.
[0117] In the actual scenario, the payment center can provide multiple interfaces. The reconciliation platform can send an order acquisition request to the payment center through the currently valid interface provided by the payment center. It can be understood that in the actual scenario, due to factors such as hardware performance and user requirements, the payment center may change the currently valid interface.
[0118] For example, the payment center can provide Interface A, Interface B, and Interface C. If within time period 1, there are 5 reconciliation platforms waiting to obtain order data from the payment center; and within time period 2, there is 1 reconciliation platform waiting to obtain order data from the payment center, then the technical staff on the payment center side can set that within time period 1, Interface A, Interface B, and Interface C are all valid interfaces; within time period 2, Interface A is the valid interface. During the operation of the payment center, Interface A has a hardware failure and needs to be repaired; then within time period 1, the reconciliation platforms need to send order acquisition requests to the payment center through Interface B and Interface C; within time period 2, they can send order acquisition requests to the payment center through Interface B. That is, in the actual scenario, there may be a situation where the interface for sending order acquisition requests to the payment center needs to be modified.
[0119] Therefore, to facilitate handling in the above situations, the code template can also include positions for filling in interface identifiers where the interface identifiers are not filled in; the reconciliation platforms can also correspondingly record the identifiers of the currently available interfaces of the payment center. Filling in the identifier of the currently recorded interface in the interface identifier filling position can obtain the complete and runnable current order acquisition code. Running the current order acquisition code, the reconciliation platforms can generate order acquisition requests for obtaining the current order data and send the currently generated order acquisition requests to the payment center through the interface indicated by the identifier of the currently filled-in interface.
[0120] Exemplarily, the payment center can send the identifiers of its currently valid interfaces to the reconciliation platforms, and the reconciliation platforms can record the received interface identifiers locally. When it is necessary to generate the order acquisition code, the locally recorded interface identifiers are filled into the interface identifier filling positions. When the currently valid interfaces of the payment center change, the payment center can send indication information indicating the change of the valid interfaces to the reconciliation platforms, and the reconciliation platforms can update the identifiers of the locally recorded interfaces based on the indication information.
[0121] It can be understood that there can also be multiple currently valid interface identifiers of the payment center. In this case, configuration can be performed based on these multiple interface identifiers according to business requirements.
[0122] For example, the technical staff can set the usage priorities of multiple interfaces, and the reconciliation platforms can fill in the identifier of the currently valid interface with the highest priority into the interface identifier filling position.
[0123] For example, the reconciliation platforms can obtain order data corresponding to different payment platforms through different interfaces. For example, the identifiers of the interfaces corresponding to each payment business party can be correspondingly recorded in the above data table. Subsequently, the identifier of the interface corresponding to this payment business party is filled into the interface identifier filling position to obtain the order acquisition code corresponding to this payment business party.
[0124] Obviously, in the actual scenario, the recording method, usage method, etc. of the interface identifier are more than this, and the present invention does not limit this.
[0125] Compared with the prior art, the more payment platforms currently supported by the reconciliation platform to be reconciled, the larger the amount of code involved in the prior art. When the currently effective interfaces in the payment center are changed, based on the prior art, it is necessary to search for the identifiers of the interfaces to be changed in a large amount of code, and then modify them to the identifiers of the interfaces to be changed one by one, and the modification process is cumbersome and complex. However, based on the embodiments of the present invention, only the identifier of the interface recorded by the reconciliation platform to be reconciled needs to be changed, the modification process is simple, and the maintenance difficulty is low. And obviously, the more payment platforms supported by the reconciliation platform to be reconciled, the more prominent the advantage of low code maintenance difficulty of the present invention.
[0126] In some embodiments, an order number and an order amount of an order are recorded in an order data.
[0127] After step S104, the method may further include the following steps:
[0128] Step 1: For each payment platform that receives order data from the payment center, search for the reconciliation order data to be reconciled that is paid through the payment platform from the order data recorded locally by the reconciliation platform.
[0129] Step 2: For each reconciliation order data, determine whether there is comparison order data in the order data of the received payment platform whose recorded order number is the same as the order number recorded in the reconciliation order data; in the case where there is no comparison order data, determine that the reconciliation order data is abnormal; in the case where there is comparison order data, determine whether the order amount recorded in the comparison order data is the same as the order amount recorded in the reconciliation order data.
[0130] Step 3: If the order amount recorded in the comparison order data is not the same as the order amount recorded in the reconciliation order data, determine that the reconciliation order data is abnormal; if the order amount recorded in the comparison order data is the same as the order amount recorded in the reconciliation order data, determine that the reconciliation order data is not abnormal.
[0131] The order data obtained by the reconciliation platform from the payment center is the order data recorded by the payment center for payments made through the payment platform. To ensure the safety of funds, the reconciliation platform can compare the data recorded by the payment center with the data recorded locally.
[0132] Specifically, for each payment platform that receives order data from the payment center, that is, for each payment platform supported by the platform to be reconciled, the platform to be reconciled can search for the order data to be reconciled that is paid through this payment platform from the order data recorded locally. When the platform to be reconciled records order data locally, it will correspondingly record the platform identifier corresponding to each order data, that is, record which payment platform each order data is paid through. When conducting reconciliation, the platform to be reconciled can also search for the order data of each payment platform from the order data recorded locally in the order of the recorded platform identifiers of each payment platform, that is, based on the order data obtained from the payment center, reconcile the order data of each payment platform in turn.
[0133] For each order data to be reconciled, when there is no pending comparison order data in the order data of this payment platform received, whose recorded order number is the same as the order number recorded in this order data to be reconciled, that is, when the payment center does not record the order data corresponding to this order data to be reconciled, this order data to be reconciled is abnormal. For example, the order corresponding to this order data to be reconciled (the subsequent order to be reconciled) may not have been paid in full.
[0134] When there is pending comparison order data, if the order amount recorded in the pending comparison order data is inconsistent with the order amount recorded in this order data to be reconciled, that is, there may be an abnormal payment situation for the order to be reconciled, such as double payment. Obviously, this order data to be reconciled is also abnormal.
[0135] It can be understood that for each payment platform that receives order data from the payment center, after the platform to be reconciled obtains the order data paid through this payment platform from the payment center, it can conduct reconciliation based on the obtained order data. Or, the platform to be reconciled can also conduct reconciliation on all the obtained order data after obtaining the order data of each payment platform currently supported by the platform to be reconciled from the payment center.
[0136] It can be understood that in the case where the platform to be reconciled obtains order data within a certain time period from the payment center each time, the platform to be reconciled can search for the order data to be reconciled that is paid through the payment platform for which order data needs to be obtained currently from the order data recorded locally. Subsequently, reconcile the order data to be reconciled within this time period.
[0137] Based on the above processing, the platform to be reconciled can reconcile with the payment center to identify abnormal orders with problems such as double payment and incorrect payment, ensuring the security of funds.
[0138] In some embodiments, refer to Figure 3 , Figure 3The third flowchart of the order data acquisition method provided by the embodiment of the present invention. The method may include the following steps:
[0139] S1: The reconciliation task arrives (reconcile the data of yesterday every morning at 0:00).
[0140] In this step, when the reconciliation task arrives, it means reaching the preset acquisition period in the foregoing embodiment. In the embodiment of the present invention, the preset acquisition period is one day.
[0141] S2: Query the quantity ordered by the mall yesterday.
[0142] In this step, the mall is the platform to be reconciled in the foregoing embodiment; the quantity ordered by the mall yesterday is the data locally recorded by the platform to be reconciled: within the current acquisition period, the order data paid through various payment methods on the platform to be reconciled, that is, the mall data introduced later.
[0143] S3: Query the configured business party data table and traverse the returned data.
[0144] In this step, the business party is the payment platform in the foregoing embodiment; the business party data table is the data table that records the platform identifiers of each payment platform currently supported by the platform to be reconciled in the foregoing embodiment.
[0145] That is, the platform to be reconciled traverses the data table to obtain the platform identifiers of each payment platform currently supported by the platform to be reconciled.
[0146] S4: Request the payment center to obtain data according to the identifier "mall_A_plus"; obtain the "2024-01-01_mall_A_plus_pay.csv.zip" returned by the payment center.
[0147] In this step, after obtaining the platform identifier mall_A_plus, the platform to be reconciled can fill the platform identifier mall_A_plus into a preset code template to obtain the current order acquisition code; run the current order acquisition code to generate an order acquisition request for obtaining the current order data, and send the currently generated order acquisition request to the payment center. The payment center searches for the current order data based on the received order acquisition request; makes the current order data into a compressed package according to the specified compression method, and the name of this compressed package is "2024-01-01_mall_A_plus_pay.csv.zip", and then sends this compressed package to the platform to be reconciled.
[0148] S5: Request the payment center to obtain data according to the identifier "mall_A"; obtain the "2024-01-01_mall_A_pay.csv.zip" returned by the payment center.
[0149] In this step, after the reconciliation platform obtains the platform identifier mall_A, it can fill the platform identifier mall_A into the code template to obtain the current order acquisition code; run the current order acquisition code to generate an order acquisition request for obtaining the current order data, and send the currently generated order acquisition request to the payment center. Based on the received order acquisition request, the payment center searches for the current order data; according to the specified compression method, it makes the current order data into a compressed package named "2024-01-01_mall_A_pay.csv.zip", and then sends this compressed package to the reconciliation platform.
[0150] S6: Unzip and summarize.
[0151] In this step, after the reconciliation platform obtains the compressed packages of the order data of each payment platform sent by the payment center, it can unzip these compressed packages, and then summarize the unzipped order data, such as sorting these orders according to the order number.
[0152] S7: Compare and record with the mall data.
[0153] In this step, the mall data is the order data locally recorded by the reconciliation platform in the foregoing embodiment: within the current acquisition cycle, the order data paid through each payment method on the reconciliation platform.
[0154] For each payment platform currently supported by the reconciliation platform, the reconciliation platform can search the locally recorded order data for the reconciliation order data paid through this payment platform within the current acquisition cycle. For each reconciliation order data, based on the order number of this reconciliation order data, it is determined whether there is comparable order data with the same order number in the order data obtained from the payment center. In the case where there is no comparable order data, this reconciliation order data is abnormal; in the case where there is comparable order data, if the order amount recorded in the comparable order data is inconsistent with the order amount recorded in this reconciliation order data, this reconciliation order data is abnormal.
[0155] Based on the above processing, after the reconciliation platform for providing the order placement service in the server obtains the current platform identifier to be filled in for the payment platform that currently needs to obtain order data, it fills the current platform identifier to be filled in into the preset code template to obtain the current order acquisition code; by running the current order acquisition code, it obtains the current order data from the payment center. Obviously, when the payment methods supported by the reconciliation platform change, that is, when the payment platform for which order data needs to be obtained changes, only the obtained platform identifier needs to be changed, and then the corresponding order acquisition code can be automatically generated based on the obtained platform identifier, without having to rewrite the code, which can improve the order data acquisition efficiency.
[0156] Moreover, since the platform to be reconciled can maintain the partner data assigned by the payment center through a data table, when a newly supported payment platform is added to the platform to be reconciled, that is, when a new payment partner is docked, the newly docked payment partner can be stored in the configuration table (i.e., the aforementioned data table). When the reconciliation task is executed, that is, when obtaining order data from the payment center, the platform to be reconciled first obtains data from the configuration table, that is, obtains the platform identifiers of each payment platform currently supported by the platform to be reconciled. And since in the present invention, order acquisition code can be obtained based on a code template, that is, different partner data is configured and the variable logic is removed, so that the code process can be reused, thereby enabling the code process to support the reconciliation data functions of different partners, that is, different platform identifiers can be filled into the code template to obtain order acquisition code for obtaining order data of different payment platforms. That is, the variable logic is configured, optimizing the code logic to achieve dynamic implementation, and subsequent reconciliation logic will not be modified due to new payment method partners.
[0157] Therefore, after the platform to be reconciled obtains the platform identifiers of each payment platform currently supported, it can traverse and request the payment center interface based on the code template to obtain order data corresponding to the partner. The order data obtained from the payment center is summarized and then compared with the order data recorded locally in the mall. When the number of order data is inconsistent, and / or when the order amounts in the order data with the same order number are inconsistent, it can be determined that the order data is abnormal. Subsequently, no matter how many payment methods the mall docks, it can query the partner configuration table and dynamically obtain the reconciliation data according to the partner, without modifying the reconciliation logic every time a payment method is docked, thus improving the order acquisition efficiency.
[0158] And it can be understood that since the variable logic is configured in the present invention and the reconciliation data functions of different partners are implemented through a reusable code process, when the number of payment platforms supported by the platform to be reconciled is large, the amount of code for executing the order data acquisition method provided by the present invention is necessarily less than that of the method of writing corresponding code for each payment platform in the prior art.
[0159] Exemplarily, the amount of code for writing code for one payment platform is about 15 lines. In the case where the platform to be reconciled supports n payment platforms, based on the prior art, technicians need to write n × 15 lines of code to obtain code for obtaining order data corresponding to each payment platform.
[0160] Based on the order data acquisition method provided by the present invention, the code for obtaining the order data corresponding to each payment platform can be obtained only by including the code for calling the configuration table, the code representing loop processing, and the code corresponding to the code template. That is, the code obtained based on the present invention includes (15 + m) lines of code. In an actual scenario, m is usually only dozens of lines of code, and the configuration table to be called usually only includes n lines of data.
[0161] It can be seen that when the number of payment platforms supported by the platform to be reconciled is greater than the platform number threshold, the amount of code involved in the present invention is less than that involved in the prior art. That is, the code involved in the present invention is more concise and has a lower maintenance difficulty. The platform number threshold is calculated based on the specific amount of code for a payment platform and the specific amounts of code representing the code for calling the configuration table and the code for loop processing written in the actual scenario. Obviously, the more payment platforms supported by the platform to be reconciled, the more prominent the advantages of the concise code and low maintenance difficulty of the present invention.
[0162] The present invention also provides an order data acquisition system. The order data acquisition system includes a platform to be reconciled and a payment center in the server for providing order placement services, where: the platform to be reconciled is used to execute any one of the order data acquisition methods in the foregoing embodiments; the payment center is used to send order data to the platform to be reconciled based on the order acquisition request received from the platform to be reconciled.
[0163] Based on the above processing, after the platform to be reconciled in the server for providing order placement services obtains the current platform identifier to be filled in for the payment platform that currently needs to obtain order data, it fills the current platform identifier to be filled in into a preset code template to obtain the current order acquisition code; by running the current order acquisition code, it obtains the current order data from the payment center. Obviously, when the payment method supported by the platform to be reconciled changes, that is, when the payment platform that needs to obtain order data changes, only the platform identifier that can be obtained needs to be changed, and then the corresponding order acquisition code can be automatically generated based on the obtained platform identifier without having to rewrite the code, which can improve the order data acquisition efficiency.
[0164] Based on the same inventive concept as the above order data acquisition method, an embodiment of the present invention also provides an order data acquisition device, and the device is applied to the platform to be reconciled in the server for providing order placement services. See Figure 4 , Figure 4 which is a structural diagram of the order data acquisition device provided by the embodiment of the present invention. The device includes:
[0165] A first identifier acquisition module 401, configured to acquire the platform identifier of the payment platform that currently needs to obtain order data as the current platform identifier to be filled in;
[0166] A code acquisition module 402, configured to fill the currently to-be-filled platform identifier into a preset code template to obtain a current order acquisition code; wherein, the code template is used to: generate an order acquisition request for acquiring order data, and send the generated order acquisition request to a payment center.
[0167] A code running module 403, configured to run the current order acquisition code to generate an order acquisition request for acquiring the current order data, and send the currently generated order acquisition request to the payment center, so that the payment center sends the current order data to the to-be-reconciled platform based on the received order acquisition request; wherein, the current order data is: order data paid through the payment platform for which the order data needs to be acquired currently.
[0168] A receiving module 404, configured to receive the current order data sent by the payment center.
[0169] Optionally, the first identifier acquisition module 401 is specifically configured to determine the currently to-be-filled platform identifier according to the record order of the platform identifiers of the payment platforms currently supported by the to-be-reconciled platform.
[0170] The device further includes: a second identifier acquisition module, configured to, after the receiving module 404 executes receiving the current order data sent by the payment center, return to execute the step of determining the currently to-be-filled platform identifier according to the record order of the platform identifiers of the payment platforms currently supported by the to-be-reconciled platform until the order data of the payment platforms currently supported by the to-be-reconciled platform is acquired.
[0171] Optionally, the device further includes: an adjustment module, configured to, when receiving a modification instruction for the record order, modify the record order according to the modification method carried in the modification instruction; wherein, the modification method includes at least one of the following: adding a platform identifier to the record order, deleting a specified platform identifier from the record order, and adjusting the order of the platform identifiers in the record order.
[0172] Optionally, the first identifier acquisition module 401 is specifically configured to, when receiving an order acquisition instruction carrying a preset acquisition period, obtain the platform identifier of the payment platform for which the order data needs to be acquired currently at each time when the preset acquisition period is reached, as the currently to-be-filled platform identifier.
[0173] Optionally, the code acquisition module 402 is specifically configured to fill the current platform identifier to be filled and the default time period into the code template to obtain the current order acquisition code; the default time period is the time period between the time when the order data of the payment platform that needs to obtain order data currently was last obtained and the current time; the code execution module 403 is specifically configured to execute the current order acquisition code to generate an order acquisition request for obtaining the current order data within the default time period, and send the currently generated order acquisition request to the payment center, so that the payment center sends the current order data within the default time period to the reconciliation platform to be reconciled based on the received order acquisition request.
[0174] Optionally, the code acquisition module 402 is specifically configured to fill the current platform identifier to be filled and the identifier of the currently recorded interface into the code template to obtain the current order acquisition code; the code execution module 403 is specifically configured to execute the current order acquisition code to generate an order acquisition request for obtaining the current order data, and send the currently generated order acquisition request to the payment center through the interface indicated by the identifier of the currently recorded interface, so that the payment center sends the current order data to the reconciliation platform to be reconciled based on the received order acquisition request.
[0175] Optionally, an order data records the order number and order amount of an order.
[0176] The apparatus further includes a reconciliation module, configured to, after the receiving module 404 receives the current order data sent by the payment center, for each payment platform from which the order data is received from the payment center, find the order data to be reconciled that is paid through this payment platform from the order data locally recorded by the reconciliation platform to be reconciled; for each order data to be reconciled, determine whether there is order data to be compared whose recorded order number is the same as the order number recorded in the order data of this payment platform received; in the case where there is no such order data to be compared, determine that the order data to be reconciled is abnormal; in the case where there is such order data to be compared, determine whether the order amount recorded in the order data to be compared is the same as the order amount recorded in the order data to be reconciled; if the order amount recorded in the order data to be compared is not the same as the order amount recorded in the order data to be reconciled, determine that the order data to be reconciled is abnormal; if the order amount recorded in the order data to be compared is the same as the order amount recorded in the order data to be reconciled, determine that the order data to be reconciled is normal.
[0177] Based on the order data acquisition device provided by the embodiments of the present invention, after the reconciliation platform in the server for providing order placement services obtains the current platform identifier to be filled in of the payment platform that currently needs to obtain order data, it fills the current platform identifier to be filled in into a preset code template to obtain the current order acquisition code; by running the current order acquisition code, it obtains the current order data from the payment center. Obviously, when the payment methods supported by the reconciliation platform change, that is, when the payment platform that needs to obtain order data changes, only the platform identifier that can be obtained needs to be changed, and subsequently, the corresponding order acquisition code can be automatically generated based on the obtained platform identifier without having to rewrite the code, which can improve the order data acquisition efficiency.
[0178] The embodiments of the present invention also provide a reconciliation platform, as Figure 5 shown, including a processor 501, a communication interface 502, a memory 503, and a communication bus 504. Among them, the processor 501, the communication interface 502, and the memory 503 communicate with each other through the communication bus 504. The memory 503 is used to store a computer program; the processor 501 is used to implement the order data acquisition method described in any one of the foregoing embodiments when executing the program stored on the memory 503.
[0179] The communication bus mentioned in the above terminal may be a Peripheral Component Interconnect (PCI) bus or an Extended Industry Standard Architecture (EISA) bus, etc. This communication bus can be divided into an address bus, a data bus, a control bus, etc. For the sake of convenience of representation, only a thick line is shown in the figure, but it does not mean that there is only one bus or one type of bus.
[0180] The communication interface is used for communication between the above terminal and other devices.
[0181] The memory may include a Random Access Memory (RAM), or may also include a non-volatile memory, such as at least one disk memory. Optionally, the memory may also be at least one storage device located far from the foregoing processor.
[0182] The above-mentioned processor may be a general-purpose processor, including a Central Processing Unit (CPU for short), a Network Processor (NP for short), etc.; it may also be a Digital Signal Processor (DSP for short), an Application Specific Integrated Circuit (ASIC for short), a Field-Programmable Gate Array (FPGA for short), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components.
[0183] In another embodiment provided by the present invention, a computer-readable storage medium is further provided. A computer program is stored in the computer-readable storage medium. When the computer program is executed by a processor, the order data acquisition method described in any one of the above embodiments is implemented.
[0184] In another embodiment provided by the present invention, a computer program product containing instructions is further provided. When it runs on a computer, the computer is caused to execute the order data acquisition method described in any one of the above embodiments.
[0185] In the above embodiments, it can be implemented in whole or in part by software, hardware, firmware, or any combination thereof. When implemented using software, it can be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on a computer, the processes or functions described in the embodiments of the present invention are generated in whole or in part. The computer may be a general-purpose computer, a special-purpose computer, a computer network, or other programmable devices. The computer instructions may be stored in a computer-readable storage medium, or transmitted from one computer-readable storage medium to another computer-readable storage medium. For example, the computer instructions may be transmitted from one website, computer, server, or data center to another website, computer, server, or data center in a wired manner (such as coaxial cable, optical fiber, Digital Subscriber Line (DSL)) or a wireless manner (such as infrared, wireless, microwave, etc.). The computer-readable storage medium may be any available medium that can be accessed by a computer, or a data storage device such as a server or data center that includes one or more integrated available media. The available medium may be a magnetic medium (such as a floppy disk, a hard disk, a magnetic tape), an optical medium (such as a DVD), or a semiconductor medium (such as a Solid State Disk (SSD)).
[0186] It should be noted that in this text, relational terms such as first and second are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any actual relationship or order between these entities or operations. Moreover, the terms "comprising", "including" or any other variant thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device comprising a series of elements not only includes those elements, but also includes other elements not expressly listed, or further includes elements inherent to such process, method, article or device. Without further limitation, an element defined by the statement "comprising a..." does not exclude the existence of additional identical elements in the process, method, article or device comprising the said element.
[0187] Each embodiment in this specification is described in a related manner. For the same or similar parts among the embodiments, reference can be made to each other. Each embodiment focuses on the differences from other embodiments. In particular, for embodiments of a system, device, reconciliation platform to be reconciled, computer-readable storage medium, and computer program product, since they are basically similar to the method embodiments, the description is relatively simple, and reference can be made to the partial description of the method embodiments for the relevant parts.
[0188] The above description is only a preferred embodiment of the present invention and is not intended to limit the protection scope of the present invention. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present invention are included within the protection scope of the present invention.
Claims
1. A method for acquiring order data, characterized in that: The method is applied to a pending reconciliation platform for providing order placement services on a server side, and the method includes: Obtain the platform ID of the payment platform for which order data is currently to be obtained, as the current platform ID to be filled in; Fill the current platform identifier to be filled into the preset code template to obtain the current order acquisition code; wherein the code template is used to: generate an order acquisition request for acquiring order data, and send the generated order acquisition request to the payment center; Run the current order acquisition code to generate an order acquisition request for acquiring the current order data, and send the currently generated order acquisition request to the payment center, so that the payment center sends the current order data to the to-be-reconciled platform based on the received order acquisition request; wherein the current order data is: order data paid through the payment platform for which the order data currently needs to be acquired; Receive the current order data sent by the payment center.
2. The method according to claim 1, characterized in that The step of obtaining the platform identifier of the payment platform for which order data is currently to be obtained as the current platform identifier to be filled in includes: Determine the current platform identifier to be filled in according to the order of recording the platform identifiers of the payment platforms currently supported by the to-be-reconciled platform; After receiving the current order data sent by the payment center, the method further includes: Return to the step of determining the current platform identifier to be filled in according to the order of recording the platform identifiers of the payment platforms currently supported by the platform to be reconciled, until the order data of the payment platforms currently supported by the platform to be reconciled is obtained.
3. The method according to claim 2, characterized in that The method further comprises: When a modification instruction for the record sequence is received, the record sequence is modified according to the modification method carried in the modification instruction; wherein the modification method includes at least one of the following: adding a platform identifier to the record sequence, deleting a specified platform identifier in the record sequence, and adjusting the order of platform identifiers in the record sequence.
4. The method according to claim 1, characterized in that: The step of obtaining the platform identifier of the payment platform for which order data is currently to be obtained as the current platform identifier to be filled in includes: When an order acquisition instruction carrying a preset acquisition cycle is received, each time the preset acquisition cycle is reached, the platform identifier of the payment platform for which order data is currently required to be acquired is acquired as the current platform identifier to be filled in.
5. The method according to claim 1, characterized in that The step of filling the current platform identifier to be filled into the preset code template to obtain the current order acquisition code includes: Fill the current platform identifier and default time period into the preset code template to obtain the current order acquisition code; the default time period is: the time period between the last time the order data for payment was obtained through the payment platform for which the order data currently needs to be obtained and the current time; The running of the current order acquisition code to generate an order acquisition request for acquiring the current order data, and sending the currently generated order acquisition request to the payment center, so that the payment center sends the current order data to the to-be-reconciled platform based on the received order acquisition request, includes: Run the current order acquisition code to generate an order acquisition request for acquiring the current order data within the default time period, and send the currently generated order acquisition request to the payment center, so that the payment center sends the current order data within the default time period to the reconciliation platform based on the received order acquisition request.
6. The method according to claim 1, characterized in that The step of filling the current platform identifier to be filled into the preset code template to obtain the current order acquisition code includes: Fill the current platform ID to be filled in and the ID of the currently recorded interface into the preset code template to obtain the current order acquisition code; The running of the current order acquisition code to generate an order acquisition request for acquiring the current order data, and sending the currently generated order acquisition request to the payment center, so that the payment center sends the current order data to the to-be-reconciled platform based on the received order acquisition request, includes: Run the current order acquisition code to generate an order acquisition request for acquiring the current order data, and send the currently generated order acquisition request to the payment center through the interface indicated by the identifier of the currently recorded interface, so that the payment center sends the current order data to the reconciliation platform based on the received order acquisition request.
7. The method according to claim 1, characterized in that An order record contains an order number and an order amount. After receiving the current order data sent by the payment center, the method further includes: For each payment platform that has received order data from the payment center, searching for order data to be reconciled that has been paid through the payment platform from among the order data locally recorded by the platform to be reconciled; For each order data to be reconciled, determine whether there is any order data to be compared whose recorded order number is consistent with the order number recorded in the order data to be reconciled in the order data received from the payment platform; In the case where the order data to be compared does not exist, determining that the order data to be reconciled is abnormal; In the case where the order data to be compared exists, determining whether the order amount recorded in the order data to be compared is consistent with the order amount recorded in the order data to be reconciled; If the order amount recorded in the order data to be compared is inconsistent with the order amount recorded in the order data to be reconciled, it is determined that there is an abnormality in the order data to be reconciled; If the order amount recorded in the order data to be compared is consistent with the order amount recorded in the order data to be reconciled, it is determined that there is no abnormality in the order data to be reconciled.
8. An order data acquisition system, characterized in that: The order data acquisition system includes a pending reconciliation platform and a payment center for providing order services on the server side, wherein: The reconciliation platform is used to execute the method described in any one of claims 1 to 7 above; The payment center is used to send order data to the platform to be reconciled based on the order acquisition request sent by the platform to be reconciled.
9. An order data acquisition device, characterized in that: The device is applied to a pending reconciliation platform for providing order placement services in a service end, and the device includes: A first identification acquisition module is used to acquire the platform identification of the payment platform for which order data is currently to be acquired as the current platform identification to be filled in; A code acquisition module is used to fill the current platform identifier to be filled into a preset code template to obtain the current order acquisition code; wherein the code template is used to: generate an order acquisition request for acquiring order data, and send the generated order acquisition request to the payment center; A code running module, used for running the current order acquisition code to generate an order acquisition request for acquiring the current order data, and sending the currently generated order acquisition request to the payment center, so that the payment center sends the current order data to the to-be-reconciled platform based on the received order acquisition request; wherein the current order data is: order data paid through the payment platform for which the order data currently needs to be acquired; The receiving module is used to receive the current order data sent by the payment center.
10. A reconciliation platform, characterized in that: It includes a processor, a communication interface, a memory and a communication bus, wherein the processor, the communication interface and the memory communicate with each other through the communication bus; Memory, used to store computer programs; A processor, for implementing any of the methods described in claims 1-7 when executing a program stored in a memory.
11. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the method according to any one of claims 1 to 7 is implemented.
12. A computer program product, characterized in that When the computer program product is run on a computer, the computer is enabled to execute the method according to any one of claims 1 to 7.