1. Packages
  2. Oracle Cloud Infrastructure
  3. API Docs
  4. FleetAppsManagement
  5. getInventoryRecords
Oracle Cloud Infrastructure v3.3.0 published on Thursday, Jul 17, 2025 by Pulumi

oci.FleetAppsManagement.getInventoryRecords

Explore with Pulumi AI

oci logo
Oracle Cloud Infrastructure v3.3.0 published on Thursday, Jul 17, 2025 by Pulumi

    This data source provides the list of Inventory Records in Oracle Cloud Infrastructure Fleet Apps Management service.

    Gets a list of inventoryDetails.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as oci from "@pulumi/oci";
    
    const testInventoryRecords = oci.FleetAppsManagement.getInventoryRecords({
        compartmentId: compartmentId,
        compartmentIdInSubtree: inventoryRecordCompartmentIdInSubtree,
        fleetId: testFleet.id,
        resourceId: testResource.id,
    });
    
    import pulumi
    import pulumi_oci as oci
    
    test_inventory_records = oci.FleetAppsManagement.get_inventory_records(compartment_id=compartment_id,
        compartment_id_in_subtree=inventory_record_compartment_id_in_subtree,
        fleet_id=test_fleet["id"],
        resource_id=test_resource["id"])
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-oci/sdk/v3/go/oci/fleetappsmanagement"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := fleetappsmanagement.GetInventoryRecords(ctx, &fleetappsmanagement.GetInventoryRecordsArgs{
    			CompartmentId:          compartmentId,
    			CompartmentIdInSubtree: pulumi.BoolRef(inventoryRecordCompartmentIdInSubtree),
    			FleetId:                pulumi.StringRef(testFleet.Id),
    			ResourceId:             pulumi.StringRef(testResource.Id),
    		}, nil)
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Oci = Pulumi.Oci;
    
    return await Deployment.RunAsync(() => 
    {
        var testInventoryRecords = Oci.FleetAppsManagement.GetInventoryRecords.Invoke(new()
        {
            CompartmentId = compartmentId,
            CompartmentIdInSubtree = inventoryRecordCompartmentIdInSubtree,
            FleetId = testFleet.Id,
            ResourceId = testResource.Id,
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.oci.FleetAppsManagement.FleetAppsManagementFunctions;
    import com.pulumi.oci.FleetAppsManagement.inputs.GetInventoryRecordsArgs;
    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 testInventoryRecords = FleetAppsManagementFunctions.getInventoryRecords(GetInventoryRecordsArgs.builder()
                .compartmentId(compartmentId)
                .compartmentIdInSubtree(inventoryRecordCompartmentIdInSubtree)
                .fleetId(testFleet.id())
                .resourceId(testResource.id())
                .build());
    
        }
    }
    
    variables:
      testInventoryRecords:
        fn::invoke:
          function: oci:FleetAppsManagement:getInventoryRecords
          arguments:
            compartmentId: ${compartmentId}
            compartmentIdInSubtree: ${inventoryRecordCompartmentIdInSubtree}
            fleetId: ${testFleet.id}
            resourceId: ${testResource.id}
    

    Using getInventoryRecords

    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 getInventoryRecords(args: GetInventoryRecordsArgs, opts?: InvokeOptions): Promise<GetInventoryRecordsResult>
    function getInventoryRecordsOutput(args: GetInventoryRecordsOutputArgs, opts?: InvokeOptions): Output<GetInventoryRecordsResult>
    def get_inventory_records(compartment_id: Optional[str] = None,
                              compartment_id_in_subtree: Optional[bool] = None,
                              filters: Optional[Sequence[GetInventoryRecordsFilter]] = None,
                              fleet_id: Optional[str] = None,
                              resource_id: Optional[str] = None,
                              opts: Optional[InvokeOptions] = None) -> GetInventoryRecordsResult
    def get_inventory_records_output(compartment_id: Optional[pulumi.Input[str]] = None,
                              compartment_id_in_subtree: Optional[pulumi.Input[bool]] = None,
                              filters: Optional[pulumi.Input[Sequence[pulumi.Input[GetInventoryRecordsFilterArgs]]]] = None,
                              fleet_id: Optional[pulumi.Input[str]] = None,
                              resource_id: Optional[pulumi.Input[str]] = None,
                              opts: Optional[InvokeOptions] = None) -> Output[GetInventoryRecordsResult]
    func GetInventoryRecords(ctx *Context, args *GetInventoryRecordsArgs, opts ...InvokeOption) (*GetInventoryRecordsResult, error)
    func GetInventoryRecordsOutput(ctx *Context, args *GetInventoryRecordsOutputArgs, opts ...InvokeOption) GetInventoryRecordsResultOutput

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

    public static class GetInventoryRecords 
    {
        public static Task<GetInventoryRecordsResult> InvokeAsync(GetInventoryRecordsArgs args, InvokeOptions? opts = null)
        public static Output<GetInventoryRecordsResult> Invoke(GetInventoryRecordsInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetInventoryRecordsResult> getInventoryRecords(GetInventoryRecordsArgs args, InvokeOptions options)
    public static Output<GetInventoryRecordsResult> getInventoryRecords(GetInventoryRecordsArgs args, InvokeOptions options)
    
    fn::invoke:
      function: oci:FleetAppsManagement/getInventoryRecords:getInventoryRecords
      arguments:
        # arguments dictionary

    The following arguments are supported:

    CompartmentId string
    The ID of the compartment in which to list resources.
    CompartmentIdInSubtree bool
    If set to true, resources will be returned for not only the provided compartment, but all compartments which descend from it. Which resources are returned and their field contents depends on the value of accessLevel.
    Filters List<GetInventoryRecordsFilter>
    FleetId string
    unique Fleet identifier
    ResourceId string
    Resource Identifier
    CompartmentId string
    The ID of the compartment in which to list resources.
    CompartmentIdInSubtree bool
    If set to true, resources will be returned for not only the provided compartment, but all compartments which descend from it. Which resources are returned and their field contents depends on the value of accessLevel.
    Filters []GetInventoryRecordsFilter
    FleetId string
    unique Fleet identifier
    ResourceId string
    Resource Identifier
    compartmentId String
    The ID of the compartment in which to list resources.
    compartmentIdInSubtree Boolean
    If set to true, resources will be returned for not only the provided compartment, but all compartments which descend from it. Which resources are returned and their field contents depends on the value of accessLevel.
    filters List<GetInventoryRecordsFilter>
    fleetId String
    unique Fleet identifier
    resourceId String
    Resource Identifier
    compartmentId string
    The ID of the compartment in which to list resources.
    compartmentIdInSubtree boolean
    If set to true, resources will be returned for not only the provided compartment, but all compartments which descend from it. Which resources are returned and their field contents depends on the value of accessLevel.
    filters GetInventoryRecordsFilter[]
    fleetId string
    unique Fleet identifier
    resourceId string
    Resource Identifier
    compartment_id str
    The ID of the compartment in which to list resources.
    compartment_id_in_subtree bool
    If set to true, resources will be returned for not only the provided compartment, but all compartments which descend from it. Which resources are returned and their field contents depends on the value of accessLevel.
    filters Sequence[GetInventoryRecordsFilter]
    fleet_id str
    unique Fleet identifier
    resource_id str
    Resource Identifier
    compartmentId String
    The ID of the compartment in which to list resources.
    compartmentIdInSubtree Boolean
    If set to true, resources will be returned for not only the provided compartment, but all compartments which descend from it. Which resources are returned and their field contents depends on the value of accessLevel.
    filters List<Property Map>
    fleetId String
    unique Fleet identifier
    resourceId String
    Resource Identifier

    getInventoryRecords Result

    The following output properties are available:

    CompartmentId string
    OCID of the compartment to which the resource belongs to.
    Id string
    The provider-assigned unique ID for this managed resource.
    InventoryRecordCollections List<GetInventoryRecordsInventoryRecordCollection>
    The list of inventory_record_collection.
    CompartmentIdInSubtree bool
    Filters List<GetInventoryRecordsFilter>
    FleetId string
    ResourceId string
    CompartmentId string
    OCID of the compartment to which the resource belongs to.
    Id string
    The provider-assigned unique ID for this managed resource.
    InventoryRecordCollections []GetInventoryRecordsInventoryRecordCollection
    The list of inventory_record_collection.
    CompartmentIdInSubtree bool
    Filters []GetInventoryRecordsFilter
    FleetId string
    ResourceId string
    compartmentId String
    OCID of the compartment to which the resource belongs to.
    id String
    The provider-assigned unique ID for this managed resource.
    inventoryRecordCollections List<GetInventoryRecordsInventoryRecordCollection>
    The list of inventory_record_collection.
    compartmentIdInSubtree Boolean
    filters List<GetInventoryRecordsFilter>
    fleetId String
    resourceId String
    compartmentId string
    OCID of the compartment to which the resource belongs to.
    id string
    The provider-assigned unique ID for this managed resource.
    inventoryRecordCollections GetInventoryRecordsInventoryRecordCollection[]
    The list of inventory_record_collection.
    compartmentIdInSubtree boolean
    filters GetInventoryRecordsFilter[]
    fleetId string
    resourceId string
    compartment_id str
    OCID of the compartment to which the resource belongs to.
    id str
    The provider-assigned unique ID for this managed resource.
    inventory_record_collections Sequence[GetInventoryRecordsInventoryRecordCollection]
    The list of inventory_record_collection.
    compartment_id_in_subtree bool
    filters Sequence[GetInventoryRecordsFilter]
    fleet_id str
    resource_id str
    compartmentId String
    OCID of the compartment to which the resource belongs to.
    id String
    The provider-assigned unique ID for this managed resource.
    inventoryRecordCollections List<Property Map>
    The list of inventory_record_collection.
    compartmentIdInSubtree Boolean
    filters List<Property Map>
    fleetId String
    resourceId String

    Supporting Types

    GetInventoryRecordsFilter

    Name string
    Name of the inventory target property.
    Values List<string>
    Regex bool
    Name string
    Name of the inventory target property.
    Values []string
    Regex bool
    name String
    Name of the inventory target property.
    values List<String>
    regex Boolean
    name string
    Name of the inventory target property.
    values string[]
    regex boolean
    name str
    Name of the inventory target property.
    values Sequence[str]
    regex bool
    name String
    Name of the inventory target property.
    values List<String>
    regex Boolean

    GetInventoryRecordsInventoryRecordCollection

    items List<Property Map>
    List of inventory targets

    GetInventoryRecordsInventoryRecordCollectionItem

    Architecture string
    Architecture of the resource associated with the target
    CompartmentId string
    The ID of the compartment in which to list resources.
    Components List<GetInventoryRecordsInventoryRecordCollectionItemComponent>
    List of target components
    InstalledPatches List<GetInventoryRecordsInventoryRecordCollectionItemInstalledPatch>
    List of details on the patches currently installed on the target
    OsType string
    OS installed on the resource associated with the target
    Properties List<GetInventoryRecordsInventoryRecordCollectionItemProperty>
    List of target properties
    State string
    The current state of the Inventory target.
    TargetId string
    The OCID of the Inventory target.
    TargetName string
    Name of the target
    TargetProductId string
    OCID of the product installed at the target path
    TargetProductName string
    Name of the product installed at the target path
    TargetResourceId string
    OCID of the resource associated with the target
    TargetResourceName string
    Name of the resource associated with the target
    TimeCreated string
    The time this resource was created. An RFC3339 formatted datetime string.
    TimeUpdated string
    The time this resource was last updated. An RFC3339 formatted datetime string.
    Version string
    Version of the product on the target
    Architecture string
    Architecture of the resource associated with the target
    CompartmentId string
    The ID of the compartment in which to list resources.
    Components []GetInventoryRecordsInventoryRecordCollectionItemComponent
    List of target components
    InstalledPatches []GetInventoryRecordsInventoryRecordCollectionItemInstalledPatch
    List of details on the patches currently installed on the target
    OsType string
    OS installed on the resource associated with the target
    Properties []GetInventoryRecordsInventoryRecordCollectionItemProperty
    List of target properties
    State string
    The current state of the Inventory target.
    TargetId string
    The OCID of the Inventory target.
    TargetName string
    Name of the target
    TargetProductId string
    OCID of the product installed at the target path
    TargetProductName string
    Name of the product installed at the target path
    TargetResourceId string
    OCID of the resource associated with the target
    TargetResourceName string
    Name of the resource associated with the target
    TimeCreated string
    The time this resource was created. An RFC3339 formatted datetime string.
    TimeUpdated string
    The time this resource was last updated. An RFC3339 formatted datetime string.
    Version string
    Version of the product on the target
    architecture String
    Architecture of the resource associated with the target
    compartmentId String
    The ID of the compartment in which to list resources.
    components List<GetInventoryRecordsInventoryRecordCollectionItemComponent>
    List of target components
    installedPatches List<GetInventoryRecordsInventoryRecordCollectionItemInstalledPatch>
    List of details on the patches currently installed on the target
    osType String
    OS installed on the resource associated with the target
    properties List<GetInventoryRecordsInventoryRecordCollectionItemProperty>
    List of target properties
    state String
    The current state of the Inventory target.
    targetId String
    The OCID of the Inventory target.
    targetName String
    Name of the target
    targetProductId String
    OCID of the product installed at the target path
    targetProductName String
    Name of the product installed at the target path
    targetResourceId String
    OCID of the resource associated with the target
    targetResourceName String
    Name of the resource associated with the target
    timeCreated String
    The time this resource was created. An RFC3339 formatted datetime string.
    timeUpdated String
    The time this resource was last updated. An RFC3339 formatted datetime string.
    version String
    Version of the product on the target
    architecture string
    Architecture of the resource associated with the target
    compartmentId string
    The ID of the compartment in which to list resources.
    components GetInventoryRecordsInventoryRecordCollectionItemComponent[]
    List of target components
    installedPatches GetInventoryRecordsInventoryRecordCollectionItemInstalledPatch[]
    List of details on the patches currently installed on the target
    osType string
    OS installed on the resource associated with the target
    properties GetInventoryRecordsInventoryRecordCollectionItemProperty[]
    List of target properties
    state string
    The current state of the Inventory target.
    targetId string
    The OCID of the Inventory target.
    targetName string
    Name of the target
    targetProductId string
    OCID of the product installed at the target path
    targetProductName string
    Name of the product installed at the target path
    targetResourceId string
    OCID of the resource associated with the target
    targetResourceName string
    Name of the resource associated with the target
    timeCreated string
    The time this resource was created. An RFC3339 formatted datetime string.
    timeUpdated string
    The time this resource was last updated. An RFC3339 formatted datetime string.
    version string
    Version of the product on the target
    architecture str
    Architecture of the resource associated with the target
    compartment_id str
    The ID of the compartment in which to list resources.
    components Sequence[GetInventoryRecordsInventoryRecordCollectionItemComponent]
    List of target components
    installed_patches Sequence[GetInventoryRecordsInventoryRecordCollectionItemInstalledPatch]
    List of details on the patches currently installed on the target
    os_type str
    OS installed on the resource associated with the target
    properties Sequence[GetInventoryRecordsInventoryRecordCollectionItemProperty]
    List of target properties
    state str
    The current state of the Inventory target.
    target_id str
    The OCID of the Inventory target.
    target_name str
    Name of the target
    target_product_id str
    OCID of the product installed at the target path
    target_product_name str
    Name of the product installed at the target path
    target_resource_id str
    OCID of the resource associated with the target
    target_resource_name str
    Name of the resource associated with the target
    time_created str
    The time this resource was created. An RFC3339 formatted datetime string.
    time_updated str
    The time this resource was last updated. An RFC3339 formatted datetime string.
    version str
    Version of the product on the target
    architecture String
    Architecture of the resource associated with the target
    compartmentId String
    The ID of the compartment in which to list resources.
    components List<Property Map>
    List of target components
    installedPatches List<Property Map>
    List of details on the patches currently installed on the target
    osType String
    OS installed on the resource associated with the target
    properties List<Property Map>
    List of target properties
    state String
    The current state of the Inventory target.
    targetId String
    The OCID of the Inventory target.
    targetName String
    Name of the target
    targetProductId String
    OCID of the product installed at the target path
    targetProductName String
    Name of the product installed at the target path
    targetResourceId String
    OCID of the resource associated with the target
    targetResourceName String
    Name of the resource associated with the target
    timeCreated String
    The time this resource was created. An RFC3339 formatted datetime string.
    timeUpdated String
    The time this resource was last updated. An RFC3339 formatted datetime string.
    version String
    Version of the product on the target

    GetInventoryRecordsInventoryRecordCollectionItemComponent

    ComponentName string
    Name of the target component
    ComponentPath string
    Path of the component
    ComponentVersion string
    Version of the target component
    Properties List<GetInventoryRecordsInventoryRecordCollectionItemComponentProperty>
    List of target properties
    ComponentName string
    Name of the target component
    ComponentPath string
    Path of the component
    ComponentVersion string
    Version of the target component
    Properties []GetInventoryRecordsInventoryRecordCollectionItemComponentProperty
    List of target properties
    componentName String
    Name of the target component
    componentPath String
    Path of the component
    componentVersion String
    Version of the target component
    properties List<GetInventoryRecordsInventoryRecordCollectionItemComponentProperty>
    List of target properties
    componentName string
    Name of the target component
    componentPath string
    Path of the component
    componentVersion string
    Version of the target component
    properties GetInventoryRecordsInventoryRecordCollectionItemComponentProperty[]
    List of target properties
    component_name str
    Name of the target component
    component_path str
    Path of the component
    component_version str
    Version of the target component
    properties Sequence[GetInventoryRecordsInventoryRecordCollectionItemComponentProperty]
    List of target properties
    componentName String
    Name of the target component
    componentPath String
    Path of the component
    componentVersion String
    Version of the target component
    properties List<Property Map>
    List of target properties

    GetInventoryRecordsInventoryRecordCollectionItemComponentProperty

    Name string
    Name of the inventory target property.
    Value string
    Value of the inventory target property.
    Name string
    Name of the inventory target property.
    Value string
    Value of the inventory target property.
    name String
    Name of the inventory target property.
    value String
    Value of the inventory target property.
    name string
    Name of the inventory target property.
    value string
    Value of the inventory target property.
    name str
    Name of the inventory target property.
    value str
    Value of the inventory target property.
    name String
    Name of the inventory target property.
    value String
    Value of the inventory target property.

    GetInventoryRecordsInventoryRecordCollectionItemInstalledPatch

    PatchDescription string
    Description for the installed patch
    PatchId string
    OCID of the installed patch
    PatchName string
    Name of the installed patch
    PatchType string
    Type of patch applied
    TimeApplied string
    Date on which the patch was applied to the target
    PatchDescription string
    Description for the installed patch
    PatchId string
    OCID of the installed patch
    PatchName string
    Name of the installed patch
    PatchType string
    Type of patch applied
    TimeApplied string
    Date on which the patch was applied to the target
    patchDescription String
    Description for the installed patch
    patchId String
    OCID of the installed patch
    patchName String
    Name of the installed patch
    patchType String
    Type of patch applied
    timeApplied String
    Date on which the patch was applied to the target
    patchDescription string
    Description for the installed patch
    patchId string
    OCID of the installed patch
    patchName string
    Name of the installed patch
    patchType string
    Type of patch applied
    timeApplied string
    Date on which the patch was applied to the target
    patch_description str
    Description for the installed patch
    patch_id str
    OCID of the installed patch
    patch_name str
    Name of the installed patch
    patch_type str
    Type of patch applied
    time_applied str
    Date on which the patch was applied to the target
    patchDescription String
    Description for the installed patch
    patchId String
    OCID of the installed patch
    patchName String
    Name of the installed patch
    patchType String
    Type of patch applied
    timeApplied String
    Date on which the patch was applied to the target

    GetInventoryRecordsInventoryRecordCollectionItemProperty

    Name string
    Name of the inventory target property.
    Value string
    Value of the inventory target property.
    Name string
    Name of the inventory target property.
    Value string
    Value of the inventory target property.
    name String
    Name of the inventory target property.
    value String
    Value of the inventory target property.
    name string
    Name of the inventory target property.
    value string
    Value of the inventory target property.
    name str
    Name of the inventory target property.
    value str
    Value of the inventory target property.
    name String
    Name of the inventory target property.
    value String
    Value of the inventory target property.

    Package Details

    Repository
    oci pulumi/pulumi-oci
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the oci Terraform Provider.
    oci logo
    Oracle Cloud Infrastructure v3.3.0 published on Thursday, Jul 17, 2025 by Pulumi