To add VMware marketplace in VCD 10.5 multisite and share it to tenants, please follow the steps below:
1. Please check the following to add VMware Marketplace using API through Postman:
Reference : https://developer.vmware.com/apis/vmware-cloud-director/v38.1/cloudapi/1.0.0/catalogContentSources/post/
POST https://<VCD IP or FQDN>/cloudapi/1.0.0/catalogContentSources
Headers:
Accept: application/json;version=39.0.0-alpha
Content-Type: application/json;version=39.0.0-alpha
Authorization: Bearer XXXXX
Body:
{
"url": "https://gtw.marketplace.cloud.vmware.com/api/v1",
"description": "",
"sourceType": "VmwareMarketplace",
"orgId": "urn:vcloud:org:a93c9db9-####-####-####-########5f9",
"owner": {
"name": "system",
"id": "urn:vcloud:user:07e746aa-####-####-####-########c6a"
},
"name": "<Name of VMware Marketplace>",
"lastSynced": null,
"apiToken": "<Generated token from https://console.cloud.vmware.com/csp/gateway/discovery>"
}
NOTE: Add the name and the API token. Please refer to the documentation on how to generate an API token.
Take note of the VMware MarketPlace ID from the above response. i.e. urn:vcloud:catalogContentSource:xxxxxxxx
2. To share the new VMware Marketplace created using API through Postman:
Reference : https://developer.vmware.com/apis/vmware-cloud-director/v38.1/cloudapi/1.0.0/catalogContentSources/catalogContentSourceId/accessControls/put/
PUT https://<VCD IP or FQDN>/cloudapi/1.0.0/catalogContentSources/urn:vcloud:catalogContentSource:<VMware MarketPlace ID from the above POST call>/accessControls
Headers:
Accept: application/json;version=39.0.0-alpha
Content-Type: application/json;version=39.0.0-alpha
Authorization: Bearer XXXXX
Body:
{
"resultTotal": 1,
"pageCount": 1,
"page": 1,
"pageSize": 25,
"associations": null,
"values": [
{
"id": "urn:vcloud:accessControl:8f3f6906-####-####-####-########98d",
"tenant": {
"name": "<name of Org>",
"id": "urn:vcloud:org:<id of org>"
},
"grantType": "MembershipAccessControlGrant",
"objectId": "urn:vcloud:catalogContentSource:<VMware MarketPlace ID from the above POST call>:<VMware MarketPlace ID from the above POST call>",
"accessLevelId": "urn:vcloud:accessLevel:ReadOnly",
"memberId": "urn:vcloud:org:<id of org>"
}
]
}
NOTE:The ID of the Organization can be taken from the VCD URL, i.e. https://<VCD IP or FQDN>/provider/cloud/organizations/urn:vcloud:org:xxxxxxxx/configure/general