API js fix and annotations