Add api and models for alerts