Skip to content

Instantly share code, notes, and snippets.

@nchudleigh
Last active August 22, 2016 15:11
Show Gist options
  • Save nchudleigh/8a758ec7dca64c4d1aa2d79fd81d6789 to your computer and use it in GitHub Desktop.
Save nchudleigh/8a758ec7dca64c4d1aa2d79fd81d6789 to your computer and use it in GitHub Desktop.
Capturing Signups with the GrowSumo Javascript Snippet
function yourSignupFunction(customerEmail, customerName, customerKey) {
/*
customer_key (string, required)
used to uniquely identify your customer
*/
growsumo.data.customer_key = customerKey;
/*
email (string, required)
email of the customer signing up
*/
growsumo.data.email = customerEmail;
/*
name (string, optional)
name of the customer signing up
*/
growsumo.data.name = customerName;
/*
Note that createSignup is an asynchonous call, and will
return immediately and call createSignupHandler when it
receives a response from GrowSumo's servers
*/
growsumo.createSignup(createSignupHandler);
};
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment