Context menu paste

When I paste using context menu a node into a group, it should get group details along with it. So, in the context menu paste, I want to know the group details so that I can modify the properties.
//Code
$(go.TextBlock, “Paste”),
{
click(e: go.InputEvent, obj: go.GraphObject) {
var group = obj.part[“adornedPart”];
console.log(group);
const isGroup = group instanceof go.Group;
console.log(isGroup);
if (!isGroup) {
obj.diagram.currentTool.doCancel();
} else {
var groupId = group[“data”].groupId;

      //Want to know the clipboard items

        const part = obj.part;
        console.log(part);
        if (part !== null && part.diagram !== null) {
          part.diagram.commandHandler.pasteSelection(
            part.diagram.lastInput.documentPoint
          );
        }
      }
    }

Implement a https://gojs.net/latest/intro/events.html#ClipboardPasted DiagramEvent listener to modify the copied Nodes and Links.