1. Packages
  2. Incident Provider
  3. API Docs
  4. CatalogTypeAttribute
incident 5.5.0 published on Wednesday, Apr 30, 2025 by incident-io

incident.CatalogTypeAttribute

Explore with Pulumi AI

incident logo
incident 5.5.0 published on Wednesday, Apr 30, 2025 by incident-io

    Manage and browse catalog resources.

    Use the incident.io catalog to track services, teams, product features and anything else that helps build a map of your organisation. These different categories of thing become catalog types, and each instance (like a particular service or team) is a catalog entry.

    Each type is made up of a series of attributes, and each attribute has a type. Types can even have attributes that refer to other catalog types.

    We automatically create catalog types when you connect an integration, such as GitHub repositories or PagerDuty services and teams. You can use this API to create custom types, that are specifically tailored to your organisation.

    Examples might be a ‘Service’ type with an ‘Alert channel’ which you can point at a Slack channel, or ‘Team’ which specifies its ‘Manager’ and ‘Technical Lead’ as Slack users. You can then use these types to create powerful new workflows.

    Consider using our official catalog importer. It can be used to sync catalog data from sources like local files or GitHub and push them into the incident.io catalog without having to directly interact with our public API.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as incident from "@pulumi/incident";
    
    const service = new incident.CatalogType("service", {description: "All services that we run across our product"});
    const serviceTier = new incident.CatalogType("serviceTier", {description: "Level of importance for each service"});
    const serviceDescription = new incident.CatalogTypeAttribute("serviceDescription", {
        catalogTypeId: service.id,
        type: "Text",
    });
    const serviceTeam = new incident.CatalogTypeAttribute("serviceTeam", {
        catalogTypeId: service.id,
        type: "Text",
    });
    const serviceServiceTier = new incident.CatalogTypeAttribute("serviceServiceTier", {
        catalogTypeId: service.id,
        type: serviceTier.typeName,
    });
    // To create a backlink (i.e. Service tier -> Services)
    const serviceTierServices = new incident.CatalogTypeAttribute("serviceTierServices", {
        catalogTypeId: serviceTier.id,
        type: service.typeName,
        backlinkAttribute: serviceServiceTier.id,
    });
    
    import pulumi
    import pulumi_incident as incident
    
    service = incident.CatalogType("service", description="All services that we run across our product")
    service_tier = incident.CatalogType("serviceTier", description="Level of importance for each service")
    service_description = incident.CatalogTypeAttribute("serviceDescription",
        catalog_type_id=service.id,
        type="Text")
    service_team = incident.CatalogTypeAttribute("serviceTeam",
        catalog_type_id=service.id,
        type="Text")
    service_service_tier = incident.CatalogTypeAttribute("serviceServiceTier",
        catalog_type_id=service.id,
        type=service_tier.type_name)
    # To create a backlink (i.e. Service tier -> Services)
    service_tier_services = incident.CatalogTypeAttribute("serviceTierServices",
        catalog_type_id=service_tier.id,
        type=service.type_name,
        backlink_attribute=service_service_tier.id)
    
    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 {
    		service, err := incident.NewCatalogType(ctx, "service", &incident.CatalogTypeArgs{
    			Description: pulumi.String("All services that we run across our product"),
    		})
    		if err != nil {
    			return err
    		}
    		serviceTier, err := incident.NewCatalogType(ctx, "serviceTier", &incident.CatalogTypeArgs{
    			Description: pulumi.String("Level of importance for each service"),
    		})
    		if err != nil {
    			return err
    		}
    		_, err = incident.NewCatalogTypeAttribute(ctx, "serviceDescription", &incident.CatalogTypeAttributeArgs{
    			CatalogTypeId: service.ID(),
    			Type:          pulumi.String("Text"),
    		})
    		if err != nil {
    			return err
    		}
    		_, err = incident.NewCatalogTypeAttribute(ctx, "serviceTeam", &incident.CatalogTypeAttributeArgs{
    			CatalogTypeId: service.ID(),
    			Type:          pulumi.String("Text"),
    		})
    		if err != nil {
    			return err
    		}
    		serviceServiceTier, err := incident.NewCatalogTypeAttribute(ctx, "serviceServiceTier", &incident.CatalogTypeAttributeArgs{
    			CatalogTypeId: service.ID(),
    			Type:          serviceTier.TypeName,
    		})
    		if err != nil {
    			return err
    		}
    		// To create a backlink (i.e. Service tier -> Services)
    		_, err = incident.NewCatalogTypeAttribute(ctx, "serviceTierServices", &incident.CatalogTypeAttributeArgs{
    			CatalogTypeId:     serviceTier.ID(),
    			Type:              service.TypeName,
    			BacklinkAttribute: serviceServiceTier.ID(),
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using Pulumi;
    using Incident = Pulumi.Incident;
    
    return await Deployment.RunAsync(() => 
    {
        var service = new Incident.CatalogType("service", new()
        {
            Description = "All services that we run across our product",
        });
    
        var serviceTier = new Incident.CatalogType("serviceTier", new()
        {
            Description = "Level of importance for each service",
        });
    
        var serviceDescription = new Incident.CatalogTypeAttribute("serviceDescription", new()
        {
            CatalogTypeId = service.Id,
            Type = "Text",
        });
    
        var serviceTeam = new Incident.CatalogTypeAttribute("serviceTeam", new()
        {
            CatalogTypeId = service.Id,
            Type = "Text",
        });
    
        var serviceServiceTier = new Incident.CatalogTypeAttribute("serviceServiceTier", new()
        {
            CatalogTypeId = service.Id,
            Type = serviceTier.TypeName,
        });
    
        // To create a backlink (i.e. Service tier -> Services)
        var serviceTierServices = new Incident.CatalogTypeAttribute("serviceTierServices", new()
        {
            CatalogTypeId = serviceTier.Id,
            Type = service.TypeName,
            BacklinkAttribute = serviceServiceTier.Id,
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.incident.CatalogType;
    import com.pulumi.incident.CatalogTypeArgs;
    import com.pulumi.incident.CatalogTypeAttribute;
    import com.pulumi.incident.CatalogTypeAttributeArgs;
    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 service = new CatalogType("service", CatalogTypeArgs.builder()
                .description("All services that we run across our product")
                .build());
    
            var serviceTier = new CatalogType("serviceTier", CatalogTypeArgs.builder()
                .description("Level of importance for each service")
                .build());
    
            var serviceDescription = new CatalogTypeAttribute("serviceDescription", CatalogTypeAttributeArgs.builder()
                .catalogTypeId(service.id())
                .type("Text")
                .build());
    
            var serviceTeam = new CatalogTypeAttribute("serviceTeam", CatalogTypeAttributeArgs.builder()
                .catalogTypeId(service.id())
                .type("Text")
                .build());
    
            var serviceServiceTier = new CatalogTypeAttribute("serviceServiceTier", CatalogTypeAttributeArgs.builder()
                .catalogTypeId(service.id())
                .type(serviceTier.typeName())
                .build());
    
            // To create a backlink (i.e. Service tier -> Services)
            var serviceTierServices = new CatalogTypeAttribute("serviceTierServices", CatalogTypeAttributeArgs.builder()
                .catalogTypeId(serviceTier.id())
                .type(service.typeName())
                .backlinkAttribute(serviceServiceTier.id())
                .build());
    
        }
    }
    
    resources:
      service:
        type: incident:CatalogType
        properties:
          description: All services that we run across our product
      serviceTier:
        type: incident:CatalogType
        properties:
          description: Level of importance for each service
      serviceDescription:
        type: incident:CatalogTypeAttribute
        properties:
          catalogTypeId: ${service.id}
          type: Text
      serviceTeam:
        type: incident:CatalogTypeAttribute
        properties:
          catalogTypeId: ${service.id}
          type: Text
      serviceServiceTier:
        type: incident:CatalogTypeAttribute
        properties:
          catalogTypeId: ${service.id}
          type: ${serviceTier.typeName}
      # To create a backlink (i.e. Service tier -> Services)
      serviceTierServices:
        type: incident:CatalogTypeAttribute
        properties:
          catalogTypeId: ${serviceTier.id}
          type: ${service.typeName}
          backlinkAttribute: ${serviceServiceTier.id}
    

    Create CatalogTypeAttribute Resource

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

    Constructor syntax

    new CatalogTypeAttribute(name: string, args: CatalogTypeAttributeArgs, opts?: CustomResourceOptions);
    @overload
    def CatalogTypeAttribute(resource_name: str,
                             args: CatalogTypeAttributeArgs,
                             opts: Optional[ResourceOptions] = None)
    
    @overload
    def CatalogTypeAttribute(resource_name: str,
                             opts: Optional[ResourceOptions] = None,
                             catalog_type_id: Optional[str] = None,
                             type: Optional[str] = None,
                             array: Optional[bool] = None,
                             backlink_attribute: Optional[str] = None,
                             name: Optional[str] = None,
                             paths: Optional[Sequence[str]] = None,
                             schema_only: Optional[bool] = None)
    func NewCatalogTypeAttribute(ctx *Context, name string, args CatalogTypeAttributeArgs, opts ...ResourceOption) (*CatalogTypeAttribute, error)
    public CatalogTypeAttribute(string name, CatalogTypeAttributeArgs args, CustomResourceOptions? opts = null)
    public CatalogTypeAttribute(String name, CatalogTypeAttributeArgs args)
    public CatalogTypeAttribute(String name, CatalogTypeAttributeArgs args, CustomResourceOptions options)
    
    type: incident:CatalogTypeAttribute
    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 CatalogTypeAttributeArgs
    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 CatalogTypeAttributeArgs
    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 CatalogTypeAttributeArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args CatalogTypeAttributeArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args CatalogTypeAttributeArgs
    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 catalogTypeAttributeResource = new Incident.CatalogTypeAttribute("catalogTypeAttributeResource", new()
    {
        CatalogTypeId = "string",
        Type = "string",
        Array = false,
        BacklinkAttribute = "string",
        Name = "string",
        Paths = new[]
        {
            "string",
        },
        SchemaOnly = false,
    });
    
    example, err := incident.NewCatalogTypeAttribute(ctx, "catalogTypeAttributeResource", &incident.CatalogTypeAttributeArgs{
    	CatalogTypeId:     pulumi.String("string"),
    	Type:              pulumi.String("string"),
    	Array:             pulumi.Bool(false),
    	BacklinkAttribute: pulumi.String("string"),
    	Name:              pulumi.String("string"),
    	Paths: pulumi.StringArray{
    		pulumi.String("string"),
    	},
    	SchemaOnly: pulumi.Bool(false),
    })
    
    var catalogTypeAttributeResource = new CatalogTypeAttribute("catalogTypeAttributeResource", CatalogTypeAttributeArgs.builder()
        .catalogTypeId("string")
        .type("string")
        .array(false)
        .backlinkAttribute("string")
        .name("string")
        .paths("string")
        .schemaOnly(false)
        .build());
    
    catalog_type_attribute_resource = incident.CatalogTypeAttribute("catalogTypeAttributeResource",
        catalog_type_id="string",
        type="string",
        array=False,
        backlink_attribute="string",
        name="string",
        paths=["string"],
        schema_only=False)
    
    const catalogTypeAttributeResource = new incident.CatalogTypeAttribute("catalogTypeAttributeResource", {
        catalogTypeId: "string",
        type: "string",
        array: false,
        backlinkAttribute: "string",
        name: "string",
        paths: ["string"],
        schemaOnly: false,
    });
    
    type: incident:CatalogTypeAttribute
    properties:
        array: false
        backlinkAttribute: string
        catalogTypeId: string
        name: string
        paths:
            - string
        schemaOnly: false
        type: string
    

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

    CatalogTypeId string
    ID of this catalog type
    Type string
    The type of this attribute.
    Array bool
    Whether this attribute is an array or scalar.
    BacklinkAttribute string
    If this is a backlink, the id of the attribute that it's linked from
    Name string
    The name of this attribute.
    Paths List<string>
    If this is a path attribute, the path that we should use to pull the data
    SchemaOnly bool
    CatalogTypeId string
    ID of this catalog type
    Type string
    The type of this attribute.
    Array bool
    Whether this attribute is an array or scalar.
    BacklinkAttribute string
    If this is a backlink, the id of the attribute that it's linked from
    Name string
    The name of this attribute.
    Paths []string
    If this is a path attribute, the path that we should use to pull the data
    SchemaOnly bool
    catalogTypeId String
    ID of this catalog type
    type String
    The type of this attribute.
    array Boolean
    Whether this attribute is an array or scalar.
    backlinkAttribute String
    If this is a backlink, the id of the attribute that it's linked from
    name String
    The name of this attribute.
    paths List<String>
    If this is a path attribute, the path that we should use to pull the data
    schemaOnly Boolean
    catalogTypeId string
    ID of this catalog type
    type string
    The type of this attribute.
    array boolean
    Whether this attribute is an array or scalar.
    backlinkAttribute string
    If this is a backlink, the id of the attribute that it's linked from
    name string
    The name of this attribute.
    paths string[]
    If this is a path attribute, the path that we should use to pull the data
    schemaOnly boolean
    catalog_type_id str
    ID of this catalog type
    type str
    The type of this attribute.
    array bool
    Whether this attribute is an array or scalar.
    backlink_attribute str
    If this is a backlink, the id of the attribute that it's linked from
    name str
    The name of this attribute.
    paths Sequence[str]
    If this is a path attribute, the path that we should use to pull the data
    schema_only bool
    catalogTypeId String
    ID of this catalog type
    type String
    The type of this attribute.
    array Boolean
    Whether this attribute is an array or scalar.
    backlinkAttribute String
    If this is a backlink, the id of the attribute that it's linked from
    name String
    The name of this attribute.
    paths List<String>
    If this is a path attribute, the path that we should use to pull the data
    schemaOnly Boolean

    Outputs

    All input properties are implicitly available as output properties. Additionally, the CatalogTypeAttribute 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 CatalogTypeAttribute Resource

    Get an existing CatalogTypeAttribute 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?: CatalogTypeAttributeState, opts?: CustomResourceOptions): CatalogTypeAttribute
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            array: Optional[bool] = None,
            backlink_attribute: Optional[str] = None,
            catalog_type_id: Optional[str] = None,
            name: Optional[str] = None,
            paths: Optional[Sequence[str]] = None,
            schema_only: Optional[bool] = None,
            type: Optional[str] = None) -> CatalogTypeAttribute
    func GetCatalogTypeAttribute(ctx *Context, name string, id IDInput, state *CatalogTypeAttributeState, opts ...ResourceOption) (*CatalogTypeAttribute, error)
    public static CatalogTypeAttribute Get(string name, Input<string> id, CatalogTypeAttributeState? state, CustomResourceOptions? opts = null)
    public static CatalogTypeAttribute get(String name, Output<String> id, CatalogTypeAttributeState state, CustomResourceOptions options)
    resources:  _:    type: incident:CatalogTypeAttribute    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:
    Array bool
    Whether this attribute is an array or scalar.
    BacklinkAttribute string
    If this is a backlink, the id of the attribute that it's linked from
    CatalogTypeId string
    ID of this catalog type
    Name string
    The name of this attribute.
    Paths List<string>
    If this is a path attribute, the path that we should use to pull the data
    SchemaOnly bool
    Type string
    The type of this attribute.
    Array bool
    Whether this attribute is an array or scalar.
    BacklinkAttribute string
    If this is a backlink, the id of the attribute that it's linked from
    CatalogTypeId string
    ID of this catalog type
    Name string
    The name of this attribute.
    Paths []string
    If this is a path attribute, the path that we should use to pull the data
    SchemaOnly bool
    Type string
    The type of this attribute.
    array Boolean
    Whether this attribute is an array or scalar.
    backlinkAttribute String
    If this is a backlink, the id of the attribute that it's linked from
    catalogTypeId String
    ID of this catalog type
    name String
    The name of this attribute.
    paths List<String>
    If this is a path attribute, the path that we should use to pull the data
    schemaOnly Boolean
    type String
    The type of this attribute.
    array boolean
    Whether this attribute is an array or scalar.
    backlinkAttribute string
    If this is a backlink, the id of the attribute that it's linked from
    catalogTypeId string
    ID of this catalog type
    name string
    The name of this attribute.
    paths string[]
    If this is a path attribute, the path that we should use to pull the data
    schemaOnly boolean
    type string
    The type of this attribute.
    array bool
    Whether this attribute is an array or scalar.
    backlink_attribute str
    If this is a backlink, the id of the attribute that it's linked from
    catalog_type_id str
    ID of this catalog type
    name str
    The name of this attribute.
    paths Sequence[str]
    If this is a path attribute, the path that we should use to pull the data
    schema_only bool
    type str
    The type of this attribute.
    array Boolean
    Whether this attribute is an array or scalar.
    backlinkAttribute String
    If this is a backlink, the id of the attribute that it's linked from
    catalogTypeId String
    ID of this catalog type
    name String
    The name of this attribute.
    paths List<String>
    If this is a path attribute, the path that we should use to pull the data
    schemaOnly Boolean
    type String
    The type of this attribute.

    Import

    #!/bin/bash

    Import a catalog type attribute using the format catalog_type_id:attribute_id

    Replace the IDs with real IDs from your incident.io organization

    $ pulumi import incident:index/catalogTypeAttribute:CatalogTypeAttribute example 01ABC123DEF456GHI789JKL:01MNO456PQR789STU012VWX
    

    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.5.0 published on Wednesday, Apr 30, 2025 by incident-io