The paper reports the role of graphite as an optode for recording of time domain photoacoustic (PA) spectra of some new solid heterocyclic groups nitrogen-rich imidazole, 1,2,4-triazole and tetrazole molecules using 532 nm and 1064 nm wavelengths. The fundamental and second harmonic of 30 ps pulse duration are obtained from Q-switched Nd: YAG laser at 10 Hz repetition rate. The used solid HEMs have very weak absorption in the visible and NIR region. Therefore, these compounds are physically mixed with graphite powder in equal proportion for enhancing the PA signal. The optode works as a receptor of incident visible-NIR radiation and releases thermal signal which is communicated to reporter explosive molecules in terms of phonon waves and helps to generate acoustic signature. The study also carried out to understand the behavior of acoustic waves with respect to data acquisition time and incident laser energy. These compounds have different non-radiative decay times and quality factors “Q” of PA cavity, which reveals the change in the structure and conjugate bonds of the molecules in the graphite matrix. The finding is also supported by the Raman spectra due to direct coupling of phonon wave’s momentum between graphite and HEMs in terms of shift in the G and D bands of graphite.