claude-plugin-wordpress-manager 2.3.1 → 2.6.0
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.
- package/.claude-plugin/plugin.json +15 -3
- package/CHANGELOG.md +62 -0
- package/agents/wp-content-strategist.md +104 -0
- package/agents/wp-distribution-manager.md +98 -0
- package/docs/GUIDE.md +183 -23
- package/docs/plans/2026-03-01-tier3-wcop-design.md +373 -0
- package/docs/plans/2026-03-01-tier3-wcop-implementation.md +915 -0
- package/hooks/hooks.json +18 -0
- package/package.json +18 -3
- package/servers/wp-rest-bridge/build/tools/buffer.d.ts +3 -0
- package/servers/wp-rest-bridge/build/tools/buffer.js +205 -0
- package/servers/wp-rest-bridge/build/tools/comments.d.ts +6 -6
- package/servers/wp-rest-bridge/build/tools/gsc.d.ts +3 -0
- package/servers/wp-rest-bridge/build/tools/gsc.js +354 -0
- package/servers/wp-rest-bridge/build/tools/index.d.ts +38 -38
- package/servers/wp-rest-bridge/build/tools/index.js +12 -0
- package/servers/wp-rest-bridge/build/tools/mailchimp.d.ts +3 -0
- package/servers/wp-rest-bridge/build/tools/mailchimp.js +265 -0
- package/servers/wp-rest-bridge/build/tools/media.d.ts +2 -2
- package/servers/wp-rest-bridge/build/tools/multisite-sites.d.ts +2 -2
- package/servers/wp-rest-bridge/build/tools/plugin-repository.d.ts +1 -1
- package/servers/wp-rest-bridge/build/tools/search.d.ts +2 -2
- package/servers/wp-rest-bridge/build/tools/sendgrid.d.ts +3 -0
- package/servers/wp-rest-bridge/build/tools/sendgrid.js +255 -0
- package/servers/wp-rest-bridge/build/tools/unified-content.d.ts +8 -8
- package/servers/wp-rest-bridge/build/tools/unified-taxonomies.d.ts +4 -4
- package/servers/wp-rest-bridge/build/tools/users.d.ts +6 -6
- package/servers/wp-rest-bridge/build/tools/wc-coupons.d.ts +1 -1
- package/servers/wp-rest-bridge/build/tools/wc-customers.d.ts +3 -3
- package/servers/wp-rest-bridge/build/tools/wc-orders.d.ts +4 -4
- package/servers/wp-rest-bridge/build/tools/wc-products.d.ts +8 -8
- package/servers/wp-rest-bridge/build/tools/wc-webhooks.d.ts +4 -4
- package/servers/wp-rest-bridge/build/types.d.ts +122 -0
- package/servers/wp-rest-bridge/build/wordpress.d.ts +14 -0
- package/servers/wp-rest-bridge/build/wordpress.js +151 -0
- package/servers/wp-rest-bridge/package.json +1 -0
- package/skills/wordpress-router/references/decision-tree.md +8 -2
- package/skills/wp-content/SKILL.md +2 -0
- package/skills/wp-content-attribution/SKILL.md +2 -0
- package/skills/wp-content-optimization/SKILL.md +172 -0
- package/skills/wp-content-optimization/references/content-freshness.md +234 -0
- package/skills/wp-content-optimization/references/headline-optimization.md +171 -0
- package/skills/wp-content-optimization/references/meta-optimization.md +243 -0
- package/skills/wp-content-optimization/references/readability-analysis.md +201 -0
- package/skills/wp-content-optimization/references/seo-content-scoring.md +245 -0
- package/skills/wp-content-optimization/scripts/content_optimization_inspect.mjs +237 -0
- package/skills/wp-content-repurposing/SKILL.md +1 -0
- package/skills/wp-monitoring/SKILL.md +1 -0
- package/skills/wp-programmatic-seo/SKILL.md +2 -0
- package/skills/wp-search-console/SKILL.md +121 -0
- package/skills/wp-search-console/references/competitor-gap-analysis.md +226 -0
- package/skills/wp-search-console/references/content-seo-feedback.md +181 -0
- package/skills/wp-search-console/references/gsc-setup.md +110 -0
- package/skills/wp-search-console/references/indexing-management.md +182 -0
- package/skills/wp-search-console/references/keyword-tracking.md +181 -0
- package/skills/wp-search-console/scripts/search_console_inspect.mjs +178 -0
- package/skills/wp-social-email/SKILL.md +152 -0
- package/skills/wp-social-email/references/audience-segmentation.md +173 -0
- package/skills/wp-social-email/references/buffer-social-publishing.md +124 -0
- package/skills/wp-social-email/references/content-to-distribution.md +156 -0
- package/skills/wp-social-email/references/distribution-analytics.md +208 -0
- package/skills/wp-social-email/references/mailchimp-integration.md +145 -0
- package/skills/wp-social-email/references/sendgrid-transactional.md +165 -0
- package/skills/wp-social-email/scripts/distribution_inspect.mjs +165 -0
- package/skills/wp-webhooks/SKILL.md +1 -0
|
@@ -0,0 +1,173 @@
|
|
|
1
|
+
# Audience Segmentation
|
|
2
|
+
|
|
3
|
+
## Overview
|
|
4
|
+
|
|
5
|
+
Audience segmentation divides your subscriber base into targeted groups for more relevant messaging. Effective segmentation improves open rates, click rates, and reduces unsubscribes. This reference covers segmentation strategies across Mailchimp, SendGrid, and Buffer.
|
|
6
|
+
|
|
7
|
+
## Mailchimp List Segmentation
|
|
8
|
+
|
|
9
|
+
### Segment by subscriber data
|
|
10
|
+
|
|
11
|
+
Mailchimp segments are dynamic filters applied to an audience. Subscribers matching the criteria are automatically included.
|
|
12
|
+
|
|
13
|
+
```
|
|
14
|
+
Tool: mc_get_audience_members
|
|
15
|
+
Params:
|
|
16
|
+
audience_id: "abc123def4"
|
|
17
|
+
status: "subscribed"
|
|
18
|
+
# Filter by merge fields, tags, or activity in the Mailchimp UI
|
|
19
|
+
```
|
|
20
|
+
|
|
21
|
+
### Tag-based segmentation
|
|
22
|
+
|
|
23
|
+
Tags are the most flexible segmentation method via the API:
|
|
24
|
+
|
|
25
|
+
```
|
|
26
|
+
Tool: mc_add_subscriber
|
|
27
|
+
Params:
|
|
28
|
+
audience_id: "abc123def4"
|
|
29
|
+
email: "user@example.com"
|
|
30
|
+
tags: ["wordpress-user", "product-interest-seo", "signup-2026-q1"]
|
|
31
|
+
```
|
|
32
|
+
|
|
33
|
+
### Common Mailchimp segments
|
|
34
|
+
|
|
35
|
+
| Segment | Criteria | Use Case |
|
|
36
|
+
|---------|----------|----------|
|
|
37
|
+
| New subscribers | Signup date < 30 days | Welcome series, onboarding |
|
|
38
|
+
| Engaged readers | Opened last 3 campaigns | Premium content, surveys |
|
|
39
|
+
| Inactive | Not opened in 90 days | Re-engagement campaign |
|
|
40
|
+
| Product interest | Tagged by category | Targeted product launches |
|
|
41
|
+
| High-value | Purchase history > $100 | VIP offers, early access |
|
|
42
|
+
| Location-based | Merge field `COUNTRY` | Localized content, events |
|
|
43
|
+
|
|
44
|
+
### Merge fields for segmentation
|
|
45
|
+
|
|
46
|
+
Define custom merge fields to capture WordPress user data:
|
|
47
|
+
|
|
48
|
+
| Merge Tag | Type | WordPress Source |
|
|
49
|
+
|-----------|------|-----------------|
|
|
50
|
+
| `FNAME` | Text | `user.first_name` |
|
|
51
|
+
| `LNAME` | Text | `user.last_name` |
|
|
52
|
+
| `WP_ROLE` | Text | `user.role` (subscriber, customer, etc.) |
|
|
53
|
+
| `SIGNUP_SRC` | Text | Registration source (blog, checkout, popup) |
|
|
54
|
+
| `LAST_ORDER` | Date | Most recent WooCommerce order date |
|
|
55
|
+
| `ORDER_TOTAL` | Number | Lifetime order value |
|
|
56
|
+
|
|
57
|
+
## SendGrid Contact Segmentation
|
|
58
|
+
|
|
59
|
+
### Contact lists
|
|
60
|
+
|
|
61
|
+
SendGrid uses contact lists for static segmentation:
|
|
62
|
+
|
|
63
|
+
```
|
|
64
|
+
Tool: sg_add_contacts
|
|
65
|
+
Params:
|
|
66
|
+
list_ids: ["list_new_users", "list_blog_subscribers"]
|
|
67
|
+
contacts:
|
|
68
|
+
- email: "user@example.com"
|
|
69
|
+
first_name: "Jane"
|
|
70
|
+
custom_fields:
|
|
71
|
+
signup_source: "blog_popup"
|
|
72
|
+
wp_user_id: "42"
|
|
73
|
+
```
|
|
74
|
+
|
|
75
|
+
### Custom fields
|
|
76
|
+
|
|
77
|
+
Define custom fields in SendGrid to mirror WordPress user data:
|
|
78
|
+
|
|
79
|
+
| Field Name | Type | Purpose |
|
|
80
|
+
|------------|------|---------|
|
|
81
|
+
| `wp_user_id` | Number | Link to WordPress user record |
|
|
82
|
+
| `signup_source` | Text | Track acquisition channel |
|
|
83
|
+
| `user_role` | Text | WordPress role for permission-based content |
|
|
84
|
+
| `last_purchase_date` | Date | Trigger post-purchase sequences |
|
|
85
|
+
| `content_preference` | Text | Category interest for targeted notifications |
|
|
86
|
+
|
|
87
|
+
### SGQL queries for segmentation
|
|
88
|
+
|
|
89
|
+
```
|
|
90
|
+
Tool: sg_list_contacts
|
|
91
|
+
Params:
|
|
92
|
+
query: "signup_source = 'blog_popup' AND last_purchase_date IS NULL"
|
|
93
|
+
```
|
|
94
|
+
|
|
95
|
+
Common SGQL patterns:
|
|
96
|
+
|
|
97
|
+
| Query | Segment |
|
|
98
|
+
|-------|---------|
|
|
99
|
+
| `signup_source = 'checkout'` | Customers who bought |
|
|
100
|
+
| `last_purchase_date < '2026-01-01'` | Lapsed customers |
|
|
101
|
+
| `user_role = 'subscriber'` | Blog-only subscribers |
|
|
102
|
+
| `content_preference = 'tutorials'` | Tutorial readers |
|
|
103
|
+
|
|
104
|
+
## Buffer Profile-Based Targeting
|
|
105
|
+
|
|
106
|
+
Buffer segments audiences by social profile rather than individual users. Each profile reaches a different audience.
|
|
107
|
+
|
|
108
|
+
### Profile selection strategy
|
|
109
|
+
|
|
110
|
+
| Profile | Audience Type | Content Style |
|
|
111
|
+
|---------|--------------|---------------|
|
|
112
|
+
| Twitter/X | Tech-savvy, real-time | Short, punchy, hashtags |
|
|
113
|
+
| LinkedIn | Professional, B2B | Thought leadership, data-driven |
|
|
114
|
+
| Facebook | Broad, community | Storytelling, engagement prompts |
|
|
115
|
+
| Instagram | Visual-first, younger | Image-heavy, lifestyle |
|
|
116
|
+
|
|
117
|
+
### Targeting by profile
|
|
118
|
+
|
|
119
|
+
```
|
|
120
|
+
Tool: buf_create_update
|
|
121
|
+
Params:
|
|
122
|
+
profile_ids: ["linkedin_id"] # Only post to LinkedIn for B2B content
|
|
123
|
+
text: "Our latest research on WordPress performance..."
|
|
124
|
+
```
|
|
125
|
+
|
|
126
|
+
Select profiles based on content type:
|
|
127
|
+
- **Product launches**: All profiles
|
|
128
|
+
- **Technical tutorials**: Twitter + LinkedIn
|
|
129
|
+
- **Behind-the-scenes**: Instagram + Facebook
|
|
130
|
+
- **Industry news**: Twitter + LinkedIn
|
|
131
|
+
|
|
132
|
+
## Building Personas from WordPress Data
|
|
133
|
+
|
|
134
|
+
### Data sources for persona building
|
|
135
|
+
|
|
136
|
+
| Source | Data | Tool |
|
|
137
|
+
|--------|------|------|
|
|
138
|
+
| WordPress users | Role, registration date, profile fields | `wp_list_users` |
|
|
139
|
+
| WooCommerce orders | Purchase history, AOV, frequency | `wc_list_orders` |
|
|
140
|
+
| Post analytics | Most-read categories, time on page | Site analytics |
|
|
141
|
+
| Form submissions | Stated interests, preferences | Contact form data |
|
|
142
|
+
|
|
143
|
+
### Persona-to-segment mapping
|
|
144
|
+
|
|
145
|
+
| Persona | Characteristics | Mailchimp Tags | SendGrid Lists |
|
|
146
|
+
|---------|----------------|----------------|----------------|
|
|
147
|
+
| New Visitor | First 30 days, no purchase | `new-visitor` | `list_onboarding` |
|
|
148
|
+
| Blog Reader | Regular reader, no purchase | `blog-reader`, category tags | `list_blog` |
|
|
149
|
+
| First Buyer | 1 order, < $50 | `first-buyer` | `list_customers` |
|
|
150
|
+
| Loyal Customer | 3+ orders, > $200 | `loyal-customer`, `vip` | `list_vip` |
|
|
151
|
+
| Churning | No activity 60+ days | `at-risk` | `list_reengagement` |
|
|
152
|
+
|
|
153
|
+
### Sync WordPress users to segments
|
|
154
|
+
|
|
155
|
+
Workflow to keep segments current:
|
|
156
|
+
|
|
157
|
+
```
|
|
158
|
+
1. wp_list_users → fetch all users with roles and metadata
|
|
159
|
+
2. For each user, determine persona based on rules
|
|
160
|
+
3. mc_add_subscriber → set tags matching persona
|
|
161
|
+
4. sg_add_contacts → add to appropriate contact lists
|
|
162
|
+
5. Schedule weekly sync to update segment membership
|
|
163
|
+
```
|
|
164
|
+
|
|
165
|
+
## Best Practices
|
|
166
|
+
|
|
167
|
+
- **Start simple**: Begin with 3-4 segments (new, active, inactive, customer); add granularity as data grows
|
|
168
|
+
- **Dynamic over static**: Prefer Mailchimp tag-based segments that update automatically over manually managed lists
|
|
169
|
+
- **Consistent field naming**: Use the same custom field names across Mailchimp and SendGrid for easier cross-channel management
|
|
170
|
+
- **Hygiene**: Remove hard bounces and unsubscribes from all platforms; sync removals across services
|
|
171
|
+
- **Privacy compliance**: Honor opt-out preferences across all channels; never re-add unsubscribed contacts
|
|
172
|
+
- **Test segments**: Before sending a campaign to a new segment, verify member count and sample members for accuracy
|
|
173
|
+
- **Document segments**: Maintain a segment registry with criteria, purpose, and last review date
|
|
@@ -0,0 +1,124 @@
|
|
|
1
|
+
# Buffer Social Publishing
|
|
2
|
+
|
|
3
|
+
## Overview
|
|
4
|
+
|
|
5
|
+
Buffer is a social media scheduling platform that manages posting across Twitter/X, Facebook, Instagram, LinkedIn, and other channels. The WP REST Bridge provides 5 MCP tools (`buf_*`) for creating posts, managing queues, and retrieving analytics.
|
|
6
|
+
|
|
7
|
+
## Setup
|
|
8
|
+
|
|
9
|
+
### Access Token Configuration
|
|
10
|
+
|
|
11
|
+
Add Buffer credentials to `WP_SITES_CONFIG`:
|
|
12
|
+
|
|
13
|
+
```json
|
|
14
|
+
{
|
|
15
|
+
"sites": [{
|
|
16
|
+
"name": "my-site",
|
|
17
|
+
"url": "https://example.com",
|
|
18
|
+
"distribution": {
|
|
19
|
+
"buffer": {
|
|
20
|
+
"access_token": "1/xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx"
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
}]
|
|
24
|
+
}
|
|
25
|
+
```
|
|
26
|
+
|
|
27
|
+
Obtain the access token from Buffer's developer portal (Settings → Apps → Access Token).
|
|
28
|
+
|
|
29
|
+
## Profile Management
|
|
30
|
+
|
|
31
|
+
### List connected profiles
|
|
32
|
+
|
|
33
|
+
```
|
|
34
|
+
Tool: buf_list_profiles
|
|
35
|
+
Returns: Array of profiles with id, service (twitter, facebook, etc.),
|
|
36
|
+
formatted_username, avatar, schedules, counts
|
|
37
|
+
```
|
|
38
|
+
|
|
39
|
+
Each profile represents a connected social account. A single Buffer account may have multiple profiles (e.g., @company on Twitter + Company Page on Facebook).
|
|
40
|
+
|
|
41
|
+
## Post Creation
|
|
42
|
+
|
|
43
|
+
### Create a social post
|
|
44
|
+
|
|
45
|
+
```
|
|
46
|
+
Tool: buf_create_update
|
|
47
|
+
Params:
|
|
48
|
+
profile_ids: ["profile_abc123"]
|
|
49
|
+
text: "New blog post: 10 Tips for Better SEO — Read more at https://example.com/seo-tips"
|
|
50
|
+
scheduled_at: "2026-03-15T14:00:00Z" # Optional: omit for immediate queue
|
|
51
|
+
```
|
|
52
|
+
|
|
53
|
+
### Create a post with media
|
|
54
|
+
|
|
55
|
+
```
|
|
56
|
+
Tool: buf_create_update
|
|
57
|
+
Params:
|
|
58
|
+
profile_ids: ["profile_abc123", "profile_def456"]
|
|
59
|
+
text: "Check out our latest product launch!"
|
|
60
|
+
media:
|
|
61
|
+
photo: "https://example.com/wp-content/uploads/2026/03/product-launch.jpg"
|
|
62
|
+
thumbnail: "https://example.com/wp-content/uploads/2026/03/product-launch-thumb.jpg"
|
|
63
|
+
```
|
|
64
|
+
|
|
65
|
+
### Post to multiple profiles
|
|
66
|
+
|
|
67
|
+
Pass an array of `profile_ids` to publish the same content across channels simultaneously. Buffer adapts character limits per platform.
|
|
68
|
+
|
|
69
|
+
```
|
|
70
|
+
Tool: buf_create_update
|
|
71
|
+
Params:
|
|
72
|
+
profile_ids: ["twitter_id", "facebook_id", "linkedin_id"]
|
|
73
|
+
text: "We just published a comprehensive guide to WordPress performance optimization."
|
|
74
|
+
```
|
|
75
|
+
|
|
76
|
+
## Queue Management
|
|
77
|
+
|
|
78
|
+
### List pending posts
|
|
79
|
+
|
|
80
|
+
```
|
|
81
|
+
Tool: buf_list_pending
|
|
82
|
+
Params:
|
|
83
|
+
profile_id: "profile_abc123"
|
|
84
|
+
Returns: Array of queued posts with id, text, scheduled_at, media
|
|
85
|
+
```
|
|
86
|
+
|
|
87
|
+
### List sent posts
|
|
88
|
+
|
|
89
|
+
```
|
|
90
|
+
Tool: buf_list_sent
|
|
91
|
+
Params:
|
|
92
|
+
profile_id: "profile_abc123"
|
|
93
|
+
count: 20
|
|
94
|
+
page: 1
|
|
95
|
+
Returns: Array of published posts with engagement metrics
|
|
96
|
+
```
|
|
97
|
+
|
|
98
|
+
## WordPress-to-Buffer Workflow
|
|
99
|
+
|
|
100
|
+
Typical flow for distributing a WordPress post to social media:
|
|
101
|
+
|
|
102
|
+
1. **Fetch the post** using `wp_get_post` to get title, excerpt, permalink, featured image
|
|
103
|
+
2. **Format for social**: Compose text from post title + excerpt (truncated to platform limits)
|
|
104
|
+
3. **Attach media**: Use the featured image URL as the `media.photo` parameter
|
|
105
|
+
4. **Schedule**: Set `scheduled_at` for optimal posting time or omit for queue placement
|
|
106
|
+
5. **Post to profiles**: Select target profiles and call `buf_create_update`
|
|
107
|
+
|
|
108
|
+
```
|
|
109
|
+
# Example: Blog post → Twitter + LinkedIn
|
|
110
|
+
Step 1: wp_get_post id=42 → { title, excerpt, link, featured_media_url }
|
|
111
|
+
Step 2: Compose text = "📝 {title}\n\n{excerpt}\n\nRead more: {link}"
|
|
112
|
+
Step 3: buf_create_update profile_ids=[twitter, linkedin] text=... media.photo={featured_media_url}
|
|
113
|
+
```
|
|
114
|
+
|
|
115
|
+
## Best Practices
|
|
116
|
+
|
|
117
|
+
- **Optimal posting times**: Analyze `buf_get_analytics` to identify when your audience is most active; schedule posts during those windows
|
|
118
|
+
- **Platform-specific formatting**: Twitter has 280 chars; LinkedIn allows 3000; tailor text length per profile rather than using identical copy
|
|
119
|
+
- **Hashtag strategy**: Use 1-2 relevant hashtags on Twitter, 3-5 on LinkedIn; avoid hashtags on Facebook
|
|
120
|
+
- **Image dimensions**: Use 1200x628px for link previews, 1080x1080px for square posts; Buffer will resize but starting with correct dimensions avoids cropping
|
|
121
|
+
- **Queue spacing**: Buffer's default schedule spaces posts throughout the day; avoid overriding with manual times unless needed
|
|
122
|
+
- **Evergreen content**: Re-queue high-performing posts using `buf_list_sent` to identify top performers, then `buf_create_update` to re-share
|
|
123
|
+
- **UTM parameters**: Append `?utm_source=buffer&utm_medium=social&utm_campaign={campaign}` to URLs for tracking in Google Analytics
|
|
124
|
+
- **Avoid duplicate content**: Check `buf_list_pending` before creating new posts to prevent queue duplication
|
|
@@ -0,0 +1,156 @@
|
|
|
1
|
+
# Content-to-Distribution Workflow
|
|
2
|
+
|
|
3
|
+
## Overview
|
|
4
|
+
|
|
5
|
+
The content-to-distribution pipeline transforms WordPress content into format-appropriate messages for email and social channels. This reference covers the full workflow: fetching content, adapting it per channel, scheduling distribution, and orchestrating multi-channel campaigns.
|
|
6
|
+
|
|
7
|
+
## WordPress-to-Channel Pipeline
|
|
8
|
+
|
|
9
|
+
### Core flow
|
|
10
|
+
|
|
11
|
+
```
|
|
12
|
+
WordPress Post → Fetch Content → Adapt Format → Distribute
|
|
13
|
+
(wp_get_post) (per channel) (mc_*/buf_*/sg_*)
|
|
14
|
+
```
|
|
15
|
+
|
|
16
|
+
### Step 1: Fetch the source content
|
|
17
|
+
|
|
18
|
+
```
|
|
19
|
+
Tool: wp_get_post
|
|
20
|
+
Params:
|
|
21
|
+
id: 42
|
|
22
|
+
_embed: true # Include featured image, author, categories
|
|
23
|
+
Returns:
|
|
24
|
+
title, excerpt, content (HTML), permalink, featured_media_url,
|
|
25
|
+
author, categories, tags, date
|
|
26
|
+
```
|
|
27
|
+
|
|
28
|
+
### Step 2: Adapt for each channel
|
|
29
|
+
|
|
30
|
+
The same post requires different formatting per distribution target.
|
|
31
|
+
|
|
32
|
+
### Step 3: Distribute via service tools
|
|
33
|
+
|
|
34
|
+
Route the adapted content to the appropriate MCP tool.
|
|
35
|
+
|
|
36
|
+
## Content Adaptation Per Channel
|
|
37
|
+
|
|
38
|
+
### Blog → Newsletter (Mailchimp)
|
|
39
|
+
|
|
40
|
+
| Element | Adaptation |
|
|
41
|
+
|---------|------------|
|
|
42
|
+
| Title | Campaign subject line (max 150 chars, add emoji or personalization) |
|
|
43
|
+
| Excerpt | Preview text (max 200 chars) |
|
|
44
|
+
| Content | Full HTML body, reformatted for email (inline CSS, max 600px width) |
|
|
45
|
+
| Featured image | Hero image at top of email (600px wide) |
|
|
46
|
+
| CTA | "Read the full post" button linking to permalink |
|
|
47
|
+
|
|
48
|
+
```
|
|
49
|
+
1. wp_get_post → extract title, content, featured_image
|
|
50
|
+
2. mc_create_campaign → subject = post title, from_name = site name
|
|
51
|
+
3. mc_set_campaign_content → html = email-formatted post content
|
|
52
|
+
4. mc_send_campaign → deliver or schedule
|
|
53
|
+
```
|
|
54
|
+
|
|
55
|
+
### Blog → Social Post (Buffer)
|
|
56
|
+
|
|
57
|
+
| Platform | Adaptation |
|
|
58
|
+
|----------|------------|
|
|
59
|
+
| Twitter/X | Title + shortened excerpt (max 250 chars with URL) |
|
|
60
|
+
| LinkedIn | Title + full excerpt + 3-5 hashtags (max 700 chars) |
|
|
61
|
+
| Facebook | Title + excerpt + URL (no character pressure) |
|
|
62
|
+
| Instagram | Excerpt + 10-15 hashtags (image required) |
|
|
63
|
+
|
|
64
|
+
```
|
|
65
|
+
1. wp_get_post → extract title, excerpt, permalink, featured_image
|
|
66
|
+
2. Compose platform-specific text variants
|
|
67
|
+
3. buf_create_update → text, media.photo, profile_ids, scheduled_at
|
|
68
|
+
```
|
|
69
|
+
|
|
70
|
+
### Blog → Transactional Notification (SendGrid)
|
|
71
|
+
|
|
72
|
+
For notifying specific users about relevant new content:
|
|
73
|
+
|
|
74
|
+
```
|
|
75
|
+
1. wp_get_post → extract title, excerpt, permalink
|
|
76
|
+
2. sg_list_contacts → find users matching content category
|
|
77
|
+
3. sg_send_email → template with post title, excerpt, read-more link
|
|
78
|
+
```
|
|
79
|
+
|
|
80
|
+
## Scheduling Strategies
|
|
81
|
+
|
|
82
|
+
### Immediate distribution
|
|
83
|
+
|
|
84
|
+
Publish to all channels as soon as the WordPress post goes live. Best for breaking news or time-sensitive content.
|
|
85
|
+
|
|
86
|
+
```
|
|
87
|
+
1. WordPress publish event triggers distribution
|
|
88
|
+
2. mc_send_campaign (send now)
|
|
89
|
+
3. buf_create_update (no scheduled_at → immediate queue)
|
|
90
|
+
4. sg_send_email (immediate delivery)
|
|
91
|
+
```
|
|
92
|
+
|
|
93
|
+
### Staggered distribution
|
|
94
|
+
|
|
95
|
+
Spread distribution across hours or days to maximize reach across time zones and channel algorithms.
|
|
96
|
+
|
|
97
|
+
```
|
|
98
|
+
Day 0, Hour 0: Blog post published
|
|
99
|
+
Day 0, Hour 1: buf_create_update → Twitter (immediate engagement)
|
|
100
|
+
Day 0, Hour 4: buf_create_update → LinkedIn (business hours)
|
|
101
|
+
Day 1, Hour 10: mc_send_campaign → Newsletter (Tuesday 10am optimal)
|
|
102
|
+
Day 3: buf_create_update → Facebook (extend reach)
|
|
103
|
+
Day 7: sg_send_email → Re-engagement for non-openers
|
|
104
|
+
```
|
|
105
|
+
|
|
106
|
+
### Evergreen rotation
|
|
107
|
+
|
|
108
|
+
Re-distribute high-performing content on a recurring schedule:
|
|
109
|
+
|
|
110
|
+
```
|
|
111
|
+
1. buf_list_sent → identify posts with highest engagement
|
|
112
|
+
2. Filter for content older than 30 days (avoid fatigue)
|
|
113
|
+
3. buf_create_update → re-share with updated text
|
|
114
|
+
4. Track performance to retire content below threshold
|
|
115
|
+
```
|
|
116
|
+
|
|
117
|
+
## Multi-Channel Distribution Workflow
|
|
118
|
+
|
|
119
|
+
### Full orchestration example
|
|
120
|
+
|
|
121
|
+
Distribute a new blog post across all three services:
|
|
122
|
+
|
|
123
|
+
```
|
|
124
|
+
# 1. Fetch source content
|
|
125
|
+
wp_get_post id=42 → { title, excerpt, content, permalink, featured_image }
|
|
126
|
+
|
|
127
|
+
# 2. Email campaign (Mailchimp)
|
|
128
|
+
mc_create_campaign type="regular" audience_id=... subject="{title}"
|
|
129
|
+
mc_set_campaign_content campaign_id=... html="{formatted_content}"
|
|
130
|
+
mc_send_campaign campaign_id=... schedule_time="2026-03-15T10:00:00Z"
|
|
131
|
+
|
|
132
|
+
# 3. Social posts (Buffer)
|
|
133
|
+
buf_create_update profile_ids=[twitter] text="{short_text}" media.photo="{featured_image}"
|
|
134
|
+
buf_create_update profile_ids=[linkedin] text="{long_text}" scheduled_at="2026-03-15T14:00:00Z"
|
|
135
|
+
|
|
136
|
+
# 4. Notification email (SendGrid)
|
|
137
|
+
sg_send_email to="vip-subscribers" template_id="d-newpost" dynamic_template_data={title, excerpt, permalink}
|
|
138
|
+
```
|
|
139
|
+
|
|
140
|
+
### Coordination checklist
|
|
141
|
+
|
|
142
|
+
- [ ] Source content finalized and published on WordPress
|
|
143
|
+
- [ ] Email campaign created and content set (Mailchimp)
|
|
144
|
+
- [ ] Social posts queued for each target profile (Buffer)
|
|
145
|
+
- [ ] Transactional notifications sent to relevant user segments (SendGrid)
|
|
146
|
+
- [ ] UTM parameters appended to all outbound URLs
|
|
147
|
+
- [ ] Analytics tracking confirmed for each channel
|
|
148
|
+
|
|
149
|
+
## Best Practices
|
|
150
|
+
|
|
151
|
+
- **Single source of truth**: Always fetch content from WordPress (`wp_get_post`) rather than duplicating content manually
|
|
152
|
+
- **URL tracking**: Append UTM parameters per channel (`utm_source=mailchimp`, `utm_source=buffer`, `utm_source=sendgrid`)
|
|
153
|
+
- **Content freshness**: Verify post status is `publish` before distributing; draft content should never reach channels
|
|
154
|
+
- **Error handling**: If one channel fails, proceed with others; log failures and retry individually
|
|
155
|
+
- **Preview before send**: Use Mailchimp preview and Buffer draft features to review formatting before live distribution
|
|
156
|
+
- **Audience overlap**: Be mindful that users may follow multiple channels; vary the messaging slightly to avoid fatigue
|
|
@@ -0,0 +1,208 @@
|
|
|
1
|
+
# Distribution Analytics
|
|
2
|
+
|
|
3
|
+
## Overview
|
|
4
|
+
|
|
5
|
+
Distribution analytics measure the effectiveness of content distributed across email (Mailchimp, SendGrid) and social (Buffer) channels. Tracking performance per channel enables data-driven decisions on content strategy, send timing, and audience targeting.
|
|
6
|
+
|
|
7
|
+
## Mailchimp Campaign Reports
|
|
8
|
+
|
|
9
|
+
### Get campaign performance
|
|
10
|
+
|
|
11
|
+
```
|
|
12
|
+
Tool: mc_get_campaign_report
|
|
13
|
+
Params:
|
|
14
|
+
campaign_id: "campaign_xyz"
|
|
15
|
+
Returns:
|
|
16
|
+
emails_sent: 1250
|
|
17
|
+
opens:
|
|
18
|
+
total: 487
|
|
19
|
+
unique: 412
|
|
20
|
+
rate: 0.33
|
|
21
|
+
clicks:
|
|
22
|
+
total: 98
|
|
23
|
+
unique: 76
|
|
24
|
+
rate: 0.061
|
|
25
|
+
bounces:
|
|
26
|
+
hard: 3
|
|
27
|
+
soft: 12
|
|
28
|
+
unsubscribes: 2
|
|
29
|
+
forwards: 5
|
|
30
|
+
abuse_reports: 0
|
|
31
|
+
```
|
|
32
|
+
|
|
33
|
+
### Key Mailchimp metrics
|
|
34
|
+
|
|
35
|
+
| Metric | Calculation | Benchmark |
|
|
36
|
+
|--------|-------------|-----------|
|
|
37
|
+
| Open rate | Unique opens / Delivered | 20-25% |
|
|
38
|
+
| Click rate | Unique clicks / Delivered | 2.5-5% |
|
|
39
|
+
| Click-to-open rate | Unique clicks / Unique opens | 10-15% |
|
|
40
|
+
| Bounce rate | (Hard + Soft bounces) / Sent | < 2% |
|
|
41
|
+
| Unsubscribe rate | Unsubscribes / Delivered | < 0.5% |
|
|
42
|
+
| List growth rate | (New - Unsubscribes) / Total | > 2% monthly |
|
|
43
|
+
|
|
44
|
+
### Analyzing campaign trends
|
|
45
|
+
|
|
46
|
+
Compare multiple campaigns to identify patterns:
|
|
47
|
+
|
|
48
|
+
```
|
|
49
|
+
# Fetch reports for recent campaigns
|
|
50
|
+
mc_get_campaign_report campaign_id="campaign_1" → { open_rate: 0.28, click_rate: 0.04 }
|
|
51
|
+
mc_get_campaign_report campaign_id="campaign_2" → { open_rate: 0.35, click_rate: 0.07 }
|
|
52
|
+
mc_get_campaign_report campaign_id="campaign_3" → { open_rate: 0.22, click_rate: 0.03 }
|
|
53
|
+
|
|
54
|
+
# Campaign 2 outperformed — analyze: subject line? send time? content type?
|
|
55
|
+
```
|
|
56
|
+
|
|
57
|
+
## Buffer Analytics
|
|
58
|
+
|
|
59
|
+
### Get social profile analytics
|
|
60
|
+
|
|
61
|
+
```
|
|
62
|
+
Tool: buf_get_analytics
|
|
63
|
+
Params:
|
|
64
|
+
profile_id: "profile_abc123"
|
|
65
|
+
Returns:
|
|
66
|
+
posts_count: 45
|
|
67
|
+
total_reach: 12500
|
|
68
|
+
total_engagement: 890
|
|
69
|
+
total_clicks: 234
|
|
70
|
+
per_post_average:
|
|
71
|
+
reach: 278
|
|
72
|
+
engagement: 19.8
|
|
73
|
+
clicks: 5.2
|
|
74
|
+
```
|
|
75
|
+
|
|
76
|
+
### Key Buffer metrics
|
|
77
|
+
|
|
78
|
+
| Metric | Description | Benchmark |
|
|
79
|
+
|--------|-------------|-----------|
|
|
80
|
+
| Reach | Number of unique users who saw the post | Varies by platform |
|
|
81
|
+
| Engagement | Likes + comments + shares + retweets | 1-3% of reach |
|
|
82
|
+
| Engagement rate | Engagement / Reach | 1-5% (varies by platform) |
|
|
83
|
+
| Clicks | Link clicks from post | 0.5-2% of reach |
|
|
84
|
+
| Click-through rate | Clicks / Reach | 1-3% |
|
|
85
|
+
| Best time to post | Time slot with highest engagement | Platform-specific |
|
|
86
|
+
|
|
87
|
+
### Identifying top-performing content
|
|
88
|
+
|
|
89
|
+
```
|
|
90
|
+
Tool: buf_list_sent
|
|
91
|
+
Params:
|
|
92
|
+
profile_id: "profile_abc123"
|
|
93
|
+
count: 50
|
|
94
|
+
|
|
95
|
+
# Sort results by engagement metrics to find top performers
|
|
96
|
+
# Re-share top content using buf_create_update with updated text
|
|
97
|
+
```
|
|
98
|
+
|
|
99
|
+
## SendGrid Statistics
|
|
100
|
+
|
|
101
|
+
### Get email delivery stats
|
|
102
|
+
|
|
103
|
+
```
|
|
104
|
+
Tool: sg_get_stats
|
|
105
|
+
Params:
|
|
106
|
+
start_date: "2026-03-01"
|
|
107
|
+
end_date: "2026-03-15"
|
|
108
|
+
Returns:
|
|
109
|
+
- date: "2026-03-01"
|
|
110
|
+
metrics:
|
|
111
|
+
requests: 150
|
|
112
|
+
delivered: 148
|
|
113
|
+
opens: 52
|
|
114
|
+
unique_opens: 45
|
|
115
|
+
clicks: 12
|
|
116
|
+
unique_clicks: 10
|
|
117
|
+
bounces: 2
|
|
118
|
+
spam_reports: 0
|
|
119
|
+
blocks: 0
|
|
120
|
+
```
|
|
121
|
+
|
|
122
|
+
### Key SendGrid metrics
|
|
123
|
+
|
|
124
|
+
| Metric | Calculation | Benchmark |
|
|
125
|
+
|--------|-------------|-----------|
|
|
126
|
+
| Delivery rate | Delivered / Requests | > 95% |
|
|
127
|
+
| Open rate | Unique opens / Delivered | 15-25% (transactional: 40-60%) |
|
|
128
|
+
| Click rate | Unique clicks / Delivered | 2-5% |
|
|
129
|
+
| Bounce rate | Bounces / Requests | < 3% |
|
|
130
|
+
| Spam complaint rate | Spam reports / Delivered | < 0.1% |
|
|
131
|
+
| Block rate | Blocks / Requests | < 1% |
|
|
132
|
+
|
|
133
|
+
### Transactional vs marketing benchmarks
|
|
134
|
+
|
|
135
|
+
Transactional emails (welcome, order confirmation) consistently outperform marketing emails:
|
|
136
|
+
|
|
137
|
+
| Type | Open Rate | Click Rate |
|
|
138
|
+
|------|-----------|------------|
|
|
139
|
+
| Transactional | 40-60% | 10-20% |
|
|
140
|
+
| Marketing | 15-25% | 2-5% |
|
|
141
|
+
|
|
142
|
+
## Cross-Channel Performance Comparison
|
|
143
|
+
|
|
144
|
+
### Unified metrics dashboard
|
|
145
|
+
|
|
146
|
+
Build a cross-channel view by combining data from all three services:
|
|
147
|
+
|
|
148
|
+
```
|
|
149
|
+
# Email (Mailchimp campaigns)
|
|
150
|
+
mc_get_campaign_report → opens, clicks, unsubscribes
|
|
151
|
+
|
|
152
|
+
# Social (Buffer)
|
|
153
|
+
buf_get_analytics → reach, engagement, clicks
|
|
154
|
+
|
|
155
|
+
# Transactional (SendGrid)
|
|
156
|
+
sg_get_stats → deliveries, opens, clicks
|
|
157
|
+
```
|
|
158
|
+
|
|
159
|
+
### Channel comparison table
|
|
160
|
+
|
|
161
|
+
| Channel | Reach | Engagement Rate | Click Rate | Cost per Click |
|
|
162
|
+
|---------|-------|-----------------|------------|----------------|
|
|
163
|
+
| Email (Mailchimp) | Audience size | Open rate 20-25% | 2.5-5% | Low |
|
|
164
|
+
| Social (Buffer) | Follower count + viral | 1-5% | 0.5-2% | Free (organic) |
|
|
165
|
+
| Transactional (SendGrid) | Per-event | 40-60% open | 10-20% | Per email |
|
|
166
|
+
|
|
167
|
+
### Attribution tracking
|
|
168
|
+
|
|
169
|
+
Use UTM parameters to track which channel drives conversions in WordPress/WooCommerce:
|
|
170
|
+
|
|
171
|
+
| Channel | UTM Source | UTM Medium | UTM Campaign |
|
|
172
|
+
|---------|-----------|------------|--------------|
|
|
173
|
+
| Mailchimp | `mailchimp` | `email` | `{campaign_name}` |
|
|
174
|
+
| Buffer | `buffer` | `social` | `{post_slug}` |
|
|
175
|
+
| SendGrid | `sendgrid` | `email` | `{template_name}` |
|
|
176
|
+
|
|
177
|
+
## KPIs and Benchmarks
|
|
178
|
+
|
|
179
|
+
### Weekly KPIs to track
|
|
180
|
+
|
|
181
|
+
| KPI | Target | Tool |
|
|
182
|
+
|-----|--------|------|
|
|
183
|
+
| Email open rate | > 22% | `mc_get_campaign_report` |
|
|
184
|
+
| Email click rate | > 3% | `mc_get_campaign_report` |
|
|
185
|
+
| Social engagement rate | > 2% | `buf_get_analytics` |
|
|
186
|
+
| Email delivery rate | > 95% | `sg_get_stats` |
|
|
187
|
+
| List growth (net) | > 50/week | `mc_get_audience_members` count delta |
|
|
188
|
+
| Content distributed | 3+ posts/week | Track distribution events |
|
|
189
|
+
|
|
190
|
+
### Red flags requiring action
|
|
191
|
+
|
|
192
|
+
| Signal | Threshold | Action |
|
|
193
|
+
|--------|-----------|--------|
|
|
194
|
+
| Open rate drop | < 15% | Review subject lines, check deliverability |
|
|
195
|
+
| High unsubscribe rate | > 0.5% | Reduce frequency, improve segmentation |
|
|
196
|
+
| Bounce rate spike | > 5% | Clean list, verify new signups |
|
|
197
|
+
| Spam complaints | > 0.1% | Review content, check opt-in process |
|
|
198
|
+
| Social engagement decline | < 0.5% | Refresh content format, test new posting times |
|
|
199
|
+
| Delivery blocks | > 1% | Check domain reputation, review SPF/DKIM |
|
|
200
|
+
|
|
201
|
+
## Best Practices
|
|
202
|
+
|
|
203
|
+
- **Weekly review cadence**: Pull analytics every Monday; compare to previous week and 4-week average
|
|
204
|
+
- **A/B test systematically**: Test one variable at a time (subject line, send time, content format) and track results in `mc_get_campaign_report`
|
|
205
|
+
- **Channel-specific goals**: Email optimizes for clicks; social optimizes for engagement; transactional optimizes for delivery
|
|
206
|
+
- **Sunset inactive contacts**: After 90 days of no opens, move contacts to a re-engagement segment or suppress
|
|
207
|
+
- **Document learnings**: Record what subject lines, content types, and send times produce the best results
|
|
208
|
+
- **Automate reporting**: Build a weekly script that calls `mc_get_campaign_report`, `buf_get_analytics`, and `sg_get_stats` to generate a unified report
|