Why return both?  T'would be nicer to have just one object representing the endpoint (you might look at SimpleDelegator in the stdlib for how to handle this neatly).