trilium_alchemy

TriliumAlchemy: an SDK and CLI toolkit for Trilium Notes.

Class index

Imported

Session

core

Interface to Trilium and context in which to store changes to entities.

Note

core.note

Encapsulates a note. Can be subclassed for custom attribute accessors.

BaseAttribute

core.attribute

Encapsulates an attribute, a key-value record attached to a note.

Label

core.attribute

Encapsulates a label.

Relation

core.attribute

Encapsulates a relation.

Branch

core.branch

Encapsulates a branch, a parent-child association between notes.

BaseDeclarativeNote

core.declarative.base

Note to use as subclass for declarative notes, i.e. note classes which automatically sync with the corresponding note if it already exists in Trilium.

BaseDeclarativeMixin

core.declarative.base

Reusable collection of attributes and children which can be inherited by a BaseDeclarativeNote.

BaseEntity

core.entity

Base class for Trilium entities.

State

core.entity

Entity state. Maintained automatically based on the user’s updates and object’s current state in Trilium.

CodeNote

lib.note_types

Defines a code note.

CssNote

lib.note_types

Defines a CSS note.

HtmlNote

lib.note_types

Defines a HTML note.

JsBackendNote

lib.note_types

Defines a backend script.

JsFrontendNote

lib.note_types

Defines a frontend script.

TextNote

lib.note_types

Defines a text note.

BaseTemplateNote

lib.extension_types

Defines a template.

BaseWorkspaceTemplateNote

lib.extension_types

Defines a workspace template.

BaseAppCssNote

lib.extension_types

Defines a CSS note with label #appCss.

BaseThemeNote

lib.extension_types

Defines a theme.

BaseWidgetNote

lib.extension_types

Defines a widget.

BaseFrontendScriptNote

lib.extension_types

Defines a frontend script.

BaseBackendScriptNote

lib.extension_types

Defines a backend script.

BaseWorkspaceNote

lib.system_types

Defines a workspace root.

BaseSystemNote

lib.system_types

Base class for a “system” note, a collection of various types of infrastructure notes.

BaseRootSystemNote

lib.system_types

Base class for a root “system” note, additionally containing themes.

BaseRootNote

lib.system_types

Base class for a hierarchy root note.

Function index

Imported

label

core.declarative.decorators

Adds a Label to a BaseDeclarativeNote or BaseDeclarativeMixin subclass.

relation

core.declarative.decorators

Adds a Relation to a BaseDeclarativeNote or BaseDeclarativeMixin subclass.

label_def

core.declarative.decorators

Adds a Label definition (promoted label) to a BaseDeclarativeNote or BaseDeclarativeMixin subclass.

relation_def

core.declarative.decorators

Adds a Relation definition (promoted relation) to a BaseDeclarativeNote or BaseDeclarativeMixin subclass.

children

core.declarative.decorators

Add BaseDeclarativeNote subclasses as children, implicitly creating a Branch. May use a tuple of (child_cls, prefix) to additionally set branch prefix.

child

core.declarative.decorators

Instantiate provided class and add as child, creating a Branch and setting provided kwargs.

Exception index

Imported

ReadOnlyError

core.exceptions

Raised when user attempts to write a field which is read-only.

ValidationError

core.exceptions

Raised upon flush when changes in unit of work are invalid or incompatible.