Question

How do I launch a blueprint with a project reference?

  • 20 June 2022
  • 1 reply
  • 150 views

Userlevel 2
Badge +2

Hi all!

I’m guessing I’m missing something obvious here, but I can’t figure it out so I’m hoping that the community can give me a helping hand. :)

I want to launch a blueprint using the /blueprints/{uuid}/launch API call as the “simple launch” call doesn’t do what I want. I want to automatically associate the new application with a project and as far as I can tell I have to use the “normal launch” for that.

I grabbed the exact payload that Prism Central/Calm sends and have spent half a day trying to clean it up so that I can re-use it, but this is where I get nowhere. If I remove too much, I get an error directly from the API but most of the time I can submit the request without errors.

Compounding the issue is that there is nothing showing in the Tasks-indicator in Prism Central, not even an error or a warning, after I sent in the call - there is simply no trace at all of the task I just created.

If I check the pending launch details with the /blueprints/{uuid}/pending_launches/{launched_uuid} call, I get mixed results. If I really screw up the payload, I get an error but most of the time it either reports state as “running” or blank.

If I grab the number of pending launches, I get:

{
  "entities": [],
  "metadata": {
    "total_matches": 7,
    "kind": "blueprint"
  }
}

In other words, there is something that should be happening, but I have no clue as to why it’s not happening.

What is the minimum required content in the payload for me to be able to launch a blueprint, associated with a project, and with custom values for both VM capacity as well as other runtime editable variables?

Or if that is too precise to list, what do I need to change in the payload that I captured for it to work? I see references to cloned blueprints ("name": "Windows Server 2019 fb47926d") but I can’t figure out if this is a name generated by Prism Central or if it’s read from the backend.

If it’s generated, what else in the payload is generated and what is a reference to an existing item?

It wouldn’t have been so tedious to dig through all this if there’d been proper documentation for the “internal” API calls that Prism Central and Calm uses but now I have to capture network traffic and analyze it separately to figure out what’s what. :/

Any feedback in the matter would be extremely helpful.

Thanks!


1 reply

I hope you’ve found an answer to this in the year since you posted, but I’m in the same boat right now, and found these links that seem to work:

 

Reply