Get the conversion tracking code of an action
Returns what the console's Conversion Tracking Code window shows for the action.
https://YOUR-NETWORK-DOMAIN/rest-api/action/id/{id}/tracking-code.do Returns what the console's Conversion Tracking Code window shows for the action. 'postback' (needs ACTION_TRACKING_S2S) — the server-to-server URLs: actionTrackUrl, fired with the click id the landing page received in the easclid parameter (landingUrlExample shows the $$CLICK_ID$$ macro to put in the click URL), and the legacy per-action variant (subIdMacro, subIdLandingUrlExample, subIdActionTrackUrl). 'pixel' (needs ACTION_TRACKING_CODE and a campaignId, as the pixel is campaign-specific) — jsPixelCode, the image pixel URL pixelTrackingUrl, and jsPixelCodeWithPiggybacks when the campaign has piggyback pixels on and the role holds PIGGYBACK_PIXEL_TRACKING. The codes are built on 'host' when given (one of the selectable ad-serving domains), else on the campaign's conversion-pixel domain, else on the action's own; the domain used is echoed in 'host'. Requires VIEW access to the action, and to the campaign's advertiser when campaignId is given.
Path Params
id integer required
The numeric database ID of the action
301 Query Params
campaignId integer
Campaign the codes are for; required for the pixel
2001 host string
Ad-serving domain to build the codes on; one of the selectable domains
ads.example.com Responses
200
The tracking codes the caller may see, under postback and/or pixel
400
Unknown ad-serving domain, or only the pixel is permitted and no campaignId was given
401
Authentication error
403
No access to the action or campaign, or neither ACTION_TRACKING_S2S nor ACTION_TRACKING_CODE
404
Action or campaign not found