You can try out with the color harmony rule like analogous which can produce analogous themes with both the colors present. Specify one as the base color and and fill the other color value in any of the other colors to adjust the analogous colors based on the both the colors. Keep in mind that not all rules can work this way as they will not hold valid and will therefore modify the base color follow the rule. The best way to deal with this case is to specify one as a base color and adjust the theme to find the best matches as per the rules and then move on to the custom rule and replace one of the colors with the second one.
Alternatively, you can search themes created by the community based on your color values(you can type both the color values space seperated on the search box, say 000000 and FFFFFF to search themes which have both black and white colors in them), and modify them to suit your needs.