added index to api