Generate ASCII art from image.
You can try this API here: ascii-generator.herokuapp.com
- Golang 1.17
- Git (for clone project)
git clone https://github.com/shaynlink/ascii-api.git
cd ascii-api
go run *.go
I recommend to use Postman. for try API in local
Method | Path | Description |
---|---|---|
POST | / | Generate ASCII art from image. |
* | * | Generate ASCII art from image. |
Parameters form-data
- image: Image file.
- width: Width of the generated ASCII art.
- invert: Invert the image.
Return text ACII art.
curl --location --request POST 'http://ascii.projects.shaynlink.dev' \
--form 'image=@"./test.png"' \
--form 'width="80"' \
--form 'invert="true"'
const axios = require('axios');
const FormData = require('form-data');
const fs = require('fs');
const data = new FormData();
data.append('image', fs.createReadStream('./test.png'));
data.append('width', 80);
data.append('invert', true);
axios({
method: 'post',
url: 'http://ascii.projects.shaynlink.dev',
headers: data.getHeaders()
data
})
.then(({data}) => {
console.log(data);
});
All of the contributors that have helped with implementing various features, adding themes, fixing bugs, and more.
Thanks you for support my project and me, using ascii-generator.
You can also support me by donate, patron or buy me a coffee.