shivamarora123 / Energion-BE

This is the back-end repository for the Smart India Hackathon 2018, Government of Gujarat Project, GIS-GPS based connection estimation. Team ENV!$!ON members - Aaditya Chakravarty, Anshul Sharma, Chirag makkar, Lakshay Chhabra, Lokesh Manchanda, Shivam Arora

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Smart India Hackathon, 2018

Introduction

This is the back-end API setup for the GIS-GPS based connection estimation generation project deployed in conjuction with the specifics defined in the respective SRS document to allow for the same.

Installation and Running

npm install

build config.js (reference: config.dummy.js in system/ )

npm start

Routes

Welcome Route

Method Route Address Input Parameters Output JSON Expectation
GET / None Welcome Message

Authentication Routes

Method Route Address Input Parameters Output JSON Expectation
POST /auth/register fullName, userName, email, phone, passEnter, passConfirm Success/Error Message
GET /auth/verify/:username/:code None Success/Error Message
POST /auth/verify/phone/:username otp Success/Error Message
POST /auth/login username, password Success Message -> Token or Error Message
GET /auth/logout token (Header: x-access-token) or Params Success/Error Message
POST /auth/change-password token, oldPassword, newPassword Success/Error Message
GET /auth/status token Success/Error Message

Estimation Routes

Method Route Address Input Parameters Output JSON Expectation
POST /matrix/est address, capacity Rate Object

Connection Routes

Method Route Address Input Parameters Output JSON Expectation
POST /connection/new applicantName, father_husbandName, connectionAddress, contactNumber, emailAddress, permanentAddress, aadharNumber, connectionCategory, connectionType, loadDemand, voltageSupply Success/Error Message
POST /connection/transfer applicationID,transferName,aadhar,address updatedData Object / Error Message
POST /connection/closure applicationID,billNumber,billAmount,reason updatedData Object / Error Message
POST /connection/delete applicationID Success /Error Message
POST /connection/update applicationID, applicantName data/Error
POST /connection/mycon email data/Error

To-do List

  • Passport / Oauth Integration

  • Finalize models.

  • Organize client side redirects.

Application URL

https://api-egn.nvixion.tech

About

This is the back-end repository for the Smart India Hackathon 2018, Government of Gujarat Project, GIS-GPS based connection estimation. Team ENV!$!ON members - Aaditya Chakravarty, Anshul Sharma, Chirag makkar, Lakshay Chhabra, Lokesh Manchanda, Shivam Arora

License:MIT License


Languages

Language:JavaScript 99.1%Language:HTML 0.9%