Edit: For anyone who is also wondering about this, the quickest solution I’ve found is to update the deployment via deployment API after onboarding.
To easily get the icon ID either:
1) First, manually change the icon of a deployment by uploading or use a previously uploaded icon. The icon ID can then be viewed in the deployment request history.
2) Get the icon ID from the deployment API GET response of a deployment you know has the icon you’d like to use. (There’s probably multiple items and APIs you could get the icon ID from like this)
______________________________________
Hi I'm wondering how to change the icon in a vRO workflow after importing using the onboarding APIs.
I successfully onboard a machine and set the deployment name. It seems the best way to accomplish via APIs would be to use the update deployment API, PATCH /deployment/api/deployments/{deploymentId}. I see in the model of this API, there is
"iconId": "string",
which seems to be where I should specify an icon ID.
To me the next logical step would be to utilize the POST /icon/api/icons API to upload an icon and then hopefully get the icon ID from the successful 201 response, since GET /icon/api/icons/{id} requires knowledge of the icon ID.
My questions:
1) How do I use POST /icon/api/icons using the VraGenericRestClient (vRA REST Plugin) when it seems the content type needs to be "multipart/form-data" and the vRA REST plugin needs stringified JSON? How do I specify the icon in the request payload? (API explorer details below)
2) How do I get icons using the GET icons API without already knowing or being able to access the icon ID? I've used icons as vRO resources but thinking I can't use those in this situation?
3) If my thinking/methods are off, what is the most straight forward way to set the icon of a deployment within a vRO workflow (not a curl command on the appliance)
Thanks!
Hello
Did you find a solution? I am especially interested in uploading an icon (POST /icon/api/icons).