1. Packages
  2. Oracle Cloud Infrastructure
  3. API Docs
  4. LicenseManager
  5. getProductLicenseConsumers
Oracle Cloud Infrastructure v2.28.0 published on Thursday, Mar 27, 2025 by Pulumi

oci.LicenseManager.getProductLicenseConsumers

Explore with Pulumi AI

Oracle Cloud Infrastructure v2.28.0 published on Thursday, Mar 27, 2025 by Pulumi

This data source provides the list of Product License Consumers in Oracle Cloud Infrastructure License Manager service.

Retrieves the product license consumers for a particular product license ID.

Example Usage

import * as pulumi from "@pulumi/pulumi";
import * as oci from "@pulumi/oci";

const testProductLicenseConsumers = oci.LicenseManager.getProductLicenseConsumers({
    compartmentId: compartmentId,
    productLicenseId: testProductLicense.id,
    isCompartmentIdInSubtree: productLicenseConsumerIsCompartmentIdInSubtree,
});
Copy
import pulumi
import pulumi_oci as oci

test_product_license_consumers = oci.LicenseManager.get_product_license_consumers(compartment_id=compartment_id,
    product_license_id=test_product_license["id"],
    is_compartment_id_in_subtree=product_license_consumer_is_compartment_id_in_subtree)
Copy
package main

import (
	"github.com/pulumi/pulumi-oci/sdk/v2/go/oci/licensemanager"
	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)

func main() {
	pulumi.Run(func(ctx *pulumi.Context) error {
		_, err := licensemanager.GetProductLicenseConsumers(ctx, &licensemanager.GetProductLicenseConsumersArgs{
			CompartmentId:            compartmentId,
			ProductLicenseId:         testProductLicense.Id,
			IsCompartmentIdInSubtree: pulumi.BoolRef(productLicenseConsumerIsCompartmentIdInSubtree),
		}, nil)
		if err != nil {
			return err
		}
		return nil
	})
}
Copy
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Oci = Pulumi.Oci;

return await Deployment.RunAsync(() => 
{
    var testProductLicenseConsumers = Oci.LicenseManager.GetProductLicenseConsumers.Invoke(new()
    {
        CompartmentId = compartmentId,
        ProductLicenseId = testProductLicense.Id,
        IsCompartmentIdInSubtree = productLicenseConsumerIsCompartmentIdInSubtree,
    });

});
Copy
package generated_program;

import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.oci.LicenseManager.LicenseManagerFunctions;
import com.pulumi.oci.LicenseManager.inputs.GetProductLicenseConsumersArgs;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;

public class App {
    public static void main(String[] args) {
        Pulumi.run(App::stack);
    }

    public static void stack(Context ctx) {
        final var testProductLicenseConsumers = LicenseManagerFunctions.getProductLicenseConsumers(GetProductLicenseConsumersArgs.builder()
            .compartmentId(compartmentId)
            .productLicenseId(testProductLicense.id())
            .isCompartmentIdInSubtree(productLicenseConsumerIsCompartmentIdInSubtree)
            .build());

    }
}
Copy
variables:
  testProductLicenseConsumers:
    fn::invoke:
      function: oci:LicenseManager:getProductLicenseConsumers
      arguments:
        compartmentId: ${compartmentId}
        productLicenseId: ${testProductLicense.id}
        isCompartmentIdInSubtree: ${productLicenseConsumerIsCompartmentIdInSubtree}
Copy

Using getProductLicenseConsumers

Two invocation forms are available. The direct form accepts plain arguments and either blocks until the result value is available, or returns a Promise-wrapped result. The output form accepts Input-wrapped arguments and returns an Output-wrapped result.

function getProductLicenseConsumers(args: GetProductLicenseConsumersArgs, opts?: InvokeOptions): Promise<GetProductLicenseConsumersResult>
function getProductLicenseConsumersOutput(args: GetProductLicenseConsumersOutputArgs, opts?: InvokeOptions): Output<GetProductLicenseConsumersResult>
Copy
def get_product_license_consumers(compartment_id: Optional[str] = None,
                                  is_compartment_id_in_subtree: Optional[bool] = None,
                                  product_license_id: Optional[str] = None,
                                  opts: Optional[InvokeOptions] = None) -> GetProductLicenseConsumersResult
def get_product_license_consumers_output(compartment_id: Optional[pulumi.Input[str]] = None,
                                  is_compartment_id_in_subtree: Optional[pulumi.Input[bool]] = None,
                                  product_license_id: Optional[pulumi.Input[str]] = None,
                                  opts: Optional[InvokeOptions] = None) -> Output[GetProductLicenseConsumersResult]
Copy
func GetProductLicenseConsumers(ctx *Context, args *GetProductLicenseConsumersArgs, opts ...InvokeOption) (*GetProductLicenseConsumersResult, error)
func GetProductLicenseConsumersOutput(ctx *Context, args *GetProductLicenseConsumersOutputArgs, opts ...InvokeOption) GetProductLicenseConsumersResultOutput
Copy

