Ajax in AngualarJS

Tried Ajax in Angualar and promises api provided in Angualr for success and error