feat: add run swap

This commit is contained in:
Kyle Fang
2023-03-09 13:25:15 +08:00
parent f657c2ad53
commit ba105c6422
28 changed files with 3297 additions and 18 deletions

25
scripts/gen-contract.ts Normal file
View File

@@ -0,0 +1,25 @@
import { generateContracts } from "clarity-codegen/lib/generate"
import * as path from "path"
const API_HOST = "https://stacks-node-api.alexlab.co"
const CONTRACT_DEPLOYER = "SP3K8BC0PPEVCV7NZ6QSRWPQ2JE9E5B6N3PA0KBR9"
const contracts = [
"swap-helper-v1-02",
"swap-helper-v1-03",
"amm-swap-pool",
"token-amm-swap-pool",
"swap-helper-bridged",
]
;(async function main() {
await generateContracts(
API_HOST,
CONTRACT_DEPLOYER,
contracts,
path.resolve(__dirname, "../src/generated/smartContract/"),
"Alex",
"../smartContractHelpers/codegenImport",
)
})().catch(console.error)