1. Packages
  2. Oracle Cloud Infrastructure
  3. API Docs
  4. OneSubsription
  5. getCommitment
Oracle Cloud Infrastructure v2.11.0 published on Thursday, Sep 19, 2024 by Pulumi

oci.OneSubsription.getCommitment

Explore with Pulumi AI

oci logo
Oracle Cloud Infrastructure v2.11.0 published on Thursday, Sep 19, 2024 by Pulumi

    This data source provides details about a specific Commitment resource in Oracle Cloud Infrastructure Onesubscription service.

    This API returns the commitment details corresponding to the id provided

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as oci from "@pulumi/oci";
    
    const testCommitment = oci.OneSubsription.getCommitment({
        commitmentId: testCommitmentOciOnesubscriptionCommitment.id,
    });
    
    import pulumi
    import pulumi_oci as oci
    
    test_commitment = oci.OneSubsription.get_commitment(commitment_id=test_commitment_oci_onesubscription_commitment["id"])
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-oci/sdk/v2/go/oci/OneSubsription"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := OneSubsription.GetCommitment(ctx, &onesubsription.GetCommitmentArgs{
    			CommitmentId: testCommitmentOciOnesubscriptionCommitment.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 testCommitment = Oci.OneSubsription.GetCommitment.Invoke(new()
        {
            CommitmentId = testCommitmentOciOnesubscriptionCommitment.Id,
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.oci.OneSubsription.OneSubsriptionFunctions;
    import com.pulumi.oci.OneSubsription.inputs.GetCommitmentArgs;
    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 testCommitment = OneSubsriptionFunctions.getCommitment(GetCommitmentArgs.builder()
                .commitmentId(testCommitmentOciOnesubscriptionCommitment.id())
                .build());
    
        }
    }
    
    variables:
      testCommitment:
        fn::invoke:
          Function: oci:OneSubsription:getCommitment
          Arguments:
            commitmentId: ${testCommitmentOciOnesubscriptionCommitment.id}
    

    Using getCommitment

    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 getCommitment(args: GetCommitmentArgs, opts?: InvokeOptions): Promise<GetCommitmentResult>
    function getCommitmentOutput(args: GetCommitmentOutputArgs, opts?: InvokeOptions): Output<GetCommitmentResult>
    def get_commitment(commitment_id: Optional[str] = None,
                       opts: Optional[InvokeOptions] = None) -> GetCommitmentResult
    def get_commitment_output(commitment_id: Optional[pulumi.Input[str]] = None,
                       opts: Optional[InvokeOptions] = None) -> Output[GetCommitmentResult]
    func GetCommitment(ctx *Context, args *GetCommitmentArgs, opts ...InvokeOption) (*GetCommitmentResult, error)
    func GetCommitmentOutput(ctx *Context, args *GetCommitmentOutputArgs, opts ...InvokeOption) GetCommitmentResultOutput

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

    public static class GetCommitment 
    {
        public static Task<GetCommitmentResult> InvokeAsync(GetCommitmentArgs args, InvokeOptions? opts = null)
        public static Output<GetCommitmentResult> Invoke(GetCommitmentInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetCommitmentResult> getCommitment(GetCommitmentArgs args, InvokeOptions options)
    // Output-based functions aren't available in Java yet
    
    fn::invoke:
      function: oci:OneSubsription/getCommitment:getCommitment
      arguments:
        # arguments dictionary

    The following arguments are supported:

    CommitmentId string
    The Commitment Id
    CommitmentId string
    The Commitment Id
    commitmentId String
    The Commitment Id
    commitmentId string
    The Commitment Id
    commitment_id str
    The Commitment Id
    commitmentId String
    The Commitment Id

    getCommitment Result

    The following output properties are available:

    AvailableAmount string
    Commitment available amount
    CommitmentId string
    FundedAllocationValue string
    Funded Allocation line value example: 12000.00
    Id string
    The provider-assigned unique ID for this managed resource.
    Quantity string
    Commitment quantity
    SubscribedServiceId string
    SPM internal Subscribed Service ID
    TimeEnd string
    Commitment end date
    TimeStart string
    Commitment start date
    UsedAmount string
    Commitment used amount
    AvailableAmount string
    Commitment available amount
    CommitmentId string
    FundedAllocationValue string
    Funded Allocation line value example: 12000.00
    Id string
    The provider-assigned unique ID for this managed resource.
    Quantity string
    Commitment quantity
    SubscribedServiceId string
    SPM internal Subscribed Service ID
    TimeEnd string
    Commitment end date
    TimeStart string
    Commitment start date
    UsedAmount string
    Commitment used amount
    availableAmount String
    Commitment available amount
    commitmentId String
    fundedAllocationValue String
    Funded Allocation line value example: 12000.00
    id String
    The provider-assigned unique ID for this managed resource.
    quantity String
    Commitment quantity
    subscribedServiceId String
    SPM internal Subscribed Service ID
    timeEnd String
    Commitment end date
    timeStart String
    Commitment start date
    usedAmount String
    Commitment used amount
    availableAmount string
    Commitment available amount
    commitmentId string
    fundedAllocationValue string
    Funded Allocation line value example: 12000.00
    id string
    The provider-assigned unique ID for this managed resource.
    quantity string
    Commitment quantity
    subscribedServiceId string
    SPM internal Subscribed Service ID
    timeEnd string
    Commitment end date
    timeStart string
    Commitment start date
    usedAmount string
    Commitment used amount
    available_amount str
    Commitment available amount
    commitment_id str
    funded_allocation_value str
    Funded Allocation line value example: 12000.00
    id str
    The provider-assigned unique ID for this managed resource.
    quantity str
    Commitment quantity
    subscribed_service_id str
    SPM internal Subscribed Service ID
    time_end str
    Commitment end date
    time_start str
    Commitment start date
    used_amount str
    Commitment used amount
    availableAmount String
    Commitment available amount
    commitmentId String
    fundedAllocationValue String
    Funded Allocation line value example: 12000.00
    id String
    The provider-assigned unique ID for this managed resource.
    quantity String
    Commitment quantity
    subscribedServiceId String
    SPM internal Subscribed Service ID
    timeEnd String
    Commitment end date
    timeStart String
    Commitment start date
    usedAmount String
    Commitment used amount

    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 v2.11.0 published on Thursday, Sep 19, 2024 by Pulumi