[api] move the webui engine classes into the api structure

This is the 2nd nail in the coffin of the webui