One of the oldest theories about why people get sleepy is that a fatigue or toxin substance gets accumulated in the body. Initially, it was thought that this substance should reside in the blood. However, the fact that conjoined twins with a common circulatory system sleep independently argues against a common sleep-inducing factor in the blood.
But then scientists thought: maybe this putative sleep factor is not in the blood but in the brain. In order to test this idea, Legrende and Pieron in 1913 kept dogs awake for several days. They extracted cerebrospinal fluid from these animals and were able to induce sleep by injecting the fluid into the ventricular system of non-sleep deprived dogs. So that indicated a sleep inducing factor was in the brain system. The word hypnotoxin was used to describe this unknown factor. The "toxin" use reflected the idea that sleep was a negative, something bad.
For centuries many thought of sleep as a purely passive process while waking was active and being awake was like using a muscle which had to be rested during sleep.
Later physicians and scientists observed sleepiness and tiredness have a circadian rhythmicity which cannot be explained by the simple accumulation of a sleep-inducing factor, so the chemical theory of sleep was discarded. Today we know there are many sleep-inducing neurochemicals, but the simple ideas of the past are not valid. The idea of biomarkers, which are useful in other areas of medicine, for sleep, continues to be out there,
This primitive idea centered on blood flows, with the notion that during sleep blood to the brain was reduced. The blood relocated to the middle of the body.
The ancients had the idea of humors (or humours) – fluids in the body that controlled or at least influenced so illness, health, and behavior. The fluids were blood, phlegm, black bile and yellow bile and naturalist from Ancient Greece to early modern Europe thought these both influenced the body and humans could control the body by doing things to the humors. With modern science we know better, but the term lives on to some extent. Today the word "humoral" refers to fluid in the body outside cells, Lymph is a good example. The cytokines interleukin-1 beta (IL1ß) and tumor necrosis factor alpha (TNFa) are present in lymph and are known to affect sleep propensity. They promote NREM sleep and can be considered part of the homeostatic regulatory mechanism. Think of this as a humoral regulation of sleep to complement hormonal regulation from melatonin and cortisol.
Today scientists know that sleep regulation is complex and involves many chemicals in the brain and body. Adenosine, nitric oxide, prostaglandin D2, tumor necrosis factor, interleukin-1, and growth hormone releasing hormone (GHRH) play parts in the regulation of NREM sleep. Ghrelin (for hunger), orexins, corticotropin releasing hormone and adrenocorticotropic hormone (ACTH) promote waking.
There are mysteries still to be discovered, but duration and soundness of sleep are known to be at least influenced by these chemicals. Drug design (for sleep disorders) takes into account what is known about the biochemistry of the brain. Doctors and scientists are still working out the details and complex interactions inside the living body.
Scientists have never found brain cells that lack energy and "need" to sleep. Nor have they found neurons that run-out of neurotransmitters during the waking state and need to sleep to replenish them. It is true that the longer a neuronal assembly has been in the waking state the more likely it will flip to the sleeping state, but at the biochemical level, there is no imperative that it do so because of exhaustion.
There is no universal decline in neuron firing rate during sleep. Neurons in some areas decrease their activity during sleep while neurons in other areas actually increase their firing rate. This is true both during NREM as well as REM period sleep and this has been observed both through EEG scalp readings and by functional imaging studies of the human brain.
It's not the absence of sensory stimulation that causes sleep. The organism as a whole and individual organs and even clusters of cells undergo circadian cycles. Sleep is something we do, not the absence of doing anything.