定制 lumetas/trilium-notes 二次开发

按需修改功能、优化性能、对接业务系统,提供一站式技术支持

邮箱:yvsm@zunyunkeji.com | QQ:316430983 | 微信:yvsm316

lumetas/trilium-notes

最新稳定版本:v0.0.1

Composer 安装命令:

composer require lumetas/trilium-notes

包简介

README 文档

README

Languages

Introduction

PHP client for Trilium Notes ETAPI. Allows programmatic management of notes, branches, attributes and attachments.

Installation

Install via composer:

composer require lumetas/trilium-notes

Quick Start

<?php
require 'vendor/autoload.php';

use Lumetas\TriliumNotes\Trilium;

$trilium = new Trilium('http://localhost:37740/etapi', 'your-auth-token');

// Create a note
$note = $trilium->createNote(
    'root',
    'New Note',
    'text',
    'Note content'
);

// Get content
echo $note->getContent();

Core Classes

Trilium

Main API client class. Takes endpoint and auth token.

Key methods:

  • getNoteById() - get note by ID
  • createNote() - create new note
  • searchNotes() - search notes
  • createAttribute() - create attribute

Note

Class for working with notes.

Key methods:

  • getContent() / writeContent() - content management
  • getAttributes() - get attributes
  • createLabel() / createRelation() - create label/relation
  • export() / import() - export/import

Branch

Class for working with branches (note relationships).

Attribute

Class for working with attributes (labels and relations).

Attachment

Class for working with attachments.

Examples

Create Note with Label

$noteWithBranch = $trilium->createNote(
    'root',
    'Note with label',
    'text',
    'Content'
);

$note = $noteWithBranch->getNote();
$note->createLabel('important', 'high');

Search Notes

$notes = $trilium->searchNotes('search query', [
    'ancestorNoteId' => 'root',
    'limit' => 10
]);

foreach ($notes as $note) {
    echo $note->getTitle();
}

Links

统计信息

  • 总下载量: 1
  • 月度下载量: 0
  • 日度下载量: 0
  • 收藏数: 0
  • 点击次数: 1
  • 依赖项目数: 0
  • 推荐数: 0

GitHub 信息

  • Stars: 0
  • Watchers: 0
  • Forks: 0
  • 开发语言: PHP

其他信息

  • 授权协议: Unknown
  • 更新时间: 2025-07-27

承接程序开发

PHP开发

VUE

Vue开发

前端开发

小程序开发

公众号开发

系统定制

数据库设计

云部署

网站建设

安全加固