ToolForm: Move dictionary building methods from mako to api.