# ad.updated

An ad was edited through Zernio (`source: "zernio"`), or outside Zernio and detected by the sync (`source: "platform"`).

### When it fires

Fires once, to the owner of the edited ad. Outside edits arrive up to one sync interval late. Every edit is announced, so use the event `id` to drop repeats.

### Payload notes

`changes` lists the edited fields: `name`, `status` (the ad's own on/off switch), `budget`, `targeting` or `creative`. Ignore unknown values; new ones can be added.

### Reading the change

The event never carries old or new values, so read the ad. `platformId` can change when a LinkedIn creative is replaced, while `adId` stays stable.

### When it does not fire

From the sync, `changes` covers only `name` and `status`. Budget, bid, schedule and targeting edits made outside Zernio, tracking tag edits and history loaded at connect are not announced. Ad rule changes arrive as `ad_rule.triggered`.




**Payload for `ad.updated`:**

- **id** (required) `string`: Stable webhook event ID: the dedupe key, also sent as the X-Zernio-Event-Id header and identical on every retry and redelivery.
- **profiles**: `WebhookProfiles` - See schema definition
- **test** `boolean`: Always true when present: only a sample sent by POST /v1/webhooks/test with an event carries it. Real deliveries never do.
- **event** (required) `string`: No description - one of: ad.updated
- **account** (required): `WebhookAdsAccount` - See schema definition
- **adObject** (required) `object`: 
  - **level** (required) `string`: Always `AD`. - one of: AD
  - **platformId** (required) `string`: Platform-native ad ID.
  - **platformAdAccountId** (required) `string`: Platform-native ad account ID.
  - **adId** (required) `string`: Zernio ad ID, usable with GET /v1/ads/{adId}.
  - **name** (required) `string`: No description
  - **campaign** (required) `object,null`: The campaign the ad belongs to, or null when the platform has none.
  - **adSet** (required) `object,null`: The ad set the ad belongs to, or null when the platform has none.
- **changes** (required) `array[string]`: Fields edited by this request. `status` is the ad's own on/off switch. Ignore values you do not know.
- **source** (required) `string`: Where the edit was made. `zernio` for edits through Zernio, `platform` for edits the sync detected outside Zernio. - one of: zernio, platform
- **timestamp** (required) `string` (date-time): UTC time at which Zernio generated this event.