Skip to content

Joshdike/Archive-Service-api

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Archive Service API

A ZIP archiving service built with Go. This service allows you to:

  • Create tasks for grouping files
  • Download multiple files concurrently (PDFs/JPEGs)
  • Monitor progress
  • Generate downloadable ZIP archives

Features

  • Concurrent Processing: Handles multiple downloads simultaneously

  • Task Management: Track progress of file collections

  • Auto-Zipping: Automatically puts files into ZIP archives

  • REST API: Simple HTTP endpoints for integration

  • Rate Limiting: Controls concurrent tasks to prevent overload

  • Port Configurations: API is hosted on localhost and PORT 8080

  • Limitations:

  1. Calling GetStatus on a Task with 3 or more downloads, autocompletes the task and returns archive link which means more files can't be added to that task
  2. You can't access the task Id of a completed task
  3. There is no storage(database). The program deletes all previously downloaded files and archives when restarted
  4. The method used for checking URL, checks header or extension but not content. This may incorrectly reject valid files that contain incorrect headers or extension. The method was used because it's faster and lightweight.
  5. Need to write more test files

API Endpoints

Method Endpoint Description
POST "/archives" Creat a new task
POST "/archives/{id}" Add a file to a task
GET "/archives/{id}" Get task status and ZIP URL
GET "/end/{id}" Force-complete a task early

Prerequisites

  • Go 1.20+
  • Linux/macOS (or WSL on Windows)

Installation

git clone https://github.com/Joshdike/Archive-Service-api.git
cd 11.07.2025
go mod download

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages