Skip to content

Commit

Permalink
Merge pull request #60 from BirthdayResearch/cuong/edit-readme
Browse files Browse the repository at this point in the history
chore: Edit readme and rename files
  • Loading branch information
cuongquangnam authored Oct 9, 2023
2 parents 7f2832c + 09d3c2c commit a3df62a
Show file tree
Hide file tree
Showing 4 changed files with 32 additions and 0 deletions.
32 changes: 32 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,35 @@
# DeFiChain <-> DeFiMetaChain State Relayer

A project comprising of smart contracts and scripts to port certain information from DeFiChain to DeFiMetaChain

### Directory Structure

```
├── bot // <-- Logic for the bot + integration test
├── contracts // <- The smart contracts + example solidity usage
├── scripts // <- Deployment scripts + gas estimation
├── tests // <- Smart contract tests
├── containers // <- Containers for integration tests
```

### How to use the package to update information on DeFiMetaChain

```typescript
import {handler} from "@waveshq/state-relayer-bot";
import { EnvironmentNetwork } from "@waveshq/walletkit-core"

handler({
testGasCost: false,
urlNetwork: /* Defi Meta Chain RPC Provider URL */,
envNetwork: EnvironmentNetwork.MainNet,
contractAddress: /* YOUR STATE RELAYER PROXY ADDRESS */,
signer: /* signer object */,
gasUpdateDEX: /* gas limit for dex update transaction */,
gasUpdateMaster: /* gas limit for master node update transaction */,
gasUpdateVault: /* gas limit for vault update transaction */
})
```

### Instruction to consume the smart contract information

Examples on how to consume the information exposed by the smart contract is showcased via [this folder](./contracts/example)
File renamed without changes.
File renamed without changes.
File renamed without changes.

0 comments on commit a3df62a

Please sign in to comment.