def get_endpoint_by_subscriber_id_and_protocol(<EOL>self, subscriber_id, protocol):
self._validate_subscriber_id(subscriber_id)<EOL>self._validate_endpoint_protocol(protocol)<EOL>url = "<STR_LIT>".format(<EOL>subscriber_id, protocol)<EOL>response = NWS_DAO().getURL(url, self._read_headers)<EOL>if response.status != <NUM_LIT:200>:<EOL><INDENT>raise DataFailureException(url, response.status, response.data)<EOL><DEDENT>data = json.loads(response.data)<EOL>try:<EOL><INDENT>return self._endpoint_from_json(data.get("<STR_LIT>")[<NUM_LIT:0>])<EOL><DEDENT>except IndexError:<EOL><INDENT>raise DataFailureException(url, <NUM_LIT>, "<STR_LIT>")<EOL><DEDENT>
Get an endpoint by subscriber_id and protocol