completed、120 秒未満の working、または手動審査用の submitted)
PATCH セマンティクス: 指定したフィールドのみ更新し、未指定フィールドは変更しません。
Request Schema: /schemas/v2/media-buy/update-media-buy-request.json
Response Schema: /schemas/v2/media-buy/update-media-buy-response.json
クイックスタート
メディアバイを作成し、一時停止します。リクエストパラメーター
| Parameter | Type | Required | Description |
|---|---|---|---|
media_buy_id | string | Yes* | 更新対象のパブリッシャー側メディアバイ ID |
buyer_ref | string | Yes* | 更新対象のバイヤー参照 ID |
start_time | string | No | 更新後の開始日時 |
end_time | string | No | 更新後の終了日時 |
paused | boolean | No | メディアバイ全体を一時停止/再開(true=停止、false=稼働) |
packages | PackageUpdate[] | No | パッケージ単位の更新(下記参照) |
reporting_webhook | object | No | レポート用 Webhook 設定の更新(下記参照) |
push_notification_config | object | No | 非同期処理通知用 Webhook |
media_buy_id OR buyer_ref is required (not both)
Reporting Webhook オブジェクト
このメディアバイの自動レポート配信を設定します。| Parameter | Type | Required | Description |
|---|---|---|---|
url | string | Yes | Webhook エンドポイント URL |
authentication | object | Yes | schemes と credentials を持つ認証設定 |
reporting_frequency | string | Yes | hourly / daily / monthly |
requested_metrics | string[] | No | 取得したい指標(未指定ならすべて) |
token | string | No | 検証用のクライアントトークン(16 文字以上) |
reporting_webhook はキャンペーンの継続レポート設定、push_notification_config は「この更新が完了したら知らせて」といった非同期通知用です。
Package Update オブジェクト
| Parameter | Type | Description |
|---|---|---|
package_id | string | 更新対象のパブリッシャー側パッケージ ID |
buyer_ref | string | 更新対象のバイヤー参照 ID |
paused | boolean | パッケージ単位で一時停止/再開(true=停止、false=稼働) |
budget | number | 予算の更新値 |
impressions | number | このパッケージのインプレッション目標の更新値 |
pacing | string | ペーシング戦略の更新 |
bid_price | number | 入札額の更新(オークション商品のみ) |
targeting_overlay | TargetingOverlay | ターゲティング制約の更新 |
creative_assignments | CreativeAssignment[] | 割り当てクリエイティブを置き換え(重み/プレースメント指定可) |
creatives | CreativeAsset[] | 新規クリエイティブをインラインでアップロード・割り当て(ライブラリ未登録であること) |
package_id または buyer_ref のどちらかが必須
レスポンス
成功レスポンス
| Field | Description |
|---|---|
media_buy_id | メディアバイ ID |
buyer_ref | バイヤー参照 ID |
implementation_date | 変更が反映される日時 (ISO 8601)。承認待ちの場合は null |
affected_packages | 更新後の完全な状態を示す Package オブジェクト配列 |
エラーレスポンス
| Field | Description |
|---|---|
errors | Array of error objects explaining failure |
errors を確認してください。
主なシナリオ
パッケージ予算の更新
特定パッケージの予算を増額:キャンペーン日程の変更
キャンペーン終了日を延長:ターゲティングの更新
地理制限を追加・変更:Replace Creatives
Swap out creative assignments for a package:Multiple Package Updates
Update multiple packages in one call:What Can Be Updated
Campaign-Level Updates
✅ Can update:- Start/end times (subject to seller approval)
- Campaign status (active/paused)
- Reporting webhook configuration (URL, frequency, metrics)
- Media buy ID
- Buyer reference
- Brand manifest
- Original package product IDs
Package-Level Updates
✅ Can update:- Budget allocation
- Pacing strategy
- Bid prices (auction products)
- Targeting overlays
- Creative assignments
- Package status (active/paused)
- Package ID
- Product ID
- Pricing option ID
- Format IDs (creatives must match existing formats)
Error Handling
Common errors and resolutions:| Error Code | Description | Resolution |
|---|---|---|
MEDIA_BUY_NOT_FOUND | Media buy doesn’t exist | Verify media_buy_id or buyer_ref |
PACKAGE_NOT_FOUND | Package doesn’t exist | Verify package_id or buyer_ref |
UPDATE_NOT_ALLOWED | Field cannot be changed | See “What Can Be Updated” above |
BUDGET_INSUFFICIENT | New budget below minimum | Increase budget amount |
POLICY_VIOLATION | Update violates content policy | Review policy requirements |
INVALID_STATE | Operation not allowed in current state | Check campaign status |
CREATIVE_ID_EXISTS | Creative ID already exists in library | Use a different creative_id, assign existing creatives via creative_assignments, or update via sync_creatives |
Update Approval
Some updates require seller approval and return pending status:- Significant budget increases (threshold varies by seller)
- Date range changes affecting inventory availability
- Targeting changes that alter campaign scope
- Creative changes requiring policy review
implementation_date will be null:
PATCH Semantics
Only specified fields are updated - omitted fields remain unchanged:creative_assignments), provide the complete new array:
Asynchronous Operations
Updates may be asynchronous, especially with seller approval.Response Patterns
Synchronous (completed immediately):Protocol-Specific Handling
AdCP tasks work across multiple protocols (MCP, A2A, REST). Each protocol handles async operations differently:- Status checking: Polling, webhooks, or streaming
- Updates: Protocol-specific mechanisms
- Long-running tasks: Different timeout and notification patterns
Best Practices
1. Use Precise Updates Update only what needs to change - don’t resend unchanged values. 2. Budget Increases Small incremental increases are more likely to be auto-approved than large jumps. 3. Pause Before Major Changes Pause campaigns before making significant targeting or creative changes to avoid delivery issues. 4. Test with Small Changes Test update workflows with minor changes before critical campaign modifications. 5. Monitor Status Always check response status andimplementation_date for approval requirements.
6. Validate Package State
Check affected_packages in response to confirm changes were applied correctly.
Usage Notes
- Updates are atomic - either all changes apply or none do
- Both media buys and packages can be referenced by
buyer_refor publisher IDs - Pending states (
working,submitted) are normal, not errors - Orchestrators MUST handle pending states as part of normal workflow
implementation_dateindicates when changes take effect (null if pending approval)- Inline creatives: The
creativesarray creates NEW creatives only. To update existing creatives, usesync_creatives. To assign existing library creatives, usecreative_assignmentsin the Package Update object.
Next Steps
After updating a media buy:- Verify Changes: Use
get_media_buy_deliveryto confirm updates - Upload New Creatives: Use
sync_creativesif creative assignments changed - Monitor Performance: Track impact of changes on campaign metrics
- Optimize Further: Use
provide_performance_feedbackfor ongoing optimization
Learn More
- Media Buy Lifecycle - Complete campaign workflow
- Targeting - Targeting overlays and restrictions
- Async Operations - Async patterns and status checking
- create_media_buy - Initial campaign creation