Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
44 changes: 21 additions & 23 deletions app/en/home/auth-providers/pagerduty/page.mdx
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,10 @@ import { Tabs, Callout, Steps } from "nextra/components";

The PagerDuty auth provider enables tools and agents to call [PagerDuty APIs](https://developer.pagerduty.com/api-reference/) on behalf of a user using OAuth 2.0 authentication.

<Callout type="warning">
Arcade currently supports **Classic** PagerDuty OAuth apps only. Choose Classic and select either **read-only** or **read/write** access. Newer Web App or other models are not supported. See [PagerDuty OAuth functionality](https://developer.pagerduty.com/docs/oauth-functionality).
</Callout>

<Callout>
Want to quickly get started with PagerDuty in your agent or AI app? The
pre-built [Arcade PagerDuty MCP
Expand Down Expand Up @@ -56,10 +60,10 @@ To integrate with PagerDuty's API using OAuth 2.0, you'll need to register an ap

#### Configure OAuth settings

1. Choose **Scoped OAuth** as the authorization method
2. Select the required **permission scopes** based on your application's needs:
- Common scopes include: `read`, `write`, `analytics.read`, `users.read`, `teams.read`, etc.
3. Add the **Redirect URL** generated by Arcade (see configuration section below) to your app's redirect URLs
1. Choose **Classic** OAuth and select the permission level:
- **Read-only** (recommended; all current MCP tools only read data)
- Or **Read/Write** if you plan custom tools that modify data
2. Add the **Redirect URL** generated by Arcade (see configuration section below) to your app's redirect URLs

#### Save your credentials

Expand All @@ -68,7 +72,7 @@ To integrate with PagerDuty's API using OAuth 2.0, you'll need to register an ap

</Steps>

For detailed instructions, refer to PagerDuty's [OAuth 2.0 guide](https://www.pagerduty.com/blog/insights/build-sophisticated-apps-for-your-pagerduty-environment-using-oauth-2-0-and-api-scopes/) and [OAuth documentation](https://developer.pagerduty.com/docs/ZG9jOjExMDI5NTgx-o-auth-2-functionality).
For detailed instructions, refer to PagerDuty's [OAuth 2.0 guide](https://www.pagerduty.com/blog/insights/build-sophisticated-apps-for-your-pagerduty-environment-using-oauth-2-0-and-api-scopes/) and [OAuth documentation](https://developer.pagerduty.com/docs/oauth-functionality).

Next, add the PagerDuty app to Arcade.

Expand Down Expand Up @@ -143,7 +147,7 @@ Edit the `engine.yaml` file and add a new item to the `auth.providers` section:
```yaml
auth:
providers:
- id: arcade-pagerduty
- id: pagerduty
description: PagerDuty OAuth 2.0 provider
enabled: true
type: oauth2
Expand Down Expand Up @@ -195,8 +199,8 @@ user_id = "{arcade_user_id}"
# Start the authorization process
auth_response = client.auth.start(
user_id=user_id,
provider="arcade-pagerduty",
scopes=["read", "write"]
provider="pagerduty",
scopes=[]
)

if auth_response.status != "completed":
Expand All @@ -222,10 +226,7 @@ const client = new Arcade();
const userId = "{arcade_user_id}";

// Start the authorization process
const authResponse = await client.auth.start(userId, "arcade-pagerduty", [
"read",
"write",
]);
const authResponse = await client.auth.start(userId, "pagerduty", []);

if (authResponse.status !== "completed") {
console.log("Please complete the authorization challenge in your browser:");
Expand All @@ -249,21 +250,18 @@ You can use the pre-built [Arcade PagerDuty MCP Server](/mcp-servers/development

If the pre-built tools in the PagerDuty MCP Server don't meet your needs, you can author your own [custom tools](/home/build-tools/create-a-mcp-server) that interact with the PagerDuty API.

Use the `OAuth2()` auth class to specify that a tool requires authorization with PagerDuty. The `context.authorization.token` field will be automatically populated with the user's PagerDuty token:
Use the `PagerDuty()` auth class to specify that a tool requires authorization with PagerDuty. The `context.authorization.token` field will be automatically populated with the user's PagerDuty token:

```python {8-12,22}
from typing import Annotated

import httpx
from arcade_tdk import ToolContext, tool
from arcade_tdk.auth import OAuth2
from arcade_tdk.auth import PagerDuty


@tool(
requires_auth=OAuth2(
provider_id="arcade-pagerduty",
scopes=["read"]
)
requires_auth=PagerDuty()
)
async def get_current_user(
context: ToolContext,
Expand All @@ -283,11 +281,11 @@ async def get_current_user(
return dict(response.json())
```

## Available Scopes
## Permissions

PagerDuty uses a simplified scope system with the following scopes:
PagerDuty Classic apps use two permission levels:

- `read` - Read-only access to PagerDuty resources
- `write` - Full read and write access to PagerDuty resources
- **read** — Read-only access to PagerDuty resources (recommended; all current MCP tools are read-only)
- **write** — Full read/write access (only needed if you add custom write tools)

For more details about PagerDuty's OAuth scopes and permissions, refer to the [PagerDuty OAuth Scopes documentation](https://developer.pagerduty.com/docs/ZG9jOjExMDI5NTgx-o-auth-2-functionality#scopes).
For more details about PagerDutys OAuth permissions, refer to the [PagerDuty OAuth functionality docs](https://developer.pagerduty.com/docs/oauth-functionality#scopes).
3 changes: 3 additions & 0 deletions app/en/mcp-servers/customer-support/_meta.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,9 @@ const meta: MetaRecord = {
pylon: {
title: "Pylon",
},
pagerduty: {
title: "PagerDuty",
},
};

export default meta;
Loading