DynamoDB Read-Only MCP
DynamoDB 読み取り専用 MCP
モデルコンテキストプロトコル(MCP)を利用してAWS DynamoDBデータベースにクエリを実行するサーバー。このサーバーにより、ClaudeのようなLLMは自然言語リクエストを通じてDynamoDBデータをクエリできるようになります。
特徴
この MCP サーバーは次の機能を提供します。
テーブル管理ツール:
list-tables: すべての DynamoDB テーブルのリストを表示するdescribe-table: 特定のテーブルに関する詳細情報を表示する
データクエリツール:
scan-table: テーブルのデータ全体または一部をスキャンするquery-table: テーブル内の特定の条件に一致するデータを検索するpaginate-query-table: 特定の条件に一致する複数のページにわたるデータを取得するget-item: 特定のキーを持つアイテムを取得するcount-items: テーブル内のアイテム数を計算する
リソース:
dynamodb-tables-info: すべてのテーブルのメタデータを提供するリソースdynamodb-table-schema: 特定のテーブルのスキーマ情報を提供するリソース
プロンプト:
dynamodb-query-help: DynamoDB クエリを書くためのヘルププロンプト
Related MCP server: Azure Cosmos DB MCP Server
インストールと実行
以下のRun with NPXメソッドを使用すると、インストールせずに実行できます。
Smithery経由でインストール
Smithery経由で Claude Desktop 用の DynamoDB 読み取り専用サーバーを自動的にインストールするには:
npx -y @smithery/cli install @jjikky/dynamo-readonly-mcp --client claudeインストール
リポジトリをクローンします。
git clone https://github.com/jjikky/dynamo-readonly-mcp.git cd dynamo-readonly-mcp必要なパッケージをインストールします。
npm install.envファイルを作成し、AWS 認証情報を設定します。AWS_ACCESS_KEY_ID=your_access_key AWS_SECRET_ACCESS_KEY=your_secret_key AWS_REGION=your_region
ビルドと実行
npm run build
npm startClaudeデスクトップに接続
この MCP サーバーを Claude Desktop で使用するには、Claude Desktop 構成ファイルを変更する必要があります。
Claude Desktop 構成ファイルを開きます。
macOS:
~/Library/Application Support/Claude/claude_desktop_config.jsonWindows:
%APPDATA%\Claude\claude_desktop_config.json
次のようにサーバー構成を追加します。
{ "mcpServers": { "dynamodb-readonly": { "command": "node", "args": ["/absolute-path/dynamo-readonly-mcp/dist/index.js"], "env": { "AWS_ACCESS_KEY_ID": "your_access_key", "AWS_SECRET_ACCESS_KEY": "your_secret_key", "AWS_REGION": "your_region" } } } }Claude Desktop を再起動します。
NPXで実行
グローバルインストールなしでnpxを使用してこのサーバーを実行することもできます。
{
"mcpServers": {
"dynamodb-readonly": {
"command": "npx",
"args": ["-y", "dynamo-readonly-mcp"],
"env": {
"AWS_ACCESS_KEY_ID": "your_access_key",
"AWS_SECRET_ACCESS_KEY": "your_secret_key",
"AWS_REGION": "your_region"
}
}
}
}使用例
クロードに次のような質問をすることができます:
「DynamoDB にはどのようなテーブルがあるのか教えていただけますか?」
「Usersテーブルの構造を説明する」
「「Users」テーブルで、グループIDが「0lxp4paxk7」であるユーザーの数を見つけます」
建築
この MCP サーバーは次の階層構造で構成されています。
クライアントインターフェース(Claude Desktop) - ユーザーとLLM間のインタラクション
MCPプロトコル層- 標準化されたメッセージ交換方法を提供する
DynamoDB サーバー- DynamoDB と対話する関数を実装します
AWS SDK - AWS DynamoDB サービスと通信します
主要な操作メカニズム
1. 初期化と接続
サーバーが起動すると、次のプロセスが実行されます。
async function main() {
const transport = new StdioServerTransport();
await server.connect(transport);
console.error('DynamoDB read-only MCP server is running...');
}StdioServerTransport標準入出力を介して通信チャネルを設定します。server.connect(transport)MCP プロトコルを介して Claude Desktop に接続します。接続中に、サーバーはサポートされているツール、リソース、およびプロンプトに関する情報をクライアントに送信します。
2. ツール要求処理
ユーザーが Claude に「DynamoDB テーブルのリストを表示してください」のような質問をした場合:
クロードはこのリクエストを分析し、
list-tablesツールを呼び出します。この要求は、MCP プロトコルを通じてサーバーに送信されます。
サーバーは対応するツール ハンドラーを実行します。
server.tool('list-tables', 'Gets a list of all DynamoDB tables', {}, async () => {
try {
const tables = await listTables();
return {
content: [{ type: 'text', text: JSON.stringify(tables, null, 2) }],
};
} catch (error) {
return { isError: true, content: [{ type: 'text', text: `Error: ${error.message}` }] };
}
});結果は MCP プロトコルを通じて Claude に返されます。
クロードはこの結果を自然言語に変換し、ユーザーに提示します。
3. 特定のパラメータ処理
ユーザーが「Users テーブルの構造を教えてください」と要求した場合:
Claude は、このリクエストでは
describe-tableツールを使用する必要があると判断しました。Claude はパラメータを
{ tableName: "Users" }として設定します。この情報は MCP サーバーに送信されます。
server.tool(
'describe-table',
'Gets detailed information about a DynamoDB table',
{
tableName: z.string().describe('Name of the table to get detailed information for'),
},
async ({ tableName }) => {
// Query table information using the tableName parameter
const tableInfo = await describeTable(tableName);
// Return results
}
);ここで、 z.string()は Zod ライブラリを使用してパラメータを検証します。
4. リソースの取り扱い
リソースは、読み取り専用データを提供するもう 1 つの MCP 機能です。
server.resource('dynamodb-tables-info', 'DynamoDB table information', async () => {
// Create and return resource data
const tables = await listTables();
const tablesInfo = await Promise.all(/* Query table information */);
return {
contents: [
{
uri: 'dynamodb://tables-info',
text: JSON.stringify(tablesInfo, null, 2),
mimeType: 'application/json',
},
],
};
});クロードはリソースにアクセスし、それをコンテキスト情報として使用します。
5. 迅速な対応
MCP サーバーは、特定のタスクのプロンプト テンプレートを提供できます。
server.prompt(
'dynamodb-query-help',
'A prompt that helps write DynamoDB queries',
{
tableName: z.string().describe('Table name to query'),
queryType: z.enum(['basic', 'advanced']).default('basic'),
},
async ({ tableName, queryType }) => {
// Generate prompt content
return {
messages: [
{
role: 'user',
content: { type: 'text', text: helpContent },
},
],
};
}
);このプロンプトは、ユーザーが「Users テーブルのクエリの記述方法を教えてください」と要求したときに使用されます。
データフローの概要
ユーザーは自然言語でクロードにリクエストを送信します
クロードはリクエストを分析し、適切なMCPツール/リソース/プロンプトを選択します。
MCPクライアントは標準化された形式でサーバーにリクエストを送信します。
サーバーはリクエストを処理し、AWS DynamoDB API を呼び出します。
DynamoDBは結果を返します
サーバーは結果をMCP形式に変換し、クライアントに送信します。
クロードは結果を自然言語で処理し、ユーザーに提示します。
ライセンス
このプロジェクトは MIT ライセンスに基づいてライセンスされています - 詳細については LICENSE ファイルを参照してください。
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Servers
- FlicenseNot gradedqualityDmaintenanceA server that enables interaction with PostgreSQL, MySQL, MariaDB, or SQLite databases through Claude Desktop using natural language queries.1
- AlicenseBqualityDmaintenanceA server that enables LLMs like Claude to interact with Azure Cosmos DB databases through natural language queries, acting as a translator between AI assistants and database systems.43MIT
- AlicenseCqualityAmaintenanceA server that enables LLMs (like Claude and VSCode Copilot) to interact with Azure Cosmos DB data through natural language queries, acting as a translator between AI assistants and your database.3243MIT
- AlicenseNot gradedqualityDmaintenanceThis server provides database access capabilities to Claude, supporting SQLite, SQL Server, PostgreSQL, and MySQL databases.853MIT
Related MCP Connectors
GibsonAI MCP server: manage your databases with natural language
Hosted Amazon Seller Central and Amazon Ads MCP server for Claude, ChatGPT, Cursor, and agents.
Query PostgreSQL databases in plain English — LLM-generated, safety-validated SQL.
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/jjikky/dynamo-readonly-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server