You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
description: A media sales agent that implements the AdCP Media Buy protocol
5
+
sidebarType: 10
6
+
---
7
+
8
+
# Prebid Sales Agent
9
+
10
+
The Prebid Sales Agent is a server that exposes advertising inventory to AI agents via the Model Context Protocol (MCP) and Agent-to-Agent (A2A) protocol. It is designed to integrate with ad servers like Google Ad Manager and provides tools for managing inventory and campaigns throughout their lifecycle.
11
+
12
+
<divclass="alert alert-info"role="alert">
13
+
For the full source code and latest updates, visit the <ahref="https://github.com/prebid/salesagent">prebid/salesagent repository</a>.
14
+
</div>
15
+
16
+
## Key Features
17
+
18
+
### For AI Agents
19
+
20
+
-**Product Discovery**: Natural language search for advertising products.
21
+
-**Campaign Creation**: Automated media buying with targeting capabilities.
22
+
-**Creative Management**: Streamlined upload and approval workflows.
23
+
-**Performance Monitoring**: Real-time access to campaign metrics.
24
+
25
+
### For Publishers
26
+
27
+
-**Multi-Tenant System**: Isolates data per publisher for security and organization.
28
+
-**Adapter Pattern**: Supports multiple ad servers (e.g., Google Ad Manager).
29
+
-**Real-time Dashboard**: Live activity feed powered by Server-Sent Events (SSE).
30
+
-**Workflow Management**: Unified system for human-in-the-loop approvals.
31
+
-**Admin Interface**: Web UI with Google OAuth for easy management.
32
+
33
+
### For Developers
34
+
35
+
-**MCP Protocol**: Standard interface for AI agents.
36
+
-**A2A Protocol**: Agent-to-Agent communication via JSON-RPC 2.0.
37
+
-**REST API**: Programmatic tenant management.
38
+
-**Docker Deployment**: Easy setup for both local and production environments.
For production, publishers can deploy their own sales agent instance. The repository provides guides for various deployment methods, including Docker and cloud platforms.
65
+
66
+
## The AdContext Protocol (AdCP)
67
+
68
+
The Sales Agent is built on the **AdContext Protocol (AdCP)**, an open standard designed to standardize how AI agents interact with advertising platforms.
69
+
70
+
<divclass="alert alert-info"role="alert">
71
+
For comprehensive documentation, visit <ahref="https://docs.adcontextprotocol.org/docs/intro">docs.adcontextprotocol.org</a>.
72
+
</div>
73
+
74
+
### Protocol Architecture
75
+
76
+
AdCP operates as a layer on top of standard AI interaction protocols:
77
+
78
+
-**MCP (Model Context Protocol)**: Facilitates direct integration with AI assistants (e.g., Claude Desktop).
79
+
-**A2A (Agent-to-Agent Protocol)**: Enables complex, autonomous workflows and collaboration between agents using JSON-RPC 2.0.
80
+
81
+
### Core Concepts
82
+
83
+
AdCP abstracts complex advertising operations into standardized domains:
84
+
85
+
1.**Inventory Discovery** (`get_products`): Agents can search for ad products using natural language criteria (e.g., "video ads in North America") rather than specific line item IDs.
86
+
2.**Media Buying** (`create_media_buy`): A normalized workflow for proposal, negotiation, and booking that works consistently across different ad servers.
87
+
3.**Creative Management** (`build_creative`): Standardized handling of creative assets, allowing agents to generate or upload assets that match publisher specifications.
88
+
4.**Signal Activation** (`get_signals`, `activate_signal`): Mechanisms for passing context and identity signals to improve targeting and campaign performance.
89
+
90
+
### Workflow Example
91
+
92
+
A typical AI-driven campaign flow using AdCP might look like this:
93
+
94
+
1.**Discovery**: Expected outcome is a list of available "Products" matching the agent's intent.
95
+
2.**Planning**: The agent uses `create_media_buy` to submit a proposal.
96
+
3.**Review**: The Sales Agent (and potentially a human publisher) reviews the proposal.
97
+
4.**Execution**: Once approved, the Sales Agent pushes the orders to the underlying ad server (e.g., GAM).
98
+
99
+
## Architecture
100
+
101
+
The project follows a clean structure isolating core MCP components, business logic services, and ad server adapters.
102
+
103
+
```text
104
+
salesagent/
105
+
├── src/
106
+
│ ├── core/ # Core MCP server components
107
+
│ ├── services/ # Business logic services
108
+
│ ├── adapters/ # Ad server integrations (e.g., GAM)
109
+
│ └── admin/ # Admin UI (Flask)
110
+
├── scripts/ # Utility and deployment scripts
111
+
└── tests/ # Comprehensive test suite
112
+
```
113
+
114
+
## Contributing
115
+
116
+
Contributions are welcome! Please refer to the [Development Guide](https://github.com/prebid/salesagent/blob/main/docs/development/README.md) in the repository for details on setting up your environment and creating pull requests.
Copy file name to clipboardExpand all lines: dev-docs/analytics/intentiq.md
+20-19Lines changed: 20 additions & 19 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -35,9 +35,9 @@ No registration for this module is required.
35
35
| options.browserBlackList | Optional | String | This is the name of a browser that can be added to a blacklist.|`"chrome"`|
36
36
| options.domainName | Optional | String | Specifies the domain of the page in which the IntentIQ object is currently running and serving the impression. This domain will be used later in the revenue reporting breakdown by domain. For example, cnn.com. It identifies the primary source of requests to the IntentIQ servers, even within nested web pages.|`"currentDomain.com"`|
37
37
| options. additionalParams | Optional | Array | This parameter allows sending additional custom key-value parameters with specific destination logic (sync, VR, winreport). Each custom parameter is defined as an object in the array. |`[ { parameterName: “abc”, parameterValue: 123, destination: [1,1,0] } ]`|
38
-
| options. additionalParams[0].parameterName |Required| String | Name of the custom parameter. This will be sent as a query parameter. |`"abc"`|
39
-
| options. additionalParams[0].parameterValue |Required| String / Number | Value to assign to the parameter. |`123`|
40
-
| options. additionalParams[0].destination |Required| Array | Array of numbers either `1` or `0`. Controls where this parameter is sent `[sendWithSync, sendWithVr, winreport]`. |`[1, 0, 0]`|
38
+
| options. additionalParams[0].parameterName |Optional| String | Name of the custom parameter. This will be sent as a query parameter. |`"abc"`|
39
+
| options. additionalParams[0].parameterValue |Optional| String / Number | Value to assign to the parameter. |`123`|
40
+
| options. additionalParams[0].destination |Optional| Array | Array of numbers either `1` or `0`. Controls where this parameter is sent `[sendWithSync, sendWithVr, winreport]`. |`[1, 0, 0]`|
41
41
42
42
#### Example Configuration
43
43
@@ -46,11 +46,8 @@ pbjs.enableAnalytics({
46
46
provider:'iiqAnalytics',
47
47
options: {
48
48
partner:1177538,
49
-
manualWinReportEnabled:false,
50
-
reportMethod:"GET",
51
-
adUnitConfig:1,
49
+
ABTestingConfigurationSource:'IIQServer',
52
50
domainName:"currentDomain.com",
53
-
gamPredictReporting:false
54
51
}
55
52
});
56
53
```
@@ -91,24 +88,28 @@ originalCpm: 1.5, // Original CPM value.
| biddingPlatformId | Integer | Specify the platform in which this ad impression was rendered – 1 – Prebid, 2 – Amazon, 3 – Google, 4 – Open RTB (including your local Prebid server) | 1 | Yes |
102
-
| partnerAuctionId | String | Use this when you are running multiple auction solutions across your assets and have a unified identifier for auctions | 3d44542d-xx-4662-xxxx-4xxxx3d8e | No |
103
-
| bidderCode | String | Specifies the name of the bidder that won the auction as reported by Prebid and all other bidding platforms | newAppnexus | Yes |
104
-
| prebidAuctionId | String | Specifies the identifier of the Prebid auction. Leave empty or undefined if Prebid is not the bidding platform | 3513ce01-de02-490b-9d87-bfc137697f82 | No |
105
-
| cpm | Decimal | Cost per mille of the impression as received from the demand-side auction (without modifications or reductions) | 5.62 | Yes |
106
-
| currency | String | Currency of the auction | USD | Yes |
107
-
| originalCpm | Decimal | Leave empty or undefined if Prebid is not the bidding platform | 5.5 | No |
108
-
| originalCurrency | String | Currency of the original auction | USD | No |
109
-
| status | String | Status of the impression. Leave empty or undefined if Prebid is not the bidding platform | rendered | No |
110
-
| placementId | String | Unique identifier of the ad unit on the webpage that showed this ad | div-1 | No |
111
-
| adType | String | Specifies the type of ad served. Possible values: “banner“, “video“, “native“, “audio“. | banner | No |
100
+
| biddingPlatformId | Integer | Specify the platform in which this ad impression was rendered – 1 – Prebid, 2 – Amazon, 3 – Google, 4 – Open RTB (including your local Prebid server) | 1 | Yes |
101
+
| partnerAuctionId | String | Use this when you are running multiple auction solutions across your assets and have a unified identifier for auctions | 3d44542d-xx-4662-xxxx-4xxxx3d8e | No |
102
+
| bidderCode | String | Specifies the name of the bidder that won the auction as reported by Prebid and all other bidding platforms | newAppnexus | Yes |
103
+
| prebidAuctionId | String | Specifies the identifier of the Prebid auction. Leave empty or undefined if Prebid is not the bidding platform |||
104
+
| cpm | Decimal | Cost per mille of the impression as received from the demand-side auction (without modifications or reductions) | 5.62 | Yes |
105
+
| currency | String | Currency of the auction | USD | Yes |
106
+
| originalCpm | Decimal | Leave empty or undefined if Prebid is not the bidding platform | 5.5 | No |
107
+
| originalCurrency | String | Currency of the original auction | USD | No |
108
+
| status | String | Status of the impression. Leave empty or undefined if Prebid is not the bidding platform | rendered | No |
109
+
| placementId | String | Unique identifier of the ad unit on the webpage that showed this ad | div-1 | No |
110
+
| adType | String | Specifies the type of ad served. Possible values: “banner“, “video“, “native“, “audio“. | banner | No |
111
+
| size | String | Size of adUnit item | 320x250 | No |
112
+
| pos | number | The pos field specifies the position of the adUnit on the page according to the OpenRTB 2.5 specification | 0 | No |
112
113
113
114
To report the auction win, call the function as follows:
0 commit comments