add rudimentary pg apis