Set Program Custom Domain
growsurf_set_campaign_custom_domainSet or replace the custom domain for your GrowSurf program's landing pages. Pass a hostname such as refer.example.com in domain; https:// is added if you leave it out. Paths, ports, queries, and http:// return 400. Replacing a domain removes the old one right away, and its pages stop loading there, so confirm with the customer before replacing a domain that is already set. Sending the current domain again changes nothing. A domain used by another program returns 409, and 403 means the account cannot use custom domains yet: a higher plan is needed, or for an affiliate program, a payment method on file. A new domain starts unverified: add the CNAME record from the returned dnsRecord at the DNS provider (dnsRecord.name pointing to dnsRecord.value), then call growsurf_verify_campaign_custom_domain. Targets campaignId if supplied, otherwise GROWSURF_CAMPAIGN_ID.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"domain": "<domain>",
"campaignId": "<campaignId>"
},
"name": "growsurf_set_campaign_custom_domain"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| domain | Yes | The hostname to serve the program's landing pages from, with or without `https://`, such as `refer.example.com`. | |
| campaignId | Yes | Target program (campaign) id for this call. Defaults to GROWSURF_CAMPAIGN_ID when omitted. Program IDs also identify newly created programs without restarting the server. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||