Giter Club home page Giter Club logo

nfthack22's Introduction

NFTpay

Make your own blockchain-hosted invoices - hosted for free on IPFS and fulfilled by cryptocurrency.

Built for the NFThack2022 hackathon.

Benefits

  • Free hosting for invoice checkout pages.
  • No need to open a partnership with an external vendor for managing invoices, or paying vendor-specific fees such as those from Stripe.
  • Receipts auto-hosted as NFT's. No chance of losing an attachment or document showing the time and receipt of purchase. Receipt and time of purchase forever retained on ethereum's network.
  • Payments facillated and settled on crypto. Use either credit card or your ERC20 token of choice to settle the payment.
  • On successful payment callback, receipts represented as NFTs are delivered by the app to both the buyer and seller wallets after the transaction.

Technologies used

Invoice hosting/generation

  • IPFS/Filecoin: Hosting of the invoice metadata on IPFS with it's own NFT contract. Invoice metadata saved in a static IPFS-served json file.

Payments/Checkout

  • Unlock Protocol: Creates an ethereum based paywall where a user chooses an Ethereum wallet as the checkout method of choice.
  • Circle: Enables settling transactions in USDC using credit card directly from the invoice checkout screen.
  • Superfluid: Continuous stream invoice support (usable for subscriptions/licensing). Option to set up a superfluid flow on the invoice checkout page.

NFT Receipts

  • Covalent: Transaction history / lookup. After transactions are completed, Covalent can be used for destination address lookup to view the history on a particular network in a user-friendly table format in-app.
  • NFTPort: Creation of the NFT payment receipts for arbitrary addresses and blockchains (Filecoin could have potentially been used as well).

Running the project

This project is a hackathon prototype and would require additional work to be production ready (i.e. around some of the final checkout flows).

To run/demo the project locally, NFTpay requires the following environment variables.

    REACT_APP_NFT_KEY={YOUR_NFT_STORAGE_KEY} # NFT storage key for IPFS.
    REACT_APP_COVALENT_KEY={YOUR_COVALENT_API_KEY} # Covalent key for the history page.
    REACT_APP_NFT_PORT_KEY={YOUR_NFT_PORT_API_KEY} # NFT port api key for receipt creation.

After declaring the above environment variables, use the below command to start the project:

yarn && yarn start

Homepage

Deployment

  • nftpay.surge.sh

Example Invoice

Use cid: bafyreifxtpw5sgtpvpc5r5ltyhhxtgikxcwyba7rx2wayvvgb7gh7bfhva /pay/{cid}

Useful links/references

nfthack22's People

Contributors

cbonoz 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.