npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

n8n-nodes-opencode-sdk

v0.1.0

Published

n8n node per interagire con il SDK di OpenCode AI

Readme

n8n-nodes-opencode-sdk

n8n-node badge npm version license

Nodo ufficiale per n8n che permette di interagire con OpenCode AI — un potente AI coding agent — tramite il suo SDK ufficiale (@opencode-ai/sdk).


Requisiti

  • n8n v1.0+
  • Un server OpenCode in esecuzione (locale o remoto)
  • (Opzionale) Una API Key configurata in opencode.json

Installazione

Da npm

npm install n8n-nodes-opencode-sdk

Da Settings di n8n

  1. Vai su Settings > Community Nodes
  2. Clicca Install
  3. Inserisci n8n-nodes-opencode-sdk
  4. Riavvia n8n

Configurazione

Credenziali

Crea una nuova credenziale di tipo OpenCode SDK API con:

| Campo | Descrizione | |-------|-------------| | Server URL | URL del server OpenCode (default: http://localhost:17424) | | API Key | Chiave API dal tuo opencode.json (opzionale) | | Directory | Path del progetto sul server (opzionale, sovrascrivibile per-operazione) |

Nota: Molte operazioni supportano un campo Directory che sovrascrive quello impostato nelle credenziali, permettendoti di operare su progetti diversi nello stesso workflow.

Risorse e Operazioni

Il nodo espone 16 risorse per un totale di oltre 70 operazioni:

Session

| Operazione | Descrizione | |------------|-------------| | Create | Crea una nuova sessione AI | | Get | Recupera una sessione per ID | | Get Many | Elenca tutte le sessioni | | Update | Aggiorna proprietà della sessione | | Delete | Elimina una sessione | | Send Prompt | Invia un prompt e attendi risposta | | Send Prompt Async | Invia un prompt senza attendere | | Get Messages | Recupera i messaggi di una sessione | | Get Message | Recupera un singolo messaggio | | Get Children | Elenca le sessioni figlie | | Get Todo | Ottiene i todo della sessione | | Get Diff | Ottiene il diff della sessione | | Init | Analizza il progetto e crea AGENTS.md | | Fork | Crea un fork a un messaggio specifico | | Abort | Interrompe una sessione in esecuzione | | Share | Crea un link di condivisione | | Unshare | Rimuove il link di condivisione | | Summarize | Riassume la sessione | | Execute Command | Esegue un comando nella sessione | | Run Shell | Esegue un comando shell | | Revert | Annulla un messaggio | | Unrevert | Ripristina messaggi annullati | | Delete Message | Elimina un messaggio |

File

| Operazione | Descrizione | |------------|-------------| | List | Elenca file e directory | | Read | Legge il contenuto di un file | | Status | Mostra lo stato git dei file |

VCS (Version Control)

| Operazione | Descrizione | |------------|-------------| | Get Info | Informazioni sul repository (branch, default branch) | | Status | File modificati | | Diff | Diff git o branch | | Apply Patch | Applica una patch |

Project

| Operazione | Descrizione | |------------|-------------| | List All | Elenca tutti i progetti | | Get Current | Progetto corrente | | Init Git | Inizializza un repository git | | Update | Aggiorna impostazioni progetto | | Directories | Elenca le directory del progetto |

Find

| Operazione | Descrizione | |------------|-------------| | Find Text | Cerca testo nei file (ripgrep) | | Find Files | Cerca file per nome | | Find Symbols | Cerca simboli LSP |

Server

| Operazione | Descrizione | |------------|-------------| | Health | Verifica stato del server | | Get Config | Legge la configurazione | | Update Config | Aggiorna la configurazione | | List Agents | Elenca gli agenti disponibili | | List Providers | Elenca i provider AI | | Dispose | Distrugge l'istanza corrente | | Upgrade | Aggiorna la versione di OpenCode |

Tool

| Operazione | Descrizione | |------------|-------------| | List | Elenca strumenti con schema JSON | | List IDs | Elenca tutti gli ID strumento |

Worktree

| Operazione | Descrizione | |------------|-------------| | List | Elenca i worktree git | | Create | Crea un worktree | | Remove | Rimuove un worktree | | Reset | Resetta un worktree |

MCP (Model Context Protocol)

| Operazione | Descrizione | |------------|-------------| | Status | Stato dei server MCP | | Add | Aggiunge un server MCP | | Connect | Connette un server MCP | | Disconnect | Disconnette un server MCP |

PTY (Terminale)

| Operazione | Descrizione | |------------|-------------| | List | Elenca sessioni PTY | | Create | Crea una sessione PTY | | Get | Info sessione PTY | | Update | Aggiorna sessione PTY (dimensioni, titolo) | | Remove | Rimuove sessione PTY |

Question

| Operazione | Descrizione | |------------|-------------| | List | Elenca domande in sospeso | | Reply | Risponde a una domanda | | Reject | Respinge una domanda |

Permission

| Operazione | Descrizione | |------------|-------------| | List | Elenca richieste di permesso | | Reply | Risponde (allow/deny) |

Provider

| Operazione | Descrizione | |------------|-------------| | List | Elenca i provider configurati | | Get Auth Methods | Metodi di autenticazione disponibili |

Sync

| Operazione | Descrizione | |------------|-------------| | Start | Avvia la sincronizzazione workspace | | Replay | Riproduce eventi di sync | | Steal | Sposta una sessione nel workspace |

App

| Operazione | Descrizione | |------------|-------------| | Log | Scrive un messaggio nei log del server | | List Agents | Elenca agenti disponibili | | List Skills | Elenca skill disponibili |

System

| Operazione | Descrizione | |------------|-------------| | Dispose Instance | Distrugge l'istanza corrente | | Get Path | Percorsi correnti (home, state, config) | | List Commands | Comandi disponibili | | LSP Status | Stato del server LSP | | Formatter Status | Stato del formatter |

Esempi d'uso

Inviare un prompt a una sessione

Resource: Session
Operation: Send Prompt
Session ID: <id-sessione>
Prompt Text: Refattorizza questo codice usando i pattern più moderni

Creare una sessione e inviare un prompt

Resource: Session
Operation: Create
Title: Refactoring
Agent: build
Model: claude-sonnet-4-20250514
↓ (usa l'ID output come Session ID)
Resource: Session
Operation: Send Prompt
Prompt Text: Migliora la struttura del progetto

Ottenere il diff git del progetto corrente

Resource: VCS
Operation: Diff
Mode: git

Cercare file nel progetto

Resource: Find
Operation: Find Files
Query: *test*
File Type Filter: ts

Sviluppo

# Clona il repository
git clone https://github.com/marcostoduto/n8n-nodes-opencode-sdk.git
cd n8n-nodes-opencode-sdk

# Installa dipendenze
npm install

# Compila
npm run build

# Collega localmente per test in n8n
npm link

# In n8n (nella directory di installazione di n8n):
npm link n8n-nodes-opencode-sdk

Build

npm run build

Il comando compila TypeScript in dist/ e copia gli asset statici (icona SVG, metadata Codex).

Pubblicazione

npm publish

Il package name deve iniziare con n8n-nodes- e la keyword n8n-community-node-package deve essere presente in package.json.

Licenza

MIT - see LICENSE

Supporto