You can find how to do this in the documentation:
http://wiki.blender.org/index.php/User:Phonybone/Python_Nodes
If you want to use nodes to create objects and grids in the procedure with it, I recommend that you use and / or fork and improve this project:
http://wiki.blender.org/index.php/Extensions:2.6/Py/Scripts/Nodes/Sverchok
(These guys also use the associated API)
If you have special blender questions, for example, I also recommend that you ask about this on this special blender exchange website:
https://blender.stackexchange.com/
EDIT:
As far as I know, in any user interface libraries there is no ready-made node-editor widget or anything similar. However, it is quite simple to implement the basic rectangles, input and output ports, and bezier strings to connect them. After the first steps, it is only a matter of preference, how many hours do you invest in design and smaller details.
I implemented my own in Python with the tkinter built-in library:

And then later in Pyglet , and then, to improve speed, I implemented it in pure C with OpenGL wrapped in Cython for use in Python

Peter Varo
source share