add basicauth sample for JS client