API service call record storage and settlement method based on blockchain
By adopting blockchain technology in API service call settlement, generating and certifying API service subscriptions and call records, the problems of insufficient comprehensive evaluation of API service quality and insufficient data security in the existing technology are solved, and efficient and secure are achieved API service transaction settlement.
Patent Information
- Application Number
- PCT/CN2023/123400
- Authority / Receiving Office
- WO · WO
- Patent Type
- Applications
- Current Assignee / Owner
- Priority Date
- 2023-08-01
- Filing Date
- 2023-10-08
- Publication Date
- 2025-02-06
AI Technical Summary
The existing API service call settlement method relies on the unilateral monitoring indicators of the service provider, lacks comprehensive consideration of the actual operation quality of the service, and the transaction settlement process is complex, and data security depends on centralized databases, which poses the risk of being tampered with.
Adopt the blockchain-based API service call proof settlement method, and build a blockchain network to generate API service subscription records and service call records, and freeze funds, settle and return funds through smart contracts to ensure the security of data. Letter and open and transparent.
It realizes comprehensive monitoring and evaluation of API service quality, provides a credible trading environment, simplifies transaction processes, improves transaction settlement efficiency, and ensures data security and immutability.
Smart Images

Figure CN2023123400_06022025_PF_FP_ABST
Abstract
Description
API service call evidence settlement method based on blockchain Technical Field
[0001] The present invention relates to the field of computer technology, and in particular to a blockchain-based API service call evidence settlement method. Background Art
[0002] With the advancement and development of cloud computing and cloud service technologies, a large number of API services are deployed in cloud resources to facilitate calls by service users. At present, the traditional API service transaction settlement takes Alibaba Cloud, Huawei Cloud and AWS as examples. Its SLA (Service Level Agreement) only makes certain guarantees on service availability, without considering indicators such as latency and throughput; service transaction settlement is settled through a third-party settlement platform: For example, the Chinese patent with publication number CN110210850A discloses an online transaction settlement method and system, the method comprising: receiving and publishing a source of goods online signing contract submitted by a first transaction member; after receiving a delisting carrier contract for the source of goods online signing contract submitted by a second transaction member, initiating a freezing request to a financial institution so that the financial institution freezes the payment amount in the payment account of the first transaction member; after receiving a notification of completion of goods delivery submitted by the second transaction member, initiating a thawing and payment request to the financial institution so that the The financial institution unfreezes the payment amount in the payment account of the first transaction member and performs payment processing; and the Chinese patent publication number CN110866753A discloses a control method, device, electronic device and storage medium for third-party settlement, which are used to improve the efficiency of third-party settlement, wherein the method includes: the third-party settlement node responds to the settlement request and sends the settlement request to the corresponding transaction participant nodes; the third-party settlement node receives the acceptance opinion sent by each transaction participant node, wherein the acceptance opinion is used to indicate the processing result of the transaction participant node on the settlement request; the third-party settlement node determines the transaction consensus information based on the received acceptance opinion, and executes the third-party settlement based on the transaction consensus information, wherein the transaction consensus information is used to indicate whether the transaction participant nodes have reached a complete consensus on the settlement request.
[0003] For services that fail to meet the SLA (Service Level Agreement), compensation is provided by returning platform vouchers afterwards, which is highly platform-bound and dependent. The relevant data is stored in the payment company's centralized database, making it difficult to ensure data security, reliability, openness and transparency. The main problems are as follows:
[0004] (1) Currently, the settlement methods for API service calls mostly rely on the unilateral monitoring indicators of the service provider, lacking a comprehensive consideration of the actual operation quality of the service, which in turn leads to an incomplete evaluation of the API service quality.
[0005] (2) The transaction settlement for API services mostly relies on third-party intermediaries, and the compensation mechanism is mostly tied to the supplier. The compensation method is difficult to effectively protect the rights and interests of service users, and the transaction settlement process is complicated, which is not conducive to the free trade between the two parties.
[0006] (3) Currently, data from API service calls, transaction settlements, and other stages are mostly stored in centralized databases. The security of these data depends on third-party payment platforms. Transaction data involves the interests of multiple parties and is at risk of being tampered with. When transaction disputes occur, it is difficult to conduct secure and reliable traceability queries, and data security is difficult to guarantee.
[0007] Summary of the Invention
[0008] The purpose of the present invention is to provide a blockchain-based API service call evidence storage and settlement method; this method optimizes the transaction process, while comprehensively monitoring the actual service call situation, reducing transaction disputes and providing a credible basis for API service quality evaluation and settlement.
[0009] The present invention provides the following technical solutions:
[0010] The blockchain-based API service calls a deposit settlement method, which includes the following steps:
[0011] Step 1: Build a blockchain network. The service user selects an API service that meets their business needs, generates an API service subscription record, and stores it on the blockchain through the service user node.
[0012] Step 2: Once the API service subscription record is uploaded to the blockchain, the service user's fixed assets will be frozen based on the API service subscription record. An asset freezing record corresponding to the API service subscription record will be generated and uploaded to the blockchain for evidence.
[0013] Step 3: Obtain the indicator data called in the API service subscription, generate the corresponding service call record and store it in the blockchain;
[0014] Step 4: Summarize the service call records on the blockchain, generate service call settlement records, and store them on the blockchain;
[0015] Step 5: When the service call settlement record is completed and stored on the chain, the frozen funds of the service user are transferred to the service provider based on the service call settlement record.
[0016] In step 1, the API service subscription record primarily includes data such as the subscription ID, service user ID, service provider ID, API service ID, price per API service call, and number of API service subscriptions. The subscription ID is derived by hashing the service user ID, service provider ID, and API service ID using the SHA-256 hash algorithm. The service user node refers to the blockchain node that the API service user calls. Furthermore, the blockchain network also includes the service provider node, which is called by the API service provider.
[0017] In step 1, the method for building a blockchain network is as follows: based on the API service call scenario, the blockchain organization is divided according to the service users and service providers, and the blockchain network is built;
[0018] The blockchain network includes a service user organization and a service provider organization. The service user organization contains multiple service user nodes and service user accounts. The service user accounts correspond one-to-one to the service users, and the service users can call the corresponding service user nodes through their accounts; the service provider organization contains multiple service provider nodes and service provider accounts. The service provider accounts correspond one-to-one to the service providers, and the service providers can call the corresponding service provider nodes through their accounts.
[0019] The service user and the service provider complete the blockchain account registration by providing relevant user information.
[0020] The service user implements data interaction operations with the blockchain by calling the corresponding service user node, including: account recharge, API service subscription and call record settlement. The service user recharges the account funds by calling the fund management contract. The functions of calling the fund management contract include account fund recharge and account fund withdrawal; the service provider implements data interaction operations with the blockchain by calling the corresponding service provider node, including: publishing services, setting service prices and account withdrawal.
[0021] In step 2, the service user's fixed assets are frozen by triggering an asset freeze contract. The asset freeze contract divides and freezes the service user's funds based on a fixed asset. The fixed asset refers to the amount required for this API service subscription. The asset freeze record includes data such as the service user ID, service provider ID, subscription ID, and fixed asset.
[0022] The asset freezing contract mainly divides and freezes the service user's funds based on the fixed assets, which facilitates the subsequent API service call settlement and can effectively prevent the service user from owing money.
[0023] The fixed asset value is calculated by multiplying the price per subscription to the API service by the number of subscriptions.
[0024] In step 3, the service call record is stored in the blockchain through the service call record on-chain contract. The service call record on-chain contract refers to a smart contract that stores the service call record on the chain.
[0025] In step 3, the indicator data called in the API service subscription is monitored and obtained based on the trusted hardware device monitoring technology; the indicator data is relevant data for judging the quality of API service, including request processing speed, response time, throughput, etc., as well as API error rate, maximum concurrency, stability and other indicators calculated based on the above indicator data; the service call record includes call record ID, user ID, provider ID, API service ID, call time, whether the call is successful, call indicator parameters, etc., wherein the call indicator parameters are the indicator data.
[0026] The hardware device monitoring technology refers to the related technology for monitoring API services deployed on the cloud or server, specifically including gateway plug-in capture or traffic analysis technology.
[0027] In step 4, based on the service call record summary conditions, the service call summary contract is triggered regularly to summarize the service call records on the blockchain.
[0028] The service call record summary condition refers to the condition that triggers the call summary contract, for example: summarizing the service call records on the chain every day or every week.
[0029] The service call summary contract refers to a contract for summarizing the service call records over a period of time to generate the service call settlement records.
[0030] The service call summary contract only summarizes the service call records of successful API service calls. The service call records caused by slow response and call failure due to API service quality issues are not summarized.
[0031] The service call settlement record mainly includes data such as settlement ID, service user ID, service provider ID, subscription ID, API service ID, start time, end time, settlement amount, etc.
[0032] In step 5, by triggering the service transaction record transfer contract, based on the service call settlement record, the funds transfer from the service user's frozen funds to the service provider is completed.
[0033] The service transaction transfer contract refers to a contract for completing the fund transfer between the service user and the service provider based on the service call settlement record.
[0034] The settlement method provided by the present invention also includes: when the service user completes business needs or no longer uses the API service subscription, based on the registered account information and triggering the account fund settlement contract through the service user node, completing the fund settlement or fund refund for this API service subscription.
[0035] The account fund liquidation contract is used to complete the fund transfer from the service user who successfully called the API service to the service provider based on the service call record and the service call summary record, and to unfreeze the remaining frozen fixed assets and return them to the service user. The remaining frozen fixed assets refer to the unspent funds in the fixed assets due to failed API service calls or substandard service quality.
[0036] The settlement method provided by the present invention further includes: updating the quality evaluation of the corresponding API service based on the indicator data in the service call record in the local API service transaction settlement.
[0037] The present invention also provides a blockchain-based API service call transaction settlement device, including a memory and one or more processors, wherein the memory stores executable code, and when the one or more processors execute the executable code, they are used to implement the above-mentioned blockchain-based API service call transaction settlement method.
[0038] The present invention also provides a computer-readable storage medium having a program stored thereon, which, when executed by a processor, is used to implement the above-mentioned blockchain-based API service call transaction settlement method.
[0039] Compared with the prior art, the present invention has the following excellent effects:
[0040] (1) Aiming at the problem that the evaluation indicators of API service operation quality are too one-sided and the data source is single. Based on blockchain technology, this invention provides a safe and reliable detection environment for API service transactions and calls. By comprehensively monitoring the call indicators of API services and storing them on the chain, it not only achieves a comprehensive consideration of API service quality, but also ensures the security and reliability of the evaluation data source and the non-tamperability of the subsequent data, providing an objective and fair reference standard for service users.
[0041] (2) Aiming at the problems of API service transaction settlement process service, low security and disadvantageous compensation for service users. The present invention designs an account fund management method with functions such as fund freezing and fund return, provides a safe, reliable, open and transparent transaction environment for both parties of the transaction based on the blockchain network, and realizes the automated transaction of API services through smart contract technology, fully protecting the interests of both parties of the transaction, eliminating the centralized settlement agency, simplifying the transaction process and improving the transaction settlement efficiency.
[0042] (3) The security of API service data depends on third-party payment platforms, making it difficult to prevent data from being tampered with and difficult to trace back to its source. Based on the characteristics of blockchain that are secure, reliable, tamper-proof, and traceable, the present invention designs a blockchain-based API service data storage and traceability management method, ensuring that API service transaction settlement data cannot be tampered with and can be traced back to its source.
[0043] In summary, the blockchain-based API service call evidence storage and settlement method provided by the present invention builds a secure and trustworthy transaction environment for API service calls through the blockchain, so that the two parties to the transaction can complete a trusted transaction without knowing each other, thereby optimizing the transaction process; at the same time, the actual service calls are comprehensively monitored and stored on the chain. On the one hand, it ensures that the service call records cannot be tampered with and can be traced, thereby reducing transaction disputes; on the other hand, it provides a trustworthy basis for API service quality evaluation and settlement, effectively safeguarding the interests of service users. BRIEF DESCRIPTION OF THE DRAWINGS
[0044] Figure 1 is a flow chart of the blockchain-based API service call evidence settlement method. DETAILED DESCRIPTION
[0045] In order to better understand the technical solution of the present application, the embodiments of the present application are described in detail below with reference to the accompanying drawings.
[0046] It should be clear that the embodiments described are only part of the embodiments of this application, not all of the embodiments. Based on the embodiments in this application, all other embodiments obtained by ordinary technicians in this field without making creative work are within the scope of protection of this application.
[0047] The terms used in the embodiments of the present application are for the purpose of describing specific embodiments only and are not intended to limit the present application. The singular forms "a", "an", "the" and "the" used in the embodiments of the present application and the appended claims are also intended to include plural forms unless the context clearly indicates otherwise.
[0048] As shown in Figure 1, the blockchain-based API service call evidence storage and settlement method provided by the present invention uses blockchain technology to establish a secure and trustworthy transaction environment for API service calls, enabling trusted transactions to be completed even when the two parties are unfamiliar with each other, thereby optimizing the transaction process. Simultaneously, comprehensive monitoring of service calls is performed, and call details are recorded and stored on the blockchain. This, on the one hand, ensures that service call records cannot be tampered with and are traceable, reducing transaction disputes; on the other hand, it provides a reliable basis for API service quality evaluation and settlement, effectively safeguarding the interests of service users.
[0049] The method provided in this embodiment specifically includes the following steps:
[0050] S1. Based on the API service call scenario, according to the different users, that is, according to the service users and service providers, the blockchain organization is divided to build a blockchain-based service transaction platform.
[0051] The established blockchain network is divided into service user organizations and service provider organizations. Service user organizations include multiple service user nodes. Service users can call service user nodes through registered service user accounts to implement data interaction operations with the blockchain, such as account top-up, service subscription, call record settlement, etc. Similarly, service provider organizations include multiple service provider nodes. Service providers can also call service provider nodes through registered accounts to implement data interaction operations with the blockchain, such as publishing services, setting service prices, and account withdrawals.
[0052] S2. The service user (user) completes account registration on the platform page. If they need to purchase related services, they need to top up funds in the registered account, and they can also withdraw cash at any time.
[0053] For example, if user A fills in relevant user information on the platform and tops up 100 yuan, the platform will select the service user node based on the account type to call the smart contract to complete the on-chain storage of the account registration data and account top-up data, ensuring that the data cannot be tampered with and can be traced. After user A has used the relevant services and paid the corresponding fee, he can initiate a withdrawal of the account balance. The platform will refund the account and call the smart contract through the service user node to complete the update of the account data on the chain.
[0054] Specifically, service applicant A calls the fund management contract to recharge and withdraw account funds.
[0055] The service provider implements data interaction operations with the blockchain by calling the corresponding service provider node, including: publishing services, setting service prices and account withdrawals.
[0056] S3. Based on their own business needs, service users select appropriate API services from the platform's service market and choose to subscribe.
[0057] For example, if service consumer A selects a weather API service published by service provider B and initiates a subscription, the platform will generate a weather API service subscription record based on the identity of service consumer A and the details of the weather API service. The platform will then invoke a smart contract through the service consumer node to store the weather API service subscription record on-chain.
[0058] Weather API service call records mainly include subscription ID, service user ID, service provider ID, API service ID, API service single call price, API service subscription times and other data. Among them, the subscription ID is obtained by hashing the service user ID, service provider ID and API service ID using the SHA-256 hash algorithm.
[0059] For example: Weather API service subscription record: {Subscription ID: 055c285fada98806e70c1b33b1608b1abc424b5634461055c62084005aace927, Service consumer ID: A_id, Service provider ID: B_id, API service ID: weather id, API service single call price: 1¥, API service subscription times: 10}
[0060] S4. After the API service subscription record is uploaded to the chain for evidence storage, the asset freezing contract is triggered. Based on the API service subscription record, the quota assets of the service user are frozen, and an asset freezing record corresponding to the API service subscription record is generated and uploaded to the chain for evidence storage.
[0061] The asset freeze contract mainly divides and freezes the service user's funds based on a fixed amount of assets, which facilitates the subsequent API service call settlement and can effectively prevent the service user from owing money.
[0062] Fixed assets refer to the amount required for this API service subscription, which is calculated by multiplying the price per subscription by the number of subscriptions.
[0063] Asset freeze records mainly include data such as service user ID, service provider ID, subscription ID, and fixed assets.
[0064] For example, after a weather API service call record is uploaded to the blockchain, the asset freeze contract is triggered, freezing the corresponding amount of assets of service user A who subscribed to the weather API service. A corresponding frozen asset record is also generated and uploaded to the blockchain. The frozen asset record is: {Service user ID: A_id, Service provider ID: B_id, Subscription ID: 055c285fada98806e70c1b33b1608b1abc424b5634461055c62084005aace927, Fixed amount of assets: 10¥}.
[0065] S5. Based on trusted hardware device monitoring technology, the call indicator data of the subscribed API service is monitored and the corresponding service call record is generated. The service call record chain contract is called by the service user node to store the service call record in the blockchain.
[0066] Hardware device monitoring technology refers to the related technologies for monitoring API services deployed on the cloud or servers, specifically including gateway plug-in capture or traffic analysis technologies.
[0067] Indicator data refers to relevant data used to evaluate the quality of API services, including request processing speed, response time, throughput, etc., as well as indicators such as API error rate, maximum concurrency, and stability calculated based on the above indicators.
[0068] Service call records mainly include call record ID, user ID, provider ID, API service ID, call time, whether the call is successful, and call indicator parameters. Among them, call indicator parameters are indicator data.
[0069] The service call record on-chain contract refers to a smart contract that stores service call records on-chain.
[0070] For example: After service user A subscribes to the weather API service released by service provider B, after calling the weather API service, the monitoring technology will detect the specific call data and generate a corresponding service call record, such as: {call record ID: 6e70c1b33b1608b1abc4, user ID: A_id, provider ID: B_id, API service ID: weather id, call time: 2023.6.30-12:30:30, whether the call is successful: yes, call indicator parameters: ******}, and then send it to the corresponding service user node. The service user node calls the service call record chain contract to store the data on the chain.
[0071] S6. Based on the service call record summary conditions, the service call summary contract is triggered regularly to summarize the service call records on the chain, generate service call settlement records, and store them on the chain.
[0072] The service call record summary condition refers to the condition that triggers the call summary contract, for example: summarizing the on-chain service call records every day or every week.
[0073] A service call summary contract summarizes service call records over a period of time and generates service call settlement records. This contract only summarizes successful API service call records and does not summarize service call records resulting from slow responses or call failures due to API service quality issues.
[0074] Service call settlement records mainly include settlement ID, service user ID, service provider ID, subscription ID, API service ID, start time, end time, settlement amount and other data.
[0075] For example, if service consumer A successfully calls the weather API service three times in a certain day and the service call record summary condition is to summarize once a day, the service call summary contract will be triggered, and a service call settlement record will be generated: {settlement ID: settlement_id, service consumer ID: A_id, service provider ID: B_id, subscription ID: 055c285fada98806e70c1b33b1608b1abc424b5634461055c62084005aace927, API service ID: weather id, start time: 2023.6.30-12:30:30, end time: 2023.07.01-12:30:30, settlement amount: 3¥}.
[0076] S7. As the service call settlement record is uploaded to the chain, the service transaction transfer contract is triggered. Based on the service call settlement record, the funds transfer from the service user's frozen funds to the service provider is completed.
[0077] A service transaction transfer contract is a contract that completes the transfer of funds between the service user and the service provider based on the service call settlement record.
[0078] For example, when service user A uploads the service call settlement record of the weather API service to the chain, the service transaction transfer contract is triggered, and 3¥ is transferred from the 10¥ frozen when service user A subscribes to the weather API service to the account of service provider B.
[0079] S8. When the service user completes its business needs or no longer uses the API service it subscribed to, the account fund settlement contract is triggered through the service user node based on the account information to complete the fund settlement or fund refund for the subscribed API service.
[0080] The account fund liquidation contract refers to the completion of the fund transfer from the service user who has successfully called the API service to the service provider based on the service call record and service call summary record, and the unfreezing of the remaining fixed assets and returning them to the service user.
[0081] The frozen remaining fixed assets refer to the unspent funds in the fixed assets due to API service call failure or substandard service quality.
[0082] For example, after successfully calling the weather API service three times, service user A no longer needs the service. He or she can initiate a fund liquidation application through the service user node. The service user node triggers the account fund liquidation contract based on the application information, unfreezes the remaining 7¥, and returns it to service user A.
[0083] S9. The system administrator updates the quality evaluation of the corresponding API service based on the indicator data in the service call record in the local API service transaction settlement to help service users choose better API services.
[0084] An embodiment of the present invention further provides a blockchain-based API service call transaction settlement device, comprising one or more processors, and a memory storing executable code. When the processor executes the executable code, it is used to implement the blockchain-based API service call transaction settlement method in the above embodiment. Taking software implementation as an example, as a device in a logical sense, it is formed by the processor of any device with data processing capabilities in which it is located reading the corresponding computer program instructions in the non-volatile memory into the memory and executing it. From a hardware perspective, in addition to the processor, memory, network interface, and non-volatile memory, the device with data processing capabilities in which the device in the embodiment is located may also include other hardware based on the actual function of the device with data processing capabilities, which will not be described in detail.
[0085] An embodiment of the present invention further provides a computer-readable storage medium having a program stored thereon. When the program is executed by a processor, the blockchain-based API service call transaction settlement method described in the above embodiment is implemented. The computer-readable storage medium can be an internal storage unit of any device with data processing capabilities described in any of the aforementioned embodiments, such as a hard disk or memory. The computer-readable storage medium can also be any device with data processing capabilities, such as a plug-in hard disk, smart media card (SMC), SD card, flash memory card (Flash8Card), etc. equipped on the device. Furthermore, the computer-readable storage medium can also include both an internal storage unit of any device with data processing capabilities and an external storage device. The computer-readable storage medium is used to store the computer program and other programs and data required by any device with data processing capabilities, and can also be used to temporarily store data that has been output or is about to be output.
[0086] The foregoing is merely an embodiment of the present invention and is not intended to limit the present invention. It will be apparent to those skilled in the art that various modifications and variations of the present invention are possible. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the present invention are intended to be included within the scope of the claims of the present invention.
Claims
1. The blockchain-based API service calls the evidence settlement method, which is characterized by: The method comprises the following steps: Step 1: Build a blockchain network. The service user selects an API service that meets its business needs, generates an API service subscription record, and stores it on the blockchain through the service user node. Step 2: When the API service subscription record is uploaded to the blockchain, the quota assets of the service user are frozen based on the API service subscription record, and an asset freezing record corresponding to the API service subscription record is generated and uploaded to the blockchain through the service user node on the blockchain; Step 3: Get the indicator data called in the API service subscription, generate the corresponding service call record and store it in the blockchain through the service user node on the blockchain; Step 4: Summarize the service call records on the blockchain, generate service call settlement records, and store them on the blockchain through the service user node on the blockchain; Step 5: When the service call settlement record is completed and stored on the chain, the frozen funds of the service user are transferred to the service provider based on the service call settlement record.
2. The blockchain-based API service call evidence settlement method according to claim 1, characterized in that: In step 1, the method for building a blockchain network is: based on the API service call scenario, the blockchain organization is divided for service users and service providers, and the blockchain network is built; The blockchain network includes a service user organization and a service provider organization. The service user organization includes multiple service user nodes and service user accounts. The service user accounts correspond to the service users one-to-one, and the service users can call the corresponding service user nodes through their accounts; the service provider organization includes multiple service provider nodes and service provider accounts. The service provider accounts correspond to the service providers one-to-one, and the service providers can call the corresponding service provider nodes through their accounts.
3. The blockchain-based API service call evidence settlement method according to claim 2 is characterized in that: The service user implements data interaction operations with the blockchain by calling the corresponding service user node, including: account recharge, API service subscription and call record settlement. The service user recharges the account funds by calling the fund management contract, and the functions of calling the fund management contract include account fund recharge and account fund withdrawal; the service provider implements data interaction operations with the blockchain by calling the corresponding service provider node, including: publishing services, setting service prices and account withdrawal.
4. The blockchain-based API service call evidence settlement method according to claim 1, characterized in that: In step 2, the fixed assets of the service user are frozen by triggering the asset freezing contract: the asset freezing contract is to divide and freeze the funds of the service user based on the fixed assets; the fixed assets refer to the amount required for this subscription to the API service; the asset freezing record includes the service user ID, service provider ID, subscription ID and fixed assets.
5. The blockchain-based API service call evidence settlement method according to claim 1, characterized in that: In step 3, the service call record is stored in the blockchain through the service call record on-chain contract, and the service call record on-chain contract refers to a smart contract that stores the service call record on-chain.
6. The blockchain-based API service call evidence settlement method according to claim 1, characterized in that: In step 3, the indicator data called in the API service subscription is monitored and obtained based on the trusted hardware device monitoring technology; the indicator data is the relevant data used to judge the quality of the API service, including the processing request speed, response time, throughput, and the API error rate, maximum concurrency, and stability calculated based on the above indicator data; The service call record includes a call record ID, a user ID, a provider ID, an API service ID, a call time, whether the call is successful, and a call indicator parameter, wherein the call indicator parameter is the indicator data.
7. The blockchain-based API service call evidence settlement method according to claim 1, characterized in that: In step 4, based on the service call record summary condition, the service call summary contract is triggered regularly to summarize the service call records on the blockchain; the service call record summary condition refers to the condition for triggering the call summary contract, and the service call summary contract refers to a contract for summarizing the service call records in the past period of time and generating the service call settlement record; The service call summary contract only summarizes the service call records of successful API service calls; The service call settlement record includes the settlement ID, service user ID, service provider ID, subscription ID, API service ID, start time, end time, and settlement amount.
8. The blockchain-based API service call evidence settlement method according to claim 1, characterized in that: The settlement method further includes: When the service user completes the business needs or no longer uses the API service subscription, the account fund liquidation contract is triggered based on the registered account information and through the service user node to complete the fund liquidation or fund return for this API service subscription; Based on the indicator data in the service call record in the local API service transaction settlement, the quality evaluation of the corresponding API service is updated.
9. A blockchain-based API service call transaction settlement device, comprising a memory and one or more processors, wherein the memory stores executable code, and when the one or more processors execute the executable code, they are used to implement the blockchain-based API service call transaction settlement method described in any one of claims 1-8.
10. A computer-readable storage medium having a program stored thereon, which, when executed by a processor, is used to implement the blockchain-based API service call transaction settlement method described in any one of claims 1-8.
Citation Information
Patent Citations
Service transaction processing method, system and device based on federated block chain
CN109064330A
Digital asset information exchange system and method based on block chain
CN110335147A
Commodity transaction method and system for blockchain smart contract
CN110580618A
Business deployment method and device based on block chain
CN115550374A
API (Application Program Interface) service call evidence settlement method based on block chain
CN116883170A