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/Bundled addons

Lifecycle demo (test fixture)

addons.desc.integration.lifecycle This is a test fixture used by the integration tests; it is not offered in the marketplace.

FieldValue
Addon idintegration-lifecycle
Kindintegration
Provideslifecycle
Enginewasm
ABI0.3.0
Version0.1.0
AuthorMythicalSystems
Sourceextensions/addons/fixture-lifecycle
Permissions (shown at install)none

#Capabilities

CapabilityValue
emitsintegration-lifecycle:greet
hooks[{"event":"before:PUT /api/v1/client/profile","priority":"normal"},{"event":"during:PUT /api/v1/client/profile"},{"event":"after:PUT /api/v1/client/profile"},{"event":"finished:PUT /api/v1/client/profile","priority":"monitor"},{"event":"before:integration-lifecycle:greet","ignore_cancelled":true,"priority":"highest"}]
kvtrue
mixins[{"at":"around","target":"PUT /api/v1/client/profile"},{"at":"after","priority":10,"target":"GET /api/v1/client/profile"},{"at":"return","priority":20,"target":"GET /api/v1/client/profile"}]
routes[{"access":"client","method":"POST","path":"/greet"},{"access":"client","method":"POST","path":"/greet-other"},{"access":"client","method":"GET","path":"/log"}]
uiiframe

#Events and hooks

WhatValue
Listens to (events)none
Hooksbefore:PUT /api/v1/client/profile, during:PUT /api/v1/client/profile, after:PUT /api/v1/client/profile, finished:PUT /api/v1/client/profile, before:integration-lifecycle:greet
Emitsintegration-lifecycle:greet
MixinsPUT /api/v1/client/profile (around), GET /api/v1/client/profile (after), GET /api/v1/client/profile (return)
Scheduled jobsnone

#Settings and secrets

No admin settings are declared in addon.json or in the source.

Secrets (stored encrypted, never returned by the API): none.

Outbound HTTP allowed to: none. $server is the hostname of the server configured for the product, $setting:<key> the host of that setting.

#HTTP routes

Mounted under /api/v1/addons/integration-lifecycle/.

MethodPathAccessPermission
POST/greetclient-
POST/greet-otherclient-
GET/logclient-

#UI

Pages: log (client), frame (client). Slots: client.invoices.toolbar, client.dashboard.after. See Widgets and slots.

#addon.json

extensions/addons/fixture-lifecycle/addon.jsonJSON
{
  "abi": "0.3.0",
  "author": "MythicalSystems",
  "capabilities": {
    "emits": [
      "integration-lifecycle:greet"
    ],
    "hooks": [
      {
        "event": "before:PUT /api/v1/client/profile",
        "priority": "normal"
      },
      {
        "event": "during:PUT /api/v1/client/profile"
      },
      {
        "event": "after:PUT /api/v1/client/profile"
      },
      {
        "event": "finished:PUT /api/v1/client/profile",
        "priority": "monitor"
      },
      {
        "event": "before:integration-lifecycle:greet",
        "ignore_cancelled": true,
        "priority": "highest"
      }
    ],
    "kv": true,
    "mixins": [
      {
        "at": "around",
        "target": "PUT /api/v1/client/profile"
      },
      {
        "at": "after",
        "priority": 10,
        "target": "GET /api/v1/client/profile"
      },
      {
        "at": "return",
        "priority": 20,
        "target": "GET /api/v1/client/profile"
      }
    ],
    "routes": [
      {
        "access": "client",
        "method": "POST",
        "path": "/greet"
      },
      {
        "access": "client",
        "method": "POST",
        "path": "/greet-other"
      },
      {
        "access": "client",
        "method": "GET",
        "path": "/log"
      }
    ],
    "ui": [
      "iframe"
    ]
  },
  "description": "addons.desc.integration.lifecycle",
  "engine": "wasm",
  "i18n": {
    "en": {
      "badge": "Lifecycle on",
      "frame_title": "Lifecycle frame",
      "key": "Phase",
      "log_hint": "Counters of every event phase and mixin.",
      "log_title": "Event log",
      "value": "Count"
    },
    "ro": {
      "badge": "Lifecycle activ",
      "frame_title": "Cadru lifecycle",
      "key": "Fază",
      "log_hint": "Contoare pentru fiecare fază de eveniment și mixin.",
      "log_title": "Jurnal evenimente",
      "value": "Număr"
    }
  },
  "id": "integration-lifecycle",
  "kind": "integration",
  "name": "Lifecycle demo (test fixture)",
  "permissions": [],
  "provides": "lifecycle",
  "settings": [],
  "ui": {
    "pages": [
      {
        "area": "client",
        "body": {
          "children": [
            {
              "text": "{{t:plugin.integration-lifecycle.log_hint}}",
              "type": "text"
            },
            {
              "columns": [
                {
                  "header": "plugin.integration-lifecycle.key",
                  "value": "{{row.key}}"
                },
                {
                  "header": "plugin.integration-lifecycle.value",
                  "value": "{{row.value}}"
                }
              ],
              "rows": "{{data.log.rows}}",
              "type": "table"
            }
          ],
          "type": "stack"
        },
        "data": {
          "log": {
            "get": "/api/v1/addons/integration-lifecycle/log"
          }
        },
        "icon": "Lightning",
        "id": "log",
        "nav": true,
        "title": "plugin.integration-lifecycle.log_title"
      },
      {
        "area": "client",
        "frame": {
          "height": 200,
          "src": "assets/ui.html"
        },
        "icon": "AppWindow",
        "id": "frame",
        "nav": true,
        "title": "plugin.integration-lifecycle.frame_title"
      }
    ],
    "slots": [
      {
        "body": {
          "text": "{{t:plugin.integration-lifecycle.badge}}",
          "type": "badge"
        },
        "slot": "client.invoices.toolbar"
      },
      {
        "body": {
          "height": 120,
          "src": "assets/ui.html",
          "type": "frame"
        },
        "slot": "client.dashboard.after"
      }
    ]
  },
  "version": "0.1.0",
  "wasm": "addon.wasm"
}