The following is by no means an exhaustive list (variations of the expression, for example, are not included) and for each prophet, only one example is cited. (Zechariah, just a minor prophet, for example, uses the expression over thirty times.)
Moses (Exodus 4:22)
Joshua (Joshua 24:2)
A man of God (1 Samuel 2:27)
Samuel (1 Samuel 10:17-18)
Nathan (2 Samuel 7:5)
Gad, Davids seer (2 Samuel 24:11-12)
Shemaiah the man of God (1 Kings 12:24)
A man of God (1 Kings 13:1-2)
Elisha (2 Kings 7:1)
Ahijah the prophet (1 Kings 14:7)
Elijah (2 Chronicles 21:12)
A prophet (1 Kings 20:13)
Shemaiah the prophet (2 Chronicles 12:5)
Jahaziel (2 Chronicles 20:14-15)
Zechariah, son of a priest, not the minor prophet (2 Chronicles 24:20)
Huldah the prophetess (2 Chronicles 34:23)
Isaiah (Isaiah 1:11)
Jeremiah (Jeremiah 2:2)
Ezekiel (Ezekiel 3:11)
Hosea (Hosea 2:13)
Joel (Joel 2:12)
Amos (Amos 1:3)
Obadiah (Obadiah 1:1)
Micah (Micah 2:3)
Nahum (Nahum 1:12)
Zephaniah (Zephaniah 1:2)
Haggai (Haggai 1:5)
Zechariah (Zechariah 1:3)
Malachi (Malachi 1:2)
Even false prophets spoke this way (1 Kings 22:11).
New Testament: Revelation 1:8, Agabus used the expression, "The Holy Spirit says (Acts 21:10).