01Jobs it does
Each one is a real command line. Copy it, or open it in the builder below to change it.
tracking link
Also: generate a tracking link, campaign link
p202 tracker create-with-url02What you get
Captured from the real binary, run against a demo store with 30 days of traffic. Switch tabs to see the same run as JSON, the shape scripts and agents parse.
$ p202 tracker create-with-url --aff-campaign-id 1 --ppc-account-id 3 --click-cpc 0.42 tracker: {"aff_campaign_id":1,"click_cloaking":-1,"click_cpa":null,"click_cpc":0.42,"etag":"\"77b98206caa2d24c5f429c04772c8a256b548906\"","landing_page_id":0,"ppc_account_id":3,"rotator_id":0,"text_ad_id":0,"tracker_id":18,"tracker_id_public":388360112,"user_id":1,"version":"77b98206caa2d24c5f429c04772c8a256b548906"} tracking_url: {"direct_url":"https://track.example.com/tracking202/redirect/dl.php?t202id=388360112\u0026t202kw=","tracker_id":18,"tracker_id_public":388360112,"tracking_params":"?t202id=388360112\u0026t202kw="}
$ p202 tracker create-with-url --aff-campaign-id 1 --ppc-account-id 3 --click-cpc 0.42 --json { "tracker": { "aff_campaign_id": 1, "click_cloaking": -1, "click_cpa": null, "click_cpc": 0.42, "etag": "\"4a5dc8fe10d2b662f86149ff3c2b4d9cb2dc0fcc\"", "landing_page_id": 0, "ppc_account_id": 3, "rotator_id": 0, "text_ad_id": 0, "tracker_id": 19, "tracker_id_public": 399460057, "user_id": 1, "version": "4a5dc8fe10d2b662f86149ff3c2b4d9cb2dc0fcc" }, "tracking_url": { "direct_url": "https://track.example.com/tracking202/redirect/dl.php?t202id=399460057\u0026t202kw=", "tracker_id": 19, "tracker_id_public": 399460057, "tracking_params": "?t202id=399460057\u0026t202kw=" } }
03Build your command
Pick values and the command line writes itself, quoted and ready to paste.
p202 tracker create-with-urlSet flags below; the command updates as you type.
04Flags
22 flags, plus the global flags every command takes.
| Flag | What it does |
|---|---|
| --aff-campaign-idstring | Campaign ID (from p202 campaign list); 0 for a link to a redirector (--rotator-id) or an advanced landing page |
| --c1string | Value for c1 in the link, as given (e.g. your traffic source's macro); default: the traffic source's own variable |
| --c2string | Value for c2 in the link, as given (e.g. your traffic source's macro); default: the traffic source's own variable |
| --c3string | Value for c3 in the link, as given (e.g. your traffic source's macro); default: the traffic source's own variable |
| --c4string | Value for c4 in the link, as given (e.g. your traffic source's macro); default: the traffic source's own variable |
| --click-cloakingstring | Cloaking: 1 on, 0 off, -1 use the campaign's setting: -1, 0, 1-101 |
| --click-cpastring | Cost per action, 0-99.99999; on update, makes the tracker CPA and clears its cost per click. Not with --click-cpc |
| --click-cpcstring | Cost per click, 0-99.99999; on update, makes the tracker CPC and clears its cost per action |
| --idempotency-keystring | Retry-safe create: the server records the response under this key and replays it on a retry with the same key and payload instead of creating a duplicate |
| --landing-page-idstring | Landing page ID |
| --ppc-account-idstring | PPC account ID |
| --rotator-idstring | Rotator ID |
| --t202bstring | Value for t202b in the link, as given (e.g. your traffic source's macro); default: the traffic source's own variable |
| --t202kwstring | Value for t202kw in the link, as given (e.g. your traffic source's macro); default: the traffic source's own variable |
| --t202refstring | Value for t202ref in the link, as given (e.g. your traffic source's macro); default: the traffic source's own variable |
| --text-ad-idstring | Text ad ID |
| --tracker-id-publicstring | Public tracker ID |
| --utm-campaignstring | Value for utm_campaign in the link, as given (e.g. your traffic source's macro); default: the traffic source's own variable |
| --utm-contentstring | Value for utm_content in the link, as given (e.g. your traffic source's macro); default: the traffic source's own variable |
| --utm-mediumstring | Value for utm_medium in the link, as given (e.g. your traffic source's macro); default: the traffic source's own variable |
| --utm-sourcestring | Value for utm_source in the link, as given (e.g. your traffic source's macro); default: the traffic source's own variable |
| --utm-termstring | Value for utm_term in the link, as given (e.g. your traffic source's macro); default: the traffic source's own variable |
05For agents
Running this from an agent
- Read the same facts as JSON:
p202 commands tracker create-with-url --json. - With
AI_AGENT,CLAUDECODEor another agent variable set, output is compact JSON and errors arrive on stderr as a JSON envelope with ahint. - Exit codes: 0 ok, 1 bad input, 2 auth, 3 network, 4 server error, 5 partial failure.
- This command writes. Add
--stagedto record it as a proposal a person applies withp202 change apply.
{
"path": "p202 tracker create-with-url",
"use": "create-with-url",
"short": "Create a tracker and return its tracking URL",
"runnable": true,
"tasks": [
{
"run": "p202 tracker create-with-url",
"ui_pages": [
"Setup › Get Links"
],
"phrases": [
"tracking link",
"generate a tracking link",
"campaign link"
]
}
],
"flags": [
{
"name": "aff-campaign-id",
"type": "string",
"default": "",
"usage": "Campaign ID (from `p202 campaign list`); 0 for a link to a redirector (--rotator-id) or an advanced landing page",
"required": false
},
{
"name": "c1",
"type": "string",
"default": "",
"usage": "Value for c1 in the link, as given (e.g. your traffic source's macro); default: the traffic source's own variable",
"required": false
},
{
"name": "c2",
"type": "string",
"default": "",
"usage": "Value for c2 in the link, as given (e.g. your traffic source's macro); default: the traffic source's own variable",
"required": false
},
{
"name": "c3",
"type": "string",
"default": "",
"usage": "Value for c3 in the link, as given (e.g. your traffic source's macro); default: the traffic source's own variable",
"required": false
},
{
"name": "c4",
"type": "string",
"default": "",
"usage": "Value for c4 in the link, as given (e.g. your traffic source's macro); default: the traffic source's own variable",
"required": false
},
{
"name": "click-cloaking",
"type": "string",
"default": "",
"usage": "Cloaking: 1 on, 0 off, -1 use the campaign's setting: -1, 0, 1",
"allowed_values": [
"-1",
"0",
"1"
],
"required": false
},
{
"name": "click-cpa",
"type": "string",
"default": "",
"usage": "Cost per action, 0-99.99999; on update, makes the tracker CPA and clears its cost per click. Not with --click-cpc",
"required": false
},
{
"name": "click-cpc",
"type": "string",
"default": "",
"usage": "Cost per click, 0-99.99999; on update, makes the tracker CPC and clears its cost per action",
"required": false
},
{
"name": "idempotency-key",
"type": "string",
"default": "",
"usage": "Retry-safe create: the server records the response under this key and replays it on a retry with the same key and payload instead of creating a duplicate",
"required": false
},
{
"name": "landing-page-id",
"type": "string",
"default": "",
"usage": "Landing page ID",
"required": false
},
{
"name": "ppc-account-id",
"type": "string",
"default": "",
"usage": "PPC account ID",
"required": false
},
{
"name": "rotator-id",
"type": "string",
"default": "",
"usage": "Rotator ID",
"required": false
},
{
"name": "t202b",
"type": "string",
"default": "",
"usage": "Value for t202b in the link, as given (e.g. your traffic source's macro); default: the traffic source's own variable",
"required": false
},
{
"name": "t202kw",
"type": "string",
"default": "",
"usage": "Value for t202kw in the link, as given (e.g. your traffic source's macro); default: the traffic source's own variable",
"required": false
},
{
"name": "t202ref",
"type": "string",
"default": "",
"usage": "Value for t202ref in the link, as given (e.g. your traffic source's macro); default: the traffic source's own variable",
"required": false
},
{
"name": "text-ad-id",
"type": "string",
"default": "",
"usage": "Text ad ID",
"required": false
},
{
"name": "tracker-id-public",
"type": "string",
"default": "",
"usage": "Public tracker ID",
"required": false
},
{
"name": "utm-campaign",
"type": "string",
"default": "",
"usage": "Value for utm_campaign in the link, as given (e.g. your traffic source's macro); default: the traffic source's own variable",
"required": false
},
{
"name": "utm-content",
"type": "string",
"default": "",
"usage": "Value for utm_content in the link, as given (e.g. your traffic source's macro); default: the traffic source's own variable",
"required": false
},
{
"name": "utm-medium",
"type": "string",
"default": "",
"usage": "Value for utm_medium in the link, as given (e.g. your traffic source's macro); default: the traffic source's own variable",
"required": false
},
{
"name": "utm-source",
"type": "string",
"default": "",
"usage": "Value for utm_source in the link, as given (e.g. your traffic source's macro); default: the traffic source's own variable",
"required": false
},
{
"name": "utm-term",
"type": "string",
"default": "",
"usage": "Value for utm_term in the link, as given (e.g. your traffic source's macro); default: the traffic source's own variable",
"required": false
}
]
}