update documentation:
- removed older apis
- updated js snippet