1. Packages
  2. Oracle Cloud Infrastructure
  3. API Docs
  4. Marketplace
  5. getListingPackageAgreements
Oracle Cloud Infrastructure v2.17.0 published on Friday, Nov 15, 2024 by Pulumi

oci.Marketplace.getListingPackageAgreements

Explore with Pulumi AI

oci logo
Oracle Cloud Infrastructure v2.17.0 published on Friday, Nov 15, 2024 by Pulumi

    This data source provides the list of Listing Package Agreements in Oracle Cloud Infrastructure Marketplace service.

    Returns the terms of use agreements that must be accepted before you can deploy the specified version of a package.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as oci from "@pulumi/oci";
    
    const testListingPackageAgreements = oci.Marketplace.getListingPackageAgreements({
        listingId: testListing.id,
        packageVersion: listingPackageAgreementPackageVersion,
        compartmentId: compartmentId,
    });
    
    import pulumi
    import pulumi_oci as oci
    
    test_listing_package_agreements = oci.Marketplace.get_listing_package_agreements(listing_id=test_listing["id"],
        package_version=listing_package_agreement_package_version,
        compartment_id=compartment_id)
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-oci/sdk/v2/go/oci/Marketplace"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := Marketplace.GetListingPackageAgreements(ctx, &marketplace.GetListingPackageAgreementsArgs{
    			ListingId:      testListing.Id,
    			PackageVersion: listingPackageAgreementPackageVersion,
    			CompartmentId:  pulumi.StringRef(compartmentId),
    		}, 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 testListingPackageAgreements = Oci.Marketplace.GetListingPackageAgreements.Invoke(new()
        {
            ListingId = testListing.Id,
            PackageVersion = listingPackageAgreementPackageVersion,
            CompartmentId = compartmentId,
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.oci.Marketplace.MarketplaceFunctions;
    import com.pulumi.oci.Marketplace.inputs.GetListingPackageAgreementsArgs;
    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 testListingPackageAgreements = MarketplaceFunctions.getListingPackageAgreements(GetListingPackageAgreementsArgs.builder()
                .listingId(testListing.id())
                .packageVersion(listingPackageAgreementPackageVersion)
                .compartmentId(compartmentId)
                .build());
    
        }
    }
    
    variables:
      testListingPackageAgreements:
        fn::invoke:
          Function: oci:Marketplace:getListingPackageAgreements
          Arguments:
            listingId: ${testListing.id}
            packageVersion: ${listingPackageAgreementPackageVersion}
            compartmentId: ${compartmentId}
    

    Using getListingPackageAgreements

    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 getListingPackageAgreements(args: GetListingPackageAgreementsArgs, opts?: InvokeOptions): Promise<GetListingPackageAgreementsResult>
    function getListingPackageAgreementsOutput(args: GetListingPackageAgreementsOutputArgs, opts?: InvokeOptions): Output<GetListingPackageAgreementsResult>
    def get_listing_package_agreements(compartment_id: Optional[str] = None,
                                       filters: Optional[Sequence[_marketplace.GetListingPackageAgreementsFilter]] = None,
                                       listing_id: Optional[str] = None,
                                       package_version: Optional[str] = None,
                                       opts: Optional[InvokeOptions] = None) -> GetListingPackageAgreementsResult
    def get_listing_package_agreements_output(compartment_id: Optional[pulumi.Input[str]] = None,
                                       filters: Optional[pulumi.Input[Sequence[pulumi.Input[_marketplace.GetListingPackageAgreementsFilterArgs]]]] = None,
                                       listing_id: Optional[pulumi.Input[str]] = None,
                                       package_version: Optional[pulumi.Input[str]] = None,
                                       opts: Optional[InvokeOptions] = None) -> Output[GetListingPackageAgreementsResult]
    func GetListingPackageAgreements(ctx *Context, args *GetListingPackageAgreementsArgs, opts ...InvokeOption) (*GetListingPackageAgreementsResult, error)
    func GetListingPackageAgreementsOutput(ctx *Context, args *GetListingPackageAgreementsOutputArgs, opts ...InvokeOption) GetListingPackageAgreementsResultOutput

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

    public static class GetListingPackageAgreements 
    {
        public static Task<GetListingPackageAgreementsResult> InvokeAsync(GetListingPackageAgreementsArgs args, InvokeOptions? opts = null)
        public static Output<GetListingPackageAgreementsResult> Invoke(GetListingPackageAgreementsInvokeArgs args, InvokeOptions? opts = null)
    }
    public static CompletableFuture<GetListingPackageAgreementsResult> getListingPackageAgreements(GetListingPackageAgreementsArgs args, InvokeOptions options)
    // Output-based functions aren't available in Java yet
    
    fn::invoke:
      function: oci:Marketplace/getListingPackageAgreements:getListingPackageAgreements
      arguments:
        # arguments dictionary

    The following arguments are supported:

    ListingId string
    The unique identifier for the listing.
    PackageVersion string
    The version of the package. Package versions are unique within a listing.
    CompartmentId string
    The unique identifier for the compartment.
    Filters List<GetListingPackageAgreementsFilter>
    ListingId string
    The unique identifier for the listing.
    PackageVersion string
    The version of the package. Package versions are unique within a listing.
    CompartmentId string
    The unique identifier for the compartment.
    Filters []GetListingPackageAgreementsFilter
    listingId String
    The unique identifier for the listing.
    packageVersion String
    The version of the package. Package versions are unique within a listing.
    compartmentId String
    The unique identifier for the compartment.
    filters List<GetListingPackageAgreementsFilter>
    listingId string
    The unique identifier for the listing.
    packageVersion string
    The version of the package. Package versions are unique within a listing.
    compartmentId string
    The unique identifier for the compartment.
    filters GetListingPackageAgreementsFilter[]
    listing_id str
    The unique identifier for the listing.
    package_version str
    The version of the package. Package versions are unique within a listing.
    compartment_id str
    The unique identifier for the compartment.
    filters Sequence[marketplace.GetListingPackageAgreementsFilter]
    listingId String
    The unique identifier for the listing.
    packageVersion String
    The version of the package. Package versions are unique within a listing.
    compartmentId String
    The unique identifier for the compartment.
    filters List<Property Map>

    getListingPackageAgreements Result

    The following output properties are available:

    Agreements List<GetListingPackageAgreementsAgreement>
    The list of agreements.
    Id string
    The provider-assigned unique ID for this managed resource.
    ListingId string
    PackageVersion string
    CompartmentId string
    The unique identifier for the compartment.
    Filters List<GetListingPackageAgreementsFilter>
    Agreements []GetListingPackageAgreementsAgreement
    The list of agreements.
    Id string
    The provider-assigned unique ID for this managed resource.
    ListingId string
    PackageVersion string
    CompartmentId string
    The unique identifier for the compartment.
    Filters []GetListingPackageAgreementsFilter
    agreements List<GetListingPackageAgreementsAgreement>
    The list of agreements.
    id String
    The provider-assigned unique ID for this managed resource.
    listingId String
    packageVersion String
    compartmentId String
    The unique identifier for the compartment.
    filters List<GetListingPackageAgreementsFilter>
    agreements GetListingPackageAgreementsAgreement[]
    The list of agreements.
    id string
    The provider-assigned unique ID for this managed resource.
    listingId string
    packageVersion string
    compartmentId string
    The unique identifier for the compartment.
    filters GetListingPackageAgreementsFilter[]
    agreements Sequence[marketplace.GetListingPackageAgreementsAgreement]
    The list of agreements.
    id str
    The provider-assigned unique ID for this managed resource.
    listing_id str
    package_version str
    compartment_id str
    The unique identifier for the compartment.
    filters Sequence[marketplace.GetListingPackageAgreementsFilter]
    agreements List<Property Map>
    The list of agreements.
    id String
    The provider-assigned unique ID for this managed resource.
    listingId String
    packageVersion String
    compartmentId String
    The unique identifier for the compartment.
    filters List<Property Map>

    Supporting Types

    GetListingPackageAgreementsAgreement

    Author string
    Who authored the agreement.
    ContentUrl string
    The content URL of the agreement.
    Id string
    The unique identifier for the agreement.
    Prompt string
    Textual prompt to read and accept the agreement.
    Author string
    Who authored the agreement.
    ContentUrl string
    The content URL of the agreement.
    Id string
    The unique identifier for the agreement.
    Prompt string
    Textual prompt to read and accept the agreement.
    author String
    Who authored the agreement.
    contentUrl String
    The content URL of the agreement.
    id String
    The unique identifier for the agreement.
    prompt String
    Textual prompt to read and accept the agreement.
    author string
    Who authored the agreement.
    contentUrl string
    The content URL of the agreement.
    id string
    The unique identifier for the agreement.
    prompt string
    Textual prompt to read and accept the agreement.
    author str
    Who authored the agreement.
    content_url str
    The content URL of the agreement.
    id str
    The unique identifier for the agreement.
    prompt str
    Textual prompt to read and accept the agreement.
    author String
    Who authored the agreement.
    contentUrl String
    The content URL of the agreement.
    id String
    The unique identifier for the agreement.
    prompt String
    Textual prompt to read and accept the agreement.

    GetListingPackageAgreementsFilter

    Name string
    Values List<string>
    Regex bool
    Name string
    Values []string
    Regex bool
    name String
    values List<String>
    regex Boolean
    name string
    values string[]
    regex boolean
    name str
    values Sequence[str]
    regex bool
    name String
    values List<String>
    regex Boolean

    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.17.0 published on Friday, Nov 15, 2024 by Pulumi