Code Monkey home page Code Monkey logo

fampay_assignment's Introduction

FAMPAY ASSIGNMENT

submitted by Mustafiz Kaifee

Steps to run this project

  1. Clone or Download this repo.

  2. run npm i

  3. Put API_KEY in youtubeApiKeys.js file

  4. create .env file in the root directory or rename .env.sample to .env. Add or update the port and database URL.

    PORT=3000 DB_URI=mongodb://localhost:27017/fampay_youtube

  5. To start the server run npm run start

  6. The server will start running on the port you specify start query YouTube videos and keep adding them to the database.

  7. To test the search and query API. Copy the URL or import the curl for that.

    i. Search all video API -> http://localhost:3000/video

     `curl --location 'http://localhost:3000/video/'`
    

    ii search video by query -> http://localhost:3000/video/search?q=india&page=1

     `curl --location 'http://localhost:3000/video/search?q=india&page=1'`
    

To run using docker

  1. Download docker.
  2. Build a docker image using the command docker build -t <image_name> .
  3. Before starting the docker update the DB_URL inside docker-compose.yml file to the actual db URL or keep it as if you are using local Mongodb.
  4. Start the docker docker compose up
  5. The server will start running on the port you specify.

fampay_assignment's People

Contributors

mustafiz04 avatar

Watchers

 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.