

# 交互式会话 API
<a name="aws-glue-api-interactive-sessions"></a>

交互式会话 API 描述与使用 Amazon Glue 交互式会话构建和测试数据集成的提取、转换和加载 (ETL) 脚本相关的 Amazon Glue API。

## 数据类型
<a name="aws-glue-api-interactive-sessions-objects"></a>
+ [Session 结构](#aws-glue-api-interactive-sessions-Session)
+ [SessionCommand 结构](#aws-glue-api-interactive-sessions-SessionCommand)
+ [Statement 结构](#aws-glue-api-interactive-sessions-Statement)
+ [StatementOutput 结构](#aws-glue-api-interactive-sessions-StatementOutput)
+ [StatementOutputData 结构](#aws-glue-api-interactive-sessions-StatementOutputData)
+ [ConnectionsList 结构](#aws-glue-api-interactive-sessions-ConnectionsList)

## Session 结构
<a name="aws-glue-api-interactive-sessions-Session"></a>

远程 Spark 运行时环境的运行时段。

**Fields**
+ `Id` – UTF-8 字符串，长度不少于 1 个字节或超过 255 个字节，与 [Single-line string pattern](aws-glue-api-common.md#aws-glue-api-regex-oneLine) 匹配。

  会话 ID。
+ `CreatedOn` – 时间戳。

  创建会话的日期和时间。
+ `Status` – UTF-8 字符串（有效值：`PROVISIONING` \$1`READY` \$1`FAILED` \$1`TIMEOUT` \$1`STOPPING` \$1`STOPPED` ）。

  会话状态。
+ `ErrorMessage` – 描述字符串，长度不超过 2048 个字节，与 [URI address multi-line string pattern](aws-glue-api-common.md#aws-glue-api-regex-uri) 匹配。

  会话期间显示的错误消息。
+ `Description` – 描述字符串，长度不超过 2048 个字节，与 [URI address multi-line string pattern](aws-glue-api-common.md#aws-glue-api-regex-uri) 匹配。

  会话描述。
+ `Role` – UTF-8 字符串，不少于 20 个字节，不超过 2048 个字节，与 [Custom string pattern #30](aws-glue-api-common.md#regex_30) 匹配。

  与此会话关联的 IAM 角色的名称或 Amazon Resource Name (ARN)。
+ `Command` – 一个 [SessionCommand](#aws-glue-api-interactive-sessions-SessionCommand) 对象。

  命令对象。请参阅 SessionCommand。
+ `DefaultArguments` – 键值对的映射数组，不超过 75 对。

  每个键是一个 UTF-8 字符串，不少于 1 个字节或超过 128 个字节，与 [Custom string pattern #31](aws-glue-api-common.md#regex_31) 匹配。

  每个值都是一个 UTF-8 字符串，长度不超过 4096 个字节，与 [URI address multi-line string pattern](aws-glue-api-common.md#aws-glue-api-regex-uri) 匹配。

  键值对的映射数组。最多 75 对。
+ `Connections` – 一个 [ConnectionsList](#aws-glue-api-interactive-sessions-ConnectionsList) 对象。

  用于会话的连接数。
+ `Progress` – 数字（double）。

  会话的代码执行进度。
+ `MaxCapacity` – 数字（double）。

  任务运行时可分配的 Amazon Glue 数据处理单元 (DPU) 的数量。DPU 是对处理能力的相对度量，它由 4 个 vCPU 的计算容量和 16GB 内存组成。
+ `SecurityConfiguration` – UTF-8 字符串，长度不少于 1 个字节或超过 255 个字节，与 [Single-line string pattern](aws-glue-api-common.md#aws-glue-api-regex-oneLine) 匹配。

  会话要使用的 SecurityConfiguration 结构的名称。
+ `GlueVersion` – UTF-8 字符串，长度不少于 1 个字节或超过 255 个字节，与 [Custom string pattern #48](aws-glue-api-common.md#regex_48) 匹配。

  Amazon Glue 版本决定了 Amazon Glue 支持的 Apache Spark 和 Python 版本。GlueVersion 必须大于 2.0。
+ `DataAccessId` – UTF-8 字符串，长度不少于 1 个字节，不超过 36 个字节。

  会话的数据访问 ID。
+ `PartitionId` – UTF-8 字符串，长度不少于 1 个字节，不超过 36 个字节。

  会话的分区 ID。
+ `NumberOfWorkers` – 数字（整数）。

  用于会话的已定义 `WorkerType` 的工件数量。
+ `WorkerType` – UTF-8 字符串（有效值：`Standard=""` \$1`G.1X=""` \$1`G.2X=""` \$1`G.025X=""` \$1`G.4X=""` \$1`G.8X=""` \$1`Z.2X=""` ）。

  会话运行时分配的预定义工作线程的类型。接受 `G.1X`、`G.2X`、`G.4X`、`G.8X` for Spark 会话的值。接受 `Z.2X` for Ray 的值。
+ `CompletedOn` – 时间戳。

  此会话的完成日期和时间。
+ `ExecutionTime` – 数字（double）。

  会话运行的总时间。
+ `DPUSeconds` – 数字（double）。

  会话消耗的 DPU（公式：执行时间 \$1 最大容量）。
+ `IdleTimeout` – 数字（整数）。

  会话超时前的空闲分钟数。
+ `ProfileName` – UTF-8 字符串，长度不少于 1 个字节或超过 255 个字节，与 [Single-line string pattern](aws-glue-api-common.md#aws-glue-api-regex-oneLine) 匹配。

  与会话关联的 Amazon Glue 使用情况配置文件名称。

## SessionCommand 结构
<a name="aws-glue-api-interactive-sessions-SessionCommand"></a>

运行任务的 `SessionCommand`。

**Fields**
+ `Name` – UTF-8 字符串，长度不少于 1 个字节或超过 255 个字节，与 [Single-line string pattern](aws-glue-api-common.md#aws-glue-api-regex-oneLine) 匹配。

  指定 SessionCommand 的名称。可以是“gluetel”或“gluestreaming”。
+ `PythonVersion` – UTF-8 字符串，与 [Custom string pattern #49](aws-glue-api-common.md#regex_49) 匹配。

  指定 Python 版本。Python 版本指示了 Spark 类型的任务支持的版本。

## Statement 结构
<a name="aws-glue-api-interactive-sessions-Statement"></a>

在会话中实现特定操作的语句或请求。

**Fields**
+ `Id` – 数字（整数）。

  语句的 ID。
+ `Code` – UTF-8 字符串。

  语句的执行代码。
+ `State` – UTF-8 字符串（有效值：`WAITING` \$1`RUNNING` \$1`AVAILABLE` \$1`CANCELLING` \$1`CANCELLED` \$1`ERROR` ）。

  执行请求时的状态。
+ `Output` – 一个 [StatementOutput](#aws-glue-api-interactive-sessions-StatementOutput) 对象。

  JSON 中的输出。
+ `Progress` – 数字（double）。

  代码执行进度。
+ `StartedOn` – 数字（长型）。

  任务定义开始的 Unix 时间和日期。
+ `CompletedOn` – 数字（长型）。

  任务定义完成的 Unix 时间和日期。

## StatementOutput 结构
<a name="aws-glue-api-interactive-sessions-StatementOutput"></a>

JSON 格式的代码执行输出。

**Fields**
+ `Data` – 一个 [StatementOutputData](#aws-glue-api-interactive-sessions-StatementOutputData) 对象。

  代码执行输出。
+ `ExecutionCount` – 数字（整数）。

  输出的执行计数。
+ `Status` – UTF-8 字符串（有效值：`WAITING` \$1`RUNNING` \$1`AVAILABLE` \$1`CANCELLING` \$1`CANCELLED` \$1`ERROR` ）。

  代码执行输出的状态。
+ `ErrorName` – UTF-8 字符串。

  输出中的错误名称。
+ `ErrorValue` – UTF-8 字符串。

  输出的错误值。
+ `Traceback` – UTF-8 字符串数组。

  输出的回溯。

## StatementOutputData 结构
<a name="aws-glue-api-interactive-sessions-StatementOutputData"></a>

JSON 格式的代码执行输出。

**Fields**
+ `TextPlain` – UTF-8 字符串。

  文本格式的代码执行输出。

## ConnectionsList 结构
<a name="aws-glue-api-interactive-sessions-ConnectionsList"></a>

指定作业所使用的连接。

**Fields**
+ `Connections` – UTF-8 字符串数组，不超过 1000 个字符串。

  作业所使用的连接的列表。

## 操作
<a name="aws-glue-api-interactive-sessions-actions"></a>
+ [CreateSession 操作（Python：create\$1session）](#aws-glue-api-interactive-sessions-CreateSession)
+ [StopSession 操作（Python：stop\$1session）](#aws-glue-api-interactive-sessions-StopSession)
+ [DeleteSession 操作（Python：delete\$1session）](#aws-glue-api-interactive-sessions-DeleteSession)
+ [GetSession 操作（Python：get\$1session）](#aws-glue-api-interactive-sessions-GetSession)
+ [ListSession 操作（Python：list\$1ession）](#aws-glue-api-interactive-sessions-ListSessions)
+ [RunStatement 操作（Python：run\$1statement）](#aws-glue-api-interactive-sessions-RunStatement)
+ [CancelStatement 操作（Python：cancel\$1statement）](#aws-glue-api-interactive-sessions-CancelStatement)
+ [GetStatement 操作（Python：get\$1statement）](#aws-glue-api-interactive-sessions-GetStatement)
+ [ListStatements 操作（Python：list\$1statements）](#aws-glue-api-interactive-sessions-ListStatements)
+ [GetGlueIdentityCenterConfiguration 操作（Python：get\$1glue\$1identity\$1center\$1configuration）](#aws-glue-api-interactive-sessions-GetGlueIdentityCenterConfiguration)
+ [UpdateGlueIdentityCenterConfiguration 操作（Python：update\$1glue\$1identity\$1center\$1configuration）](#aws-glue-api-interactive-sessions-UpdateGlueIdentityCenterConfiguration)
+ [CreateGlueIdentityCenterConfiguration 操作（Python：create\$1glue\$1identity\$1center\$1configuration）](#aws-glue-api-interactive-sessions-CreateGlueIdentityCenterConfiguration)
+ [DeleteGlueIdentityCenterConfiguration 操作（Python：delete\$1glue\$1identity\$1center\$1configuration）](#aws-glue-api-interactive-sessions-DeleteGlueIdentityCenterConfiguration)

## CreateSession 操作（Python：create\$1session）
<a name="aws-glue-api-interactive-sessions-CreateSession"></a>

创建新的会话。

**请求**

请求创建新的会话。
+ `Id` – *必填：*UTF-8 字符串，长度不少于 1 个字节或超过 255 个字节，与 [Single-line string pattern](aws-glue-api-common.md#aws-glue-api-regex-oneLine) 匹配。

  会话请求 ID。
+ `Description` – 描述字符串，长度不超过 2048 个字节，与 [URI address multi-line string pattern](aws-glue-api-common.md#aws-glue-api-regex-uri) 匹配。

  会话描述。
+ `Role` – *必需：*UTF-8 字符串，长度不少于 20 个字节，不超过 2048 个字节，与 [Custom string pattern #30](aws-glue-api-common.md#regex_30) 匹配。

  IAM 角色 ARN 
+ `Command` – *必填：*一个 [SessionCommand](#aws-glue-api-interactive-sessions-SessionCommand) 对象。

  运行任务的 `SessionCommand`。
+ `Timeout` - 数字（整数），至少为 1。

   会话超时前的分钟数。Spark ETL 作业的默认值为 48 小时（2880 分钟）。有关其他作业类型，请查阅文档。
+ `IdleTimeout` - 数字（整数），至少为 1。

   会话超时前的空闲分钟数。Spark ETL 作业的默认值为“超时”。有关其他作业类型，请查阅文档。
+ `DefaultArguments` – 键值对的映射数组，不超过 75 对。

  每个键是一个 UTF-8 字符串，不少于 1 个字节或超过 128 个字节，与 [Custom string pattern #31](aws-glue-api-common.md#regex_31) 匹配。

  每个值都是一个 UTF-8 字符串，长度不超过 4096 个字节，与 [URI address multi-line string pattern](aws-glue-api-common.md#aws-glue-api-regex-uri) 匹配。

  键值对的映射数组。最多 75 对。
+ `Connections` – 一个 [ConnectionsList](#aws-glue-api-interactive-sessions-ConnectionsList) 对象。

  用于会话的连接数。
+ `MaxCapacity` – 数字（double）。

  任务运行时可分配的 Amazon Glue 数据处理单元 (DPU) 的数量。DPU 是对处理能力的相对度量，它由 4 个 vCPU 的计算容量和 16GB 内存组成。
+ `NumberOfWorkers` – 数字（整数）。

  用于会话的已定义 `WorkerType` 的工件数量。
+ `WorkerType` – UTF-8 字符串（有效值：`Standard=""` \$1`G.1X=""` \$1`G.2X=""` \$1`G.025X=""` \$1`G.4X=""` \$1`G.8X=""` \$1`Z.2X=""` ）。

  任务运行时分配的预定义工作线程的类型。接受 G.1X、G.2X、G.4X 或 G.8X for Spark 作业的值。接受 Ray 笔记本的值 Z.2X。
  + 对于 `G.1X` 工作线程类型，每个工作线程映射到 1 个 DPU（4 个 vCPU，16GB 内存），94GB 磁盘，并且每个工作线程提供 1 个执行程序。我们建议将这种工作线程类型用于数据转换、联接和查询等工作负载，以提供一种可扩展且经济实惠的方式来运行大多数作业。
  + 对于 `G.2X` 工作线程类型，每个工作线程映射到 2 个 DPU（8 个 vCPU，32GB 内存），138GB 磁盘，并且每个工作线程提供 1 个执行程序。我们建议将这种工作线程类型用于数据转换、联接和查询等工作负载，以提供一种可扩展且经济实惠的方式来运行大多数作业。
  + 对于 `G.4X` 工作线程类型，每个工作线程映射到 4 个 DPU（16 个 vCPU，64GB 内存），256GB 磁盘，并且每个工作线程提供 1 个执行程序。对于工作负载包含要求最高的转换、聚合、联接和查询的作业，我们建议使用这种工作线程类型。此工作线程类型仅适用于以下 Amazon 区域的 Amazon Glue 3.0 版或更高版本的 Spark ETL 作业：美国东部（俄亥俄州）、美国东部（弗吉尼亚州北部）、美国西部（俄勒冈州）、亚太地区（新加坡）、亚太地区（悉尼）、亚太地区（东京）、加拿大（中部）、欧洲地区（法兰克福）、欧洲地区（爱尔兰）和欧洲地区（斯德哥尔摩）。
  + 对于 `G.8X` 工作线程类型，每个工作线程映射到 8 个 DPU（32 个 vCPU，128GB 内存），512GB 磁盘，并且每个工作线程提供 1 个执行程序。对于工作负载包含要求最高的转换、聚合、联接和查询的作业，我们建议使用这种工作线程类型。此工作线程类型仅适用于 Amazon Glue 3.0 版或更高版本的 Spark ETL 作业，其区域与 `G.4X` 工作线程类型支持的 Amazon 区域相同。
  + 对于 `Z.2X` 工作线程类型，每个工作线程映射到 2 个 M-DPU（8 个 vCPU，64GB 内存），128GB 磁盘，基于自动缩放器最多提供 8 个 Ray 工作线程。
+ `SecurityConfiguration` – UTF-8 字符串，长度不少于 1 个字节或超过 255 个字节，与 [Single-line string pattern](aws-glue-api-common.md#aws-glue-api-regex-oneLine) 匹配。

  会话要使用的 SecurityConfiguration 结构的名称。
+ `GlueVersion` – UTF-8 字符串，长度不少于 1 个字节或超过 255 个字节，与 [Custom string pattern #48](aws-glue-api-common.md#regex_48) 匹配。

  Amazon Glue 版本决定了 Amazon Glue 支持的 Apache Spark 和 Python 版本。GlueVersion 必须大于 2.0。
+ `DataAccessId` – UTF-8 字符串，长度不少于 1 个字节，不超过 36 个字节。

  会话的数据访问 ID。
+ `PartitionId` – UTF-8 字符串，长度不少于 1 个字节，不超过 36 个字节。

  会话的分区 ID。
+ `Tags` – 键值对的映射数组，不超过 50 对。

  每个键都是一个 UTF-8 字符串，长度不少于 1 个字节或超过 128 个字节。

  每个值是一个 UTF-8 字符串，不超过 256 个字节。

  属于会话的键值对（标签）的映射。
+ `RequestOrigin` – UTF-8 字符串，长度不少于 1 个字节或超过 128 个字节，与 [Custom string pattern #31](aws-glue-api-common.md#regex_31) 匹配。

  请求的源。
+ `ProfileName` – UTF-8 字符串，长度不少于 1 个字节或超过 255 个字节，与 [Single-line string pattern](aws-glue-api-common.md#aws-glue-api-regex-oneLine) 匹配。

  与会话关联的 Amazon Glue 使用情况配置文件名称。

**响应**
+ `Session` – 一个 [Session](#aws-glue-api-interactive-sessions-Session) 对象。

  返回响应中的会话对象。

**错误**
+ `AccessDeniedException`
+ `IdempotentParameterMismatchException`
+ `InternalServiceException`
+ `OperationTimeoutException`
+ `InvalidInputException`
+ `ValidationException`
+ `AlreadyExistsException`
+ `ResourceNumberLimitExceededException`

## StopSession 操作（Python：stop\$1session）
<a name="aws-glue-api-interactive-sessions-StopSession"></a>

停止会话。

**请求**
+ `Id` – *必填：*UTF-8 字符串，长度不少于 1 个字节或超过 255 个字节，与 [Single-line string pattern](aws-glue-api-common.md#aws-glue-api-regex-oneLine) 匹配。

  要停止的会话 ID。
+ `RequestOrigin` – UTF-8 字符串，长度不少于 1 个字节或超过 128 个字节，与 [Custom string pattern #31](aws-glue-api-common.md#regex_31) 匹配。

  请求的源。

**响应**
+ `Id` – UTF-8 字符串，长度不少于 1 个字节或超过 255 个字节，与 [Single-line string pattern](aws-glue-api-common.md#aws-glue-api-regex-oneLine) 匹配。

  返回已停止会话的 ID。

**错误**
+ `AccessDeniedException`
+ `InternalServiceException`
+ `OperationTimeoutException`
+ `InvalidInputException`
+ `IllegalSessionStateException`
+ `ConcurrentModificationException`

## DeleteSession 操作（Python：delete\$1session）
<a name="aws-glue-api-interactive-sessions-DeleteSession"></a>

删除会话。

**请求**
+ `Id` – *必填：*UTF-8 字符串，长度不少于 1 个字节或超过 255 个字节，与 [Single-line string pattern](aws-glue-api-common.md#aws-glue-api-regex-oneLine) 匹配。

  要删除的会话 ID。
+ `RequestOrigin` – UTF-8 字符串，长度不少于 1 个字节或超过 128 个字节，与 [Custom string pattern #31](aws-glue-api-common.md#regex_31) 匹配。

  删除会话请求的源名称。

**响应**
+ `Id` – UTF-8 字符串，长度不少于 1 个字节或超过 255 个字节，与 [Single-line string pattern](aws-glue-api-common.md#aws-glue-api-regex-oneLine) 匹配。

  返回要删除会话 ID。

**错误**
+ `AccessDeniedException`
+ `InternalServiceException`
+ `OperationTimeoutException`
+ `InvalidInputException`
+ `IllegalSessionStateException`
+ `ConcurrentModificationException`

## GetSession 操作（Python：get\$1session）
<a name="aws-glue-api-interactive-sessions-GetSession"></a>

检索会话。

**请求**
+ `Id` – *必填：*UTF-8 字符串，长度不少于 1 个字节或超过 255 个字节，与 [Single-line string pattern](aws-glue-api-common.md#aws-glue-api-regex-oneLine) 匹配。

  会话 ID。
+ `RequestOrigin` – UTF-8 字符串，长度不少于 1 个字节或超过 128 个字节，与 [Custom string pattern #31](aws-glue-api-common.md#regex_31) 匹配。

  请求的源。

**响应**
+ `Session` – 一个 [Session](#aws-glue-api-interactive-sessions-Session) 对象。

  响应中会返回会话对象。

**错误**
+ `AccessDeniedException`
+ `EntityNotFoundException`
+ `InternalServiceException`
+ `OperationTimeoutException`
+ `InvalidInputException`

## ListSession 操作（Python：list\$1ession）
<a name="aws-glue-api-interactive-sessions-ListSessions"></a>

检索会话列表。

**请求**
+ `NextToken` – UTF-8 字符串，长度不超过 400000 个字节。

  下一组结果的令牌，没有更多结果时为 null。
+ `MaxResults` – 数字（整数），不小于 1 或大于 1000。

  最大结果数量。
+ `Tags` – 键值对的映射数组，不超过 50 对。

  每个键都是一个 UTF-8 字符串，长度不少于 1 个字节或超过 128 个字节。

  每个值是一个 UTF-8 字符串，不超过 256 个字节。

  属于会话的标签。
+ `RequestOrigin` – UTF-8 字符串，长度不少于 1 个字节或超过 128 个字节，与 [Custom string pattern #31](aws-glue-api-common.md#regex_31) 匹配。

  请求的源。

**响应**
+ `Ids` – UTF-8 字符串数组。

  返回会话 ID。
+ `Sessions` – [Session](#aws-glue-api-interactive-sessions-Session) 对象的数组。

  返回会话对象。
+ `NextToken` – UTF-8 字符串，长度不超过 400000 个字节。

  下一组结果的令牌，没有更多结果时为 null。

**错误**
+ `AccessDeniedException`
+ `InvalidInputException`
+ `InternalServiceException`
+ `OperationTimeoutException`

## RunStatement 操作（Python：run\$1statement）
<a name="aws-glue-api-interactive-sessions-RunStatement"></a>

执行语句。

**请求**
+ `SessionId` – *必填：*UTF-8 字符串，长度不少于 1 个字节或超过 255 个字节，与 [Single-line string pattern](aws-glue-api-common.md#aws-glue-api-regex-oneLine) 匹配。

  要运行的语句的会话 ID。
+ `Code` – *必需：* UTF-8 字符串，长度不超过 68000 个字节。

  要运行的语句代码。
+ `RequestOrigin` – UTF-8 字符串，长度不少于 1 个字节或超过 128 个字节，与 [Custom string pattern #31](aws-glue-api-common.md#regex_31) 匹配。

  请求的源。

**响应**
+ `Id` – 数字（整数）。

  返回所运行的语句的 ID。

**错误**
+ `EntityNotFoundException`
+ `AccessDeniedException`
+ `InternalServiceException`
+ `OperationTimeoutException`
+ `InvalidInputException`
+ `ValidationException`
+ `ResourceNumberLimitExceededException`
+ `IllegalSessionStateException`

## CancelStatement 操作（Python：cancel\$1statement）
<a name="aws-glue-api-interactive-sessions-CancelStatement"></a>

取消语句。

**请求**
+ `SessionId` – *必填：*UTF-8 字符串，长度不少于 1 个字节或超过 255 个字节，与 [Single-line string pattern](aws-glue-api-common.md#aws-glue-api-regex-oneLine) 匹配。

  要取消的语句的会话 ID。
+ `Id` – *必填*：数字（整数）。

  要取消的语句的 ID。
+ `RequestOrigin` – UTF-8 字符串，长度不少于 1 个字节或超过 128 个字节，与 [Custom string pattern #31](aws-glue-api-common.md#regex_31) 匹配。

  用于取消语句的请求的源。

**响应**
+ *无响应参数。*

**错误**
+ `AccessDeniedException`
+ `EntityNotFoundException`
+ `InternalServiceException`
+ `OperationTimeoutException`
+ `InvalidInputException`
+ `IllegalSessionStateException`

## GetStatement 操作（Python：get\$1statement）
<a name="aws-glue-api-interactive-sessions-GetStatement"></a>

检索语句。

**请求**
+ `SessionId` – *必填：*UTF-8 字符串，长度不少于 1 个字节或超过 255 个字节，与 [Single-line string pattern](aws-glue-api-common.md#aws-glue-api-regex-oneLine) 匹配。

  语句的会话 ID。
+ `Id` – *必填*：数字（整数）。

  语句的 ID。
+ `RequestOrigin` – UTF-8 字符串，长度不少于 1 个字节或超过 128 个字节，与 [Custom string pattern #31](aws-glue-api-common.md#regex_31) 匹配。

  请求的源。

**响应**
+ `Statement` – 一个 [语句](#aws-glue-api-interactive-sessions-Statement) 对象。

  返回语句。

**错误**
+ `AccessDeniedException`
+ `EntityNotFoundException`
+ `InternalServiceException`
+ `OperationTimeoutException`
+ `InvalidInputException`
+ `IllegalSessionStateException`

## ListStatements 操作（Python：list\$1statements）
<a name="aws-glue-api-interactive-sessions-ListStatements"></a>

列出会话的语句。

**请求**
+ `SessionId` – *必填：*UTF-8 字符串，长度不少于 1 个字节或超过 255 个字节，与 [Single-line string pattern](aws-glue-api-common.md#aws-glue-api-regex-oneLine) 匹配。

  语句的会话 ID。
+ `RequestOrigin` – UTF-8 字符串，长度不少于 1 个字节或超过 128 个字节，与 [Custom string pattern #31](aws-glue-api-common.md#regex_31) 匹配。

  用于列出语句的请求的源。
+ `NextToken` – UTF-8 字符串，长度不超过 400000 个字节。

  延续标记 (如果这是延续调用)。

**响应**
+ `Statements` – [语句](#aws-glue-api-interactive-sessions-Statement) 对象的数组。

  返回语句列表。
+ `NextToken` – UTF-8 字符串，长度不超过 400000 个字节。

  延续令牌（如果尚未返回所有语句）。

**错误**
+ `AccessDeniedException`
+ `EntityNotFoundException`
+ `InternalServiceException`
+ `OperationTimeoutException`
+ `InvalidInputException`
+ `IllegalSessionStateException`

## GetGlueIdentityCenterConfiguration 操作（Python：get\$1glue\$1identity\$1center\$1configuration）
<a name="aws-glue-api-interactive-sessions-GetGlueIdentityCenterConfiguration"></a>

检索当前 Amazon Glue Identity Center 配置详细信息，包括关联的 Identity Center 实例和应用程序信息。

**请求**
+ *无请求参数。*

**响应**

包含 Amazon Glue Identity Center 配置详细信息的响应。
+ `ApplicationArn`：UTF-8 字符串，长度不少于 10 个字节，不超过 1224 个字节。

  与 Amazon Glue 配置关联的 Identity Center 应用程序的 Amazon 资源名称（ARN）。
+ `InstanceArn`：UTF-8 字符串，长度不少于 10 个字节，不超过 1224 个字节。

  与 Amazon Glue 配置关联的 Identity Center 实例的 Amazon 资源名称（ARN）。
+ `Scopes` – UTF-8 字符串数组。

  为 Amazon Glue 配置定义权限和访问级别的 Identity Center 作用域列表。

**错误**
+ `InvalidInputException`
+ `EntityNotFoundException`
+ `InternalServiceException`
+ `OperationTimeoutException`
+ `AccessDeniedException`
+ `ConcurrentModificationException`

## UpdateGlueIdentityCenterConfiguration 操作（Python：update\$1glue\$1identity\$1center\$1configuration）
<a name="aws-glue-api-interactive-sessions-UpdateGlueIdentityCenterConfiguration"></a>

更新现有 Amazon Glue Identity Center 配置，从而允许修改集成的作用域和权限。

**请求**

请求更新现有的 Amazon Glue Identity Center 配置。
+ `Scopes` – UTF-8 字符串数组，不少于 1 个字符串，不超过 50 个字符串。

  为 Amazon Glue 配置定义更新后权限和访问级别的 Identity Center 作用域列表。

**响应**
+ *无响应参数。*

**错误**
+ `InvalidInputException`
+ `EntityNotFoundException`
+ `InternalServiceException`
+ `OperationTimeoutException`
+ `AccessDeniedException`
+ `ConcurrentModificationException`

## CreateGlueIdentityCenterConfiguration 操作（Python：create\$1glue\$1identity\$1center\$1configuration）
<a name="aws-glue-api-interactive-sessions-CreateGlueIdentityCenterConfiguration"></a>

创建新的 Amazon Glue Identity Center 配置，以在 Amazon Glue 与 Amazon IAM Identity Center 之间实现集成，从而用于身份验证和授权。

**请求**

请求创建新的 Amazon Glue Identity Center 配置。
+ `InstanceArn`：*（必需）*UTF-8 字符串，长度不少于 10 个字节，不超过 1224 个字节。

  将与 Amazon Glue 配置关联的 Identity Center 实例的 Amazon 资源名称（ARN）。
+ `Scopes` – UTF-8 字符串数组，不少于 1 个字符串，不超过 50 个字符串。

  为 Amazon Glue 配置定义权限和访问级别的 Identity Center 作用域列表。

**响应**

创建新 Amazon Glue Identity Center 配置的响应。
+ `ApplicationArn`：UTF-8 字符串，长度不少于 10 个字节，不超过 1224 个字节。

  与 Amazon Glue 配置创建的 Identity Center 应用程序的 Amazon 资源名称（ARN）。

**错误**
+ `InvalidInputException`
+ `AlreadyExistsException`
+ `InternalServiceException`
+ `OperationTimeoutException`
+ `AccessDeniedException`
+ `ConcurrentModificationException`

## DeleteGlueIdentityCenterConfiguration 操作（Python：delete\$1glue\$1identity\$1center\$1configuration）
<a name="aws-glue-api-interactive-sessions-DeleteGlueIdentityCenterConfiguration"></a>

删除现有的 Amazon Glue Identity Center 配置，并移除 Amazon Glue 与 Amazon IAM Identity Center 之间的集成。

**请求**
+ *无请求参数。*

**响应**
+ *无响应参数。*

**错误**
+ `InvalidInputException`
+ `EntityNotFoundException`
+ `InternalServiceException`
+ `OperationTimeoutException`
+ `AccessDeniedException`
+ `ConcurrentModificationException`