Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cannot assign personalized merge tags to "To: field, such as *|FNAME|* #244

Open
tan-yong-sheng opened this issue Jun 14, 2022 · 0 comments

Comments

@tan-yong-sheng
Copy link

tan-yong-sheng commented Jun 14, 2022

First of all, appreciate the works. This library is indeed helpful.

It works when I tried to create an email campaign in Mailchimp, but I have still some problems I have faced

(1) Campaign name cannot be set different from subject line
(2) Cannot personalize To Field with merge tags, e.g., |FNAME|
(3) Cannot create preview text.
(4) can i programmatically upload image to mailchimp server and then get the image link?

image

Below is the function I have used to created to create mailchimp campaign.

def campaign_creation_function(campaign_name, audience_id, from_name, reply_to, client):
    campaign_name = campaign_name
    audience_id = audience_id
    from_name = from_name
    reply_to = reply_to

    data = {
        "recipients" :
        {
            "list_id": audience_id
        },
        "settings":
        {
            "subject_line": campaign_name,
            "from_name": from_name,
            "reply_to": reply_to
        },
        "type": "regular"
    }

    new_campaign = client.campaigns.create(data=data)
    
    return new_campaign
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant