matimo-mailchimp 0.1.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- matimo_mailchimp-0.1.0/.gitignore +63 -0
- matimo_mailchimp-0.1.0/PKG-INFO +112 -0
- matimo_mailchimp-0.1.0/README.md +98 -0
- matimo_mailchimp-0.1.0/pyproject.toml +27 -0
- matimo_mailchimp-0.1.0/src/matimo_mailchimp/__init__.py +17 -0
- matimo_mailchimp-0.1.0/src/matimo_mailchimp/tools/mailchimp-add-list-member/definition.yaml +117 -0
- matimo_mailchimp-0.1.0/src/matimo_mailchimp/tools/mailchimp-create-campaign/definition.yaml +125 -0
- matimo_mailchimp-0.1.0/src/matimo_mailchimp/tools/mailchimp-get-list-members/definition.yaml +101 -0
- matimo_mailchimp-0.1.0/src/matimo_mailchimp/tools/mailchimp-get-lists/definition.yaml +81 -0
- matimo_mailchimp-0.1.0/src/matimo_mailchimp/tools/mailchimp-remove-list-member/definition.yaml +64 -0
- matimo_mailchimp-0.1.0/src/matimo_mailchimp/tools/mailchimp-send-campaign/definition.yaml +59 -0
- matimo_mailchimp-0.1.0/src/matimo_mailchimp/tools/mailchimp-update-list-member/definition.yaml +105 -0
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
# Dependencies
|
|
2
|
+
**/node_modules/
|
|
3
|
+
package-lock.json
|
|
4
|
+
yarn.lock
|
|
5
|
+
|
|
6
|
+
# Build output
|
|
7
|
+
**/dist/
|
|
8
|
+
*.tsbuildinfo
|
|
9
|
+
|
|
10
|
+
# Python compiled / build
|
|
11
|
+
**/__pycache__/
|
|
12
|
+
*.py[cod]
|
|
13
|
+
*$py.class
|
|
14
|
+
*.egg-info/
|
|
15
|
+
*.egg
|
|
16
|
+
**/build/
|
|
17
|
+
**/.eggs/
|
|
18
|
+
**/.venv/
|
|
19
|
+
**/.mypy_cache/
|
|
20
|
+
**/.ruff_cache/
|
|
21
|
+
**/.pytest_cache/
|
|
22
|
+
|
|
23
|
+
# Test coverage
|
|
24
|
+
**/coverage/
|
|
25
|
+
**/.nyc_output/
|
|
26
|
+
|
|
27
|
+
# IDE
|
|
28
|
+
.vscode/
|
|
29
|
+
.idea/
|
|
30
|
+
*.swp
|
|
31
|
+
*.swo
|
|
32
|
+
*~
|
|
33
|
+
.DS_Store
|
|
34
|
+
|
|
35
|
+
# Environment
|
|
36
|
+
.env
|
|
37
|
+
.env.local
|
|
38
|
+
.env.*.local
|
|
39
|
+
|
|
40
|
+
# Logs
|
|
41
|
+
*.log
|
|
42
|
+
npm-debug.log*
|
|
43
|
+
yarn-debug.log*
|
|
44
|
+
yarn-error.log*
|
|
45
|
+
|
|
46
|
+
# OS
|
|
47
|
+
.DS_Store
|
|
48
|
+
Thumbs.db
|
|
49
|
+
|
|
50
|
+
# Temporary files
|
|
51
|
+
tmp/
|
|
52
|
+
temp/
|
|
53
|
+
*.tmp
|
|
54
|
+
typescript/examples/mcp/matimo-tools/.matimo-approvals.json
|
|
55
|
+
typescript/examples/mcp/matimo-tools/fetch-weather/definition.yaml
|
|
56
|
+
typescript/examples/mcp/matimo-tools/npm_downloads/definition.yaml
|
|
57
|
+
typescript/examples/mcp/matimo-tools/skills/ecosystem-health/SKILL.md
|
|
58
|
+
typescript/examples/mcp/matimo-tools/skills/matimo-health-check/SKILL.md
|
|
59
|
+
typescript/examples/mcp/matimo-tools/skills/moltbook-identity/SKILL.md
|
|
60
|
+
typescript/packages/cli/.matimo/certs/server.crt
|
|
61
|
+
typescript/packages/cli/.matimo/certs/server.key
|
|
62
|
+
typescript/examples/mcp/.matimo/certs/server.crt
|
|
63
|
+
typescript/examples/mcp/.matimo/certs/server.key
|
|
@@ -0,0 +1,112 @@
|
|
|
1
|
+
Metadata-Version: 2.4
|
|
2
|
+
Name: matimo-mailchimp
|
|
3
|
+
Version: 0.1.0
|
|
4
|
+
Summary: Matimo provider — Mailchimp tools (campaigns, lists, members)
|
|
5
|
+
License: MIT
|
|
6
|
+
Keywords: agents,ai,mailchimp,matimo,tools
|
|
7
|
+
Classifier: Development Status :: 4 - Beta
|
|
8
|
+
Classifier: Intended Audience :: Developers
|
|
9
|
+
Classifier: License :: OSI Approved :: MIT License
|
|
10
|
+
Classifier: Programming Language :: Python :: 3.11
|
|
11
|
+
Requires-Python: >=3.11
|
|
12
|
+
Requires-Dist: matimo-core<0.2.0,>=0.1.0
|
|
13
|
+
Description-Content-Type: text/markdown
|
|
14
|
+
|
|
15
|
+
# matimo-mailchimp
|
|
16
|
+
|
|
17
|
+
> Mailchimp tools for [Matimo](https://matimo.dev) — manage campaigns, lists, and subscribers.
|
|
18
|
+
|
|
19
|
+
[](https://pypi.org/project/matimo-mailchimp/)
|
|
20
|
+
[](https://matimo.dev/docs)
|
|
21
|
+
|
|
22
|
+
---
|
|
23
|
+
|
|
24
|
+
## Installation
|
|
25
|
+
|
|
26
|
+
```bash
|
|
27
|
+
pip install matimo matimo-mailchimp
|
|
28
|
+
```
|
|
29
|
+
|
|
30
|
+
---
|
|
31
|
+
|
|
32
|
+
## Available Tools (7 Total)
|
|
33
|
+
|
|
34
|
+
| Tool | Description |
|
|
35
|
+
|------|-------------|
|
|
36
|
+
| `mailchimp-get-lists` | List all audiences (lists) in your account |
|
|
37
|
+
| `mailchimp-get-list-members` | Get subscribers in an audience |
|
|
38
|
+
| `mailchimp-add-list-member` | Subscribe an email address to an audience |
|
|
39
|
+
| `mailchimp-update-list-member` | Update subscriber tags, status, or merge fields |
|
|
40
|
+
| `mailchimp-remove-list-member` | Unsubscribe or archive a list member |
|
|
41
|
+
| `mailchimp-create-campaign` | Create a new email campaign |
|
|
42
|
+
| `mailchimp-send-campaign` | Send a campaign to its audience |
|
|
43
|
+
|
|
44
|
+
---
|
|
45
|
+
|
|
46
|
+
## Quick Start
|
|
47
|
+
|
|
48
|
+
```python
|
|
49
|
+
import asyncio
|
|
50
|
+
import os
|
|
51
|
+
from matimo import Matimo
|
|
52
|
+
from matimo_mailchimp import get_tools_path
|
|
53
|
+
|
|
54
|
+
async def main():
|
|
55
|
+
matimo = await Matimo.init(get_tools_path())
|
|
56
|
+
|
|
57
|
+
# List all audiences
|
|
58
|
+
lists = await matimo.execute('mailchimp-get-lists', {})
|
|
59
|
+
print(lists)
|
|
60
|
+
|
|
61
|
+
# Add a subscriber
|
|
62
|
+
await matimo.execute('mailchimp-add-list-member', {
|
|
63
|
+
'list_id': 'abc123def',
|
|
64
|
+
'email_address': 'new@example.com',
|
|
65
|
+
'status': 'subscribed',
|
|
66
|
+
'merge_fields': {'FNAME': 'Jane', 'LNAME': 'Doe'},
|
|
67
|
+
})
|
|
68
|
+
|
|
69
|
+
# Create and send a campaign
|
|
70
|
+
campaign = await matimo.execute('mailchimp-create-campaign', {
|
|
71
|
+
'list_id': 'abc123def',
|
|
72
|
+
'subject_line': 'April Newsletter',
|
|
73
|
+
'from_name': 'My Company',
|
|
74
|
+
'reply_to': 'hello@example.com',
|
|
75
|
+
})
|
|
76
|
+
await matimo.execute('mailchimp-send-campaign', {
|
|
77
|
+
'campaign_id': campaign['id'],
|
|
78
|
+
})
|
|
79
|
+
|
|
80
|
+
asyncio.run(main())
|
|
81
|
+
```
|
|
82
|
+
|
|
83
|
+
---
|
|
84
|
+
|
|
85
|
+
## Authentication
|
|
86
|
+
|
|
87
|
+
```bash
|
|
88
|
+
export MAILCHIMP_API_KEY="your-api-key-us1" # includes datacenter suffix
|
|
89
|
+
export MAILCHIMP_SERVER_PREFIX="us1" # datacenter prefix from your API key
|
|
90
|
+
```
|
|
91
|
+
|
|
92
|
+
### Getting Mailchimp API Credentials
|
|
93
|
+
|
|
94
|
+
1. Log in to [Mailchimp](https://mailchimp.com) → **Profile** → **Extras** → **API keys**
|
|
95
|
+
2. Click **Create A Key**
|
|
96
|
+
3. Copy the API key — the suffix (`us1`, `us6`, etc.) is your server prefix
|
|
97
|
+
|
|
98
|
+
---
|
|
99
|
+
|
|
100
|
+
## Documentation
|
|
101
|
+
|
|
102
|
+
- [Mailchimp Marketing API](https://mailchimp.com/developer/marketing/api/)
|
|
103
|
+
- [Python Examples](https://github.com/tallclub/matimo/tree/main/python/examples/native/mailchimp)
|
|
104
|
+
|
|
105
|
+
---
|
|
106
|
+
|
|
107
|
+
## Links
|
|
108
|
+
|
|
109
|
+
- **PyPI:** https://pypi.org/project/matimo-mailchimp/
|
|
110
|
+
- **GitHub:** https://github.com/tallclub/matimo
|
|
111
|
+
- **Mailchimp Developer Docs:** https://mailchimp.com/developer/
|
|
112
|
+
|
|
@@ -0,0 +1,98 @@
|
|
|
1
|
+
# matimo-mailchimp
|
|
2
|
+
|
|
3
|
+
> Mailchimp tools for [Matimo](https://matimo.dev) — manage campaigns, lists, and subscribers.
|
|
4
|
+
|
|
5
|
+
[](https://pypi.org/project/matimo-mailchimp/)
|
|
6
|
+
[](https://matimo.dev/docs)
|
|
7
|
+
|
|
8
|
+
---
|
|
9
|
+
|
|
10
|
+
## Installation
|
|
11
|
+
|
|
12
|
+
```bash
|
|
13
|
+
pip install matimo matimo-mailchimp
|
|
14
|
+
```
|
|
15
|
+
|
|
16
|
+
---
|
|
17
|
+
|
|
18
|
+
## Available Tools (7 Total)
|
|
19
|
+
|
|
20
|
+
| Tool | Description |
|
|
21
|
+
|------|-------------|
|
|
22
|
+
| `mailchimp-get-lists` | List all audiences (lists) in your account |
|
|
23
|
+
| `mailchimp-get-list-members` | Get subscribers in an audience |
|
|
24
|
+
| `mailchimp-add-list-member` | Subscribe an email address to an audience |
|
|
25
|
+
| `mailchimp-update-list-member` | Update subscriber tags, status, or merge fields |
|
|
26
|
+
| `mailchimp-remove-list-member` | Unsubscribe or archive a list member |
|
|
27
|
+
| `mailchimp-create-campaign` | Create a new email campaign |
|
|
28
|
+
| `mailchimp-send-campaign` | Send a campaign to its audience |
|
|
29
|
+
|
|
30
|
+
---
|
|
31
|
+
|
|
32
|
+
## Quick Start
|
|
33
|
+
|
|
34
|
+
```python
|
|
35
|
+
import asyncio
|
|
36
|
+
import os
|
|
37
|
+
from matimo import Matimo
|
|
38
|
+
from matimo_mailchimp import get_tools_path
|
|
39
|
+
|
|
40
|
+
async def main():
|
|
41
|
+
matimo = await Matimo.init(get_tools_path())
|
|
42
|
+
|
|
43
|
+
# List all audiences
|
|
44
|
+
lists = await matimo.execute('mailchimp-get-lists', {})
|
|
45
|
+
print(lists)
|
|
46
|
+
|
|
47
|
+
# Add a subscriber
|
|
48
|
+
await matimo.execute('mailchimp-add-list-member', {
|
|
49
|
+
'list_id': 'abc123def',
|
|
50
|
+
'email_address': 'new@example.com',
|
|
51
|
+
'status': 'subscribed',
|
|
52
|
+
'merge_fields': {'FNAME': 'Jane', 'LNAME': 'Doe'},
|
|
53
|
+
})
|
|
54
|
+
|
|
55
|
+
# Create and send a campaign
|
|
56
|
+
campaign = await matimo.execute('mailchimp-create-campaign', {
|
|
57
|
+
'list_id': 'abc123def',
|
|
58
|
+
'subject_line': 'April Newsletter',
|
|
59
|
+
'from_name': 'My Company',
|
|
60
|
+
'reply_to': 'hello@example.com',
|
|
61
|
+
})
|
|
62
|
+
await matimo.execute('mailchimp-send-campaign', {
|
|
63
|
+
'campaign_id': campaign['id'],
|
|
64
|
+
})
|
|
65
|
+
|
|
66
|
+
asyncio.run(main())
|
|
67
|
+
```
|
|
68
|
+
|
|
69
|
+
---
|
|
70
|
+
|
|
71
|
+
## Authentication
|
|
72
|
+
|
|
73
|
+
```bash
|
|
74
|
+
export MAILCHIMP_API_KEY="your-api-key-us1" # includes datacenter suffix
|
|
75
|
+
export MAILCHIMP_SERVER_PREFIX="us1" # datacenter prefix from your API key
|
|
76
|
+
```
|
|
77
|
+
|
|
78
|
+
### Getting Mailchimp API Credentials
|
|
79
|
+
|
|
80
|
+
1. Log in to [Mailchimp](https://mailchimp.com) → **Profile** → **Extras** → **API keys**
|
|
81
|
+
2. Click **Create A Key**
|
|
82
|
+
3. Copy the API key — the suffix (`us1`, `us6`, etc.) is your server prefix
|
|
83
|
+
|
|
84
|
+
---
|
|
85
|
+
|
|
86
|
+
## Documentation
|
|
87
|
+
|
|
88
|
+
- [Mailchimp Marketing API](https://mailchimp.com/developer/marketing/api/)
|
|
89
|
+
- [Python Examples](https://github.com/tallclub/matimo/tree/main/python/examples/native/mailchimp)
|
|
90
|
+
|
|
91
|
+
---
|
|
92
|
+
|
|
93
|
+
## Links
|
|
94
|
+
|
|
95
|
+
- **PyPI:** https://pypi.org/project/matimo-mailchimp/
|
|
96
|
+
- **GitHub:** https://github.com/tallclub/matimo
|
|
97
|
+
- **Mailchimp Developer Docs:** https://mailchimp.com/developer/
|
|
98
|
+
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
[build-system]
|
|
2
|
+
requires = ["hatchling"]
|
|
3
|
+
build-backend = "hatchling.build"
|
|
4
|
+
|
|
5
|
+
[project]
|
|
6
|
+
name = "matimo-mailchimp"
|
|
7
|
+
version = "0.1.0"
|
|
8
|
+
description = "Matimo provider — Mailchimp tools (campaigns, lists, members)"
|
|
9
|
+
readme = "README.md"
|
|
10
|
+
license = { text = "MIT" }
|
|
11
|
+
requires-python = ">=3.11"
|
|
12
|
+
keywords = ["ai", "tools", "agents", "matimo", "mailchimp"]
|
|
13
|
+
classifiers = [
|
|
14
|
+
"Development Status :: 4 - Beta",
|
|
15
|
+
"Intended Audience :: Developers",
|
|
16
|
+
"License :: OSI Approved :: MIT License",
|
|
17
|
+
"Programming Language :: Python :: 3.11",
|
|
18
|
+
]
|
|
19
|
+
dependencies = [
|
|
20
|
+
"matimo-core>=0.1.0,<0.2.0",
|
|
21
|
+
]
|
|
22
|
+
|
|
23
|
+
[project.entry-points."matimo.providers"]
|
|
24
|
+
mailchimp = "matimo_mailchimp:get_tools_path"
|
|
25
|
+
|
|
26
|
+
[tool.hatch.build.targets.wheel]
|
|
27
|
+
packages = ["src/matimo_mailchimp"]
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
"""Matimo mailchimp provider — exposes the path to YAML tool definitions."""
|
|
2
|
+
from __future__ import annotations
|
|
3
|
+
|
|
4
|
+
import importlib.resources
|
|
5
|
+
from pathlib import Path
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
def get_tools_path() -> str:
|
|
9
|
+
"""Return the absolute path to the bundled mailchimp tool definitions."""
|
|
10
|
+
try:
|
|
11
|
+
ref = importlib.resources.files("matimo_mailchimp") / "tools"
|
|
12
|
+
return str(ref)
|
|
13
|
+
except Exception:
|
|
14
|
+
return str(Path(__file__).parent / "tools")
|
|
15
|
+
|
|
16
|
+
|
|
17
|
+
__all__ = ["get_tools_path"]
|
|
@@ -0,0 +1,117 @@
|
|
|
1
|
+
name: mailchimp-add-list-member
|
|
2
|
+
version: '1.0.0'
|
|
3
|
+
description: >
|
|
4
|
+
Add a new subscriber to a Mailchimp audience (list). Use this to subscribe
|
|
5
|
+
a contact to receive email campaigns. Supports setting merge fields (first name, last name)
|
|
6
|
+
and tags for segmentation.
|
|
7
|
+
|
|
8
|
+
parameters:
|
|
9
|
+
server_prefix:
|
|
10
|
+
type: string
|
|
11
|
+
required: true
|
|
12
|
+
description: >
|
|
13
|
+
Your Mailchimp data center prefix (e.g. "us6"). Found at the end of your API key:
|
|
14
|
+
"abc123-us6" → server_prefix is "us6".
|
|
15
|
+
list_id:
|
|
16
|
+
type: string
|
|
17
|
+
required: true
|
|
18
|
+
description: The unique ID of the Mailchimp audience/list to add the member to
|
|
19
|
+
email_address:
|
|
20
|
+
type: string
|
|
21
|
+
required: true
|
|
22
|
+
description: The email address of the subscriber to add
|
|
23
|
+
status:
|
|
24
|
+
type: string
|
|
25
|
+
required: true
|
|
26
|
+
description: >
|
|
27
|
+
Subscriber status: "subscribed" (opted in), "unsubscribed" (opted out),
|
|
28
|
+
"pending" (requires email confirmation), or "cleaned" (invalid email)
|
|
29
|
+
enum:
|
|
30
|
+
- subscribed
|
|
31
|
+
- unsubscribed
|
|
32
|
+
- pending
|
|
33
|
+
- cleaned
|
|
34
|
+
merge_fields:
|
|
35
|
+
type: object
|
|
36
|
+
required: false
|
|
37
|
+
description: >
|
|
38
|
+
Key-value pairs for merge fields such as FNAME (first name) and LNAME (last name).
|
|
39
|
+
Example: {"FNAME": "Jane", "LNAME": "Doe"}
|
|
40
|
+
tags:
|
|
41
|
+
type: array
|
|
42
|
+
required: false
|
|
43
|
+
description: Array of tag names to apply to the subscriber for segmentation
|
|
44
|
+
|
|
45
|
+
execution:
|
|
46
|
+
type: http
|
|
47
|
+
method: POST
|
|
48
|
+
url: 'https://{server_prefix}.api.mailchimp.com/3.0/lists/{list_id}/members'
|
|
49
|
+
headers:
|
|
50
|
+
Authorization: 'apikey {MAILCHIMP_API_KEY}'
|
|
51
|
+
Content-Type: application/json
|
|
52
|
+
body:
|
|
53
|
+
email_address: '{email_address}'
|
|
54
|
+
status: '{status}'
|
|
55
|
+
merge_fields: '{merge_fields}'
|
|
56
|
+
tags: '{tags}'
|
|
57
|
+
timeout: 30000
|
|
58
|
+
|
|
59
|
+
authentication:
|
|
60
|
+
type: api_key
|
|
61
|
+
location: header
|
|
62
|
+
name: Authorization
|
|
63
|
+
notes:
|
|
64
|
+
env: MAILCHIMP_API_KEY
|
|
65
|
+
|
|
66
|
+
output_schema:
|
|
67
|
+
type: object
|
|
68
|
+
properties:
|
|
69
|
+
success:
|
|
70
|
+
type: boolean
|
|
71
|
+
data:
|
|
72
|
+
type: object
|
|
73
|
+
properties:
|
|
74
|
+
id:
|
|
75
|
+
type: string
|
|
76
|
+
description: MD5 hash of the subscriber email (subscriber_hash)
|
|
77
|
+
email_address:
|
|
78
|
+
type: string
|
|
79
|
+
status:
|
|
80
|
+
type: string
|
|
81
|
+
merge_fields:
|
|
82
|
+
type: object
|
|
83
|
+
tags:
|
|
84
|
+
type: array
|
|
85
|
+
list_id:
|
|
86
|
+
type: string
|
|
87
|
+
timestamp_opt:
|
|
88
|
+
type: string
|
|
89
|
+
timestamp_signup:
|
|
90
|
+
type: string
|
|
91
|
+
|
|
92
|
+
error_handling:
|
|
93
|
+
retry: 2
|
|
94
|
+
backoff_type: exponential
|
|
95
|
+
initial_delay_ms: 500
|
|
96
|
+
|
|
97
|
+
examples:
|
|
98
|
+
- name: 'Subscribe a new contact'
|
|
99
|
+
params:
|
|
100
|
+
server_prefix: us6
|
|
101
|
+
list_id: abc123def4
|
|
102
|
+
email_address: jane@example.com
|
|
103
|
+
status: subscribed
|
|
104
|
+
merge_fields:
|
|
105
|
+
FNAME: Jane
|
|
106
|
+
LNAME: Doe
|
|
107
|
+
expected_result: 'Returns the new member record with id (subscriber_hash) and status'
|
|
108
|
+
- name: 'Add pending subscriber with tags'
|
|
109
|
+
params:
|
|
110
|
+
server_prefix: us6
|
|
111
|
+
list_id: abc123def4
|
|
112
|
+
email_address: pending@example.com
|
|
113
|
+
status: pending
|
|
114
|
+
tags:
|
|
115
|
+
- newsletter
|
|
116
|
+
- vip
|
|
117
|
+
expected_result: 'Returns member record with pending status awaiting confirmation'
|
|
@@ -0,0 +1,125 @@
|
|
|
1
|
+
name: mailchimp-create-campaign
|
|
2
|
+
version: '1.0.0'
|
|
3
|
+
description: >
|
|
4
|
+
Create a new Mailchimp email campaign. Supports regular, plaintext, RSS,
|
|
5
|
+
and A/B test variate campaign types. After creating, configure the campaign
|
|
6
|
+
content and use mailchimp-send-campaign to send it.
|
|
7
|
+
|
|
8
|
+
parameters:
|
|
9
|
+
server_prefix:
|
|
10
|
+
type: string
|
|
11
|
+
required: true
|
|
12
|
+
description: >
|
|
13
|
+
Your Mailchimp data center prefix (e.g. "us6"). Found at the end of your API key:
|
|
14
|
+
"abc123-us6" → server_prefix is "us6".
|
|
15
|
+
type:
|
|
16
|
+
type: string
|
|
17
|
+
required: true
|
|
18
|
+
description: >
|
|
19
|
+
Campaign type: "regular" (standard email), "plaintext" (text-only email),
|
|
20
|
+
"rss" (RSS-driven campaign), or "variate" (A/B test campaign)
|
|
21
|
+
enum:
|
|
22
|
+
- regular
|
|
23
|
+
- plaintext
|
|
24
|
+
- rss
|
|
25
|
+
- variate
|
|
26
|
+
list_id:
|
|
27
|
+
type: string
|
|
28
|
+
required: false
|
|
29
|
+
description: >
|
|
30
|
+
The unique ID of the Mailchimp audience/list to send this campaign to.
|
|
31
|
+
Required when type is "regular" or "plaintext".
|
|
32
|
+
subject_line:
|
|
33
|
+
type: string
|
|
34
|
+
required: false
|
|
35
|
+
description: The subject line for the campaign email
|
|
36
|
+
preview_text:
|
|
37
|
+
type: string
|
|
38
|
+
required: false
|
|
39
|
+
description: Preview text displayed after the subject line in email clients (max 150 chars)
|
|
40
|
+
title:
|
|
41
|
+
type: string
|
|
42
|
+
required: false
|
|
43
|
+
description: Internal title for the campaign (used to identify it in Mailchimp dashboard)
|
|
44
|
+
from_name:
|
|
45
|
+
type: string
|
|
46
|
+
required: false
|
|
47
|
+
description: The "From" name subscribers will see in their inbox
|
|
48
|
+
reply_to:
|
|
49
|
+
type: string
|
|
50
|
+
required: false
|
|
51
|
+
description: The reply-to email address for the campaign
|
|
52
|
+
|
|
53
|
+
execution:
|
|
54
|
+
type: http
|
|
55
|
+
method: POST
|
|
56
|
+
url: 'https://{server_prefix}.api.mailchimp.com/3.0/campaigns'
|
|
57
|
+
headers:
|
|
58
|
+
Authorization: 'apikey {MAILCHIMP_API_KEY}'
|
|
59
|
+
Content-Type: application/json
|
|
60
|
+
body:
|
|
61
|
+
type: '{type}'
|
|
62
|
+
recipients:
|
|
63
|
+
list_id: '{list_id}'
|
|
64
|
+
settings:
|
|
65
|
+
subject_line: '{subject_line}'
|
|
66
|
+
preview_text: '{preview_text}'
|
|
67
|
+
title: '{title}'
|
|
68
|
+
from_name: '{from_name}'
|
|
69
|
+
reply_to: '{reply_to}'
|
|
70
|
+
timeout: 30000
|
|
71
|
+
|
|
72
|
+
authentication:
|
|
73
|
+
type: api_key
|
|
74
|
+
location: header
|
|
75
|
+
name: Authorization
|
|
76
|
+
notes:
|
|
77
|
+
env: MAILCHIMP_API_KEY
|
|
78
|
+
|
|
79
|
+
output_schema:
|
|
80
|
+
type: object
|
|
81
|
+
properties:
|
|
82
|
+
success:
|
|
83
|
+
type: boolean
|
|
84
|
+
data:
|
|
85
|
+
type: object
|
|
86
|
+
properties:
|
|
87
|
+
id:
|
|
88
|
+
type: string
|
|
89
|
+
description: Unique campaign ID (use this with mailchimp-send-campaign)
|
|
90
|
+
type:
|
|
91
|
+
type: string
|
|
92
|
+
status:
|
|
93
|
+
type: string
|
|
94
|
+
description: Campaign status (save, paused, schedule, sending, sent)
|
|
95
|
+
settings:
|
|
96
|
+
type: object
|
|
97
|
+
recipients:
|
|
98
|
+
type: object
|
|
99
|
+
|
|
100
|
+
error_handling:
|
|
101
|
+
retry: 2
|
|
102
|
+
backoff_type: exponential
|
|
103
|
+
initial_delay_ms: 500
|
|
104
|
+
|
|
105
|
+
examples:
|
|
106
|
+
- name: 'Create a regular campaign'
|
|
107
|
+
params:
|
|
108
|
+
server_prefix: us6
|
|
109
|
+
type: regular
|
|
110
|
+
list_id: abc123def4
|
|
111
|
+
subject_line: 'Welcome to our newsletter!'
|
|
112
|
+
preview_text: 'Check out what we have for you this month'
|
|
113
|
+
title: 'Monthly Newsletter - March 2026'
|
|
114
|
+
from_name: 'Acme Marketing'
|
|
115
|
+
reply_to: marketing@acme.com
|
|
116
|
+
expected_result: 'Returns campaign record with id for use in mailchimp-send-campaign'
|
|
117
|
+
- name: 'Create a plaintext campaign'
|
|
118
|
+
params:
|
|
119
|
+
server_prefix: us6
|
|
120
|
+
type: plaintext
|
|
121
|
+
list_id: abc123def4
|
|
122
|
+
subject_line: 'Quick update from us'
|
|
123
|
+
from_name: 'Acme Team'
|
|
124
|
+
reply_to: hello@acme.com
|
|
125
|
+
expected_result: 'Returns plaintext campaign record ready to add content and send'
|
|
@@ -0,0 +1,101 @@
|
|
|
1
|
+
name: mailchimp-get-list-members
|
|
2
|
+
version: '1.0.0'
|
|
3
|
+
description: >
|
|
4
|
+
Get all members (subscribers) from a Mailchimp audience/list with optional
|
|
5
|
+
filtering by subscription status and pagination support.
|
|
6
|
+
|
|
7
|
+
parameters:
|
|
8
|
+
server_prefix:
|
|
9
|
+
type: string
|
|
10
|
+
required: true
|
|
11
|
+
description: >
|
|
12
|
+
Your Mailchimp data center prefix (e.g. "us6"). Found at the end of your API key:
|
|
13
|
+
"abc123-us6" → server_prefix is "us6".
|
|
14
|
+
list_id:
|
|
15
|
+
type: string
|
|
16
|
+
required: true
|
|
17
|
+
description: The unique ID of the Mailchimp audience/list to get members from
|
|
18
|
+
status:
|
|
19
|
+
type: string
|
|
20
|
+
required: false
|
|
21
|
+
description: >
|
|
22
|
+
Filter members by subscription status. Options: "subscribed", "unsubscribed",
|
|
23
|
+
"pending", "cleaned", "transactional", "archived". Omit to get all members.
|
|
24
|
+
enum:
|
|
25
|
+
- subscribed
|
|
26
|
+
- unsubscribed
|
|
27
|
+
- pending
|
|
28
|
+
- cleaned
|
|
29
|
+
- transactional
|
|
30
|
+
- archived
|
|
31
|
+
count:
|
|
32
|
+
type: number
|
|
33
|
+
required: false
|
|
34
|
+
description: Number of members to return per page (default 10, max 1000)
|
|
35
|
+
default: 10
|
|
36
|
+
min: 1
|
|
37
|
+
max: 1000
|
|
38
|
+
offset:
|
|
39
|
+
type: number
|
|
40
|
+
required: false
|
|
41
|
+
description: Number of records to skip for pagination (default 0)
|
|
42
|
+
default: 0
|
|
43
|
+
min: 0
|
|
44
|
+
|
|
45
|
+
execution:
|
|
46
|
+
type: http
|
|
47
|
+
method: GET
|
|
48
|
+
url: 'https://{server_prefix}.api.mailchimp.com/3.0/lists/{list_id}/members'
|
|
49
|
+
headers:
|
|
50
|
+
Authorization: 'apikey {MAILCHIMP_API_KEY}'
|
|
51
|
+
Content-Type: application/json
|
|
52
|
+
query_params:
|
|
53
|
+
status: '{status}'
|
|
54
|
+
count: '{count}'
|
|
55
|
+
offset: '{offset}'
|
|
56
|
+
timeout: 30000
|
|
57
|
+
|
|
58
|
+
authentication:
|
|
59
|
+
type: api_key
|
|
60
|
+
location: header
|
|
61
|
+
name: Authorization
|
|
62
|
+
notes:
|
|
63
|
+
env: MAILCHIMP_API_KEY
|
|
64
|
+
|
|
65
|
+
output_schema:
|
|
66
|
+
type: object
|
|
67
|
+
properties:
|
|
68
|
+
success:
|
|
69
|
+
type: boolean
|
|
70
|
+
data:
|
|
71
|
+
type: object
|
|
72
|
+
properties:
|
|
73
|
+
members:
|
|
74
|
+
type: array
|
|
75
|
+
description: Array of member objects with email, status, and merge fields
|
|
76
|
+
list_id:
|
|
77
|
+
type: string
|
|
78
|
+
total_items:
|
|
79
|
+
type: number
|
|
80
|
+
|
|
81
|
+
error_handling:
|
|
82
|
+
retry: 2
|
|
83
|
+
backoff_type: exponential
|
|
84
|
+
initial_delay_ms: 500
|
|
85
|
+
|
|
86
|
+
examples:
|
|
87
|
+
- name: 'Get all subscribed members'
|
|
88
|
+
params:
|
|
89
|
+
server_prefix: us6
|
|
90
|
+
list_id: abc123def4
|
|
91
|
+
status: subscribed
|
|
92
|
+
count: 100
|
|
93
|
+
offset: 0
|
|
94
|
+
expected_result: 'Returns array of subscribed members with total_items count'
|
|
95
|
+
- name: 'Get first page of all members'
|
|
96
|
+
params:
|
|
97
|
+
server_prefix: us6
|
|
98
|
+
list_id: abc123def4
|
|
99
|
+
count: 10
|
|
100
|
+
offset: 0
|
|
101
|
+
expected_result: 'Returns first 10 members across all statuses'
|
|
@@ -0,0 +1,81 @@
|
|
|
1
|
+
name: mailchimp-get-lists
|
|
2
|
+
version: '1.0.0'
|
|
3
|
+
description: >
|
|
4
|
+
Get all Mailchimp audiences (lists) for the authenticated account.
|
|
5
|
+
Returns a paginated list of all audiences with subscriber counts and settings.
|
|
6
|
+
|
|
7
|
+
parameters:
|
|
8
|
+
server_prefix:
|
|
9
|
+
type: string
|
|
10
|
+
required: true
|
|
11
|
+
description: >
|
|
12
|
+
Your Mailchimp data center prefix (e.g. "us6"). Found at the end of your API key:
|
|
13
|
+
"abc123-us6" → server_prefix is "us6".
|
|
14
|
+
count:
|
|
15
|
+
type: number
|
|
16
|
+
required: false
|
|
17
|
+
description: Number of audiences to return (default 10, max 1000)
|
|
18
|
+
default: 10
|
|
19
|
+
min: 1
|
|
20
|
+
max: 1000
|
|
21
|
+
offset:
|
|
22
|
+
type: number
|
|
23
|
+
required: false
|
|
24
|
+
description: Number of records to skip for pagination (default 0)
|
|
25
|
+
default: 0
|
|
26
|
+
min: 0
|
|
27
|
+
|
|
28
|
+
execution:
|
|
29
|
+
type: http
|
|
30
|
+
method: GET
|
|
31
|
+
url: 'https://{server_prefix}.api.mailchimp.com/3.0/lists'
|
|
32
|
+
headers:
|
|
33
|
+
Authorization: 'apikey {MAILCHIMP_API_KEY}'
|
|
34
|
+
Content-Type: application/json
|
|
35
|
+
query_params:
|
|
36
|
+
count: '{count}'
|
|
37
|
+
offset: '{offset}'
|
|
38
|
+
timeout: 30000
|
|
39
|
+
|
|
40
|
+
authentication:
|
|
41
|
+
type: api_key
|
|
42
|
+
location: header
|
|
43
|
+
name: Authorization
|
|
44
|
+
notes:
|
|
45
|
+
env: MAILCHIMP_API_KEY
|
|
46
|
+
|
|
47
|
+
output_schema:
|
|
48
|
+
type: object
|
|
49
|
+
properties:
|
|
50
|
+
success:
|
|
51
|
+
type: boolean
|
|
52
|
+
data:
|
|
53
|
+
type: object
|
|
54
|
+
properties:
|
|
55
|
+
lists:
|
|
56
|
+
type: array
|
|
57
|
+
description: Array of audience objects
|
|
58
|
+
total_items:
|
|
59
|
+
type: number
|
|
60
|
+
description: Total number of audiences in the account
|
|
61
|
+
_links:
|
|
62
|
+
type: array
|
|
63
|
+
|
|
64
|
+
error_handling:
|
|
65
|
+
retry: 2
|
|
66
|
+
backoff_type: exponential
|
|
67
|
+
initial_delay_ms: 500
|
|
68
|
+
|
|
69
|
+
examples:
|
|
70
|
+
- name: 'Get first 10 audiences'
|
|
71
|
+
params:
|
|
72
|
+
server_prefix: us6
|
|
73
|
+
count: 10
|
|
74
|
+
offset: 0
|
|
75
|
+
expected_result: 'Returns a list of audiences with total_items count'
|
|
76
|
+
- name: 'Get next page of audiences'
|
|
77
|
+
params:
|
|
78
|
+
server_prefix: us6
|
|
79
|
+
count: 10
|
|
80
|
+
offset: 10
|
|
81
|
+
expected_result: 'Returns the second page of audiences'
|
matimo_mailchimp-0.1.0/src/matimo_mailchimp/tools/mailchimp-remove-list-member/definition.yaml
ADDED
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
name: mailchimp-remove-list-member
|
|
2
|
+
version: '1.0.0'
|
|
3
|
+
description: >
|
|
4
|
+
Archive (unsubscribe and remove) a subscriber from a Mailchimp audience/list.
|
|
5
|
+
This action archives the contact so they no longer appear as an active member.
|
|
6
|
+
Use the MD5 hash of the lowercase email address as the subscriber_hash.
|
|
7
|
+
⚠️ This action requires approval — it cannot be undone from this tool.
|
|
8
|
+
|
|
9
|
+
requires_approval: true
|
|
10
|
+
|
|
11
|
+
parameters:
|
|
12
|
+
server_prefix:
|
|
13
|
+
type: string
|
|
14
|
+
required: true
|
|
15
|
+
description: >
|
|
16
|
+
Your Mailchimp data center prefix (e.g. "us6"). Found at the end of your API key:
|
|
17
|
+
"abc123-us6" → server_prefix is "us6".
|
|
18
|
+
list_id:
|
|
19
|
+
type: string
|
|
20
|
+
required: true
|
|
21
|
+
description: The unique ID of the Mailchimp audience/list the member belongs to
|
|
22
|
+
subscriber_hash:
|
|
23
|
+
type: string
|
|
24
|
+
required: true
|
|
25
|
+
description: >
|
|
26
|
+
The MD5 hash of the subscriber's lowercase email address. You can generate this
|
|
27
|
+
using MD5("email@example.com"). Use the id field from list member responses.
|
|
28
|
+
|
|
29
|
+
execution:
|
|
30
|
+
type: http
|
|
31
|
+
method: DELETE
|
|
32
|
+
url: 'https://{server_prefix}.api.mailchimp.com/3.0/lists/{list_id}/members/{subscriber_hash}'
|
|
33
|
+
headers:
|
|
34
|
+
Authorization: 'apikey {MAILCHIMP_API_KEY}'
|
|
35
|
+
Content-Type: application/json
|
|
36
|
+
timeout: 30000
|
|
37
|
+
|
|
38
|
+
authentication:
|
|
39
|
+
type: api_key
|
|
40
|
+
location: header
|
|
41
|
+
name: Authorization
|
|
42
|
+
notes:
|
|
43
|
+
env: MAILCHIMP_API_KEY
|
|
44
|
+
|
|
45
|
+
output_schema:
|
|
46
|
+
type: object
|
|
47
|
+
properties:
|
|
48
|
+
success:
|
|
49
|
+
type: boolean
|
|
50
|
+
statusCode:
|
|
51
|
+
type: number
|
|
52
|
+
|
|
53
|
+
error_handling:
|
|
54
|
+
retry: 1
|
|
55
|
+
backoff_type: linear
|
|
56
|
+
initial_delay_ms: 1000
|
|
57
|
+
|
|
58
|
+
examples:
|
|
59
|
+
- name: 'Remove a subscriber'
|
|
60
|
+
params:
|
|
61
|
+
server_prefix: us6
|
|
62
|
+
list_id: abc123def4
|
|
63
|
+
subscriber_hash: b775e3e869bc8eae5fcb23cdc5ec64ff
|
|
64
|
+
expected_result: 'Returns 204 No Content on success (success: true, statusCode: 204)'
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
name: mailchimp-send-campaign
|
|
2
|
+
version: '1.0.0'
|
|
3
|
+
description: >
|
|
4
|
+
Send a Mailchimp campaign. This triggers the campaign to be delivered
|
|
5
|
+
to all recipients in the audience. The campaign must have content set
|
|
6
|
+
and all required settings configured before sending.
|
|
7
|
+
⚠️ This action requires approval as it triggers mass email delivery.
|
|
8
|
+
|
|
9
|
+
requires_approval: true
|
|
10
|
+
|
|
11
|
+
parameters:
|
|
12
|
+
server_prefix:
|
|
13
|
+
type: string
|
|
14
|
+
required: true
|
|
15
|
+
description: >
|
|
16
|
+
Your Mailchimp data center prefix (e.g. "us6"). Found at the end of your API key:
|
|
17
|
+
"abc123-us6" → server_prefix is "us6".
|
|
18
|
+
campaign_id:
|
|
19
|
+
type: string
|
|
20
|
+
required: true
|
|
21
|
+
description: >
|
|
22
|
+
The unique ID of the campaign to send. Obtained from mailchimp-create-campaign
|
|
23
|
+
response or from the Mailchimp dashboard.
|
|
24
|
+
|
|
25
|
+
execution:
|
|
26
|
+
type: http
|
|
27
|
+
method: POST
|
|
28
|
+
url: 'https://{server_prefix}.api.mailchimp.com/3.0/campaigns/{campaign_id}/actions/send'
|
|
29
|
+
headers:
|
|
30
|
+
Authorization: 'apikey {MAILCHIMP_API_KEY}'
|
|
31
|
+
Content-Type: application/json
|
|
32
|
+
timeout: 30000
|
|
33
|
+
|
|
34
|
+
authentication:
|
|
35
|
+
type: api_key
|
|
36
|
+
location: header
|
|
37
|
+
name: Authorization
|
|
38
|
+
notes:
|
|
39
|
+
env: MAILCHIMP_API_KEY
|
|
40
|
+
|
|
41
|
+
output_schema:
|
|
42
|
+
type: object
|
|
43
|
+
properties:
|
|
44
|
+
success:
|
|
45
|
+
type: boolean
|
|
46
|
+
statusCode:
|
|
47
|
+
type: number
|
|
48
|
+
|
|
49
|
+
error_handling:
|
|
50
|
+
retry: 1
|
|
51
|
+
backoff_type: linear
|
|
52
|
+
initial_delay_ms: 2000
|
|
53
|
+
|
|
54
|
+
examples:
|
|
55
|
+
- name: 'Send a prepared campaign'
|
|
56
|
+
params:
|
|
57
|
+
server_prefix: us6
|
|
58
|
+
campaign_id: a1b2c3d4e5
|
|
59
|
+
expected_result: 'Returns 204 No Content on success (success: true, statusCode: 204)'
|
matimo_mailchimp-0.1.0/src/matimo_mailchimp/tools/mailchimp-update-list-member/definition.yaml
ADDED
|
@@ -0,0 +1,105 @@
|
|
|
1
|
+
name: mailchimp-update-list-member
|
|
2
|
+
version: '1.0.0'
|
|
3
|
+
description: >
|
|
4
|
+
Update an existing subscriber's information in a Mailchimp audience/list.
|
|
5
|
+
Use the subscriber_hash (MD5 hash of the lowercase email address) to identify the member.
|
|
6
|
+
Supports updating status, email address, and merge fields.
|
|
7
|
+
|
|
8
|
+
parameters:
|
|
9
|
+
server_prefix:
|
|
10
|
+
type: string
|
|
11
|
+
required: true
|
|
12
|
+
description: >
|
|
13
|
+
Your Mailchimp data center prefix (e.g. "us6"). Found at the end of your API key:
|
|
14
|
+
"abc123-us6" → server_prefix is "us6".
|
|
15
|
+
list_id:
|
|
16
|
+
type: string
|
|
17
|
+
required: true
|
|
18
|
+
description: The unique ID of the Mailchimp audience/list the member belongs to
|
|
19
|
+
subscriber_hash:
|
|
20
|
+
type: string
|
|
21
|
+
required: true
|
|
22
|
+
description: >
|
|
23
|
+
The MD5 hash of the subscriber's lowercase email address. You can generate this
|
|
24
|
+
using MD5("email@example.com"). Use the id field from mailchimp-add-list-member response.
|
|
25
|
+
status:
|
|
26
|
+
type: string
|
|
27
|
+
required: false
|
|
28
|
+
description: >
|
|
29
|
+
Update subscription status. Options: "subscribed", "unsubscribed", "pending", "cleaned"
|
|
30
|
+
enum:
|
|
31
|
+
- subscribed
|
|
32
|
+
- unsubscribed
|
|
33
|
+
- pending
|
|
34
|
+
- cleaned
|
|
35
|
+
email_address:
|
|
36
|
+
type: string
|
|
37
|
+
required: false
|
|
38
|
+
description: New email address for the subscriber (updates the email)
|
|
39
|
+
merge_fields:
|
|
40
|
+
type: object
|
|
41
|
+
required: false
|
|
42
|
+
description: >
|
|
43
|
+
Key-value pairs for merge fields to update. Example: {"FNAME": "Jane", "LNAME": "Smith"}
|
|
44
|
+
|
|
45
|
+
execution:
|
|
46
|
+
type: http
|
|
47
|
+
method: PATCH
|
|
48
|
+
url: 'https://{server_prefix}.api.mailchimp.com/3.0/lists/{list_id}/members/{subscriber_hash}'
|
|
49
|
+
headers:
|
|
50
|
+
Authorization: 'apikey {MAILCHIMP_API_KEY}'
|
|
51
|
+
Content-Type: application/json
|
|
52
|
+
body:
|
|
53
|
+
status: '{status}'
|
|
54
|
+
email_address: '{email_address}'
|
|
55
|
+
merge_fields: '{merge_fields}'
|
|
56
|
+
timeout: 30000
|
|
57
|
+
|
|
58
|
+
authentication:
|
|
59
|
+
type: api_key
|
|
60
|
+
location: header
|
|
61
|
+
name: Authorization
|
|
62
|
+
notes:
|
|
63
|
+
env: MAILCHIMP_API_KEY
|
|
64
|
+
|
|
65
|
+
output_schema:
|
|
66
|
+
type: object
|
|
67
|
+
properties:
|
|
68
|
+
success:
|
|
69
|
+
type: boolean
|
|
70
|
+
data:
|
|
71
|
+
type: object
|
|
72
|
+
properties:
|
|
73
|
+
id:
|
|
74
|
+
type: string
|
|
75
|
+
email_address:
|
|
76
|
+
type: string
|
|
77
|
+
status:
|
|
78
|
+
type: string
|
|
79
|
+
merge_fields:
|
|
80
|
+
type: object
|
|
81
|
+
list_id:
|
|
82
|
+
type: string
|
|
83
|
+
|
|
84
|
+
error_handling:
|
|
85
|
+
retry: 2
|
|
86
|
+
backoff_type: exponential
|
|
87
|
+
initial_delay_ms: 500
|
|
88
|
+
|
|
89
|
+
examples:
|
|
90
|
+
- name: 'Unsubscribe a member'
|
|
91
|
+
params:
|
|
92
|
+
server_prefix: us6
|
|
93
|
+
list_id: abc123def4
|
|
94
|
+
subscriber_hash: b775e3e869bc8eae5fcb23cdc5ec64ff
|
|
95
|
+
status: unsubscribed
|
|
96
|
+
expected_result: 'Returns updated member record with unsubscribed status'
|
|
97
|
+
- name: 'Update subscriber name'
|
|
98
|
+
params:
|
|
99
|
+
server_prefix: us6
|
|
100
|
+
list_id: abc123def4
|
|
101
|
+
subscriber_hash: b775e3e869bc8eae5fcb23cdc5ec64ff
|
|
102
|
+
merge_fields:
|
|
103
|
+
FNAME: Jane
|
|
104
|
+
LNAME: Smith
|
|
105
|
+
expected_result: 'Returns updated member record with new merge fields'
|