Skip to content

Commit 8dea0ad

Browse files
authored
feat: improve webhook sync in skills (#120)
1 parent ac5fe40 commit 8dea0ad

3 files changed

Lines changed: 37 additions & 1 deletion

File tree

.agents/skills/zoneless-marketplace/SKILL.md

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -103,6 +103,37 @@ command preserves unrelated variables, ignores the target in Git, and writes
103103
owner-only permissions. For deployment, add only environment variable names
104104
and secret-manager references; the human supplies live values during handoff.
105105

106+
## Configure test webhook delivery when used
107+
108+
If the integration implements a Zoneless webhook route, determine its public
109+
HTTPS URL. For localhost, explain that Zoneless cannot reach `localhost`; the
110+
human must run a tunnel such as `ngrok http <port>` or Cloudflare Tunnel and
111+
provide its public URL. Do not silently install or leave a tunnel running.
112+
113+
Before handoff, ask for that URL so you can complete webhook sync. If the human
114+
cannot provide one, distinguish **application code complete** from **webhook
115+
delivery pending** and include the exact command they must run later.
116+
117+
For the standard marketplace flow, sync the onboarding, transfer, and payout
118+
events without displaying the signing secret:
119+
120+
```bash
121+
npx @zoneless/cli@latest webhook sync \
122+
--url "https://<public-host>/<server-webhook-route>" \
123+
--events "account.updated,transfer.created,payout.paid,payout.failed" \
124+
--json
125+
```
126+
127+
Add `--target <relative-path>` when the server uses a non-default env file.
128+
`webhook sync` replaces the managed endpoint's event list, so if the application
129+
already handles other Zoneless events, pass the union of its existing events
130+
and the marketplace events it needs. Restart the application afterward so it
131+
loads `ZONELESS_WEBHOOK_SECRET`.
132+
133+
If the implementation intentionally retrieves account and payout status instead
134+
of using webhooks, do not create an unused endpoint or require
135+
`ZONELESS_WEBHOOK_SECRET`.
136+
106137
## Use test mode, then hand off live promotion
107138

108139
Setup provisions both test and live profiles and makes test the current CLI

.agents/skills/zoneless-payments/SKILL.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -107,6 +107,11 @@ that Zoneless cannot reach `localhost`; the human must run a tunnel such as
107107
`ngrok http <port>` or Cloudflare Tunnel and provide its public HTTPS URL. Do not
108108
silently install or leave a tunnel process running.
109109

110+
Before handoff, ask the human for the public HTTPS URL so you can complete
111+
webhook sync. If they cannot provide one, distinguish **application code
112+
complete** from **webhook delivery pending** and include the exact command they
113+
must run later; do not imply that webhook-backed entitlements are ready.
114+
110115
Once the URL is known, create or update the bound test endpoint and sync its
111116
signing secret without displaying it:
112117

apps/cli/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@zoneless/cli",
3-
"version": "0.1.7",
3+
"version": "0.1.8",
44
"description": "Provision and manage an agent-operated Zoneless store",
55
"license": "Apache-2.0",
66
"repository": {

0 commit comments

Comments
 (0)