Short answer first, then the reasoning. Oral semaglutide is absorbed in the stomach with the help of SNAC, which locally raises pH and protects the peptide long enough to cross. That mechanism is fragile: bioavailability is roughly 1% and highly sensitive to gastric contents, so a mouthful of coffee genuinely changes the exposure. This is why the label wants 30 minutes and no more than half a glass of plain water.
Ask again with the specifics and you will get a better answer than this one.