We usually postulate the principle of least action. Then we can get Lagrangian mechanics. After that we can get Hamiltonian mechanics either from postulate or from the equivalent Lagrangian mechanics. Finally we get the Hamilton-Jacobi equation (HJE).
But what if we have HJE as postulate instead? How can we get Hamiltonian mechanics from it?