Skip to main content
スキーマと公式 SDK を使って AdCP 連携を始めましょう。

スキーマへのアクセス

AdCP スキーマは次の 2 つの入手先があります:
SourceURLBest For
Websitehttps://adcontextprotocol.org/schemas/v2/実行時取得、バージョンエイリアス
GitHubhttps://github.com/adcontextprotocol/adcp/tree/main/dist/schemasオフライン利用、CI/CD パイプライン
どちらも同一のスキーマを提供します。GitHub リポジトリにはすべてのリリース版とバンドル済みスキーマがコードベースに含まれています。

主なスキーマ

SchemaURL
Producthttps://adcontextprotocol.org/schemas/v2/core/product.json
Media Buyhttps://adcontextprotocol.org/schemas/v2/core/media-buy.json
Creative Formathttps://adcontextprotocol.org/schemas/v2/core/creative-format.json
Schema Registryhttps://adcontextprotocol.org/schemas/v2/index.json

AI コーディングエージェント向け

AI コーディングエージェントには、MCP 連携ドキュメントとして https://docs.adcontextprotocol.org/mcp を参照させてください。

クライアント SDK

AdCP は JavaScript/TypeScript と Python 向けの公式 SDK を提供します。クライアント/サーバーのどちらでも利用できます。

JavaScript / TypeScript

npm version
npm install @adcp/client
import { ADCPClient } from '@adcp/client';

const client = new ADCPClient({
  agentUrl: 'https://sales.example.com'
});

const products = await client.getProducts({
  brief: 'Video campaign for pet owners'
});
リソース: パッケージのエクスポート:
  • @adcp/client — Main API
  • @adcp/client/testing — Testing utilities (includes testAgent)
  • @adcp/client/advanced — Advanced API features
  • @adcp/client/types — TypeScript type definitions

Python

PyPI version
pip install adcp
from adcp import ADCPClient

client = ADCPClient(agent_url='https://sales.example.com')

products = client.get_products(
    brief='Video campaign for pet owners'
)
リソース:

CLI ツール

両 SDK にはテストや開発向けの CLI が含まれます。

JavaScript CLI

npx @adcp/client --help
npx @adcp/client get-products --agent https://sales.example.com --brief "CTV campaign"

Python CLI

uvx adcp --help
uvx adcp get-products --agent https://sales.example.com --brief "CTV campaign"

スキーマのバージョニング

AdCP はセマンティックバージョニングを採用しています。用途に応じてパスを選択してください:
PathExampleBest For
Exact version/schemas/2.6.0/本番、SDK 生成
Major version/schemas/v2/開発、ドキュメント
Minor version/schemas/v2.5/安定開発(パッチのみ反映)

本番(推奨)

安定性のため固定バージョンを指定します:
const SCHEMA_VERSION = '2.6.0';
const schema = await fetch(
  `https://adcontextprotocol.org/schemas/${SCHEMA_VERSION}/core/product.json`
);

開発

後方互換の更新を取り込みたい場合はメジャー版のエイリアスを使用します:
const schema = await fetch(
  'https://adcontextprotocol.org/schemas/v2/core/product.json'
);

SDK 型生成

# TypeScript
npx json-schema-to-typescript \
  https://adcontextprotocol.org/schemas/2.6.0/core/product.json \
  --output types/product.d.ts

# Python
datamodel-codegen \
  --url https://adcontextprotocol.org/schemas/2.6.0/core/product.json \
  --output models/product.py

バンドル済みスキーマ

$ref 解決をサポートしないツール向けに、参照をすべて解決済みのバンドルスキーマを利用できます。Web と GitHub の両方から取得可能です:

Web からの取得

https://adcontextprotocol.org/schemas/2.6.0/bundled/media-buy/create-media-buy-request.json

GitHub からの取得

Bundled schemas are committed to the repository at dist/schemas/{VERSION}/bundled/:
# Clone and access locally
git clone https://github.com/adcontextprotocol/adcp.git
ls adcp/dist/schemas/2.5.3/bundled/media-buy/

# Or fetch directly via GitHub raw
curl https://raw.githubusercontent.com/adcontextprotocol/adcp/main/dist/schemas/2.5.3/bundled/media-buy/get-products-request.json

ディレクトリ構造

dist/schemas/{VERSION}/
├── bundled/                      # Fully dereferenced schemas
│   ├── media-buy/                # Media buying tasks
│   ├── creative/                 # Creative tasks
│   ├── signals/                  # Signal protocol tasks
│   ├── property/                 # Property/governance tasks
│   ├── content-standards/        # Content standards tasks
│   ├── sponsored-intelligence/   # Sponsored intelligence tasks
│   ├── protocol/                 # Protocol tasks
│   └── core/                     # Core task schemas
├── core/                         # Modular schemas with $ref
├── media-buy/
└── index.json                    # Schema registry

バンドルスキーマのカテゴリ

すべてのリクエスト/レスポンス系タスクスキーマがバンドルされています:
CategoryTasks
bundled/media-buy/get-products, create-media-buy, update-media-buy, list-creative-formats, sync-creatives, build-creative, list-creatives, get-media-buy-delivery, list-authorized-properties, provide-performance-feedback
bundled/creative/list-creative-formats, preview-creative
bundled/signals/get-signals, activate-signal
bundled/property/create-property-list, get-property-list, list-property-lists, update-property-list, delete-property-list, get-property-features, validate-property-delivery
bundled/content-standards/create-content-standards, get-content-standards, list-content-standards, update-content-standards, calibrate-content, validate-content-delivery, get-media-buy-artifacts
bundled/sponsored-intelligence/si-get-offering, si-initiate-session, si-send-message, si-terminate-session
bundled/protocol/get-adcp-capabilities
bundled/core/tasks-get, tasks-list
[利用可能なスキーマ]は schema registry を参照してください。

バージョンの確認

# Get current version
curl https://adcontextprotocol.org/schemas/v2/index.json | jq '.adcp_version'
Release Notes でバージョン履歴と移行ガイドを確認してください。