Tools to help teams develop smart contracts on the Cardano blockchain

Overview

toolkit-for-cardano

toolkit-for-cardano simplifies the development of Cardano smart contracts by providing teams with frequently needed tasks:

  • Build Transactions
  • Sign Transactions
  • Submit Transactions
  • Mint Tokens
  • Create Wallet
  • Fund Wallet
  • Transfer Funds
  • Calculate Fees

toolkit-for-cardano is not intended as a replacement for a wallet, but rather as a development tool to allow teams to make progress with minimal wallet integration overhead.

Prerequisites

Before launching toolkit-for-cardano, you'll need to identify an address that will be considered the Treasury™ address. This address will be used to fund all other addresses. Make sure that (a) the UTXO in this address only contain ADA and no other tokens and (b) each UTXO has a large quantity of ADA as the tool currently only uses a single TxIn for funding.

If you've just configured your private testnet and would like create a treasury address and then fund it, you can use the scripts provided:

scripts/generate-address.sh treasury                       # generates files including treasury.addr
TESTNET_MAGIC=31415 scripts/fund-treasury.sh treasury.addr # sends the initial funds to the treasury.addr address
  • ensure CARDANO_NODE_SOCKET_PATH is set
  • ensure CARDANO_NODE_HOME is set to your testnet root dir if other than ${HOME}/alonzo-testnet

Quick Start

  1. clone this repository
  2. edit docker-compose.yml adjust /home/ubuntu/alonzo-testnet to your testnet root
  3. ensure that your treasury keys are in ./addresses/treasury.*
  4. ensure that your treasury address is funded
  5. docker-compose up -d

Done!

This will launch:

  • cardano-db-sync-extended
  • postgres on port 5432
  • toolkit-for-cardano on port 3200

Important

To enable cardano-db-sync-extended on a private testnet, we used an unmerged branch of input-output-hk/cardano-db-sync, kderme/fix-fork-at-0, that resolves an issue working against private testnets. https://github.com/input-output-hk/cardano-db-sync/pull/766

It does appear that this branch still has issues. Specifically, if you need to restart the cardano-db-sync-extended, you will need to delete the docker volumes before restarting as there appears to be some issue with continuing.

docker-compose rm -fv && docker volume rm $(docker volume ls | awk '{print $2}' | grep -v VOLUME)
  • this may grab other unused volumes

Building

docker image

docker build -t sundaeswap/toolkit-for-cardano .

self contained cli

Assuming go 1.16 or better and node 1.14 or better are installed

(cd ui && yarn install && yarn local:build)
GOOS=linux go build

Change GOOS to match your target OS e.g. darwin, linux, windows, etc

Concepts

Minting

Minted tokens are in the namespace of the wallet that generated them. That wallet can mint as many or few tokens as it wishes. However, tokens minted by one wallet are not fungible with tokens minted by another wallet.

Wallets

toolkit-for-cardano generates only the loosest concept of a wallet. It makes no attempt at securing the wallet as it is designed for development purposes only.

Because the wallet is just a string, it simplifies the interaction with the frontend as it can put in a cookie, local storage, whatever is convenient.

Treasury

The treasury wallet is any wallet with sufficient ADA to fund other wallets.
Most often, this will be the wallet funded via the faucet. toolkit-for-cardano will need access to the wallet address as well as the signing key (.skey)

Comments
  • Why is your twitter pointing to a scammer telegram group trying to steal your seed phrase ?

    Why is your twitter pointing to a scammer telegram group trying to steal your seed phrase ?

    Sundaeswap's website https://sundaeswap.finance links to their official twitter account https://twitter.com/SundaeSwap which in turn links to their official telegram group https://t.co/tNhjtAJSYx. This telegram group is a scam group - I asked for assistance and they asked me for my seed phrase. Can somebody please explain what is going on ?

    opened by petarbelokonski 3
  • Pi/register stake

    Pi/register stake

    Does a couple of things:

    • Adds a script to register the stake pool on startup
    • Generates the delegation certificate when creating a wallet
    • Adds the ability to register a wallets stake address
    • Adds the ability to delegate an address to the stake pool

    First attempt at go, so feel free to provide feedback or make commits to the branch with suggested cleanup!

    opened by Quantumplation 0
  • UI Improvements

    UI Improvements

    Adding some more polish to frontend components

    • [x] Inputs strict for numbers + basic validation checks for queries
    • [x] Failed queries bubble up errors + make success/fail toasts clearer
    • [x] Components mounting/un-mounting state updates
    • [x] Fixed some wallet balance/utxo list scroll issues
    • [x] Wallet actions as <form/> elements to capture enter key presses
    opened by youmustfight 0
  • Toolkit UI Pt2

    Toolkit UI Pt2

    Adding some more pizazz.

    • [x] Tip indicator showing era/block
    • [x] Query for existing wallets and allow selection of those
    • [x] Nicer header/footer details, repo links, intro explainer text
    • [x] UTXOs viewer on wallet

    | Disconnected | Connected | | --- | --- | | image | image |

    opened by youmustfight 0
  • Simple UI

    Simple UI

    First pass at a UI for creating/connecting a wallet and then depositing ADA or minting tokens for it. Could still be fixed up for mobile, some meta properties, and to just be more hype

    | Disconnected | Connected | | --- | --- | | image | image |

    opened by youmustfight 0
  • Quickstart tutorials on youtube

    Quickstart tutorials on youtube

    Any chance of a few quickstart tutorials and templates to get developers upto speed who are coming from a traditional background and may have never programmed for the blockchain before?

    opened by mrgithub 0
