Giter Site home page Giter Site logo

desico-token-crowdsale's Introduction

Desico Token

https://badges.frapsoft.com/os/mit/mit.svg?v=102 Build Status Coverage Status

About

DESICO is the world’s first platform to issue, buy, and sell security tokens in full compliance with the law. See desico.io for more details.

Development

The smart contracts are being implemented in Solidity 0.4.21.

Prerequisites

  • NodeJS, version 9+ (I use nvm to manage Node versions — brew install nvm.)
  • truffle, which is a comprehensive framework for Ethereum development. npm install -g truffle — this should install Truffle v4.1.5 or better. Check that with truffle version.

Initialisation

    npm install

Compiling

From within Truffle

Run the truffle development environment

truffle develop

then from the prompt you can run

compile
migrate
test

as well as other truffle commands. See truffleframework.com for more.

Standalone

Run

npm test

To generate code coverage reports run

npm run coverage

Note Generating code coverage reports takes a bit longer to run than just running the tests.

Linting

We provide the following linting options

  • npm run lint — to lint the solidity files and the javascript.

Deploying to rinkeby

You'll need an address on the Rinkeby blockchain with some ETH in it.

Use MetaMask to create a wallet and use faucet.metamask.io to get some ETH for it.

You will need to supply a file called .env in the root of the project (copy & change from .env.test).

Then run

npm run deploy:rinkeby

API

    node app.js
  • /whitelist/:address - check address is whitelisted (curl -X GET http://localhost:3000/whitelist/0x0)
  • /whitelist/:address - add address to whitelist (curl -X POST http://localhost:3000/whitelist/0x0)
  • /whitelist/:address - remove address from whitelist (curl -X DELETE http://localhost:3000/whitelist/0x0)
  • /ico/started - check ICO is started or not (curl -X GET http://localhost:3000/ico/started)
  • /ico/ended - check ICO is ended or not (curl -X GET http://localhost:3000/ico/ended)
  • /ico/initialized - check ICO is initialized or not (curl -X GET http://localhost:3000/ico/initialized)
  • /ico/initialize - initialize ICO (curl -X GET http://localhost:3000/ico/initialize)
  • /ico/finalized - check ICO is finalized or not (curl -X GET http://localhost:3000/ico/finalized)
  • /ico/finalize - finalize ICO (curl -X GET http://localhost:3000/ico/finalize)
  • /ico/amount/:value - get current rate (by wei) (curl -X GET http://localhost:3000/ico/amount/10000000000000000000)

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.