mcpField
T
tinysend

tinysend

リモート
tinysend.com開発ツール018 週間前に更新
リポジトリ公式サイト

tinysend について

tinysendはtinysend APIの公式TypeScript SDKで、メールやニュースレターのデータを扱うアプリケーションやエージェント向けです。依存関係のないfetchベースの設計で、API全体を利用できます。

主な機能

  1. 01メーリングリストの管理
  2. 02リストの作成と取得
  3. 03fetchによるAPIアクセス
  4. 04実行時依存関係なし
  5. 05ベースURLとfetchのカスタマイズ

活用シーン

  1. 01TypeScriptコードからtinysend APIを利用
  2. 02SDKでリストを管理
  3. 03カスタムfetch実装を設定

設定

リモートサーバーはインストール不要です。クライアントを選んで設定をコピーするか、ワンクリックで導入できます。

エンドポイントhttps://mcp.tinysend.com
インストールコマンドをコピー
Claude CodeTerminal
Cursor.cursor/mcp.json
VS Code.vscode/mcp.json
Claude Desktopclaude_desktop_config.json
Windsurf~/.codeium/windsurf/mcp_config.json

コマンドはターミナルで実行し、JSON は各クライアントの MCP 設定に貼り付けて再起動します。認可が必要なサーバーは初回接続時にログインを求めます。

ツール

詳細

tinysend

tinysend API 用の公式 TypeScript SDK です。依存関係ゼロで、fetch ベースです。Node.js、Bun、Deno、Cloudflare Workers、ブラウザーで動作します。

購読者数

インストール

npm install tinysend

トークンの取得

すべての呼び出しにはベアラートークン(sk_...)が必要です。

  • 人間の場合:tinysend.com のアカウント設定で作成します
  • エージェントの場合:人間の介在なしで、自分自身を登録します。プロトコルは tinysend.com/auth.md(id.tinysend.com/agent/auth に POST)、手順ガイドは tinysend.com/agents/agent-auth にあります

使い方

import { Tinysend } from 'tinysend';

const ts = new Tinysend('sk_...');

// lists
const lists = await ts.lists.list();
const list = await ts.lists.create({ name: 'Weekly Update' });

// subscribers
await ts.subscribers.create(list.id, { email: '[email protected]', verified: true });

// send an email
const post = await ts.posts.create(list.id, {
  subject: 'Hello World',
  body_html: '<p>Welcome to our newsletter!</p>',
});
await ts.posts.send(list.id, post.id);

// contacts
const contacts = await ts.contacts.list({ search: 'john' });

// mailboxes
const mailboxes = await ts.mailboxes.list();

// stats
const stats = await ts.stats.project();

// webhooks
const hook = await ts.webhooks.create({
  url: 'https://example.com/webhook',
  events: ['post.sent', 'subscriber.created'],
});

// sender domain (who emails come from)
await ts.sender.set(list.id, { type: 'custom_domain', name: 'James', email: 'james', domain: 'acme.com' });
await ts.sender.check(list.id); // re-check DNS

// custom domain for the archive site
await ts.siteDomains.set(list.id, { domain: 'news.acme.com' });

// waitlists
await ts.lists.join(list.id, { email: '[email protected]' });
await ts.lists.invite(list.id, { count: 100 });

// automations, invites, usage, settings
const automations = await ts.automations.list();
const invites = await ts.invites.list();
const usage = await ts.usage.get();

この SDK は API の全機能をカバーしており、リリースのたびにライブの openapi spec と照合して検証されます。

エラー処理

import { Tinysend, TinysendError } from 'tinysend';

try {
  await ts.lists.get('nonexistent');
} catch (err) {
  if (err instanceof TinysendError) {
    console.log(err.status);  // 404
    console.log(err.code);    // 'not_found'
    console.log(err.message); // 'list not found'
  }
}

設定

const ts = new Tinysend('sk_...', {
  baseUrl: 'https://api.tinysend.com/v1',  // default
  fetch: customFetch,                        // custom fetch implementation
});

ライセンス

MIT


system operator の製品です

コメント

MCP は初めてですか?

プロトコルの概要から最初のサーバーの導入まで、よくある疑問にまとめて答えます。

AI アプリケーションが外部のツールやデータソースに統一的な方法で接続するためのオープンなプロトコルです。クライアントはモデルとの対話を担い、MCP サーバーはツール・リソース・プロンプトテンプレートを提供します。標準メッセージでやり取りするため、1 つのサーバーを複数のクライアントで再利用できます。