Skip to content

Conversation

@bokelley
Copy link
Contributor

@bokelley bokelley commented Nov 5, 2025

Summary

Per the AdCP specification, all parameters for get_media_buy_delivery should be optional. When media_buy_ids is omitted, the operation should return delivery data for all media buys the requester has access to, filtered by the provided criteria.

Changes

  • Remove incorrect validation requiring media_buy_ids in A2A server handler
  • Pass all optional parameters (buyer_refs, status_filter, start_date, end_date) to core implementation
  • Add test case verifying optional media_buy_ids behavior

Testing

All unit tests pass. New test verifies that requests without media_buy_ids are accepted and parameters are correctly forwarded to the core implementation.

Per the AdCP specification, all parameters for get_media_buy_delivery are optional.
When media_buy_ids is omitted, the operation should return delivery data for all
media buys the requester has access to, filtered by the provided criteria
(status_filter, start_date, end_date, buyer_refs).

Changes:
- Remove incorrect validation requiring media_buy_ids in A2A server handler
- Pass all optional parameters (buyer_refs, status_filter, start_date, end_date)
  to core implementation
- Update docstring to clarify that omitting media_buy_ids queries all accessible buys
- Add test case verifying optional media_buy_ids behavior

The core implementation (_get_media_buy_delivery_impl) already handled this correctly,
filtering by status when no IDs were provided. The bug was only in the A2A server's
parameter validation layer.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
@bokelley bokelley merged commit 5c69013 into main Nov 5, 2025
10 checks passed
bokelley added a commit that referenced this pull request Nov 5, 2025
Resolved conflict in templates/add_product_gam.html by keeping our tree API approach for hierarchical size extraction (required for child ad unit sizes) while incorporating debug logging from main.

Conflict resolution:
- Kept tree API fetch (not flat list) for edit mode initialization
- Preserved recursive cacheTreeUnits() function for hierarchical caching
- Added debug console.log statements from main for troubleshooting
- This ensures child ad unit sizes are available for format matching

Other changes from main:
- Remove MCP protocol test button and APIs (PR #702)
- Make media_buy_ids optional per AdCP spec (PR #704)
- Fix User record creation during OAuth (PR #701)
- Fix inventory fetching for placements (multiple commits)
- Various bug fixes and improvements

Tests: Will run after merge completion

🤖 Generated with Claude Code

Co-Authored-By: Claude <noreply@anthropic.com>
danf-newton pushed a commit to Newton-Research-Inc/salesagent that referenced this pull request Nov 24, 2025
…pec (adcontextprotocol#704)

Per the AdCP specification, all parameters for get_media_buy_delivery are optional.
When media_buy_ids is omitted, the operation should return delivery data for all
media buys the requester has access to, filtered by the provided criteria
(status_filter, start_date, end_date, buyer_refs).

Changes:
- Remove incorrect validation requiring media_buy_ids in A2A server handler
- Pass all optional parameters (buyer_refs, status_filter, start_date, end_date)
  to core implementation
- Update docstring to clarify that omitting media_buy_ids queries all accessible buys
- Add test case verifying optional media_buy_ids behavior

The core implementation (_get_media_buy_delivery_impl) already handled this correctly,
filtering by status when no IDs were provided. The bug was only in the A2A server's
parameter validation layer.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-authored-by: Claude <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants