add validations to api availability