added v2_inventory and seperated the query class