From 6a925c53542be033b9480f459b65b2aebb064671 Mon Sep 17 00:00:00 2001 From: ahkelly Date: Fri, 20 Jan 2017 16:47:29 -0500 Subject: [PATCH] Added new funtions for interest categories added getListInterestCategories(), getListInterestCategoryDetails(), getListInterestCategoryInterests(), getCampaigns(), getCampaignContent() --- src/mailchimp.cfc | 24 +++++++++++++++++++++++- 1 file changed, 23 insertions(+), 1 deletion(-) diff --git a/src/mailchimp.cfc b/src/mailchimp.cfc index be914a9..14bd1e6 100644 --- a/src/mailchimp.cfc +++ b/src/mailchimp.cfc @@ -1,6 +1,6 @@ /* * ColdFusion MailChimp API 3.0 wrapper -* v1.0.0 +* v1.0.1 * https://github.com/kevindb/cf-mailchimp * * ColdFusion wrapper for the MailChimp 3.0 API @@ -59,6 +59,28 @@ component displayname="MailChimp" { return get("lists/" & arguments.listId); } + // Retrieves a list of interest categories (group titles) for a specified list + public function getListInterestCategories( + required string listId + ) { + return get("lists/" & arguments.listId & "/interest-categories"); + } + + // Retrieves a details for an interest category for a specified list + public function getListInterestCategoryDetails( + required string listId + required string interestCategoryId + ) { + return get("lists/" & arguments.listId & "/interest-categories/" & arguments.interestCategoryId); + } + + // Retrieves interest for an interest category for a specified list + public function getListInterestCategoryInterests( + required string listId + required string interestCategoryId + ) { + return get("lists/" & arguments.listId & "/interest-categories/" & arguments.interestCategoryId & '/interests'); + } // MailChimp Member calls // http://developer.mailchimp.com/documentation/mailchimp/reference/lists/members/