Nitrogen triodide energetics Ammonia has a heat of formation of $-46 \:\mathrm{kJ/mol}$ (which means that it's formation from the elements releases heat). When mixed with iodine at room temperature, it makes nitrogen triodide (heat of formation +146 complexed with ammonia, +287 pure). With the slightest touch it decomposes explosively back into nitrogen and iodine. Thus the net reaction for both steps seems to be ammonia decomposing into its elements.

Iodine seems to be catalyzing its decomposition. However, such a highly endothermic reaction seems unlikely (evaporating water is only $40.65 \:\mathrm{kJ/mol}$). Also, ammonia's formation is spontaneous ($-26 \:\mathrm{kJ/mol}$) despite the entropy cost with $1 \:\mathrm{atm}$ reactants. This shouldn't go backwards.

So where do we get the energy to make this unstable compound? Iodine is a weak halogen, it barely reacts with hydrogen. Could oxygen drag this reaction forward by stealing hydrogen from ammonia?
I'm not sure what your question is. The reaction from NI3 is largely exothermic (Wikipedia gives –290 kJ/mol as the reaction enthalpy), which is consistent with its explosiveness. The reaction from NI3 · NH3 is also exothermic: you quote the heat of formation of the NI3 · NH3 as being +146 kJ/mol, and the heat of formation of product NH4I is –202 kJ/mol. Both are largely favored entropically because they release gas.