Hello everyone,
I’m trying to install and use the Directus Community Node for n8n following the official documentation (https://directus.io/docs/guides/integrations/n8n), but I keep encountering the same error and I’m stuck.
Issue:
When I attempt to install the Directus node, I receive the following error:
Error loading package "@directus/n8n-nodes-directus":
The specified package could not be loaded
Cause: Class could not be found. Please check if the class is named correctly.
Has anyone encountered this exact error?
Is there a specific configuration, naming requirement, or workaround needed to get the Directus node to load in n8n?
Any guidance or suggestions would be greatly appreciated.
Thank you
Hi there, sorry for the confusion. We will be updating the docs as soon as possible. Those steps are for unverified nodes and ours is now approved by n8n so you can use and install the node by simply searching for it.
Hi Lindsey,
Thank you for your reply. Unfortunately, the Directus nodes are unavailable to me. I am using the latest self-hosted version of n8n.
I am now able to see the Directus node; however, I still cannot install it.
Hm that is odd, I’m looking into this and will get back to you as soon as I figure out what’s going on with it. Can you send me what Node version if you’re using node and try these steps:
In the same boat here… On N8N 1.123.19:
Error loading package “@directus/n8n-nodes-directus” :The specified package could not be loaded Cause: Class could not be found. Please check if the class is named correctly.
The “not vetted for installation” error is misleading, the @directus/n8n-nodes-directus package is officially verified by n8n. The issue is that you’re likely trying to install it through Settings → Community Nodes using the npm package name.
Here’s the fix:
-
If you installed anything, uninstall it first through Settings → Community Nodes
-
Click the + button in your workflow editor to open the node palette
-
Search for “Directus” (just the word, not the package name)
-
Install the verified node - it should show a verification badge/shield icon
The verification system only works when you install through the node palette search, not when you manually enter the package name in Settings. Once installed this way, you shouldn’t see either error.
The “Class could not be found” error you saw initially was caused by stale files - the fix typically being clearing ~/.n8n/nodes. Now just make sure to reinstall via the node palette and you should be good to go!
Let me know if you’re still seeing issues after trying this.