Other generated classes use the isInternal property to specify whether they are declared with public or internal visibility modifier. Enum classes it is choosing between internal and no visibility modifier. This makes the generated code incompatible with explicitApi mode