From dbc2baaae9cf9bfcd7697fbfbc596d47f2ab72c8 Mon Sep 17 00:00:00 2001 From: Alex <61672317+AlexDevAPI@users.noreply.github.com> Date: Mon, 18 Jan 2021 18:42:38 +0800 Subject: [PATCH 01/36] Create API_Protocol.md --- applications/API_Protocol.md | 7 +++++++ 1 file changed, 7 insertions(+) create mode 100644 applications/API_Protocol.md diff --git a/applications/API_Protocol.md b/applications/API_Protocol.md new file mode 100644 index 00000000000..01058693918 --- /dev/null +++ b/applications/API_Protocol.md @@ -0,0 +1,7 @@ +# Open Grant Proposal + +* **Project Name:** API Protocol +* **Proposer:** [API Protocol](https://github.com/APIProtocol) +* **Payment Address:** 36wHH7KseuqtyTLMCB8dXKWm8VKdPRR8Vs + +## Project Overview :page_facing_up: From 471c816375c1133931540bc42947b758ffa1a00f Mon Sep 17 00:00:00 2001 From: Alex <61672317+AlexDevAPI@users.noreply.github.com> Date: Mon, 18 Jan 2021 18:58:30 +0800 Subject: [PATCH 02/36] Update API_Protocol.md --- applications/API_Protocol.md | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/applications/API_Protocol.md b/applications/API_Protocol.md index 01058693918..918a90a5138 100644 --- a/applications/API_Protocol.md +++ b/applications/API_Protocol.md @@ -5,3 +5,24 @@ * **Payment Address:** 36wHH7KseuqtyTLMCB8dXKWm8VKdPRR8Vs ## Project Overview :page_facing_up: + + + +API Protocol is a new generation of decentralized web API connector protocol for Web 3.0 applications, designed to make web 3.0 APIs easier to find, access and use, thus promoting the development of Web 3.0. + +API Protocol is a next-generation decentralized API (dAPI) service aggregator that enables your applications (dApps) to be truly decentralized and helps you accelerate development, significantly reduce time-to-market, reduce the risks associated with scaling and security over technology, significantly reduce downtime, and run applications on any decentralized or centralized cloud as well as any blockchain and smart contract platform. + + The API Protocol platform brings together a number of core technology innovations that will enable developers to build truly decentralized blockchain applications and digital products in the fastest way possible, without compromising on scalability, performance, security, resiliency and decentralization. + + API Protocol will build a cross-chain decentralized API service management platform on Polkdot based on the Substrate framework to provide decentralized API infrastructure for blockchain developers and improve the efficiency of developers building Dapp. + ![img](https://raw.githubusercontent.com/APIProtocol/research/main/API%20Protocol.png) + +## Team Interest + + The initial team members of API Protocol come from the blockchain and basic software operation and maintenance industries, and have a deep understanding of the operation and developer pain points in the IT industry. In order to serve the Web 3.0 ecosystem and make the Web 3.0 APIs easier to use, discover and find, so that developers can assemble their business like building blocks, we launched the API Protocol project. + + + + + + From 485a73ccd598a4816c353aaeebf63b7aae042aa4 Mon Sep 17 00:00:00 2001 From: Alex <61672317+AlexDevAPI@users.noreply.github.com> Date: Mon, 18 Jan 2021 19:09:27 +0800 Subject: [PATCH 03/36] Update API_Protocol.md --- applications/API_Protocol.md | 47 ++++++++++++++++++++++++++++++++++++ 1 file changed, 47 insertions(+) diff --git a/applications/API_Protocol.md b/applications/API_Protocol.md index 918a90a5138..e3828fcac6b 100644 --- a/applications/API_Protocol.md +++ b/applications/API_Protocol.md @@ -21,6 +21,53 @@ API Protocol is a next-generation decentralized API (dAPI) service aggregator th The initial team members of API Protocol come from the blockchain and basic software operation and maintenance industries, and have a deep understanding of the operation and developer pain points in the IT industry. In order to serve the Web 3.0 ecosystem and make the Web 3.0 APIs easier to use, discover and find, so that developers can assemble their business like building blocks, we launched the API Protocol project. + ## Project Details + + +### Architecture + ![img](https://raw.githubusercontent.com/APIProtocol/research/main/API%20Protocol%20arc.png) + +#### Technical components: + ##### 1 Consensus Layer + + Maintain the consensus security of the entire network security, API Protocol underlying the development of the Substrate framework, can enjoy the security and efficiency of Substrate. + + ##### 2 P2P Network + + Defines how ecological nodes interact and find each other + + ##### 3 API Adaptation Layer + + Adapt the underlying API services to help developers unify and shield the underlying service implementation details, and developers can enjoy out-of-the-box services. + + ##### 4 API Service Availability Engine + + Defines service availability metrics and compensation schemes for API services. + + ##### 5 API Service Registration + + Developers register API services so that other developers can discover and invoke them. + + ##### 6 API service discovery mechanism + + The process of discovering the service provider during the invocation. + + ##### 7 API MarketPlace + + Economic mechanism to provide suitable API services to openers + + + + + + + + + + + + + From 00ab540505d865084944550e76796e17e673ae39 Mon Sep 17 00:00:00 2001 From: Alex <61672317+AlexDevAPI@users.noreply.github.com> Date: Mon, 18 Jan 2021 19:30:08 +0800 Subject: [PATCH 04/36] Update API_Protocol.md --- applications/API_Protocol.md | 43 +++++++++++++++++++++++++++++++++++- 1 file changed, 42 insertions(+), 1 deletion(-) diff --git a/applications/API_Protocol.md b/applications/API_Protocol.md index e3828fcac6b..5848ba4cad9 100644 --- a/applications/API_Protocol.md +++ b/applications/API_Protocol.md @@ -25,7 +25,7 @@ API Protocol is a next-generation decentralized API (dAPI) service aggregator th ### Architecture - ![img](https://raw.githubusercontent.com/APIProtocol/research/main/API%20Protocol%20arc.png) + ![img](https://raw.githubusercontent.com/APIProtocol/research/main/API%20Protocol%20Architecture.png) #### Technical components: ##### 1 Consensus Layer @@ -55,6 +55,47 @@ API Protocol is a next-generation decentralized API (dAPI) service aggregator th ##### 7 API MarketPlace Economic mechanism to provide suitable API services to openers + +## Project usage scenarios: + + ##### Blockchain as a service + + ![img](https://raw.githubusercontent.com/APIProtocol/research/main/block%20chain%20%20as%20a%20service.png) + + BlockChain as a service makes it easy for developers to complete instant access to Ethereum, Filecoin/IPFS, Polkadot, Nucypher, Uniswap and other on-chain and off-chain protocols. + + ##### API as a service + + ![img](https://raw.githubusercontent.com/APIProtocol/research/main/api%20as%20a%20service.png) + + API as a service, allowing developers to easily switch and access between various underlying protocols. + + ##### Decentralized API Market + + ![img](https://raw.githubusercontent.com/APIProtocol/research/main/marketplace.png) + + A decentralized API marketplace based on Substrate blockchain technology, giving developers more and more reliable service options. + + ##### SDK as a service + + ![img](https://raw.githubusercontent.com/APIProtocol/research/main/sdk%20as%20a%20service.png) + + The decentralized SDK developed by the API Protocol team allows developers to quickly build their own applications + + ## Substrate / Polkadot Integration: + + The API Protocol will be developed and designed based on the Substate 2.0 underlying engine, leveraging the Substate 2.0 off-chain module to provide API services for Web 3.0 developers. + + + + + + + + + + + From d985ab05989574ccefc7c5596224c26bb10d504f Mon Sep 17 00:00:00 2001 From: Alex <61672317+AlexDevAPI@users.noreply.github.com> Date: Mon, 18 Jan 2021 19:30:58 +0800 Subject: [PATCH 05/36] Update API_Protocol.md --- applications/API_Protocol.md | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/applications/API_Protocol.md b/applications/API_Protocol.md index 5848ba4cad9..505ac9e855b 100644 --- a/applications/API_Protocol.md +++ b/applications/API_Protocol.md @@ -58,25 +58,25 @@ API Protocol is a next-generation decentralized API (dAPI) service aggregator th ## Project usage scenarios: - ##### Blockchain as a service + ##### 1 Blockchain as a service ![img](https://raw.githubusercontent.com/APIProtocol/research/main/block%20chain%20%20as%20a%20service.png) BlockChain as a service makes it easy for developers to complete instant access to Ethereum, Filecoin/IPFS, Polkadot, Nucypher, Uniswap and other on-chain and off-chain protocols. - ##### API as a service + ##### 2 API as a service ![img](https://raw.githubusercontent.com/APIProtocol/research/main/api%20as%20a%20service.png) API as a service, allowing developers to easily switch and access between various underlying protocols. - ##### Decentralized API Market + ##### 3 Decentralized API Market ![img](https://raw.githubusercontent.com/APIProtocol/research/main/marketplace.png) A decentralized API marketplace based on Substrate blockchain technology, giving developers more and more reliable service options. - ##### SDK as a service + ##### 4 SDK as a service ![img](https://raw.githubusercontent.com/APIProtocol/research/main/sdk%20as%20a%20service.png) From f8dcbd724427116a4e1e5a7a8560b77772737006 Mon Sep 17 00:00:00 2001 From: Alex <61672317+AlexDevAPI@users.noreply.github.com> Date: Mon, 18 Jan 2021 19:32:47 +0800 Subject: [PATCH 06/36] Update API_Protocol.md --- applications/API_Protocol.md | 3 +++ 1 file changed, 3 insertions(+) diff --git a/applications/API_Protocol.md b/applications/API_Protocol.md index 505ac9e855b..cfa58ade674 100644 --- a/applications/API_Protocol.md +++ b/applications/API_Protocol.md @@ -85,6 +85,9 @@ API Protocol is a next-generation decentralized API (dAPI) service aggregator th ## Substrate / Polkadot Integration: The API Protocol will be developed and designed based on the Substate 2.0 underlying engine, leveraging the Substate 2.0 off-chain module to provide API services for Web 3.0 developers. + + ## Ecosystem Fit + API Protocol is the Web 3.0 API economic infrastructure, dedicated to making Web 3.0 APIs easier to find, access and use, to develop Web 3.0 applications more simple and efficient, thus promoting the development of Web 3.0. From 476fb365ea644e1fa02aaceff94c38ed908b3cfe Mon Sep 17 00:00:00 2001 From: Alex <61672317+AlexDevAPI@users.noreply.github.com> Date: Mon, 18 Jan 2021 19:42:47 +0800 Subject: [PATCH 07/36] Update API_Protocol.md --- applications/API_Protocol.md | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/applications/API_Protocol.md b/applications/API_Protocol.md index cfa58ade674..0c02ced068d 100644 --- a/applications/API_Protocol.md +++ b/applications/API_Protocol.md @@ -88,6 +88,25 @@ API Protocol is a next-generation decentralized API (dAPI) service aggregator th ## Ecosystem Fit API Protocol is the Web 3.0 API economic infrastructure, dedicated to making Web 3.0 APIs easier to find, access and use, to develop Web 3.0 applications more simple and efficient, thus promoting the development of Web 3.0. + + + ## Team members + +* haijun - CTO/Project Lead +* Alex - Developer + +## Contact + +[API Protocol](https://apiprotocol.link/#/) + + + + + +## Legal Structure +No Legal Entity + + From 7cd3c67e73097862c143025bae2e96f1082ea300 Mon Sep 17 00:00:00 2001 From: Alex <61672317+AlexDevAPI@users.noreply.github.com> Date: Mon, 18 Jan 2021 19:52:15 +0800 Subject: [PATCH 08/36] Update API_Protocol.md --- applications/API_Protocol.md | 13 +++++++++++++ 1 file changed, 13 insertions(+) diff --git a/applications/API_Protocol.md b/applications/API_Protocol.md index 0c02ced068d..05736c9f6cf 100644 --- a/applications/API_Protocol.md +++ b/applications/API_Protocol.md @@ -105,6 +105,19 @@ API Protocol is a next-generation decentralized API (dAPI) service aggregator th ## Legal Structure No Legal Entity + +## Team's experience +The project leader, Haijun, is a serial entrepreneur who has experienced the entrepreneurial wave of mobile Internet and enterprise-level IT services, and has also participated in the public chain development of blockchain projects. Previously, he developed products based on the Cosmos-SDK ecosystem, but he saw polkadot’s The Web 3.0 ecological vision is more in line with the development trend of the Internet, and I hope to participate in the construction of the Web 3.0 ecology, so the API Protocol project was established. + +## Team Code Repos +* https://github.com/AlexDevAPI + + +## Team LinkedIn Profiles +* https://www.linkedin.com/in/haijun-zhao-0a76652b/ + + + From 0cfca1a8fac59c239474f52bd7a9d86f817eb200 Mon Sep 17 00:00:00 2001 From: Alex <61672317+AlexDevAPI@users.noreply.github.com> Date: Mon, 18 Jan 2021 19:52:34 +0800 Subject: [PATCH 09/36] Update API_Protocol.md --- applications/API_Protocol.md | 2 ++ 1 file changed, 2 insertions(+) diff --git a/applications/API_Protocol.md b/applications/API_Protocol.md index 05736c9f6cf..c49440e0a95 100644 --- a/applications/API_Protocol.md +++ b/applications/API_Protocol.md @@ -15,6 +15,8 @@ API Protocol is a next-generation decentralized API (dAPI) service aggregator th The API Protocol platform brings together a number of core technology innovations that will enable developers to build truly decentralized blockchain applications and digital products in the fastest way possible, without compromising on scalability, performance, security, resiliency and decentralization. API Protocol will build a cross-chain decentralized API service management platform on Polkdot based on the Substrate framework to provide decentralized API infrastructure for blockchain developers and improve the efficiency of developers building Dapp. + + ![img](https://raw.githubusercontent.com/APIProtocol/research/main/API%20Protocol.png) ## Team Interest From bb2734f34bd984a35255f1c077f9aa621e609225 Mon Sep 17 00:00:00 2001 From: Alex <61672317+AlexDevAPI@users.noreply.github.com> Date: Tue, 19 Jan 2021 10:42:51 +0800 Subject: [PATCH 10/36] Update API_Protocol.md --- applications/API_Protocol.md | 54 ++++++++++++++++++++++++++++++++++++ 1 file changed, 54 insertions(+) diff --git a/applications/API_Protocol.md b/applications/API_Protocol.md index c49440e0a95..2d781abe3dc 100644 --- a/applications/API_Protocol.md +++ b/applications/API_Protocol.md @@ -118,6 +118,60 @@ The project leader, Haijun, is a serial entrepreneur who has experienced the ent ## Team LinkedIn Profiles * https://www.linkedin.com/in/haijun-zhao-0a76652b/ +## Development Roadmap :nut_and_bolt: + +### Overview + +* **Total Estimated Duration:** 2 months +* **Full-time equivalent (FTE):** 3 +* **Total Costs:** 1.5 BTC + +#### Milestone 1 — Verify Production of Concepts (POC) and Implement Substrate Modules + +In this milestone, we will verify features with limited users and launch the testnet for the production of concepts. The implementation of off-chain workers of Substrate Framework will be built and validated. + +* **Estimated Duration:** 2 months +* **Full-time Equivalent (FTE)**: 3 +* **Costs:** 1.5 BTC + +| **Number** | **Deliverable** | **Specification** | +| ---------- | ---------------------------------------- | ------------------------------------------------------------ | +| 0a. | License | Apache License 2.0 | +| 0b. | Documentation | Documents containing the description of whole architecture design for API Protocol. | +| 0c. | Testing Guide | We will provide a full test suite and guide for the POC. | +| 1. | API Service Node | The node provides the function of adapting node APIs such as ETH, Filecoin/IPFS, Chia, and Polkadot. | +| 2. | API Hub network | The API hub network is a decentralized network that mainly provides decentralized API service discovery and invocation. | +| 3. | API Marketplace | API MarketPlace is an open API service exchange and pricing market. Web 3.0 Dapp can easily obtain the API services you want through API MarketPlace. | +| 4. | Docker Image | The API Protocol docker image contains the POC version which can be running anywhere to verify the idea of API Protocol. | + +### Community Engagement + +API Protocol 's current community engagement strategies include: + +* **Exposure on Leading Media Channels:** We will continue to publish articles about API Protocol in well-known media such as Golden Finance and Mars Finance. +* **Ecosystem Development Lead Program:** As the team is still small, we are now recruiting excellent developers through various channels, and later we will also set up a community eco-developer fund to attract more developers to participate in the API Protocol eco-building. +* **Promotion of Online and Offline Events:** WWe are also actively participating in Polkadot ecological AMA activities, in order to better understand Polkadot, so as to better serve Web 3.0 developers.. + +API Protocol's future community engagement strategies include: + +* **Bounty Program for General Community:** API Protocol is a brand new project, the community is relatively weak, so in the initial stage, we are more to find like-minded community ambassadors to help build the API community. For these community ambassadors, we will also give generous returns。 + +* **Incentive Program for API Providers:** After the main functions are completed, we will set up an incentive program to encourage more market API providers for API Protocol。 + + +## Future Plans + +* Expand the team +* Expand community influence. +* Ecological construction. + +## Additional Information :heavy_plus_sign: + +* Website: https://apiprotocol.link +* Twitter: https://twitter.com/APIProtocol +* Medium: https://apiprotocol.medium.com/ +* Github: https://github.com/APIProtocol + From 223559b75c1026dfa4a967e52a1eef199f0da02c Mon Sep 17 00:00:00 2001 From: Alex <61672317+AlexDevAPI@users.noreply.github.com> Date: Tue, 19 Jan 2021 10:46:54 +0800 Subject: [PATCH 11/36] Update API_Protocol.md --- applications/API_Protocol.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/applications/API_Protocol.md b/applications/API_Protocol.md index 2d781abe3dc..ff74f664954 100644 --- a/applications/API_Protocol.md +++ b/applications/API_Protocol.md @@ -89,7 +89,7 @@ API Protocol is a next-generation decentralized API (dAPI) service aggregator th The API Protocol will be developed and designed based on the Substate 2.0 underlying engine, leveraging the Substate 2.0 off-chain module to provide API services for Web 3.0 developers. ## Ecosystem Fit - API Protocol is the Web 3.0 API economic infrastructure, dedicated to making Web 3.0 APIs easier to find, access and use, to develop Web 3.0 applications more simple and efficient, thus promoting the development of Web 3.0. + API Protocol is the Web 3.0 API Economy infrastructure, dedicated to making Web 3.0 APIs easier to find, access and use, to develop Web 3.0 applications more simple and efficient, thus promoting the development of Web 3.0. ## Team members @@ -122,7 +122,7 @@ The project leader, Haijun, is a serial entrepreneur who has experienced the ent ### Overview -* **Total Estimated Duration:** 2 months +* **Total Estimated Duration:** 3 months * **Full-time equivalent (FTE):** 3 * **Total Costs:** 1.5 BTC From 53e4f389f1221e84ed29ac1c5a274410e7a37b40 Mon Sep 17 00:00:00 2001 From: Alex <61672317+AlexDevAPI@users.noreply.github.com> Date: Tue, 19 Jan 2021 10:49:10 +0800 Subject: [PATCH 12/36] Update API_Protocol.md --- applications/API_Protocol.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/applications/API_Protocol.md b/applications/API_Protocol.md index ff74f664954..ec2b1257423 100644 --- a/applications/API_Protocol.md +++ b/applications/API_Protocol.md @@ -150,7 +150,7 @@ API Protocol 's current community engagement strategies include: * **Exposure on Leading Media Channels:** We will continue to publish articles about API Protocol in well-known media such as Golden Finance and Mars Finance. * **Ecosystem Development Lead Program:** As the team is still small, we are now recruiting excellent developers through various channels, and later we will also set up a community eco-developer fund to attract more developers to participate in the API Protocol eco-building. -* **Promotion of Online and Offline Events:** WWe are also actively participating in Polkadot ecological AMA activities, in order to better understand Polkadot, so as to better serve Web 3.0 developers.. +* **Promotion of Online and Offline Events:** We are also actively participating in Polkadot ecological AMA activities, in order to better understand Polkadot, so as to better serve Web 3.0 developers. API Protocol's future community engagement strategies include: From 59f287ae93de07e24c4395c93321d41512713c80 Mon Sep 17 00:00:00 2001 From: Alex <61672317+AlexDevAPI@users.noreply.github.com> Date: Tue, 19 Jan 2021 10:50:13 +0800 Subject: [PATCH 13/36] Update API_Protocol.md --- applications/API_Protocol.md | 1 + 1 file changed, 1 insertion(+) diff --git a/applications/API_Protocol.md b/applications/API_Protocol.md index ec2b1257423..72fa49e0184 100644 --- a/applications/API_Protocol.md +++ b/applications/API_Protocol.md @@ -174,6 +174,7 @@ API Protocol's future community engagement strategies include: + From 5f17d92d79490e123ac77c48fef123d2c53bd4bb Mon Sep 17 00:00:00 2001 From: Alex <61672317+AlexDevAPI@users.noreply.github.com> Date: Wed, 20 Jan 2021 10:00:02 +0800 Subject: [PATCH 14/36] Update API_Protocol.md --- applications/API_Protocol.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/applications/API_Protocol.md b/applications/API_Protocol.md index 72fa49e0184..b2492793a51 100644 --- a/applications/API_Protocol.md +++ b/applications/API_Protocol.md @@ -132,7 +132,7 @@ In this milestone, we will verify features with limited users and launch the tes * **Estimated Duration:** 2 months * **Full-time Equivalent (FTE)**: 3 -* **Costs:** 1.5 BTC +* **Costs:** 0.5 BTC | **Number** | **Deliverable** | **Specification** | | ---------- | ---------------------------------------- | ------------------------------------------------------------ | From b3f18ceaa210cd78f1652ab71c81d35d240fde97 Mon Sep 17 00:00:00 2001 From: Alex <61672317+AlexDevAPI@users.noreply.github.com> Date: Wed, 20 Jan 2021 15:25:05 +0800 Subject: [PATCH 15/36] Update API_Protocol.md --- applications/API_Protocol.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/applications/API_Protocol.md b/applications/API_Protocol.md index b2492793a51..7abc8e7edfb 100644 --- a/applications/API_Protocol.md +++ b/applications/API_Protocol.md @@ -124,7 +124,7 @@ The project leader, Haijun, is a serial entrepreneur who has experienced the ent * **Total Estimated Duration:** 3 months * **Full-time equivalent (FTE):** 3 -* **Total Costs:** 1.5 BTC +* **Total Costs:** 0.5 BTC #### Milestone 1 — Verify Production of Concepts (POC) and Implement Substrate Modules From 0e2e01fa91292cc9e1ff92b23a98ed0d7686a7d0 Mon Sep 17 00:00:00 2001 From: Alex <61672317+AlexDevAPI@users.noreply.github.com> Date: Sun, 24 Jan 2021 17:31:16 +0800 Subject: [PATCH 16/36] Update API_Protocol.md --- applications/API_Protocol.md | 85 ++++++++++++++++++++---------------- 1 file changed, 47 insertions(+), 38 deletions(-) diff --git a/applications/API_Protocol.md b/applications/API_Protocol.md index 7abc8e7edfb..45b59245edd 100644 --- a/applications/API_Protocol.md +++ b/applications/API_Protocol.md @@ -64,25 +64,68 @@ API Protocol is a next-generation decentralized API (dAPI) service aggregator th ![img](https://raw.githubusercontent.com/APIProtocol/research/main/block%20chain%20%20as%20a%20service.png) - BlockChain as a service makes it easy for developers to complete instant access to Ethereum, Filecoin/IPFS, Polkadot, Nucypher, Uniswap and other on-chain and off-chain protocols. + When using Blockchain as a service, developers can use the node service provided by the API Protocol ecosystem to achieve timely access to the Ethereum, IPFS network, and Polkadot ecological nodes。 + + At the time of authorization, the user's project ID and private key registered in the API Protocol platform are used to complete security control, and the user's information is managed centrally at the beginning, and the decentralization will be completed at a later stage by using the Poca ecological user information management project. + ```python + Complete security control using Project ID: + + curl https://.apiprotocol.link/naas/PROJECT-ID + + Use project ID and project key to complete security control: + + curl --user :PROJECT-SECRET \ + https://.apiprotocol.link/naas/PROJECT-ID + + ``` + Initially, the supported protocols are HTTPS and WebSocket : + ``` + :JSON-RPC OVER HTTPS + :JOSN-RPC OVER WebSocket + ``` + A request time example: + ``` + $ curl -X POST \ + -H "Content-Type: application/json" \ + --data '{"jsonrpc": "2.0", "id": 1, "method": "eth_blockNumber", "params": []}' \ + "https://polkadot.apiprotocol.link/naas/PROJECT-ID" + ``` + Return result: + ``` + {"jsonrpc": "2.0","result": "0x657abc", "id":1} + ``` ##### 2 API as a service ![img](https://raw.githubusercontent.com/APIProtocol/research/main/api%20as%20a%20service.png) + + API as a Service allows service providers to monetize their API services, and by providing an API marketplace in the API Protocol ecosystem, API service utilizers can receive revenue and incentives in the form of API Protocol native tokens. + + The types of APIs are initially divided into the API Protocol system: data services and event services. + + ###### Data API Service Access Process. + + The data API service provider encapsulates its service in the form of microservice, and then registers through API Protocol's decentralized marketplace, and then after the community of API Protoco ecosystem votes to reach a certain number of votes, the API service provider registers a proxy service contract in API Protocol's consensus network. The contract contains a request for data to be processed, and then sends a request event to the API service provider, which receives the request, does the corresponding processing operations, and returns the result to the proxy contract, which sends the data to the service requester. + + ![img](https://raw.githubusercontent.com/APIProtocol/research/main/data%20API%20service.png) + + + ###### Event API Service Access Process. + + ![img](https://raw.githubusercontent.com/APIProtocol/research/main/Event%20API%20Service.png) - API as a service, allowing developers to easily switch and access between various underlying protocols. ##### 3 Decentralized API Market ![img](https://raw.githubusercontent.com/APIProtocol/research/main/marketplace.png) - A decentralized API marketplace based on Substrate blockchain technology, giving developers more and more reliable service options. + API Protocol's decentralized marketplace serves as a contract for managing basic API information, including registration and payment of API services, as well as basic information display, and will later support decentralized exchange functions based on API tokens to help API service providers better monetize their APIs. ##### 4 SDK as a service ![img](https://raw.githubusercontent.com/APIProtocol/research/main/sdk%20as%20a%20service.png) - The decentralized SDK developed by the API Protocol team allows developers to quickly build their own applications + SDKs play an important role in the software development process as a tool to help developers build applications quickly, but the lack of commercialization of development SDKs has led to a lack of willingness to build SDKs. The rewards will be decided by API Protocol's community vote. ## Substrate / Polkadot Integration: @@ -172,37 +215,3 @@ API Protocol's future community engagement strategies include: * Medium: https://apiprotocol.medium.com/ * Github: https://github.com/APIProtocol - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - From 0ded88e411217d603afa713cc0564ffc0b384c53 Mon Sep 17 00:00:00 2001 From: Alex <61672317+AlexDevAPI@users.noreply.github.com> Date: Mon, 25 Jan 2021 12:36:07 +0800 Subject: [PATCH 17/36] Update API_Protocol.md --- applications/API_Protocol.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/applications/API_Protocol.md b/applications/API_Protocol.md index 45b59245edd..f33a932acf6 100644 --- a/applications/API_Protocol.md +++ b/applications/API_Protocol.md @@ -152,7 +152,7 @@ API Protocol is a next-generation decentralized API (dAPI) service aggregator th No Legal Entity ## Team's experience -The project leader, Haijun, is a serial entrepreneur who has experienced the entrepreneurial wave of mobile Internet and enterprise-level IT services, and has also participated in the public chain development of blockchain projects. Previously, he developed products based on the Cosmos-SDK ecosystem, but he saw polkadot’s The Web 3.0 ecological vision is more in line with the development trend of the Internet, and I hope to participate in the construction of the Web 3.0 ecology, so the API Protocol project was established. +The project leader, Haijun, is a serial entrepreneur who has experienced the entrepreneurial wave of mobile Internet and enterprise-level IT services, and has also participated in the public chain development of blockchain projects. Previously, he developed products based on the Cosmos-SDK ecosystem, but he saw polkadot’s The Web 3.0 ecological vision is more in line with the development trend of the Internet, and We hope to participate in the construction of the Web 3.0 ecology, so the API Protocol project was established. ## Team Code Repos * https://github.com/AlexDevAPI From 925d2661dd5af4b1fdb6931525e4816f69f2ffec Mon Sep 17 00:00:00 2001 From: Alex <61672317+AlexDevAPI@users.noreply.github.com> Date: Mon, 25 Jan 2021 15:00:59 +0800 Subject: [PATCH 18/36] Update API_Protocol.md --- applications/API_Protocol.md | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/applications/API_Protocol.md b/applications/API_Protocol.md index f33a932acf6..d5c252f502f 100644 --- a/applications/API_Protocol.md +++ b/applications/API_Protocol.md @@ -127,6 +127,13 @@ API Protocol is a next-generation decentralized API (dAPI) service aggregator th SDKs play an important role in the software development process as a tool to help developers build applications quickly, but the lack of commercialization of development SDKs has led to a lack of willingness to build SDKs. The rewards will be decided by API Protocol's community vote. + ##### API service operator + + + API service providers will run API Node, which is a blockchain network node based on Substrate 2.0. In addition to participating in network consensus and maintaining network security, it also has an off-chain work function based on Substrate Off-Chain Workers technology. + + ![img](https://raw.githubusercontent.com/APIProtocol/research/main/API%20Node.png) + ## Substrate / Polkadot Integration: The API Protocol will be developed and designed based on the Substate 2.0 underlying engine, leveraging the Substate 2.0 off-chain module to provide API services for Web 3.0 developers. From 81fca7cfbc48fdbb374e6992d93fe1cb36986bf0 Mon Sep 17 00:00:00 2001 From: Alex <61672317+AlexDevAPI@users.noreply.github.com> Date: Mon, 25 Jan 2021 15:02:42 +0800 Subject: [PATCH 19/36] Update API_Protocol.md --- applications/API_Protocol.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/applications/API_Protocol.md b/applications/API_Protocol.md index d5c252f502f..ba85f9f91b0 100644 --- a/applications/API_Protocol.md +++ b/applications/API_Protocol.md @@ -127,7 +127,7 @@ API Protocol is a next-generation decentralized API (dAPI) service aggregator th SDKs play an important role in the software development process as a tool to help developers build applications quickly, but the lack of commercialization of development SDKs has led to a lack of willingness to build SDKs. The rewards will be decided by API Protocol's community vote. - ##### API service operator + ##### 5 API service operator API service providers will run API Node, which is a blockchain network node based on Substrate 2.0. In addition to participating in network consensus and maintaining network security, it also has an off-chain work function based on Substrate Off-Chain Workers technology. From e21333c902342ec70297bc8179b3a9fc947a5ed4 Mon Sep 17 00:00:00 2001 From: Alex <61672317+AlexDevAPI@users.noreply.github.com> Date: Mon, 25 Jan 2021 15:32:41 +0800 Subject: [PATCH 20/36] Update API_Protocol.md --- applications/API_Protocol.md | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/applications/API_Protocol.md b/applications/API_Protocol.md index ba85f9f91b0..fb34b04e3fa 100644 --- a/applications/API_Protocol.md +++ b/applications/API_Protocol.md @@ -134,6 +134,14 @@ API Protocol is a next-generation decentralized API (dAPI) service aggregator th ![img](https://raw.githubusercontent.com/APIProtocol/research/main/API%20Node.png) + ##### 6 Dapp developer + + + Dapp developers can use the Baas service provided by API Protocol to quickly access the blockchain network and quickly develop and distribute their applications. + ![img](https://raw.githubusercontent.com/APIProtocol/research/main/Developer.png) + + + ## Substrate / Polkadot Integration: The API Protocol will be developed and designed based on the Substate 2.0 underlying engine, leveraging the Substate 2.0 off-chain module to provide API services for Web 3.0 developers. From 77bc49587f67951d6cc68e992869e37c5bb0ab22 Mon Sep 17 00:00:00 2001 From: Alex <61672317+AlexDevAPI@users.noreply.github.com> Date: Mon, 25 Jan 2021 15:33:41 +0800 Subject: [PATCH 21/36] Update API_Protocol.md --- applications/API_Protocol.md | 1 + 1 file changed, 1 insertion(+) diff --git a/applications/API_Protocol.md b/applications/API_Protocol.md index fb34b04e3fa..32350011631 100644 --- a/applications/API_Protocol.md +++ b/applications/API_Protocol.md @@ -138,6 +138,7 @@ API Protocol is a next-generation decentralized API (dAPI) service aggregator th Dapp developers can use the Baas service provided by API Protocol to quickly access the blockchain network and quickly develop and distribute their applications. + ![img](https://raw.githubusercontent.com/APIProtocol/research/main/Developer.png) From 8ad9ca01de8e2815e2f4f8aeca243cecc25fe36b Mon Sep 17 00:00:00 2001 From: Alex <61672317+AlexDevAPI@users.noreply.github.com> Date: Mon, 25 Jan 2021 16:22:35 +0800 Subject: [PATCH 22/36] Update API_Protocol.md --- applications/API_Protocol.md | 19 ++++++++++++++++++- 1 file changed, 18 insertions(+), 1 deletion(-) diff --git a/applications/API_Protocol.md b/applications/API_Protocol.md index 32350011631..9726d2391df 100644 --- a/applications/API_Protocol.md +++ b/applications/API_Protocol.md @@ -141,7 +141,24 @@ API Protocol is a next-generation decentralized API (dAPI) service aggregator th ![img](https://raw.githubusercontent.com/APIProtocol/research/main/Developer.png) - + ##### 7 DeFi uses API services + DeFi is an on-chain smart contract. Because it needs events and data indicators to drive the program to perform corresponding operations, it needs to interact with external APIs. + When the DeFi smart contract uses the event and data indicator API provided by the API Protocol, the DeFi contract must first inherit an APIServiceBridge class, the code is as follows: + + ``` + // Contrace inherits the APIServiceBridge to gain the + // functionality of creating API Protocol data requests. + contract DeFiContract is APIServiceBridge { + + constructor( address proxyAPI) public { + + setProxyAPI(proxyAPI); + } + // Additional functions here: + +} + + ``` ## Substrate / Polkadot Integration: From 6b73ede9b02c56f34558383d7d5f17529a3c5ba7 Mon Sep 17 00:00:00 2001 From: Alex <61672317+AlexDevAPI@users.noreply.github.com> Date: Mon, 25 Jan 2021 16:23:25 +0800 Subject: [PATCH 23/36] Update API_Protocol.md --- applications/API_Protocol.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/applications/API_Protocol.md b/applications/API_Protocol.md index 9726d2391df..26b1b2a5a0c 100644 --- a/applications/API_Protocol.md +++ b/applications/API_Protocol.md @@ -145,7 +145,7 @@ API Protocol is a next-generation decentralized API (dAPI) service aggregator th DeFi is an on-chain smart contract. Because it needs events and data indicators to drive the program to perform corresponding operations, it needs to interact with external APIs. When the DeFi smart contract uses the event and data indicator API provided by the API Protocol, the DeFi contract must first inherit an APIServiceBridge class, the code is as follows: - ``` + ```python // Contrace inherits the APIServiceBridge to gain the // functionality of creating API Protocol data requests. contract DeFiContract is APIServiceBridge { From b4b9e1896aa34d66a1f9a4a0626e8a43f36817cc Mon Sep 17 00:00:00 2001 From: Alex <61672317+AlexDevAPI@users.noreply.github.com> Date: Tue, 26 Jan 2021 08:33:02 +0800 Subject: [PATCH 24/36] Update API_Protocol.md --- applications/API_Protocol.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/applications/API_Protocol.md b/applications/API_Protocol.md index 26b1b2a5a0c..4a6f0bfea9c 100644 --- a/applications/API_Protocol.md +++ b/applications/API_Protocol.md @@ -198,7 +198,7 @@ The project leader, Haijun, is a serial entrepreneur who has experienced the ent ### Overview -* **Total Estimated Duration:** 3 months +* **Total Estimated Duration:** 2 months * **Full-time equivalent (FTE):** 3 * **Total Costs:** 0.5 BTC From ff881668a7e01ac514a9dc78427a19a94b62862a Mon Sep 17 00:00:00 2001 From: Alex <61672317+AlexDevAPI@users.noreply.github.com> Date: Tue, 26 Jan 2021 11:37:02 +0800 Subject: [PATCH 25/36] Update API_Protocol.md --- applications/API_Protocol.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/applications/API_Protocol.md b/applications/API_Protocol.md index 4a6f0bfea9c..9aafd9a82a0 100644 --- a/applications/API_Protocol.md +++ b/applications/API_Protocol.md @@ -130,7 +130,7 @@ API Protocol is a next-generation decentralized API (dAPI) service aggregator th ##### 5 API service operator - API service providers will run API Node, which is a blockchain network node based on Substrate 2.0. In addition to participating in network consensus and maintaining network security, it also has an off-chain work function based on Substrate Off-Chain Workers technology. + API service providers will run API Node, which is a blockchain network node based on Substrate 2.0. In addition to participating in network consensus and maintaining network security, it also has an off-chain work function based on Substrate Off-Chain technology. ![img](https://raw.githubusercontent.com/APIProtocol/research/main/API%20Node.png) From 9ddaf338371da38e7b40797a9274a5830976cf69 Mon Sep 17 00:00:00 2001 From: Alex <61672317+AlexDevAPI@users.noreply.github.com> Date: Tue, 26 Jan 2021 14:38:51 +0800 Subject: [PATCH 26/36] Update API_Protocol.md --- applications/API_Protocol.md | 58 ++++++++++++++++++++++++++++++++++++ 1 file changed, 58 insertions(+) diff --git a/applications/API_Protocol.md b/applications/API_Protocol.md index 9aafd9a82a0..ab7dd2baec6 100644 --- a/applications/API_Protocol.md +++ b/applications/API_Protocol.md @@ -164,6 +164,64 @@ API Protocol is a next-generation decentralized API (dAPI) service aggregator th The API Protocol will be developed and designed based on the Substate 2.0 underlying engine, leveraging the Substate 2.0 off-chain module to provide API services for Web 3.0 developers. + ### Tech Stack + + #### Rust + Rust is a systems programming language with a focus on security, especially concurrency security, and a multi-paradigm language that supports functional and imperative programming paradigms as well as generics. + + Rust will be the primary development language for API Protocol. + + #### Substrate + + Substrate is an open source, modular and scalable blockchain development framework, Substrate provides the core components of blockchain: database layer (RocksDB), network layer (libp2p), transaction queue, pluggable consensus, off-chain working mechanism, FRAME. + + ![img](https://raw.githubusercontent.com/APIProtocol/research/main/substrate.png) + + API Protocol is a blockchain project built on top of Substate 2.0. The construction of the underlying ecology of polkadot ecology is crucial to the success of API Protocol, API Protocol network is connected to polkadot ecology as a parachain of polkadot ecology, sharing the security and performance of polkadot ecology. The API Protocol network is connected to Polkadot as a parachain of Polkadot ecosystem, sharing the network security and performance brought by Polkadot's underlying consensus security and Substrate2.0, API Protocol is committed to become the underlying API monetization infrastructure to promote the development of Web 3.0. API Protocol will also join Polkadot's Relay chain at the right time to better serve developers in the Polkadot ecosystem. + + #### Off-Chain Features + + As traditional external API services based on the prophecy machine are typically used to listen for blockchain events and trigger tasks based on conditions. When these tasks are executed, the execution results are submitted to the blockchain in the form of transactions. While this approach works, it still has some shortcomings in terms of security, scalability, and basic efficiency. This is why Substrate 2.0 has developed important features: off-chain functionality, including Off-Chain Worker, Off-Chain Storage, and Off-Chain Indexing, which help smart contracts gain access to reference data and event data, and API Protocol will use these features to help smart contracts gain access to external data through the API. + + ![img]( https://raw.githubusercontent.com/APIProtocol/research/main/off-chain.png) + + + + #### ink! + + ink! is a domain-specific language based on Rust for writing smart contracts using Rust and compiling them into WASM code, designed for correctness, simplicity and efficiency. API Protoco will integrate the ink! function module to provide efficient contract services and enjoy the convenience of ink! development, so we use as the smart contract language + + #### Frontier + + Frontier is Substrate's Ethernet-compatible layer that allows developers to run unmodified Ethernet DAPPs. the program will allow any Substrate chain to appear as a fully Ethernet chain and host any tool supported by the Ethernet Solidity programming language, including MetaMask, Truffle and any other tool that uses Web3 RPC tools. + + Solidity, the EVM-based smart contract language, is currently the most widely used language by blockchain contract developers, so in order to integrate the developer community and lower the developer threshold, API Protocol will also provide support for Solidity language contracts, and for EVM, we will choose Frontier as the compatible layer. + + #### Substrate Archive + + Substrate Archive is the blockchain indexing engine that indexes all block data, state data and Extrinsic data into the PostgreSQL database. API Protocol requires Substrate Archive when providing event data API services and data retrieval services. + + #### PosgreSQL + + PostgreSQL is a very advanced Object-Relational Database Management System (ORDBMS), the most powerful, feature-rich and advanced free software database system available. Some features are not even available in commercial databases. API Protocol will use this database to store blockchain statistics. + + #### IPFS + + IPFS is a decentralized distributed transport network, and API Protocol will use IPFS as the underlying technical facility for service communication and lookup services. + +#### OpenAPI-Specification + + OAS defines a standard, language-independent RESTful API interface specification that allows both developers and operating systems to view and understand the functionality of a service without access to source code, documentation, or network traffic inspection (both for human and machine learning and reading). When OAS is properly defined, developers can understand and interact with remote services with minimal implementation logic. API Protocoto will implement API gateway interfaces and management functions in accordance with the OpenAPI Specification. + +#### polkadot/apps + + polkadot/apps is a development framework for developing polkadot browser applications, and API Protocol will develop browser-related views and interaction products based on it. + + + + + + ## Ecosystem Fit API Protocol is the Web 3.0 API Economy infrastructure, dedicated to making Web 3.0 APIs easier to find, access and use, to develop Web 3.0 applications more simple and efficient, thus promoting the development of Web 3.0. From 9e53113e1423a5d4c6d0f99ccd2afb58e13d161f Mon Sep 17 00:00:00 2001 From: Alex <61672317+AlexDevAPI@users.noreply.github.com> Date: Wed, 27 Jan 2021 11:23:47 +0800 Subject: [PATCH 27/36] Update API_Protocol.md --- applications/API_Protocol.md | 35 +++++++++++++++++++++++++++++++++++ 1 file changed, 35 insertions(+) diff --git a/applications/API_Protocol.md b/applications/API_Protocol.md index ab7dd2baec6..6b825f865b4 100644 --- a/applications/API_Protocol.md +++ b/applications/API_Protocol.md @@ -219,6 +219,41 @@ API Protocol is a next-generation decentralized API (dAPI) service aggregator th +### Interface Specification + +#### 1. Fast access to Web 3.0 nodes through the Naas service provided by API Protocol. + +``` +- desc: When developers deploy and test their Web3.0 APPs, they need to use third-party services to access the Web3.0 network due to cost issues. + +- params: Project ID, accesstoken, specific request + +- return:Return the corresponding request result + +``` + +#### 2. Access reference data, such as btc prices, through the Reference Data API interface provided by API Protocol. + +``` +- desc: During the operation of smart contracts, sometimes they need off-chain reference data to make corresponding judgments and calculations, so they need to read off-chain data. + +- params: APIDataID + +- return:Return the corresponding data and data validity time + +``` + + +#### 3. Access reference data, such as btc prices, through the Reference Data API interface provided by API Protocol. + +``` +- desc: Smart contracts themselves are event-driven programs, usually driven by users sending transactions, but sometimes smart contracts need to do certain operations when a certain condition is met, so they need external event APIs.. + +- params: API EventID,Conditions for event triggering + +- return:Event ID + +``` From 69c19afa7bad55f1a74fd99eb2999e8536107e16 Mon Sep 17 00:00:00 2001 From: Alex <61672317+AlexDevAPI@users.noreply.github.com> Date: Wed, 27 Jan 2021 11:54:25 +0800 Subject: [PATCH 28/36] Update API_Protocol.md --- applications/API_Protocol.md | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/applications/API_Protocol.md b/applications/API_Protocol.md index 6b825f865b4..8116b834faf 100644 --- a/applications/API_Protocol.md +++ b/applications/API_Protocol.md @@ -258,8 +258,23 @@ API Protocol is a next-generation decentralized API (dAPI) service aggregator th ## Ecosystem Fit + API Protocol is the Web 3.0 API Economy infrastructure, dedicated to making Web 3.0 APIs easier to find, access and use, to develop Web 3.0 applications more simple and efficient, thus promoting the development of Web 3.0. + At the beginning of the project, we will support the following Web 3.0 Ecology projects. + + * Naas Services: Filecoin/IPFS , Ethereum, Polkadot candidate network CC1, Acala,etc。 + + * API Services: Plasm, Moonbeam, etc. + + * SDK Services : Substrate 2.0,Polkadot etc. + + As the Web 3.0 ecosystem grows, we will support more Web 3.0 API services. + + ## The Purpose of this Grant + + The purpose of this grant is to verify the feasibility of the project. Considering the rapid development of Web 3.0, we hope to verify the feasibility of the project through this grant, and cooperate with Polkadot eco-partners to explore the infrastructure of Web 3.0 API economy, so as to better empower the Web 3.0 API economy. + ## Team members From b78b0a1f594fa798a3cd4c22ece82167f932d216 Mon Sep 17 00:00:00 2001 From: Alex <61672317+AlexDevAPI@users.noreply.github.com> Date: Thu, 28 Jan 2021 11:01:14 +0800 Subject: [PATCH 29/36] Update API_Protocol.md --- applications/API_Protocol.md | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/applications/API_Protocol.md b/applications/API_Protocol.md index 8116b834faf..319cae9547b 100644 --- a/applications/API_Protocol.md +++ b/applications/API_Protocol.md @@ -66,7 +66,7 @@ API Protocol is a next-generation decentralized API (dAPI) service aggregator th When using Blockchain as a service, developers can use the node service provided by the API Protocol ecosystem to achieve timely access to the Ethereum, IPFS network, and Polkadot ecological nodes。 - At the time of authorization, the user's project ID and private key registered in the API Protocol platform are used to complete security control, and the user's information is managed centrally at the beginning, and the decentralization will be completed at a later stage by using the Poca ecological user information management project. + At the time of authorization, the user's project ID and private key registered in the API Protocol platform are used to complete security control, and the user's information is managed centrally at the beginning, and the decentralization will be completed at a later stage by using the Polkadot ecological user information management project. ```python Complete security control using Project ID: @@ -83,7 +83,7 @@ API Protocol is a next-generation decentralized API (dAPI) service aggregator th :JSON-RPC OVER HTTPS :JOSN-RPC OVER WebSocket ``` - A request time example: + A request example: ``` $ curl -X POST \ -H "Content-Type: application/json" \ @@ -101,11 +101,11 @@ API Protocol is a next-generation decentralized API (dAPI) service aggregator th API as a Service allows service providers to monetize their API services, and by providing an API marketplace in the API Protocol ecosystem, API service utilizers can receive revenue and incentives in the form of API Protocol native tokens. - The types of APIs are initially divided into the API Protocol system: data services and event services. + The types of APIs are initially divided in the API Protocol system: data services and event services. ###### Data API Service Access Process. - The data API service provider encapsulates its service in the form of microservice, and then registers through API Protocol's decentralized marketplace, and then after the community of API Protoco ecosystem votes to reach a certain number of votes, the API service provider registers a proxy service contract in API Protocol's consensus network. The contract contains a request for data to be processed, and then sends a request event to the API service provider, which receives the request, does the corresponding processing operations, and returns the result to the proxy contract, which sends the data to the service requester. + The data API service provider encapsulates its service in the form of microservice, and then registers through API Protocol's decentralized marketplace, and then after the community of API Protocol ecosystem votes to reach a certain number of votes, the API service provider registers a proxy service contract in API Protocol's consensus network. The contract contains a request for data to be processed, and then sends a request event to the API service provider, which receives the request, does the corresponding processing operations, and returns the result to the proxy contract, which sends the data to the service requester. ![img](https://raw.githubusercontent.com/APIProtocol/research/main/data%20API%20service.png) @@ -177,11 +177,11 @@ API Protocol is a next-generation decentralized API (dAPI) service aggregator th ![img](https://raw.githubusercontent.com/APIProtocol/research/main/substrate.png) - API Protocol is a blockchain project built on top of Substate 2.0. The construction of the underlying ecology of polkadot ecology is crucial to the success of API Protocol, API Protocol network is connected to polkadot ecology as a parachain of polkadot ecology, sharing the security and performance of polkadot ecology. The API Protocol network is connected to Polkadot as a parachain of Polkadot ecosystem, sharing the network security and performance brought by Polkadot's underlying consensus security and Substrate2.0, API Protocol is committed to become the underlying API monetization infrastructure to promote the development of Web 3.0. API Protocol will also join Polkadot's Relay chain at the right time to better serve developers in the Polkadot ecosystem. + API Protocol is a blockchain project built on top of Substate 2.0. The API Protocol network is connected to Polkadot as a parachain of Polkadot ecosystem, sharing the network security and performance brought by Polkadot's underlying consensus security and Substrate2.0, API Protocol is committed to become the underlying API monetization infrastructure to promote the development of Web 3.0. API Protocol will also join Polkadot's Relay chain at the right time to better serve developers in the Polkadot ecosystem. #### Off-Chain Features - As traditional external API services based on the prophecy machine are typically used to listen for blockchain events and trigger tasks based on conditions. When these tasks are executed, the execution results are submitted to the blockchain in the form of transactions. While this approach works, it still has some shortcomings in terms of security, scalability, and basic efficiency. This is why Substrate 2.0 has developed important features: off-chain functionality, including Off-Chain Worker, Off-Chain Storage, and Off-Chain Indexing, which help smart contracts gain access to reference data and event data, and API Protocol will use these features to help smart contracts gain access to external data through the API. + As traditional external API services based on the oracle machine are typically used to listen for blockchain events and trigger tasks based on conditions. When these tasks are executed, the execution results are submitted to the blockchain in the form of transactions. While this approach works, it still has some shortcomings in terms of security, scalability, and basic efficiency. This is why Substrate 2.0 has developed important features: off-chain functionality, including Off-Chain Worker, Off-Chain Storage, and Off-Chain Indexing, which help smart contracts gain access to reference data and event data, and API Protocol will use these features to help smart contracts gain access to external data through the API. ![img]( https://raw.githubusercontent.com/APIProtocol/research/main/off-chain.png) From cab767b3add6eace09863b728dd158d861008e37 Mon Sep 17 00:00:00 2001 From: Alex <61672317+AlexDevAPI@users.noreply.github.com> Date: Sat, 30 Jan 2021 19:16:48 +0800 Subject: [PATCH 30/36] Update API_Protocol.md --- applications/API_Protocol.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/applications/API_Protocol.md b/applications/API_Protocol.md index 319cae9547b..76d6c80a171 100644 --- a/applications/API_Protocol.md +++ b/applications/API_Protocol.md @@ -278,7 +278,7 @@ API Protocol is a next-generation decentralized API (dAPI) service aggregator th ## Team members -* haijun - CTO/Project Lead +* haijun - CTO * Alex - Developer ## Contact From 645cbc2e05795b41783ef1c68c9cd26182517f98 Mon Sep 17 00:00:00 2001 From: Alex <61672317+AlexDevAPI@users.noreply.github.com> Date: Wed, 24 Feb 2021 20:44:19 +0800 Subject: [PATCH 31/36] Update API_Protocol.md --- applications/API_Protocol.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/applications/API_Protocol.md b/applications/API_Protocol.md index 76d6c80a171..cdb6a8a4dc0 100644 --- a/applications/API_Protocol.md +++ b/applications/API_Protocol.md @@ -17,7 +17,7 @@ API Protocol is a next-generation decentralized API (dAPI) service aggregator th API Protocol will build a cross-chain decentralized API service management platform on Polkdot based on the Substrate framework to provide decentralized API infrastructure for blockchain developers and improve the efficiency of developers building Dapp. - ![img](https://raw.githubusercontent.com/APIProtocol/research/main/API%20Protocol.png) + ## Team Interest @@ -316,7 +316,7 @@ In this milestone, we will verify features with limited users and launch the tes * **Estimated Duration:** 2 months * **Full-time Equivalent (FTE)**: 3 -* **Costs:** 0.5 BTC +* **Costs:** 10000 DAI | **Number** | **Deliverable** | **Specification** | | ---------- | ---------------------------------------- | ------------------------------------------------------------ | From 7eb5df4a771e2e070a79e80bfe308a4b8b478aab Mon Sep 17 00:00:00 2001 From: Alex <61672317+AlexDevAPI@users.noreply.github.com> Date: Wed, 24 Feb 2021 20:45:04 +0800 Subject: [PATCH 32/36] Update API_Protocol.md --- applications/API_Protocol.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/applications/API_Protocol.md b/applications/API_Protocol.md index cdb6a8a4dc0..c73eb1ada11 100644 --- a/applications/API_Protocol.md +++ b/applications/API_Protocol.md @@ -316,7 +316,7 @@ In this milestone, we will verify features with limited users and launch the tes * **Estimated Duration:** 2 months * **Full-time Equivalent (FTE)**: 3 -* **Costs:** 10000 DAI +* **Costs:** 8000 DAI | **Number** | **Deliverable** | **Specification** | | ---------- | ---------------------------------------- | ------------------------------------------------------------ | From 1f8498962d497e78822204f342f6aef2dad34fc1 Mon Sep 17 00:00:00 2001 From: Alex <61672317+AlexDevAPI@users.noreply.github.com> Date: Wed, 24 Feb 2021 22:40:43 +0800 Subject: [PATCH 33/36] Update API_Protocol.md --- applications/API_Protocol.md | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/applications/API_Protocol.md b/applications/API_Protocol.md index c73eb1ada11..d61d9508b11 100644 --- a/applications/API_Protocol.md +++ b/applications/API_Protocol.md @@ -2,7 +2,7 @@ * **Project Name:** API Protocol * **Proposer:** [API Protocol](https://github.com/APIProtocol) -* **Payment Address:** 36wHH7KseuqtyTLMCB8dXKWm8VKdPRR8Vs +* **Payment Address:** 0xe871829Bd2367332316bDef9a315CDad906A3282 ## Project Overview :page_facing_up: @@ -308,7 +308,7 @@ The project leader, Haijun, is a serial entrepreneur who has experienced the ent * **Total Estimated Duration:** 2 months * **Full-time equivalent (FTE):** 3 -* **Total Costs:** 0.5 BTC +* **Total Costs:** 8000 DAI #### Milestone 1 — Verify Production of Concepts (POC) and Implement Substrate Modules From 89e470fa5006f8684eb89c6a01ed170095a2b87e Mon Sep 17 00:00:00 2001 From: Alex <61672317+AlexDevAPI@users.noreply.github.com> Date: Fri, 5 Mar 2021 11:16:53 +0800 Subject: [PATCH 34/36] Update API_Protocol.md --- applications/API_Protocol.md | 55 +++++++++++++++++++++++++++++++++++- 1 file changed, 54 insertions(+), 1 deletion(-) diff --git a/applications/API_Protocol.md b/applications/API_Protocol.md index d61d9508b11..1aa44b60457 100644 --- a/applications/API_Protocol.md +++ b/applications/API_Protocol.md @@ -273,7 +273,60 @@ API Protocol is a next-generation decentralized API (dAPI) service aggregator th ## The Purpose of this Grant - The purpose of this grant is to verify the feasibility of the project. Considering the rapid development of Web 3.0, we hope to verify the feasibility of the project through this grant, and cooperate with Polkadot eco-partners to explore the infrastructure of Web 3.0 API economy, so as to better empower the Web 3.0 API economy. + API Protocol is a relatively large engineering project, and at the beginning of the project we hope to receive funding mainly to complete the feasibility verification of a decentralised service registration and discovery mechanism based on a p2p network. + + + Under normal circumstances, when we need to access an API service we need to know the service instance and port. If the service instance address and port are fixed, we can directly put its configuration file in a file and use it, but in decentralized API service invocation, the corresponding IP address and port can only be obtained after the API service instance is actually deployed, and the API The service caller obtains the address and port of the API service instance through the decentralized API service discovery mechanism. Decentralised API service discovery is simply the process of finding the address and port of the instance providing the API service through the decentralised API service discovery mechanism. + + + A standard API service discovery architecture has three main components: an API service registry, an API service invoker, and an API service provider, as shown in the diagram. + + + ![img]( https://raw.githubusercontent.com/APIProtocol/research/main/API%20discovery.png) + + + + In the API Protocol, the process of using an API service consists of the following steps: + + + #### 1 API service registration. + + + The API service provider runs the API Protocol Node and the API Service Provider Node, then registers the service via a decentralised marketplace and broadcasts the registration information to a P2P network of API Protocol Node nodes. + + + #### 2 API Service Discovery. + + + The API service requester subscribes to the API service of the decentralised network and then gets information about the node IP and port associated with the API service to follow. + + #### 3 API service requests. + + + The API service requester gets the IP and port information related to the service provider through the decentralised API service registration network and then requests the service + + +### The software architecture is shown in the diagram: + + +#### API Node: + + +![img](https://raw.githubusercontent.com/APIProtocol/research/main/API%20Protocol%20Node.png) + + +#### API Service registration and call + + +![img](https://raw.githubusercontent.com/APIProtocol/research/main/API%20Service%20registration%20and%20call%20(1).png) + + + +### Purpose of the grant. + +We wanted to first implement a pallet based on Substrate as a registration and discovery mechanism for web services based on P2P networks. + + ## Team members From 8f6abe0aaca38b76abe8400f5277d4b938d983d8 Mon Sep 17 00:00:00 2001 From: Alex <61672317+AlexDevAPI@users.noreply.github.com> Date: Fri, 5 Mar 2021 18:47:34 +0800 Subject: [PATCH 35/36] Update API_Protocol.md --- applications/API_Protocol.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/applications/API_Protocol.md b/applications/API_Protocol.md index 1aa44b60457..567da4d13f8 100644 --- a/applications/API_Protocol.md +++ b/applications/API_Protocol.md @@ -361,7 +361,7 @@ The project leader, Haijun, is a serial entrepreneur who has experienced the ent * **Total Estimated Duration:** 2 months * **Full-time equivalent (FTE):** 3 -* **Total Costs:** 8000 DAI +* **Total Costs:** 4000 DAI #### Milestone 1 — Verify Production of Concepts (POC) and Implement Substrate Modules From 24a38483ea69d308ddc999a787810c98f31665af Mon Sep 17 00:00:00 2001 From: Alex <61672317+AlexDevAPI@users.noreply.github.com> Date: Fri, 5 Mar 2021 18:49:17 +0800 Subject: [PATCH 36/36] Update API_Protocol.md --- applications/API_Protocol.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/applications/API_Protocol.md b/applications/API_Protocol.md index 567da4d13f8..1aa44b60457 100644 --- a/applications/API_Protocol.md +++ b/applications/API_Protocol.md @@ -361,7 +361,7 @@ The project leader, Haijun, is a serial entrepreneur who has experienced the ent * **Total Estimated Duration:** 2 months * **Full-time equivalent (FTE):** 3 -* **Total Costs:** 4000 DAI +* **Total Costs:** 8000 DAI #### Milestone 1 — Verify Production of Concepts (POC) and Implement Substrate Modules