Expand description
Capability ID mappings for env.host_call dispatch.
Each capability module has a unique cap_id and each function within
it has a unique fn_id. These constants are used by:
- The stdlib capability modules (to return
CapabilityCallerrors) - The WASM code generator (to emit
env.host_call(cap_id, fn_id, ...)instructions)
Constants§
- CAP_
CREDENTIAL - Credential resolution (internal — PEPL code does not call directly).
- CAP_
HTTP - HTTP capability (get, post, put, patch, delete).
- CAP_
LOCATION - Location/GPS capability (current).
- CAP_
NOTIFICATIONS - Push notifications capability (send).
- CAP_
STORAGE - Persistent storage capability (get, set, delete, keys).
- CREDENTIAL_
GET - HTTP_
DELETE - HTTP_
GET - HTTP_
PATCH - HTTP_
POST - HTTP_
PUT - LOCATION_
CURRENT - NOTIFICATIONS_
SEND - STORAGE_
DELETE - STORAGE_
GET - STORAGE_
KEYS - STORAGE_
SET
Functions§
- capability_
module_ names - Returns all capability module names.
- is_
capability_ module - Returns
trueif the given module name is a capability module. - resolve_
ids - Resolve a capability module name + function name to
(cap_id, fn_id).