/HNG-Stage-5

You will develop the Backend for their Chrome task. This backend will receive the video they send, save it to disk and render the page where the video can be played. Do not add authentication. This is an individual task, not a team task. Have your own repo where you work on this. You do not need to use a DB for this, except you want to.

Primary LanguageJavaScript

HNG Stage 5 Backend - Develop a Chrome Extension Video uploader and Transcriber

Node.js Multer Express MongoDB CRUD API Blob

A simple REST API for CRUD operations to recieve streamed videos save them in chunks the finalize the video compilation then send the video-url to the compiled video. Resources using Node.js, Multer, Blob, Express, MongoDB, and Mongoose.

Table of Contents

Prerequisites

Before you begin, ensure you have met the following requirements:

  • IDE- Vscode or any suitable.
  • Node.js and npm installed.
  • MongoDB installed and running.
  • Postman or a similar tool for API testing.

Getting Started

Installation

  1. Clone the repository:

    git clone https://github.com/Okafor-Ifeanyi/HNG-Stage-5
  2. Change to the project directory:

    cd your-api-repo
  3. Install dependencies:

    npm install

Environment Variables

  • Create a .env file in the root directory of your project and add the following environment variables:
    MONGO_URI= ? your_mongodb_uri_here  
    PORT= ? your_desired_port_here
    DEEPGRAM_API_KEY= ? your_desired_port_here

MONGO_URI=your_mongodb_uri_here
PORT=your_desired_port_here DEEPGRAM_API_KEY= ? your_desired_port_here

API Endpoints

  • Create a new session: POST /api/createSession

  • Upload video CHunk to session: POST /api/createSession

  • finalize session: POST /api/finalize-session

  • Get specific Session by sessionID: GET /api/:info

  • Get all Session Video URL: PATCH /api/:id

Testing

Use Postman or your preferred API testing tool to test the CRUD operations. Here's a sample Postman collection you can import: Postman Collection.

Render Live

Documentation

This Docs contains an extensive documentation with the following features

  • Standard formats for requests and responses for each endpoint.
  • Sample usage of the API, including example requests and expected responses.
  • Any known limitations or assumptions made during development.
  • Instructions for setting up and deploying the API locally or on a server.

Postman Docs

Contributing

Contributions are welcome! Feel free to open issues or submit pull requests.

License

This project is licensed under the MIT License.

Copyright (c) 2023 Prog BIO