Skip to content

GDPS-MRKT/Images

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

MRKT Images API

Image processing API for MRKT

Prerequisites

  • Rust installed
  • A device or server capable of running 24/7

Running

1. Download the repository manually or clone it:

git clone https://github.com/GDPS-MRKT/Images.git
cd Images

2. Create a .env file and fill it according to your needs using .env.example as a template

3. Start the instance with:

  • cargo run --release for production
  • cargo run for development/testing

Once you've done all of this, you should have a running instance!

Usage

Once you've got your instance running, you may use these endpoints:

Method Endpoint Description
GET / Check if the server's up or not
GET /info Get some information about the server
POST /process Process an image (resolution, format)

POST /process expects a multipart form-data; here's what you can put inside:

Field Required Description
file Yes (not if link is provided) An image to process
link Yes (not if file is provided) A link to an image to process
resolution No Something like WIDTHxHEIGHT or just a 1:1 ratio
format Yes Either png, jpg, jpeg, gif or webp

License

This project is licensed under the MIT License.

About

Image processing API for MRKT

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Contributors

Languages