Skip to content

emmsdan/isecure-send-api

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

25 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

iSecure-send-api

I woke up one morning and decided to do "A simple end-to-end encrypted file sending system". That's why we have this project.

It has just three main feature:

  • upload files and secure
  • control file access/download
    • download files a number of times.
    • files can't be downloaded after a particular time
  • only the person sent to can access/download it.

but you can contribute to it by just raising a PR.

LIVE API DEMO: https://my-secure-share-api.herokuapp.com/ FRONTEND REPO: https://github.com/emmsdan/isecure-send-frontend

js-standard-style

TECHS

  • NodeJS/ExpressJS
  • Mysql
  • heroku

API DEFINITIONS

Refresh Database

GET: api/refresh

response

{
  "message": "Database Tables refresh"
}

Successful Upload

POST: api/upload

request

Use the follow:

  • for expires_in: "5m", "1h", "12h", "1d", "3d", "5d", "7d"
  • for downloads_allowed: 1, 10, 15, 20, 25, 50, 100
  • for iss_file: upload files to be zipped
{
  "sender_name": "Emmanuel Daniel",
  "sender_email": "uniq@mail.org",
  "receiver_email": "example@main.com",
  "expires_in": "5m",
  "downloads_allowed": "10",
  "iss_file": "files"
}

response

{
    "message": "Uploaded successfully.",
    "status": "success",
    "fileInfo": {
        "url": "/74mr/6n2ou",
        "sender_name": "Emmanuel Daniel",
        "sender_email": "uniq@mail.org",
        "receiver_email": "example@main.com",
        "expires_in": "5m",
        "downloads_allowed": "10"
    }
}

Download File

POST: api/:secure_id (secure_id = (url generated during upload))

response

Success
  • should download the file
Error
{
  "message": "URL has expired or is invalid."
}

About

A simple end-to-end encrypted file sending system.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published