The Rambam in Hilchos Tefilah 1:1-3 describes the Biblical mitzvah of prayer. In Halacha 2 he writes:
ומגיד שבחו של הקדוש ברוך הוא, ואחר כך שואל צרכיו שהוא צריך להן בבקשה ובתחינה, ואחר כך נותן שבח והודיה לה' על הטובה שהשפיע לו
He tells of Hashem's praises, and afterwards asks for his needs in requests and supplications, and after that gives praise and thanks to Hashem for the good that He has bestowed upon him
Now, it happens to be that this Biblical 3-tiered structure is paralleled in our Rabbinically instituted prayers, which begin with praises, follow with requests, and finish with thanks. But, where did the Rambam get that this exists in the Biblical structure of prayer? The entire source of the Biblical mitzvah is, as the Rambam says in Halacha 1, just the one verse of "ועבדתם, את ה' אלוהיכם" - "And you shall serve Hashem your G-d" (Shemos 23:25). How did the Rambam derive this 3-part formation of prayer?