Extract method for creating the service url

Signed-off-by: Igor Popov <igor.popov89@gmail.com>