Unfortunately, no, I don’t believe it’s possible in the API. Please contact Constant Contact with that question!
Thread Starter
jon182
(@brody182)
Ah, thanks! Yes, I forgot about that.
So yeah, it’s possible using the plugin, but not built in. You can have someone at fiverr.com or codeable.io help you write something to display them—I’m afraid I don’t have the availability to do that now.
Here’s a start, though:
// Make sure to call this after the plugins_loaded action:
$campaigns = WP_CTCT::getInstance()->cc->getAllEmailCampaigns();
// Then process the campaigns below
Thread Starter
jon182
(@brody182)
maybe you can give me a hint, i’m trying to pull the email campaigns in a json file like this
https://api.constantcontact.com/v2/emailmarketing/campaigns?status=SENT&api_key=xxxxxxxxxxxxxxxxxxxxxxx
bit its telling me “unauthorized” do i need to add something else in the url?
Thread Starter
jon182
(@brody182)
never mind I cant use JavaScript anyway
Yeah, authentication’s now that simple…requires OAuth token. That’s why I suggest using the code above.
Thread Starter
jon182
(@brody182)
if i add that code to your plugin, how do i display the list of campaigns on a page? do i need to create a shortcode?
That’s not complete code at all, and shouldn’t be added to the plugin; create another plugin. That’s just a start for a developer to work with. Please get in touch with the services I recommended; they’ll be able to help.