[REFACTOR] integration with Widget API codebase