Mechanochemical methods for assembling carbon-nitrogen bonds play a central role in the ongoing green chemistry-driven renovation of organic synthesis, including the synthesis of active pharmaceutical ingredients (APIs). However, chemoselective issues in these transformations, such as the tolerance of unmasked hydroxyl groups, have not been systematically explored. Screening of various amide coupling conditions revealed that 1 ethyl 3 (3 dimethylaminopropyl)carbodiimide (EDC) in combination with ethyl acetate as a liquid-assisted grinding (LAG) solvent was the most selective amide coupler, delivering 76–94% yields of the respective amide products from unprotected hydroxycarboxylic acids. Boc-protected tyrosine and serine with unmasked hydroxyl functionalities were successfully involved in peptide couplings. By incorporating green chemistry principles as a driver for innovation, the established protocol was applied to the synthesis of imatinib, an anticancer drug included in the World Health Organization’s List of Essential Medicines. The target API was synthesized with an overall yield of 86% and 99% HPLC purity through a two-step mechanochemical C–N bond assembling reaction sequence starting from 4 (hydroxymethyl)benzoic acid. A comparison of green chemistry metrics between the developed mechanochemical approach and similar solution-based approaches revealed reduced waste generation, enhanced eco-friendliness, and a superior safety profile for the proposed strategy. The safety improvement was primarily attributed to the elimination of toxic solvents and a genotoxic intermediate from the production chain.