1. Packages
  2. Ibm Provider
  3. API Docs
  4. EnDestinationCos
ibm 1.78.0 published on Wednesday, Apr 30, 2025 by ibm-cloud

ibm.EnDestinationCos

Explore with Pulumi AI

ibm logo
ibm 1.78.0 published on Wednesday, Apr 30, 2025 by ibm-cloud

    Create, update, or delete a IBM Cloud Object Storage destination by using IBM Cloud™ Event Notifications.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as ibm from "@pulumi/ibm";
    
    const cosEnDestination = new ibm.EnDestinationCos("cosEnDestination", {
        instanceGuid: ibm_resource_instance.en_terraform_test_resource.guid,
        type: "ibmcos",
        collectFailedEvents: true,
        description: "IBM Cloud Object Storage Destination for event notification",
        config: {
            params: {
                bucketName: "cos-test-bucket",
                instanceId: "1f7avhy78-3ehu-4d02-b123-8297333e0748399",
                endpoint: "https://s3.us-east.cloud-object-storage.appdomain.cloud",
            },
        },
    });
    
    import pulumi
    import pulumi_ibm as ibm
    
    cos_en_destination = ibm.EnDestinationCos("cosEnDestination",
        instance_guid=ibm_resource_instance["en_terraform_test_resource"]["guid"],
        type="ibmcos",
        collect_failed_events=True,
        description="IBM Cloud Object Storage Destination for event notification",
        config={
            "params": {
                "bucket_name": "cos-test-bucket",
                "instance_id": "1f7avhy78-3ehu-4d02-b123-8297333e0748399",
                "endpoint": "https://s3.us-east.cloud-object-storage.appdomain.cloud",
            },
        })
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-terraform-provider/sdks/go/ibm/ibm"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		_, err := ibm.NewEnDestinationCos(ctx, "cosEnDestination", &ibm.EnDestinationCosArgs{
    			InstanceGuid:        pulumi.Any(ibm_resource_instance.En_terraform_test_resource.Guid),
    			Type:                pulumi.String("ibmcos"),
    			CollectFailedEvents: pulumi.Bool(true),
    			Description:         pulumi.String("IBM Cloud Object Storage Destination for event notification"),
    			Config: &ibm.EnDestinationCosConfigArgs{
    				Params: &ibm.EnDestinationCosConfigParamsArgs{
    					BucketName: pulumi.String("cos-test-bucket"),
    					InstanceId: pulumi.String("1f7avhy78-3ehu-4d02-b123-8297333e0748399"),
    					Endpoint:   pulumi.String("https://s3.us-east.cloud-object-storage.appdomain.cloud"),
    				},
    			},
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Ibm = Pulumi.Ibm;
    
    return await Deployment.RunAsync(() => 
    {
        var cosEnDestination = new Ibm.EnDestinationCos("cosEnDestination", new()
        {
            InstanceGuid = ibm_resource_instance.En_terraform_test_resource.Guid,
            Type = "ibmcos",
            CollectFailedEvents = true,
            Description = "IBM Cloud Object Storage Destination for event notification",
            Config = new Ibm.Inputs.EnDestinationCosConfigArgs
            {
                Params = new Ibm.Inputs.EnDestinationCosConfigParamsArgs
                {
                    BucketName = "cos-test-bucket",
                    InstanceId = "1f7avhy78-3ehu-4d02-b123-8297333e0748399",
                    Endpoint = "https://s3.us-east.cloud-object-storage.appdomain.cloud",
                },
            },
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.ibm.EnDestinationCos;
    import com.pulumi.ibm.EnDestinationCosArgs;
    import com.pulumi.ibm.inputs.EnDestinationCosConfigArgs;
    import com.pulumi.ibm.inputs.EnDestinationCosConfigParamsArgs;
    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 cosEnDestination = new EnDestinationCos("cosEnDestination", EnDestinationCosArgs.builder()
                .instanceGuid(ibm_resource_instance.en_terraform_test_resource().guid())
                .type("ibmcos")
                .collectFailedEvents(true)
                .description("IBM Cloud Object Storage Destination for event notification")
                .config(EnDestinationCosConfigArgs.builder()
                    .params(EnDestinationCosConfigParamsArgs.builder()
                        .bucketName("cos-test-bucket")
                        .instanceId("1f7avhy78-3ehu-4d02-b123-8297333e0748399")
                        .endpoint("https://s3.us-east.cloud-object-storage.appdomain.cloud")
                        .build())
                    .build())
                .build());
    
        }
    }
    
    resources:
      cosEnDestination:
        type: ibm:EnDestinationCos
        properties:
          instanceGuid: ${ibm_resource_instance.en_terraform_test_resource.guid}
          type: ibmcos
          collectFailedEvents: true
          description: IBM Cloud Object Storage Destination for event notification
          config:
            params:
              bucketName: cos-test-bucket
              instanceId: 1f7avhy78-3ehu-4d02-b123-8297333e0748399
              endpoint: https://s3.us-east.cloud-object-storage.appdomain.cloud
    

    Create EnDestinationCos Resource

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

    Constructor syntax

    new EnDestinationCos(name: string, args: EnDestinationCosArgs, opts?: CustomResourceOptions);
    @overload
    def EnDestinationCos(resource_name: str,
                         args: EnDestinationCosArgs,
                         opts: Optional[ResourceOptions] = None)
    
    @overload
    def EnDestinationCos(resource_name: str,
                         opts: Optional[ResourceOptions] = None,
                         instance_guid: Optional[str] = None,
                         type: Optional[str] = None,
                         collect_failed_events: Optional[bool] = None,
                         config: Optional[EnDestinationCosConfigArgs] = None,
                         description: Optional[str] = None,
                         en_destination_cos_id: Optional[str] = None,
                         name: Optional[str] = None)
    func NewEnDestinationCos(ctx *Context, name string, args EnDestinationCosArgs, opts ...ResourceOption) (*EnDestinationCos, error)
    public EnDestinationCos(string name, EnDestinationCosArgs args, CustomResourceOptions? opts = null)
    public EnDestinationCos(String name, EnDestinationCosArgs args)
    public EnDestinationCos(String name, EnDestinationCosArgs args, CustomResourceOptions options)
    
    type: ibm:EnDestinationCos
    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 EnDestinationCosArgs
    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 EnDestinationCosArgs
    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 EnDestinationCosArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args EnDestinationCosArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args EnDestinationCosArgs
    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 enDestinationCosResource = new Ibm.EnDestinationCos("enDestinationCosResource", new()
    {
        InstanceGuid = "string",
        Type = "string",
        CollectFailedEvents = false,
        Config = new Ibm.Inputs.EnDestinationCosConfigArgs
        {
            Params = new Ibm.Inputs.EnDestinationCosConfigParamsArgs
            {
                BucketName = "string",
                InstanceId = "string",
                Endpoint = "string",
            },
        },
        Description = "string",
        EnDestinationCosId = "string",
        Name = "string",
    });
    
    example, err := ibm.NewEnDestinationCos(ctx, "enDestinationCosResource", &ibm.EnDestinationCosArgs{
    	InstanceGuid:        pulumi.String("string"),
    	Type:                pulumi.String("string"),
    	CollectFailedEvents: pulumi.Bool(false),
    	Config: &ibm.EnDestinationCosConfigArgs{
    		Params: &ibm.EnDestinationCosConfigParamsArgs{
    			BucketName: pulumi.String("string"),
    			InstanceId: pulumi.String("string"),
    			Endpoint:   pulumi.String("string"),
    		},
    	},
    	Description:        pulumi.String("string"),
    	EnDestinationCosId: pulumi.String("string"),
    	Name:               pulumi.String("string"),
    })
    
    var enDestinationCosResource = new EnDestinationCos("enDestinationCosResource", EnDestinationCosArgs.builder()
        .instanceGuid("string")
        .type("string")
        .collectFailedEvents(false)
        .config(EnDestinationCosConfigArgs.builder()
            .params(EnDestinationCosConfigParamsArgs.builder()
                .bucketName("string")
                .instanceId("string")
                .endpoint("string")
                .build())
            .build())
        .description("string")
        .enDestinationCosId("string")
        .name("string")
        .build());
    
    en_destination_cos_resource = ibm.EnDestinationCos("enDestinationCosResource",
        instance_guid="string",
        type="string",
        collect_failed_events=False,
        config={
            "params": {
                "bucket_name": "string",
                "instance_id": "string",
                "endpoint": "string",
            },
        },
        description="string",
        en_destination_cos_id="string",
        name="string")
    
    const enDestinationCosResource = new ibm.EnDestinationCos("enDestinationCosResource", {
        instanceGuid: "string",
        type: "string",
        collectFailedEvents: false,
        config: {
            params: {
                bucketName: "string",
                instanceId: "string",
                endpoint: "string",
            },
        },
        description: "string",
        enDestinationCosId: "string",
        name: "string",
    });
    
    type: ibm:EnDestinationCos
    properties:
        collectFailedEvents: false
        config:
            params:
                bucketName: string
                endpoint: string
                instanceId: string
        description: string
        enDestinationCosId: string
        instanceGuid: string
        name: string
        type: string
    

    EnDestinationCos 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 EnDestinationCos resource accepts the following input properties:

    InstanceGuid string
    Unique identifier for IBM Cloud Event Notifications instance.
    Type string
    ibmcos.
    CollectFailedEvents bool
    Toggle switch to enable collect failed event in Cloud Object Storage bucket.
    Config EnDestinationCosConfig

    Payload describing a destination configuration.

    Nested scheme for config:

    Description string
    The Destination description.
    EnDestinationCosId string
    (String) The unique identifier of the cos_en_destination.
    Name string
    The Destintion name.
    InstanceGuid string
    Unique identifier for IBM Cloud Event Notifications instance.
    Type string
    ibmcos.
    CollectFailedEvents bool
    Toggle switch to enable collect failed event in Cloud Object Storage bucket.
    Config EnDestinationCosConfigArgs

    Payload describing a destination configuration.

    Nested scheme for config:

    Description string
    The Destination description.
    EnDestinationCosId string
    (String) The unique identifier of the cos_en_destination.
    Name string
    The Destintion name.
    instanceGuid String
    Unique identifier for IBM Cloud Event Notifications instance.
    type String
    ibmcos.
    collectFailedEvents Boolean
    Toggle switch to enable collect failed event in Cloud Object Storage bucket.
    config EnDestinationCosConfig

    Payload describing a destination configuration.

    Nested scheme for config:

    description String
    The Destination description.
    enDestinationCosId String
    (String) The unique identifier of the cos_en_destination.
    name String
    The Destintion name.
    instanceGuid string
    Unique identifier for IBM Cloud Event Notifications instance.
    type string
    ibmcos.
    collectFailedEvents boolean
    Toggle switch to enable collect failed event in Cloud Object Storage bucket.
    config EnDestinationCosConfig

    Payload describing a destination configuration.

    Nested scheme for config:

    description string
    The Destination description.
    enDestinationCosId string
    (String) The unique identifier of the cos_en_destination.
    name string
    The Destintion name.
    instance_guid str
    Unique identifier for IBM Cloud Event Notifications instance.
    type str
    ibmcos.
    collect_failed_events bool
    Toggle switch to enable collect failed event in Cloud Object Storage bucket.
    config EnDestinationCosConfigArgs

    Payload describing a destination configuration.

    Nested scheme for config:

    description str
    The Destination description.
    en_destination_cos_id str
    (String) The unique identifier of the cos_en_destination.
    name str
    The Destintion name.
    instanceGuid String
    Unique identifier for IBM Cloud Event Notifications instance.
    type String
    ibmcos.
    collectFailedEvents Boolean
    Toggle switch to enable collect failed event in Cloud Object Storage bucket.
    config Property Map

    Payload describing a destination configuration.

    Nested scheme for config:

    description String
    The Destination description.
    enDestinationCosId String
    (String) The unique identifier of the cos_en_destination.
    name String
    The Destintion name.

    Outputs

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

    DestinationId string
    (String) The unique identifier of the created destination.
    Id string
    The provider-assigned unique ID for this managed resource.
    SubscriptionCount double
    (Integer) Number of subscriptions.

    • Constraints: The minimum value is 0.
    SubscriptionNames List<string>
    (List) List of subscriptions.
    UpdatedAt string
    (String) Last updated time.
    DestinationId string
    (String) The unique identifier of the created destination.
    Id string
    The provider-assigned unique ID for this managed resource.
    SubscriptionCount float64
    (Integer) Number of subscriptions.

    • Constraints: The minimum value is 0.
    SubscriptionNames []string
    (List) List of subscriptions.
    UpdatedAt string
    (String) Last updated time.
    destinationId String
    (String) The unique identifier of the created destination.
    id String
    The provider-assigned unique ID for this managed resource.
    subscriptionCount Double
    (Integer) Number of subscriptions.

    • Constraints: The minimum value is 0.
    subscriptionNames List<String>
    (List) List of subscriptions.
    updatedAt String
    (String) Last updated time.
    destinationId string
    (String) The unique identifier of the created destination.
    id string
    The provider-assigned unique ID for this managed resource.
    subscriptionCount number
    (Integer) Number of subscriptions.

    • Constraints: The minimum value is 0.
    subscriptionNames string[]
    (List) List of subscriptions.
    updatedAt string
    (String) Last updated time.
    destination_id str
    (String) The unique identifier of the created destination.
    id str
    The provider-assigned unique ID for this managed resource.
    subscription_count float
    (Integer) Number of subscriptions.

    • Constraints: The minimum value is 0.
    subscription_names Sequence[str]
    (List) List of subscriptions.
    updated_at str
    (String) Last updated time.
    destinationId String
    (String) The unique identifier of the created destination.
    id String
    The provider-assigned unique ID for this managed resource.
    subscriptionCount Number
    (Integer) Number of subscriptions.

    • Constraints: The minimum value is 0.
    subscriptionNames List<String>
    (List) List of subscriptions.
    updatedAt String
    (String) Last updated time.

    Look up Existing EnDestinationCos Resource

    Get an existing EnDestinationCos 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?: EnDestinationCosState, opts?: CustomResourceOptions): EnDestinationCos
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            collect_failed_events: Optional[bool] = None,
            config: Optional[EnDestinationCosConfigArgs] = None,
            description: Optional[str] = None,
            destination_id: Optional[str] = None,
            en_destination_cos_id: Optional[str] = None,
            instance_guid: Optional[str] = None,
            name: Optional[str] = None,
            subscription_count: Optional[float] = None,
            subscription_names: Optional[Sequence[str]] = None,
            type: Optional[str] = None,
            updated_at: Optional[str] = None) -> EnDestinationCos
    func GetEnDestinationCos(ctx *Context, name string, id IDInput, state *EnDestinationCosState, opts ...ResourceOption) (*EnDestinationCos, error)
    public static EnDestinationCos Get(string name, Input<string> id, EnDestinationCosState? state, CustomResourceOptions? opts = null)
    public static EnDestinationCos get(String name, Output<String> id, EnDestinationCosState state, CustomResourceOptions options)
    resources:  _:    type: ibm:EnDestinationCos    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:
    CollectFailedEvents bool
    Toggle switch to enable collect failed event in Cloud Object Storage bucket.
    Config EnDestinationCosConfig

    Payload describing a destination configuration.

    Nested scheme for config:

    Description string
    The Destination description.
    DestinationId string
    (String) The unique identifier of the created destination.
    EnDestinationCosId string
    (String) The unique identifier of the cos_en_destination.
    InstanceGuid string
    Unique identifier for IBM Cloud Event Notifications instance.
    Name string
    The Destintion name.
    SubscriptionCount double
    (Integer) Number of subscriptions.

    • Constraints: The minimum value is 0.
    SubscriptionNames List<string>
    (List) List of subscriptions.
    Type string
    ibmcos.
    UpdatedAt string
    (String) Last updated time.
    CollectFailedEvents bool
    Toggle switch to enable collect failed event in Cloud Object Storage bucket.
    Config EnDestinationCosConfigArgs

    Payload describing a destination configuration.

    Nested scheme for config:

    Description string
    The Destination description.
    DestinationId string
    (String) The unique identifier of the created destination.
    EnDestinationCosId string
    (String) The unique identifier of the cos_en_destination.
    InstanceGuid string
    Unique identifier for IBM Cloud Event Notifications instance.
    Name string
    The Destintion name.
    SubscriptionCount float64
    (Integer) Number of subscriptions.

    • Constraints: The minimum value is 0.
    SubscriptionNames []string
    (List) List of subscriptions.
    Type string
    ibmcos.
    UpdatedAt string
    (String) Last updated time.
    collectFailedEvents Boolean
    Toggle switch to enable collect failed event in Cloud Object Storage bucket.
    config EnDestinationCosConfig

    Payload describing a destination configuration.

    Nested scheme for config:

    description String
    The Destination description.
    destinationId String
    (String) The unique identifier of the created destination.
    enDestinationCosId String
    (String) The unique identifier of the cos_en_destination.
    instanceGuid String
    Unique identifier for IBM Cloud Event Notifications instance.
    name String
    The Destintion name.
    subscriptionCount Double
    (Integer) Number of subscriptions.

    • Constraints: The minimum value is 0.
    subscriptionNames List<String>
    (List) List of subscriptions.
    type String
    ibmcos.
    updatedAt String
    (String) Last updated time.
    collectFailedEvents boolean
    Toggle switch to enable collect failed event in Cloud Object Storage bucket.
    config EnDestinationCosConfig

    Payload describing a destination configuration.

    Nested scheme for config:

    description string
    The Destination description.
    destinationId string
    (String) The unique identifier of the created destination.
    enDestinationCosId string
    (String) The unique identifier of the cos_en_destination.
    instanceGuid string
    Unique identifier for IBM Cloud Event Notifications instance.
    name string
    The Destintion name.
    subscriptionCount number
    (Integer) Number of subscriptions.

    • Constraints: The minimum value is 0.
    subscriptionNames string[]
    (List) List of subscriptions.
    type string
    ibmcos.
    updatedAt string
    (String) Last updated time.
    collect_failed_events bool
    Toggle switch to enable collect failed event in Cloud Object Storage bucket.
    config EnDestinationCosConfigArgs

    Payload describing a destination configuration.

    Nested scheme for config:

    description str
    The Destination description.
    destination_id str
    (String) The unique identifier of the created destination.
    en_destination_cos_id str
    (String) The unique identifier of the cos_en_destination.
    instance_guid str
    Unique identifier for IBM Cloud Event Notifications instance.
    name str
    The Destintion name.
    subscription_count float
    (Integer) Number of subscriptions.

    • Constraints: The minimum value is 0.
    subscription_names Sequence[str]
    (List) List of subscriptions.
    type str
    ibmcos.
    updated_at str
    (String) Last updated time.
    collectFailedEvents Boolean
    Toggle switch to enable collect failed event in Cloud Object Storage bucket.
    config Property Map

    Payload describing a destination configuration.

    Nested scheme for config:

    description String
    The Destination description.
    destinationId String
    (String) The unique identifier of the created destination.
    enDestinationCosId String
    (String) The unique identifier of the cos_en_destination.
    instanceGuid String
    Unique identifier for IBM Cloud Event Notifications instance.
    name String
    The Destintion name.
    subscriptionCount Number
    (Integer) Number of subscriptions.

    • Constraints: The minimum value is 0.
    subscriptionNames List<String>
    (List) List of subscriptions.
    type String
    ibmcos.
    updatedAt String
    (String) Last updated time.

    Supporting Types

    EnDestinationCosConfig, EnDestinationCosConfigArgs

    Params EnDestinationCosConfigParams
    Nested scheme for params:
    Params EnDestinationCosConfigParams
    Nested scheme for params:
    params EnDestinationCosConfigParams
    Nested scheme for params:
    params EnDestinationCosConfigParams
    Nested scheme for params:
    params EnDestinationCosConfigParams
    Nested scheme for params:
    params Property Map
    Nested scheme for params:

    EnDestinationCosConfigParams, EnDestinationCosConfigParamsArgs

    BucketName string
    The COS bucket name
    InstanceId string
    The instance id for COS instance
    Endpoint string
    The endpoint for the COS bucket endpoint
    BucketName string
    The COS bucket name
    InstanceId string
    The instance id for COS instance
    Endpoint string
    The endpoint for the COS bucket endpoint
    bucketName String
    The COS bucket name
    instanceId String
    The instance id for COS instance
    endpoint String
    The endpoint for the COS bucket endpoint
    bucketName string
    The COS bucket name
    instanceId string
    The instance id for COS instance
    endpoint string
    The endpoint for the COS bucket endpoint
    bucket_name str
    The COS bucket name
    instance_id str
    The instance id for COS instance
    endpoint str
    The endpoint for the COS bucket endpoint
    bucketName String
    The COS bucket name
    instanceId String
    The instance id for COS instance
    endpoint String
    The endpoint for the COS bucket endpoint

    Import

    You can import the ibm_en_destination_cos resource by using id.

    The id property can be formed from instance_guid, and destination_id in the following format:

    <instance_guid>/<destination_id>

    • instance_guid: A string. Unique identifier for IBM Cloud Event Notifications instance.

    • destination_id: A string. Unique identifier for Destination.

    Example

    $ pulumi import ibm:index/enDestinationCos:EnDestinationCos cos_en_destination <instance_guid>/<destination_id>
    

    To learn more about importing existing cloud resources, see Importing resources.

    Package Details

    Repository
    ibm ibm-cloud/terraform-provider-ibm
    License
    Notes
    This Pulumi package is based on the ibm Terraform Provider.
    ibm logo
    ibm 1.78.0 published on Wednesday, Apr 30, 2025 by ibm-cloud