One image for multiple categories

In that case you could contrive to do something similar with the API, but you’re on your own for that. You’d start with Reverse engineer the Discourse API. . .