MCP Reference: calendarmcp.googleapis.com

Model Context Protocol(MCP)サーバーは、大規模言語モデル(LLM)または AI アプリケーションにコンテキスト、データ、機能を提供する外部サービスとの間のプロキシとして機能します。MCP サーバーは、AI アプリケーションをデータベースやウェブサービスなどの外部システムに接続し、そのレスポンスを AI アプリケーションが理解できる形式に変換します。

MCP ツール

MCP ツールは、現実世界でアクションを実行する目的で MCP サーバーが LLM または AI アプリケーションに対して公開する関数または実行可能な機能です。

calendarmcp.googleapis.com MCP サーバーには、次のツールがあります。

MCP ツール
list_events

指定された条件を満たす、指定されたカレンダーの予定を一覧表示します。

主な機能:

  • カレンダー ID(ユーザーのメイン カレンダーなど)。
  • キーワードのマッチタイプ。
  • 期間のフィルタリング。
  • 時間とキーワードの制約に一致するすべてのイベントを取得します。

次の場合には、代わりに search_events ツールを使用します。

  • 制約を満たすイベントをすべて見つけるのではなく、最も関連性の高い(上位 K 個の)イベントを見つける必要があります。
  • セマンティック検索機能が必要である。
  • ユーザーのメイン カレンダーのみを対象に特定の情報を検索している。

このツールは、次のようなクエリに使用します。

  • 明日のカレンダーの予定は?
  • 2025 年 7 月 14 日の予定は?
  • 来週の会議の予定を教えて
  • 今日の午後の予定の重複を確認する

例:

list_events(
    start_time='2024-09-17T06:00:00',
    end_time='2024-09-17T12:00:00',
    page_size=10
)
# Returns up to 10 calendar events between 6:00 AM and 12:00 PM on September 17, 2024 from the user's primary calendar.
get_event

指定されたカレンダーから単一の予定を返します。

このツールは、次のようなクエリに使用します。

  • チーム会議の詳細を取得します。
  • カレンダーで ID が event123 の予定を表示して。

例:

get_event(
    event_id='event123'
)
# Returns the event details for the event with id `event123` on the user's primary calendar.
list_calendars

ユーザーのカレンダー リストにあるカレンダーを返します。

このツールは、次のようなクエリに使用します。

  • すべてのカレンダーを表示して

例:

list_calendars()
# Returns all calendars the authenticated user has access to.
suggest_time

1 つ以上のカレンダーで期間を提案します。メインカレンダーにアクセスするには、attendee_emails フィールドに「primary」を追加します。

このツールは、次のようなクエリに使用します。

  • 会議の実施日を教えてください。
  • 両方の都合の良い 30 分間の時間枠を見つけてください。
  • 月曜日の午前中に jane.doe@google.com の予定が空いているかどうかを確認して。

例:

suggest_time(
    attendee_emails=['joedoe@gmail.com', 'janedoe@gmail.com'],
    start_time='2024-09-10T00:00:00',
    end_time='2024-09-17T00:00:00',
    duration_minutes=60,
    preferences={
        'start_hour': '09:00',
        'end_hour': '17:00',
        'exclude_weekends': True
    }
)
# Returns up to 5 suggested time slots where both users are available for at least one hour between 9:00 AM and 5:00 PM on weekdays from September 10 through September 16, 2024.
create_event

カレンダーの予定を作成します。

このツールは、次のようなクエリに使用します。

  • 明日の午後 2 時に「Jane との会議」という予定をカレンダーに作成して。
  • 来週の月曜日の午前 10 時から 11 時まで、john.doe@google.com との会議をスケジュールしてください。

例:

create_event(
    summary='Meeting with Jane',
    start_time='2024-09-17T14:00:00',
    end_time='2024-09-17T15:00:00'
)
# Creates an event on the primary calendar for September 17, 2024 from 2pm to 3pm called 'Meeting with Jane'.
update_event

カレンダーの予定を更新します。

このツールは、次のようなクエリに使用します。

  • 「Jane との会議」のイベントを 1 時間後に変更します。
  • 明日の会議に john.doe@google.com を追加して。

例:

update_event(
    event_id='event123',
    summary='Meeting with Jane and John'
)
# Updates the summary of event with id 'event123' on the primary calendar to 'Meeting with Jane and John'.
delete_event

カレンダーの予定を削除します。

このツールは、次のようなクエリに使用します。

  • カレンダーの ID が event123 の予定を削除して。

予定をキャンセルまたは辞退するには、respond_to_event ツールを使用します。

例:

delete_event(
    event_id='event123'
)
# Deletes the event with id 'event123' on the user's primary calendar.
respond_to_event

予定に返信します。

このツールは、次のようなクエリに使用します。

  • カレンダーの ID event123 の予定を承認します。
  • ジェーンとの会議を辞退して。
  • 次の会議をキャンセルして。
  • 計画会議を仮承諾します。

例:

respond_to_event(
    event_id='event123',
    response_status='accepted'
)
# Responds with status 'accepted' to the event with id 'event123' on the user's primary calendar.

MCP ツールの仕様を取得する

MCP サーバー内のすべてのツールの MCP ツール仕様を取得するには、tools/list メソッドを使用します。次の例は、curl を使用して、MCP サーバー内で現在使用可能なすべてのツールとその仕様を一覧表示する方法を示しています。

Curl リクエスト
curl --location 'https://calendarmcp.googleapis.com/mcp' \
--header 'content-type: application/json' \
--header 'accept: application/json, text/event-stream' \
--data '{
    "method": "tools/list",
    "jsonrpc": "2.0",
    "id": 1
}'