update api fix issue #1