(6R)-L-erythro-5,6,7,8-tetrahydrobiopterin + L-phenylalanine + O2 = (4aS,6R)-4a-hydroxy-L-erythro-5,6,7,8-tetrahydrobiopterin + L-tyrosine (6R)-L-erythro-5,6,7,8-tetrahydrobiopterin + L-tryptophan + O2 = (4aS,6R)-4a-hydroxy-L-erythro-5,6,7,8-tetrahydrobiopterin + 5-hydroxy-L-tryptophan N-terminal region of PAH is thought to contain allosteric binding sites for phenylalanine and to constitute an 'inhibitory' domain that regulates the activity of a catalytic domain in the C-terminal portion of the molecule. Amino-acid degradation; L-phenylalanine degradation; acetoacetate and fumarate from L-phenylalanine: step 1/6. Phenylalanine hydrolase activity is found in yolk granules of embryos, and female abdomen and fat body tissues. Tryptophan hydroxylase is expressed in serotonergic neurons. Both enzymes are present in cuticular tissues. In Drosophila, the 2 enzymes, PAH and TRH are found to be encoded by the same gene. Preference for the substrate is probably due to post-translational modifications such as phosphorylation, or by changes in the N-terminal regulatory domain. Belongs to the biopterin-dependent aromatic amino acid hydroxylase family.