Change server code switches
Changed onenabled: the owner switch, any owner proof. Off: your code does not run; saves follow the page's list rules. accountRead: "Reads your other pages", only with the profile that published the code (its X-Owner-Token or a signed-in session). Answers the same view as the read.
Request
- Base URLhttps://brewpage.app
- Auth
- API key in header X-Owner-Token
- or API key in header X-Manage-Key
Path parameters
Headers
Owner token returned at creation, or a token of your profile
Management key of this publication
Request body
Server code switches; either or both
Owner switch. Off: your code does not run; saves follow the page's list rules.
"Reads your other pages": only with the profile that published the code
Response
Saved; same answer as the read
Server code of an HTML page or site: switches, code, counters, usage and the newest runs (owner only).
Owner switch. Off: your code does not run; saves follow the page's list rules.
Paused by BrewPage: the code does not run; while enabled, saves of a page with beforeWrite are refused until lifted. With enabled false, saves follow the page's list rules.
The code runs now: on, not paused and server code available.
"Reads your other pages" (bp.account): off by default, off again after any code, token or profile change.
This request may change accountRead: it carries the profile that published the code.
Code version: +1 for each changed lambda.js
Always lambda.js
The text of lambda.js
Exported handlers: onEntry, onComment, beforeWrite
Own endpoint names (at most 2), called by the page with bp.lambda(name, body)
Usage windows: this page's UTC hour (runs), the profile's UTC day (runs, run time, fetches)
Caps of the same windows as usage, as they apply to this page now
Newest finished runs, newest first
offset for GET .../lambda/runs to read older runs; absent when none
Changes
- info
endpoint added
- info