Ascii's Toybox

Welcome to the toybox! This is my dumping ground for random interactive toys and APIs. Make yourself at home and feel free to play around with the stuff here.

This page also acts as a manual for the programming interfaces hosted on this domain. Methods are assumed to be GET unless mentioned otherwise.

One Word Story

Text written by strangers on the internet, one word at a time.

Click here to try it out

Circles of Trust

Each circle acts as a guestbook of people who've stopped by to grow its size. However, at any point, someone can choose to Betray the circle, dooming it and rendering it destroyed.

Click here to try it out

Color generator

/color/:pattern

Get a PNG image representing a given color. pattern follows the color format.

/palette/:pattern

Get a PNG image representing a swatch of colors. Maximum number of items is 20. pattern follows the color format.

Query parameters

/gradient/:pattern

Get a PNG image representing a gradient of colors. Maximum number of items is 20. pattern follows the color format with gradient stops.

Query parameters

Color format

The color parser supports both hexadecimal codes (without the leading hash symbol) and RGB expressions in rgb(0-255,0-255,0-255) format. Web named colors are also supported.

For endpoints that support multiple colors, each color is to be separated by a + character. Add {n} to the end of the expression to repeat it that many times. For example: blue{4}.

Use an asterisk symbol to request a random color. In parentheses after the asterisk, you can specify how to generate each color channel: min-max constrains the generator to a range. num locks that channel to a particular value. * is equivalent to 0-255. For example: *(128-192,222,*).

For endpoints that support gradient stops, prefix the color expression with n: to define a stop, where n is a value between 0 and 100 (percent). For example: 0:red+30:green+100:blue.

All operators can be chained together. For example, to generate a palette of several greens followed by one red:
*(64-198,255,0-128){5}+red.

Misc.

/headers

Get the request headers as received by the server.