0

I need to handle different wallets and payments on Ethereum from different internal services, so ideally instead of adding built-in capabilities to handle wallets and transfers on each service, I want to have that in one service, and the rest of the services consuming that service to make the transfers.

So, what open source projects are out there that allow to:

  1. Deploy it as a HTTP server, preferable with a REST API.
  2. The server stores in some way the private key/s of the wallets. Then allows to make transfer thorugh API calls, were the client is validated with some sort of authentication like a header token, instead of clients providing the private key. If it support multi-signing keys, better, so no party included the server has all the credentials to make the transfer, an clients have to provide one of the keys but not all of them to make it.
  3. It allows to connect with different networks by configuration, like mainnet, or a testnet like Goerli, or even to a local ethereum network launched for testing.

And, but not mandatory:

  1. Allow basic settings like maybe setup limits on transfers, call a webhook or send a message to a queue if a transaction is made, etc.
  2. Allow to get useful information about the wallets, like the balance, transactions history, etc.
  3. Handle other coins / tokens than ETH.

There are SaaS products out there that provide services like these, but they are expensive, and proved to be unreliable when issues arises based on my experience, and also you have to trust the private keys to them, and I don't want that.

1 Answer 1

2

I'm working on a CLI wallet https://0xweb.org, also this is a contract package manager for NodeJS. Though this is a side project, which we decided to open source, it is already completely functional. Underneath we use https://github.com/0xweb-org/dequanto library for the blockchain-related staff.

It doesn't cover all of your needs, it is maybe more low level, but it extends web3js and ethers with lots of things in the direction you've described, so maybe you'll find smth. useful there.

  1. It doesn't provide an HTTP layer. It covers only Blockchain, Accounts, Tokens, and Smart-Contracts topics. You can use Next.js, Express, or any other nodejs restful library to implement the endpoints of your need.

  2. We encrypt the account's storage with the machine KEY and the application key provided at the application start, via environment or an argument. You could easily add the per private-key encryption. In your endpoint, before storing the account, you can encrypt the key with the user's password, and when executing transactions, you must then decrypt the private key.

  3. There are some easy-to-use clients for various chains, the clients support blockchain node pools, so when one of the nodes is out of sync, or offline, the application will still work. You have to add the list of node URLs to the yml configuration. Retries and other things are also supported.

  4. There is a class for transactions https://github.com/0xweb-org/dequanto/blob/master/src/tokens/TokenTransferService.ts - doesn't have webhooks or limits, but again - those features you can add quite easy.

  5. There is an Indexer Class, you can walk through the blocks and transactions to index things per your need, or also Etherscan API is implemented, so you can get all transactions per address from there.

  6. We ship a JSON with all known tokens from 1inch, sushiswap, coinmarketcap. And with the TokenService you'll get tokens data by symbol or address.

There are lots of other things, the overview might be at first look not so obvious, I'm trying to extract things from our internal projects and make them more structured and organized.

For now, the main goal of the 0xweb is to provide an easy way to install (generate) smart contract client classes in TypeScript for validated contracts.

1
  • Your project seems a good option but yes not exactly what I'm looking for, but in case there is nothing out there, can be the starting point to build what I need. Commented May 5, 2022 at 13:57

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.