Endpoints resource [#78016138]

This may look strange, but the point is that it's possible to create endpoint with certificate. In that case there should be no error. Endpoint will be created with assigned IP address (catch all domains case). 

I've extracted this to a helper and will add comment so it's more clear.