Seizn.

APIドキュメント

Seiznをアプリケーションに統合するために必要なすべて。数行のコードでAIに永続メモリを追加できます。

クイックスタート

ダッシュボードからAPIキーを取得し ダッシュボード、リクエストを開始してください:

bash
# Add a memory
curl -X POST https://seizn.com/api/memories \
  -H "Authorization: Bearer YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"content": "User prefers dark mode interfaces"}'

# Search memories
curl "https://seizn.com/api/memories?query=user+preferences" \
  -H "Authorization: Bearer YOUR_API_KEY"

認証

すべてのAPIリクエストには Authorization: Bearer ヘッダーにAPIキーが必要です。

bash
curl -H "Authorization: Bearer szn_your_api_key_here" \
  https://seizn.com/api/memories?query=test

セキュリティ: APIキーを安全に保管してください。クライアント側のコードに公開しないでください。環境変数またはバックエンドプロキシを使用してください。

APIエンドポイント

POST/api/memories

ユーザーのメモリストアに新しいメモリを追加します。

リクエストボディ

content-string (required)
memory_type-string - fact, preference, experience, relationship, instruction
tags-string[]
namespace-string (default: "default")
scope-string - user, session, agent
session_id-string
agent_id-string

レスポンス

{
  "success": true,
  "memory": {
    "id": "550e8400-e29b-41d4-a716-446655440000",
    "content": "User prefers dark mode interfaces",
    "memory_type": "preference",
    "tags": ["ui", "settings"],
    "namespace": "default",
    "created_at": "2026-01-08T10:30:00Z"
  }
}
GET/api/memories

意味的類似性を使用してメモリを検索します。

クエリパラメータ

query-string (required)
limit-number (default: 10, max: 100)
threshold-number 0-1 (default: 0.7)
namespace-string

レスポンス

{
  "success": true,
  "results": [
    {
      "id": "550e8400-e29b-41d4-a716-446655440000",
      "content": "User prefers dark mode interfaces",
      "memory_type": "preference",
      "tags": ["ui", "settings"],
      "similarity": 0.89
    }
  ],
  "count": 1
}
DELETE/api/memories

IDでメモリを削除します。

クエリパラメータ

ids-string (required) - comma-separated

レスポンス

{
  "success": true,
  "deleted": 3
}
POST/api/extract

AIを使用して会話からメモリを抽出して保存します。

リクエストボディ

conversation-string (required)
model-string - haiku | sonnet (default: haiku)
auto_store-boolean (default: true)
namespace-string (default: "default")

レスポンス

{
  "message": "Extracted 3 memories, stored 3",
  "extracted": [
    {
      "content": "User is a software developer working with Python",
      "memory_type": "fact",
      "tags": ["profession", "programming"],
      "confidence": 0.95,
      "importance": 7
    }
  ],
  "stored": [...]
}
POST/api/query

関連するメモリをコンテキストとして使用してAI生成の応答を取得します (RAG)。

リクエストボディ

query-string (required)
model-string - haiku | sonnet (default: haiku)
top_k-number (default: 5)
namespace-string
include_memories-boolean (default: true)

レスポンス

{
  "response": "Based on your preferences, I'd recommend using VS Code with a dark theme...",
  "memories_used": [
    {
      "id": "550e8400-e29b-41d4-a716-446655440000",
      "content": "User prefers dark mode interfaces",
      "similarity": 0.85
    }
  ],
  "model_used": "haiku"
}

レート制限

プラン日次API呼び出し最大メモリAPIキー
無料1,0001002
Starter50,0005,0003
プラス500,00050,0005
プロ2,000,000無制限10
エンタープライズ無制限無制限100

レート制限を超えると、APIは 429 Too Many Requests レスポンスを返します。

エラーコード

コード説明
200成功
400不正なリクエスト - パラメータが不足または無効
401認証エラー - APIキーが無効または不足
429リクエスト過多 - レート制限超過
500内部サーバーエラー - 問題が発生しました

セキュリティとガバナンス

データセキュリティ

  • 保存時の暗号化: すべてのデータをAES-256で暗号化
  • 転送中の暗号化: すべての接続にTLS 1.3
  • テナント分離: アカウント間の完全なデータ分離

APIキー管理

  • キーローテーション: ダッシュボードからいつでもキーをローテーション
  • キーの有効期限: 90日後に自動期限切れ (設定可能)
  • 使用状況追跡: キーごとの使用状況をリアルタイムで監視

データ保持と削除

  • エクスポート: APIまたはダッシュボードを通じていつでもすべてのデータをエクスポート
  • 削除: 30日後に保持なしで完全削除
  • GDPR/CCPA: データ主体の権利に完全準拠

SDK

Python

bash
pip install seizn
python
from seizn import Seizn

client = Seizn(api_key="your_api_key")

# Add memory
client.add("User prefers dark mode")

# Search
results = client.search("preferences")

# Extract from conversation
client.extract(conversation="...")

JavaScript

bash
npm install seizn
javascript
import { Seizn } from 'seizn';

const client = new Seizn({ apiKey: 'your_api_key' });

// Add memory
await client.add('User prefers dark mode');

// Search
const results = await client.search('preferences');

// Extract from conversation
await client.extract({ conversation: '...' });

MCP Server — Every Editor, One Memory

The Seizn MCP Server (seizn-mcp) bridges your Seizn memories to AI coding assistants via the Model Context Protocol. 40+ tools, MCP Resources, webhooks, OAuth device flow, and multi-editor config sync — all in one package.

bash
# Install globally or use npx
npx seizn-mcp@latest

# Or add to Claude Code settings (~/.claude/settings.json)
{
  "mcpServers": {
    "seizn": {
      "command": "npx",
      "args": ["-y", "seizn-mcp@latest"],
      "env": { "SEIZN_API_KEY": "your-api-key" }
    }
  }
}

Supported Editors

  • > Claude Code — native MCP
  • > Cursor — native MCP
  • > Windsurf — native MCP
  • > Cline — native MCP
  • ~ GitHub Copilot — via config sync
  • ~ Aider — via config sync
  • ~ OpenAI Codex — via config sync

Key Features

  • > 40+ MCP Tools — memories, knowledge graph, profile, webhooks, config sync
  • > MCP Resources — seizn://memories/recent, seizn://profile, seizn://context/{format}
  • > OAuth Device Flow — browser auth, no API key copy
  • > Auto Context — detects project from package.json, pyproject.toml, Cargo.toml
  • > UTF-8 Support — Korean, Japanese, Chinese, Arabic and 100+ languages

Multi-Editor Config Sync

Seizn exports your memories as editor-specific configuration files. Your AI preferences follow you across every tool.

FileAI ToolMethod
CLAUDE.mdClaude CodeMCP + File
AGENTS.mdOpenAI CodexFile Sync
.cursor/rulesCursorMCP + File
.windsurfrulesWindsurfMCP + File
.github/copilot-instructions.mdGitHub CopilotFile Sync
.clinerulesClineMCP + File
CONVENTIONS.mdAiderFile Sync

OAuth Device Flow

No more copying API keys. The MCP server supports RFC 8628 Device Authorization Grant for browser-based authentication.

1

Run auth_login tool

2

Enter code ABCD-1234 in browser

3

Token saved to ~/.seizn/

Zero-copy auth: The device flow generates a human-readable code, opens your browser, and saves credentials automatically. Works with any terminal or SSH session.