growsurf_update_campaign_installation
Patch GrowSurf program installation configuration, updating only the fields you send. Change allowed origins or Share URL after customer confirmation.
Instructions
Update the Installation tab configuration for your GrowSurf program. Only the fields you send are changed; anything you leave out is untouched (arrays replace wholesale). To let GrowSurf run on another origin, such as http://localhost:3000, add that origin to allowedUrls and preserve the rest of the array; a browser origin missing from both shareUrl and allowedUrls can return 403. Leave shareUrl out of the patch unless the customer asked for a different landing page: every referral link already shared points at the current one. A patch that would replace a Share URL that is already set is refused until you confirm it with the customer and resend with replaceExistingShareUrl: true. Fetch the tab first, then pass just the fields you want to change under fields. Targets campaignId if you pass it, otherwise GROWSURF_CAMPAIGN_ID.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| fields | Yes | Installation fields to patch. Common keys include `shareUrl`, `allowedUrls`, `signupEvent`, `referralTrigger`, and `signup`. Arrays replace wholesale. | |
| campaignId | No | Target program (campaign) id for this call. Defaults to GROWSURF_CAMPAIGN_ID when omitted. Pass the `id` returned by growsurf_create_campaign to configure or operate a program you just created, without restarting the server. | |
| replaceExistingShareUrl | No | Set this to `true` only after the customer confirms they want a different landing page. Without it, a patch that would replace a Share URL that is already set is refused. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||