Please describe your proposed solution.
Cardano Submit API is used to allow submission of a transaction on Cardano to a Cardano node using HTTP, without understanding the underlying Cardano protocols. This is useful in the creation of everything from DEXes and dApps to light wallets.
The Cardano ecosystem has a strong preference for Haskell as a development language for its low level software implementations. This use of functional programming and provably correct code is great for a blockchain. However, most applications running on a blockchain are simply clients to the blockchain and inherit much of the security from the chain. Creating higher level applications in multiple languages increases the ecosystem diversity and attracts developers from different talent backgrounds.
Our team will create a Golang implementation of the Cardano Submit API version 3.1.0 as specified in the Swagger document published by IOHK. This implementation will utilize common Golang project structure and layout and will be written in a way which is familiar to Golang developers while introducing the developer to Cardano. The code, comments, and documentation will be written to appeal to developers familiar with Golang programming and should require minimal prior understanding of Cardano. This code will incorporate the libada library created by Bitrue as well as the Golang implementation of Ouroboros network library created by CloudStruct.
Please describe how your proposed solution will address the Challenge that you have submitted it in.
Golang is an extremely popular programming language. GitHub Language Statistics from GitHut 2.0 (code: <https://github.com/madnight/githut>) show that in Q4 2021, the number of pull requests on Golang repositories grew 8.161% and Haskell repositories grew 0.180% (source: https://madnight.github.io/githut/#/pull_requests/2021/4/Go,Haskell) while the number of repository stars on Golang repositories grew 11.763% and Haskell repositories grew 0.178% (source: <https://madnight.github.io/githut/#/stars/2021/4/Go,Haskell>). The Golang developer community is approximately 4x the size of the Haskell developer community, based on the number of Github repos with code for each. Since it’s hard to judge community size, we’re using these numbers as a proxy. We hope to bridge the gap between Golang developers and the Cardano blockchain and attract more developers to Cardano.
Creation of an alternative implementation of an existing service while utilizing existing library components from the ecosystem provides a larger surface area for developer integrations for off-chain code necessary for transaction submission in complex scenarios such as lending and DeFi. Use of a more popular programming language and integration with existing libraries will provide this. Along with this, we will provide deeper support for alternative operating systems, such as FreeBSD, and alternative architectures, such as ARM.
What are the main risks that could prevent you from delivering the project successfully and please explain how you will mitigate each risk?
The main challenge will be creating robustness in the error handling around the various conditions outside the happy path. This risk will be mitigated by performing additional validation in the service before submitting to a Cardano node and thorough testing.
Another risk would be changes in the underlying transaction format introducing incompatibility with the payload decoding, coming in Vasil or future hard fork combinator events. We propose to mitigate this risks through battle testing the software on testnet and mainnet, utilizing partnerships and replacing our own Submit API services.