Skip to main content
PUT
/
inventory-sources
/
{sourceId}
/
ad-server
Replace managed sales agent ad-server config
curl --request PUT \
  --url https://api.interchange.io/api/v2/storefront/inventory-sources/{sourceId}/ad-server \
  --header 'Authorization: Bearer <token>' \
  --header 'Content-Type: application/json' \
  --data '
{
  "type": "google_ad_manager",
  "networkCode": "12345678"
}
'
{
  "customerId": 0,
  "provisioningStatus": "pending",
  "tenantId": "<string>",
  "mcpUrl": "<string>",
  "a2aUrl": "<string>",
  "adServer": {
    "type": "google_ad_manager",
    "networkCode": "12345678"
  },
  "serviceAccountEmail": "jsmith@example.com",
  "lastError": "<string>",
  "lastTestedAt": "2023-11-07T05:31:56Z",
  "provisionedAt": "2023-11-07T05:31:56Z",
  "deactivatedAt": "2023-11-07T05:31:56Z",
  "createdAt": "2023-11-07T05:31:56Z",
  "updatedAt": "2023-11-07T05:31:56Z"
}

Documentation Index

Fetch the complete documentation index at: https://docs.interchange.io/llms.txt

Use this file to discover all available pages before exploring further.

Authorizations

Authorization
string
header
required

API key or access token

Path Parameters

sourceId
string
required

Inventory source ID

Minimum string length: 1

Body

application/json

Discriminated union of supported ad-server configurations.

type
enum<string>
required
Available options:
google_ad_manager
networkCode
string
required

Google Ad Manager network code.

Required string length: 1 - 32
Pattern: ^[0-9]+$
Example:

"12345678"

Response

Replace managed sales agent ad-server config

Storefront → managed Prebid Sales Agent connection. One row per customer.

customerId
integer
required

Owning customer/storefront id.

Required range: -9007199254740991 <= x <= 9007199254740991
provisioningStatus
enum<string>
required

Lifecycle of the PSA tenant. pending: publisher saved an ad-server config but provisioning has not been attempted. provisioning: upstream call in flight. active: tenant is live. failed: last provisioning attempt failed. deactivated: soft-deleted.

Available options:
pending,
provisioning,
active,
failed,
deactivated
tenantId
string | null
required

Upstream salesagent tenant id. Null until provisioning succeeds.

mcpUrl
string | null
required

MCP endpoint exposed by the provisioned PSA tenant. May be a relative path (e.g. /mcp/) — the consumer composes the absolute URL using the upstream salesagent base URL.

a2aUrl
string | null
required

A2A endpoint exposed by the provisioned PSA tenant. May be a relative path (e.g. /a2a) — see mcpUrl for resolution.

adServer
object
required

Publisher-supplied ad-server config. Null if not yet collected.

serviceAccountEmail
string<email> | null
required

Shared service-account email the publisher must grant access to in their ad server. Surfaced so the UI can show it during onboarding.

Pattern: ^(?!\.)(?!.*\.\.)([A-Za-z0-9_'+\-\.]*)[A-Za-z0-9_+-]@([A-Za-z0-9][A-Za-z0-9\-]*\.)+[A-Za-z]{2,}$
lastError
string | null
required

Failure reason from the most recent provisioning or test-connection attempt.

lastTestedAt
string<date-time> | null
required
Pattern: ^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))T(?:(?:[01]\d|2[0-3]):[0-5]\d(?::[0-5]\d(?:\.\d+)?)?(?:Z))$
provisionedAt
string<date-time> | null
required
Pattern: ^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))T(?:(?:[01]\d|2[0-3]):[0-5]\d(?::[0-5]\d(?:\.\d+)?)?(?:Z))$
deactivatedAt
string<date-time> | null
required
Pattern: ^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))T(?:(?:[01]\d|2[0-3]):[0-5]\d(?::[0-5]\d(?:\.\d+)?)?(?:Z))$
createdAt
string<date-time>
required
Pattern: ^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))T(?:(?:[01]\d|2[0-3]):[0-5]\d(?::[0-5]\d(?:\.\d+)?)?(?:Z))$
updatedAt
string<date-time>
required
Pattern: ^(?:(?:\d\d[2468][048]|\d\d[13579][26]|\d\d0[48]|[02468][048]00|[13579][26]00)-02-29|\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\d|30)|(?:02)-(?:0[1-9]|1\d|2[0-8])))T(?:(?:[01]\d|2[0-3]):[0-5]\d(?::[0-5]\d(?:\.\d+)?)?(?:Z))$