Oracle Cloud Infrastructure v2.17.0 published on Friday, Nov 15, 2024 by Pulumi
oci.Optimizer.getEnrollmentStatuses
Explore with Pulumi AI
This data source provides the list of Enrollment Statuses in Oracle Cloud Infrastructure Optimizer service.
Lists the Cloud Advisor enrollment statuses.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as oci from "@pulumi/oci";
const testEnrollmentStatuses = oci.Optimizer.getEnrollmentStatuses({
compartmentId: compartmentId,
state: enrollmentStatusState,
status: enrollmentStatusStatus,
});
import pulumi
import pulumi_oci as oci
test_enrollment_statuses = oci.Optimizer.get_enrollment_statuses(compartment_id=compartment_id,
state=enrollment_status_state,
status=enrollment_status_status)
package main
import (
"github.com/pulumi/pulumi-oci/sdk/v2/go/oci/Optimizer"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := Optimizer.GetEnrollmentStatuses(ctx, &optimizer.GetEnrollmentStatusesArgs{
CompartmentId: compartmentId,
State: pulumi.StringRef(enrollmentStatusState),
Status: pulumi.StringRef(enrollmentStatusStatus),
}, 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 testEnrollmentStatuses = Oci.Optimizer.GetEnrollmentStatuses.Invoke(new()
{
CompartmentId = compartmentId,
State = enrollmentStatusState,
Status = enrollmentStatusStatus,
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.oci.Optimizer.OptimizerFunctions;
import com.pulumi.oci.Optimizer.inputs.GetEnrollmentStatusesArgs;
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 testEnrollmentStatuses = OptimizerFunctions.getEnrollmentStatuses(GetEnrollmentStatusesArgs.builder()
.compartmentId(compartmentId)
.state(enrollmentStatusState)
.status(enrollmentStatusStatus)
.build());
}
}
variables:
testEnrollmentStatuses:
fn::invoke:
Function: oci:Optimizer:getEnrollmentStatuses
Arguments:
compartmentId: ${compartmentId}
state: ${enrollmentStatusState}
status: ${enrollmentStatusStatus}
Using getEnrollmentStatuses
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 getEnrollmentStatuses(args: GetEnrollmentStatusesArgs, opts?: InvokeOptions): Promise<GetEnrollmentStatusesResult>
function getEnrollmentStatusesOutput(args: GetEnrollmentStatusesOutputArgs, opts?: InvokeOptions): Output<GetEnrollmentStatusesResult>
def get_enrollment_statuses(compartment_id: Optional[str] = None,
filters: Optional[Sequence[_optimizer.GetEnrollmentStatusesFilter]] = None,
state: Optional[str] = None,
status: Optional[str] = None,
opts: Optional[InvokeOptions] = None) -> GetEnrollmentStatusesResult
def get_enrollment_statuses_output(compartment_id: Optional[pulumi.Input[str]] = None,
filters: Optional[pulumi.Input[Sequence[pulumi.Input[_optimizer.GetEnrollmentStatusesFilterArgs]]]] = None,
state: Optional[pulumi.Input[str]] = None,
status: Optional[pulumi.Input[str]] = None,
opts: Optional[InvokeOptions] = None) -> Output[GetEnrollmentStatusesResult]
func GetEnrollmentStatuses(ctx *Context, args *GetEnrollmentStatusesArgs, opts ...InvokeOption) (*GetEnrollmentStatusesResult, error)
func GetEnrollmentStatusesOutput(ctx *Context, args *GetEnrollmentStatusesOutputArgs, opts ...InvokeOption) GetEnrollmentStatusesResultOutput
> Note: This function is named GetEnrollmentStatuses
in the Go SDK.
public static class GetEnrollmentStatuses
{
public static Task<GetEnrollmentStatusesResult> InvokeAsync(GetEnrollmentStatusesArgs args, InvokeOptions? opts = null)
public static Output<GetEnrollmentStatusesResult> Invoke(GetEnrollmentStatusesInvokeArgs args, InvokeOptions? opts = null)
}
public static CompletableFuture<GetEnrollmentStatusesResult> getEnrollmentStatuses(GetEnrollmentStatusesArgs args, InvokeOptions options)
// Output-based functions aren't available in Java yet
fn::invoke:
function: oci:Optimizer/getEnrollmentStatuses:getEnrollmentStatuses
arguments:
# arguments dictionary
The following arguments are supported:
- Compartment
Id string - The OCID of the compartment.
- Filters
List<Get
Enrollment Statuses Filter> - State string
- A filter that returns results that match the lifecycle state specified.
- Status string
- A filter that returns results that match the Cloud Advisor enrollment status specified.
- Compartment
Id string - The OCID of the compartment.
- Filters
[]Get
Enrollment Statuses Filter - State string
- A filter that returns results that match the lifecycle state specified.
- Status string
- A filter that returns results that match the Cloud Advisor enrollment status specified.
- compartment
Id String - The OCID of the compartment.
- filters
List<Get
Enrollment Statuses Filter> - state String
- A filter that returns results that match the lifecycle state specified.
- status String
- A filter that returns results that match the Cloud Advisor enrollment status specified.
- compartment
Id string - The OCID of the compartment.
- filters
Get
Enrollment Statuses Filter[] - state string
- A filter that returns results that match the lifecycle state specified.
- status string
- A filter that returns results that match the Cloud Advisor enrollment status specified.
- compartment_
id str - The OCID of the compartment.
- filters
Sequence[optimizer.
Get Enrollment Statuses Filter] - state str
- A filter that returns results that match the lifecycle state specified.
- status str
- A filter that returns results that match the Cloud Advisor enrollment status specified.
- compartment
Id String - The OCID of the compartment.
- filters List<Property Map>
- state String
- A filter that returns results that match the lifecycle state specified.
- status String
- A filter that returns results that match the Cloud Advisor enrollment status specified.
getEnrollmentStatuses Result
The following output properties are available:
- Compartment
Id string - The OCID of the compartment.
- Enrollment
Status List<GetCollections Enrollment Statuses Enrollment Status Collection> - The list of enrollment_status_collection.
- Id string
- The provider-assigned unique ID for this managed resource.
- Filters
List<Get
Enrollment Statuses Filter> - State string
- The enrollment status' current state.
- Status string
- The current Cloud Advisor enrollment status.
- Compartment
Id string - The OCID of the compartment.
- Enrollment
Status []GetCollections Enrollment Statuses Enrollment Status Collection - The list of enrollment_status_collection.
- Id string
- The provider-assigned unique ID for this managed resource.
- Filters
[]Get
Enrollment Statuses Filter - State string
- The enrollment status' current state.
- Status string
- The current Cloud Advisor enrollment status.
- compartment
Id String - The OCID of the compartment.
- enrollment
Status List<GetCollections Enrollment Statuses Enrollment Status Collection> - The list of enrollment_status_collection.
- id String
- The provider-assigned unique ID for this managed resource.
- filters
List<Get
Enrollment Statuses Filter> - state String
- The enrollment status' current state.
- status String
- The current Cloud Advisor enrollment status.
- compartment
Id string - The OCID of the compartment.
- enrollment
Status GetCollections Enrollment Statuses Enrollment Status Collection[] - The list of enrollment_status_collection.
- id string
- The provider-assigned unique ID for this managed resource.
- filters
Get
Enrollment Statuses Filter[] - state string
- The enrollment status' current state.
- status string
- The current Cloud Advisor enrollment status.
- compartment_
id str - The OCID of the compartment.
- enrollment_
status_ Sequence[optimizer.collections Get Enrollment Statuses Enrollment Status Collection] - The list of enrollment_status_collection.
- id str
- The provider-assigned unique ID for this managed resource.
- filters
Sequence[optimizer.
Get Enrollment Statuses Filter] - state str
- The enrollment status' current state.
- status str
- The current Cloud Advisor enrollment status.
- compartment
Id String - The OCID of the compartment.
- enrollment
Status List<Property Map>Collections - The list of enrollment_status_collection.
- id String
- The provider-assigned unique ID for this managed resource.
- filters List<Property Map>
- state String
- The enrollment status' current state.
- status String
- The current Cloud Advisor enrollment status.
Supporting Types
GetEnrollmentStatusesEnrollmentStatusCollection
GetEnrollmentStatusesEnrollmentStatusCollectionItem
- Compartment
Id string - The OCID of the compartment.
- Enrollment
Status stringId - Id string
- The OCID of the enrollment status.
- State string
- A filter that returns results that match the lifecycle state specified.
- Status string
- A filter that returns results that match the Cloud Advisor enrollment status specified.
- Status
Reason string - The reason for the enrollment status of the tenancy.
- Time
Created string - The date and time the enrollment status was created, in the format defined by RFC3339.
- Time
Updated string - The date and time the enrollment status was last updated, in the format defined by RFC3339.
- Compartment
Id string - The OCID of the compartment.
- Enrollment
Status stringId - Id string
- The OCID of the enrollment status.
- State string
- A filter that returns results that match the lifecycle state specified.
- Status string
- A filter that returns results that match the Cloud Advisor enrollment status specified.
- Status
Reason string - The reason for the enrollment status of the tenancy.
- Time
Created string - The date and time the enrollment status was created, in the format defined by RFC3339.
- Time
Updated string - The date and time the enrollment status was last updated, in the format defined by RFC3339.
- compartment
Id String - The OCID of the compartment.
- enrollment
Status StringId - id String
- The OCID of the enrollment status.
- state String
- A filter that returns results that match the lifecycle state specified.
- status String
- A filter that returns results that match the Cloud Advisor enrollment status specified.
- status
Reason String - The reason for the enrollment status of the tenancy.
- time
Created String - The date and time the enrollment status was created, in the format defined by RFC3339.
- time
Updated String - The date and time the enrollment status was last updated, in the format defined by RFC3339.
- compartment
Id string - The OCID of the compartment.
- enrollment
Status stringId - id string
- The OCID of the enrollment status.
- state string
- A filter that returns results that match the lifecycle state specified.
- status string
- A filter that returns results that match the Cloud Advisor enrollment status specified.
- status
Reason string - The reason for the enrollment status of the tenancy.
- time
Created string - The date and time the enrollment status was created, in the format defined by RFC3339.
- time
Updated string - The date and time the enrollment status was last updated, in the format defined by RFC3339.
- compartment_
id str - The OCID of the compartment.
- enrollment_
status_ strid - id str
- The OCID of the enrollment status.
- state str
- A filter that returns results that match the lifecycle state specified.
- status str
- A filter that returns results that match the Cloud Advisor enrollment status specified.
- status_
reason str - The reason for the enrollment status of the tenancy.
- time_
created str - The date and time the enrollment status was created, in the format defined by RFC3339.
- time_
updated str - The date and time the enrollment status was last updated, in the format defined by RFC3339.
- compartment
Id String - The OCID of the compartment.
- enrollment
Status StringId - id String
- The OCID of the enrollment status.
- state String
- A filter that returns results that match the lifecycle state specified.
- status String
- A filter that returns results that match the Cloud Advisor enrollment status specified.
- status
Reason String - The reason for the enrollment status of the tenancy.
- time
Created String - The date and time the enrollment status was created, in the format defined by RFC3339.
- time
Updated String - The date and time the enrollment status was last updated, in the format defined by RFC3339.
GetEnrollmentStatusesFilter
Package Details
- Repository
- oci pulumi/pulumi-oci
- License
- Apache-2.0
- Notes
- This Pulumi package is based on the
oci
Terraform Provider.