Skip to content

bentinata/go-palette

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Go Palette

A simple Go API to get most common colors from an image. Basic view is available to try at https://bentinata.com/palette.

Prerequisite

You need to install gin first.

go get -u github.com/gin-gonic/gin

Running

Run it right away, like:

go run *.go

Or build it first, then execute:

go build && ./go-palette

Server will be available on port 5000.

HTTP API

The actual product is an HTTP API, available at POST /image.

curl -F file=@/path/to/your/image 127.0.0.1:5000/image

This will return a response like:

{
  "data": [
    "#282a29", 
    "#ec1d25", 
    "#4b6688", 
    "#f1f1f4"
  ]
}

About

Go palette quantization app.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published