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

oci.Marketplace.getCategories

Explore with Pulumi AI

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

    This data source provides the list of Categories in Oracle Cloud Infrastructure Marketplace service.

    Gets the list of all the categories for listings published to Oracle Cloud Infrastructure Marketplace. Categories apply to the software product provided by the listing.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as oci from "@pulumi/oci";
    
    const testCategories = oci.Marketplace.getCategories({
        compartmentId: compartmentId,
    });
    
    import pulumi
    import pulumi_oci as oci
    
    test_categories = oci.Marketplace.get_categories(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.GetCategories(ctx, &marketplace.GetCategoriesArgs{
    			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 testCategories = Oci.Marketplace.GetCategories.Invoke(new()
        {
            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.GetCategoriesArgs;
    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 testCategories = MarketplaceFunctions.getCategories(GetCategoriesArgs.builder()
                .compartmentId(compartmentId)
                .build());
    
        }
    }
    
    variables:
      testCategories:
        fn::invoke:
          Function: oci:Marketplace:getCategories
          Arguments:
            compartmentId: ${compartmentId}
    

    Using getCategories

    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 getCategories(args: GetCategoriesArgs, opts?: InvokeOptions): Promise<GetCategoriesResult>
    function getCategoriesOutput(args: GetCategoriesOutputArgs, opts?: InvokeOptions): Output<GetCategoriesResult>
    def get_categories(compartment_id: Optional[str] = None,
                       filters: Optional[Sequence[_marketplace.GetCategoriesFilter]] = None,
                       opts: Optional[InvokeOptions] = None) -> GetCategoriesResult
    def get_categories_output(compartment_id: Optional[pulumi.Input[str]] = None,
                       filters: Optional[pulumi.Input[Sequence[pulumi.Input[_marketplace.GetCategoriesFilterArgs]]]] = None,
                       opts: Optional[InvokeOptions] = None) -> Output[GetCategoriesResult]
    func GetCategories(ctx *Context, args *GetCategoriesArgs, opts ...InvokeOption) (*GetCategoriesResult, error)
    func GetCategoriesOutput(ctx *Context, args *GetCategoriesOutputArgs, opts ...InvokeOption) GetCategoriesResultOutput

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

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

    The following arguments are supported:

    CompartmentId string
    The unique identifier for the compartment.
    Filters List<GetCategoriesFilter>
    CompartmentId string
    The unique identifier for the compartment.
    Filters []GetCategoriesFilter
    compartmentId String
    The unique identifier for the compartment.
    filters List<GetCategoriesFilter>
    compartmentId string
    The unique identifier for the compartment.
    filters GetCategoriesFilter[]
    compartment_id str
    The unique identifier for the compartment.
    filters Sequence[marketplace.GetCategoriesFilter]
    compartmentId String
    The unique identifier for the compartment.
    filters List<Property Map>

    getCategories Result

    The following output properties are available:

    Categories List<GetCategoriesCategory>
    The list of categories.
    Id string
    The provider-assigned unique ID for this managed resource.
    CompartmentId string
    Filters List<GetCategoriesFilter>
    Categories []GetCategoriesCategory
    The list of categories.
    Id string
    The provider-assigned unique ID for this managed resource.
    CompartmentId string
    Filters []GetCategoriesFilter
    categories List<GetCategoriesCategory>
    The list of categories.
    id String
    The provider-assigned unique ID for this managed resource.
    compartmentId String
    filters List<GetCategoriesFilter>
    categories GetCategoriesCategory[]
    The list of categories.
    id string
    The provider-assigned unique ID for this managed resource.
    compartmentId string
    filters GetCategoriesFilter[]
    categories Sequence[marketplace.GetCategoriesCategory]
    The list of categories.
    id str
    The provider-assigned unique ID for this managed resource.
    compartment_id str
    filters Sequence[marketplace.GetCategoriesFilter]
    categories List<Property Map>
    The list of categories.
    id String
    The provider-assigned unique ID for this managed resource.
    compartmentId String
    filters List<Property Map>

    Supporting Types

    GetCategoriesCategory

    Name string
    Name of the product category.
    Name string
    Name of the product category.
    name String
    Name of the product category.
    name string
    Name of the product category.
    name str
    Name of the product category.
    name String
    Name of the product category.

    GetCategoriesFilter

    Name string
    Name of the product category.
    Values List<string>
    Regex bool
    Name string
    Name of the product category.
    Values []string
    Regex bool
    name String
    Name of the product category.
    values List<String>
    regex Boolean
    name string
    Name of the product category.
    values string[]
    regex boolean
    name str
    Name of the product category.
    values Sequence[str]
    regex bool
    name String
    Name of the product category.
    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.11.0 published on Thursday, Sep 19, 2024 by Pulumi