Skip to content

Latest commit

 

History

6 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

This is a repository I specifically created for the fyle backend coding challenge

The data taken from the csv file in the repository was converted into json and stored in a database provided by mlabs which is a Database-as-a-Service provider.

I used Node.js and Express.js for the backend
I used MongoDB for the database

It has been hosted in heroku as requested.

URLs for the solution below:

Question 1: Given a bank branch IFSC code, get branch details
- Answer 1: https://stark-fjord-77483.herokuapp.com/banks_ifsc/{ifsc_code} 
			here {ifsc_code} is replaced by any valid IFSC code you give 

Question 2: Given a bank name and city, gets details of all branches of the bank in the city
- Answer 2: https://stark-fjord-77483.herokuapp.com/banks_name_city/{bank_name}/{city_name}
			here {bank_name} is replaced by any bank name that you give
				 {city_name} is replaced by any city name that you give

***VERY IMPORTANT***
The queries are case sensitive, so if you are looking for data which has all upper case letters, please put the parameter in upper case

I tested the APIs that I developed using the Postman API testing tool which comes as a google chrome extension and it comes with URI encoding

I have one instance of the app already set up with the domain : https://stark-fjord-77483.herokuapp.com/

But just in case you need to create another app:
(If you do know the steps, that's great. But then, I thought I'd best iterate it once more for the purpose of running my app on your own)

1. Download the Heroku CLI for the Operating System you use (for me it's Mac OS based).

2. Do make sure that you have the latest versions of 'node', 'npm' and 'git' installed.

3. Clone the repository from github and enter the directory
	$ git clone https://github.com/PLSV/fyle_challenge
	$ cd fyle_challenge

4. Create the app on heroku which gets ready to receive your source code and create a randomized domain for your app which you can rename
	$ heroku create
Aftermath : Creating sharp-rain-871... done, stack is cedar-14
			http://sharp-rain-871.herokuapp.com/ | https://git.heroku.com/sharp-rain-871.git
			Git remote heroku added
	URL for your app : http://sharp-rain-871.herokuapp.com/

5. Now, deploy your code
	$ git push heroku master

6. Make sure that one instance of the app is running
	$ heroku ps:scale web=1

7. Now visit the app at the URL generated by its app name. As a handy shortcut, you can open the website as follows:
	$ heroku open
Aftermath : the app opens on a new tab and shows the home page of the app being rendered.

for building a general purpose Node.js application, visit : https://devcenter.heroku.com/articles/getting-started-with-nodejs#introduction

About

This repository contains the source code for the fyle challenge

Resources

Stars

0 stars

Watchers

1 watching

Forks

Releases

Packages

Contributors

Languages