api 1.0 compatible, started working on version 2.0