Catalyzes the formation of NAD(+) from nicotinamide mononucleotide (NMN) and ATP. Can also use the deamidated form; nicotinic acid mononucleotide (NaMN) as substrate with the same efficiency. Can use triazofurin monophosphate (TrMP) as substrate. Also catalyzes the reverse reaction, i.e. the pyrophosphorolytic cleavage of NAD(+). For the pyrophosphorolytic activity, prefers NAD(+) and NaAD as substrates and degrades NADH, nicotinic acid adenine dinucleotide phosphate (NHD) and nicotinamide guanine dinucleotide (NGD) less effectively. Involved in the synthesis of ATP in the nucleus, together with PARP1, PARG and NUDT5. Nuclear ATP generation is required for extensive chromatin remodeling events that are energy-consuming. Fails to cleave phosphorylated dinucleotides NADP(+), NADPH and NaADP(+) (By similarity). Protects against axonal degeneration following mechanical or toxic insults (By similarity). ATP + beta-nicotinamide D-ribonucleotide + H(+) = diphosphate + NAD(+) ATP + H(+) + nicotinate beta-D-ribonucleotide = deamido-NAD(+) + diphosphate Divalent metal cations. Zn(2+) confers higher activity as compared to Mg(2+). Activity is strongly inhibited by galotannin. Inhibited by P1-(adenosine-5')-P4-(nicotinic-acid-riboside-5')-tetraphosphate (Nap4AD). Cofactor biosynthesis; NAD(+) biosynthesis; NAD(+) from nicotinamide D-ribonucleotide: step 1/1. Cofactor biosynthesis; NAD(+) biosynthesis; deamido-NAD(+) from nicotinate D-ribonucleotide: step 1/1. Homohexamer. Interacts with ADPRT/PARP1. Belongs to the eukaryotic NMN adenylyltransferase family.