[api] add billingtype consts
some code cleanups.