google script get name of google form

JavaScript
function onFormSubmit(e) {
	var user = {email: e.namedValues['Email address'][0], form: e.form.getPublishedUrl()};

	Logger.log("email is: " + user.email() + "\nForm link is : " + user.form);
}
Source

Also in JavaScript: