Added javascript helper API