Method and device for docking charging platform equipment with third-party platform, and medium
By comparing the interface information between the charging platform equipment and the government platform, generating differential information and generating interface packages, the problem that the charging platform equipment needs to customize interfaces for multiple government platforms is solved, and the effect of simplifying interface development and reducing costs is achieved.
Patent Information
- Application Number
- CN202510436123.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-04-07
- Publication Date
- 2025-06-20
AI Technical Summary
Charging platform equipment needs to customize interfaces for multiple government platforms, resulting in cumbersome interface development work, consumes a lot of human resources, and increases operating costs.
By obtaining the target interface information of the target third-party platform and comparing it with the standard interface information, generating interface differences information, and generating interface packages for the target third-party platform based on the difference information, simplifying the interface development process.
The interface development work of charging platform equipment connecting multiple government platforms has been simplified, reducing human resources investment and reducing operating costs.
Smart Images

Figure CN120179283A_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of charging operations, and particularly to a method, device and medium for a charging platform device to dock with a third-party platform. Background Art
[0002] With the development of technology and the improvement of environmental awareness, new energy vehicles are becoming more and more popular in daily life. New energy vehicles can be charged through charging piles. The charging piles can be managed by charging platform devices. Usually, in order to meet the government supervision requirements and apply for government policy subsidies, the charging platform devices can be connected to multiple government platforms and provide relevant data of the charging platform devices to the multiple government platforms. However, different government platforms have their own business requirements and interface standards, which bring many inconveniences to the docking work of the charging platform devices. Currently, the charging platform devices customize interfaces that meet the business requirements and interface standards of the government platforms for the government platforms. The government platforms can obtain the data of the charging platform devices through this interface.
[0003] However, the charging platform devices customize interfaces for each government platform. When the charging platform devices need to dock with multiple government platforms, the charging platform devices customize interfaces for the government platforms one by one, resulting in a large number of technical personnel being required to complete the interface development work. This solution is relatively cumbersome, consumes a large amount of human resources, and thus leads to a relatively high operation cost of the charging platform devices. Summary of the Invention
[0004] Based on this, it is necessary to provide a method, device and medium for a charging platform device to dock with a third-party platform for the above technical problems, so as to solve how to simplify the interface development work for the charging platform device to dock with multiple government platforms.
[0005] The present invention provides a method for a charging platform device to dock with a third-party platform, including:
[0006] Obtaining target interface information of a target third-party platform, where the target interface information is interface information of at least one interface of the target third-party platform;
[0007] Comparing the target interface information with standard interface information to obtain interface difference information of the at least one interface, where the standard interface information is interface information of at least one interface of the charging platform device;
[0008] Obtaining a standard interface package, where the standard interface package is generated according to the standard interface information, and the standard interface package includes interface configuration information of at least one interface of the charging platform device;
[0009] Generate the interface package of the target third-party platform according to the interface difference information of the at least one interface and the standard interface package. The interface package of the target third-party platform includes the interface configuration information of at least one interface of the target third-party platform, and the interface package of the target third-party platform is used for the charging platform device to provide interface data for the target third-party platform.
[0010] Optionally, the target interface information includes at least one parameter of the target interface of the target third-party platform, and the standard interface information includes at least one parameter of the target interface of the charging platform device. Comparing the target interface information and the standard interface information to obtain the interface difference information of the at least one interface includes:
[0011] Compare at least one parameter of the target interface of the target third-party platform with at least one parameter of the target interface of the charging platform device to obtain at least one difference parameter;
[0012] Use the at least one difference parameter as the difference information of the at least one interface.
[0013] Optionally, the at least one difference parameter includes a deletion parameter, the standard interface package includes the interface configuration information of the target interface of the charging platform device, and the interface configuration information of the target interface includes the configuration information of the field corresponding to the deletion parameter;
[0014] The generating the interface package of the target third-party platform according to the interface difference information of the at least one interface and the standard interface package includes:
[0015] Determine a first field mapping table according to the deletion parameter. The first field mapping table is used to determine a first data converter, and the first data converter is used to delete the field corresponding to the deletion parameter;
[0016] Generate the interface configuration information of the target interface of the target third-party platform according to the first field mapping table and the interface configuration information of the target interface of the charging platform device in the standard interface package;
[0017] Generate the interface package of the target third-party platform according to the interface configuration information of the target interface of the target third-party platform.
[0018] Optionally, the at least one difference parameter includes an addition parameter. The generating the interface package of the target third-party platform according to the interface difference information of the at least one interface and the standard interface package includes:
[0019] Determine a first data source and a second field mapping table according to the newly added parameter, where the second field mapping table is used to determine a second data converter, and the second data converter is used to add a field corresponding to the newly added parameter;
[0020] Generate interface configuration information for the target interface of the target third-party platform according to the first data source, the second field mapping table, and the interface configuration information of the target interface of the charging platform device in the standard interface package;
[0021] Generate an interface package for the target third-party platform according to the interface configuration information of the target interface of the target third-party platform.
[0022] Optionally, the first data source is a default data source or an extended data source.
[0023] Optionally, the method further includes:
[0024] Receive a data request from the target third-party platform, where the data request is used to request output parameter data of a service interface, and the data request includes: an identifier of the target third-party platform and an identifier of the service interface;
[0025] Obtain the interface package of the target third-party platform according to the identifier of the target third-party platform;
[0026] Query the interface package of the target third-party platform according to the identifier of the service interface to obtain the interface configuration information of the service interface;
[0027] Obtain the output parameter data of the service interface according to the interface configuration information of the service interface;
[0028] Send the output parameter data of the service interface to the target third-party platform.
[0029] Optionally, the interface configuration information of the service interface includes: field configuration corresponding to the output parameter of the service interface, and the field configuration corresponding to the output parameter includes: a second data source. Obtaining the output parameter data of the service interface according to the interface configuration information of the service interface includes:
[0030] Obtain the output parameter data of the service interface according to the second data source.
[0031] Optionally, the field configuration corresponding to the output parameter further includes: a third field mapping table, where the third field mapping table is used to determine a third data converter, and the third data converter is used to convert data from the second data source; obtaining the output parameter data of the service interface according to the second data source includes:
[0032] Obtain the first original data from the second data source;
[0033] According to the third field mapping table, convert the first original data to obtain the output parameter data of the service interface.
[0034] Optionally, the method further includes:
[0035] Obtain the first business process event;
[0036] Determine the identifier of the target third-party platform corresponding to the first business process event and the identifier of the service interface corresponding to the first business process event according to a preset correspondence relationship, where the preset correspondence relationship includes the correspondence relationship between the identifier of at least one business process event and the identifiers of the third-party platform and the interface;
[0037] Obtain the interface package of the target third-party platform according to the identifier of the target third-party platform, where the interface package of the target third-party platform includes: at least one interface configuration information;
[0038] Query the interface package of the target third-party platform according to the identifier of the service interface to obtain the interface configuration information of the service interface;
[0039] Obtain the input parameter data of the service interface according to the interface configuration information of the service interface;
[0040] Send the input parameter data of the service interface to the target third-party platform.
[0041] Optionally, the interface configuration information of the service interface includes: the field configuration corresponding to the input parameter of the service interface, and the field configuration corresponding to the input parameter includes: a third data source. Obtaining the input parameter data of the service interface according to the interface configuration information of the service interface includes:
[0042] Obtain the input parameter data of the service interface according to the third data source.
[0043] Optionally, the field configuration corresponding to the input parameter further includes: a fourth field mapping table, where the fourth field mapping table is used to determine a fourth data converter; the fourth data converter is used to convert the data from the third data source. Obtaining the input parameter data of the service interface according to the third data source includes:
[0044] Obtain the second original data from the third data source;
[0045] According to the fourth field mapping table, convert the second original data to obtain the input parameter data of the service interface.
[0046] The present invention also provides a charging platform device, including:
[0047] A first acquisition module, configured to acquire target interface information of a target third-party platform, where the target interface information is interface information of at least one interface of the target third-party platform;
[0048] A comparison module, configured to compare the target interface information with standard interface information to obtain interface difference information of the at least one interface, where the standard interface information is interface information of at least one interface of the charging platform device;
[0049] A second acquisition module, which acquires a standard interface package, where the standard interface package is generated according to the standard interface information, and the standard interface package includes interface configuration information of at least one interface of the charging platform device;
[0050] A generation module, configured to generate an interface package of the target third-party platform according to the interface difference information of the at least one interface and the standard interface package, where the interface package of the target third-party platform includes interface configuration information of at least one interface of the target third-party platform, and the interface package of the target third-party platform is used for the charging platform device to provide interface data for the target third-party platform.
[0051] The present invention also provides one or more readable storage media storing computer-readable instructions, and when the computer-readable instructions are executed by a processor, the above method is implemented.
[0052] The method, device and medium for a charging platform device to dock with a third-party platform include: obtaining target interface information of a target third-party platform, where the target interface information is the interface information of at least one interface of the target third-party platform; comparing the target interface information with standard interface information to obtain interface difference information of the at least one interface, where the standard interface information is the interface information of at least one interface of the charging platform device; obtaining a standard interface package, which is generated according to the standard interface information and includes interface configuration information of at least one interface of the charging platform device; generating an interface package of the target third-party platform according to the interface difference information of the at least one interface and the standard interface package, where the interface package of the target third-party platform includes interface configuration information of at least one interface of the target third-party platform, and the interface package of the target third-party platform is used for the charging platform device to provide interface data for the target third-party platform. It can be seen that in the present invention, the difference between the target interface information and the standard interface information is compared to obtain the difference information, and then changes are made based on the standard interface package according to the difference information to obtain the interface package of the target third-party platform. The interface package of the target third-party platform includes interface configuration information of at least one interface of the target third-party platform, and the interface package of the target third-party platform is used for the charging platform device to provide interface data for the target third-party platform. When the charging platform device needs to dock with multiple government platforms, the charging platform device can make changes based on the standard interface package to obtain interface packages corresponding to multiple government platforms respectively, which is beneficial to simplifying the interface development work for the charging platform device to dock with multiple government platforms, thereby reducing the investment in human resources and lowering the operation cost. BRIEF DESCRIPTION OF THE DRAWINGS
[0053] In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings required for the description of the embodiments of the present invention will be briefly introduced below. Obviously, the drawings in the following description are only some embodiments of the present invention. For those of ordinary skill in the art, other drawings can be obtained based on these drawings without creative efforts.
[0054] Figure 1 is one of the flow diagrams of the method for a charging platform device to dock with a third-party platform in an embodiment of the present invention;
[0055] Figure 2 is the second flow diagram of the method for a charging platform device to dock with a third-party platform in an embodiment of the present invention;
[0056] Figure 3 is the third flow diagram of the method for a charging platform device to dock with a third-party platform in an embodiment of the present invention;
[0057] Figure 4 It is the fourth flowchart of the method for a charging platform device to dock with a third-party platform in an embodiment of the present invention;
[0058] Figure 5 It is a system communication schematic diagram provided in an embodiment of the present invention;
[0059] Figure 6 It is the fifth flowchart of the method for a charging platform device to dock with a third-party platform in an embodiment of the present invention;
[0060] Figure 7 It is the sixth flowchart of the method for a charging platform device to dock with a third-party platform in an embodiment of the present invention;
[0061] Figure 8 It is the seventh flowchart of the method for a charging platform device to dock with a third-party platform in an embodiment of the present invention;
[0062] Figure 9 It is the eighth flowchart of the method for a charging platform device to dock with a third-party platform in an embodiment of the present invention;
[0063] Figure 10 It is the ninth flowchart of the method for a charging platform device to dock with a third-party platform in an embodiment of the present invention;
[0064] Figure 11 It is the tenth flowchart of the method for a charging platform device to dock with a third-party platform in an embodiment of the present invention;
[0065] Figure 12 It is a structural schematic diagram of a charging platform device in an embodiment of the present invention;
[0066] Figure 13 It is a schematic diagram of a computer device in an embodiment of the present invention. Specific Embodiments
[0067] Next, the technical solutions in the embodiments of the present invention will be clearly and completely described in conjunction with the accompanying drawings in the embodiments of the present invention. Obviously, the described embodiments are some, but not all, of the embodiments of the present invention. All other embodiments obtained by those of ordinary skill in the art based on the embodiments of the present invention without making creative efforts shall fall within the protection scope of the present invention.
[0068] In one embodiment, as Figure 1 shown, Figure 1 It is the first flowchart of the method for a charging platform device to dock with a third-party platform in an embodiment of the present invention. The embodiment of the present invention provides a method for a charging platform device to dock with a third-party platform, which specifically includes the following steps:
[0069] S101. Obtain the target interface information of the target third-party platform.
[0070] To meet government supervision requirements and apply for government policy subsidies, the charging platform device can be connected to multiple government platforms and provide relevant data of the charging platform device to multiple government platforms. The target third-party platform can be a government platform or a third-party platform that needs to exchange data with the charging platform device. The present invention does not limit this. Subsequently, the present invention will take docking with a government platform as an example to introduce the technical solution of the present invention in detail.
[0071] The target interface information includes the interface information of at least one interface of the target third-party platform. For example, the target interface information includes the interface standard document provided by the target third-party platform to the charging platform device. The interface standard document details the interface information of one or more interfaces implemented by the charging platform device and the interface information of one or more interfaces implemented by the target third-party platform.
[0072] S102. Compare the target interface information with the standard interface information to obtain the interface difference information of at least one interface.
[0073] The standard interface information is defined by the charging platform device. The standard interface information includes the interface information of at least one interface of the charging platform device. Among them, the interface information of each interface is defined according to the charging industry standard interconnection protocol.
[0074] Refer to Figure 2 , Figure 2 is the second flow diagram of the method for the charging platform device to dock with the third-party platform in an embodiment of the present invention; in an embodiment of the present invention, the target interface information includes: at least one parameter of the target interface of the target third-party platform, and the standard interface information includes: at least one parameter of the target interface of the charging platform device. Comparing the target interface information with the standard interface information to obtain the interface difference information of at least one interface includes:
[0075] S201. Compare at least one parameter of the target interface of the target third-party platform with at least one parameter of the target interface of the charging platform device to obtain at least one difference parameter.
[0076] It should be noted that the present invention will take the target interface as an example to introduce in detail how to determine the interface difference information.
[0077] The interface identifier of the target interface of the target third-party platform is the same as the interface identifier of the target interface of the charging platform device. The target interface of the target third-party platform includes at least one parameter; the target interface of the charging platform device includes at least one parameter. The parameter type can be an input parameter or an output parameter.
[0078] Optionally, during parameter comparison, the charging platform device compares two parameters with the same parameter type among at least one parameter of the target interface of the target third-party platform and at least one parameter of the target interface of the charging platform device. For example, the charging platform device compares the output parameters of the target interface of the target third-party platform with the output parameters of the target interface of the charging platform device to obtain the differential output parameters. The differential output parameters can be deleted parameters or added parameters. A deleted parameter is an output parameter that the output parameters of the target interface of the target third-party platform lack compared to the output parameters of the target interface of the charging platform device. For example, the output parameters of the target interface of the target third-party platform include A and B, while the output parameters of the target interface of the charging platform device include A, B, and C. Then it can be known that the deleted parameter is C. An added parameter is an output parameter that the output parameters of the target interface of the target third-party platform add compared to the output parameters of the target interface of the charging platform device. For example, the output parameters of the target interface of the target third-party platform include A, B, and C, while the output parameters of the target interface of the charging platform device include A and B. Then it can be known that the added parameter is C. Another example is that the charging platform device compares the input parameters of the target interface of the target third-party platform with the input parameters of the target interface of the charging platform device to obtain the differential input parameters. The differential input parameters can be deleted parameters or added parameters.
[0079] S202. Use at least one differential parameter as the differential information of at least one interface.
[0080] The charging platform device uses the at least one differential parameter generated as the differential information of at least one interface.
[0081] S103. Obtain the standard interface package.
[0082] The standard interface package is generated according to the standard interface information. That is, the charging platform device generates the standard interface package according to the standard interface information. The standard interface package includes the interface configuration information of at least one interface of the charging platform device. Here, taking the interface configuration information of the target interface of the charging platform device as an example for introduction, the interface information of the target interface of the charging platform includes at least one parameter. Each parameter corresponds to a field. The interface configuration information of the target interface of the charging platform includes the configuration information of each field corresponding to the parameter of the target interface.
[0083] S104. Generate the interface package of the target third-party platform according to the interface differential information of at least one interface and the standard interface package.
[0084] The interface package of the target third-party platform includes the interface configuration information of at least one interface of the target third-party platform. The interface package of the target third-party platform is used for the charging platform device to provide interface data for the target third-party platform. Here, the interface configuration information of the target interface of the target third-party platform is taken as an example for introduction. The interface information of the target interface of the target third-party platform includes at least one parameter. Each parameter corresponds to a field. The interface configuration information of the target interface of the target third-party platform includes the configuration information of the field corresponding to each parameter of the target interface.
[0085] Refer to Figure 3 , Figure 3 is the third flow diagram of the method for the charging platform device to dock with the third-party platform in an embodiment of the present invention; in an embodiment of the present invention, at least one difference parameter includes a deletion parameter, the standard interface package includes the interface configuration information of the target interface of the charging platform device, and the interface configuration information of the target interface includes the configuration information of the field corresponding to the deletion parameter; generating the interface package of the target third-party platform according to the interface difference information of at least one interface and the standard interface package includes:
[0086] S301. Determine the first field mapping table according to the deletion parameter.
[0087] It should be noted that each deletion parameter corresponds to a field mapping table. One field mapping table corresponds to one data converter. The first field mapping table is used to determine the first data converter. For example, the first field mapping table includes the identifier of the first data converter. The first data converter is used to delete the field corresponding to the deletion parameter.
[0088] S302. Generate the interface configuration information of the target interface of the target third-party platform according to the first field mapping table and the interface configuration information of the target interface of the charging platform device in the standard interface package.
[0089] The interface configuration information of the target interface of the charging platform device in the standard interface package includes the configuration information of all fields corresponding to all parameters of the target interface of the charging platform device. The configuration information of the field corresponding to each parameter includes a data source. The data source is the data source of the parameter. The charging platform device adds the first field mapping table to the configuration information of the field corresponding to the deletion parameter in the interface configuration information of the target interface of the charging platform device to obtain the interface configuration information of the target interface of the target third-party platform.
[0090] S303. Generate the interface package of the target third-party platform according to the interface configuration information of the target interface of the target third-party platform.
[0091] It should be noted that the generation process of the interface configuration information of other interfaces of the target third-party platform is similar to that of the foregoing S301 to S302. For this, the present invention will not be elaborated further. The interface configuration information of all interfaces between the charging platform device and the target third-party platform generates the interface package of the target third-party platform.
[0092] Refer to Figure 4 , Figure 4 FIG. 3 is a schematic flowchart of a method for a charging platform device to dock with a third-party platform in an embodiment of the present invention. In an embodiment of the present invention, at least one difference parameter includes a new parameter. Generating an interface package for the target third-party platform according to the interface difference information of at least one interface and the standard interface package includes:
[0093] S401. Determine a first data source and a second field mapping table according to the new parameter.
[0094] The first data source is the data source for this new parameter. The first data source includes the charging platform device, the charging pile, and the target third-party platform. Optionally, the data source may also include a default data source or an extended data source. The default data source provides a default value for the new parameter. The extended data source indicates that the charging device can receive data from other devices.
[0095] Each new parameter corresponds to a field mapping table. One field mapping table corresponds to one data converter. The second field mapping table is used to determine the second data converter.
[0096] S402. Generate the interface configuration information of the target interface of the target third-party platform according to the first data source, the second field mapping table, and the interface configuration information of the target interface of the charging platform device in the standard interface package.
[0097] The interface configuration information of the target interface of the charging platform device in the standard interface package includes the configuration information of all fields corresponding to all parameters of the target interface of the charging platform device. The configuration information of each parameter corresponding field includes the data source. The charging platform device adds the configuration information of the field corresponding to the new parameter in the interface configuration information of the target interface of the charging platform device to obtain the interface configuration information of the target interface of the target third-party platform. The configuration information of the field corresponding to the new parameter includes: the first data source and the second field mapping table.
[0098] S403. Generate the interface package of the target third-party platform according to the interface configuration information of the target interface of the target third-party platform.
[0099] It should be noted that the generation process of the interface configuration information of other interfaces of the target third-party platform is similar to that of the foregoing S401 to S402. For this, the present invention will not be elaborated further. The interface configuration information of all interfaces between the charging platform device and the target third-party platform generates the interface package of the target third-party platform.
[0100] It should be noted that the above is introduced by adding parameters and deleting parameters. In actual applications, there are also solutions obtained by combining the scenario of deleting parameters with the scenario of adding parameters. Specifically, reference can be made to the above S301 to S303 and S401 to S403. Regarding this, the present application will not elaborate further.
[0101] It should be noted that the generation process of the above interface package of the target third-party platform can be presented in the form of a page. Specifically, the user can obtain the interface package of the target third-party platform through the visual configuration of the page.
[0102] Refer to Figure 5 , Figure 5 is a schematic diagram of an interface package of the target third-party platform. As can be seen from Figure 5 , the interface package of the target third-party platform includes at least one interface configuration information. Each interface configuration information may include a data source, a data converter, and a field mapping table. Refer to Figure 6 , Figure 6 is the fourth schematic diagram of the process of the charging platform device docking with the third-party platform in an embodiment of the present invention; in an embodiment of the present invention, the method further includes:
[0103] S601. Receive a data request from the target third-party platform.
[0104] The data request is used to request the output parameter data of the service interface. Among them, the charging platform device receives the data request from the target third-party platform. This data request is used for the target third-party platform to obtain the data of the charging platform device. The data request includes the identifier of the target third-party platform and the identifier of the service interface. The service interface is the interface implemented by the charging platform device. The identifier of the service interface is used to indicate the service interface. It can be understood that the target third-party platform calls the service interface through the data request. Therefore, the information carried in the data request can be understood as the input parameter data of the service interface. The charging platform should return the output parameter data of the service interface.
[0105] S602. Obtain the interface package of the target third-party platform according to the identifier of the target third-party platform.
[0106] The charging platform device stores the interface packages of multiple target third-party platforms. The charging platform device obtains the interface package of the target third-party platform according to the identifier of the target third-party platform.
[0107] S603. Query the interface package of the target third-party platform according to the identifier of the service interface to obtain the interface configuration information of the service interface.
[0108] The interface package of the target third-party platform includes at least one interface configuration information. Each interface configuration information has an identifier corresponding to the interface. The charging platform device can query the interface package of the target third-party platform according to the identifier of the service interface to obtain the interface configuration information of the service interface.
[0109] S604. Obtain the output parameter data of the service interface according to the interface configuration information of the service interface.
[0110] Refer to Figure 7 , Figure 7 FIG. 5 is a schematic flow chart of a method for a charging platform device to dock with a third-party platform in an embodiment of the present invention; in an embodiment of the present invention, the interface configuration information of the service interface includes: the field configuration corresponding to the output parameter of the service interface, and the field configuration corresponding to the output parameter includes: a second data source. Obtaining the output parameter data of the service interface according to the interface configuration information of the service interface includes:
[0111] S701. Obtain the output parameter data of the service interface according to the second data source.
[0112] Refer to Figure 8 , Figure 8 FIG. 6 is a schematic flow chart of a method for a charging platform device to dock with a third-party platform in an embodiment of the present invention; in an embodiment of the present invention, the field configuration corresponding to the output parameter further includes: a third field mapping table, and the third field mapping table is used to determine a third data converter. Obtaining the output parameter data of the service interface according to the second data source includes:
[0113] S801. Obtain the first raw data from the second data source.
[0114] The charging platform device obtains the raw data of the field corresponding to the output parameter from the second data source. Specifically, the above embodiments of the present invention have been described in detail, and the present invention will not be elaborated herein.
[0115] S802. Convert the first raw data according to the third field mapping table to obtain the output parameter data of the service interface.
[0116] Specifically, the charging platform device determines a third data converter according to the third field mapping table. Then, the charging platform device converts the first raw data through the third data converter to obtain the output parameter data of the service interface.
[0117] S605. Send the output parameter data of the service interface to the target third-party platform.
[0118] It should be noted that the above is an introduction with one output parameter as an example. When there are multiple output parameters in the service interface, the process for the charging platform device to obtain data of other output parameters is similar to the aforementioned S701 and the processes of S801 - S802, and will not be elaborated here. Then, the charging platform device sends all the output parameter data of the service interface to the target third-party platform.
[0119] Refer to Figure 9 , Figure 9 is the seventh flowchart of the method for the charging platform device to dock with the third-party platform in an embodiment of the present invention; in an embodiment of the present invention, the method further includes:
[0120] S901. Obtain the first service process event;
[0121] It should be noted that the first service process event can be a service process event triggered by the charging platform device itself.
[0122] S902. Determine the identifier of the target third-party platform corresponding to the first service process event and the identifier of the service interface corresponding to the first service process event according to the preset corresponding relationship.
[0123] It should be noted that the preset corresponding relationship includes the corresponding relationship between the identifier of at least one service process event and the identifiers of the third-party platform and the interface. Optionally, the preset corresponding relationship can be represented by a table. For example, the preset corresponding relationship is shown in Table 1:
[0124] Table 1
[0125] Identification of business process events Identification of third-party platforms Identification of interfaces 01 a 00001 02 b 00002 03 c 00003 04 d 00004
[0126] For example, the identifier of the first service process event is 01. As can be seen from Table 1, the identifier of the target third-party platform is a, and the identifier of the service interface is 00001.
[0127] It can be understood that in S902, the charging platform device can call the service interface of the target third-party platform to transmit data to the target third-party platform. Specifically, the input parameters of the service interface can carry data of the charging platform device.
[0128] S903. Obtain the interface package of the target third-party platform according to the identifier of the target third-party platform.
[0129] S904. Query the interface package of the target third-party platform according to the identifier of the service interface to obtain the interface configuration information of the service interface.
[0130] S903 to S904 are similar to S602 to S603 in the embodiment shown above, and will not be elaborated here. Figure 6
[0131] S905. Acquire input parameter data of the service interface according to the interface configuration information of the service interface.
[0132] Reference Figure 10 , Figure 10 It is a flowchart of the method for connecting a charging platform device to a third-party platform in one embodiment of the present invention; in one embodiment of the present invention, the interface configuration information of the business interface includes: the field configuration corresponding to the input parameter of the business interface, and the field configuration corresponding to the input parameter includes: a third data source, and the input parameter data of the business interface is obtained according to the interface configuration information of the business interface, including:
[0133] 1001. Obtain input parameter data of a business interface according to a third data source.
[0134] It should be noted that S1001 is different from the above Figure 7 S701 in the illustrated embodiment is similar, and the present invention will not elaborate on this.
[0135] Reference Figure 11 , Figure 11 It is a flowchart of the method for connecting a charging platform device to a third-party platform in one embodiment of the present invention. In one embodiment of the present invention, the field configuration corresponding to the input parameter also includes: a fourth field mapping table, the fourth field mapping table is used to determine a fourth data converter, and the fourth data converter is used to convert the field corresponding to the input parameter; obtaining input parameter data of the business interface according to the third data source includes:
[0136] 1101. Obtain second original data from a third data source.
[0137] It should be noted that S1101 is different from the above Figure 8 S801 in the illustrated embodiment is similar, and the present invention will not elaborate on this.
[0138] 1102. Convert the second original data according to the fourth field mapping table to obtain input parameter data of the business interface.
[0139] It should be noted that S1102 is different from the above Figure 8 S802 in the illustrated embodiment is similar, and the present invention will not elaborate on this.
[0140] 906. Send the input parameter data of the business interface to the target third-party platform.
[0141] It should be noted that the above is introduced by taking one input parameter as an example. When there are multiple input parameters for the service interface, the process of the charging platform device obtaining data of other input parameters is similar to the aforementioned S901 and S1001 - S1002 processes, which will not be elaborated here. Then, the charging platform device sends all the input parameter data of the service interface to the target third-party platform.
[0142] It should be understood that the magnitudes of the sequence numbers of the steps in the above embodiments do not imply the order of execution. The order of execution of each process should be determined by its function and internal logic, and should not constitute any limitation to the implementation process of the embodiments of the present invention.
[0143] In one embodiment, a charging platform device is provided, which corresponds one-to-one to the method of the charging platform device docking with a third-party platform in the above embodiment. As Figure 12 shown, Figure 12 is a schematic structural diagram of a charging platform device in an embodiment of the present invention. The charging platform device includes:
[0144] A first acquisition module 1201, configured to acquire target interface information of a target third-party platform, where the target interface information is interface information of at least one interface of the target third-party platform;
[0145] A comparison module 1202, configured to compare the target interface information with standard interface information to obtain interface difference information of the at least one interface, where the standard interface information is interface information of at least one interface of the charging platform device;
[0146] A second acquisition module 1203, configured to acquire a standard interface package, where the standard interface package is generated according to the standard interface information, and the standard interface package includes interface configuration information of at least one interface of the charging platform device;
[0147] A generation module 1204, configured to generate an interface package of the target third-party platform according to the interface difference information of the at least one interface and the standard interface package. The interface package of the target third-party platform includes interface configuration information of at least one interface of the target third-party platform, and the interface package of the target third-party platform is used for the charging platform device to provide interface data for the target third-party platform.
[0148] Optionally, the target interface information includes at least one parameter of a target interface of the target third-party platform, and the standard interface information includes at least one parameter of a target interface of the charging platform device. The comparison module 1202 is specifically configured to:
[0149] Compare at least one parameter of the target interface of the target third-party platform with at least one parameter of the target interface of the charging platform device to obtain at least one difference parameter;
[0150] Use the at least one difference parameter as the difference information of the at least one interface.
[0151] Optionally, the at least one difference parameter includes a deletion parameter, the standard interface package includes the interface configuration information of the target interface of the charging platform device, and the interface configuration information of the target interface includes the configuration information of the field corresponding to the deletion parameter;
[0152] The generation module 1204 is specifically configured to:
[0153] Determine a first field mapping table according to the deletion parameter, where the first field mapping table is used to determine a first data converter, and the first data converter is used to delete the field corresponding to the deletion parameter;
[0154] Generate the interface configuration information of the target interface of the target third-party platform according to the first field mapping table and the interface configuration information of the target interface of the charging platform device in the standard interface package;
[0155] Generate the interface package of the target third-party platform according to the interface configuration information of the target interface of the target third-party platform.
[0156] Optionally, the at least one difference parameter includes an addition parameter, and the generation module 1204 is specifically configured to:
[0157] Determine a first data source and a second field mapping table according to the addition parameter, where the second field mapping table is used to determine a second data converter, and the second data converter is used to add the field corresponding to the addition parameter;
[0158] Generate the interface configuration information of the target interface of the target third-party platform according to the first data source, the second field mapping table, and the interface configuration information of the target interface of the charging platform device in the standard interface package;
[0159] Generate the interface package of the target third-party platform according to the interface configuration information of the target interface of the target third-party platform.
[0160] Optionally, the first data source is a default data source or an extended data source.
[0161] Optionally, the first acquisition module 1201 is further configured to:
[0162] Receive data requests from the target third-party platform, where the data requests are used to request output parameter data of a service interface, and the data requests include: the identifier of the target third-party platform and the identifier of the service interface;
[0163] Obtain the interface package of the target third-party platform according to the identifier of the target third-party platform;
[0164] The charging platform device further includes a query module 1205 and a sending module 1206.
[0165] The query module 1205 is configured to query the interface package of the target third-party platform according to the identifier of the service interface, and obtain the interface configuration information of the service interface;
[0166] The first acquisition module 1201 is further configured to: obtain the output parameter data of the service interface according to the interface configuration information of the service interface;
[0167] The sending module 1206 is configured to send the output parameter data of the service interface to the target third-party platform.
[0168] Optionally, the interface configuration information of the service interface includes: the field configuration corresponding to the output parameter of the service interface, and the field configuration corresponding to the output parameter includes: a second data source. The first acquisition module 1201 is specifically configured to: obtain the output parameter data of the service interface according to the second data source.
[0169] Optionally, the field configuration corresponding to the output parameter further includes: a third field mapping table, which is used to determine a third data converter, and the third data converter is used to convert the data from the second data source; the first acquisition module 1201 is specifically configured to: obtain first raw data from the second data source; and convert the first raw data according to the third field mapping table to obtain the output parameter data of the service interface.
[0170] Optionally, the first acquisition module 1201 is further configured to:
[0171] Obtain a first business process event;
[0172] The charging platform device further includes a query module 1205, a sending module 1206, and a determination module 1207.
[0173] The determination module 1207 is configured to determine the identifier of the target third-party platform corresponding to the first business process event and the identifier of the service interface corresponding to the first business process event according to a preset correspondence relationship, where the preset correspondence relationship includes the correspondence relationship between the identifiers of at least one business process event and the identifiers of the third-party platform and the interface;
[0174] The first acquisition module 1201 is further configured to: acquire the interface package of the target third-party platform according to the identifier of the target third-party platform, where the interface package of the target third-party platform includes: at least one interface configuration information;
[0175] The query module 1205 is configured to query the interface package of the target third-party platform according to the identifier of the service interface, and obtain the interface configuration information of the service interface;
[0176] The first acquisition module 1201 is further configured to: acquire the input parameter data of the service interface according to the interface configuration information of the service interface;
[0177] The sending module 1206 is configured to send the input parameter data of the service interface to the target third-party platform.
[0178] Optionally, the interface configuration information of the service interface includes: the field configuration corresponding to the input parameter of the service interface, and the field configuration corresponding to the input parameter includes: a third data source. The first acquisition module 1201 is specifically configured to:
[0179] Acquire the input parameter data of the service interface according to the third data source.
[0180] Optionally, the field configuration corresponding to the input parameter further includes: a fourth field mapping table, where the fourth field mapping table is used to determine a fourth data converter; the fourth data converter is used to convert the data from the third data source. The first acquisition module 1201 is specifically configured to:
[0181] Acquire second original data from the third data source;
[0182] Convert the second original data according to the fourth field mapping table to obtain the input parameter data of the service interface.
[0183] For the specific limitations of the energy storage platform device, reference may be made to the limitations of the method for the charging platform device to dock with the third-party platform in the above text, which will not be elaborated here. Each module in the above energy storage platform device can be implemented in whole or in part by software, hardware, and their combination. The above modules can be embedded in the processor in the computer device in hardware form or independent of it, or stored in the memory in the computer device in software form, so that the processor can call and execute the operations corresponding to the above modules.
[0184] In one embodiment, a computer device is provided. The computer device may be a server, and its internal structure diagram may be as Figure 13 shown Figure 13It is a schematic diagram of a computer device in an embodiment of the present invention. The computer device includes a processor, a memory, a network interface, and a database connected through a device bus. Among them, the processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a readable storage medium and an internal memory. The readable storage medium stores an operating device, computer-readable instructions, and a database. The internal memory provides an environment for the operation of the operating device and computer-readable instructions in the readable storage medium. The database of the computer device is used to store data related to the method of docking a charging platform device with a third-party platform. The network interface of the computer device is used to communicate with an external terminal through a network connection. When the computer-readable instructions are executed by the processor, a method for docking a charging platform device with a third-party platform is implemented. The readable storage medium provided in this embodiment includes a non-volatile readable storage medium and a volatile readable storage medium.
[0185] In one embodiment, a computer device is provided. The computer device may be a terminal device, and its internal structure diagram may be as Figure 13 shown. The computer device includes a processor, a memory, and a network interface connected through a device bus. Among them, the processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a readable storage medium. The readable storage medium stores computer-readable instructions. The network interface of the computer device is used to communicate with an external terminal through a network connection. When the computer-readable instructions are executed by the processor, a method for docking a charging platform device with a third-party platform is implemented. The readable storage medium provided in this embodiment includes a non-volatile readable storage medium and a volatile readable storage medium.
[0186] In an embodiment, a computer device is provided, including a memory, a processor, and computer-readable instructions stored in the memory and executable on the processor. When the processor executes the computer-readable instructions, the steps of the method for docking a charging platform device with a third-party platform as described above are implemented.
[0187] In one embodiment, a readable storage medium is provided. The readable storage medium stores computer-readable instructions. When the computer-readable instructions are executed by a processor, the method steps of the charging platform device docking with a third-party platform as described above are implemented. Those of ordinary skill in the art can understand that all or part of the processes in the above-described embodiment methods can be completed by instructing relevant hardware through computer-readable instructions. The computer-readable instructions can be stored in a non-volatile readable storage medium or a volatile readable storage medium. When the computer-readable instructions are executed, they can include the processes of the embodiments of the above-described various methods. Among them, any reference to a memory, storage, database, or other medium used in the various embodiments provided in the present application can include non-volatile and / or volatile memories. Non-volatile memory can include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM), or flash memory. Volatile memory can include random access memory (RAM) or an external cache. By way of illustration and not limitation, RAM is available in various forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (DDR SDRAM), enhanced SDRAM (ESDRAM), synchronous link DRAM (SLDRAM), Rambus direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and Rambus dynamic RAM (RDRAM), etc.
[0188] Those skilled in the art can clearly understand that for the convenience and brevity of description, only the above-mentioned division of each functional unit and module is used as an example. In actual applications, the above functions can be allocated to different functional units and modules according to needs, that is, the internal structure of the device is divided into different functional units or modules to complete all or part of the functions described above.
[0189] The above embodiments are only used to illustrate the technical solutions of the present invention and are not intended to limit them. Although the present invention has been described in detail with reference to the foregoing embodiments, those of ordinary skill in the art should understand that they can still modify the technical solutions described in the foregoing embodiments, or perform equivalent replacements for some of the technical features. These modifications or replacements do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the various embodiments of the present invention and should all be included in the protection scope of the present invention.
Claims
1. A method for connecting a charging platform device to a third-party platform, characterized in that: The method comprises: Acquire target interface information of a target third-party platform, where the target interface information is interface information of at least one interface of the target third-party platform; Compare the target interface information with the standard interface information to obtain interface difference information of the at least one interface, wherein the standard interface information is interface information of at least one interface of the charging platform device; Acquire a standard interface package, wherein the standard interface package includes interface configuration information of at least one interface of the charging platform device; The interface package of the target third-party platform is generated according to the interface difference information of the at least one interface and the standard interface package. The interface package of the target third-party platform includes the interface configuration information of at least one interface of the target third-party platform. The interface package of the target third-party platform is used for the charging platform device to communicate with the target third-party platform.
2. The method according to claim 1, characterized in that: The target interface information includes: at least one parameter of the target interface of the target third-party platform, the standard interface information includes: at least one parameter of the target interface of the charging platform device, and the interface difference information of the at least one interface is obtained by comparing the target interface information with the standard interface information, including: Compare at least one parameter of the target interface of the target third-party platform with at least one parameter of the target interface of the charging platform device to obtain at least one difference parameter; The at least one difference parameter is used as the difference information of the at least one interface.
3. The method according to claim 2, characterized in that: The at least one difference parameter includes a deletion parameter, the standard interface package includes interface configuration information of a target interface of the charging platform device, and the interface configuration information of the target interface includes configuration information of a field corresponding to the deletion parameter; The generating the interface package of the target third-party platform according to the interface difference information of the at least one interface and the standard interface package includes: Determine a first field mapping table according to the deletion parameter, the first field mapping table is used to determine a first data converter, and the first data converter is used to delete the field corresponding to the deletion parameter; Generate interface configuration information of the target interface of the target third-party platform according to the first field mapping table and the interface configuration information of the target interface of the charging platform device in the standard interface package; An interface package of the target third-party platform is generated according to the interface configuration information of the target interface of the target third-party platform.
4. The method according to claim 2, characterized in that: The at least one difference parameter includes a newly added parameter, and the generating the interface package of the target third-party platform according to the interface difference information of the at least one interface and the standard interface package includes: Determine a first data source and a second field mapping table according to the newly added parameter, the second field mapping table is used to determine a second data converter, and the second data converter is used to add a field corresponding to the newly added parameter; Generate interface configuration information of the target interface of the target third-party platform according to the first data source, the second field mapping table and the interface configuration information of the target interface of the charging platform device in the standard interface package; An interface package of the target third-party platform is generated according to the interface configuration information of the target interface of the target third-party platform.
5. The method according to any one of claims 1 to 4, characterized in that: The method further comprises: Receiving a data request from the target third-party platform, the data request being used to request output parameter data of a service interface, the data request including: an identifier of the target third-party platform and an identifier of the service interface; Obtaining an interface package of the target third-party platform according to an identifier of the target third-party platform; Querying the interface package of the target third-party platform according to the identifier of the service interface to obtain interface configuration information of the service interface; Acquire output parameter data of the service interface according to the interface configuration information of the service interface; The output parameter data of the business interface is sent to the target third-party platform.
6. The method according to claim 5, characterized in that: The interface configuration information of the business interface includes: field configuration corresponding to the output parameter of the business interface, the field configuration corresponding to the output parameter includes: a second data source and a third field mapping table, the third field mapping table is used to determine a third data converter, and the third data converter is used to convert data from the second data source; the obtaining the output parameter data of the business interface according to the interface configuration information of the business interface includes: Acquire first original data from the second data source; The first original data is converted according to the third field mapping table to obtain output parameter data of the business interface.
7. The method according to any one of claims 1 to 4, characterized in that: The method further comprises: Get the first business process event; Determining the identifier of the target third-party platform corresponding to the first business process event and the identifier of the business interface corresponding to the first business process event according to a preset corresponding relationship, wherein the preset corresponding relationship includes a corresponding relationship between at least one business process event identifier and an identifier of the third-party platform and an identifier of the interface; Acquire an interface package of the target third-party platform according to the identifier of the target third-party platform, wherein the interface package of the target third-party platform includes: at least one interface configuration information; Querying the interface package of the target third-party platform according to the identifier of the service interface to obtain interface configuration information of the service interface; Acquiring input parameter data of the service interface according to the interface configuration information of the service interface; Sending the input parameter data of the business interface to the target third-party platform.
8. The method according to claim 7, characterized in that: The interface configuration information of the business interface includes: field configuration corresponding to the input parameter of the business interface, the field configuration corresponding to the input parameter includes: a third data source and a fourth field mapping table, the fourth field mapping table is used to determine a fourth data converter; the fourth data converter is used to convert data from the third data source; the acquiring the input parameter data of the business interface according to the interface configuration information of the business interface includes: Acquire second original data from the third data source; The second original data is converted according to the fourth field mapping table to obtain input parameter data of the business interface.
9. A charging platform device, characterized in that: include: A first acquisition module, configured to acquire target interface information of a target third-party platform, wherein the target interface information is interface information of at least one interface of the target third-party platform; a comparison module, configured to compare the target interface information with the standard interface information to obtain interface difference information of the at least one interface, wherein the standard interface information is interface information of at least one interface of the charging platform device; A second acquisition module is configured to acquire a standard interface package, wherein the standard interface package is generated according to the standard interface information, and the standard interface package includes interface configuration information of at least one interface of the charging platform device; A generation module is used to generate an interface package of the target third-party platform based on the interface difference information of the at least one interface and the standard interface package, wherein the interface package of the target third-party platform includes the interface configuration information of at least one interface of the target third-party platform, and the interface package of the target third-party platform is used by the charging platform device to provide interface data for the target third-party platform.
10. A readable storage medium having computer readable instructions stored thereon, characterized in that: When the computer readable instructions are executed by a processor, the method according to any one of claims 1 to 8 is implemented.