Giter Club home page Giter Club logo

aqarnftoken's Introduction

Udacity - Blockchain Developer Nanodegree

AQAR Real Estate Exchange

AQAR Token is A Real Estate Exchange contract.

Install

This repository contains Smart Contract code in Solidity (using Truffle), tests (also using Truffle)

To install, download or clone the repo, then:

npm install

In directory eth-project/
truffle compile

Tests

To run truffle tests: In directory eth-project/

For all tests:
truffle test

For single file tests:
truffle test test/TestERC721Mintable.js
truffle test test/TestSquareVerifier.js
truffle test test/TestSolnSquareVerifier.js

Addresses and Links

OpenSea Marketplace Storefront link's: Aqar Real Estate Exchange

Token:

Contract address: 0x1b031B79727d8Dad0bc55D0d97082d47a5e94bEA
Contract abi's: /eth-project/build/contracts/SolnSquareVerifier.json

Verifier:

Contract address: 0xC0eacA14c6D3dD8FED326eBcf99A0C557789EB3d
Contract abi's: /eth-project/build/contracts/Verifier.json

ZoKrates (generate zk-Snarks Validator)

Step 1: Run ZoKrates in Docker

docker run -v <path to your project folder>:/home/zokrates/code -ti zokrates/zokrates:0.3.0 /bin/bash

Change directory

cd code/zokrates/code/square/

Step 2: Compile the program written in ZoKrates DSL

~/zokrates compile -i square.code

Step 3: Generate the Trusted Setup

~/zokrates setup

Step 4: Compute Witness

~/zokrates compute-witness -a 3 9

Step 5: Generate Proof

~/zokrates generate-proof

Step 6: Export Verifier

~/zokrates export-verifier

Deploy to Rinkeby

Update <your infura key> in /eth-project/truffle-config.js before migrate to Rinkeby Network. And create a .secret file in /eth-project/ with your mnemonic.

Start deployment

truffle migrate --network rinkeby

Minting tokens Process

update <your infura key> and <your mnemonic words> in /eth-project/scripts/secret.json before start minting,
In directory /eth-project/scripts, run:

Submit new solution for tokenId

node submit-sol.js <proof.json file location> <tokenId>

Mint new token for tokenId

node mint.js <tokenId>

Token Metadata

Aqar metadata api project: aqarnft-meadata using this startup code

Project Resources

ZoKrates Improvements

squares as input to ZoKrates is not directly related to the real estate property use case. It is just meant to show how the process can be done programmatically. There might be other data that can be input to ZoKrates to verify land titles.

aqarnftoken's People

Contributors

khalidfsh avatar

Stargazers

Michael Demarais avatar howekuo avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.