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

Send campaign immediately #24

Closed
mgax opened this issue May 15, 2024 · 0 comments · Fixed by #37
Closed

Send campaign immediately #24

mgax opened this issue May 15, 2024 · 0 comments · Fixed by #37
Assignees

Comments

@mgax
Copy link
Member

mgax commented May 15, 2024

When a newsletter page is ready, and the author has presumably sent a test email to themselves, it should be possible to trigger campaign sending.

Add a method to MailchimpCampaignBackend named send_campaign(campaign_id: str). It should call the Mailchimp client's client.campaigns.send method.

In the page editor, on the newsletter tab, when the user clicks Send campaign, it should:

  1. Call the campaign backend's save_campaign method, so that Mailchimp has the latest content.
  2. Call the campaign backend's send_campaign method, to send the campaign.

If the API calls are successful, the server should redirect to the page editor, where the "Newsletter" tab will show the campaign sending status.

If the API calls return errors, they should be sent as a message (using the wagtail.admin.messages framework).

@mgax mgax self-assigned this Jun 17, 2024
This was referenced Jun 17, 2024
@mgax mgax closed this as completed in #37 Jun 20, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Done
Development

Successfully merging a pull request may close this issue.

1 participant