Custom Settings Pages saving in API and surrounding code for #693
Fixes #1037