Owner
SundaeSwap Finance
Decentralized trading protocol on Cardano.
SundaeSwap Finance
Go module for the Cardano Blockchain

cardano-go cardano-go is both a library for creating go applicactions that interact with the Cardano Blockchain as well as a CLI to manage Cardano Wal

Alonso Villegas 37 Nov 22, 2022
Running chaincode in development mode: Smart contract developers that want to iteratively develop and test their chaincode packages without the overhead of the smart contract lifecycle process for every update.

Fabric DEVMODE - Nano bash 1 ORG + 1 PEER + 1 ORDERER Based on fabric-samples/test-network-nano-bash, but using devmode fabric peer Prereqs Follow the

Kmilo Denis González 3 May 14, 2022
Arbitrum is a Layer 2 cryptocurrency platform that makes smart contracts scalable, fast, and private.

Arbitrum is a Layer 2 cryptocurrency platform that makes smart contracts scalable, fast, and private. Arbitrum interoperates closely with Ethereum, so Ethereum developers can easily cross-compile their contracts to run on Arbitrum. Arbitrum achieves these goals through a unique combination of incentives, network protocol design, and virtual machine architecture.

Offchain Labs 977 Nov 26, 2022
Akroma GO client - Akroma is an EVM based application development platform (smart-contracts).

Akroma Akroma is an EVM based application development platform (smart-contracts). Akroma will utilize a Masternode system, and build out an Oracle pla

null 3 Jul 24, 2022
OpenZeppelin Contracts is a library for secure smart contract development.

A library for secure smart contract development. Build on a solid foundation of community-vetted code. Implementations of standards like ERC20 and ERC

OpenZeppelin 20.6k Nov 22, 2022
Accompanying repository for the "Build Ethereum From Scratch - Smart Contracts and More" course by David Katz

Build Ethereum From Scratch - Smart Contracts and More This repository accompanies the "Build Ethereum From Scratch - Smart Contracts and More" course

David Katz 44 Oct 20, 2022
Troon-NFT-Contract is deployed on Flow Blockchain, which is a white-label smart-contract for NFTs with an addition layer of Brand, Schema and Template

Overview Summary of NFTContract NFTContract is a Non Fungible Token (NFT) standard for Flow blockchain. It offers a powerful set while keeping unneces

null 0 Jan 4, 2022
Blockchain-go - A repository that houses a blockchain implemented in Go

blockchain-go This is a repository that houses a blockchain implemented in Go. F

Onyeka 1 May 1, 2022
Contracts for the versus-flow.art project

Versus Flow Auction Contract This is a git repo for the cadence contrats for [email protected] Follow the guide below to set it up and test locally in the

Versus@Flow 12 Jul 19, 2022
C4udit - Static analyzer for solidity contracts based on regexs specifically crafted for Code4Rena contests

c4udit Introduction c4udit is a static analyzer for solidity contracts based on

byterocket 122 Nov 22, 2022
An interoperable smart contract hub

Juno An interoperable smart contract hub which automatically executes, controls or documents a procedure of relevant events and actions according to t

Juno 249 Dec 1, 2022
The bare metal Go smart card

Authors Andrea Barisani [email protected] | [email protected] Introduction The GoKey application implements a USB smartcard in pure Go

F-Secure Foundry 141 Nov 4, 2022
Yet another Binance Smart Chain client based on TrustFi Network

TrustFi Smart Chain The goal of TrustFi Smart Chain is to bring programmability and interoperability to Binance Chain. In order to embrace the existin

TrustFi Network 19 Mar 27, 2021
The Fabric Smart Client is a new Fabric Client that lets you focus on the business processes and simplifies the development of Fabric-based distributed application.

Fabric Smart Client The Fabric Smart Client (FSC, for short) is a new Fabric client-side component whose objective is twofold. FSC aims to simplify th

null 42 Nov 15, 2022
A smart contract development toolchain for Go

ethgen - A smart contract development toolchain for Go A simple yet powerful toolchain for Go based smart contract development Compile solidity contra

Tally 34 Sep 14, 2022
A Binance Smart Chain client based on the go-ethereum fork

A Binance Smart Chain client based on the go-ethereum fork

null 1.9k Nov 29, 2022
Golang libraries for generating QR codes for Smart Health Cards representing COVID-19 Immunizations

go-smarthealthcards Golang libraries for generating QR codes for Smart Health Cards representing COVID-19 Immunizations. Usage Individual Libraries Yo

Amit Gupta 0 Dec 5, 2021
Automation for faucet-smart with some hacks 😈

give-me-bnb Automation for https://testnet.binance.org/faucet-smart with some hacks ?? Usage $ give-me-bnb -help Usage of give-me-bnb: -proxy string

Nikita Korshunov 46 Nov 19, 2022
A smart Hub for holding server stat

Stat Hub A smart Hub for holding server stat 中文说明 | English README Overview Stat Hub is a service for collecting and displaying servers stat. Stat Hub

follow 0 Aug 29, 2020