This is a TypeScript/Express port of the Australian Government's branding API to generate logos with text (originally written in Kotlin and Spring Boot). The logos it generates are almost identical to the original ones (just some small font rendering differences), and from some unscientific tests it appears to be substantially faster. The actual API/query parameter usage is backwards compatible with the original implementation, but there are additional features.
This api generates Government logos using the coat of arms that follow the guidelines
Although this api is live, it's not monitored or setup to horizontally scale.
Use it in production at your risk.
You're better off using it to generate images and then serve them yourself
https://aus-crest.vercel.app/inline.png?agency=Department%20Of%20Finance&height=200
https://aus-crest.vercel.app/stacked.png?agency=Department%20Of%20Finance&height=200
https://aus-crest.vercel.app/inline.png?agency=Department%20Of%20Health&agency=Department%20of%20Foreign%20Affairs%20and%20Trade&agency=Attorney-General%27s%20Department&height=200
https://aus-crest.vercel.app/stacked.png?agency=Department%20Of%20Health&agency=Department%20of%20Foreign%20Affairs%20and%20Trade&agency=Attorney-General%27s%20Department&height=200
https://aus-crest.vercel.app/inline.png?agency=Department%20of%20the%0APrime%20Minister%20and%20Cabinet&agency=%7CGovernment%20Branding%20Unit&height=200
There are two endpoints:
https://aus-crest.vercel.app/inline.png
https://aus-crest.vercel.app/stacked.png
Both endpoints take the same parameters:
The name of the agecny to display.
You can add as many '&agency' paramaters as you like, they will be added in order.
The guidelines cater for sub-headings, for things such as function names.
These use a non-bold font.
If you prepend an 'agency' param with a pipe char (|, or %7C), that text will be a sub-heading
Lines won't wrap.
If you want to break up a line, add a newline (\n, or %0A).
Sets the total height of the image.
The width is derrived based on the longest 'agency' parameter
Overrides the natural aspect-ratio of the images and pads it out to be a square
Overrides the "Australian Government" text with the parameter value