Skip to main content

Mailchimp Python connector

dex-connector-intuit-mailchimp v0.2.1 implements the Mailchimp Marketing API getMember, listMembers, upsertMember, updateMemberTags, and sendCampaign operations as typed Dex Steps, and the memberChanged poll Trigger. It requires dex-connectors-sdk 0.12.0 or later, the release of the poll Trigger kit. The manifest generates their models, definitions, connection bindings, Step factories, and mocks. The provider client and operation invocations are hand written. sendCampaign sends under the SDK single-dispatch fence with max_sends=call.max_sends (3 by default), reads campaign status before every send, resends an unknown outcome only while the campaign is still a draft and the cap allows, and selects uncertain at the cap; see the connector README.

Use in a Flow

The runnable contact read example binds the static mailchimp-audience connection through Dex project configuration, reads an audience contact, and persists its safe result. Its input is a Mailchimp audience ID and bare email address. The key stays in Dex Web Connections and is resolved at each provider call; it is never a Flow input or Attribute. Contact operations reject malformed bare addresses before contacting Mailchimp. Malformed contact reads and campaign responses select invalidResponse; a malformed answer to upsertMember or updateMemberTags is retried.

From this directory:

uv sync --locked
DEX_CONNECTOR_CONFIG_FILE=/path/to/connections.json uv run python -m examples.get_member.main
DEX_CONNECTOR_CONFIG_FILE=/path/to/connections.json uv run python -m examples.get_member.start \
  mailchimp-contact-001 examples/get_member/sample-input.json

The connection form has two visible values: api_key and the optional maxResponseBytes. The manifest authorization guide links to Mailchimp's API keys page and explains creation, suffix format, secrecy, rotation, and revoke. The response limit is bytes; leaving it blank keeps the displayed default. The contact example has no operation-specific configuration unit.

memberChanged Trigger

memberChanged delivers each contact added to or changed in one audience, at behavior parity with the Go connector; the connector README describes the baseline, lookback, paging, event IDs, status filter, rate limits, and cursor resets. The poll cursor token, the keyed snapshot entries, and the Trigger event IDs match Go byte for byte, so Go and Python replicas share one cursor document and one Trigger inbox; tests/test_member_changed_go_parity.py replays a recording of the Go fetcher, including HTML-escaped and non-ASCII merge fields, numbers in exponent form, reordered tags, paging by time and by offset, and every failure class.

  • new_project_member_trigger_runner(project, connection, routes) loads each binding's saved audienceId and statuses and records each change in the binding's project Trigger inbox before its cursor commits, as examples/member_changed/worker.py does. A binding without a saved audience raises ValueError.
  • new_member_trigger_runner(connection, routes) takes MemberChangedTriggerRoute values with a configuration, a target, and an optional cursor store.
  • new_member_changed_trigger(...) keeps its cursor in memory, like Go's generated NewMemberChangedTrigger, so it records a new baseline on every start.

The connection's pollInterval (Config.poll_interval_seconds, at least 5 seconds) sets the delay between polls; Client raises ValueError below it. The runner sends one request at a time for every binding of a connection. A 429, or a 403 without an error document, is mark_rate_limited with Retry-After; a 400 for the poll query, an undecodable cursor, or a cursor for another audience is mark_cursor_invalid, which records a new baseline.

The member_changed example starts one MailchimpMemberChangePython Flow per change and reads the contact back with new_get_member_step.

Verify

uv run ruff check .
uv run mypy --strict src tests examples
uv run pytest tests
DEX_FLOW_SERVICE_ADDRESS=127.0.0.1:8801 uv run pytest examples/member_changed/integration_test.py

From the repository root, make test-connector-conformance CONNECTOR_DIRECTORY=connectors/intuit/mailchimp replays the Go-recorded provider scenarios against this package. They cover each branch, malformed addresses and provider bodies, final 429 and 5xx retries, transport failure, complete input fields, a resend below the send cap, read-back of an earlier send, campaign uncertainty at the cap, and a pre-fence checkpoint. With an isolated Dex development server, DEX_FLOW_SERVICE_ADDRESS=127.0.0.1:25401 uv run pytest examples/get_member/integration_test.py exercises the real Worker and Client with a local provider stand-in.

No live Mailchimp account was used for this port. Bearer authorization, the live API responses and error titles, contact and tag idempotency, and campaign send state transitions remain unverified against Mailchimp itself, as do the Trigger's live assumptions: whether since_last_changed is exclusive at one-second resolution, how soon a change becomes listable, and whether Mailchimp ever sends Retry-After.

Metadata

Release files for dex-connector-intuit-mailchimp 0.2.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for dex-connector-intuit-mailchimp 0.2.1
File Size Uploaded Provenance Actions
dex_connector_intuit_mailchimp-0.2.1.tar.gz 167.2 kB Without provenance Details for dex_connector_intuit_mailchimp-0.2.1.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for dex-connector-intuit-mailchimp 0.2.1
File Interpreter ABI Platform Actions
dex_connector_intuit_mailchimp-0.2.1-py3-none-any.whl Python 3 none any Details for dex_connector_intuit_mailchimp-0.2.1-py3-none-any.whl

Total release size: 219.3 kB

Release files / dex_connector_intuit_mailchimp-0.2.1.tar.gz

Download URL dex_connector_intuit_mailchimp-0.2.1.tar.gz
Size 167.2 kB
Tags Source
SHA-256 checksum
How to use checksums
6bcd71086578b256ceb6ddd9ed25a19ddc8a79849ee0ad5f0fdf747325c3089b
BLAKE2b-256 checksum
How to use checksums
c33acd934d8ed886517a2e61e87f71d3251a48ea45a429033698afe990dde3b4
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.13.9 {"installer":{"name":"uv","version":"0.13.9","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"26.04","id":"resolute","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Release files / dex_connector_intuit_mailchimp-0.2.1-py3-none-any.whl

Download URL dex_connector_intuit_mailchimp-0.2.1-py3-none-any.whl
Size 52.1 kB
Tags Python 3
SHA-256 checksum
How to use checksums
e9022188f3767a747a73fc4e0e9000fb03e0e45868e3046621c04200bb4e213a
BLAKE2b-256 checksum
How to use checksums
b06938996a4e2faa26f1ffd9e2bff54e45dfde38df8e5c2caaa03389f2af8110
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.13.9 {"installer":{"name":"uv","version":"0.13.9","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"26.04","id":"resolute","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Security for dex-connector-intuit-mailchimp 0.2.1

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page