This application is a demonstration of following APIs:
- Calls YouTube APIs continuously in background with some intervals
- Fetches latest videos and stores specific fields with indexing in database (MongoDB)
- A GET API which returns the stored video data in a paginated response sorted in descending order of published datetime
- A basic search API to search the stored videos using their title and description
Hosts FamEnd (client) at localhost:8080
and PayEnd (server) at localhost:3000
.
The very first step would be to create a .env
file in PayEnd
directory (or set an environment variable):
GOOGLE_API_KEYS=api,keys,separated,by,comma
NOTE: To get the keys, follow YouTube's specifications.
The whole project is dockerized (by composing dockerized versions of client and server individually), to set everything up:
docker-compose build && docker-compose up
That's it! Or, if you prefer a non-dockerized solution:
- < in PayEnd directory >
pip install -r requirements.txt python server.py
- < in FamEnd directory >
npm install npm start
The client (FamEnd) hosts a Search
functionality with pagination. Here's some screenshots:
(cropped because of the API key)
Aitik Gupta - aitikgupta.com/