working on bag api and model