what is your plan? Do you want to create completely new diagrams or do you want to update existing diagrams according to e.g. your programmatically triggered model changes? If the latter is true and you want to update simple layouted diagrams like class diagrams, consider to install a canonial edit policy for the edit parts.
The question is quite interesting. I actually have both the needs.
Thus I need to know what API to exploit when I need to create a completely new set of diagrams (i.e. an just generated model from a QVT-O transformation), and, how to install a "canonical edit policy" for the parts to edit in case of diagram update.
I guess the canonial edit policy should works per default because it comes with gmf. this means if you e.g. create a new class programmatically a graphical node should be created accordingly (BTW: are you planning to use a QVTo transformation to update the UML model?)
Since I've never used the diagram generation component, I cannot tell you how to use it programmatically. I think you should take a look into the projects in [branches/0.9.X/]extraplugins/diagramtemplate/* of the papyrus svn. I think these are the projects which are responsible for diagram generation.