Here is an example I found on GitHub on how to create a new Product Master with variants and then release it in AX2012.
All about IT
Here is an example I found on GitHub on how to create a new Product Master with variants and then release it in AX2012.