ibm.EnDestinationPagerduty
Explore with Pulumi AI
Create, update, or delete a pagerduty destination by using IBM Cloud™ Event Notifications.
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as ibm from "@pulumi/ibm";
const pagerdutyEnDestination = new ibm.EnDestinationPagerduty("pagerdutyEnDestination", {
instanceGuid: ibm_resource_instance.en_terraform_test_resource.guid,
type: "pagerduty",
collectFailedEvents: false,
description: "Destination pagerduty for event notification",
config: {
params: {
apiKey: "user token for assigned group",
routingKey: "integration key for pagerduty",
},
},
});
import pulumi
import pulumi_ibm as ibm
pagerduty_en_destination = ibm.EnDestinationPagerduty("pagerdutyEnDestination",
instance_guid=ibm_resource_instance["en_terraform_test_resource"]["guid"],
type="pagerduty",
collect_failed_events=False,
description="Destination pagerduty for event notification",
config={
"params": {
"api_key": "user token for assigned group",
"routing_key": "integration key for pagerduty",
},
})
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.NewEnDestinationPagerduty(ctx, "pagerdutyEnDestination", &ibm.EnDestinationPagerdutyArgs{
InstanceGuid: pulumi.Any(ibm_resource_instance.En_terraform_test_resource.Guid),
Type: pulumi.String("pagerduty"),
CollectFailedEvents: pulumi.Bool(false),
Description: pulumi.String("Destination pagerduty for event notification"),
Config: &ibm.EnDestinationPagerdutyConfigArgs{
Params: &ibm.EnDestinationPagerdutyConfigParamsArgs{
ApiKey: pulumi.String("user token for assigned group"),
RoutingKey: pulumi.String("integration key for pagerduty"),
},
},
})
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 pagerdutyEnDestination = new Ibm.EnDestinationPagerduty("pagerdutyEnDestination", new()
{
InstanceGuid = ibm_resource_instance.En_terraform_test_resource.Guid,
Type = "pagerduty",
CollectFailedEvents = false,
Description = "Destination pagerduty for event notification",
Config = new Ibm.Inputs.EnDestinationPagerdutyConfigArgs
{
Params = new Ibm.Inputs.EnDestinationPagerdutyConfigParamsArgs
{
ApiKey = "user token for assigned group",
RoutingKey = "integration key for pagerduty",
},
},
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.ibm.EnDestinationPagerduty;
import com.pulumi.ibm.EnDestinationPagerdutyArgs;
import com.pulumi.ibm.inputs.EnDestinationPagerdutyConfigArgs;
import com.pulumi.ibm.inputs.EnDestinationPagerdutyConfigParamsArgs;
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 pagerdutyEnDestination = new EnDestinationPagerduty("pagerdutyEnDestination", EnDestinationPagerdutyArgs.builder()
.instanceGuid(ibm_resource_instance.en_terraform_test_resource().guid())
.type("pagerduty")
.collectFailedEvents(false)
.description("Destination pagerduty for event notification")
.config(EnDestinationPagerdutyConfigArgs.builder()
.params(EnDestinationPagerdutyConfigParamsArgs.builder()
.apiKey("user token for assigned group")
.routingKey("integration key for pagerduty")
.build())
.build())
.build());
}
}
resources:
pagerdutyEnDestination:
type: ibm:EnDestinationPagerduty
properties:
instanceGuid: ${ibm_resource_instance.en_terraform_test_resource.guid}
type: pagerduty
collectFailedEvents: false
description: Destination pagerduty for event notification
config:
params:
apiKey: user token for assigned group
routingKey: integration key for pagerduty
Create EnDestinationPagerduty Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new EnDestinationPagerduty(name: string, args: EnDestinationPagerdutyArgs, opts?: CustomResourceOptions);
@overload
def EnDestinationPagerduty(resource_name: str,
args: EnDestinationPagerdutyArgs,
opts: Optional[ResourceOptions] = None)
@overload
def EnDestinationPagerduty(resource_name: str,
opts: Optional[ResourceOptions] = None,
config: Optional[EnDestinationPagerdutyConfigArgs] = None,
instance_guid: Optional[str] = None,
type: Optional[str] = None,
collect_failed_events: Optional[bool] = None,
description: Optional[str] = None,
en_destination_pagerduty_id: Optional[str] = None,
name: Optional[str] = None)
func NewEnDestinationPagerduty(ctx *Context, name string, args EnDestinationPagerdutyArgs, opts ...ResourceOption) (*EnDestinationPagerduty, error)
public EnDestinationPagerduty(string name, EnDestinationPagerdutyArgs args, CustomResourceOptions? opts = null)
public EnDestinationPagerduty(String name, EnDestinationPagerdutyArgs args)
public EnDestinationPagerduty(String name, EnDestinationPagerdutyArgs args, CustomResourceOptions options)
type: ibm:EnDestinationPagerduty
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 EnDestinationPagerdutyArgs
- 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 EnDestinationPagerdutyArgs
- 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 EnDestinationPagerdutyArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args EnDestinationPagerdutyArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args EnDestinationPagerdutyArgs
- 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 enDestinationPagerdutyResource = new Ibm.EnDestinationPagerduty("enDestinationPagerdutyResource", new()
{
Config = new Ibm.Inputs.EnDestinationPagerdutyConfigArgs
{
Params = new Ibm.Inputs.EnDestinationPagerdutyConfigParamsArgs
{
RoutingKey = "string",
},
},
InstanceGuid = "string",
Type = "string",
CollectFailedEvents = false,
Description = "string",
EnDestinationPagerdutyId = "string",
Name = "string",
});
example, err := ibm.NewEnDestinationPagerduty(ctx, "enDestinationPagerdutyResource", &ibm.EnDestinationPagerdutyArgs{
Config: &ibm.EnDestinationPagerdutyConfigArgs{
Params: &ibm.EnDestinationPagerdutyConfigParamsArgs{
RoutingKey: pulumi.String("string"),
},
},
InstanceGuid: pulumi.String("string"),
Type: pulumi.String("string"),
CollectFailedEvents: pulumi.Bool(false),
Description: pulumi.String("string"),
EnDestinationPagerdutyId: pulumi.String("string"),
Name: pulumi.String("string"),
})
var enDestinationPagerdutyResource = new EnDestinationPagerduty("enDestinationPagerdutyResource", EnDestinationPagerdutyArgs.builder()
.config(EnDestinationPagerdutyConfigArgs.builder()
.params(EnDestinationPagerdutyConfigParamsArgs.builder()
.routingKey("string")
.build())
.build())
.instanceGuid("string")
.type("string")
.collectFailedEvents(false)
.description("string")
.enDestinationPagerdutyId("string")
.name("string")
.build());
en_destination_pagerduty_resource = ibm.EnDestinationPagerduty("enDestinationPagerdutyResource",
config={
"params": {
"routing_key": "string",
},
},
instance_guid="string",
type="string",
collect_failed_events=False,
description="string",
en_destination_pagerduty_id="string",
name="string")
const enDestinationPagerdutyResource = new ibm.EnDestinationPagerduty("enDestinationPagerdutyResource", {
config: {
params: {
routingKey: "string",
},
},
instanceGuid: "string",
type: "string",
collectFailedEvents: false,
description: "string",
enDestinationPagerdutyId: "string",
name: "string",
});
type: ibm:EnDestinationPagerduty
properties:
collectFailedEvents: false
config:
params:
routingKey: string
description: string
enDestinationPagerdutyId: string
instanceGuid: string
name: string
type: string
EnDestinationPagerduty 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 EnDestinationPagerduty resource accepts the following input properties:
- Config
En
Destination Pagerduty Config Payload describing a destination configuration.
Nested scheme for config:
- Instance
Guid string - Unique identifier for IBM Cloud Event Notifications instance.
- Type string
- pagerduty.
- Collect
Failed boolEvents - Toggle switch to enable collect failed event in Cloud Object Storage bucket.
- Description string
- The Destination description.
- En
Destination stringPagerduty Id - (String) The unique identifier of the
pagerduty_en_destination
. - Name string
- The Destintion name.
- Config
En
Destination Pagerduty Config Args Payload describing a destination configuration.
Nested scheme for config:
- Instance
Guid string - Unique identifier for IBM Cloud Event Notifications instance.
- Type string
- pagerduty.
- Collect
Failed boolEvents - Toggle switch to enable collect failed event in Cloud Object Storage bucket.
- Description string
- The Destination description.
- En
Destination stringPagerduty Id - (String) The unique identifier of the
pagerduty_en_destination
. - Name string
- The Destintion name.
- config
En
Destination Pagerduty Config Payload describing a destination configuration.
Nested scheme for config:
- instance
Guid String - Unique identifier for IBM Cloud Event Notifications instance.
- type String
- pagerduty.
- collect
Failed BooleanEvents - Toggle switch to enable collect failed event in Cloud Object Storage bucket.
- description String
- The Destination description.
- en
Destination StringPagerduty Id - (String) The unique identifier of the
pagerduty_en_destination
. - name String
- The Destintion name.
- config
En
Destination Pagerduty Config Payload describing a destination configuration.
Nested scheme for config:
- instance
Guid string - Unique identifier for IBM Cloud Event Notifications instance.
- type string
- pagerduty.
- collect
Failed booleanEvents - Toggle switch to enable collect failed event in Cloud Object Storage bucket.
- description string
- The Destination description.
- en
Destination stringPagerduty Id - (String) The unique identifier of the
pagerduty_en_destination
. - name string
- The Destintion name.
- config
En
Destination Pagerduty Config Args Payload describing a destination configuration.
Nested scheme for config:
- instance_
guid str - Unique identifier for IBM Cloud Event Notifications instance.
- type str
- pagerduty.
- collect_
failed_ boolevents - Toggle switch to enable collect failed event in Cloud Object Storage bucket.
- description str
- The Destination description.
- en_
destination_ strpagerduty_ id - (String) The unique identifier of the
pagerduty_en_destination
. - name str
- The Destintion name.
- config Property Map
Payload describing a destination configuration.
Nested scheme for config:
- instance
Guid String - Unique identifier for IBM Cloud Event Notifications instance.
- type String
- pagerduty.
- collect
Failed BooleanEvents - Toggle switch to enable collect failed event in Cloud Object Storage bucket.
- description String
- The Destination description.
- en
Destination StringPagerduty Id - (String) The unique identifier of the
pagerduty_en_destination
. - name String
- The Destintion name.
Outputs
All input properties are implicitly available as output properties. Additionally, the EnDestinationPagerduty resource produces the following output properties:
- Destination
Id string - (String) The unique identifier of the created destination.
- Id string
- The provider-assigned unique ID for this managed resource.
- Subscription
Count double - (Integer) Number of subscriptions.
- Constraints: The minimum value is
0
.
- Constraints: The minimum value is
- Subscription
Names List<string> - (List) List of subscriptions.
- Updated
At string - (String) Last updated time.
- Destination
Id string - (String) The unique identifier of the created destination.
- Id string
- The provider-assigned unique ID for this managed resource.
- Subscription
Count float64 - (Integer) Number of subscriptions.
- Constraints: The minimum value is
0
.
- Constraints: The minimum value is
- Subscription
Names []string - (List) List of subscriptions.
- Updated
At string - (String) Last updated time.
- destination
Id String - (String) The unique identifier of the created destination.
- id String
- The provider-assigned unique ID for this managed resource.
- subscription
Count Double - (Integer) Number of subscriptions.
- Constraints: The minimum value is
0
.
- Constraints: The minimum value is
- subscription
Names List<String> - (List) List of subscriptions.
- updated
At String - (String) Last updated time.
- destination
Id string - (String) The unique identifier of the created destination.
- id string
- The provider-assigned unique ID for this managed resource.
- subscription
Count number - (Integer) Number of subscriptions.
- Constraints: The minimum value is
0
.
- Constraints: The minimum value is
- subscription
Names string[] - (List) List of subscriptions.
- updated
At 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
.
- Constraints: The minimum value is
- subscription_
names Sequence[str] - (List) List of subscriptions.
- updated_
at str - (String) Last updated time.
- destination
Id String - (String) The unique identifier of the created destination.
- id String
- The provider-assigned unique ID for this managed resource.
- subscription
Count Number - (Integer) Number of subscriptions.
- Constraints: The minimum value is
0
.
- Constraints: The minimum value is
- subscription
Names List<String> - (List) List of subscriptions.
- updated
At String - (String) Last updated time.
Look up Existing EnDestinationPagerduty Resource
Get an existing EnDestinationPagerduty 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?: EnDestinationPagerdutyState, opts?: CustomResourceOptions): EnDestinationPagerduty
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
collect_failed_events: Optional[bool] = None,
config: Optional[EnDestinationPagerdutyConfigArgs] = None,
description: Optional[str] = None,
destination_id: Optional[str] = None,
en_destination_pagerduty_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) -> EnDestinationPagerduty
func GetEnDestinationPagerduty(ctx *Context, name string, id IDInput, state *EnDestinationPagerdutyState, opts ...ResourceOption) (*EnDestinationPagerduty, error)
public static EnDestinationPagerduty Get(string name, Input<string> id, EnDestinationPagerdutyState? state, CustomResourceOptions? opts = null)
public static EnDestinationPagerduty get(String name, Output<String> id, EnDestinationPagerdutyState state, CustomResourceOptions options)
resources: _: type: ibm:EnDestinationPagerduty 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.
- Collect
Failed boolEvents - Toggle switch to enable collect failed event in Cloud Object Storage bucket.
- Config
En
Destination Pagerduty Config Payload describing a destination configuration.
Nested scheme for config:
- Description string
- The Destination description.
- Destination
Id string - (String) The unique identifier of the created destination.
- En
Destination stringPagerduty Id - (String) The unique identifier of the
pagerduty_en_destination
. - Instance
Guid string - Unique identifier for IBM Cloud Event Notifications instance.
- Name string
- The Destintion name.
- Subscription
Count double - (Integer) Number of subscriptions.
- Constraints: The minimum value is
0
.
- Constraints: The minimum value is
- Subscription
Names List<string> - (List) List of subscriptions.
- Type string
- pagerduty.
- Updated
At string - (String) Last updated time.
- Collect
Failed boolEvents - Toggle switch to enable collect failed event in Cloud Object Storage bucket.
- Config
En
Destination Pagerduty Config Args Payload describing a destination configuration.
Nested scheme for config:
- Description string
- The Destination description.
- Destination
Id string - (String) The unique identifier of the created destination.
- En
Destination stringPagerduty Id - (String) The unique identifier of the
pagerduty_en_destination
. - Instance
Guid string - Unique identifier for IBM Cloud Event Notifications instance.
- Name string
- The Destintion name.
- Subscription
Count float64 - (Integer) Number of subscriptions.
- Constraints: The minimum value is
0
.
- Constraints: The minimum value is
- Subscription
Names []string - (List) List of subscriptions.
- Type string
- pagerduty.
- Updated
At string - (String) Last updated time.
- collect
Failed BooleanEvents - Toggle switch to enable collect failed event in Cloud Object Storage bucket.
- config
En
Destination Pagerduty Config Payload describing a destination configuration.
Nested scheme for config:
- description String
- The Destination description.
- destination
Id String - (String) The unique identifier of the created destination.
- en
Destination StringPagerduty Id - (String) The unique identifier of the
pagerduty_en_destination
. - instance
Guid String - Unique identifier for IBM Cloud Event Notifications instance.
- name String
- The Destintion name.
- subscription
Count Double - (Integer) Number of subscriptions.
- Constraints: The minimum value is
0
.
- Constraints: The minimum value is
- subscription
Names List<String> - (List) List of subscriptions.
- type String
- pagerduty.
- updated
At String - (String) Last updated time.
- collect
Failed booleanEvents - Toggle switch to enable collect failed event in Cloud Object Storage bucket.
- config
En
Destination Pagerduty Config Payload describing a destination configuration.
Nested scheme for config:
- description string
- The Destination description.
- destination
Id string - (String) The unique identifier of the created destination.
- en
Destination stringPagerduty Id - (String) The unique identifier of the
pagerduty_en_destination
. - instance
Guid string - Unique identifier for IBM Cloud Event Notifications instance.
- name string
- The Destintion name.
- subscription
Count number - (Integer) Number of subscriptions.
- Constraints: The minimum value is
0
.
- Constraints: The minimum value is
- subscription
Names string[] - (List) List of subscriptions.
- type string
- pagerduty.
- updated
At string - (String) Last updated time.
- collect_
failed_ boolevents - Toggle switch to enable collect failed event in Cloud Object Storage bucket.
- config
En
Destination Pagerduty Config Args 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_ strpagerduty_ id - (String) The unique identifier of the
pagerduty_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
.
- Constraints: The minimum value is
- subscription_
names Sequence[str] - (List) List of subscriptions.
- type str
- pagerduty.
- updated_
at str - (String) Last updated time.
- collect
Failed BooleanEvents - 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.
- destination
Id String - (String) The unique identifier of the created destination.
- en
Destination StringPagerduty Id - (String) The unique identifier of the
pagerduty_en_destination
. - instance
Guid String - Unique identifier for IBM Cloud Event Notifications instance.
- name String
- The Destintion name.
- subscription
Count Number - (Integer) Number of subscriptions.
- Constraints: The minimum value is
0
.
- Constraints: The minimum value is
- subscription
Names List<String> - (List) List of subscriptions.
- type String
- pagerduty.
- updated
At String - (String) Last updated time.
Supporting Types
EnDestinationPagerdutyConfig, EnDestinationPagerdutyConfigArgs
- Params
En
Destination Pagerduty Config Params - Nested scheme for params:
- Params
En
Destination Pagerduty Config Params - Nested scheme for params:
- params
En
Destination Pagerduty Config Params - Nested scheme for params:
- params
En
Destination Pagerduty Config Params - Nested scheme for params:
- params
En
Destination Pagerduty Config Params - Nested scheme for params:
- params Property Map
- Nested scheme for params:
EnDestinationPagerdutyConfigParams, EnDestinationPagerdutyConfigParamsArgs
- Routing
Key string - Routing Key (Integration Key) for the team in PagerDuty account.
- Api
Key string - API Key for the PagerDuty account.
- Routing
Key string - Routing Key (Integration Key) for the team in PagerDuty account.
- Api
Key string - API Key for the PagerDuty account.
- routing
Key String - Routing Key (Integration Key) for the team in PagerDuty account.
- api
Key String - API Key for the PagerDuty account.
- routing
Key string - Routing Key (Integration Key) for the team in PagerDuty account.
- api
Key string - API Key for the PagerDuty account.
- routing_
key str - Routing Key (Integration Key) for the team in PagerDuty account.
- api_
key str - API Key for the PagerDuty account.
- routing
Key String - Routing Key (Integration Key) for the team in PagerDuty account.
- api
Key String - API Key for the PagerDuty account.
Import
You can import the ibm_en_destination_pagerduty
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/enDestinationPagerduty:EnDestinationPagerduty pagerduty_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.