Edit Campaign with template from API

Participant

Edit Campaign with template from API

Excuse the question, but I'm editing a campaign template from the API, modifying various data, pretend not modify the fields and text_content email_content already defined in the template, but the edition I send the message:

 

Array
(
    [0] => Array
        (
            [error_key] => json.regex.mismatch.email_content
            [error_message] => #/email_content: This attribute value must be of the format '...'
        )

)

 

I need to edit this template with fields subject, from_mail, message_Footer, but not modify these fields.

As I send these fields:

 

 

/*$micamp->text_content = $_POST['text_content'];
$micamp->email_content = $_POST['email_content'];
$micamp->email_content_format = $_POST['format'];
$micamp->template_type = "CUSTOM";  // "STOCK"; //"CUSTOM";  ???*/

1 REPLY 1
Member

Hello,

 

Thanks for posting on the forums.  I'm not quite sure why you are getting the error.  Can you provide a more complete code snippet or the body of the request that is returning the error?  Feel free to PM me.

 

Regards,

 

Andrew B.

Constant Contact, API Support

Developer Portal

View API documentation, code samples, get your API key.

Visit Page