Code of Civil Procedure CCP § 2032.020
(a) Any party may obtain discovery, subject to the restrictions set forth in Chapter 5 (commencing with Section 2019.010 ), by means of a physical or mental examination of (1) a party to the action, (2) an agent of any party, or (3) a natural person in the custody or under the legal control of a party, in any action in which the mental or physical condition (including the blood group) of that party or other person is in controversy in the action.
(b) A physical examination conducted under this chapter shall be performed only by a licensed physician or other appropriate licensed health care practitioner.
(c)(1) A mental examination conducted under this chapter shall be performed only by a licensed physician, or by a licensed clinical psychologist who holds a doctoral degree in psychology and has had at least five years of postgraduate experience in the diagnosis of emotional and mental disorders.
(2) If an action involves allegations of sexual abuse of a minor, including any act listed in paragraphs (1) to (3), inclusive, of subdivision (a) of Section 1002 , and the examinee is less than 15 years of age, the licensed physician or clinical psychologist shall have expertise in child abuse and trauma.