Not released yet. PeltyCMS is under development and not released yet; these docs describe the upcoming release and may change.
PeltyCMS Developer docs
User docsDevelopers
v0.1.0

Developer docs/Extension reference

Hook points index

Every string you can put in capabilities.hooks[].event, capabilities.events or capabilities.mixins[].target, with what it can do.

TargetWhereCountCancelModifyDocs
<pre-event>, e.g. order.before_placehooks4yeslisted keysCancel and modify
<domain-event>events (on-event)34nonoEvents index
after:<domain-event>, finished:<domain-event>hooks68nonoEvents index
before:<METHOD> <route>, before:*hooks464yesrequest bodyCancel and modify
during: / after: / finished:<METHOD> <route>hooks1392nonoHooks and mixins
before:<addon>:<event>hooksaddon-definedyeswhole payloadEvents and hooks
<METHOD> <route> mixin (before, after, around, return)mixins795return replacesbody / responseHooks and mixins
UI slotui.slotssee page--Widgets and slots

#Phases

PhaseWhenCan change itPayload
beforeBefore the action, synchronously, in priority orderyes: modify, cancel, uncancelevent payload (requests: {method, path, route, query, body})
duringWhile the request runs, in the background (requests only)no{request}
afterAfter successnodomain: the event payload; requests: {request, http_status, response}; custom: {source, payload}
finishedAlways lastno{status: ok|failed|cancelled, …}

#Priorities

NameValueNote
lowest0runs first
low50
normal100default
high150
highest200
monitor1000runs last, observe only

Integers from -1000 to 1000 are accepted too.