Copy/Paste Nodes allows to copy and paste nodes in all node editors as JSON text. Some of the possible usecases are:
Two new keyboard shortcuts are added in all Node Editors: CTRL+ALT+C and CTRL+ALT+V (CMD on macos). These will copy/paste nodes as text to the system clipboard instead of the internal clipboard used by CTRL+C/CTRL+V.
NOTE: The structure of the generated JSON is NOT finalized, this should be considered in an alpha state. I hope to gather feedback on the exact fields that are necessary for the serialization to be useful.
The code tries to keep the generated JSON short, only keeping fields that are not default. This results in almost human-readable output, but it is very easy to trigger exceptions if this output is edited by hand. Quite a bit more error checking should be done in future versions.
The stored structure and property names are mostly mirroring the internal structure of the node trees. One exception is that default_value and location_absolute have been renamed to _val and _loc. They occur in almost every node, and the long names make the output much more verbose and the actual useful information less readable.
This extension requests the following permission:
Copy and paste nodes to the clipboard
What a great add-on! It not only makes building node trees much more convenient, but when combined with an LLM, it also greatly reduces the effort required to create them. Thanks to this add-on, I no longer need to build my own custom workflow for using GPT to construct node trees.