1. Packages
  2. Prismacloud Provider
  3. API Docs
  4. Collection
prismacloud 1.7.0 published on Monday, Apr 14, 2025 by paloaltonetworks

prismacloud.Collection

Explore with Pulumi AI

prismacloud logo
prismacloud 1.7.0 published on Monday, Apr 14, 2025 by paloaltonetworks

    Manage a collection.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as prismacloud from "@pulumi/prismacloud";
    
    const example = new prismacloud.Collection("example", {
        assetGroups: [{
            accountGroupIds: ["account_group_ids"],
            accountIds: ["account_ids"],
            repositoryIds: ["repository_ids"],
        }],
        description: "Made by Pulumi",
    });
    
    import pulumi
    import pulumi_prismacloud as prismacloud
    
    example = prismacloud.Collection("example",
        asset_groups=[{
            "account_group_ids": ["account_group_ids"],
            "account_ids": ["account_ids"],
            "repository_ids": ["repository_ids"],
        }],
        description="Made by Pulumi")
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-terraform-provider/sdks/go/prismacloud/prismacloud"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := prismacloud.NewCollection(ctx, "example", &prismacloud.CollectionArgs{
    			AssetGroups: prismacloud.CollectionAssetGroupArray{
    				&prismacloud.CollectionAssetGroupArgs{
    					AccountGroupIds: pulumi.StringArray{
    						pulumi.String("account_group_ids"),
    					},
    					AccountIds: pulumi.StringArray{
    						pulumi.String("account_ids"),
    					},
    					RepositoryIds: pulumi.StringArray{
    						pulumi.String("repository_ids"),
    					},
    				},
    			},
    			Description: pulumi.String("Made by Pulumi"),
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Prismacloud = Pulumi.Prismacloud;
    
    return await Deployment.RunAsync(() => 
    {
        var example = new Prismacloud.Collection("example", new()
        {
            AssetGroups = new[]
            {
                new Prismacloud.Inputs.CollectionAssetGroupArgs
                {
                    AccountGroupIds = new[]
                    {
                        "account_group_ids",
                    },
                    AccountIds = new[]
                    {
                        "account_ids",
                    },
                    RepositoryIds = new[]
                    {
                        "repository_ids",
                    },
                },
            },
            Description = "Made by Pulumi",
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.prismacloud.Collection;
    import com.pulumi.prismacloud.CollectionArgs;
    import com.pulumi.prismacloud.inputs.CollectionAssetGroupArgs;
    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) {
            var example = new Collection("example", CollectionArgs.builder()
                .assetGroups(CollectionAssetGroupArgs.builder()
                    .accountGroupIds("account_group_ids")
                    .accountIds("account_ids")
                    .repositoryIds("repository_ids")
                    .build())
                .description("Made by Pulumi")
                .build());
    
        }
    }
    
    resources:
      example:
        type: prismacloud:Collection
        properties:
          assetGroups:
            - accountGroupIds:
                - account_group_ids
              accountIds:
                - account_ids
              repositoryIds:
                - repository_ids
          description: Made by Pulumi
    

    Create Collection Resource

    Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.

    Constructor syntax

    new Collection(name: string, args: CollectionArgs, opts?: CustomResourceOptions);
    @overload
    def Collection(resource_name: str,
                   args: CollectionArgs,
                   opts: Optional[ResourceOptions] = None)
    
    @overload
    def Collection(resource_name: str,
                   opts: Optional[ResourceOptions] = None,
                   asset_groups: Optional[Sequence[CollectionAssetGroupArgs]] = None,
                   description: Optional[str] = None,
                   name: Optional[str] = None)
    func NewCollection(ctx *Context, name string, args CollectionArgs, opts ...ResourceOption) (*Collection, error)
    public Collection(string name, CollectionArgs args, CustomResourceOptions? opts = null)
    public Collection(String name, CollectionArgs args)
    public Collection(String name, CollectionArgs args, CustomResourceOptions options)
    
    type: prismacloud:Collection
    properties: # The arguments to resource properties.
    options: # Bag of options to control resource's behavior.
    
    

    Parameters

    name string
    The unique name of the resource.
    args CollectionArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    resource_name str
    The unique name of the resource.
    args CollectionArgs
    The arguments to resource properties.
    opts ResourceOptions
    Bag of options to control resource's behavior.
    ctx Context
    Context object for the current deployment.
    name string
    The unique name of the resource.
    args CollectionArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args CollectionArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args CollectionArgs
    The arguments to resource properties.
    options CustomResourceOptions
    Bag of options to control resource's behavior.

    Constructor example

    The following reference example uses placeholder values for all input properties.

    var collectionResource = new Prismacloud.Collection("collectionResource", new()
    {
        AssetGroups = new[]
        {
            new Prismacloud.Inputs.CollectionAssetGroupArgs
            {
                AccountGroupIds = new[]
                {
                    "string",
                },
                AccountIds = new[]
                {
                    "string",
                },
                RepositoryIds = new[]
                {
                    "string",
                },
            },
        },
        Description = "string",
        Name = "string",
    });
    
    example, err := prismacloud.NewCollection(ctx, "collectionResource", &prismacloud.CollectionArgs{
    	AssetGroups: prismacloud.CollectionAssetGroupArray{
    		&prismacloud.CollectionAssetGroupArgs{
    			AccountGroupIds: pulumi.StringArray{
    				pulumi.String("string"),
    			},
    			AccountIds: pulumi.StringArray{
    				pulumi.String("string"),
    			},
    			RepositoryIds: pulumi.StringArray{
    				pulumi.String("string"),
    			},
    		},
    	},
    	Description: pulumi.String("string"),
    	Name:        pulumi.String("string"),
    })
    
    var collectionResource = new Collection("collectionResource", CollectionArgs.builder()
        .assetGroups(CollectionAssetGroupArgs.builder()
            .accountGroupIds("string")
            .accountIds("string")
            .repositoryIds("string")
            .build())
        .description("string")
        .name("string")
        .build());
    
    collection_resource = prismacloud.Collection("collectionResource",
        asset_groups=[{
            "account_group_ids": ["string"],
            "account_ids": ["string"],
            "repository_ids": ["string"],
        }],
        description="string",
        name="string")
    
    const collectionResource = new prismacloud.Collection("collectionResource", {
        assetGroups: [{
            accountGroupIds: ["string"],
            accountIds: ["string"],
            repositoryIds: ["string"],
        }],
        description: "string",
        name: "string",
    });
    
    type: prismacloud:Collection
    properties:
        assetGroups:
            - accountGroupIds:
                - string
              accountIds:
                - string
              repositoryIds:
                - string
        description: string
        name: string
    

    Collection Resource Properties

    To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.

    Inputs

    In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.

    The Collection resource accepts the following input properties:

    AssetGroups List<CollectionAssetGroup>
    List of asset groups contained within the collection as defined below
    Description string
    Description of the collection.
    Name string
    Name of the collection.
    AssetGroups []CollectionAssetGroupArgs
    List of asset groups contained within the collection as defined below
    Description string
    Description of the collection.
    Name string
    Name of the collection.
    assetGroups List<CollectionAssetGroup>
    List of asset groups contained within the collection as defined below
    description String
    Description of the collection.
    name String
    Name of the collection.
    assetGroups CollectionAssetGroup[]
    List of asset groups contained within the collection as defined below
    description string
    Description of the collection.
    name string
    Name of the collection.
    asset_groups Sequence[CollectionAssetGroupArgs]
    List of asset groups contained within the collection as defined below
    description str
    Description of the collection.
    name str
    Name of the collection.
    assetGroups List<Property Map>
    List of asset groups contained within the collection as defined below
    description String
    Description of the collection.
    name String
    Name of the collection.

    Outputs

    All input properties are implicitly available as output properties. Additionally, the Collection resource produces the following output properties:

    CreatedBy string
    Created by.
    CreatedTs double
    (int) The timestamp when the collection was created.
    Id string
    The provider-assigned unique ID for this managed resource.
    LastModifiedBy string
    Last modified by.
    LastModifiedTs double
    (int) Last modified timestamp.
    CreatedBy string
    Created by.
    CreatedTs float64
    (int) The timestamp when the collection was created.
    Id string
    The provider-assigned unique ID for this managed resource.
    LastModifiedBy string
    Last modified by.
    LastModifiedTs float64
    (int) Last modified timestamp.
    createdBy String
    Created by.
    createdTs Double
    (int) The timestamp when the collection was created.
    id String
    The provider-assigned unique ID for this managed resource.
    lastModifiedBy String
    Last modified by.
    lastModifiedTs Double
    (int) Last modified timestamp.
    createdBy string
    Created by.
    createdTs number
    (int) The timestamp when the collection was created.
    id string
    The provider-assigned unique ID for this managed resource.
    lastModifiedBy string
    Last modified by.
    lastModifiedTs number
    (int) Last modified timestamp.
    created_by str
    Created by.
    created_ts float
    (int) The timestamp when the collection was created.
    id str
    The provider-assigned unique ID for this managed resource.
    last_modified_by str
    Last modified by.
    last_modified_ts float
    (int) Last modified timestamp.
    createdBy String
    Created by.
    createdTs Number
    (int) The timestamp when the collection was created.
    id String
    The provider-assigned unique ID for this managed resource.
    lastModifiedBy String
    Last modified by.
    lastModifiedTs Number
    (int) Last modified timestamp.

    Look up Existing Collection Resource

    Get an existing Collection resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

    public static get(name: string, id: Input<ID>, state?: CollectionState, opts?: CustomResourceOptions): Collection
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            asset_groups: Optional[Sequence[CollectionAssetGroupArgs]] = None,
            created_by: Optional[str] = None,
            created_ts: Optional[float] = None,
            description: Optional[str] = None,
            last_modified_by: Optional[str] = None,
            last_modified_ts: Optional[float] = None,
            name: Optional[str] = None) -> Collection
    func GetCollection(ctx *Context, name string, id IDInput, state *CollectionState, opts ...ResourceOption) (*Collection, error)
    public static Collection Get(string name, Input<string> id, CollectionState? state, CustomResourceOptions? opts = null)
    public static Collection get(String name, Output<String> id, CollectionState state, CustomResourceOptions options)
    resources:  _:    type: prismacloud:Collection    get:      id: ${id}
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    resource_name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    name
    The unique name of the resulting resource.
    id
    The unique provider ID of the resource to lookup.
    state
    Any extra arguments used during the lookup.
    opts
    A bag of options that control this resource's behavior.
    The following state arguments are supported:
    AssetGroups List<CollectionAssetGroup>
    List of asset groups contained within the collection as defined below
    CreatedBy string
    Created by.
    CreatedTs double
    (int) The timestamp when the collection was created.
    Description string
    Description of the collection.
    LastModifiedBy string
    Last modified by.
    LastModifiedTs double
    (int) Last modified timestamp.
    Name string
    Name of the collection.
    AssetGroups []CollectionAssetGroupArgs
    List of asset groups contained within the collection as defined below
    CreatedBy string
    Created by.
    CreatedTs float64
    (int) The timestamp when the collection was created.
    Description string
    Description of the collection.
    LastModifiedBy string
    Last modified by.
    LastModifiedTs float64
    (int) Last modified timestamp.
    Name string
    Name of the collection.
    assetGroups List<CollectionAssetGroup>
    List of asset groups contained within the collection as defined below
    createdBy String
    Created by.
    createdTs Double
    (int) The timestamp when the collection was created.
    description String
    Description of the collection.
    lastModifiedBy String
    Last modified by.
    lastModifiedTs Double
    (int) Last modified timestamp.
    name String
    Name of the collection.
    assetGroups CollectionAssetGroup[]
    List of asset groups contained within the collection as defined below
    createdBy string
    Created by.
    createdTs number
    (int) The timestamp when the collection was created.
    description string
    Description of the collection.
    lastModifiedBy string
    Last modified by.
    lastModifiedTs number
    (int) Last modified timestamp.
    name string
    Name of the collection.
    asset_groups Sequence[CollectionAssetGroupArgs]
    List of asset groups contained within the collection as defined below
    created_by str
    Created by.
    created_ts float
    (int) The timestamp when the collection was created.
    description str
    Description of the collection.
    last_modified_by str
    Last modified by.
    last_modified_ts float
    (int) Last modified timestamp.
    name str
    Name of the collection.
    assetGroups List<Property Map>
    List of asset groups contained within the collection as defined below
    createdBy String
    Created by.
    createdTs Number
    (int) The timestamp when the collection was created.
    description String
    Description of the collection.
    lastModifiedBy String
    Last modified by.
    lastModifiedTs Number
    (int) Last modified timestamp.
    name String
    Name of the collection.

    Supporting Types

    CollectionAssetGroup, CollectionAssetGroupArgs

    AccountGroupIds List<string>
    (Optional) A list of account group IDs associated with the collection.
    AccountIds List<string>
    (Optional) A list of cloud account IDs associated with the collection.
    RepositoryIds List<string>
    (Optional) A list of repository IDs associated with the collection.
    AccountGroupIds []string
    (Optional) A list of account group IDs associated with the collection.
    AccountIds []string
    (Optional) A list of cloud account IDs associated with the collection.
    RepositoryIds []string
    (Optional) A list of repository IDs associated with the collection.
    accountGroupIds List<String>
    (Optional) A list of account group IDs associated with the collection.
    accountIds List<String>
    (Optional) A list of cloud account IDs associated with the collection.
    repositoryIds List<String>
    (Optional) A list of repository IDs associated with the collection.
    accountGroupIds string[]
    (Optional) A list of account group IDs associated with the collection.
    accountIds string[]
    (Optional) A list of cloud account IDs associated with the collection.
    repositoryIds string[]
    (Optional) A list of repository IDs associated with the collection.
    account_group_ids Sequence[str]
    (Optional) A list of account group IDs associated with the collection.
    account_ids Sequence[str]
    (Optional) A list of cloud account IDs associated with the collection.
    repository_ids Sequence[str]
    (Optional) A list of repository IDs associated with the collection.
    accountGroupIds List<String>
    (Optional) A list of account group IDs associated with the collection.
    accountIds List<String>
    (Optional) A list of cloud account IDs associated with the collection.
    repositoryIds List<String>
    (Optional) A list of repository IDs associated with the collection.

    Package Details

    Repository
    prismacloud paloaltonetworks/terraform-provider-prismacloud
    License
    Notes
    This Pulumi package is based on the prismacloud Terraform Provider.
    prismacloud logo
    prismacloud 1.7.0 published on Monday, Apr 14, 2025 by paloaltonetworks