import fetch from 'node-fetch'; | |
import { smock } from '@defi-wonderland/smock'; | |
async function deployMockContractFromAddress(contractAddress: string, etherscanKey: string) { | |
const abi = await fetch(`https://api.etherscan.io/api?module=contract&action=getabi&address=${contractAddress}&apikey=${etherscanKey}`) | |
.then(response => response.json()) | |
.then(data => JSON.parse(data['result'])); | |
return smock.fake(abi, {address: contractAddress}); | |
} |
I am attesting that this GitHub handle anonymoussprocket is linked to the Tezos account tz1eU1NCk7U6sNxDKos7CJMM7P97bW3wyGB1 for tzprofiles | |
sig:edsigtwwTgkiJZuqnGFDgsHsfV1Ejt8K2WXhD6Nei8WKgHr8CnbHrvcqJoUpT1LwRgzHWtPzqxQZ5itS4LHTC3KNX7iyNbhSCq1 |
This is the full code for an simplistic dApp on Tezos. It is presented as part of the Cryptonomic dApp development curriculum with ConseilJS & SmartPy. The relevant discussion of this code is in Part 6.
To get access to Tezos & Conseil infrastructure signup for an account at Nautilus Cloud. The missing parameters in the code below will come from there.
The purpose of this script is to demonstrate common operations on an FA1.2 token on the Tezos platform using the ConseilJS library and Nautilus Cloud infrastructure.
<html> | |
<head> | |
<style> | |
#hen-embed { | |
border: 1px solid black; | |
height: 800px; | |
width: 500px; | |
} | |
</style> | |
<script> |
Single script to test common Tezos user workflows. Additionally this sample illustrates the use of ConseilJS for interactions with a Tezos blockchain node.
This tutorial requires nodejs 12.21+ & npm. It's highly recommended to install those via nvm.
This is a companion code sample to go with the Tezos is now an asset tokenization platform article on Medium from The Cryptonomic Aperiodical. As always, to test this code get infrastructure access from Nautilus Cloud.
The code included here demonstrates token deployment and management workflows. It does not have an example for burn()
, but that is also available in the API.
These materials are meant to accompany the live workshops by Cryptonomic for blockchain and smart contract development. This version focuses on the Tezos chain and smart contract development with SmartPy.
The code in this workship is written Typescript. We will use the ConseilJS library to interact with the Tezos Alphanet chain. It is possible to use the ConseilJS npm package with nodejs directly with JavaScript. There is also a minified deployment for use on websites. The smart contract section follows the Smart Contract Development Syllabus and uses SmartPy. The contracts covered in the syllabus are also available on Github. While this introduction coveres much of the Tezos user workflows, some things are out of scope. Please refer to the full [ConseilJS Documentation](https://cryptonomic.github.io/