Could anyone inform me about the scriptural/biblical foundation for the concept of mashiach? From which verse(s) came the conclusion that the 'idea of' mashiach exist? How was it determined that there is a mashiach?
not everything has a source in scripture. things that can be deduced from reason often do not have a source there. The concept of the Messiah is that history is not a chain of events going nowhere but that there is a goal and it is going in that direction, namely, towards G-d's ultimate plan. (see Rabbi Uziel Milevsky here for more).
nevertheless there are some hints in the torah, the earliest is in Genesis 1:2 "And the spirit of G‑d hovered above the surface of the waters" - midrash rabba - "The spirit of G‑d hovered"—this is the spirit of Moshiach
see also Rambam, Laws of Kings, ch.11:
"G‑d, your G‑d, will return your captivity and have mercy on you. He will return and gather you [from all the nations whither G‑d, your G‑d, has scattered you]. If your banished shall be at the utmost end of the heavens [G‑d, your G‑d, will gather you from there]... (Numbers 24:17) "A Star shall come out of Jacob. This is David - And a Sceptre shall rise out of Israel. This is the king Messiah" see here.
Wikipedia has a list of places in Nach that definitely refer to an eschatological messianic figure. There are also many locations in the Torah itself that refer to future events and individuals elliptically. This question provides many verses and their interpretations. For instance:
- Yaakov's explicitly labels his final address to his children as eschatological - "I will tell you what will happen to you at the end of days." (Gen. 49:10) He later refers to a continuity of power within the Tribe of Judah and a gathering of all the nations. Chazal understand this to refer to the Davidic line as having eternal kingship, fully realized at the end of days.
- Bilaam's final prophecy when he also tells Balak what will happen to HIS nation at the end of days (Num. 24:14) refers to a "star descending from Yaakov and a scepter from Israel" - a metonymy connected to the scepter of Judah prophesied by Yaakov and understood to refer to the same messianic king.
These two may be the most direct references to a messianic figure in the Torah, but many other verses are interpreted to refer to messianic times (such as the end of both sets of klalos).