Coder Social home page Coder Social logo

moteesh-in2tive / affondra Goto Github PK

View Code? Open in Web Editor NEW

This project forked from eg-easy/affondra

0.0 1.0 0.0 2.66 MB

P2P NFT trading market based on cosmos-sdk

Home Page: https://affondra.web.app/

License: MIT License

Shell 0.47% Makefile 0.49% Go 51.00% JavaScript 11.75% HTML 2.76% Vue 33.54%

affondra's Introduction

Affondra

version Go Report Card

Affondra is a blockchain application using cosmos-sdk that anyone can use when trading NFT items. Users can sell their NFT item peer to peer, and the person who introduce the items can earn affiliate reward in Affondra market.

Implementation

Completed

✔️ basic blockchain functions
✔️ issue NFT token
✔️ create Item based on NFT
✔️ update Item infomation
✔️ buy Item
✔️ affiliate system
✔️ faucet system
✔️ web wallet

Firstly, watch Demo!

API Endpoint (Swagger)

You can refer to the api endpoint of Affondra module and NFT module.
View in Swagger Hub.

System Architecture

  1. Develop Affondra blockchain application with Starport.
  2. Use Firebase Hosting to host Vue application.
  3. Use Firebase storage to keep item images that users uploaded.
  4. Use Firebase cloud functions to set a faucet function. The faucet account mnemonic keys are stored in the cloud service so that users can get faucet with no time and try our product quickly.
  5. Nginx is used for load balancing and cors setting. It seems that rest server won't response to OPTIONS method request so we proxy frontend request using Nginx server.
  6. Affondra module is originally created to trade NFT, to motivate affliate, and to certify correct payment.

Install

affondrad & affondracli

requirement Go 1.15+ is required for the Cosmos SDK.

$ git clone github.com/EG-easy/affondra.git
$ cd affondra && git checkout -b [branch] tags/[latest release tag]
$ make

Try affondracli version and affondrad version to verify everything is OK!

Initialize configuration files and genesis file

Just use shell scripts bellow.

$ sh scripts/start.sh

Now let's start!

$ affondrad start

Play with CLI

Mint NFT

Firstly, you need to mint(or receive) a NFT. When creating NFT, you can modify the denom, nft id, description, tokenURI.

$ affondracli tx nft mint your-favorite-denom random-nft-id $(affondracli keys show -a user1) --tokenURI http://metadata.com --from user1 -y

Create Item

Now you have a NFT and you can sell it as a Item in the Affondra trading market. Just set the price you want to sell and affiliate reward for those who promote your item.

$ affondracli tx affondra create-item your-favorite-denom random-nft-id 1000affondollar 10affondollar This item is Awesome! true --from=user1 -y

Buy Item

Now your friend A introduces the item to your friend B, and friend B bought the item with the command below. Then you will get 990affondollar and your friend will get 10affondollar as a affiliate reward, and B will successfully receive the NFT from you.

$ affondracli tx buy-item random-nft-id B'address A'address --from B -y

Presentation

1 "AFFONDRA Presentatoin" 2 "AFFONDRA Presentatoin" 3 "AFFONDRA Presentatoin" 4 "AFFONDRA Presentatoin" 5 "AFFONDRA Presentatoin" 6 "AFFONDRA Presentatoin" 7 "AFFONDRA Presentatoin" 8 "AFFONDRA Presentatoin" 9 "AFFONDRA Presentatoin" 10 "AFFONDRA Presentatoin" 11 "AFFONDRA Presentatoin" 12 "AFFONDRA Presentatoin"

License

Licensed under the MIT.

affondra's People

Contributors

eg-easy avatar jyama321 avatar yukikajihara 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.