Here's how to use it
The three current endpoints are https://placem.at/people
, https://placem.at/places
, and https://placem.at/things
. Any one of those will actually give you a valid image back on its own, but you probably want to do something a little bit fancier. The good news is that all three endpoints accept the same parameters, so there's not too much to remember. Everything is controlled via a few simple query string parameters:
-
Width
w
https://placem.at/people?w=500
- Specifies the width of the returned image. Can be used alone, or alongside
h
. A number in pixels. -
Height
h
https://placem.at/places?h=400
- Specifies the height of the returned image. Can be used alone, or alongside
w
. A number in pixels. -
Random
random
https://placem.at/things?w=250&random=some_seed
- By default, Placemat will always return the same image for a given size. If you want to mix things up a bit, pass
random=1
. If you want to get the same "random" image every time, pass any other value forrandom
, e.g.random=hello
orrandom=2
. This tends to be especially handy for the/people
endpoint. -
Text
txt
https://placem.at/people?txt=Hello+World
- Placemat will add your requested dimensions to the returned image by default, but you can bypass that by passing
txt=0
. If you want to display custom text, just send along something liketxt=Hello+World
! -
Text Color
txtclr
https://placem.at/places?txt=Hello+World&txtclr=f00
- Change the displayed text color. Accepts a 3 (RGB), 4 (ARGB), 6 (RRGGBB), or 8 digit (AARRGGBB) hexadecimal value. The first two digits of an 8 digit hex value represent the color's alpha transparency. Defaults to
BFFF
. -
Overlay Color
overlay_color
https://placem.at/things?overlay_color=0f0
- Defines a custom overlay color. Accepts a 3 (RGB), 6 (RRGGBB) or 8 digit (AARRGGBB) hexidecimal value. The first two digits of an 8 digit hex value represent the color's alpha transparency. Defaults to
ACACAC
-
Overlay Blend Mode
overlay_blend
https://placem.at/places?overlay_blend=difference
- Allows changing the overlay's blend mode. Defaults to
multiply
, and can be assigned to any of the imgix blend modes.