How can I limit an image to a specific palette when exporting in Draw?

For example, I want to export as a .png with a specific palette of 6 colors. I can use python to do the conversion but it isn’t as clean as it would be if I could get Draw to just do it that way in the first place.