Generate a png or jpg from a rgb or hexadecimal code through http