ActiveCampaign / activecampaign-api-nodejs

Node.js wrapper for the ActiveCampaign API
MIT License
39 stars 36 forks source link

after contact added successfully in active campaign send welcome email to that contact into nodejs #67

Open dharmishtha-chhatrodiya opened 2 years ago

dharmishtha-chhatrodiya commented 2 years ago

var mailUrl = new ActiveCampaign( "https://URL.api-us1.com", "KEY" ); var contact = { email: "john@gmail.com", first_name: "john", last_name: "deo", phone: 7878787788, }; var contact_add = mailUrl.api("contact/add", contact); contact_add.then( function (result) { console.log("success result", result); }, function (result) { console.log("fail result", result); } );

// after contact added successfully in active campaign send welcome email to that contact