Skip to content

Enums

Period

Bases: StrEnum

Time period for periodic notes.

Used with client.periodic to access daily, weekly, monthly, quarterly, or yearly notes.

DAILY = 'daily' class-attribute instance-attribute

Daily note.

WEEKLY = 'weekly' class-attribute instance-attribute

Weekly note.

MONTHLY = 'monthly' class-attribute instance-attribute

Monthly note.

QUARTERLY = 'quarterly' class-attribute instance-attribute

Quarterly note.

YEARLY = 'yearly' class-attribute instance-attribute

Yearly note.

PatchOperation

Bases: StrEnum

Operation type for PATCH requests.

Determines how content is inserted relative to the target.

APPEND = 'append' class-attribute instance-attribute

Insert content after the target.

PREPEND = 'prepend' class-attribute instance-attribute

Insert content before the target.

REPLACE = 'replace' class-attribute instance-attribute

Replace the target content entirely.

TargetType

Bases: StrEnum

Target type for PATCH requests.

Specifies which part of a note the patch operation targets.

HEADING = 'heading' class-attribute instance-attribute

Target a heading section (e.g. ## My Heading).

BLOCK = 'block' class-attribute instance-attribute

Target a block reference (e.g. ^block-id).

FRONTMATTER = 'frontmatter' class-attribute instance-attribute

Target a frontmatter field.

ContentType

Bases: StrEnum

Content types (MIME types) used by the Obsidian REST API.

Controls the format of request and response bodies.

MARKDOWN = 'text/markdown' class-attribute instance-attribute

Plain Markdown text.

NOTE_JSON = 'application/vnd.olrapi.note+json' class-attribute instance-attribute

Structured JSON with content, frontmatter, tags, and stats.

DOCUMENT_MAP = 'application/vnd.olrapi.document-map+json' class-attribute instance-attribute

JSON listing headings, blocks, and frontmatter fields.

DATAVIEW_DQL = 'application/vnd.olrapi.dataview.dql+txt' class-attribute instance-attribute

Dataview Query Language query string.

JSONLOGIC = 'application/vnd.olrapi.jsonlogic+json' class-attribute instance-attribute

JsonLogic query object.