what is recommended way of automating XCode install

Dear Sirs,

I prepare CI/CD environments, thus I have to automatically download/install XCode. please tell me what is the way recommended by Apple for such flow.

what is recommended way of automating XCode install
 
 
Q