Skip to main content

Overview

Creates a new service in your PagerDuty account. Services represent the applications, components, or systems that you want to monitor.
This is a write tool that modifies your PagerDuty account. You must enable write mode with the --enable-write-tools flag to use this tool.

Parameters

service_data
ServiceCreate
required
The data for the new service.
Do not include an id field in the service data. The service ID is automatically generated by PagerDuty.

Response

Returns the created Service object with the server-generated ID and other fields.
id
string
The unique identifier for the newly created service (server-generated).
type
string
The type of the object (always "service").
name
string
The name of the service.
description
string
The description of the service.
escalation_policy
EscalationPolicyReference
Reference to the escalation policy associated with this service.
teams
TeamReference[]
List of teams associated with the service.

Example Usage

Create a service called "Production API Service" with escalation policy PEPOLICY123

Example Request

{
  "service_data": {
    "service": {
      "name": "Production API Service",
      "description": "REST API service for production environment",
      "escalation_policy": {
        "id": "PEPOLICY123"
      },
      "teams": [
        {
          "id": "PTEAM1"
        }
      ]
    }
  }
}

Example Response

{
  "id": "PSERVICE999",
  "type": "service",
  "name": "Production API Service",
  "description": "REST API service for production environment",
  "escalation_policy": {
    "id": "PEPOLICY123",
    "type": "escalation_policy_reference",
    "summary": "Production On-Call Policy"
  },
  "teams": [
    {
      "id": "PTEAM1",
      "type": "team_reference",
      "summary": "Backend Engineering"
    }
  ]
}

Important Notes

Escalation Policy Reference: When creating a service, the escalation_policy reference only requires the id field. The summary field is server-generated and will be ignored if you provide it.Example: {"id": "PEPOLICY123"}
Before creating a service, ensure that:
  • The escalation policy ID exists and is valid
  • Any team IDs you reference exist in your account
  • You have the necessary permissions to create services

list_services

List all services

get_service

View service details

update_service

Update service configuration

list_escalation_policies

Find escalation policy IDs

Build docs developers (and LLMs) love