# n8n-nodes-fleeting-notes (Unofficial)

This is an unofficial community node for n8n that manages fleeting notes through the Fleeting Notes API. It is not affiliated with or officially supported by FleetingNotes or n8n. This node allows you to create, read, update, and delete fleeting notes from n8n workflows, which can then be synced to your Obsidian vault through Fleeting Notes.

[n8n](https://n8n.io/) is a [fair-code licensed](https://docs.n8n.io/reference/license/) workflow automation platform.

[Installation](#installation)  
[Operations](#operations)  
[Credentials](#credentials)  
[Resources](#resources)  
[Usage Examples](#usage-examples)  
[License](#license)  

## Installation

Follow these steps to install this node in your n8n instance:

### Using n8n Community Nodes

1. Open your n8n instance
2. Go to **Settings > Community Nodes**
3. Click on **Install**
4. Enter `n8n-nodes-fleeting-notes` in the input field
5. Click on **Install**

### Manual Installation

You can also manually install this node:

1. Clone the repository:
```bash
git clone https://github.com/anpigon/n8n-nodes-fleeting-notes
```

2. Install dependencies:
```bash
cd n8n-nodes-fleeting-notes
pnpm install
```

3. Build the node:
```bash
pnpm build
```

4. Link to your n8n installation:
```bash
pnpm run test-local
```

## Operations

This node provides the following operations:

### Note

* **Create** - Create a new fleeting note via Fleeting Notes API
* **Get** - Retrieve a specific note by ID
* **Get Many** - Retrieve multiple notes
* **Update** - Update an existing note's content, title, or metadata
* **Delete** - Delete a fleeting note

## Credentials

To use this node, you need to set up the Fleeting Notes API credentials:

1. **Email** - The email address for your Fleeting Notes account (required)
2. **Password** - The password for your Fleeting Notes account (required)
3. **Encryption Key** - Optional encryption key for encrypted notes

## Resources

* [Obsidian](https://obsidian.md/) - The knowledge base that works on local Markdown files
* [Fleeting Notes](https://fleetingnotes.app/) - Quick capture tool that can sync with Obsidian

## Usage Examples

Here are examples of how to use each operation:

### Create a New Note

To create a new fleeting note:

1. Add the **Fleeting Notes (Obsidian)** node to your workflow
2. Select **Note** as the Resource
3. Select **Create** as the Operation
4. Configure the following fields:
   - **Title**: The title of your note
   - **Content**: The content of your note in Markdown format

Example output:
```json
{
  "id": "550e8400-e29b-41d4-a716-446655440000",
  "title": "My New Idea",
  "content": "This is the content of my fleeting note...",
  "created_at": "2023-12-01T10:30:00.000Z",
  "modified_at": "2023-12-01T10:30:00.000Z",
  "deleted": false,
  "encrypted": false
}
```

### Get a Note

To retrieve a specific note:

1. Add the **Fleeting Notes (Obsidian)** node to your workflow
2. Select **Note** as the Resource
3. Select **Get** as the Operation
4. Set the **Note ID** to the ID of the note you want to retrieve (e.g., `550e8400-e29b-41d4-a716-446655440000`)

Example output:
```json
{
  "id": "550e8400-e29b-41d4-a716-446655440000",
  "title": "My New Idea",
  "content": "This is the content of my fleeting note...",
  "created_at": "2023-12-01T10:30:00.000Z",
  "modified_at": "2023-12-01T10:30:00.000Z",
  "deleted": false,
  "encrypted": false
}
```

### Get Many Notes

To retrieve multiple notes:

1. Add the **Fleeting Notes (Obsidian)** node to your workflow
2. Select **Note** as the Resource
3. Select **Get Many** as the Operation
4. Configure the following:
   - **Return All**: Toggle to return all notes or a limited number
   - **Limit**: If not returning all, specify the maximum number to return

Example output (returns multiple note objects):
```json
{
  "id": "550e8400-e29b-41d4-a716-446655440000",
  "title": "My New Idea",
  "content": "This is the content of my fleeting note...",
  "created_at": "2023-12-01T10:30:00.000Z",
  "modified_at": "2023-12-01T10:30:00.000Z",
  "deleted": false,
  "encrypted": false
}
```

### Update a Note

To update an existing note:

1. Add the **Fleeting Notes (Obsidian)** node to your workflow
2. Select **Note** as the Resource
3. Select **Update** as the Operation
4. Set the **Note ID** to the ID of the note to update
5. Configure the **Update Fields**:
   - **Title**: New title for the note
   - **Content**: New content for the note

Example output:
```json
{
  "id": "550e8400-e29b-41d4-a716-446655440000",
  "title": "Updated Note Title",
  "content": "Updated content of my fleeting note...",
  "created_at": "2023-12-01T10:30:00.000Z",
  "modified_at": "2023-12-01T11:45:00.000Z",
  "deleted": false,
  "encrypted": false
}
```

### Delete a Note

To delete a note:

1. Add the **Fleeting Notes (Obsidian)** node to your workflow
2. Select **Note** as the Resource
3. Select **Delete** as the Operation
4. Set the **Note ID** to the ID of the note to delete

Example output:
```json
{
  "success": true,
  "id": "550e8400-e29b-41d4-a716-446655440000"
}
```

## License

This project is licensed under the [MIT License](LICENSE).