> Note: This function is named GetProductLicenseConsumers in the Go SDK.

public static class GetProductLicenseConsumers 
{
    public static Task<GetProductLicenseConsumersResult> InvokeAsync(GetProductLicenseConsumersArgs args, InvokeOptions? opts = null)
    public static Output<GetProductLicenseConsumersResult> Invoke(GetProductLicenseConsumersInvokeArgs args, InvokeOptions? opts = null)
}
Copy
public static CompletableFuture<GetProductLicenseConsumersResult> getProductLicenseConsumers(GetProductLicenseConsumersArgs args, InvokeOptions options)
public static Output<GetProductLicenseConsumersResult> getProductLicenseConsumers(GetProductLicenseConsumersArgs args, InvokeOptions options)
Copy
fn::invoke:
  function: oci:LicenseManager/getProductLicenseConsumers:getProductLicenseConsumers
  arguments:
    # arguments dictionary
Copy

The following arguments are supported:

CompartmentId This property is required. string
The compartment OCID used for the license record, product license, and configuration.
ProductLicenseId This property is required. string
Unique product license identifier.
IsCompartmentIdInSubtree bool
Indicates if the given compartment is the root compartment.
CompartmentId This property is required. string
The compartment OCID used for the license record, product license, and configuration.
ProductLicenseId This property is required. string
Unique product license identifier.
IsCompartmentIdInSubtree bool
Indicates if the given compartment is the root compartment.
compartmentId This property is required. String
The compartment OCID used for the license record, product license, and configuration.
productLicenseId This property is required. String
Unique product license identifier.
isCompartmentIdInSubtree Boolean
Indicates if the given compartment is the root compartment.
compartmentId This property is required. string
The compartment OCID used for the license record, product license, and configuration.
productLicenseId This property is required. string
Unique product license identifier.
isCompartmentIdInSubtree boolean
Indicates if the given compartment is the root compartment.
compartment_id This property is required. str
The compartment OCID used for the license record, product license, and configuration.
product_license_id This property is required. str
Unique product license identifier.
is_compartment_id_in_subtree bool
Indicates if the given compartment is the root compartment.
compartmentId This property is required. String
The compartment OCID used for the license record, product license, and configuration.
productLicenseId This property is required. String
Unique product license identifier.
isCompartmentIdInSubtree Boolean
Indicates if the given compartment is the root compartment.

getProductLicenseConsumers Result

The following output properties are available:

CompartmentId string
Id string
The provider-assigned unique ID for this managed resource.
Items List<GetProductLicenseConsumersItem>
Collection of product license consumers.
ProductLicenseId string
IsCompartmentIdInSubtree bool
CompartmentId string
Id string
The provider-assigned unique ID for this managed resource.
Items []GetProductLicenseConsumersItem
Collection of product license consumers.
ProductLicenseId string
IsCompartmentIdInSubtree bool
compartmentId String
id String
The provider-assigned unique ID for this managed resource.
items List<GetProductLicenseConsumersItem>
Collection of product license consumers.
productLicenseId String
isCompartmentIdInSubtree Boolean
compartmentId string
id string
The provider-assigned unique ID for this managed resource.
items GetProductLicenseConsumersItem[]
Collection of product license consumers.
productLicenseId string
isCompartmentIdInSubtree boolean
compartment_id str
id str
The provider-assigned unique ID for this managed resource.
items Sequence[licensemanager.GetProductLicenseConsumersItem]
Collection of product license consumers.
product_license_id str
is_compartment_id_in_subtree bool
compartmentId String
id String
The provider-assigned unique ID for this managed resource.
items List<Property Map>
Collection of product license consumers.
productLicenseId String
isCompartmentIdInSubtree Boolean

Supporting Types

GetProductLicenseConsumersItem

