Nucleotidyltransferase that catalyzes the formation of cyclic GMP-AMP (cGAMP) from ATP and GTP. Catalysis involves both the formation of a 2,5 phosphodiester linkage at the GpA step and the formation of a 3,5 phosphodiester linkage at the ApG step, producing c[G(2,5)pA(3,5)p]. Has antiviral activity by acting as a key cytosolic DNA sensor, the presence of double- stranded DNA (dsDNA) in the cytoplasm being a danger signal that triggers the immune responses. Binds cytosolic DNA directly, leading to activation and synthesis of cGAMP, a second messenger that binds to and activates TMEM173/STING, thereby triggering type-I interferon production.