Giter Site home page Giter Site logo

pasindus96 / location-api-sl Goto Github PK

View Code? Open in Web Editor NEW
36.0 4.0 14.0 443 KB

This API can be use to all developers to get location details of Sri Lanka 🇱🇰 including major cities, sub areas, districts and Provinces. ⛳️

Home Page: https://locatesrilanka.herokuapp.com

License: MIT License

JavaScript 57.82% CSS 3.27% EJS 38.91%
location-services sri-lanka location nodejs mongodb nosql-database nosql gps-cordinates provinces administrative-districts

location-api-sl's Introduction

Location Data API - Sri Lanka

MIT License Forks Stargazers

System Diagram

Table of Contents
  1. Introduction
  2. Technologies
  3. Use Cases
  4. Getting Started
  5. Project Setup
  6. Contributing
  7. Acknowledgements

Introduction

Developers can use this API to get datails of cities, districts and provinces which located all around the Sri Lanka. This API can easily intergarte to you appication using particular URI.

Technologies

Implemantations

  • MongoDB
  • NodeJS

Hosting

  • Heroku
  • DigitalOcean

Use Cases

  • Developers can get major cities and sub areas in each district
  • GPS cordinates (Latitude and Longitude) are avilabe for each major city and sub areas. GPS cordinates can be use with Google Maps and other GPS/ Map services
  • Developers can easily get Administrative Districts of the Colombo Mucipal Council with GPS cordinates, Administrative Distict Name and Sub Area (Known name like Kollupitiya, Modara, etc.)
  • Users can get all the disticts and provinces in Sri Lanka

Getting Started

API Documentation

1. Get Major Cities And Sub Areas in Sri Lanka

   https://locatesrilanka.herokuapp.com/cities 

2. Get All Provinces in Sri Lanka

   https://locatesrilanka.herokuapp.com/provinces

3. Get All Districts in Sri Lanka

   https://locatesrilanka.herokuapp.com/districts

4. Get GPS Cordinates of major city or sub area in Sri Lanka

   https://locatesrilanka.herokuapp.com/cities/cordinates/[CITY NAME IN ENGLISH]
Example

Assume user needs to find GPS cordinates of Kadduwela, Sri Lanka

   https://locatesrilanka.herokuapp.com/cities/cordinates/Kaduwela

5. Get all major cities or sub areas in selected distict Sri Lanka

   https://locatesrilanka.herokuapp.com/cities/cordinates/[DISTRICT ID]
Example

Assume user needs to find GPS cordinates of Colombo District, Sri Lanka

   https://locatesrilanka.herokuapp.com/cities/byDistrict/5

6. Get Administrative Districts of the Colombo Mucipal Council, Sri Lanka

   https://locatesrilanka.herokuapp.com/cities/colombo_mca/[COLOMBO SUB AREA]
Example

Assume user needs to find details of Colombo 1, Sri Lanka

   https://locatesrilanka.herokuapp.com/cities/colombo_mca/1

7. Get all Administrative Districts of the Colombo Mucipal Council, Sri Lanka

   https://locatesrilanka.herokuapp.com/cities/colombo_mca

8. Get all Districts in Selected Province

   https://locatesrilanka.herokuapp.com/districts/byprovince/[PROVINCE ID]
Example

Assume user needs to find districts in western province, Sri Lanka

   https://locatesrilanka.herokuapp.com/districts/byprovince/1

9. Get count of all Districts in Selected Province

   https://locatesrilanka.herokuapp.com/districts/districtcount/[PROVINCE ID]
Example

Assume user needs to find count of districts in western province, Sri Lanka

   https://locatesrilanka.herokuapp.com/districts/districtcount/1

Project Setup

  1. Clone the repo
    git clone https://github.com/PasinduS96/location-api-sl.git
  2. Install NPM packages
    npm install
  3. Create .env file for environment varialbes
  4. Create environment variables
    PORT=
    MONGO_URI=
  5. Run Project
    npm start

Contributing

Contributions are what make the open source community such an amazing place to be learn, inspire, and create. Any contributions you make are greatly appreciated.

  1. Fork the Project
  2. Create your Feature Branch (git checkout -b feature/AmazingFeature)
  3. Commit your Changes (git commit -m 'Add some AmazingFeature')
  4. Push to the Branch (git push origin feature/AmazingFeature)
  5. Open a Pull Request

Acknowledgements

License

MIT © PasinduS96

location-api-sl's People

Contributors

pasindus96 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar

location-api-sl's Issues

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.