License management for both VMware vSphere Foundation (VVF) and VMware Cloud Foundation (VCF) 9.0 is now handled by VCF Operations, which supports keyless entitlement in both Connected and Disconnected modes.

While Connected mode in VCF Operations offers the simplest user experience for licensing, many customers may opt for the Disconnected mode for a number of reasons.
The two high level workflows for the Disconnected mode in VCF Operations consists of the following:
Initial Registration - Download the registration file from VCF Operations and upload that into the VCF Business Service Console (VCFBSC) and exchange that for a license file which will be imported into VCF Operations, completing the initial setup.

Usage Reporting - Every 180 days (or sooner), you will need to generate a usage file from VCF Operations and upload that into VCFBSC and and exchange that for an updated license file which will be imported into VCF Operations.

While the license usage reporting workflow is very straight forward, it is still a manual task that an administrator must add to their their set of tasks. For customers that plan to have more than one VCF Fleet, any manual processes will become an operational challenge.
Luckily, this is where we can turn to automation to help us scale! The solution below applies to both VCF and VVF deployments.
To demonstrate the various VCF Operations License APIs that can be used for the workflows above, I have created the following example shell scripts that uses cURL to perform API invocation:
- download_vcf_operations_registration_file.sh - Download registration file from VCF Operations
- import_vcf_operations_license_file.sh - Import license file into VCF Operations
- download_vcf_operations_usage_file.sh - Download usage file from VCF Operations
Note: VCF Operations currently has a limited set of licensing APIs that are available, the license registration and usage APIs are currently internal, which the scripts are using. In a future update, all license management functionality will have public APIs.
Automating the Initial Registration workflow:
Here is an example of running the download_vcf_operations_registration_file.sh script which will require the FQDN and credentials to your VCF Operations instance (see the variables at the top of the script) and will then save registration file locally on your filesystem:

Here is an example of running the import_vcf_operations_license_file.sh script once you have exchanged the initial registration file for a license file from VCFBSC and will require the FQDN and credentials to your VCF Operations instance (see the variables at the top of the script) along with the license file provided as a command-line argument:
Automating the Usage Reporting workflow:
Here is an example of running the download_vcf_operations_usage_file.sh script which will require the FQDN and credentials to your VCF Operations instance (see the variables at the top of the script) and will then save usage file locally on your filesystem:

Once you have exchanged the usage report file for a license file from VCFBSC, you will use the same import_vcf_operations_license_file.sh script to import the new license file back into VCF Operations:
Automating VCF Business Service Console workflow:
The VCFBSC has public REST APIs, which will enable you to also automate the tasks involving the VCFBSC. As an employee, we do not have access to the VCFBCS, so I will not be able to demonstrate the specific APIs that you will need, but they should be the following based on the API documentation:


Thanks for the comment!