Skip to main content

users

Creates, updates, deletes, gets or lists a users resource.

Overview

Nameusers
TypeResource
Idpagerduty.schedules.users

Fields

The following fields are returned by SELECT queries:

The users on the given schedule.

NameDatatypeDescription
idstring
namestringThe name of the user.
avatar_urlstring (url)The URL of the user's avatar.
colorstringThe schedule color.
contact_methodsarrayThe list of contact methods for the user.
descriptionstringThe user's bio.
emailstring (email)The user's email address.
html_urlstring (url)a URL at which the entity is uniquely displayed in the Web app
invitation_sentbooleanIf true, the user has an outstanding invitation.
job_titlestringThe user's title.
licenseobjectThe License assigned to the User
notification_rulesarrayThe list of notification rules for the user.
rolestringThe user role. Account must have the read_only_users ability to set a user as a read_only_user or a read_only_limited_user, and must have advanced permissions abilities to set a user as observer or restricted_access.
selfstring (url)the API show URL at which the object is accessible
summarystringA 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 name, though it is not intended to be an identifier.
teamsarrayThe list of teams to which the user belongs. Account must have the teams ability to set this.
time_zonestring (tzinfo)The preferred time zone name. If null, the account's time zone will be used.
typestringThe type of object being created. (default: user)

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
list_schedule_usersselectidAccept, Content-Type, since, untilList all of the users on call in a given schedule for a given time range.

A Schedule determines the time periods that users are On-Call.

For more information see the API Concepts Document

Scoped OAuth requires: users.read
_list_schedule_usersexecidAccept, Content-Type, since, untilList all of the users on call in a given schedule for a given time range.

A Schedule determines the time periods that users are On-Call.

For more information see the API Concepts Document

Scoped OAuth requires: users.read

Parameters

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
idstringThe ID of the resource.
AcceptstringThe Accept header is used as a versioning header.
Content-Typestring
sincestring (date-time)The start of the date range over which you want to search.
untilstring (date-time)The end of the date range over which you want to search.

SELECT examples

List all of the users on call in a given schedule for a given time range.

A Schedule determines the time periods that users are On-Call.

For more information see the API Concepts Document

Scoped OAuth requires: users.read

SELECT
id,
name,
avatar_url,
color,
contact_methods,
description,
email,
html_url,
invitation_sent,
job_title,
license,
notification_rules,
role,
self,
summary,
teams,
time_zone,
type
FROM pagerduty.schedules.users
WHERE id = '{{ id }}' -- required
AND Accept = '{{ Accept }}'
AND Content-Type = '{{ Content-Type }}'
AND since = '{{ since }}'
AND until = '{{ until }}'
;

Lifecycle Methods

List all of the users on call in a given schedule for a given time range.

A Schedule determines the time periods that users are On-Call.

For more information see the API Concepts Document

Scoped OAuth requires: users.read

EXEC pagerduty.schedules.users._list_schedule_users 
@id='{{ id }}' --required,
@Accept='{{ Accept }}',
@Content-Type='{{ Content-Type }}',
@since='{{ since }}',
@until='{{ until }}'
;