1. Packages
  2. Incident Provider
  3. API Docs
  4. Severity
incident 5.4.2 published on Tuesday, Apr 22, 2025 by incident-io

incident.Severity

Explore with Pulumi AI

incident logo
incident 5.4.2 published on Tuesday, Apr 22, 2025 by incident-io

    Manage incident severities.

    Each incident has a severity, picked from one of the severities configured in your organisations settings.

    Severities help categorise incidents, and communicate urgency/impact. You can use severities when filtering incidents in the dashboard, and in workflows and announcement rules.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as incident from "@pulumi/incident";
    
    // Create a Major severity with a default assigned rank.
    const trivial = new incident.Severity("trivial", {description: "Issues causing no impact. No Immediate response is required."});
    
    import pulumi
    import pulumi_incident as incident
    
    # Create a Major severity with a default assigned rank.
    trivial = incident.Severity("trivial", description="Issues causing no impact. No Immediate response is required.")
    
    package main
    
    import (
    	"github.com/pulumi/pulumi-terraform-provider/sdks/go/incident/v5/incident"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		// Create a Major severity with a default assigned rank.
    		_, err := incident.NewSeverity(ctx, "trivial", &incident.SeverityArgs{
    			Description: pulumi.String("Issues causing no impact. No Immediate response is required."),
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Incident = Pulumi.Incident;
    
    return await Deployment.RunAsync(() => 
    {
        // Create a Major severity with a default assigned rank.
        var trivial = new Incident.Severity("trivial", new()
        {
            Description = "Issues causing no impact. No Immediate response is required.",
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.incident.Severity;
    import com.pulumi.incident.SeverityArgs;
    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) {
            // Create a Major severity with a default assigned rank.
            var trivial = new Severity("trivial", SeverityArgs.builder()
                .description("Issues causing no impact. No Immediate response is required.")
                .build());
    
        }
    }
    
    resources:
      # Create a Major severity with a default assigned rank.
      trivial:
        type: incident:Severity
        properties:
          description: Issues causing no impact. No Immediate response is required.
    

    Create Severity Resource

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

    Constructor syntax

    new Severity(name: string, args: SeverityArgs, opts?: CustomResourceOptions);
    @overload
    def Severity(resource_name: str,
                 args: SeverityArgs,
                 opts: Optional[ResourceOptions] = None)
    
    @overload
    def Severity(resource_name: str,
                 opts: Optional[ResourceOptions] = None,
                 description: Optional[str] = None,
                 name: Optional[str] = None,
                 rank: Optional[float] = None)
    func NewSeverity(ctx *Context, name string, args SeverityArgs, opts ...ResourceOption) (*Severity, error)
    public Severity(string name, SeverityArgs args, CustomResourceOptions? opts = null)
    public Severity(String name, SeverityArgs args)
    public Severity(String name, SeverityArgs args, CustomResourceOptions options)
    
    type: incident:Severity
    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 SeverityArgs
    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 SeverityArgs
    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 SeverityArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args SeverityArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args SeverityArgs
    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 severityResource = new Incident.Severity("severityResource", new()
    {
        Description = "string",
        Name = "string",
        Rank = 0,
    });
    
    example, err := incident.NewSeverity(ctx, "severityResource", &incident.SeverityArgs{
    	Description: pulumi.String("string"),
    	Name:        pulumi.String("string"),
    	Rank:        pulumi.Float64(0),
    })
    
    var severityResource = new Severity("severityResource", SeverityArgs.builder()
        .description("string")
        .name("string")
        .rank(0)
        .build());
    
    severity_resource = incident.Severity("severityResource",
        description="string",
        name="string",
        rank=0)
    
    const severityResource = new incident.Severity("severityResource", {
        description: "string",
        name: "string",
        rank: 0,
    });
    
    type: incident:Severity
    properties:
        description: string
        name: string
        rank: 0
    

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

    Description string
    Description of the severity
    Name string
    Human readable name of the severity
    Rank double
    Rank to help sort severities (lower numbers are less severe)
    Description string
    Description of the severity
    Name string
    Human readable name of the severity
    Rank float64
    Rank to help sort severities (lower numbers are less severe)
    description String
    Description of the severity
    name String
    Human readable name of the severity
    rank Double
    Rank to help sort severities (lower numbers are less severe)
    description string
    Description of the severity
    name string
    Human readable name of the severity
    rank number
    Rank to help sort severities (lower numbers are less severe)
    description str
    Description of the severity
    name str
    Human readable name of the severity
    rank float
    Rank to help sort severities (lower numbers are less severe)
    description String
    Description of the severity
    name String
    Human readable name of the severity
    rank Number
    Rank to help sort severities (lower numbers are less severe)

    Outputs

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

    Id string
    The provider-assigned unique ID for this managed resource.
    Id string
    The provider-assigned unique ID for this managed resource.
    id String
    The provider-assigned unique ID for this managed resource.
    id string
    The provider-assigned unique ID for this managed resource.
    id str
    The provider-assigned unique ID for this managed resource.
    id String
    The provider-assigned unique ID for this managed resource.

    Look up Existing Severity Resource

    Get an existing Severity 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?: SeverityState, opts?: CustomResourceOptions): Severity
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            description: Optional[str] = None,
            name: Optional[str] = None,
            rank: Optional[float] = None) -> Severity
    func GetSeverity(ctx *Context, name string, id IDInput, state *SeverityState, opts ...ResourceOption) (*Severity, error)
    public static Severity Get(string name, Input<string> id, SeverityState? state, CustomResourceOptions? opts = null)
    public static Severity get(String name, Output<String> id, SeverityState state, CustomResourceOptions options)
    resources:  _:    type: incident:Severity    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:
    Description string
    Description of the severity
    Name string
    Human readable name of the severity
    Rank double
    Rank to help sort severities (lower numbers are less severe)
    Description string
    Description of the severity
    Name string
    Human readable name of the severity
    Rank float64
    Rank to help sort severities (lower numbers are less severe)
    description String
    Description of the severity
    name String
    Human readable name of the severity
    rank Double
    Rank to help sort severities (lower numbers are less severe)
    description string
    Description of the severity
    name string
    Human readable name of the severity
    rank number
    Rank to help sort severities (lower numbers are less severe)
    description str
    Description of the severity
    name str
    Human readable name of the severity
    rank float
    Rank to help sort severities (lower numbers are less severe)
    description String
    Description of the severity
    name String
    Human readable name of the severity
    rank Number
    Rank to help sort severities (lower numbers are less severe)

    Import

    #!/bin/bash

    Import a severity using its ID

    Replace the ID with a real ID from your incident.io organization

    $ pulumi import incident:index/severity:Severity example 01ABC123DEF456GHI789JKL
    

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

    Package Details

    Repository
    incident incident-io/terraform-provider-incident
    License
    Notes
    This Pulumi package is based on the incident Terraform Provider.
    incident logo
    incident 5.4.2 published on Tuesday, Apr 22, 2025 by incident-io