kuber
kuber copied to clipboard
Explore ways to setup a client library for kuber-hydra
Scope of this Ticket:
- Determine external library dependencies required.
- Determine changes required in
kuber-clientandlibcardanopacakages. - Determine how to integrate with both browser and serverside NodeJs in single package
To Do:
- generate private key from wallet seed phrases and use it to run the hydra node.
- This is needed for the browser wallet signature to be validated in hydra
Changes in kuber-Client
- Add the hydra comnand functions (init, abort, close, etc.)
- Add function to commit and de-commit UTxOs
- Add function to sign and submit hydra transaction
Changes in libcardano
- TBD
External Library Dependency
- This will be discovered as the project is being built
Update
- Added hydra lifecycle endpoints in client
- WIP hydra wallet
Update
Required features of cip30 are added to libcardano. Currently implementing hydra features in kuber-client package.
What has been done in Libcardano
- [x] created a module 'libcardano-wallet' in the libcardano repo
- [x] 2 interfaces. QueryAPIProvider and SubmitAPIProvider
- [x] a CIP30 wallet class with wallet features. The constructor of this class requires query api provider and submit api provider instances
- [x] PR: https://github.com/cardanoapi/libcardano/pull/15
What has been done in kuber-client-js
- [x] class KuberHydraService implements SubmitAPIProvider, QueryAPIProvider (makes calls to api provided by kuber-hydra-server)
- [x] class KuberNodeService implements SubmitAPIProvider, QueryAPIProvider (makes calls to api provided by kuber-server)
- [x] Simple implementation of hydra wallet (CIP30Wallet class imported from libcardano)
-
export class HydraWallet extends CIP30Wallet { constructor(hydraService: KuberHydraService) { super(hydraService, hydraService); } }
-
- [x] WIP test and setup instructions
Client library is ready and published
- https://www.npmjs.com/package/kuber-client/v/3.3.0