jeremylongshore/claude-code-plugins-plus-skills
customerio-pack
plugins/saas-packs/customerio-pack/skills/customerio-core-feature/SKILL.md
January 22, 2026
Select agents to install to:
npx add-skill https://github.com/jeremylongshore/claude-code-plugins-plus-skills/blob/main/plugins/saas-packs/customerio-pack/skills/customerio-core-feature/SKILL.md -a claude-code --skill customerio-core-featureInstallation paths:
.claude/skills/customerio-core-feature/# Customer.io Core Feature Integration
## Overview
Implement Customer.io core features: segments, transactional messaging, data pipelines, and broadcast campaigns.
## Prerequisites
- Customer.io SDK configured
- Understanding of customer data model
- App API credentials for transactional emails
## Instructions
### Feature 1: Transactional Messages
```typescript
// lib/customerio-transactional.ts
import { APIClient, RegionUS, SendEmailRequest } from '@customerio/track';
const apiClient = new APIClient(process.env.CUSTOMERIO_APP_API_KEY!, {
region: RegionUS
});
interface TransactionalEmailOptions {
to: string;
transactionalMessageId: string;
messageData?: Record<string, any>;
identifiers?: { id?: string; email?: string };
}
export async function sendTransactionalEmail(options: TransactionalEmailOptions) {
const request: SendEmailRequest = {
to: options.to,
transactional_message_id: options.transactionalMessageId,
message_data: options.messageData,
identifiers: options.identifiers
};
return apiClient.sendEmail(request);
}
// Usage examples
// Password reset
await sendTransactionalEmail({
to: 'user@example.com',
transactionalMessageId: 'password_reset',
messageData: {
reset_link: 'https://app.example.com/reset?token=abc123',
expiry_hours: 24
}
});
// Order confirmation
await sendTransactionalEmail({
to: 'customer@example.com',
transactionalMessageId: 'order_confirmation',
messageData: {
order_id: 'ORD-12345',
items: [
{ name: 'Product A', quantity: 2, price: 29.99 }
],
total: 59.98
},
identifiers: { id: 'user-456' }
});
```
### Feature 2: Segments
```typescript
// lib/customerio-segments.ts
import { TrackClient } from '@customerio/track';
// Update user attributes for segment membership
export async function updateUserForSegments(
client: TrackClient,
userId: string,
attributes: {
// Engagement metrics
last_active_at?: number;
session_count?: number;
total_t