🚀 Socket Launch Week Day 5:Introducing Repository Access Permissions and Custom Roles.Learn more
Sign In

@robinpath/mailchimp

Package Overview
Dependencies
Maintainers
4
Versions
4
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@robinpath/mailchimp - npm Package Compare versions

Comparing version
0.1.2
to
0.3.0
+6
dist/index.d.ts
import type { ModuleAdapter } from "@robinpath/core";
declare const MailchimpModule: ModuleAdapter;
export default MailchimpModule;
export { MailchimpModule };
export { MailchimpFunctions, MailchimpFunctionMetadata, MailchimpModuleMetadata, MailchimpCredentialTypes, } from "./mailchimp.js";
//# sourceMappingURL=index.d.ts.map
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,iBAAiB,CAAC;AASrD,QAAA,MAAM,eAAe,EAAE,aAQtB,CAAC;AAEF,eAAe,eAAe,CAAC;AAC/B,OAAO,EAAE,eAAe,EAAE,CAAC;AAC3B,OAAO,EACL,kBAAkB,EAClB,yBAAyB,EACzB,uBAAuB,EACvB,wBAAwB,GACzB,MAAM,gBAAgB,CAAC"}
import { MailchimpFunctions, MailchimpFunctionMetadata, MailchimpModuleMetadata, MailchimpCredentialTypes, configureMailchimp, } from "./mailchimp.js";
const MailchimpModule = {
name: "mailchimp",
functions: MailchimpFunctions,
functionMetadata: MailchimpFunctionMetadata,
moduleMetadata: MailchimpModuleMetadata,
credentialTypes: MailchimpCredentialTypes,
configure: configureMailchimp,
global: false,
};
export default MailchimpModule;
export { MailchimpModule };
export { MailchimpFunctions, MailchimpFunctionMetadata, MailchimpModuleMetadata, MailchimpCredentialTypes, } from "./mailchimp.js";
//# sourceMappingURL=index.js.map
{"version":3,"file":"index.js","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AACA,OAAO,EACL,kBAAkB,EAClB,yBAAyB,EACzB,uBAAuB,EACvB,wBAAwB,EACxB,kBAAkB,GACnB,MAAM,gBAAgB,CAAC;AAExB,MAAM,eAAe,GAAkB;IACrC,IAAI,EAAE,WAAW;IACjB,SAAS,EAAE,kBAAkB;IAC7B,gBAAgB,EAAE,yBAAyB;IAC3C,cAAc,EAAE,uBAAuB;IACvC,eAAe,EAAE,wBAAwB;IACzC,SAAS,EAAE,kBAAkB;IAC7B,MAAM,EAAE,KAAK;CACd,CAAC;AAEF,eAAe,eAAe,CAAC;AAC/B,OAAO,EAAE,eAAe,EAAE,CAAC;AAC3B,OAAO,EACL,kBAAkB,EAClB,yBAAyB,EACzB,uBAAuB,EACvB,wBAAwB,GACzB,MAAM,gBAAgB,CAAC"}
/**
* RobinPath Mailchimp Module (Node port)
*
* Mailchimp Marketing API v3.0 — audiences (lists), members (subscribers),
* tags. Mirror of packages/php/mailchimp/src/index.php for the WordPress
* plugin; shares the same credential contract, metadata shape, and error
* taxonomy so the visual editor can render both identically.
*
* Mailchimp's API key format encodes the data center as a suffix:
* `abc123def456-us21` → base URL https://us21.api.mailchimp.com/3.0/
*
* Subscribers are addressed by their MD5(lowercase email) "subscriber hash".
*
* Every handler takes a credential slug as its first argument; the module
* resolves the stored API key at call time via the injected ModuleHost.
*
* Credential type declared by this module:
* - mailchimp : { api_key, server_prefix? }
*/
import type { BuiltinHandler, CredentialTypeSchema, FunctionMetadata, ModuleHost, ModuleMetadata } from "@robinpath/core";
export declare function configureMailchimp(h: ModuleHost): void;
export declare const MailchimpFunctions: Record<string, BuiltinHandler>;
export declare const MailchimpCredentialTypes: CredentialTypeSchema[];
export declare const MailchimpFunctionMetadata: Record<string, FunctionMetadata>;
export declare const MailchimpModuleMetadata: ModuleMetadata;
//# sourceMappingURL=mailchimp.d.ts.map
{"version":3,"file":"mailchimp.d.ts","sourceRoot":"","sources":["../src/mailchimp.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAGH,OAAO,KAAK,EACV,cAAc,EACd,oBAAoB,EACpB,gBAAgB,EAChB,UAAU,EACV,cAAc,EAEf,MAAM,iBAAiB,CAAC;AAezB,wBAAgB,kBAAkB,CAAC,CAAC,EAAE,UAAU,GAAG,IAAI,CAEtD;AAgVD,eAAO,MAAM,kBAAkB,EAAE,MAAM,CAAC,MAAM,EAAE,cAAc,CAU7D,CAAC;AAIF,eAAO,MAAM,wBAAwB,EAAE,oBAAoB,EA2B1D,CAAC;AA6DF,eAAO,MAAM,yBAAyB,EAAE,MAAM,CAAC,MAAM,EAAE,gBAAgB,CA+QtE,CAAC;AAIF,eAAO,MAAM,uBAAuB,EAAE,cAqBrC,CAAC"}
/**
* RobinPath Mailchimp Module (Node port)
*
* Mailchimp Marketing API v3.0 — audiences (lists), members (subscribers),
* tags. Mirror of packages/php/mailchimp/src/index.php for the WordPress
* plugin; shares the same credential contract, metadata shape, and error
* taxonomy so the visual editor can render both identically.
*
* Mailchimp's API key format encodes the data center as a suffix:
* `abc123def456-us21` → base URL https://us21.api.mailchimp.com/3.0/
*
* Subscribers are addressed by their MD5(lowercase email) "subscriber hash".
*
* Every handler takes a credential slug as its first argument; the module
* resolves the stored API key at call time via the injected ModuleHost.
*
* Credential type declared by this module:
* - mailchimp : { api_key, server_prefix? }
*/
import { createHash } from "node:crypto";
// ── Module-local state (populated by configure hook) ────────────────────
const state = {};
function host() {
if (!state.host) {
throw new Error("Mailchimp module not initialized. Pass the adapter to rp.registerModule() via loadModule so its configure() hook runs first.");
}
return state.host;
}
export function configureMailchimp(h) {
state.host = h;
}
// ── Constants ──────────────────────────────────────────────────────────
const CREDENTIAL_TYPE = "mailchimp";
function errorReturn(error, code, extra = {}) {
return { error, code, ...extra };
}
// ── Credential resolver (mirrors PHP resolveCreds) ─────────────────────
async function resolveAuth(credentialSlug) {
if (!credentialSlug) {
return errorReturn("Credential slug is required.", "credential_not_found");
}
let fields;
try {
fields = await host().credentials.get(credentialSlug);
}
catch (e) {
return errorReturn(e instanceof Error ? e.message : String(e), "credential_not_found");
}
if (!fields) {
return errorReturn(`Credential '${credentialSlug}' not found.`, "credential_not_found");
}
const apiKey = String(fields.api_key ?? "");
if (!apiKey) {
return errorReturn("Credential has no `api_key` field.", "api_key_missing");
}
// Prefer an explicit server_prefix; otherwise derive it from the key suffix.
let serverPrefix = String(fields.server_prefix ?? "");
if (!serverPrefix) {
const parts = apiKey.split("-");
const dc = parts.length >= 2 ? parts[parts.length - 1] : "";
if (!dc) {
return errorReturn("API key must contain a `-dc` suffix (e.g. `abc123-us21`).", "api_key_malformed");
}
serverPrefix = dc;
}
return { apiKey, serverPrefix };
}
// ── HTTP helper (normalized envelope, never throws for API errors) ─────
async function http(apiKey, serverPrefix, method, pathAndQuery, body) {
const base = `https://${serverPrefix}.api.mailchimp.com/3.0/`;
const basicAuth = Buffer.from(`anystring:${apiKey}`).toString("base64");
const headers = {
Authorization: `Basic ${basicAuth}`,
Accept: "application/json",
};
if (body !== undefined && body !== null) {
headers["Content-Type"] = "application/json";
}
const init = { method, headers };
if (body !== undefined && body !== null) {
init.body = JSON.stringify(body);
}
let response;
try {
response = await fetch(`${base}${pathAndQuery.replace(/^\/+/, "")}`, init);
}
catch (e) {
return errorReturn(e instanceof Error ? e.message : String(e), "transport");
}
if (response.status === 204) {
return { ok: true };
}
const raw = await response.text();
let decoded;
try {
decoded = raw ? JSON.parse(raw) : null;
}
catch {
decoded = { raw };
}
if (response.status >= 200 && response.status < 300) {
if (decoded && typeof decoded === "object")
return decoded;
return { raw };
}
const errObj = (decoded && typeof decoded === "object")
? decoded
: {};
let message = `Mailchimp returned HTTP ${response.status}.`;
if (typeof errObj.detail === "string") {
message = errObj.detail;
}
else if (typeof errObj.title === "string") {
message = errObj.title;
}
const code = response.status === 429 ? "rate_limited" : "mailchimp_error";
return errorReturn(message, code, {
status: response.status,
mailchimp_error: errObj,
});
}
// ── Internal helpers ───────────────────────────────────────────────────
function md5Hex(input) {
return createHash("md5").update(input).digest("hex");
}
function subscriberHash(email) {
return md5Hex(email.toLowerCase().trim());
}
function encodeId(v) {
return encodeURIComponent(String(v ?? ""));
}
/**
* Shared caller — resolves the credential, invokes http(), passes through.
*/
async function call(cred, method, path, body) {
const resolved = await resolveAuth(cred);
if ("error" in resolved)
return resolved;
return http(resolved.apiKey, resolved.serverPrefix, method, path, body);
}
function isPlainObject(v) {
return !!v && typeof v === "object" && !Array.isArray(v);
}
// ── Handlers ───────────────────────────────────────────────────────────
const listAudiences = async (args) => {
const cred = String(args[0] ?? "");
const result = await call(cred, "GET", "lists?count=100", null);
if (result && typeof result === "object" && "error" in result) {
return result;
}
if (result && typeof result === "object" && Array.isArray(result.lists)) {
return result.lists;
}
return result;
};
const getAudience = async (args) => {
const cred = String(args[0] ?? "");
const listId = encodeId(args[1]);
return (await call(cred, "GET", `lists/${listId}`, null));
};
const getMember = async (args) => {
const cred = String(args[0] ?? "");
const listId = encodeId(args[1]);
const email = String(args[2] ?? "");
if (!email) {
return errorReturn("Email is required.", "validation_failed");
}
return (await call(cred, "GET", `lists/${listId}/members/${subscriberHash(email)}`, null));
};
const addMember = async (args) => {
const cred = String(args[0] ?? "");
const listId = encodeId(args[1]);
const email = String(args[2] ?? "");
const opts = (isPlainObject(args[3]) ? args[3] : {});
if (!email) {
return errorReturn("Email is required.", "validation_failed");
}
const status = String(opts.status ?? "subscribed");
// Spread caller opts first, then overwrite the canonical keys so a stray
// `email_address` / `status` in opts cannot fight the resolved values.
const body = {
...opts,
email_address: email,
status,
// status_if_new is the PUT-upsert variant — only applied on create.
status_if_new: status,
};
return (await call(cred, "PUT", `lists/${listId}/members/${subscriberHash(email)}`, body));
};
const updateMember = async (args) => {
const cred = String(args[0] ?? "");
const listId = encodeId(args[1]);
const email = String(args[2] ?? "");
const fields = (isPlainObject(args[3]) ? args[3] : {});
if (!email) {
return errorReturn("Email is required.", "validation_failed");
}
if (Object.keys(fields).length === 0) {
return errorReturn("No fields to update.", "validation_failed");
}
return (await call(cred, "PATCH", `lists/${listId}/members/${subscriberHash(email)}`, fields));
};
const removeMember = async (args) => {
const cred = String(args[0] ?? "");
const listId = encodeId(args[1]);
const email = String(args[2] ?? "");
const permanent = Boolean(args[3] ?? false);
if (!email) {
return errorReturn("Email is required.", "validation_failed");
}
const hash = subscriberHash(email);
if (permanent) {
return (await call(cred, "POST", `lists/${listId}/members/${hash}/actions/delete-permanent`, null));
}
return (await call(cred, "PATCH", `lists/${listId}/members/${hash}`, { status: "unsubscribed" }));
};
const listMembers = async (args) => {
const cred = String(args[0] ?? "");
const listId = encodeId(args[1]);
const opts = (isPlainObject(args[2]) ? args[2] : {});
const params = new URLSearchParams();
const count = opts.count !== undefined ? Number(opts.count) | 0 : 10;
if (count)
params.set("count", String(count));
if (opts.offset !== undefined && opts.offset !== null && opts.offset !== "") {
params.set("offset", String(Number(opts.offset) | 0));
}
if (opts.status !== undefined && opts.status !== null && opts.status !== "") {
params.set("status", String(opts.status));
}
if (opts.email_address !== undefined && opts.email_address !== null && opts.email_address !== "") {
params.set("email_address", String(opts.email_address));
}
if (opts.since_timestamp_opt !== undefined && opts.since_timestamp_opt !== null && opts.since_timestamp_opt !== "") {
params.set("since_timestamp_opt", String(opts.since_timestamp_opt));
}
if (Array.isArray(opts.fields) && opts.fields.length > 0) {
params.set("fields", opts.fields.map((v) => String(v)).join(","));
}
if (Array.isArray(opts.exclude_fields) && opts.exclude_fields.length > 0) {
params.set("exclude_fields", opts.exclude_fields.map((v) => String(v)).join(","));
}
const qs = params.toString();
const path = `lists/${listId}/members${qs ? `?${qs}` : ""}`;
return (await call(cred, "GET", path, null));
};
async function tagAction(args, status) {
const cred = String(args[0] ?? "");
const listId = encodeId(args[1]);
const email = String(args[2] ?? "");
const tagsInput = args[3];
if (!email) {
return errorReturn("Email is required.", "validation_failed");
}
const names = Array.isArray(tagsInput)
? tagsInput
: tagsInput !== undefined && tagsInput !== null
? [tagsInput]
: [];
const tagsBody = names.map((name) => ({ name: String(name), status }));
return call(cred, "POST", `lists/${listId}/members/${subscriberHash(email)}/tags`, { tags: tagsBody });
}
const addTag = async (args) => {
return (await tagAction(args, "active"));
};
const removeTag = async (args) => {
return (await tagAction(args, "inactive"));
};
// ── Exports: functions map ─────────────────────────────────────────────
export const MailchimpFunctions = {
listAudiences,
getAudience,
getMember,
addMember,
updateMember,
removeMember,
listMembers,
addTag,
removeTag,
};
// ── Exports: credential types ──────────────────────────────────────────
export const MailchimpCredentialTypes = [
{
slug: CREDENTIAL_TYPE,
title: "Mailchimp",
icon: "mail",
fields: [
{
name: "api_key",
title: "API Key",
type: "password",
required: true,
placeholder: "abc123def456-us21",
description: "Find under Account → Extras → API keys. The `-us21` suffix is the data center — keep it intact.",
pattern: "^[a-z0-9]+-[a-z]+\\d+$",
},
{
name: "server_prefix",
title: "Server prefix (optional)",
type: "text",
required: false,
placeholder: "us21",
description: "Optional. Overrides the data center derived from the API key suffix.",
},
],
},
];
// ── Shared parameter metadata ──────────────────────────────────────────
const credentialParam = {
name: "credential",
title: "Credential",
description: "Slug of a saved `mailchimp` credential.",
dataType: "string",
formInputType: "resource",
required: true,
allowExpression: true,
placeholder: "my_mailchimp",
resource: {
type: "credential",
listFn: "credential.list",
modes: ["list", "expression"],
searchable: true,
filter: { type: CREDENTIAL_TYPE },
},
};
const listIdParam = {
name: "listId",
title: "Audience",
description: "Audience (list) ID. Find via `listAudiences`.",
dataType: "string",
formInputType: "resource",
required: true,
allowExpression: true,
placeholder: "a1b2c3d4e5",
resource: {
type: "mailchimp_audience",
listFn: "mailchimp.listAudiences",
modes: ["list", "byId", "expression"],
searchable: true,
},
};
const emailParam = {
name: "email",
title: "Email",
description: "Subscriber email address.",
dataType: "string",
formInputType: "text",
required: true,
allowExpression: true,
placeholder: "someone@example.com",
};
const commonErrors = {
credential_not_found: "No credential with that slug exists in the vault.",
api_key_missing: "The credential exists but has no `api_key` field.",
api_key_malformed: "API key has no `-dc` suffix — cannot derive data center.",
transport: "Network failure calling api.mailchimp.com.",
mailchimp_error: "Mailchimp returned an error — see `mailchimp_error.detail`.",
rate_limited: "Rate limit hit — slow down.",
};
// ── Exports: function metadata ─────────────────────────────────────────
export const MailchimpFunctionMetadata = {
listAudiences: {
title: "List audiences",
summary: "List all audiences (lists) in the account",
description: "Calls `GET /lists`.",
group: "audiences",
action: "query",
icon: "list",
capability: "manage_options",
sideEffects: ["makes_http_call"],
idempotent: true,
since: "1.0.0",
tags: ["mailchimp", "audience", "list"],
parameters: [credentialParam],
returnType: "array",
returnDescription: "Array of audiences with `{id, name, stats: {member_count}, …}`.",
errors: commonErrors,
example: 'mailchimp.listAudiences "my_mailchimp"',
},
getAudience: {
title: "Get audience",
summary: "Retrieve a single audience by ID",
description: "Calls `GET /lists/{id}`.",
group: "audiences",
action: "read",
icon: "folder",
capability: "manage_options",
sideEffects: ["makes_http_call"],
idempotent: true,
since: "1.0.0",
tags: ["mailchimp", "audience"],
parameters: [credentialParam, listIdParam],
returnType: "object",
errors: commonErrors,
example: 'mailchimp.getAudience "my_mailchimp" "a1b2c3"',
},
getMember: {
title: "Get member",
summary: "Look up a subscriber by email",
description: "Calls `GET /lists/{id}/members/{md5(email)}`. Returns 404 as `{error: \"not_found\"}` if not subscribed.",
group: "members",
action: "read",
icon: "user",
capability: "manage_options",
sideEffects: ["makes_http_call"],
idempotent: true,
since: "1.0.0",
tags: ["mailchimp", "member", "subscriber"],
parameters: [credentialParam, listIdParam, emailParam],
returnType: "object",
errors: commonErrors,
example: 'mailchimp.getMember "my_mailchimp" "a1b2c3" "ada@example.com"',
},
addMember: {
title: "Add or upsert member",
summary: "Subscribe an email to an audience",
description: 'Calls `PUT /lists/{id}/members/{hash}` (idempotent upsert). For double opt-in, set `status: "pending"`. For single opt-in, `status: "subscribed"`.',
group: "members",
action: "write",
icon: "user-plus",
capability: "manage_options",
sideEffects: ["makes_http_call"],
idempotent: true,
since: "1.0.0",
tags: ["mailchimp", "subscribe", "member"],
parameters: [
credentialParam,
listIdParam,
emailParam,
{
name: "options",
title: "Options",
description: "Recognized keys:\n status : 'subscribed' (default) | 'pending' (double opt-in) | 'unsubscribed' | 'cleaned'\n merge_fields : { FNAME: 'Ada', LNAME: 'Lovelace', PHONE: '…' }\n interests : { interest_id: bool }\n language : 'en'\n tags : ['vip','beta']\n ip_signup : '1.2.3.4'\n vip : bool",
dataType: "object",
formInputType: "json",
required: false,
allowExpression: true,
language: "json",
rows: 6,
},
],
returnType: "object",
returnDescription: "The Mailchimp Member object.",
errors: commonErrors,
examples: [
{
title: "Subscribe form submitter",
code: 'mailchimp.addMember "my_mailchimp" "a1b2c3" {{ form.email }} {\n status: "pending",\n merge_fields: {FNAME: {{ form.first_name }}}\n}',
},
],
example: 'mailchimp.addMember "my_mailchimp" "a1b2c3" "a@b.com"',
},
updateMember: {
title: "Update member",
summary: "Patch fields on an existing subscriber",
description: "Calls `PATCH /lists/{id}/members/{hash}`. Same field shape as `addMember`.",
group: "members",
action: "write",
icon: "edit-3",
capability: "manage_options",
sideEffects: ["makes_http_call"],
idempotent: true,
since: "1.0.0",
tags: ["mailchimp", "member", "update"],
parameters: [
credentialParam,
listIdParam,
emailParam,
{
name: "fields",
title: "Fields",
description: "Same keys as `addMember` options. Only the fields you supply are changed.",
dataType: "object",
formInputType: "json",
required: true,
allowExpression: true,
language: "json",
rows: 5,
},
],
returnType: "object",
errors: commonErrors,
example: 'mailchimp.updateMember "my_mailchimp" "a1b2c3" "a@b.com" {merge_fields:{FNAME:"Ada"}}',
},
removeMember: {
title: "Unsubscribe member",
summary: "Mark a subscriber as unsubscribed (does not delete)",
description: "Calls `PATCH /lists/{id}/members/{hash}` with `status: 'unsubscribed'`. The contact remains in the audience for re-subscription. Pass `permanent: true` to fully delete via `DELETE /lists/{id}/members/{hash}/actions/delete-permanent` instead.",
group: "members",
action: "delete",
icon: "user-minus",
capability: "manage_options",
sideEffects: ["makes_http_call"],
idempotent: true,
since: "1.0.0",
tags: ["mailchimp", "unsubscribe"],
parameters: [
credentialParam,
listIdParam,
emailParam,
{
name: "permanent",
title: "Permanent delete",
description: "Hard-delete the contact (irreversible).",
dataType: "boolean",
formInputType: "checkbox",
required: false,
defaultValue: false,
allowExpression: true,
advanced: true,
},
],
returnType: "object",
errors: commonErrors,
example: 'mailchimp.removeMember "my_mailchimp" "a1b2c3" "a@b.com"',
},
listMembers: {
title: "List members",
summary: "List subscribers in an audience (paginated)",
description: "Calls `GET /lists/{id}/members`. Returns up to 1000 per page.",
group: "members",
action: "query",
icon: "users",
capability: "manage_options",
sideEffects: ["makes_http_call"],
idempotent: true,
since: "1.0.0",
tags: ["mailchimp", "members", "list"],
parameters: [
credentialParam,
listIdParam,
{
name: "options",
title: "Options",
description: "Recognized keys:\n count : 1–1000 (default 10)\n offset : pagination offset\n status : 'subscribed' | 'unsubscribed' | 'cleaned' | 'pending' | 'transactional' | 'archived'\n email_address : exact email match\n since_timestamp_opt : ISO date — only members opted in after\n fields / exclude_fields : projection",
dataType: "object",
formInputType: "json",
required: false,
allowExpression: true,
language: "json",
rows: 5,
advanced: true,
},
],
returnType: "object",
returnDescription: "{ members: [], list_id, total_items }",
errors: commonErrors,
example: 'mailchimp.listMembers "my_mailchimp" "a1b2c3" {count: 100}',
},
addTag: {
title: "Add tag(s) to member",
summary: "Apply one or more tags to a subscriber",
description: "Calls `POST /lists/{id}/members/{hash}/tags`. Tags that don't exist are created automatically.",
group: "tags",
action: "write",
icon: "tag",
capability: "manage_options",
sideEffects: ["makes_http_call"],
idempotent: true,
since: "1.0.0",
tags: ["mailchimp", "tag"],
parameters: [
credentialParam,
listIdParam,
emailParam,
{
name: "tags",
title: "Tags",
description: "String OR array of tag names.",
dataType: "any",
formInputType: "json",
required: true,
allowExpression: true,
language: "json",
rows: 3,
},
],
returnType: "object",
returnDescription: "{ ok: true } on success.",
errors: commonErrors,
example: 'mailchimp.addTag "my_mailchimp" "a1b2c3" "a@b.com" ["vip","beta"]',
},
removeTag: {
title: "Remove tag(s) from member",
summary: "Detach tags from a subscriber",
description: 'Calls `POST /lists/{id}/members/{hash}/tags` with `status: "inactive"`. The tag itself is not deleted.',
group: "tags",
action: "delete",
icon: "tag",
capability: "manage_options",
sideEffects: ["makes_http_call"],
idempotent: true,
since: "1.0.0",
tags: ["mailchimp", "tag", "remove"],
parameters: [
credentialParam,
listIdParam,
emailParam,
{
name: "tags",
title: "Tags",
description: "String OR array of tag names.",
dataType: "any",
formInputType: "json",
required: true,
allowExpression: true,
language: "json",
rows: 3,
},
],
returnType: "object",
returnDescription: "{ ok: true } on success.",
errors: commonErrors,
example: 'mailchimp.removeTag "my_mailchimp" "a1b2c3" "a@b.com" "vip"',
},
};
// ── Exports: module metadata ───────────────────────────────────────────
export const MailchimpModuleMetadata = {
slug: "mailchimp",
title: "Mailchimp",
summary: "Audiences, members, tags — manage Mailchimp lists and subscribers",
description: "Subscribe form submitters to lists, sync user data, manage tags, and look up subscribers. Members are matched by email address (Mailchimp uses an MD5 hash internally — handled for you).\n\nFor double opt-in, use `addMember` with status `pending`. For an immediate subscription (single opt-in), use `subscribed`.",
category: "marketing",
icon: "icon.svg",
color: "#FFE01B",
version: "0.2.0",
docsUrl: "https://docs.robinpath.com/modules/mailchimp",
status: "stable",
requires: [],
minNodeVersion: "18.0.0",
credentialsType: CREDENTIAL_TYPE,
operationGroups: {
audiences: { title: "Audiences", description: "Lists of subscribers.", order: 1 },
members: { title: "Members", description: "Individual subscribers.", order: 2 },
tags: { title: "Tags", description: "Subscriber tagging.", order: 3 },
},
methods: Object.keys(MailchimpFunctions),
};
//# sourceMappingURL=mailchimp.js.map
{"version":3,"file":"mailchimp.js","sourceRoot":"","sources":["../src/mailchimp.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;GAkBG;AAEH,OAAO,EAAE,UAAU,EAAE,MAAM,aAAa,CAAC;AAUzC,2EAA2E;AAE3E,MAAM,KAAK,GAA0B,EAAE,CAAC;AAExC,SAAS,IAAI;IACX,IAAI,CAAC,KAAK,CAAC,IAAI,EAAE,CAAC;QAChB,MAAM,IAAI,KAAK,CACb,8HAA8H,CAC/H,CAAC;IACJ,CAAC;IACD,OAAO,KAAK,CAAC,IAAI,CAAC;AACpB,C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EAAE,WAAW;IACjB,KAAK,EAAE,WAAW;IAClB,OAAO,EAAE,mEAAmE;IAC5E,WAAW,EACT,yTAAyT;IAC3T,QAAQ,EAAE,WAAW;IACrB,IAAI,EAAE,UAAU;IAChB,KAAK,EAAE,SAAS;IAChB,OAAO,EAAE,OAAO;IAChB,OAAO,EAAE,8CAA8C;IACvD,MAAM,EAAE,QAAQ;IAChB,QAAQ,EAAE,EAAE;IACZ,cAAc,EAAE,QAAQ;IACxB,eAAe,EAAE,eAAe;IAChC,eAAe,EAAE;QACf,SAAS,EAAE,EAAE,KAAK,EAAE,WAAW,EAAE,WAAW,EAAE,uBAAuB,EAAE,KAAK,EAAE,CAAC,EAAE;QACjF,OAAO,EAAE,EAAE,KAAK,EAAE,SAAS,EAAE,WAAW,EAAE,yBAAyB,EAAE,KAAK,EAAE,CAAC,EAAE;QAC/E,IAAI,EAAE,EAAE,KAAK,EAAE,MAAM,EAAE,WAAW,EAAE,qBAAqB,EAAE,KAAK,EAAE,CAAC,EAAE;KACtE;IACD,OAAO,EAAE,MAAM,CAAC,IAAI,CAAC,kBAAkB,CAAC;CACzC,CAAC"}
+20
-8
{
"name": "@robinpath/mailchimp",
"version": "0.1.2",
"version": "0.3.0",
"publishConfig": {

@@ -23,12 +23,18 @@ "access": "public"

"peerDependencies": {
"@robinpath/core": ">=0.20.0"
"@robinpath/core": ">=0.40.0"
},
"devDependencies": {
"@robinpath/core": "^0.30.1",
"@robinpath/core": "^0.40.0",
"typescript": "^5.6.0"
},
"description": "Mailchimp module for RobinPath.",
"description": "Mailchimp Marketing API — audiences (lists), members (subscribers), tags, and member CRUD. Uses the encrypted credential vault for API keys.",
"keywords": [
"mailchimp",
"email marketing"
"email marketing",
"newsletter",
"marketing",
"email",
"audience",
"list",
"subscriber"
],

@@ -38,6 +44,12 @@ "license": "MIT",

"category": "email-marketing",
"type": "integration",
"auth": "api-key",
"functionCount": 25
"type": "module",
"auth": "credential-vault",
"functionCount": 25,
"language": "nodejs",
"platforms": [
"cloud",
"cli",
"desktop"
]
}
}

@@ -22,3 +22,3 @@ # @robinpath/mailchimp

```bash
npm install @robinpath/mailchimp
robinpath add @robinpath/mailchimp
```

@@ -25,0 +25,0 @@