Reverse engineered prompt

GitHub

Build me a simple API that takes an uploaded image and splits it into a set of color separation images based on colors I send in. I want this for print workflows like Risograph and screen printing, so the main use case is posting a PNG plus an array of hex colors such as white and black, then getting back the generated separation file names.

Please make it easy to test locally with a route like a POST to separate that accepts multipart form data with the image and colors, and a GET route to fetch one of the generated PNG files by name. The response from the upload route should just be a list of the created file names. Keep it lightweight and practical, with sensible temporary file handling and output that works for normal print prep. If anything is unclear, look up current docs online and make reasonable choices so it runs cleanly and can be tried with curl right away.

Have a live product UI? Try website reverse