Javasript API for Scripted