remove externalInterface, handle index for array and object