1. Packages
  2. Pagerduty Provider
  3. API Docs
  4. ServiceCustomField
PagerDuty v4.25.1 published on Saturday, Jun 14, 2025 by Pulumi

pagerduty.ServiceCustomField

Explore with Pulumi AI

pagerduty logo
PagerDuty v4.25.1 published on Saturday, Jun 14, 2025 by Pulumi

    A service custom field allows you to extend PagerDuty Services with custom data fields to provide additional context and support features such as customized filtering, search, and analytics.

    Example Usage

    import * as pulumi from "@pulumi/pulumi";
    import * as pagerduty from "@pulumi/pagerduty";
    
    // Simple string field
    const environment = new pagerduty.ServiceCustomField("environment", {
        name: "environment",
        displayName: "Environment",
        dataType: "string",
        fieldType: "single_value",
        description: "The environment this service runs in",
    });
    // Field with fixed options
    const deploymentTier = new pagerduty.ServiceCustomField("deployment_tier", {
        name: "deployment_tier",
        displayName: "Deployment Tier",
        dataType: "string",
        fieldType: "single_value_fixed",
        description: "The deployment tier of the service",
        defaultValue: JSON.stringify("production"),
        fieldOptions: [
            {
                value: "production",
                dataType: "string",
            },
            {
                value: "staging",
                dataType: "string",
            },
            {
                value: "development",
                dataType: "string",
            },
        ],
    });
    // Multi-value field with fixed options
    const regions = new pagerduty.ServiceCustomField("regions", {
        name: "regions",
        displayName: "AWS Regions",
        dataType: "string",
        fieldType: "multi_value_fixed",
        description: "AWS regions where this service is deployed",
        fieldOptions: [
            {
                value: "us-east-1",
                dataType: "string",
            },
            {
                value: "us-west-1",
                dataType: "string",
            },
        ],
    });
    // Boolean field
    const critical = new pagerduty.ServiceCustomField("critical", {
        name: "is_critical",
        displayName: "Is Critical",
        dataType: "boolean",
        fieldType: "single_value",
        description: "Whether this is a critical service",
        defaultValue: JSON.stringify(true),
    });
    // Integer field
    const priority = new pagerduty.ServiceCustomField("priority", {
        name: "priority_level",
        displayName: "Priority Level",
        dataType: "integer",
        fieldType: "single_value",
        description: "Service priority level",
        defaultValue: JSON.stringify(1),
    });
    
    import pulumi
    import json
    import pulumi_pagerduty as pagerduty
    
    # Simple string field
    environment = pagerduty.ServiceCustomField("environment",
        name="environment",
        display_name="Environment",
        data_type="string",
        field_type="single_value",
        description="The environment this service runs in")
    # Field with fixed options
    deployment_tier = pagerduty.ServiceCustomField("deployment_tier",
        name="deployment_tier",
        display_name="Deployment Tier",
        data_type="string",
        field_type="single_value_fixed",
        description="The deployment tier of the service",
        default_value=json.dumps("production"),
        field_options=[
            {
                "value": "production",
                "data_type": "string",
            },
            {
                "value": "staging",
                "data_type": "string",
            },
            {
                "value": "development",
                "data_type": "string",
            },
        ])
    # Multi-value field with fixed options
    regions = pagerduty.ServiceCustomField("regions",
        name="regions",
        display_name="AWS Regions",
        data_type="string",
        field_type="multi_value_fixed",
        description="AWS regions where this service is deployed",
        field_options=[
            {
                "value": "us-east-1",
                "data_type": "string",
            },
            {
                "value": "us-west-1",
                "data_type": "string",
            },
        ])
    # Boolean field
    critical = pagerduty.ServiceCustomField("critical",
        name="is_critical",
        display_name="Is Critical",
        data_type="boolean",
        field_type="single_value",
        description="Whether this is a critical service",
        default_value=json.dumps(True))
    # Integer field
    priority = pagerduty.ServiceCustomField("priority",
        name="priority_level",
        display_name="Priority Level",
        data_type="integer",
        field_type="single_value",
        description="Service priority level",
        default_value=json.dumps(1))
    
    package main
    
    import (
    	"encoding/json"
    
    	"github.com/pulumi/pulumi-pagerduty/sdk/v4/go/pagerduty"
    	"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
    )
    
    func main() {
    	pulumi.Run(func(ctx *pulumi.Context) error {
    		// Simple string field
    		_, err := pagerduty.NewServiceCustomField(ctx, "environment", &pagerduty.ServiceCustomFieldArgs{
    			Name:        pulumi.String("environment"),
    			DisplayName: pulumi.String("Environment"),
    			DataType:    pulumi.String("string"),
    			FieldType:   pulumi.String("single_value"),
    			Description: pulumi.String("The environment this service runs in"),
    		})
    		if err != nil {
    			return err
    		}
    		tmpJSON0, err := json.Marshal("production")
    		if err != nil {
    			return err
    		}
    		json0 := string(tmpJSON0)
    		// Field with fixed options
    		_, err = pagerduty.NewServiceCustomField(ctx, "deployment_tier", &pagerduty.ServiceCustomFieldArgs{
    			Name:         pulumi.String("deployment_tier"),
    			DisplayName:  pulumi.String("Deployment Tier"),
    			DataType:     pulumi.String("string"),
    			FieldType:    pulumi.String("single_value_fixed"),
    			Description:  pulumi.String("The deployment tier of the service"),
    			DefaultValue: pulumi.String(json0),
    			FieldOptions: pagerduty.ServiceCustomFieldFieldOptionArray{
    				&pagerduty.ServiceCustomFieldFieldOptionArgs{
    					Value:    pulumi.String("production"),
    					DataType: pulumi.String("string"),
    				},
    				&pagerduty.ServiceCustomFieldFieldOptionArgs{
    					Value:    pulumi.String("staging"),
    					DataType: pulumi.String("string"),
    				},
    				&pagerduty.ServiceCustomFieldFieldOptionArgs{
    					Value:    pulumi.String("development"),
    					DataType: pulumi.String("string"),
    				},
    			},
    		})
    		if err != nil {
    			return err
    		}
    		// Multi-value field with fixed options
    		_, err = pagerduty.NewServiceCustomField(ctx, "regions", &pagerduty.ServiceCustomFieldArgs{
    			Name:        pulumi.String("regions"),
    			DisplayName: pulumi.String("AWS Regions"),
    			DataType:    pulumi.String("string"),
    			FieldType:   pulumi.String("multi_value_fixed"),
    			Description: pulumi.String("AWS regions where this service is deployed"),
    			FieldOptions: pagerduty.ServiceCustomFieldFieldOptionArray{
    				&pagerduty.ServiceCustomFieldFieldOptionArgs{
    					Value:    pulumi.String("us-east-1"),
    					DataType: pulumi.String("string"),
    				},
    				&pagerduty.ServiceCustomFieldFieldOptionArgs{
    					Value:    pulumi.String("us-west-1"),
    					DataType: pulumi.String("string"),
    				},
    			},
    		})
    		if err != nil {
    			return err
    		}
    		tmpJSON1, err := json.Marshal(true)
    		if err != nil {
    			return err
    		}
    		json1 := string(tmpJSON1)
    		// Boolean field
    		_, err = pagerduty.NewServiceCustomField(ctx, "critical", &pagerduty.ServiceCustomFieldArgs{
    			Name:         pulumi.String("is_critical"),
    			DisplayName:  pulumi.String("Is Critical"),
    			DataType:     pulumi.String("boolean"),
    			FieldType:    pulumi.String("single_value"),
    			Description:  pulumi.String("Whether this is a critical service"),
    			DefaultValue: pulumi.String(json1),
    		})
    		if err != nil {
    			return err
    		}
    		tmpJSON2, err := json.Marshal(1)
    		if err != nil {
    			return err
    		}
    		json2 := string(tmpJSON2)
    		// Integer field
    		_, err = pagerduty.NewServiceCustomField(ctx, "priority", &pagerduty.ServiceCustomFieldArgs{
    			Name:         pulumi.String("priority_level"),
    			DisplayName:  pulumi.String("Priority Level"),
    			DataType:     pulumi.String("integer"),
    			FieldType:    pulumi.String("single_value"),
    			Description:  pulumi.String("Service priority level"),
    			DefaultValue: pulumi.String(json2),
    		})
    		if err != nil {
    			return err
    		}
    		return nil
    	})
    }
    
    using System.Collections.Generic;
    using System.Linq;
    using System.Text.Json;
    using Pulumi;
    using Pagerduty = Pulumi.Pagerduty;
    
    return await Deployment.RunAsync(() => 
    {
        // Simple string field
        var environment = new Pagerduty.ServiceCustomField("environment", new()
        {
            Name = "environment",
            DisplayName = "Environment",
            DataType = "string",
            FieldType = "single_value",
            Description = "The environment this service runs in",
        });
    
        // Field with fixed options
        var deploymentTier = new Pagerduty.ServiceCustomField("deployment_tier", new()
        {
            Name = "deployment_tier",
            DisplayName = "Deployment Tier",
            DataType = "string",
            FieldType = "single_value_fixed",
            Description = "The deployment tier of the service",
            DefaultValue = JsonSerializer.Serialize("production"),
            FieldOptions = new[]
            {
                new Pagerduty.Inputs.ServiceCustomFieldFieldOptionArgs
                {
                    Value = "production",
                    DataType = "string",
                },
                new Pagerduty.Inputs.ServiceCustomFieldFieldOptionArgs
                {
                    Value = "staging",
                    DataType = "string",
                },
                new Pagerduty.Inputs.ServiceCustomFieldFieldOptionArgs
                {
                    Value = "development",
                    DataType = "string",
                },
            },
        });
    
        // Multi-value field with fixed options
        var regions = new Pagerduty.ServiceCustomField("regions", new()
        {
            Name = "regions",
            DisplayName = "AWS Regions",
            DataType = "string",
            FieldType = "multi_value_fixed",
            Description = "AWS regions where this service is deployed",
            FieldOptions = new[]
            {
                new Pagerduty.Inputs.ServiceCustomFieldFieldOptionArgs
                {
                    Value = "us-east-1",
                    DataType = "string",
                },
                new Pagerduty.Inputs.ServiceCustomFieldFieldOptionArgs
                {
                    Value = "us-west-1",
                    DataType = "string",
                },
            },
        });
    
        // Boolean field
        var critical = new Pagerduty.ServiceCustomField("critical", new()
        {
            Name = "is_critical",
            DisplayName = "Is Critical",
            DataType = "boolean",
            FieldType = "single_value",
            Description = "Whether this is a critical service",
            DefaultValue = JsonSerializer.Serialize(true),
        });
    
        // Integer field
        var priority = new Pagerduty.ServiceCustomField("priority", new()
        {
            Name = "priority_level",
            DisplayName = "Priority Level",
            DataType = "integer",
            FieldType = "single_value",
            Description = "Service priority level",
            DefaultValue = JsonSerializer.Serialize(1),
        });
    
    });
    
    package generated_program;
    
    import com.pulumi.Context;
    import com.pulumi.Pulumi;
    import com.pulumi.core.Output;
    import com.pulumi.pagerduty.ServiceCustomField;
    import com.pulumi.pagerduty.ServiceCustomFieldArgs;
    import com.pulumi.pagerduty.inputs.ServiceCustomFieldFieldOptionArgs;
    import static com.pulumi.codegen.internal.Serialization.*;
    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) {
            // Simple string field
            var environment = new ServiceCustomField("environment", ServiceCustomFieldArgs.builder()
                .name("environment")
                .displayName("Environment")
                .dataType("string")
                .fieldType("single_value")
                .description("The environment this service runs in")
                .build());
    
            // Field with fixed options
            var deploymentTier = new ServiceCustomField("deploymentTier", ServiceCustomFieldArgs.builder()
                .name("deployment_tier")
                .displayName("Deployment Tier")
                .dataType("string")
                .fieldType("single_value_fixed")
                .description("The deployment tier of the service")
                .defaultValue(serializeJson(
                    "production"))
                .fieldOptions(            
                    ServiceCustomFieldFieldOptionArgs.builder()
                        .value("production")
                        .dataType("string")
                        .build(),
                    ServiceCustomFieldFieldOptionArgs.builder()
                        .value("staging")
                        .dataType("string")
                        .build(),
                    ServiceCustomFieldFieldOptionArgs.builder()
                        .value("development")
                        .dataType("string")
                        .build())
                .build());
    
            // Multi-value field with fixed options
            var regions = new ServiceCustomField("regions", ServiceCustomFieldArgs.builder()
                .name("regions")
                .displayName("AWS Regions")
                .dataType("string")
                .fieldType("multi_value_fixed")
                .description("AWS regions where this service is deployed")
                .fieldOptions(            
                    ServiceCustomFieldFieldOptionArgs.builder()
                        .value("us-east-1")
                        .dataType("string")
                        .build(),
                    ServiceCustomFieldFieldOptionArgs.builder()
                        .value("us-west-1")
                        .dataType("string")
                        .build())
                .build());
    
            // Boolean field
            var critical = new ServiceCustomField("critical", ServiceCustomFieldArgs.builder()
                .name("is_critical")
                .displayName("Is Critical")
                .dataType("boolean")
                .fieldType("single_value")
                .description("Whether this is a critical service")
                .defaultValue(serializeJson(
                    true))
                .build());
    
            // Integer field
            var priority = new ServiceCustomField("priority", ServiceCustomFieldArgs.builder()
                .name("priority_level")
                .displayName("Priority Level")
                .dataType("integer")
                .fieldType("single_value")
                .description("Service priority level")
                .defaultValue(serializeJson(
                    1))
                .build());
    
        }
    }
    
    resources:
      # Simple string field
      environment:
        type: pagerduty:ServiceCustomField
        properties:
          name: environment
          displayName: Environment
          dataType: string
          fieldType: single_value
          description: The environment this service runs in
      # Field with fixed options
      deploymentTier:
        type: pagerduty:ServiceCustomField
        name: deployment_tier
        properties:
          name: deployment_tier
          displayName: Deployment Tier
          dataType: string
          fieldType: single_value_fixed
          description: The deployment tier of the service
          defaultValue:
            fn::toJSON: production
          fieldOptions:
            - value: production
              dataType: string
            - value: staging
              dataType: string
            - value: development
              dataType: string
      # Multi-value field with fixed options
      regions:
        type: pagerduty:ServiceCustomField
        properties:
          name: regions
          displayName: AWS Regions
          dataType: string
          fieldType: multi_value_fixed
          description: AWS regions where this service is deployed
          fieldOptions:
            - value: us-east-1
              dataType: string
            - value: us-west-1
              dataType: string
      # Boolean field
      critical:
        type: pagerduty:ServiceCustomField
        properties:
          name: is_critical
          displayName: Is Critical
          dataType: boolean
          fieldType: single_value
          description: Whether this is a critical service
          defaultValue:
            fn::toJSON: true
      # Integer field
      priority:
        type: pagerduty:ServiceCustomField
        properties:
          name: priority_level
          displayName: Priority Level
          dataType: integer
          fieldType: single_value
          description: Service priority level
          defaultValue:
            fn::toJSON: 1
    

    Create ServiceCustomField Resource

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

    Constructor syntax

    new ServiceCustomField(name: string, args: ServiceCustomFieldArgs, opts?: CustomResourceOptions);
    @overload
    def ServiceCustomField(resource_name: str,
                           args: ServiceCustomFieldArgs,
                           opts: Optional[ResourceOptions] = None)
    
    @overload
    def ServiceCustomField(resource_name: str,
                           opts: Optional[ResourceOptions] = None,
                           data_type: Optional[str] = None,
                           display_name: Optional[str] = None,
                           field_type: Optional[str] = None,
                           default_value: Optional[str] = None,
                           description: Optional[str] = None,
                           enabled: Optional[bool] = None,
                           field_options: Optional[Sequence[ServiceCustomFieldFieldOptionArgs]] = None,
                           name: Optional[str] = None)
    func NewServiceCustomField(ctx *Context, name string, args ServiceCustomFieldArgs, opts ...ResourceOption) (*ServiceCustomField, error)
    public ServiceCustomField(string name, ServiceCustomFieldArgs args, CustomResourceOptions? opts = null)
    public ServiceCustomField(String name, ServiceCustomFieldArgs args)
    public ServiceCustomField(String name, ServiceCustomFieldArgs args, CustomResourceOptions options)
    
    type: pagerduty:ServiceCustomField
    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 ServiceCustomFieldArgs
    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 ServiceCustomFieldArgs
    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 ServiceCustomFieldArgs
    The arguments to resource properties.
    opts ResourceOption
    Bag of options to control resource's behavior.
    name string
    The unique name of the resource.
    args ServiceCustomFieldArgs
    The arguments to resource properties.
    opts CustomResourceOptions
    Bag of options to control resource's behavior.
    name String
    The unique name of the resource.
    args ServiceCustomFieldArgs
    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 serviceCustomFieldResource = new Pagerduty.ServiceCustomField("serviceCustomFieldResource", new()
    {
        DataType = "string",
        DisplayName = "string",
        FieldType = "string",
        DefaultValue = "string",
        Description = "string",
        Enabled = false,
        FieldOptions = new[]
        {
            new Pagerduty.Inputs.ServiceCustomFieldFieldOptionArgs
            {
                DataType = "string",
                Value = "string",
                Id = "string",
            },
        },
        Name = "string",
    });
    
    example, err := pagerduty.NewServiceCustomField(ctx, "serviceCustomFieldResource", &pagerduty.ServiceCustomFieldArgs{
    	DataType:     pulumi.String("string"),
    	DisplayName:  pulumi.String("string"),
    	FieldType:    pulumi.String("string"),
    	DefaultValue: pulumi.String("string"),
    	Description:  pulumi.String("string"),
    	Enabled:      pulumi.Bool(false),
    	FieldOptions: pagerduty.ServiceCustomFieldFieldOptionArray{
    		&pagerduty.ServiceCustomFieldFieldOptionArgs{
    			DataType: pulumi.String("string"),
    			Value:    pulumi.String("string"),
    			Id:       pulumi.String("string"),
    		},
    	},
    	Name: pulumi.String("string"),
    })
    
    var serviceCustomFieldResource = new ServiceCustomField("serviceCustomFieldResource", ServiceCustomFieldArgs.builder()
        .dataType("string")
        .displayName("string")
        .fieldType("string")
        .defaultValue("string")
        .description("string")
        .enabled(false)
        .fieldOptions(ServiceCustomFieldFieldOptionArgs.builder()
            .dataType("string")
            .value("string")
            .id("string")
            .build())
        .name("string")
        .build());
    
    service_custom_field_resource = pagerduty.ServiceCustomField("serviceCustomFieldResource",
        data_type="string",
        display_name="string",
        field_type="string",
        default_value="string",
        description="string",
        enabled=False,
        field_options=[{
            "data_type": "string",
            "value": "string",
            "id": "string",
        }],
        name="string")
    
    const serviceCustomFieldResource = new pagerduty.ServiceCustomField("serviceCustomFieldResource", {
        dataType: "string",
        displayName: "string",
        fieldType: "string",
        defaultValue: "string",
        description: "string",
        enabled: false,
        fieldOptions: [{
            dataType: "string",
            value: "string",
            id: "string",
        }],
        name: "string",
    });
    
    type: pagerduty:ServiceCustomField
    properties:
        dataType: string
        defaultValue: string
        description: string
        displayName: string
        enabled: false
        fieldOptions:
            - dataType: string
              id: string
              value: string
        fieldType: string
        name: string
    

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

    DataType string
    The kind of data the custom field is allowed to contain. Can be one of: string, integer, float, boolean, datetime, or url.
    DisplayName string
    The human-readable name of the field. Must be unique across an account.
    FieldType string
    The type of field. Must be one of: single_value, single_value_fixed, multi_value, or multi_value_fixed.
    DefaultValue string
    The default value for the field. Must be provided as a JSON-encoded string matching the field's data type.
    Description string
    A description of the data this field contains.
    Enabled bool
    Whether the field is enabled. Defaults to true.
    FieldOptions List<ServiceCustomFieldFieldOption>
    Configuration block for defining options for single_value_fixed or multi_value_fixed field types. Can be specified multiple times for multiple options.
    Name string
    The name of the field. May include ASCII characters, specifically lowercase letters, digits, and underscores. Must be unique and cannot be changed once created.
    DataType string
    The kind of data the custom field is allowed to contain. Can be one of: string, integer, float, boolean, datetime, or url.
    DisplayName string
    The human-readable name of the field. Must be unique across an account.
    FieldType string
    The type of field. Must be one of: single_value, single_value_fixed, multi_value, or multi_value_fixed.
    DefaultValue string
    The default value for the field. Must be provided as a JSON-encoded string matching the field's data type.
    Description string
    A description of the data this field contains.
    Enabled bool
    Whether the field is enabled. Defaults to true.
    FieldOptions []ServiceCustomFieldFieldOptionArgs
    Configuration block for defining options for single_value_fixed or multi_value_fixed field types. Can be specified multiple times for multiple options.
    Name string
    The name of the field. May include ASCII characters, specifically lowercase letters, digits, and underscores. Must be unique and cannot be changed once created.
    dataType String
    The kind of data the custom field is allowed to contain. Can be one of: string, integer, float, boolean, datetime, or url.
    displayName String
    The human-readable name of the field. Must be unique across an account.
    fieldType String
    The type of field. Must be one of: single_value, single_value_fixed, multi_value, or multi_value_fixed.
    defaultValue String
    The default value for the field. Must be provided as a JSON-encoded string matching the field's data type.
    description String
    A description of the data this field contains.
    enabled Boolean
    Whether the field is enabled. Defaults to true.
    fieldOptions List<ServiceCustomFieldFieldOption>
    Configuration block for defining options for single_value_fixed or multi_value_fixed field types. Can be specified multiple times for multiple options.
    name String
    The name of the field. May include ASCII characters, specifically lowercase letters, digits, and underscores. Must be unique and cannot be changed once created.
    dataType string
    The kind of data the custom field is allowed to contain. Can be one of: string, integer, float, boolean, datetime, or url.
    displayName string
    The human-readable name of the field. Must be unique across an account.
    fieldType string
    The type of field. Must be one of: single_value, single_value_fixed, multi_value, or multi_value_fixed.
    defaultValue string
    The default value for the field. Must be provided as a JSON-encoded string matching the field's data type.
    description string
    A description of the data this field contains.
    enabled boolean
    Whether the field is enabled. Defaults to true.
    fieldOptions ServiceCustomFieldFieldOption[]
    Configuration block for defining options for single_value_fixed or multi_value_fixed field types. Can be specified multiple times for multiple options.
    name string
    The name of the field. May include ASCII characters, specifically lowercase letters, digits, and underscores. Must be unique and cannot be changed once created.
    data_type str
    The kind of data the custom field is allowed to contain. Can be one of: string, integer, float, boolean, datetime, or url.
    display_name str
    The human-readable name of the field. Must be unique across an account.
    field_type str
    The type of field. Must be one of: single_value, single_value_fixed, multi_value, or multi_value_fixed.
    default_value str
    The default value for the field. Must be provided as a JSON-encoded string matching the field's data type.
    description str
    A description of the data this field contains.
    enabled bool
    Whether the field is enabled. Defaults to true.
    field_options Sequence[ServiceCustomFieldFieldOptionArgs]
    Configuration block for defining options for single_value_fixed or multi_value_fixed field types. Can be specified multiple times for multiple options.
    name str
    The name of the field. May include ASCII characters, specifically lowercase letters, digits, and underscores. Must be unique and cannot be changed once created.
    dataType String
    The kind of data the custom field is allowed to contain. Can be one of: string, integer, float, boolean, datetime, or url.
    displayName String
    The human-readable name of the field. Must be unique across an account.
    fieldType String
    The type of field. Must be one of: single_value, single_value_fixed, multi_value, or multi_value_fixed.
    defaultValue String
    The default value for the field. Must be provided as a JSON-encoded string matching the field's data type.
    description String
    A description of the data this field contains.
    enabled Boolean
    Whether the field is enabled. Defaults to true.
    fieldOptions List<Property Map>
    Configuration block for defining options for single_value_fixed or multi_value_fixed field types. Can be specified multiple times for multiple options.
    name String
    The name of the field. May include ASCII characters, specifically lowercase letters, digits, and underscores. Must be unique and cannot be changed once created.

    Outputs

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

    Id string
    The provider-assigned unique ID for this managed resource.
    Self string
    The API show URL at which the object is accessible
    Summary string
    A short-form, server-generated string that provides succinct, important information about an object suitable for primary labeling of an entity in a client. In many cases, this will be identical to display_name
    Type string
    API object type
    Id string
    The provider-assigned unique ID for this managed resource.
    Self string
    The API show URL at which the object is accessible
    Summary string
    A short-form, server-generated string that provides succinct, important information about an object suitable for primary labeling of an entity in a client. In many cases, this will be identical to display_name
    Type string
    API object type
    id String
    The provider-assigned unique ID for this managed resource.
    self String
    The API show URL at which the object is accessible
    summary String
    A short-form, server-generated string that provides succinct, important information about an object suitable for primary labeling of an entity in a client. In many cases, this will be identical to display_name
    type String
    API object type
    id string
    The provider-assigned unique ID for this managed resource.
    self string
    The API show URL at which the object is accessible
    summary string
    A short-form, server-generated string that provides succinct, important information about an object suitable for primary labeling of an entity in a client. In many cases, this will be identical to display_name
    type string
    API object type
    id str
    The provider-assigned unique ID for this managed resource.
    self str
    The API show URL at which the object is accessible
    summary str
    A short-form, server-generated string that provides succinct, important information about an object suitable for primary labeling of an entity in a client. In many cases, this will be identical to display_name
    type str
    API object type
    id String
    The provider-assigned unique ID for this managed resource.
    self String
    The API show URL at which the object is accessible
    summary String
    A short-form, server-generated string that provides succinct, important information about an object suitable for primary labeling of an entity in a client. In many cases, this will be identical to display_name
    type String
    API object type

    Look up Existing ServiceCustomField Resource

    Get an existing ServiceCustomField 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?: ServiceCustomFieldState, opts?: CustomResourceOptions): ServiceCustomField
    @staticmethod
    def get(resource_name: str,
            id: str,
            opts: Optional[ResourceOptions] = None,
            data_type: Optional[str] = None,
            default_value: Optional[str] = None,
            description: Optional[str] = None,
            display_name: Optional[str] = None,
            enabled: Optional[bool] = None,
            field_options: Optional[Sequence[ServiceCustomFieldFieldOptionArgs]] = None,
            field_type: Optional[str] = None,
            name: Optional[str] = None,
            self: Optional[str] = None,
            summary: Optional[str] = None,
            type: Optional[str] = None) -> ServiceCustomField
    func GetServiceCustomField(ctx *Context, name string, id IDInput, state *ServiceCustomFieldState, opts ...ResourceOption) (*ServiceCustomField, error)
    public static ServiceCustomField Get(string name, Input<string> id, ServiceCustomFieldState? state, CustomResourceOptions? opts = null)
    public static ServiceCustomField get(String name, Output<String> id, ServiceCustomFieldState state, CustomResourceOptions options)
    resources:  _:    type: pagerduty:ServiceCustomField    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:
    DataType string
    The kind of data the custom field is allowed to contain. Can be one of: string, integer, float, boolean, datetime, or url.
    DefaultValue string
    The default value for the field. Must be provided as a JSON-encoded string matching the field's data type.
    Description string
    A description of the data this field contains.
    DisplayName string
    The human-readable name of the field. Must be unique across an account.
    Enabled bool
    Whether the field is enabled. Defaults to true.
    FieldOptions List<ServiceCustomFieldFieldOption>
    Configuration block for defining options for single_value_fixed or multi_value_fixed field types. Can be specified multiple times for multiple options.
    FieldType string
    The type of field. Must be one of: single_value, single_value_fixed, multi_value, or multi_value_fixed.
    Name string
    The name of the field. May include ASCII characters, specifically lowercase letters, digits, and underscores. Must be unique and cannot be changed once created.
    Self string
    The API show URL at which the object is accessible
    Summary string
    A short-form, server-generated string that provides succinct, important information about an object suitable for primary labeling of an entity in a client. In many cases, this will be identical to display_name
    Type string
    API object type
    DataType string
    The kind of data the custom field is allowed to contain. Can be one of: string, integer, float, boolean, datetime, or url.
    DefaultValue string
    The default value for the field. Must be provided as a JSON-encoded string matching the field's data type.
    Description string
    A description of the data this field contains.
    DisplayName string
    The human-readable name of the field. Must be unique across an account.
    Enabled bool
    Whether the field is enabled. Defaults to true.
    FieldOptions []ServiceCustomFieldFieldOptionArgs
    Configuration block for defining options for single_value_fixed or multi_value_fixed field types. Can be specified multiple times for multiple options.
    FieldType string
    The type of field. Must be one of: single_value, single_value_fixed, multi_value, or multi_value_fixed.
    Name string
    The name of the field. May include ASCII characters, specifically lowercase letters, digits, and underscores. Must be unique and cannot be changed once created.
    Self string
    The API show URL at which the object is accessible
    Summary string
    A short-form, server-generated string that provides succinct, important information about an object suitable for primary labeling of an entity in a client. In many cases, this will be identical to display_name
    Type string
    API object type
    dataType String
    The kind of data the custom field is allowed to contain. Can be one of: string, integer, float, boolean, datetime, or url.
    defaultValue String
    The default value for the field. Must be provided as a JSON-encoded string matching the field's data type.
    description String
    A description of the data this field contains.
    displayName String
    The human-readable name of the field. Must be unique across an account.
    enabled Boolean
    Whether the field is enabled. Defaults to true.
    fieldOptions List<ServiceCustomFieldFieldOption>
    Configuration block for defining options for single_value_fixed or multi_value_fixed field types. Can be specified multiple times for multiple options.
    fieldType String
    The type of field. Must be one of: single_value, single_value_fixed, multi_value, or multi_value_fixed.
    name String
    The name of the field. May include ASCII characters, specifically lowercase letters, digits, and underscores. Must be unique and cannot be changed once created.
    self String
    The API show URL at which the object is accessible
    summary String
    A short-form, server-generated string that provides succinct, important information about an object suitable for primary labeling of an entity in a client. In many cases, this will be identical to display_name
    type String
    API object type
    dataType string
    The kind of data the custom field is allowed to contain. Can be one of: string, integer, float, boolean, datetime, or url.
    defaultValue string
    The default value for the field. Must be provided as a JSON-encoded string matching the field's data type.
    description string
    A description of the data this field contains.
    displayName string
    The human-readable name of the field. Must be unique across an account.
    enabled boolean
    Whether the field is enabled. Defaults to true.
    fieldOptions ServiceCustomFieldFieldOption[]
    Configuration block for defining options for single_value_fixed or multi_value_fixed field types. Can be specified multiple times for multiple options.
    fieldType string
    The type of field. Must be one of: single_value, single_value_fixed, multi_value, or multi_value_fixed.
    name string
    The name of the field. May include ASCII characters, specifically lowercase letters, digits, and underscores. Must be unique and cannot be changed once created.
    self string
    The API show URL at which the object is accessible
    summary string
    A short-form, server-generated string that provides succinct, important information about an object suitable for primary labeling of an entity in a client. In many cases, this will be identical to display_name
    type string
    API object type
    data_type str
    The kind of data the custom field is allowed to contain. Can be one of: string, integer, float, boolean, datetime, or url.
    default_value str
    The default value for the field. Must be provided as a JSON-encoded string matching the field's data type.
    description str
    A description of the data this field contains.
    display_name str
    The human-readable name of the field. Must be unique across an account.
    enabled bool
    Whether the field is enabled. Defaults to true.
    field_options Sequence[ServiceCustomFieldFieldOptionArgs]
    Configuration block for defining options for single_value_fixed or multi_value_fixed field types. Can be specified multiple times for multiple options.
    field_type str
    The type of field. Must be one of: single_value, single_value_fixed, multi_value, or multi_value_fixed.
    name str
    The name of the field. May include ASCII characters, specifically lowercase letters, digits, and underscores. Must be unique and cannot be changed once created.
    self str
    The API show URL at which the object is accessible
    summary str
    A short-form, server-generated string that provides succinct, important information about an object suitable for primary labeling of an entity in a client. In many cases, this will be identical to display_name
    type str
    API object type
    dataType String
    The kind of data the custom field is allowed to contain. Can be one of: string, integer, float, boolean, datetime, or url.
    defaultValue String
    The default value for the field. Must be provided as a JSON-encoded string matching the field's data type.
    description String
    A description of the data this field contains.
    displayName String
    The human-readable name of the field. Must be unique across an account.
    enabled Boolean
    Whether the field is enabled. Defaults to true.
    fieldOptions List<Property Map>
    Configuration block for defining options for single_value_fixed or multi_value_fixed field types. Can be specified multiple times for multiple options.
    fieldType String
    The type of field. Must be one of: single_value, single_value_fixed, multi_value, or multi_value_fixed.
    name String
    The name of the field. May include ASCII characters, specifically lowercase letters, digits, and underscores. Must be unique and cannot be changed once created.
    self String
    The API show URL at which the object is accessible
    summary String
    A short-form, server-generated string that provides succinct, important information about an object suitable for primary labeling of an entity in a client. In many cases, this will be identical to display_name
    type String
    API object type

    Supporting Types

    ServiceCustomFieldFieldOption, ServiceCustomFieldFieldOptionArgs

    DataType string
    Must be string.
    Value string
    The value of the option.
    Id string
    The ID of the service custom field.
    DataType string
    Must be string.
    Value string
    The value of the option.
    Id string
    The ID of the service custom field.
    dataType String
    Must be string.
    value String
    The value of the option.
    id String
    The ID of the service custom field.
    dataType string
    Must be string.
    value string
    The value of the option.
    id string
    The ID of the service custom field.
    data_type str
    Must be string.
    value str
    The value of the option.
    id str
    The ID of the service custom field.
    dataType String
    Must be string.
    value String
    The value of the option.
    id String
    The ID of the service custom field.

    Import

    Service custom fields can be imported using the field ID, e.g.

    $ pulumi import pagerduty:index/serviceCustomField:ServiceCustomField example P123456
    

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

    Package Details

    Repository
    PagerDuty pulumi/pulumi-pagerduty
    License
    Apache-2.0
    Notes
    This Pulumi package is based on the pagerduty Terraform Provider.
    pagerduty logo
    PagerDuty v4.25.1 published on Saturday, Jun 14, 2025 by Pulumi