Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/wormhole-foundation/example-liquidity-layer
https://github.com/wormhole-foundation/example-liquidity-layer
Last synced: about 2 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/wormhole-foundation/example-liquidity-layer
- Owner: wormhole-foundation
- License: apache-2.0
- Created: 2023-09-26T14:54:14.000Z (about 1 year ago)
- Default Branch: main
- Last Pushed: 2024-10-31T19:56:08.000Z (about 2 months ago)
- Last Synced: 2024-11-05T06:42:56.545Z (about 2 months ago)
- Language: TypeScript
- Size: 3.04 MB
- Stars: 13
- Watchers: 16
- Forks: 12
- Open Issues: 28
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# example-liquidity-layer
The Example Liquidity Layer utilizes the [Wormhole Circle Integration]() contract to faciliate cross-chain transfers of USDC (along with arbitrary messages) to custom smart contracts on any CCTP-enabled blockchain.
## Get Started
Clone the repo using the following command to make sure that all necessary submodules are installed:
```
git clone [email protected]:wormhole-foundation/example-liquidity-layer.git --recurse-submodules
```## Prerequisites
### EVM
Install [Foundry tools](https://book.getfoundry.sh/getting-started/installation), which include `forge`, `anvil` and `cast` CLI tools.
## Build, Test and Deploy Smart Contracts
Each directory represents Wormhole integrations for specific blockchain networks. Please navigate to a network subdirectory to see more details (see the relevant README.md) on building, testing and deploying the smart contracts.
[Wormhole Circle Integration]: https://github.com/wormhole-foundation/wormhole-circle-integration/blob/main/DESIGN.md
### Typescript SDK
To use the Typescript SDK, at the root of this repository, run:
```sh
npm ci && npm run build && npm run pack
```Which will produce a `.tgz` file that can be installed using npm or any other package manager like:
```sh
npm install /path/to/example-liquidity-layer/wormhole-foundation-example-liquidity-layer-solana-0.0.1.tgz
```Once installed, it can be used like any other package:
```ts
// ...
import * as tokenRouterSdk from "@wormhole-foundation/example-liquidity-layer-solana/tokenRouter";
import {
LiquidityLayerDeposit,
LiquidityLayerMessage,
} from "@wormhole-foundation/example-liquidity-layer-solana/common";
import { PreparedOrder } from "@wormhole-foundation/example-liquidity-layer-solana/tokenRouter/state";
// ...
```