VMware Cloud Community
Kaustubhambulka
Enthusiast
Enthusiast
Jump to solution

List blueprint with template it is using.

Hello Team,

I need help in creating the list/report of the blueprint and its "clone from" field as shown in below image.

pastedImage_1.png

Any script using Powershell or REST api to get this field will be helpful.

0 Kudos
1 Solution

Accepted Solutions
eoinbyrne
Expert
Expert
Jump to solution

You can get the detail of the composite blueprint from this API

/composition-service/api/blueprintdocuments

vRealize Automation Composition Service API - VMware API Explorer - VMware {code}

pastedImage_1.png

View solution in original post

3 Replies
eoinbyrne
Expert
Expert
Jump to solution

You can get the detail of the composite blueprint from this API

/composition-service/api/blueprintdocuments

vRealize Automation Composition Service API - VMware API Explorer - VMware {code}

pastedImage_1.png

Kaustubhambulka
Enthusiast
Enthusiast
Jump to solution

Thanks @eoinbyrne for quick reply.

Any was I can get it for all blueprints ?

I am using powershell and the required data is in

$blueprint.components.***.data.source_machine.fixed.label

*** is changing for all the blueprints.

0 Kudos
eoinbyrne
Expert
Expert
Jump to solution

You'll need to iterate over the response data one way or another I think

However, there is a static member object in each blueprint document called "layout" which contains the names of the components within the "components" member

pastedImage_0.png

You could use that to get the component name for the machine. Or, alternatively just walk the components list and when the "type" attribute is "Infrastructure.CatalogItem.Machine.Virtual.vSphere" you know if there can be a "source_machine" entry on that object