> This is a page from the ElevenLabs documentation. For a complete page index, fetch https://elevenlabs.io/docs/llms.txt. For the full documentation in a single file, fetch https://elevenlabs.io/docs/llms-full.txt.

# Jira

## 概述

将 ElevenLabs AI 智能体与 Jira Cloud 连接，以管理问题、跟踪项目并自动化支持 workflow。此集成让智能体可以创建和更新问题、通过 workflow 流转问题、关联相关工单以便升级处理，以及跨项目搜索。

## 功能

| 功能         | 支持情况         |
| ---------- | ------------ |
| 零保留模式（ZRM） | 不支持          |
| 工具中的附件     | 不支持——工具仅处理文本 |

## 设置

此集成使用 **Jira API 令牌**进行基本身份验证。需要 Atlassian 账户邮箱、API 令牌和 Jira Cloud 子域名。

#### 生成 API 令牌

前往 [Atlassian API 令牌管理](https://id.atlassian.com/manage-profile/security/api-tokens)，然后点击 **Create API token**。复制令牌——之后将无法再次查看。

#### 查找 Jira 子域名

子域名是 Jira Cloud URL 的第一部分。例如，如果 Jira 地址是 `mycompany.atlassian.net`，则子域名是 `mycompany`。

#### 在 ElevenLabs 中连接

在 ElevenLabs 集成设置中，输入：

* **Email** - Atlassian 账户邮箱
* **API Token** - 在第 1 步生成的令牌
* **Jira Subdomain** - 第 2 步中的子域名

> **Note**
>
> API 令牌默认在一年后过期。如果智能体无法再访问 Jira，
> 请生成新令牌并更新连接。

## 识别来电者

`jira_search_issues` 工具需要 `labels` 参数，以便将搜索范围限定为特定用户的工单。这假设 Jira workflow 会向每个问题添加可识别来电者的标签——例如，将邮箱 `jane.smith@example.com` 转换为 `jane-smith-at-example-com` 这类标签。

要自动化此操作，请将 `labels` 字段配置为接收应用传入来电者标识符的[动态变量](/docs/zh/eleven-agents/customization/personalization/dynamic-variables)。这样，智能体无需在每次通话时询问来电者的邮箱。

> **Note**
>
> Jira 标签不能包含空格。常见做法是将 `@` 替换为 `-at-`，将 `.` 替换为
> `-`（例如 `jane-smith-at-example-com`）。`jira_search_issues` 工具会精确匹配标签，
> 因此提供的值必须与问题上的标签一致。

## 工作原理

#### 创建支持工单

#### 识别来电者

智能体通过邮箱地址或 labels 字段中配置的其他标识符识别来电者。

#### 收集详细信息

智能体从来电者处收集问题信息——发生了什么、严重程度以及相关背景。

#### 创建问题

智能体会在相应项目中创建 Jira 问题，并设置正确的问题类型、优先级和描述。

#### 向来电者确认

智能体会读出已创建的工单编号，方便来电者后续跟进。

#### 服务台处理

#### 查询工单

智能体会通过键获取 Jira 问题（例如 PROJ-123），并读出当前状态、
优先级和摘要。

#### 添加解决备注

智能体会在问题中添加评论，包含对话中的详细信息，例如已采取的步骤
或已收集的信息。

#### 关闭工单

智能体会使用可用的 workflow 流转，将问题转为已解决或已关闭状态。

## 系统提示词示例

#### 查看系统提示词示例

```text
# Personality

You are a helpful IT support agent responsible for managing support tickets in Jira. Be friendly, professional, and efficient.

# Environment

You operate in a support setting via voice or chat, where you help users report issues, check ticket status, and manage existing requests.

# Tone

Begin by asking how you can help. If the caller has an existing issue, ask whether they have the ticket number. If they are reporting a new issue, collect details about the problem.

Ask one question at a time and wait for the response before proceeding.

# Goal

For new issues:
- Collect a clear description of the problem
- Determine severity and urgency
- Create the ticket in the appropriate project with the right issue type and priority
- Read back the ticket number

For existing issues:
- If the caller provides a ticket number, look it up by key
- If the caller wants to check on their issues, search using the labels field
- Provide status updates
- Add comments or update priority when requested
- Always confirm before making changes

# Guardrails

- Do not discuss topics outside of IT support.
- Never expose raw Jira API responses, internal IDs, or technical field names to the caller.
- Always confirm with the caller before creating, updating, or transitioning issues.
```

## 可用工具

| 工具                      | 说明                                                      |
| ----------------------- | ------------------------------------------------------- |
| `jira_create_issue`     | 创建问题，包含项目、摘要、问题类型和优先级等可选字段。                             |
| `jira_get_issue`        | 通过键获取特定问题的详细信息。                                         |
| `jira_search_issues`    | 按标签、项目、状态、优先级、类型、受理人、文本或日期范围搜索问题。                       |
| `jira_update_issue`     | 更新现有问题的字段——优先级、受理人、标签或描述。                               |
| `jira_add_comment`      | 向问题添加纯文本评论。                                             |
| `jira_get_transitions`  | 列出问题可用的 workflow 流转。                                    |
| `jira_transition_issue` | 使用来自 `jira_get_transitions` 的流转 ID 将问题移至新的 workflow 状态。 |
| `jira_link_issues`      | 关联两个问题（例如“阻塞”、“重复”、“相关”）。                               |
| `jira_list_projects`    | 列出可用项目及其键。                                              |
| `jira_get_issue_types`  | 列出可用问题类型（例如 Bug、Task、Story）。                            |
| `jira_get_priorities`   | 列出可用优先级。                                                |

> **Note**
>
> 问题描述和评论仅支持纯文本。集成会自动将其转换为 Jira 的
> Atlassian Document Format（ADF）。不支持 Markdown 和 HTML。

## 实用链接

* [Jira Cloud REST API 文档](https://developer.atlassian.com/cloud/jira/platform/rest/v3/)
* [管理 API 令牌](https://support.atlassian.com/atlassian-account/docs/manage-api-tokens-for-your-atlassian-account/)