26 lines
1.1 KiB
Markdown
26 lines
1.1 KiB
Markdown
# Corben function sources
|
|
|
|
These two files are the source of truth for the Corben functions behind the RSVP
|
|
flow. They do NOT deploy with the site: `deploy_site` only serves the site, and
|
|
Corben functions live in the platform, not in this repo. They are checked in so
|
|
the logic is reviewable and diffable instead of only existing inside the API.
|
|
|
|
To change one, edit here and push it up:
|
|
|
|
```bash
|
|
KEY=$(grep '^CORBEN_API_KEY=' ~/.corben.env | cut -d= -f2-)
|
|
jq -n --rawfile code ops/founders-break-rsvp.js '{code:$code}' \
|
|
| curl -sS -X PUT https://api.corben.world/functions/3d3c4bed-c073-40a4-9a32-9ff6944737dd \
|
|
-H "Authorization: Bearer $KEY" -H "Content-Type: application/json" -d @-
|
|
```
|
|
|
|
The reminder is `cf2a1e4c-43f9-4cf4-8fc5-652c494940ae`. Their `env` (CORBEN_KEY,
|
|
LIST_ID, FROM, FROM_ADDRESS_ID, NOTIFY) is set on the function record and is not
|
|
in these files. Never paste the key into this repo.
|
|
|
|
Test without waiting for a real submission:
|
|
|
|
```
|
|
execute_function id=3d3c4bed-... event={"form_name":"rsvp","data":{"name":"...","email":"..."}}
|
|
execute_function id=cf2a1e4c-... event={"force":true} # sends for real
|
|
```
|