Catalyzes the reductive dealkylation of cyanocobalamin to cob(II)alamin, using FAD or FMN as cofactor and NADPH as cosubstrate. Can also catalyze the glutathione-dependent reductive demethylation of methylcobalamin, and, with much lower efficiency, the glutathione-dependent reductive demethylation of adenosylcobalamin. Under anaerobic conditions cob(I)alamin is the first product; it is highly reactive and is converted to aquocob(II)alamin in the presence of oxygen. Binds cyanocobalamin, adenosylcobalamin, methylcobalamin and other, related vitamin B12 derivatives. Can utilize both FAD and FMN. Belongs to the MMACHC family.