The Mahdi is a Mursal according to both Sunni and Shiite hadiths.
There is three things God sends Mursaleen with, Nubuwa and Resalah and Ayat in form of miracles.
Nubuwa means receiving news/information from God, it means, he received a book from God but the book is not the Prophet's task, he recites it, but it's God who reveals and he is the recipient of the revelation to humanity from God.
Resalah is the clear balagha and this is the role of God's trustees when people don't know the truth and need to be reminded.
Ayat in form of miracles is the truth to them, humans response over all has been to it that it's sorcery.
Aside from what God sends them with, he also tasked them with being witnesses and Guides and leaders who guide by his command and intercede by his permission and help by his permission and are stars and lights in the sky of this world.
And aside from that is they rule on God's behalf and represent him and judge by what he reveals and try to set the earth aright and fix believers and bring justice as much as they can to this world.
Messengers after Moses' would be needed if people turn aside from the successors of Moses' as Captains, then they become Messengers, because the truth needs to be revived.
The Ulil-Amr in 4:59 would all become Messengers if people differ and dispute regarding the religion, otherwise, it's not needed and they can just be Authorities.
The case when a Nabi is not a Rasool is a rare case when Resalah is not needed and instead God reveals a book to further enlighten them and confirm and continue to talk to humanity, but no need of that Nabi clarifying the clear truth because it's there.
The case when a Rasool is not a Nabi, is when the conditions to safeguard a book for them are not there, and instead it's better off they clarify the truth and convey the clear message, without a book received by them from them to safeguard.
The Mahdi is yet to be a Messenger, and his predecessors all became Messengers because the conditions came.
Nubuwa is receiving revelation from God to the people and is about recitations from God or books from God.
The reason God stopped Nubuwa is out of wisdom and grace, it has advantage but also disadvantages. The disadvantages is there is no reaction to real time from God's words anymore.
The advantage is despite leaving the clear message and abandoning the true light of the Quran, the Quran remains intact and agreed upon and there no argument of what is revelation from God and what isn't.
And so the Mahdi will not bring a new book but in some ways, his interpretation and translation of Quran, it will be as if the Quran is a new book. Also with programming the Quran of Ali can show dynamically how the Quran was built over the period of 23 years.
While Quran of Ali (a) would be hard to study in the past, because, you would lose track of time and dates of each verse. Put in a program now, and it will be a good study tool.
So this will be a key thing, the commentary from God and his Messenger and Ahlulbayt (a) pertaining to the Quran as well as how it was dynamically built over the period of 23 years, will be awesome.
And the way the Sunnah and Quran went together in this regard will become clear.