There are two basic forms of medicine: internal and external. I don’t know of any special restrictions to externally applied medicines.
Any substance to be taken internally must first be handed to ordained Sangha by laity, other than water and tooth care. And anything else taken internally must fit into one of four categories: almsfood, juice, medicinal tonics, and medicines. Each category is described in detail in the Vinaya. And each category is distinguished by the time limits within which it may be ingested.
*ALMSFOOD is the broadest category, encompassing almost anything considered edible, with a short list of items forbidden for specific reasons (for example, horse flesh is forbidden b/c horses are held in admiration). Food has the most restricted timeframe: it must be offered between dawn & noon, and consumed or disposed of before noon on the same day. (Nor are monks allowed to keep leftovers for another day.)
*JUICE is pretty much what you’d expect, generally the squeezed juice of fruits. There are some details not worth getting into here. (Be aware that watermelon juice and coconut juice won’t be accepted by some observant monks yet will be by others, depending on interpretation of a Pali phrase.) Juice can be offered at any hour, but must be consumed or discarded before dawn of the same day.
Liquid from foods such as nuts, beans, grains, or cooked vegetables, are not juice. The juice must be thin, not pulpy, and not pureed. Western supporters often want to offer non-allowed healthy expensive juices that contain pureed fruit or banana (which is a food). I usually have to filter pulp out of any fresh juice that gets offered. Observant communities in the West vary in their approach to unopened shelf-stable juices, since there’s no concern about potential for fermentation.
*TONICS are a specific short list of foods deemed medicinal in Ayurvedic medicine that the Buddha approved to consume as medicine. (Mere fatigue is a good enough reason to use them.) This was a shrewd move by the Buddha to ease the no-food-after-noon rule for those who needed to consume something in later hours yet without opening the floodgates to gnoshing at all hours.
As applied today the tonics exception broadly allows any sugars & oils. The list includes an Indian cheese curds that opened the door for modern dairy products to be potentially allowed, depending on one’s community’s interpretation. (The tonics exception is why you may see an otherwise ascetic Western monk munch on cheese or a slab of dark chocolate at night.)
Tonics may be offered any time but must be consumed or disposed of within 6 nights. Whether they can be re-offered beyond that time, and by whom, are protocols that vary among communities.
The most common tonics-related mistake by Western supporters is bringing after noon chocolate bars containing milk -which remains technically a food, hence making the chocolate also a food not an allowed tonic. Followed closely by the error of bringing dark chocolate containing bits of non-allowed fruits or nuts.
*Now finally we get to MEDICINE. Medicine for internal consumption must belong to one of several lists of medicine found here & there in the Vinaya. It is a complex topic. Anything deemed a medicine is allowed to be kept and used indefinitely; I like to say that it’s good for the life of the product.
Western monks typically consider most pharmaceuticals to belong to the approved category of “salt-based medicines” hence are allowed. Non-nutritive roots are allowed, hence ginger is a medicine. Coffee and tea are medicines to most monks, but reportedly not in Myanmar (where tea leaves are eaten as food).
A point of tension between observant monks and helpful Western supporters is protein powders, which usually have non-allowed ingredients even though the powders do have a medicinal status in our culture.
So it looks like your intuition was correct that an explanation of medicines would help you understand almsfood rules, at least in a general sense.