AreAllOptionsAvailable This property is required. bool
Specifies if all options are available.
IsBaseLicenseAvailable This property is required. bool
Specifies if the base license is available.
LicenseUnitType This property is required. string
The product license unit.
LicenseUnitsConsumed This property is required. double
Number of license units consumed by the resource.
MissingProducts This property is required. List<GetProductLicenseConsumersItemMissingProduct>
Collection of missing product licenses.
ProductName This property is required. string
The resource product name.
ResourceCompartmentId This property is required. string
The OCID of the compartment that contains the resource.
ResourceCompartmentName This property is required. string
The display name of the compartment that contains the resource.
ResourceId This property is required. string
The OCID of the resource.
ResourceName This property is required. string
The display name of the resource.
ResourceUnitCount This property is required. double
Number of units of the resource
ResourceUnitType This property is required. string
The unit type for the resource.
AreAllOptionsAvailable This property is required. bool
Specifies if all options are available.
IsBaseLicenseAvailable This property is required. bool
Specifies if the base license is available.
LicenseUnitType This property is required. string
The product license unit.
LicenseUnitsConsumed This property is required. float64
Number of license units consumed by the resource.
MissingProducts This property is required. []GetProductLicenseConsumersItemMissingProduct
Collection of missing product licenses.
ProductName This property is required. string
The resource product name.
ResourceCompartmentId This property is required. string
The OCID of the compartment that contains the resource.
ResourceCompartmentName This property is required. string
The display name of the compartment that contains the resource.
ResourceId This property is required. string
The OCID of the resource.
ResourceName This property is required. string
The display name of the resource.
ResourceUnitCount This property is required. float64
Number of units of the resource
ResourceUnitType This property is required. string
The unit type for the resource.
areAllOptionsAvailable This property is required. Boolean
Specifies if all options are available.
isBaseLicenseAvailable This property is required. Boolean
Specifies if the base license is available.
licenseUnitType This property is required. String
The product license unit.
licenseUnitsConsumed This property is required. Double
Number of license units consumed by the resource.
missingProducts This property is required. List<GetProductLicenseConsumersItemMissingProduct>
Collection of missing product licenses.
productName This property is required. String
The resource product name.
resourceCompartmentId This property is required. String
The OCID of the compartment that contains the resource.
resourceCompartmentName This property is required. String
The display name of the compartment that contains the resource.
resourceId This property is required. String
The OCID of the resource.
resourceName This property is required. String
The display name of the resource.
resourceUnitCount This property is required. Double
Number of units of the resource
resourceUnitType This property is required. String
The unit type for the resource.
areAllOptionsAvailable This property is required. boolean
Specifies if all options are available.
isBaseLicenseAvailable This property is required. boolean
Specifies if the base license is available.
licenseUnitType This property is required. string
The product license unit.
licenseUnitsConsumed This property is required. number
Number of license units consumed by the resource.
missingProducts This property is required. GetProductLicenseConsumersItemMissingProduct[]
Collection of missing product licenses.
productName This property is required. string
The resource product name.
resourceCompartmentId This property is required. string
The OCID of the compartment that contains the resource.
resourceCompartmentName This property is required. string
The display name of the compartment that contains the resource.
resourceId This property is required. string
The OCID of the resource.
resourceName This property is required. string
The display name of the resource.
resourceUnitCount This property is required. number
Number of units of the resource
resourceUnitType This property is required. string
The unit type for the resource.
are_all_options_available This property is required. bool
Specifies if all options are available.
is_base_license_available This property is required. bool
Specifies if the base license is available.
license_unit_type This property is required. str
The product license unit.
license_units_consumed This property is required. float
Number of license units consumed by the resource.
missing_products This property is required. Sequence[licensemanager.GetProductLicenseConsumersItemMissingProduct]
Collection of missing product licenses.
product_name This property is required. str
The resource product name.
resource_compartment_id This property is required. str
The OCID of the compartment that contains the resource.
resource_compartment_name This property is required. str
The display name of the compartment that contains the resource.
resource_id This property is required. str
The OCID of the resource.
resource_name This property is required. str
The display name of the resource.
resource_unit_count This property is required. float
Number of units of the resource
resource_unit_type This property is required. str
The unit type for the resource.
areAllOptionsAvailable This property is required. Boolean
Specifies if all options are available.
isBaseLicenseAvailable This property is required. Boolean
Specifies if the base license is available.
licenseUnitType This property is required. String
The product license unit.
licenseUnitsConsumed This property is required. Number
Number of license units consumed by the resource.
missingProducts This property is required. List<Property Map>
Collection of missing product licenses.
productName This property is required. String
The resource product name.
resourceCompartmentId This property is required. String
The OCID of the compartment that contains the resource.
resourceCompartmentName This property is required. String
The display name of the compartment that contains the resource.
resourceId This property is required. String
The OCID of the resource.
resourceName This property is required. String
The display name of the resource.
resourceUnitCount This property is required. Number
Number of units of the resource
resourceUnitType This property is required. String
The unit type for the resource.

GetProductLicenseConsumersItemMissingProduct

Category This property is required. string
Product category base or option.
Count This property is required. double
Units required for the missing product.
Name This property is required. string
Name of the product.
Category This property is required. string
Product category base or option.
Count This property is required. float64
Units required for the missing product.
Name This property is required. string
Name of the product.
category This property is required. String
Product category base or option.
count This property is required. Double
Units required for the missing product.
name This property is required. String
Name of the product.
category This property is required. string
Product category base or option.
count This property is required. number
Units required for the missing product.
name This property is required. string
Name of the product.
category This property is required. str
Product category base or option.
count This property is required. float
Units required for the missing product.
name This property is required. str
Name of the product.
category This property is required. String
Product category base or option.
count This property is required. Number
Units required for the missing product.
name This property is required. String
Name of the product.

Package Details

Repository
oci pulumi/pulumi-oci
License
Apache-2.0
Notes
This Pulumi package is based on the oci Terraform Provider.
Oracle Cloud Infrastructure v2.28.0 published on Thursday, Mar 27, 2025 by Pulumi