The duty to consult is jurisprudential. There's definitely a legal foundation for this, but you have to find it in case law. You have to read, for example, the DesRochers or the Haida Nation decisions made by the Supreme Court of Canada.
The amendment is drafted to reflect what the Supreme Court of Canada explained in those decisions. It's not invented. It definitely has a legal and constitutional foundation, in fact, but it's novel in the sense that there is no amendment of this type elsewhere.