POST /api/v2/buyer/advertisers/{advertiserId}/event-sources/sync
Syncs your event source configurations onto an advertiser. Each source gets an event_source_id you pass on every log-event call. Sync is idempotent — re-sending the same config returns unchanged. Events sent to an unregistered source are rejected, so sync before you log.
Omit event_sources entirely for a discovery-only call: it returns every existing event source on the account without modifying anything, up to 200 sources. delete_missing has no effect on a discovery-only call. An account with more than 200 sources gets a 400 VALIDATION_ERROR from discovery-only sync — use list event sources instead, which paginates.
Set a body-level idempotency_key (16–255 letters, numbers, underscores, periods, colons, or hyphens) to make a retry safe. It prevents a retried request from re-triggering the audit events and downstream pixel provisioning the sync emits, and on a discovery-only call it doubles as a request ID. Repeating the same key with the same request returns the original result and sets Idempotency-Replayed: true; reusing it with a different request returns 409 CONFLICT. Omitting it is still accepted for compatibility, but a retried call with no key is not deduplicated.
Request
Parameters
Response
action is one of created, updated, unchanged, failed, or deleted. A failed result carries an error message; the rest of the batch still applies.
Errors
400 VALIDATION_ERROR— malformedidempotency_key,account.account_iddoes not match the path, emptyevent_sources, more than 50 sources in one sync, or discovery-only on an account with more than 200 sources.404 NOT_FOUND—advertiserIddoes not exist or is not visible to the authenticated account.409 CONFLICT—idempotency_keywas already used with a different request, is outside its replay window, or the original request is still in flight.
Related
Event source tasks
All event source operations
Log Events guide
How event sources and log-event fit together
Log event
Send events through a registered source
Conversion API
Identity-hashing rules and event payloads