Machine-translated – improvements welcome. Suggest an improvement
Developing packages¶
Packages extend Ablago with ready-made folder types, views and sample folders. Whoever administers Ablago install them under Workbench → Packages from the official catalogue (see Administrator manual → Packages).
Where packages live¶
All official packages are in the repository motom001/dms-registry, one folder per package under pakete/<id>/. The same rules apply there as in Ablago: first an issue as a user story; implementation follows the label freigegeben. The rules for packages (licences, what is forbidden, names) are in REGELN.md.
Package kinds and same keys¶
Before you create a package, decide its kind – the rules are in REGELN.en.md, "Package kinds" (dms-registry #157):
- Foundation package Basis (organisation, person, storage location) – always installed; every template package depends on it.
- Template packages bring folder types, views and automations for one area (Haushalt, Fahrzeuge, Verträge, Rechnungen). They may bring code that only maintains their own folder types, e.g. calculating status and deadlines.
- Function packages bring code for all folders but no folder types (Texterkennung, PDF/A, AI).
- Add-ons extend exactly one other package (
ergaenzt) and change neither its types nor its permissions. - Languages and automation packages bring only texts or only automations.
Two rules keep packages together:
- A folder type lives in exactly one package. Other packages refer to it (
vertraege:vertrag) and list it underabhaengigkeiten. - Same keys for the same meaning –
von,an,betrag,datum,betrifft,steuerjahr,zustaendig,verbleib_original… (list in REGELN.en.md, "Same keys"). Then hit lists and views across several folder types show the same columns. The label may speak per type ("Anbieter", "Rechnungssteller"), the key may not.pruefen.pypoints out deviations in new fields. Post in Ablago follows this (since 0.242, #1042):von(text) andan(link to a user). Recognition uses both in folder types (#1043): a link fieldvon(issuer) never gets an own organisation or a person of the household – only for an outgoing document, as a suggestion with a note –, andan(recipient) stays empty for incoming documents. - How Ablago merges columns: A view with several folder types shows the columns of a hit list that every type has under the same key (packages:
standard), and of those only fields that exist in every type with the same key and the same field type (for links the field type counts, not the target); otherwise only the system columns. Conditions and the advanced search across several types also require the same target types for links. The label never counts – only the key. Avonas text (post) and avonas link (contract) are therefore not a shared column.
Text templates (e.g. a cancellation letter) are brought only as Markdown under inhalt/vorlagen/: no HTML, no images, links only https:, no password fields as placeholders. pruefen.py rejects anything else, and Ablago checks the same when installing (#1038, #1040).
Creating a package¶
git clone https://github.com/<you>/dms-registry && cd dms-registry
werkzeuge/neues-paket.sh mein_paket "My package" # copies vorlage/ to pakete/mein_paket/
Then fill in:
| File | Content |
|---|---|
manifest.yaml |
schema: 1 (required), id, name, version (SemVer), description, author, licence, required Ablago version (e.g. ">=0.63.0"), dependencies, inhalt with the paths of the content files (e.g. mappentypen: inhalt/mappentypen.yaml), optionally code |
inhalt/mappentypen.yaml |
folder types with fields, tabs, title and result list |
inhalt/sichten.yaml |
views with parent view, folder types and conditions |
inhalt/beispiele.yaml |
optional: sample folders with invented data |
inhalt/beispiele/… |
optional (from Ablago 0.223.0): example documents for the sample folders (PDF, PNG, JPEG), invented content only |
inhalt/vorgaben.yaml |
optional (dms #1038): presets – folders to keep with a fixed key, e.g. contract types |
inhalt/vorlagen/… |
optional (dms #1038): text templates of the presets, plain Markdown (.md) |
inhalt/wortlisten.yaml |
optional (from Ablago 0.127.0): groups of synonyms for the search |
inhalt/automatisierungen.yaml |
optional (from Ablago 0.177.0): ready-made automations, always created; off after installation – except those whose switch is on in the installation dialog (since 0.233.0 preset with eingeschaltet: true) |
inhalt/ablaufvorlagen.yaml |
optional (from Ablago 0.256.0, DMS_ABLAUFVORLAGEN_AB): automation templates for the “Folder” menu – only tasks and notifications |
inhalt/rundgaenge.yaml |
optional (dms #831): tours through a task |
texte/<sprache>/entdecken.json |
optional (dms #1307): texts of the tours and tips per language, German as the base language (Languages); older packages write them directly into the YAML files |
inhalt/tipps.yaml |
optional (dms #832): tips, at most 20, also “new in version …” |
inhalt/region.yaml |
optional (from Ablago 0.333.0, DMS_REGIONSPAKETE_AB, dms #1696): region package – public holidays and regions of a country as rules |
README.md, LICENSE, CHANGELOG.md |
description, licence text, changes per version |
tests/erwartung.yaml |
what must be there after installation |
The keys in these files are German (as in the registry's schemas), in every language.
Creating a package from your Ablago¶
Instead of starting with the template, you can export folder types and views you have built in Ablago under Workbench → Packages → Create package (from Ablago 0.86.0, see Administrator manual → Creating a package from your Ablago). The result is a ZIP with a folder <id>/ in the registry's format – manifest.yaml, inhalt/mappentypen.yaml, inhalt/sichten.yaml, if applicable inhalt/beispiele.yaml, README.md from the description, CHANGELOG.md, LICENSE with the full licence text and tests/erwartung.yaml. It passes werkzeuge/pruefen.py; unpacked under pakete/ it is a finished package folder for a pull request (README and description are still worth expanding).
Minimum version when creating (dms #651): "Create package" determines the required Ablago version itself – mindestversion() in server/src/pakete/erstellung/mindestversion.ts. The basis is 0.86.0 (since then "Create package" has existed); every function used from MINDEST_FUNKTIONEN can raise it: links to Ablago's folder types (0.75.0), links between examples (0.79.0), erkennung on fields (0.113.0), format, landFeld and date limits min/max (0.121.0), example documents (0.223.0), the field kinds zeitraum and prozent and negativ on amounts (FELDARTEN_AB, #1035), the field kind tabelle (DMS_TABELLE_AB, #1030), vorbelegen on link fields (DMS_VORBELEGEN_AB, #1037), gehoertZu (DMS_TEILE_AB, #1031), "refers to the preset" in display conditions (DMS_VORGABEN_AB, #1038), field kind zusammengesetzt (DMS_ZUSAMMENGESETZT_AB, #1050), archiv on the folder type (DMS_ARCHIV_PAKET_AB, #1051), merkmal, schreibschutz and "refers to an own organisation" (DMS_ORGANISATION_AB, #995), genauigkeit: monat on date fields (DMS_DATUM_MONAT_AB, #1722), the recognition kind code (DMS_CODES_AB, #1723). You can then choose >=X.Y.0 from the minimum version up to your own version (dmsOptionen(); minor versions that never existed are missing). If the package format brings something new that "Create package" takes along, it belongs in MINDEST_FUNKTIONEN – with a test in server/test/paketerstellung.test.ts. The licence is a free one from the positive list, a custom one (LicenseRef-<name>, text as LICENSE) or none (NONE); Ablago installs all three, pruefen.py only lets the positive list into the catalogue.
This is how the export maps Ablago to the package format:
| In Ablago | In the package |
|---|---|
| folder type of your own | entry in mappentypen.yaml; key from the type's key, stays the same across versions (remembered) |
| type or view from an installed package | not copied but abhaengigkeiten: { <package>: ">=<installed version>" }, links as <package>:<key> |
| link to user, role | dms:benutzer, dms:rolle (then dms at least >=0.75.0) |
| link to the storage location | basis:ablageort with abhaengigkeiten: { basis: ">=1.6.0" } (since 0.212; dms:ablageort is a deprecated alias) |
| view on a type of your own that wasn't chosen (#656) | fremde_typen: [{ kennung, name }] on the view – the type's key (or <package>:<key> if it is in a package exported earlier); then dms at least >=0.178.0 |
| default result list | trefferliste; further result lists are missing |
| the view's icon (#428) | symbol on the view |
| condition on a field | { feld, operator, wert }, dynamic values (today, me …) as an object; conditions on counts, favourites, deadlines and on fixed folders are missing |
| chosen sample folders | beispiele.yaml with schluessel and { beispiel: … } for links among each other; without passwords and links to folders not chosen |
| their documents (only with "Include their documents", #878) | PDF, PNG and JPEG under inhalt/beispiele/beispiel_<n>/, in the example under dokumente with titel (name in Ablago), datum and register; other file types stay out with a notice; then dms at least >=0.223.0 |
| archive mode (dms #1051) | archiv: { jahre, stichtag, leererStichtag } on the folder type – the reference date only if its field comes along; then dms at least >=0.237.0 |
| number sequence on the field, permissions | missing (the format doesn't know them); the check names them |
Package format (binding)¶
The format is described by the JSON schemas in the registry: schema/manifest.schema.json and schema/inhalt.schema.json. The template shows every entry with a comment. Ablago reads exactly this format:
- Manifest:
schema: 1is required; another value is rejected.inhaltnames the files withmappentypen,sichten,beispiele,wortlistenandautomatisierungen(paths relative to the package folder). The schema also knowsinhalt.rollen; Ablago doesn't read it. - A view's icon (dms #428):
symbol: <name>on a view insichten.yaml, a Lucide name from the fixed list inshared/src/ansichtsymbole.ts(e.g.house,car,euro,heart-pulse,mail). The list belongs to the Ablago version; names are never renamed or removed, only added. Ablago reads an unknown name (package for a newer version) as "without icon", without an error. Since #1519 there are 259 icons in 16 groups (previously 76; the 183 new ones from the version the changelog names under #1519). A package that uses a new icon still runs on older Ablago – the view just has no icon there; if the icon must appear, setdms: ">=<that version>". All 17 icons of the package catalogue (dms-registrywerkzeuge/symbole/) are in the list. The shapes are generated by.github/werkzeuge/ansichtsymbole-formen.mjsfromlucide-static1.76.0 – never typed by hand; new names go into the list first (meaning in de/en, group), then regenerate the shapes. - Unknown fields (dms #635): fields that Ablago doesn't know it ignores – in the manifest (at the top and in sub-sections such as
autor,inhalt, on folder types, views and examples), inkatalog.jsonand in a bundle file's directory. That way new optional fields (e.g.symbol,kuerzel,kategorien) don't break older Ablago; new fields are therefore always optional. Only another format is rejected:schemaorformatnot equal to 1. The signature still covers the raw bytes ofkatalog.json, unknown fields included. The testserver/test/unbekannte-felder.test.tsrecords this. - Package ID (
id, dms #1084): lower-case letters, digits and_, starting with a letter, 2 to 40 characters – e.g.haus_und_garten. One dot with an addition (up to 20 characters) may follow:<main package>.<addition>, e.g.texterkennung.fra. The dot means "extends the main package" – such a package must stateergaenzt: <main package>(see Add-ons), otherwise Ablago rejects it.dmsis taken. Ablago knows IDs with a dot from 0.229.0; such packages statedms: ">=0.229.0". - Keys (
schluesselfor folder types, views, automations and examples,keyfor fields and tabs) are local in the package, up to 60 characters. Ablago stores package and key separately; to the outside a folder type from a package is calledpackage:keyeverywhere – as in references, e.g.basis:person(up to 0.228basis_person; that was ambiguous, because packagehaus+ typegarten_pflanzeand packagehaus_garten+ typepflanzegave the same identifier). The limits aren't technical ones – identifiers are text, folder types are linked by uuid –, they keep links, file names and displays readable.shared/src/kennungen.tsholds all patterns in one place. - Publisher (
herausgeber, dms #1084): who publishes the package, as a reversed domain – lower-case letters, digits and hyphens, at least two parts, e.g.org.example; the official packages haveapp.ablago. Ablago shows it next to the name ("Contracts · app.ablago") and refuses installation and update if the same ID is already installed from a different publisher. Ablago only acceptsapp.ablago(alsoapp.ablago.*) from the official catalogue, from a bundle file with its signature or as a file whose checksum is listed there. At most 64 characters, ASCII only, no punycode (xn--). Ablago shows other publishers as "not verified", except from a further signed catalogue – then it binds them to that catalogue's key. Add-ons with a dot must have the same publisher as their main package; dependencies only count from the same publisher or from the project. Packages withoutherausgebercount as coming from the publisher of their catalogue: from the official oneapp.ablago, otherwise unknown – then, as before, updates only come from the same source; the first publisher stated applies from then on. Older Ablago ignore the field. - Replaced IDs (
ersetzt, dms #1084): if a package renames its ID, it names the old one(s) underersetzt(text or list, at most 5). Only an update from the same, at least equally trustworthy source and the same, known publisher moves the installation – the same entry with folder types, folders, settings, code, events and automations, only under the new ID; no second package is created. In the catalogue,ersetztis on the package. This is how the additional languages move fromtexterkennung_fratotexterkennung.fra. -
Conversion (
umbau, dms #1041): an update can convert existing folder types – for instance when Household hands over contract and insurance to the Contracts package (dms-registry #163).umbauin the manifest is a list of steps:umbau: - von: haushalt:vertrag # type whose folders move (package:key; without prefix a former own type) nach: vertrag # target type: own key or package:key of a dependency felder: { vertragspartner: von, kuendigungsfrist: kuendigungsfrist } # old → new - von: haushalt:versicherung nach: vertrag felder: { versicherer: von, versicherungsnummer: vertragsnummer, beitrag: betrag } setzen: { art: { vorgabe: versicherung } } # fixed value into empty fields register: { unterlagen: dokumente } # documents: tab old → new - von: vermietung:mietvertrag nach: vertrag felder: { mietart: art } # choice → reference by title (#1125) setzen: { kuendigungsfrist: { anzahl: 3, einheit: monate } } # period (#1125), also P3M- Take over or merge: if the target type does not exist yet, the first step to it takes over the old type with its ID – views, permission rules, AI approval, automations and direct links hang on the ID and stay. Otherwise the types are merged: the folders move into the target type with their IDs, reference fields, link tabs, tables, views and automations point to it afterwards, and the empty old type disappears (if folders are still in the bin, it stays as your own type). Calculated fields of the taken-over type (
berechnet: true, dms #1034) that the package itself brings as calculated belong to it afterwards – even if the package giving up the type calculated them before (dms #1476). A documents tab thatregistermaps to another one disappears afterwards if the package doesn't bring it and nothing is left in it (not even in the bin). - Values:
feldermaps old field identifiers to new ones; several old ones onto one new one merge (the first filled value wins). If a value does not fit the new field type, Ablago tries: text → period ("3 months"; "3 months to the end of the term" as a suggestion), text → number, amount, date or choice, number ↔ amount, anything → text. References only to folders the new field allows. Whatever does not fit, has no mapping or only roughly fits is kept in a note on the folder – nothing is lost (passwords never go into a note). Each folder gets a history entry ("Converted by package Contracts 1.0.0"). setzenwrites fixed values into empty fields of the target type – text, number, yes/no, list or{ vorgabe: … }(a preset (dms #1038), e.g. the contract type "Insurance"). Since dms #1125 also a period{ anzahl, einheit }(unittage,wochen,monate,jahre); into a field of the kind period it can also be text (P3M, "3 Monate"). A period into another field, or text that is not a period, is an error with its location (when reading, or – for target types of a dependency – in the preview).- Choice → reference (dms #1125): if
feldermaps a choice (or a text) to a reference field, Ablago looks among the reference's target types for the folder with this title – Household "Art" = "Strom" → contract type "Strom" (ignoring case, also via the option's label, i.e. "Electricity" in an English Ablago). Presets created by the same update count. If there is no folder or more than one with that title, the field stays empty and the value goes into the note; Ablago never creates folders for it. The preview lists the values without a matching folder. So bring presets for the usual values (or create them with an earlier update). - Views (dms #1125): views of the old type point to the target type afterwards. When merging, such a view then shows all folders of the target type ("Insurance policies" shows all contracts), and conditions on fields that do not come along stay and no longer match – the preview says both per view. So bring a new version in the package that owns the view (e.g. Household 2.0.0:
typen: ["vertraege:vertrag"]with a condition). Views from packages have a checksum (like presets): an update replaces a view with the version in the package as long as the administration has not changed it (see Package format, update). What the conversion changes on a view does not count as a change. - The administration's changes are recognised from the package state of the old type: fields they created or whose type they changed become questions in the preview (keep as own field, into the note, into a field of the target type). No conversion without an answer to every question.
- Permissions: when merging, the permission rules of the old type still apply to the moved folders – Ablago puts them in front of the target type's rules, for folders with the read-only field
umbau_aus(the old type). If the old type was blocked for AI services or denied to a package, that applies to the target type afterwards too. If a rule checks a field that does not come along, or if archive mode would become less strict, the preview refuses the conversion. - Limits (security): a step only touches types of the same, known publisher; the target is a type of this package or of a dependency, never
dms:. The package no longer brings the old type. A step whose old type is missing is skipped – a second update never converts anything twice. - Running it: only on its own (not in a flow with several packages), only with "Full administration", a fresh sign-in and
umbauBestaetigt; "Back up first" is preselected. Everything runs in one transaction – if something stops, nothing has changed. - Packages that hand over types get a major version (breaking change in the CHANGELOG). Older Ablago versions skip
umbau; packages using it requiredms: ">=0.243.0"(DMS_UMBAU_AB, final version set when merged). Ablago knowssetzenwith a period and choice → reference fromDMS_UMBAU_ZUORDNUNG_AB(>=0.248.0, final version set when merged) – before that, such a field stays empty and the value goes into the note; replacing unchanged views applies to every update from the same version. - Updating existing folder types (dms #1658): an update takes over changes to type properties (
titelVorlage,beschreibung,mehrzahl,erkennbarAn), to fields (label,hilfe,min,max,minLen,maxLen,erkennung,optionen,beschriftungen) and to the order of the fields in a tab – per part, as long as the administration has not changed it (checksum against the package statetypStand, as with views). Choices are added; one the package no longer lists only goes if no folder uses it. Fields the package no longer brings are dropped: without values simply, with values the values move into the folder's note in the background (“From the update of “Finances” 3.1.0:”); the value also stays on the folder, and the type's version before the update stays under Versions. Fields the administration created or changed stay. To only rename a field, use a conversion step into the same type – onlyfelder, and the package no longer brings the old field:
umbau: - von: kontoauszug nach: kontoauszug felder: { zeitraum: abrechnungszeitraum } # values move into the new field, nothing goes into the noteOlder Ablago reject such a step (“"von" and "nach" are the same folder type”) – packages using it set
dmsto the version in which dms #1658 appears. Fields without a conversion step are dropped; whether a package drops a field by mistake is checked by the registry (pakete-pruefen). - Views withfremde_typen(from Ablago 0.178.0, #656): folder types that the package doesn't bring, a view names with their key (kennung, like theschluesselof a folder type in Ablago, i.e.package:keyfor types from packages) and a name for messages. Older packages with the form<package>_<key>are assigned via the installed packages (not by splitting at the underscore). In a bundle file, a type that is found neither installed nor in the file is an error naming view and type – the bundle file is then not installed (#1084). Ablago assigns them to the type with this key when installing. If it doesn't exist, the view comes without it – if all its types are missing, it is skipped (with its subviews) and the preview says so beforehand; the rest of the package is installed. A later version of the package creates skipped views as soon as the type is there. - Fields as in the Workbench:key,label,typ(text, langtext, formatiert, zahl, betrag, datum, janein, auswahl, referenz, passwort, since dms #1035 zeitraum and prozent, since dms #1030 tabelle, since dms #1050 zusammengesetzt) and the usual properties (pflicht,eindeutig,hilfe,standard,minLen,maxLen,muster,min,max,nachkomma,waehrung,negativ,optionen,mehrfach,verweisart,frist,erkennung,wiederfinden,format,landFeld,beschriftungen). - Taking over documents (dms #937) on the folder type:ausPost: true|false("Can be created from post"; missing = on for types with a documents tab) anderkennbarAn("How to recognise it", a short sentence, at most 300 characters, e.g. "Contains invoice number, amount and payment deadline; the sender is a contract partner"; translations underbeschriftungen.<language>.erkennbarAn). On an update, Ablago only takes overausPostif the administration hasn't set it yet; since dms #1658erkennbarAnis one of the type properties (see Updating existing folder types). Older Ablago ignore the entries; "Create package" includes them. - Plural (dms #1446) on the folder type:mehrzahl: Verträge(at most 80 characters; translations underbeschriftungen.<language>.mehrzahl, e.g.en: { name: Contract, mehrzahl: Contracts }). Lists then show "12 Verträge" instead of "12 × Vertrag"; without it, "n × type" stays. On an update, Ablago takes it over as long as the administration hasn't changed the type properties (dms #1658; before, only if the folder type had none yet). Older Ablago ignore the entry (the minimum version doesn't rise); "Create package" includes it. - Labels per language (dms #728):beschriftungenmay be on the folder type, on fields, tabs and views – language → texts. The source text (name,label,hilfe,beschreibung) is German. With choice fields, the entries inoptionenare the fixed values stored in the folders; their label per language is underbeschriftungen.<language>.optionen(fixed value → text). Without a label Ablago shows the fixed value – that's why older packages with pure text options (optionen: [Strom, Gas]) work unchanged: every option is its own fixed value. For a language-neutral value,beschriftungen.de.optionengives the German text. If a package statesbeschriftungen.de.label(orname,hilfe,beschreibung), that counts as the source text. Language codes such asen,tr,pt-BR; what doesn't fit Ablago leaves out. On an update, Ablago only adds labels to existing types, fields and tabs where the administration hasn't labelled anything yet; the preview names the number. Older Ablago ignore the entry; a higherdmsisn't needed. Example:- key: art label: Art typ: auswahl optionen: [strom, gas, wasser] beschriftungen: de: { optionen: { strom: Strom, gas: Gas, wasser: Wasser } } en: { label: Kind, optionen: { strom: Electricity, gas: Gas, wasser: Water } }Conditions of views and automations as well as the values of the examples always name the fixed value (
wert: [strom]). "Create package" takes the labels along. - Formats and date limits (dms #535): withformat, text fields get a check –email,telefon,internetseite,ibanorplz. Withplz,landFeldnames the key of the field with the country (text or choice in the same folder type); if it says Germany or nothing, exactly 5 digits are required, otherwise the postcode is free. Withminandmax, date fields get limits: a date (2000-01-01) orheute, e.g.max: heutefor a birthday. Example:- { key: plz, label: PLZ, typ: text, maxLen: 10, format: plz, landFeld: land }. New and changed values must fit – also the package's examples –, stored ones stay valid. On an update, Ablago takes over format or limits on existing fields on which the administration has set neither format nor limits; the preview names them. Older Ablago ignore the entries. - Period, percentage, negative amounts (dms #1035):typ: zeitraum(number and unit) andtyp: prozent(number,min/max/nachkommaas forzahl);negativ: true, only onbetrag, allows negative amounts (missing = ≥ 0). Inbeispiele.yamla period is written as{ anzahl: 3, einheit: monate }(unitstage,wochen,monate,jahre) or short asP3M, a percentage as a number (19), a default value asP3Mor19. Example:- { key: kuendigungsfrist, label: Kündigungsfrist, typ: zeitraum, standard: P3M }. Ablago before 0.227 turned unknown field kinds into text – so the package needsdms: ">=0.227.0"; from now on Ablago rejects unknown field kinds with a message when reading the package. An update can switchnegativon for an existing amount (the preview lists it under "Format or limits"), never off. - Month precision (genauigkeit, dms #1722, from 0.336.0):genauigkeit: monatonly ontyp: datum– for dates that only exist as a month (next vehicle inspection "04/2028", expiry of a card, warranty "until March 2027"). Without the entry or withtag, everything stays as before. Ablago stores the last day of the month (2028-04-30), so deadlines, reminders, calendar, filters and sorting end at the end of the month without a special case; the API, the export andbeispiele.yamlcarry this value (YYYY-MM-DD). When writing,YYYY-MMor any day of the month works too – Ablago stores the last day. It shows as "04/2028"; you enter month and year ("04/2028", "4/2028", "04.2028", "042028"); in the calendar a day picks its month. Recognition: such fields read "April 2028", "Apr. 2028", "04/2028" and "04.2028" next to their label, aftererkennung.woerter.vor(#1714) also "042028"; a full date counts for its month. They never get the letter date. Fields precise to the day still take no bare month. Ablago rejects values other thantagandmonat, and the entry on other field kinds, when reading the package. An update sets the precision on an existing date field with the same key (preview: "Format or limits"); stored dates stay, their month is shown. Older Ablago ignore the entry and show the last day of the month as a day; "Create package" takes it over and raises the minimum version (DMS_DATUM_MONAT_AB). Example:- { key: naechste_hu, label: Next inspection, typ: datum, genauigkeit: monat, erkennung: { woerter: { vor: ["(8)", "Nächste HU"] } } }. - Table (dms #1030):typ: tabelleshows, between the fields, the folders of another type that link here through a link field – for example the items of an invoice.quelle: { typ, feld }is required:typis a type reference as forziel(own type or from a dependency, neverdms:),feldthe key of the link field there that points to this type (zielorzielOptional); optionallytrefferliste: standard(packages bring only one results list per type; the table shows its columns, never password fields) andneu(label of "+ New", at most 40 characters, e.g. "+ Position"; other languages underbeschriftungen.<language>.neu). A table has no value of its own: not inbeispiele.yaml, not intrefferlisteortitelVorlage, neverpflichtorberechnet. Example from the Invoices package:- { key: positionen, label: Positionen, typ: tabelle, quelle: { typ: rechnungsposition, feld: rechnung, trefferliste: standard, neu: "+ Position" } }. When reading, Ablago checksquelle; if it points to a type of this package, the field must exist there and link here. When installing, Ablago adds the table after its source (like links to types that are only being created); when removing, table and link go together. The package needsdms: ">=0.232.0"(older versions reject the field kind). The table never adds up totals – that is done by a package with code (calculated fields, notes). Thelabelalso appears in the note "You can see 3 of 7 Items …" (dms #1208, #1305) – so use the plural. For this the API (GET /api/v1/mappen/{id}/tabelle/{feld}) only returns the numberverborgen; a client builds the sentence itself with the field's label in its language (labelorbeschriftungen.<language>.label), never with a general "entries". - Combined (dms #1050):typ: zusammengesetztwithvorlage(required, at most 300 characters) – placeholders and filters liketitelVorlage, from fields of the same type of the kinds text, zahl, betrag, prozent, datum, zeitraum, janein, auswahl and referenz; preferably witheindeutig: truefor a combination. Example from the Compliance draft:- { key: kennung, label: Kennung, typ: zusammengesetzt, vorlage: "{bereich} · {zeitraum}", eindeutig: true }, from Invoices "invoice number per sender":vorlage: "{von} · {rechnungsnummer}". Neverpflicht, neverberechnet, nostandard; Ablago rejectsvorlageon another field kind, as well as unknown or unsuitable placeholders. The package doesn't set the identifier: Ablago calculates the value from its parts on every save (also through the API) and ignores what a package sends for it; not inbeispiele.yaml. What is stored is a key without language (dateYYYY-MM-DD, choices as their fixed value, links as folder id, never a title); on a duplicatePOST/PUT /api/v1/mappenanswers 422, with the message indetails.felderon the first field involved. Readers get the key inwerteand build the text fromvorlage, the values andbezuege. The package requiresdms: ">=0.239.0"(DMS_ZUSAMMENGESETZT_AB; older versions reject the field kind). An update that changes the template recalculates the folders; identical combinations then don't match (without asking, as when switching oneindeutig). - Show in the general search (dms #1220):inSuche: falseon the folder type for pure choice lists (e.g.vertragsartin the Contracts package) – their folders are then left out of the search in the header (advanced search without a chosen type) and are not a source for "Ask your library"; with the type chosen, in its own view and in choice and link fields they stay. Missing = yes. On the first install the entry applies, on an update only as long as the administration has not set the tick themselves. Older Ablago versions ignore it (the minimum version does not rise); "Create package" takesinSuche: falsealong. - Is part of another folder (dms #1031):gehoertZu: <field>on the folder type – the key of this type's link field through which every folder belongs to its parent (notation as in the draft of the Invoices package, theregehoertZu: rechnungon the invoice item). The field is a link with exactly one target (zielwithout a list, withoutzielOptional), withoutmehrfach, withpflicht: trueand withoutanzeigen; if it points to a type of this package, that type may not havegehoertZuitself (no chains). Such folders (parts) only appear at the parent folder – usually through a table – and through direct links, not in views, search, "+ New" and Where does this belong?; hits in them count as hits of the parent folder. Hiding is no protection: parts remain reachable through the API, the export and direct links – permissions are set by the administration. Ablago checksgehoertZuwhen reading and when installing (like the setting in the Workbench); on the first install it sets it as soon as the field exists, on an update only if the type is still independent (only the administration can switch it off). Older Ablago versions ignoregehoertZu– there the parts appear in the views. "Create package" takes the setting along and raises the minimum version (DMS_TEILE_AB). - Archive mode (dms #1051):archiv: { jahre, jahreBeruflich?, stichtag?, leererStichtag? }on the folder type, spelt as in the draft of the Compliance package (archiv: { jahre: 2, jahreBeruflich: 10, stichtag: abgeloest_am, leererStichtag: laeuftNicht }).jahreandjahreBeruflichare whole numbers from 1 to 30;jahreBeruflichapplies with the attribute "used for work" (dms #1032) and is not shorter thanjahre;stichtagnames a date field of this type (without: creation date);leererStichtagisanlage(default) orlaeuftNicht– then the period only starts once the reference date is filled in, and the folder stays locked until then; only withstichtag. It is a default for types the package newly creates: the preview when installing shows it, afterwards the administration changes it on the folder type. A package never changes existing types – neither installing nor an update sets, shortens, relaxes or switches off the archive mode of an existing type, not even a type of the same package; what the administration has set stays. Ablago checksarchivwhen reading, likepruefen.py(unknown entries, numbers, reference date,leererStichtagonly withstichtag); an error prevents the installation. Older Ablago versions ignorearchiv. "Create package" takes over the archive mode (withoutjahreBeruflich, which doesn't exist on the type) and raises the minimum version (DMS_ARCHIV_PAKET_AB). - Fill from document (erkennung, dms #336/#391; up to 0.216 "Use for recognition"):erkennung: {}marks a field that "Fill in from document" may fill; optionallyart(name,vorname,nachname,funktion,nummer,iban,ustid,email,internet,telefon,mobil,fax,strasse,hausnummer,plz,ort,datum,betrag,zeitraum,prozent,verweis,auswahl,woerter,code– matching the field kind) andhinweis(at most 300 characters, e.g. "Muster 100-####").code(dms #1723, from 0.337.0) on text and langtext: the content of a QR code or barcode that a package withdms:codeshas read on the document – never from the text. Optionally withmuster– a regular expression that must match the whole content, with the same limits as the check pattern on text fields (at most 200 characters, no nested repetitions, contents up to 1000 characters; the check rejects an unsafe pattern), e.g.erkennung: { art: code, codeart: qr, muster: 'https://www\.kba-online\.de/dub/#/zugriffsdaten/.+' }– andcodeart, a short identifier of lowercase letters and digits (e.g.qr,ean13,itf,aztec). The core has no fixed list: the names are those delivered by the package that reads codes (e.g. Barcodes); compared ignoring case and punctuation. Without both, any code matches. If several match, the one on the earlier page wins; if none matches, the field stays empty. The code is suggested with high certainty and the source "QR code on page 1", ahead of text, recognition by a package and what was learned; such a field never gets a value from the text or from an AI. Without a package withdms:codesthe field stays empty; older Ablago ignorecode. Since dms #1728 (from 0.338.0) a field withmusteralso counts for Where does this belong?: if a kept code matches it, that is a waycodeof its own with a strong vote for the folder type (“Recognised by the QR code on page 1”) – a pattern that only fits one kind of document recognises it without text.woerter(dms #1689) on a text field of a choice list (a type withausPost: falseand no fields for finding again, e.g. contract type): recognition words, comma-separated; each counts on its own as a whole word, case-insensitive, from 3 characters. If an entry (name or recognition word) appears in the document, it is weak evidence for the types that refer to the list ("Versicherungsschein" → contract, contract type insurance) and pre-fills their link field if exactly one entry matches. "Fill in from document" never fills the field itself; a field with the key or label "Erkennungswörter" gets the kind even without the setting. The choice list is never suggested as a type, and a link to it never gets "create new". Only for text, langtext, zahl, betrag, datum, auswahl, referenz, zeitraum and prozent; older Ablago ignore the entry. On an update, Ablago takes over the marking on existing fields on which the administration hasn't set anything. - Recognition words on a field (erkennung.woerter, dms #1714, from 0.335.0): one shared entry for words before the value and words per option – not to be confused with the kindwoerter(#1689) on choice lists. Ablago always sets the fixed value. Older Ablago ignore the entry. -vor: words after which the value stands on the same line ("(4)", "km-Stand", "Kd.-Nr.", "Vertragskonto"). Whole words, case-insensitive; several in a row count as one ("(4) km-Stand: 65884 km"), so does a short lead-in up to a colon ("(8) Nächste HU / Plakette: 15.10.2028"). The first place with a fitting value wins with high confidence – ahead of the letter date, the total amount, periods and numbers further up; only a recognition hint with a pattern comes first. On all field kinds of the recognition except link. Read per kind: date (DD.MM.YYYY, "15. Oktober 2028", ISO), amount, period, percentage, option of a choice field, a number for number fields, an identifier (with a digit, 3 to 40 characters) for text fields. A number or text field without a recognisable kind becomes fillable withvor(as a number). The value must fit: if a word follows the number directly, it must be the field's unit – it appears in label, key or the words ("km" in "km-Stand") or is a known abbreviation ("km" – kilometre, "h" – hour, "kWh", "kg", "l", "m³"). "(4) km-Stand: 8867 Betriebsstunden" therefore gives no mileage, nor does "(4) km-Stand: –". A month without a day ("nächste HU fällig April 2028") gives no date in a date field precise to the day; a field withgenauigkeit: monat(#1722, see below) takes it. If the words only stand before such values, the field stays empty instead of taking a similar value from elsewhere. -jeOption(onlytyp: auswahl): per fixed option further words by which it is recognised. Ablago drops options the field doesn't have (pruefen.pyrejects them). - Limits: per list at most 20 words of 3 to 60 characters (ERKENNUNGSWOERTER_MAX,ERKENNUNGSWORT_MIN,ERKENNUNGSWORT_MAX); shorter, longer and duplicate ones are dropped. Abbreviations like "GM" therefore don't count – "(7)" does. - Choice fields in general (since 0.335.0): if several options appear in the text, the earliest place wins, not the order inoptionen; at the same place the longer text. Pages follow each other in the full text, so a place on page 1 beats any later one. Places in conditional sentences ("Weist … aus", "Wurden … festgestellt, …", "Wenn", "Falls", "Sofern") don't count.- Use to find existing folders (- key: kilometerstand label: Kilometerstand typ: zahl erkennung: { woerter: { vor: ["(4)", "km-St.", "km-Stand"] } } - key: ergebnis label: Ergebnis typ: auswahl optionen: [ohne Mängel, geringe Mängel, erhebliche Mängel] erkennung: art: auswahl woerter: vor: ["(7)", Ergebnis] jeOption: ohne Mängel: [ohne festgestellte Mängel, ohne erkennbare Mängel, keine Mängel] geringe Mängel: [geringe Mängel (GM)]wiederfinden, dms #938):wiederfinden: trueon text, number and link fields – Ablago uses these values to find existing folders again in documents (customer number on the contract partner, contract number and contract partner on the contract, invoice number on the invoice, registration number on the vehicle); independent ofeindeutig. If the entry is missing, Ablago derives it as before: on for fields witherkennungwhose kind is a feature (number, IBAN, VAT id, email, internet, phone, mobile, fax, name). If you don't want that, writewiederfinden: false. On an update, Ablago sets the tick on existing fields only for an explicittrueand only where it is still missing. Older Ablago ignore the entry. - Sections in a field tab (abschnitte, dms #890): on a tab withart: felder, a list[{ vor: <field>, titel?, eingeklappt?, beschriftungen? }]. A new row starts at fieldvor(a field of this tab, at most one section per field); withtitel(at most 80 characters, translations underbeschriftungen.<language>.titel) the folder shows a heading, witheingeklappt: truethe section is closed when opening (only withtitel). Withouttitelit is just a line break. Example:abschnitte: [{ vor: geburtstag }, { vor: iban, titel: Bankverbindung, eingeklappt: true, beschriftungen: { en: { titel: Bank details } } }]. Display only – the list of fields stays. Ablago leaves out invalid entries (field missing, duplicate). On an update Ablago only adds sections to tabs that have none yet; the preview lists them. Older Ablago versions ignore the entry; “Create package” includes it. - Hiding (ausgeblendet, dms #655):ausgeblendet: trueon a field or tab (not withart: dokumente, not on tabs with system fields) – the folder doesn’t show it, values stay, a hidden field is never required. Only applies on the first installation: an update doesn’t change whether existing fields and tabs are hidden, and whatever an update brings new is visible. “Create package” includes it. Older Ablago versions ignore the entry. - Links (zielfor link fields,quellen[].typfor links tabs):schluesselfor a folder type of this package,<package>:<schluessel>for another package's folder type. The other package is then underabhaengigkeiten. A package's folder types may also link to each other in a circle. - Several target types (dms #1036):zielmay be a list –ziel: [vertrag, fahrzeuge:fahrzeug]; a single type stays a text as before. Withmehrfach: true,gleicherTyp: truekeeps all chosen folders of the same type.aus_textonly works with exactly one target type. Older Ablago versions reject a list as an invalid link; setdms:to the version that brought several target types (see what's new) so they reject it understandably. - Optional target types (zielOptional, dms #1036): types of another package this package does not depend on, as<package>:<schluessel>– for instance the invoice that also concerns a vehicle when the package Vehicles is there (Vehicles itself depends on invoices). Ablago adds each of them to the target types as soon as it exists – when installing and later, when the other package is installed; if it is missing, the field stays without it (never an error, no dependency). A link field may have onlyzielOptional(e.g. Tax year in Household); the form then says the types come with another package. Own types anddms:belong underziel. An update addszielOptionalto existing fields (never shortened); it doesn't take over new fixedzielentries on existing fields. "Create package" writes optional targets back aszielOptional. Example:- { key: betrifft, label: concerns, typ: referenz, mehrfach: true, ziel: [vertrag], zielOptional: [fahrzeuge:fahrzeug, wohnen:wohnung] }Display conditions ("refers to a folder of type …",
art: verweistypandop: zeigtAufTyp) may name a target fromzielOptionaleven if its package is missing (dms #1122): this is not an error, the condition then never applies (withnicht: truealways). If the package comes later, it applies from then on.zeigtAufTypalso works withzielOptionalwhile only one target type exists. A type that is neither underzielnor underzielOptionalof the field remains an error.The order of the folder types in the package and of the packages among each other does not matter when installing (dms #1122): links, tables, display conditions and sources of link tabs that point to something created later are added in a second pass – sources via
zielOptional(such as Vehicle → Invoices via Concerns of the invoice) only once the other package's field refers to the new type. Whatever cannot be created in the end, such as a source via a field that does not refer to this type, stops the installation naming folder type, tab and source – nothing is dropped silently. - Order of the choice (auswahlReihenfolge, dms #1671): on a link field{ feld, absteigend? }–felda field of the target type (only with exactly one target type, sortable as in the result list) or_titel,_erstellt,_geaendert. Example tax year:auswahlReihenfolge: { feld: jahr, absteigend: true }. Without it, title ascending with numbers by size applies. Older Ablago ignore it; a field the target type does not have makes the installation fail. - Copy when selected (vorbelegen, dms #1037): on a link field a list of pairs[{ von, nach }]–vona field of the target type,nacha field of this type. When a folder is chosen, Ablago suggests its values in empty fields (marked "suggested from …", editable, never overwritten; also with "Fill in from document" and "Take over document"). Example from the Contracts draft:- key: art typ: referenz ziel: vertragsart vorbelegen: - { von: kuendigungsfrist, nach: kuendigungsfrist } - { von: kuendigung_zum, nach: kuendigung_zum }When reading, Ablago checks: only on
typ: referenz; only the keysvonandnach; eachnachonce, a field of this type, not the link field itself, no password, no table, notberechnet; for target types of this packagevonexists there, is no password and fits (same field kind, text also into long text, multiple values only intomehrfachfields, for choices every option also in the target, for links every target). Target types from dependencies are checked the same way when the folder type is created; with several target types a pair applies to every type that has the field. An update brings the pairs to existing link fields on which the administration has set none (shown in the preview as "Copy when selected: …"). "Create package" takes them along. Needsdms: ">=0.234.0"– older Ablago versions skip the setting (the link works, just without suggestions). Ablago always fetches the values with the person's rights, never with a package's account, and never passes them to an AI package. - Calculated (berechnet: true, dms #1034): only this package's code writes the value – in Ablago the field is read-only ("calculated by …"), any other writer gets 400 with the package's name. Only on fields of a type the package brings; needs code withcode.rechte.schreibenon that type, never together withpflicht, never onpasswort– otherwise Ablago refuses the package when installing. An update can make an existing field calculated or release it again withberechnet: false(or without the setting); the last value stays. How the package writes (already when creating, notes, history): Calculated fields and notes. Needsdms: ">=0.231.0". Example:- Own organisation (- { key: kuendigen_bis, label: Cancel by, typ: datum, berechnet: true }merkmal: eigeneOrganisation,schreibschutz: verwaltung, dms #995): a yes/no field withmerkmal: eigeneOrganisationtells Ablago which folders are the own organisation (package Basis from 1.7.0, field "Own organisation") – at most one such field per folder type, onlytyp: janein.schreibschutz: verwaltung(on any field except password and table) means: changeable only in administration mode with the area "Own organisation" or with a role released there; any other writer gets 403 – also through the interface, packages and automations. Only the package brings both; the Workbench can neither set nor remove them. Ablago reads the details of the own organisation by the meaning of the fields, not by their key: per meaning (name, street, house number, postcode, town, email, phone; for persons first and last name) the first text field witherkennungand this kind in tab order – that is whynamecomes beforekuerzel(the short name also carriesart: name). In addition the link fields with the keysverantwortlicheranddatenschutzbeauftragter(one folder, person or organisation). Ablago reads nothing more with system rights. For display conditions there is{ art: eigeneOrganisation, feld }– a link field points to an own organisation (e.g. section "Outgoing invoice" if "From" is us). Needsdms: ">=0.238.0"(DMS_ORGANISATION_AB). Example from Basis 1.7.0:- Links to Ablago's folder types (since 0.75.0):- { key: eigene_organisation, label: Eigene Organisation, typ: janein, standard: false, merkmal: eigeneOrganisation, schreibschutz: verwaltung }dms:benutzeranddms:rolle(e.g. for "Responsible"). Allowed inziel,quellen[].typandtypenof a view. Other Ablago types (e.g. post) don't work; the iddmsis blocked for packages. A package with such links statesdms: ">=0.75.0"in the manifest; an older Ablago rejects it with an understandable message. The preview shows the types as "User (from Ablago)". - Storage location (since 0.212, issue #883): the folder type comes with the Basis package from 1.6.0 – links are writtenbasis:ablageort, and the package namesbasis: ">=1.6.0"underabhaengigkeiten(e.g. for the fieldverbleib_original"Whereabouts of original documents"). The formerdms:ablageortstill works as an alias and points to the same folder type (Basis's, or the earlier storage location of an older Library); the preview andpruefen.pygive a "deprecated" notice. The alias is dropped with Ablago 1.0. If there is no storage location, the preview rejects the package with a hint to Basis. - Views:elternis the local key of another view of the package or, (dms #1517),package:keyof a view from a package underabhaengigkeiten, e.g.eltern: "basis:fristen". If that view no longer exists at installation (deleted), the view goes to the top level, with a notice in the preview. A view withouttypenis a folder: a click shows the combined list of its sub-views and expands it; without sub-views it doesn't appear. Removing a package only removes its own views, a folder from Basis stays.oben: true(dms #1518) puts a newly created view at the start of its level, after “Neue Post” and “Favoriten”. An update never moves an existing view: parent and position stay, even ifeltern,obenor the order in the package changed, and also when replacing it with the new version. Older Ablago versions ignoreoben; forpackage:keyand folders put the minimum version from the changelog underdms:. - Take over or merge: if the target type does not exist yet, the first step to it takes over the old type with its ID – views, permission rules, AI approval, automations and direct links hang on the ID and stay. Otherwise the types are merged: the folders move into the target type with their IDs, reference fields, link tabs, tables, views and automations point to it afterwards, and the empty old type disappears (if folders are still in the bin, it stays as your own type). Calculated fields of the taken-over type (
Example “Fristen” (deadlines): Basis brings - { schluessel: fristen, name: Fristen, symbol: alarm-clock, oben: true }, Verträge hangs - { schluessel: kuendigen_bald, name: Kündigen bald, eltern: "basis:fristen", typen: [vertrag], bedingungen: [...] } below it.
bedingungen are { feld, operator, wert } with the Workbench's operators (gleich, enthaelt, kleiner, groesser, zwischen, ausserhalb, imZeitraum, einerVon, zeigtAuf, zeigtAufTyp, leer, nichtLeer, ja, nein); with zwischen and ausserhalb, wert is a list with two values. zeigtAufTyp (dms #1036) takes a list of type references (wert: [fahrzeuge:fahrzeug]) and only works on link fields with several target types; types of a package that isn't installed are dropped.
- Conditions are checked strictly (dms #1108): display conditions (anzeigen on fields and sections), conditions of views and the And cards of automations are checked against the format when Ablago reads and installs a package. If one is written wrongly – unknown art, unknown operator, invalid value, more than ten conditions in one place – Ablago rejects the package and names the type, the field or section (register.vor), the number of the condition and the reason, e.g. mappentypen[1] „vertrag“: „verlaengerung_um“: anzeigen, Condition 1: art: feld is missing in bedingung. Until now such a condition was dropped silently (the field was then always shown). A field condition in anzeigen needs art: feld twice: { art: feld, bedingung: { art: feld, feld: verlaengerung, op: einerVon, wert: { art: fest, wert: [endet] } } }; views write operator, not op. Whether the field exists in the type is still checked when the folder type is created. Input in the Workbench is not affected – its editor only produces valid conditions.
- Examples: { typ, werte }; amounts may be numbers. From Ablago 0.79.0 (#347) additionally:
- schluessel (optional, lower-case letters, digits, _; unique in the package) – so that other examples can point to this folder.
- A link field may be { beispiel: strom } (with mehrfach also a list of them), to an example of a dependency with a prefix: { beispiel: "basis:stadtwerke" }.
- Ablago creates the examples so that targets exist beforehand; the order in the file doesn't matter. Circles (A → B → A), unknown keys and prefixes that aren't under abhaengigkeiten it rejects when reading.
- If the examples are installed, those of the dependencies newly installed at the same time come along too. If a dependency is already installed without examples, links to it stay empty; the preview says so. Ablago remembers the examples' folders with keys on the installed package (beispiele).
- On an update no examples arise – as before.
- Example documents (dms #878, dms-registry #137, from 0.223.0): an example may name files under dokumente that are in the package under inhalt/beispiele/:
```yaml
- typ: vertrag
schluessel: heizung_wartung
werte: { bezeichnung: Wartungsvertrag Heizung, partner: { beispiel: heizungsbau } }
dokumente:
- { datei: beispiele/heizung/wartungsvertrag.pdf, titel: Wartungsvertrag, datum: "2023-04-01" }
- { datei: beispiele/heizung/rechnung-2026.png, register: rechnungen }
```
- `datei` (required) is relative to `inhalt/` and starts with `beispiele/`; folders and names only of letters, digits, `.`, `-` and `_`. Allowed are **PDF, PNG and JPEG** – recognised by their content, the extension must match (`.pdf`, `.png`, `.jpg`, `.jpeg`). Each file at most as large as an uploaded document (100 MB); all files under `inhalt/beispiele/` together at most `PAKET_MAX` (128 MB). They don't count towards the 20 MB limit for the other contents.
- `titel` (optional, up to 200 characters) is the document's name in Ablago; if the extension is missing, Ablago appends the file's. Without `titel` the file name applies.
- `datum` (optional, `YYYY-MM-DD`) becomes "uploaded on". Without a date the time of installation applies.
- `register` (optional) is the key of a document tab of the folder type; without it, the first one. For the package's own folder types Ablago checks this when reading, for types of other packages when creating.
- Ablago creates the documents **as if uploaded** (`DokumenteDienst.ladeHoch`, origin `paket`): preview, full text and archive version according to the Library's settings; only the worker reads PDFs, via `ladePdf()`. Folder events and automations stay quiet (`ohneEreignisse`, question 71); packages that process files (`dokument.hochgeladen`, `volltext.fertig`) get them. If a document fails, the whole package is rolled back – files included.
- The installed package has `beispielMappen`: per example the id, a checksum of the field values and the documents (`id:sha256`). An example is **unchanged** with the same field values, the same documents, no notes and no link from a folder that isn't an example. Only those are permanently deleted, files included, by "Remove examples" (`POST /api/werkbank/pakete/{id}/beispiele/entfernen`) and by removing the package; changed ones stay and are listed in the response or in the reasons.
- Older Ablago versions skip `dokumente`; packages using it require `dms: ">=0.223.0"`. Invented content only – persona names, example domains (`example.org`), invalid sample values for IBAN, tax and insurance numbers; `pruefen.py` checks paths, file types and sizes (dms-registry #137).
- Packages that use this require `dms: ">=0.79.0"` in the manifest.
-
Presets (dms #1038):
inhalt.vorgabennames a file with folders the package brings to keep – unlike examples always, without a tick, and they stay. Notation as in the Contracts package:# inhalt/vorgaben.yaml - kennung: miete # fixed, unique within the package typ: vertragsart # own type or paket:schluessel of a dependency werte: { name: Miete, kuendigungsfrist: { anzahl: 3, einheit: monate }, kuendigung_zum: Monatsende } beschriftungen: { en: { name: Rent } } vorlagen: - { datei: vorlagen/kuendigung-miete.md, titel: Kündigung Mietvertrag, register: vorlagen } # add to another package's preset: attach templates only - ergaenzt: vertraege:miete vorlagen: [{ datei: vorlagen/garage.md, titel: Stellplatz kündigen }]- Fixed key: in Ablago the preset is called
paket:<id>:<kennung>(columnvorgabeof the folder). The package ID is part of it: a package only finds its own presets again, never a folder of the administration or another package's preset – even with the same key. Key like aschluessel(lower-case letters, digits,_, up to 60 characters); once given, never rename it: a new key is a new preset. At most 200 entries. typ: an own folder type orpaket:schluesselof a package underabhaengigkeiten(Vehicles → contract type "car purchase contract" in Contracts); neverdms:. The preset gets the permissions of the target type like every folder.werte: as for examples (amounts as numbers, periods as{ anzahl, einheit }); no password fields, no links to examples. Links to presets use{ vorgabe: miete }or{ vorgabe: "vertraege:miete" }– also inbeispiele.yaml(instead of a fixed ID there).beschriftungen: language → field → text. Ablago creates the preset in the installation's language (fields without a translation stay German); values are data and don't change with the person's language.vorlagen: text templates underinhalt/vorlagen/(lower-case letters, digits,-,_, at most two folders, extension.md), each entry withdatei(required),titel(document name) andregister(documents tab; without:vorlagen, otherwise the first). At most 20 per preset. Placeholders as in automations ({vertragsnummer},{von.name}); they are filled in with "Set text" (dms #1040, see Writing text templates).- What a template may be (
server/src/pakete/vorlagen.ts, the same rules inpruefen.py): UTF-8 text without control characters, at mostVORLAGE_MAX(256 KB,server/src/grundlagen/grenzen.ts); no HTML – no comments<!-- -->either –, no images (![…]), links onlyhttps://(in[text](…),[x]: …and<https://…>;http:,mailto:,javascript:,data:appear nowhere in the text); no placeholder names a password field. Ablago checks this when reading and again when installing (then against the password fields of all folder types). ergaenzt: paket:kennung: a package may only attach templates to the preset of a package underabhaengigkeiten– Ablago rejects any other entry (werte,beschriftungen, permissions …). If the preset doesn't exist (deleted), the templates are left out; the preview says so.- Installing: without events (question 71); the creator is the package's service account (history: "Package …"). The preview (
vorgaben,ergaenzungen) shows each preset's state; presets in other packages' types and additions also appear in the box "Adds to folders of other packages". - Update: the installed package keeps per key (
vorgaben) the folder, the checksum of the values after the last write (stand) and that of the values in the package (fassung). If the folder matchesstand, it gets the new version; otherwise the administration changed it and it stays (preview: new version in the package). If the folder is missing, it was deleted and stays deleted (geloescht). An update replaces templates only while preset and document are unchanged; new ones are added. - Removing: presets in use (links, notes, other documents) stay; unused ones in own types go with the package, in other packages' types Ablago asks (
409withvorgaben, thenDELETE …?vorgaben=entfernen|behalten). Templates on other packages' presets (ergaenzungen) go with it – only those. Whatever stays keeps its key; a new installation takes it back in. - At runtime a package (service account) doesn't change or delete another package's preset and doesn't delete documents on it (403) – not even with write permission on the folder type.
- Show if … refers to the preset (dms #1033): on fields and sections,
{ art: vorgabe, feld: art, vorgabe: [miete], nicht?: true }names a particular supplied folder by its key (own orpaket:kennungof a dependency);feldis a link field. On installation Ablago turns this into "refers to" with the preset's ID; deleted ones don't count. "Create package" writes such a condition back with the key and enters the preset's package as a dependency. - Older Ablago skip
inhalt.vorgaben; packages using it requiredms: ">=0.236.0"(DMS_VORGABEN_AB). - Word lists (dms #356, from 0.127.0):
inhalt.wortlistennames a file with groups of synonyms for the search – whoever searches for one also finds the others. Every group is{ woerter: [Kfz, Auto, PKW] }with 2 to 20 different words (each 2 to 60 characters; upper/lower case and umlauts don't count in the comparison); at most 1000 groups per package. Ablago creates them on installation, replaces them with the package's on an update and removes them with the package; in the Workbench under Synonyms they can be viewed (whoever administers Ablago can copy them there as their own group). Packages with word lists requiredms: ">=0.127.0"– older Ablago silently skip the section. Example:
# inhalt/wortlisten.yaml - woerter: [Kfz, Auto, PKW, Fahrzeug] - woerter: [Nebenkosten, Betriebskosten] - Fixed key: in Ablago the preset is called
-
Automations (dms #712, dms-registry #108, from 0.177.0):
inhalt.automatisierungennames a file with ready-made automations – per entryschluessel(fixed, as for types),name, optionallybeschreibung, exactly one If cardwenn, optionallyund, at least one card indann. Cards and values as in the editor; folder types as their own key orpackage:typeof a dependency, since 0.257.0 (#1001) alsodms:postfor Ablago's post – withwenn: { art: mappe.geaendert, typ: "dms:post", felder: [an, stand], angelegt: true }and a task to{ art: feld, feld: an }you get a “Post for you” task (one per post and person, completing itself once the post is no longer new or goes to someone else; as in the Notifications package). The cardfavoritenknowsvorgabe: false; roles are not allowed there in packages. There are no fixed people – recipients are a field ({ art: feld, feld: verantwortlich, sonst: ersteller }) or the folder's creator. The Workbench cards (Whenfehler.gemeldet,protokoll.meldung,version.neu, Thensicherung, #677) and the call from outside (Whenaufruf, #679) only exist in the Workbench, as do the cards to the outside (Thenurlandemail, #671 – where data goes is decided by the administration itself) – Ablago rejects a package with them; Ablago does not read an Otherwise branch (sonst) in packages. After installation they are off; when installing, Ablago asks which should be switched on straight away. Since 0.233.0 (#1082)eingeschaltet: truemarks the ones offered ticked (can be unticked); if a package setseingeschalteton none, all are preselected as before. Without a choice when installing (API, dependencies) the ones witheingeschaltet: trueapply. No update changes on/off of an automation that is already installed. The Then card{ art: paket, aufgabe: … }(Run package on schedule) calls the package itself – see Calculating on schedule. An update only replaces unchanged automations; when the package is removed, unchanged, switched-off ones go with it. Older Ablago skip the section; packages with it requiredms: ">=0.177.0". Example:# inhalt/automatisierungen.yaml - schluessel: hu_bald name: HU wird bald fällig beschreibung: Einen Monat vor der Hauptuntersuchung bekommt der Verantwortliche eine Frist. wenn: { art: datum, typ: fahrzeug, feld: hu_faellig, vorlauf: 1, einheit: monate, uhrzeit: "07:00" } dann: - { art: aufgabe, als: aufgabe, empfaenger: [{ art: feld, feld: verantwortlich, sonst: ersteller }], text: "Für {kennzeichen} wird bald die HU fällig: {datum}." }On the date field only
fristremains ("is a deadline": appears under To do, in the calendar and triggers Date reached). Since 0.177.0 the field no longer creates tasks itself;frist.vorlauf,einheit,wiederholungandtextonly serve as defaults – a supplied automation with the same advance notice is meant to remind.Set field in linked folder (dms #1557, Then card
feld_verknuepft): sets fields of the folder a reference field of the triggering folder points to – withmehrfachin each.ueberis the reference field,werteare fields of the target type (fixed or with placeholders as withfeld; a placeholder on its own such as"{naechste_hu}"takes over the value unchanged, which requires the same field kind),nur_wennisimmer(default),leer,spaeterorfrueher(the last two for dates and numbers only). Ablago writes with the rights of the system account "Automation"; if it may not change the target folder, the folder stays unchanged and the run notes it.pakete-pruefenchecks the reference field and the target fields (field exists, kind matches, not calculated) when trigger and target are types of the package; target types of other packages are only checked on installation (the automation then shows a problem). Packages using it requiredms: ">=<version>"– the changelog names the version under #1557; older Ablago drop the unknown card (without another Then card the automation does not run there). Example (dms-registry #227):# inhalt/automatisierungen.yaml in the package fahrzeuge - schluessel: hu_ans_fahrzeug name: Nächste HU ans Fahrzeug übernehmen beschreibung: Aus dem Prüfbericht kommt „Nächste HU“ als „HU fällig“ ans Fahrzeug – nur, wenn das Datum später ist. eingeschaltet: true wenn: { art: mappe.geaendert, typ: hauptuntersuchung, felder: [naechste_hu], angelegt: true } dann: - art: feld_verknuepft ueber: fahrzeug werte: { hu_faellig: "{naechste_hu}" } nur_wenn: spaeter -
Dependencies (
abhaengigkeiten: { <package>: "<range>" }): packages that must be installed beforehand. When installing, missing dependencies come along in the same process – since Ablago 0.151.0 (#405) also those with code: the administration sees the permissions of all packages on one page and confirms them once; every package keeps its own service account and its own permissions. An update that changes the permissions needs a new confirmation as before. -
Add-ons (
ergaenzt, dms #405, from 0.151.0): a package that extends another – for instance an additional language for text recognition – says so withergaenzt. The extended package must also be underabhaengigkeiten. The installation shows add-ons as ticks below the extended package (on first installation, in the setup assistant, from a bundle file and later on the installed package), grouped bygruppe– without a group under "Add-ons". The group is a short question without a question mark (at most 40 characters); Ablago adds "?". Every add-on stays a package of its own with its own version and its own update. Older Ablago ignore the field; a package doesn't need a higherdmsfor it. Withoutergaenzta dependent package only appears as a normal package in the list.# manifest.yaml of an additional language abhaengigkeiten: texterkennung: ">=2.0.0" ergaenzt: { paket: texterkennung, gruppe: Weitere Sprachen } # or short: ergaenzt: texterkennung # Since #1084 with a dot in the ID (id: texterkennung.fra) and – when moving – the former ID: ersetzt: texterkennung_fraIn the catalogue the entry is per version (
versionen[].ergaenzt, always as{ paket, gruppe }). A collective package "all languages" without content of its own isn't needed for this. - Quick guide (kurzanleitung, dms #1047, dms-registry #164): three to five short steps "How to use it" per language, e.g.kurzanleitung: { de: [...], en: [Create a tenancy under “+ New”., Enter the end.] }. Ablago shows it once right after the installation and then on the package page under "What comes with it" – in the language of the interface, otherwise German. At most 8 steps of 300 characters each, text only (no<,>); Ablago silently skips anything invalid, older versions the whole field. No manual in the package – big topics are explained by a tour. - Versions:dmsandabhaengigkeitentake ranges:>=1.2.0,>1.2.0,1.2.0or=1.2.0,^1.2.0(same major version),~1.2.0(same minor version), optionally with an upper limit<2.0.0. With0.x,^means the same minor version:^0.63.0only fits 0.63.x. For the Ablago version therefore write>=0.63.0(or your own minimum version).
On an update, Ablago only adds: new folder types, fields, tabs and views. Removing or renaming fields or tabs has no effect on installed Ablago – so plan the format beforehand. Folder types and views that the administration has deleted are not created again by an update.
Views with a checksum (dms #1125, like presets #1038): for each view of a package, Ablago remembers how the package wrote it (name, description, parent view, folder types, conditions, results list, icon – not order, permissions on the view or labels) and the version in the package. If an update brings a new version of a view:
| View in Ablago | Update |
|---|---|
| unchanged | is replaced with the new version – same view (ID, links, permissions, position), new content; it keeps its name if that name already exists under the same parent view |
| changed by the administration | stays; the preview says so and offers "Replace with the version in the package anyway" (sichtenErsetzen with the keys) |
| installed before 0.248 (no checksum) | if it matches the new version, it gets a checksum; otherwise it stays like "changed" (with the same choice) |
| deleted | stays deleted |
If a conversion (dms #1041) changes a view, its checksum moves along – it still counts as unchanged. So a new version is worthwhile when the folder types or conditions of a view change (e.g. after a conversion); renaming a view also reaches installed Ablago this way, as long as nobody has changed it.
The texts in a package (names, labels, examples) are German as the source text; English and other languages come via beschriftungen.
Automation templates¶
A package can bring automation templates (dms #1044, from Ablago 0.256.0): runs you apply to a folder from the “Folder” menu, e.g. “Follow-up in 6 months”. In the manifest inhalt.ablaufvorlagen: inhalt/ablaufvorlagen.yaml and dms: ">=0.256.0".
- schluessel: wiedervorlage
name: Wiedervorlage
beschreibung: In sechs Monaten steht die Mappe wieder bei dir unter „Zu erledigen“.
wann: { art: in, anzahl: 6, einheit: monate } # or { art: sofort } or { art: datum }
fragen: [] # empfaenger, datum (required with art: datum; with art: in = a suggestion that can be changed, #1180), text
karten:
- { art: aufgabe, als: aufgabe, empfaenger: [{ art: selbst }], text: "Wiedervorlage: {titel}" }
- Only the
aufgabecard (task or notification,als). Any other card – email, web call, setting fields – makes the package invalid, also in an update. The permissions preview lists every template with its cards. - Recipients:
frage(the person chosen when applying, needsfragen: [empfaenger]),selbst(who applies it),ersteller(who created the folder) orfeld(reference field to users; only withtypen). There are no fixed people or roles. - Text with placeholders as in the folder title, plus
{eingabe}(answer to “Text”),{person},{empfaenger}. Ablago fills them with the recipient’s rights. typen(optional): folder types of the package orpaket:typof a dependency where the template appears in the menu; without: all.ersetzt: aufgabe_vergebenorersetzt: erinnernoverlays Ablago’s template (at most one package per template; one changed by the admin stays). Removing the package brings back Ablago’s.- On after installation; an update only replaces unchanged ones. On removal the templates go too – except those that still have planned runs (they stay as own ones).
- A run always uses the rights of the person who set it up – checked when it runs – never those of the package.
tests/erwartung.yamlgives the number:ablaufvorlagen: 3.
Describing settings¶
If your package (with code) needs settings, you describe them in the manifest under code.einstellungen – a package brings no interface of its own. Ablago shows the form, checks and stores the values (part of the backup) and gives them to the package.
code:
einstellungen:
- abschnitt: Allgemein
felder:
- { schluessel: aktiv, name: Regeln automatisch anwenden, typ: janein, standard: true }
- { schluessel: token, name: API-Schlüssel, typ: geheim, pflicht: true }
- liste: regeln
name: Regeln
eintrag: Regel
sortierbar: true
felder:
- { schluessel: absender, name: Absender enthält, typ: text }
- { schluessel: ziel, name: Mappentyp, typ: mappentyp, pflicht: true }
aktionen:
- { schluessel: anwenden, name: Regeln jetzt auf neue Post anwenden, bestaetigen: true }
- At most two levels: sections (
abschnitt,hilfe,felder) and lists (liste,name,eintrag,hilfe,sortierbar,felder). - Types:
text,mehrzeilig,zahl(min/max, optionallyschrittandvorschlaege, see below),janein,datum,auswahlandmehrfachauswahl(optionen),geheim, linksmappentyp,feld(withmappentyp:),benutzer,rolle,sicht, and since Ablago 0.124.0adresse– the service address, the only one to which the package may go on the network (withoutstandard, at most withbeispiel; see Packages with code). - Numbers with suggestions (#657): a
zahlonly accepts digits (if applicable with a comma) withinmin/max– checked in the form and on saving ("Please a number between 150 and 400.").schritt: 1only allows whole numbers. Withvorschlaege, Ablago shows a selection with labels instead of a number field; "Own value …" opens the number field. Every suggestion lies withinmin/max,standardmust be one of them. Older Ablago versions ignoreschrittandvorschlaegeand show a text field.- schluessel: dpi name: Auflösung (dpi) typ: zahl min: 150 max: 400 standard: 300 vorschlaege: - { wert: 150, name: "gering – schneller, für klare Ausdrucke" } - { wert: 300, name: "normal – empfohlen" } - { wert: 400, name: "hoch – kleine Schrift, dauert länger" } - Multiple choice for links (from Ablago 0.179.0, #658):
mehrfach: trueonmappentyp,benutzer,rolleorsichtshows the field like a link field with multiple choice (search, selection below the field, "Remove"); the value is a list of ids.schliesst_aus: <key>names a second field of the same link type in the section: what is chosen in one, Ablago doesn't offer in the other, and the server rejects the same id in both (e.g. "Only these folder types" ↔ "Exclude these folder types"). Ablago also shows a list with exactly one link field (e.g.liste: typenwitheintrag: Mappentyp) like this, without the package having to change – the list is still what is stored. If an update turns such a list into a field withmehrfach: trueunder the same key, Ablago takes over the chosen ids. - Required:
pflicht: truerequires a value – in the form and when saving. It is the opposite that is marked: fields withoutpflichtare shown with “(optional)” after the name (not forjanein– a checkbox is always on or off); required fields get no asterisk. - Values as the package gets them: section fields under their key, lists as a list of objects (with
_idper entry). Links are ids (withfeld:{ typ, feld }), secrets in plain text – only for the package itself. codealso includessprache,quelle,ereignisse,rechteandnetz(see Packages with code); the example above only shows settings and actions.code.aktionenare buttons in the package's settings (for whoever administers Ablago). Actions for the Folder ▾ menu on folders are separate, undermappenaktionen(see Actions in the “Folder” menu).- Credentials only as
geheim, never astextand never withstandard. - On an update, new fields get their default, existing values stay, dropped ones are removed.
werkzeuge/pruefen.py checks keys, defaults, options, secrets and links. Expert mode with Upload package is suitable for trying things out.
Describing settings and displays¶
The package describes, Ablago presents (#996): a package's page looks the same for every package – the Overview tab only reads, the Settings tab holds everything that can be changed. No package brings its own settings or overview page.
Checking rules per field – checked in the form and on saving with the same message:
| Entry | for | Meaning |
|---|---|---|
pflicht: true |
all except core field types | a value is required |
min, max, schritt |
zahl |
smallest and largest number, step |
laenge_min, laenge_max |
text, mehrzeilig |
length in characters (whole number from 0) |
muster, meldung |
text |
regular expression for the whole value (at most 300 characters) and the message if it does not match (at most 200 characters) |
- { schluessel: kennung, name: Customer number, typ: text, pflicht: true, laenge_max: 12, muster: "[A-Z]{2}-\\d+", meldung: "Please use the form “AB-12”." }
The package's check function: with code.einstellungen_pruefen: true, Ablago calls the package's action einstellungen_pruefen before saving – after the rules above (dms_aktion, input { "aktion": "einstellungen_pruefen", "einstellungen": {…} } with all values in plain text). It runs for at most 10 seconds and without write rights: no service account, no folder, no documents, its own storage read-only. Ablago shows the answer {"fehler": {"kennung": "The service does not know this account."}} at the field and does not save; {} or {"fehler": {}} means: fine. If the package is not running, only Ablago's checks apply.
Core field types: what only Ablago knows exists as a field type of its own. A package names it in a section (without standard, without pflicht, each at most once); Ablago keeps the value, the package does not get it among its settings.
| Type | Section in Ablago | Who gets it, even without naming it |
|---|---|---|
ki_mappentypen |
What may go to services on the network (all areas except the excluded ones; applies to all AI packages, called “packages with network access” in the interface) | AI packages (see AI packages) |
fragen_grenzen |
Ask your Library: limits per question | packages with dms:antworten |
erkennung_standard |
Fill in from document: use as default | packages with dms:erkennen |
mappenaktionen |
Actions in the “Folder” menu on or off | packages with mappenaktionen |
If a package does not name one of these field types, Ablago appends it as a section of its own after the manifest's fields. A package without fields of its own still gets the "Settings" tab that way.
code:
einstellungen:
- abschnitt: Data protection
hilfe: Excluded folder types do not go to the service.
felder:
- { schluessel: typen, name: Folder types, typ: ki_mappentypen }
Displays: code.anzeigen describes figures and states the package reports (at most 12). Ablago shows them in the overview under Reported by the package, the same for every package. The package writes the values with speicher_schreiben into its own storage under anzeige.<schluessel> – values only, no interface:
art |
Value in storage | Shown as |
|---|---|---|
zahl |
1234 |
number |
anteil |
1234/1300 |
“1,234 of 1,300” with a bar |
text |
anything (at most 200 characters) | text |
zustand |
ok, warnung or fehler, optionally : text |
chip “fine”, “Note”, “Error” with text |
code:
anzeigen:
- { schluessel: vektoren, name: Documents with vector, art: anteil }
- { schluessel: modell, name: Model, art: zustand, hilfe: Loads on first start. }
If a value is missing or does not fit the type, “not reported yet” appears. Older Ablago versions ignore code.anzeigen, code.einstellungen_pruefen and the new field entries.
What the package does with the settings and which permissions it needs is described in Packages with code.
Writing text templates¶
With Set text (dms #1040), Ablago turns a text template into a letter as a PDF – in the interface via Folder ▾ → Letter from template …, for packages and scripts via the API. How templates get into a package is described above under Presets (vorlagen on a preset or supplement); what a template may contain, likewise.
# Cancellation of contract {vertragsnummer}
Dear Sir or Madam,
I hereby cancel the contract **{bezeichnung}** at the earliest possible date, which is {kuendigen_bis}.
Customer number: {von.kundennummer}
Please confirm the cancellation in writing.
Yours faithfully
Sample without guarantee, not legal advice – have it checked by an expert if in doubt.
- Layout of the letter: Ablago sets letterhead, address, place and date – the template only contains subject and text. The first heading (
# …) becomes the subject (bold, and the PDF title); without one the PDF is named after the template. The letterhead comes from the folder in the reference fieldan(customer; person or organisation), otherwise from the own organisation (#995, only name, address, phone, email); the address from the folder in the reference fieldvon(the other party). So use the same keysvonandan. - Markdown: headings (
#,##,###), paragraphs, lists (-,1.), quotes (>), bold, italic,code. A single line break stays a line break (closing, address in the text); two or more blank lines leave space, e.g. for the signature. Links appear as text with the address in brackets – nothing in the PDF is clickable. - Placeholders as in automations:
{feld}for a field of the folder,{verweis.feld}for a field of the folder behind it (up to three levels, e.g.{von.kundennummer}), plus{heute},{titel}and{mappentyp}. Values use the format of their field type in the language of the template (date31.12.2026, amount650,00 €, period3 Monatefor German, choices with their label); references as the folder's title. There are no free formats or expressions (such as{datum:TT.MM.JJJJ}) – only the fixed list of field types. - Values are text: Ablago first parses the template and then inserts the values – in one pass. A field value such as
**bold**,[link](…)or{other_field}appears as it is. In the filled-in text (.mdnext to the PDF) such characters are escaped with\. - Gaps: If a value is missing, the person may not read it (folder or referenced folder; when downloading also without export right E) or the placeholder names a field that does not exist, the letter shows [Label], e.g. "[Contract number]". Password fields are forbidden as placeholders – checked when installing and before every typesetting.
- Language: that of the template's full text if Ablago knows it, otherwise that of the installation – never that of the interface. It is written as
/Langinto the PDF. - Limits (
server/src/grundlagen/grenzen.ts): filled-in text at most 512 KB (TEXTSATZ_TEXT_MAX), PDF at most 30 pages and 4 MB (TEXTSATZ_SEITEN,TEXTSATZ_PDF_MAX), typesetting at most 30 seconds in the worker (TEXTSATZ_ZEIT_MS). Beyond that: 413.
For packages (API): GET /api/v1/mappen/{id}/vorlagen lists a folder's templates (on the folder itself and on folders it refers to) with the state of their placeholders; POST /api/v1/mappen/{id}/vorlagen/{dokument}/setzen with { "ziel": "ablegen", "register": "dokumente" } files the PDF and the filled-in text as new documents (response: both documents and the gaps); with { "ziel": "herunterladen" } the PDF is the response. The service account needs read access to the folder, dokumente: lesen for the list, dokumente: schreiben and edit rights on the folder for setting. The PDF names package and template in its metadata (subject). Minimum version: dms: ">=0.242.0" (DMS_TEXTSATZ_AB in shared/src/textsatz.ts).
Region packages¶
Data that each country needs and that can change belongs in a region package rather than in the core (dms #1696, package “Region Deutschland”: dms-registry #244). From Ablago 0.333.0 (DMS_REGIONSPAKETE_AB in shared/src/regionspaket.ts) a package brings one file for this – purely descriptive, without code, so the package stays at the vorlagen level. Older Ablago skip inhalt.region; packages using it require dms: ">=0.333.0". Date, time and numbers stay in the core (Intl).
# manifest.yaml
inhalt:
region: inhalt/region.yaml
| Entry | Meaning |
|---|---|
land |
country according to ISO 3166-1, two capital letters (DE) – matches Workbench → Region → Country |
regionen |
list of { id, name }: id 1–3 capital letters or digits (ISO 3166-2 without the country, e.g. SN), unique; at most 60 |
feiertage |
list of rules, at most 80; on the same day the later rule wins |
feiertage[].name |
name per language, de required (en recommended), at most 80 characters each; Ablago shows the person’s language, otherwise English, otherwise German |
datum |
fixed day MM-DD (not 02-29) |
ostern |
days relative to Easter Sunday (-2 Good Friday, 50 Whit Monday), -80 to 250; the Easter formula (Gregorian) stays in the core |
vorDatum |
{ wochentag: 0–6, datum: MM-DD }: the last weekday before that day (0 = Sunday; Day of Repentance and Prayer = Wednesday before 23 November) |
regionen |
only in these regions (each listed under regionen); missing: the whole country |
ab, bis |
applies from or until this year (inclusive), 1583–9999 |
jahre |
applies only in these years (at most 30), e.g. Reformation Day 2017 nationwide |
Each rule has exactly one of datum, ostern and vorDatum; the conditions apply together. Unknown entries, wrong days, regions without an entry and lists that are too long are rejected when installing and updating – with file name, position and reason (de/en), e.g. inhalt/region.yaml: feiertage[5]: exactly one of datum, ostern and vorDatum. The file may be at most 64 KB. The same check runs in pakete-pruefen (real installer).
Excerpt of the German rules (complete: shared/regionen/de.yaml; for all 16 federal states 1990–2100 it yields exactly the same as the built-in calculator shared/src/feiertage.ts – test server/test/regionspaket.test.ts):
land: DE
regionen:
- { id: BY, name: { de: Bayern, en: Bavaria } }
- { id: SN, name: { de: Sachsen, en: Saxony } }
# … all 16 federal states
feiertage:
- { name: { de: Neujahr, en: New Year’s Day }, datum: '01-01' }
- { name: { de: Internationaler Frauentag, en: International Women’s Day }, datum: '03-08', regionen: [BE], ab: 2019 }
- { name: { de: Karfreitag, en: Good Friday }, ostern: -2 }
- { name: { de: Fronleichnam, en: Corpus Christi }, ostern: 60, regionen: [BW, BY, HE, NW, RP, SL] }
- { name: { de: Reformationstag, en: Reformation Day }, datum: '10-31', regionen: [HB, HH, NI, SH], ab: 2018 }
- { name: { de: Reformationstag, en: Reformation Day }, datum: '10-31', jahre: [2017] }
- { name: { de: Buß- und Bettag, en: Day of Repentance and Prayer }, vorDatum: { wochentag: 3, datum: '11-23' }, regionen: [SN] }
In the core: liesPaket() reads and checks the file (pruefeRegionsregeln), package management stores it on the installed package (daten.region in pakete); an update without the file removes it. shared/src/feiertagsquelle.ts is the only source of public holidays – calendar in “To do”, schedules “not on public holidays” (daily summary), preview in Workbench → Region: if there is a region package for the country of the archive that knows the chosen region, its rules apply (feiertageAusRegeln); otherwise the core calculates as before. Without a chosen region there are no public holidays. With several region packages for the same country, the first by id applies. Workbench → Region names the package the public holidays come from; the list of regions (there and in the setup assistant) comes from the package.
The chosen region stays a setting of the core (Workbench → Region, setting region, field bundesland). The package only supplies rules and regions. If it uses the same identifiers as before (DE: BW … TH), the choice is kept on installation, without a migration.
Outlook: patterns for field values (postcode, phone, IBAN, address), working days and dialling codes are not yet part of the format – they follow once the core uses them (plausibility of fields, dms #1693). Until then Ablago rejects muster as an unknown entry. The built-in holiday calculator stays until “Region Deutschland” is published and existing installations get it on update.
Checking¶
pip install pyyaml jsonschema
python3 werkzeuge/pruefen.py pakete/mein_paket # schema, required files, links, licence, changelog
python3 werkzeuge/katalog.py --probe /tmp/katalog # can the catalogue be built?
The same checks run in the pull request. A published package never changes: every change needs a higher version and an entry in CHANGELOG.md.
Checking packages with Ablago¶
pruefen.py checks the format; whether Ablago really installs a package only the installer can tell. It comes as the command pakete-pruefen in the image of every Ablago version: it reads the package folders (like liesPaket on upload), packs them like the registry and installs them with the real installer of this version into an empty library in memory – no database server, no network, no account.
docker run --rm -v "$PWD/pakete:/pakete:ro" ghcr.io/motom001/dms:<version> pakete-pruefen /pakete/basis /pakete/vertraege
docker run --rm -v "$PWD/pakete:/pakete:ro" ghcr.io/motom001/dms:<version> pakete-pruefen /pakete # all packages
- Order: the folders can be given in any order; Ablago installs the dependencies first. A folder without
manifest.yamlbut with package folders inside (e.g.pakete/) stands for all of them – inside the container no shell expands a*. - Update old → new: if the same id appears in several versions, Ablago installs the oldest and then updates version by version; a package with
ersetztcounts as the update of the replaced id (move). The same version twice with the same content counts once; with different content it is an error (increase the version). - Output:
OKorFEHLER(ERRORwith--sprache en) per package with the reasons – the same texts the preview in Ablago shows – and below them the notes of the preview (they do not fail anything). Exit code 0 if everything is fine, 1 if at least one package fails, 2 for wrong usage. - Options:
--ablago <version>checksdmsin the manifest against another version,--ohne-beispieleleaves out the examples (otherwise Ablago installs them, like the tick box in the interface),--jsonor--ergebnis <file>give the result as JSON,--sprache engives all output in English.
What the command does not check: the origin (the packages sit in a catalogue in memory that counts as the official one – signature and confirmations do not apply), the code (code/modul.wasm is stored but not run; without a built module there is only a note) and rules only PostgreSQL knows. The library in memory is the same as in Ablago's server tests; there the installations of this command also run against PostgreSQL for comparison.
In the CI of dms-registry – packages against a fixed Ablago version, in a pull request also the update from the state on main (unchanged packages count once):
- name: Check packages with Ablago
run: |
git worktree add -q "$RUNNER_TEMP/main" origin/main
docker run --rm -v "$RUNNER_TEMP/main/pakete:/alt:ro" -v "$PWD/pakete:/neu:ro" \
ghcr.io/motom001/dms:<version> pakete-pruefen /alt /neu
Without Docker, in Ablago's repository: npm ci && npm run build, then node server/dist/pakete-pruefen.js <folder…> (or during development node --import tsx server/src/pakete-pruefen.ts <folder…>). Ablago itself checks all packages from dms-registry main against its own state this way in every pull request (job katalog-pakete, warnings only) – so that a stricter check in the core does not silently break catalogue packages.
Pull request and catalogue¶
- Pull request with
Closes #…; every commit carries aSigned-off-by:(git commit -s). - After the merge, CI builds an archive
<id>-<version>.zipper package version and the cataloguekatalog.jsonwith SHA-256, signs the catalogue (katalog.sig, see below) and puts everything on the branchgh-pages. Ablago finds the package on the next Fetch catalogue.
Signed catalogue¶
From Ablago 0.141.0, Ablago checks where a catalogue comes from (#594, registry: motom001/dms-registry#74). The checksum per archive only proves that a package didn't break on the way; the signature over katalog.json proves that the whole catalogue – and with it every checksum in it – comes from the Ablago project.
- Method: Ed25519 over the exact bytes of
katalog.json. Ablago checks withcrypto.verifyfrom Node, without a further dependency (server/src/pakete/katalogsignatur.ts). -
katalog.sigis next tokatalog.json, separately, so that older Ablago versions read the catalogue unchanged:{ "format": 1, "verfahren": "ed25519", "schluessel": "6d868387314e64df", "signatur": "<64 bytes, Base64>", "erstellt": "2026-11-02T10:00:00Z" } -
Identifier and fingerprint of a key: SHA-256 over the 32 bytes of the public key, hexadecimal. The identifier is the first 16 characters, the fingerprint all 64 in groups of four.
werkzeuge/signieren.py fingerabdruck <file.pub>in the registry calculates the same way. - Two project keys: signing key (secret in the registry's CI) and reserve key (offline with the maintainer). Both public keys are fixed in Ablago; a signature with either of them is valid.
erstellt: Ablago remembers per catalogue the newest validly signed state (settingpaket_katalog_staende, part of the backup) and rejects an older one online – that way no old catalogue with a package version that has since been fixed can be slipped in. A bundle file (without internet) only shows "state of …" and warns from 90 days.- Only validly signed is official (#1351): if the official catalogue's signature is missing (404/410), can't be fetched (
nichtgeprueft) or is invalid, it counts like an outside source: the origin must be confirmed, the log records it, and packages from it never get the publisherapp.ablago. Ablago rejects states older than the last validly signed one even then; only a validly signed state is remembered.pakete-pruefensigns its in-memory catalogue with a key just for that run. - Redirects: when fetching catalogue, signature, key and archives, Ablago only follows redirects to
https://addresses (at most five).
Replacing the project keys¶
The public keys are in one place: server/src/pakete/projektschluessel.ts. There are the maintainer's real keys (signier.pub and reserve.pub from motom001/dms-registry#74, test: false); their fingerprints are in SECURITY.md. Ablago 0.141.0 to 0.144.1 still had test keys in this place.
| Key | Identifier | Fingerprint |
|---|---|---|
| Signing key | 6d868387314e64df |
6d86 8387 314e 64df 715c a3bd 9856 58d5 f888 c0ea 7cab ac91 a43f 9b99 6052 e728 |
| Reserve key | 4543c81b5ccf522d |
4543 c81b 5ccf 522d f5a3 5e76 6660 8774 5f6c ae42 4722 3b6d 91c9 63cc 34b0 3954 |
The fingerprint is SHA-256 over the 32 bytes of the key, not over the whole DER file (the 44 bytes that openssl pkey -pubin -outform der outputs). Whoever runs sha256sum over the DER file gets a different value.
Tests never sign with the built-in keys. They pass their own test keys: TEST_PROJEKT from server/test/katalogschluessel.ts as the option projektSchluessel to the Paketverwaltung or to projektSchluessel(TEST_PROJEKT). Only code sets this option; in operation there is no environment variable and no setting for it – otherwise an outside key could be smuggled in as "Ablago project". With test keys the preview shows "still checks with test keys" (test: true). The test "Projektschlüssel" checks that the built-in keys aren't test keys, that their fingerprints are exactly like this in SECURITY.md and SECURITY.en.md and that a catalogue signed with test keys counts as invalid in operation.
This is how the keys are replaced (new pair, e.g. after losing the signing key):
- The maintainer creates the key pair on their own computer (instructions in the registry's README, section "Katalog signieren") and publishes the public key.
- Replace the PEM text in
server/src/pakete/projektschluessel.ts(teststaysfalse). - Calculate the fingerprints (
python3 werkzeuge/signieren.py fingerabdruck signier.pubin the registry) and enter them inSECURITY.md,SECURITY.en.md, in the test "Projektschlüssel" and in the table above; in the registry put the public key underschluessel/and enter the fingerprints inREADME.mdandREADME.en.md.
If the signing key fails (lost or compromised), the registry continues to sign with the reserve key; Ablago accepts that without an update. Afterwards a new pair (new reserve key) comes with an Ablago release.
Your own catalogue with your own key¶
Whoever runs a catalogue themselves (see below, "Testing your own package") can sign it too. Ablago handles the key like SSH on first contact:
-
Create the key pair – on your computer, not on the web server:
openssl genpkey -algorithm ed25519 -out katalog.pem openssl pkey -in katalog.pem -pubout -out katalog.schluessel -
Sign after every build of the catalogue, with the registry's tool:
python3 werkzeuge/katalog.py <folder> python3 werkzeuge/signieren.py signieren <folder> --schluessel katalog.pem --oeffentlich katalog.schluesselIt writes
<folder>/katalog.sigand checks it straight away with the public key. 3. Publish:katalog.json,katalog.sigandkatalog.schluesselare in the same folder on an HTTPS server.katalog.pemstays with you. 4. Name the fingerprint:python3 werkzeuge/signieren.py fingerabdruck katalog.schluessel– put it on your website. Whoever adds your catalogue in Ablago sees the fingerprint and is meant to compare it with this. Ablago only takes over the key after this confirmation.
Afterwards Ablago requires a valid signature for this catalogue: if it is missing or doesn't fit, it doesn't accept the catalogue (and records this in the log). In return nobody has to confirm the origin when installing any more. Here too: an erstellt older than last seen is rejected.
Changing the key:
-
Orderly: sign the new public key with the previous one and put the signature next to it as
katalog.schluessel.sig(format likekatalog.sig):openssl genpkey -algorithm ed25519 -out neu.pem openssl pkey -in neu.pem -pubout -out neu.schluessel python3 werkzeuge/signieren.py signieren-datei neu.schluessel --schluessel katalog.pem --ziel katalog.schluessel.sig mv neu.schluessel katalog.schluessel # then sign the catalogue with neu.pemAblago takes over the new key without asking, shows a notice and records the change in the log. Leave
katalog.schluessel.sigthere for a while (about half a year): an Ablago that only fetches the catalogue again later still needs the proof. - Without the old key (lost): Ablago locks the catalogue with a clear warning until an admin confirms the new fingerprint. Let your users know and name the new fingerprint on your website.
A catalogue without katalog.schluessel stays as before: it works, but every installation from it requires confirming the origin.
Testing your own package¶
Before your package goes into the catalogue, you try it out in your own Ablago – best in a test DMS (e.g. with load test data):
- Expand Workbench → Packages → ▸ Expert mode.
- Zip the package folder, e.g.
cd pakete/mein_paket && zip -r ../../mein_paket.zip ., and choose it under Upload package. A folder beforemanifest.yaml(e.g.mein_paket/manifest.yaml) doesn't matter. Ablago checks the package like a catalogue package and shows the preview; format errors are collected there.- Limits: at most 128 MB as a ZIP (the same limit in the catalogue, when uploading, in the bundle file and when creating a package; the registry's
pruefen.pyandkatalog.pyreject larger packages), unpacked at most 20 MB withoutcode/(128 MB also apply tocode/) and 500 files. An uploaded package stays ready for installation for 30 minutes; afterwards upload it again.
- Limits: at most 128 MB as a ZIP (the same limit in the catalogue, when uploading, in the bundle file and when creating a package; the registry's
- Install (confirm the origin), look at it, change it. For an update, raise the version and upload again – Ablago updates as with an update from the catalogue (only adding). To start afresh, remove the package (works as long as there are no folders of its folder types).
Whether Ablago installs your package – also as an update and together with its dependencies – you can check faster without your own Ablago using pakete-pruefen.
You can also test several packages as your own catalogue: python3 werkzeuge/katalog.py <folder> builds katalog.json and the archives; put the folder on an HTTPS server and enter the address of katalog.json in expert mode under Further sources.
Outlook¶
- Tours and tips from packages (#831, #832): Ablago reads
inhalt.rundgaengeandinhalt.tipps– see tours and tips from packages; the check in the registry comes with dms-registry #132. - Packages with code have existed since 0.88.0: WebAssembly modules that react to events and work via the API with confirmed permissions – see Packages with code, with the overview of the core's interfaces (vectors, answers, recognition, text recognition, converting files, supplying full text).