add features to api
+ ts use function to main.js