AS AgentScopeAPI 手册 / API Reference

GitLabChannelProperties

public record GitLabChannelProperties( String token, String webhookToken, String apiBase, String webhookPath)
源码Source io/agentscope/extensions/channel/gitlab/GitLabChannelProperties.java:34–75

承载 GitLab 渠道属性数据的记录类型。位于 io.agentscope.extensions.channel.gitlab 包。核心成员包括 token、webhookToken、apiBase、webhookPath、from、GitLabChannelProperties。

Provider-specific configuration for a single GitLab channel instance, sourced from the properties block of channels.<id> in agentscope.json.

记录组件摘要Record Component Summary

组件Component类型Type说明Description
tokenString
执行令牌相关操作。
Project / Group / Personal Access Token used for the REST API outbound and bot-identity lookup. Required, with `api` scope.
webhookTokenString
执行 `webhookToken` 方法。
shared token configured on the project webhook; matched against `X-Gitlab-Token` via constant-time equality. Required.
apiBaseString
执行API 基类相关操作。
override for the GitLab REST API base; defaults to `https://gitlab.com/api/v4`.
webhookPathString
执行 `webhookPath` 方法。
HTTP path Spring exposes the webhook under; defaults to `/api/channels/gitlab/{channelId}/webhook`

构造器摘要Constructor Summary

构造器Constructor说明Description
public GitLabChannelProperties(String token, String webhookToken, String apiBase, String webhookPath)
初始化 `GitLabChannelProperties` 实例。
Creates a new instance.

方法摘要Method Summary

方法Method说明Description
public static GitLabChannelProperties from(String channelId, Map<String, Object> props)
static
创建并返回实例。
Reads a `GitLabChannelProperties` from an arbitrary properties map.

记录组件详情Record Component Detail

token

String token

执行令牌相关操作。

Project / Group / Personal Access Token used for the REST API outbound and bot-identity lookup. Required, with api scope.

源码Source io/agentscope/extensions/channel/gitlab/GitLabChannelProperties.java:34–75

webhookToken

String webhookToken

执行 webhookToken 方法。

shared token configured on the project webhook; matched against X-Gitlab-Token via constant-time equality. Required.

源码Source io/agentscope/extensions/channel/gitlab/GitLabChannelProperties.java:34–75

apiBase

String apiBase

执行API 基类相关操作。

override for the GitLab REST API base; defaults to https://gitlab.com/api/v4.

源码Source io/agentscope/extensions/channel/gitlab/GitLabChannelProperties.java:34–75

webhookPath

String webhookPath

执行 webhookPath 方法。

HTTP path Spring exposes the webhook under; defaults to /api/channels/gitlab/{channelId}/webhook

源码Source io/agentscope/extensions/channel/gitlab/GitLabChannelProperties.java:34–75

构造器详情Constructor Detail

GitLabChannelProperties

public GitLabChannelProperties(String token, String webhookToken, String apiBase, String webhookPath)

初始化 GitLabChannelProperties 实例。

Creates a new instance.

参数Parameters
名称Name类型Type说明Description
tokenString令牌(类型 `String`)。The token.
webhookTokenStringwebhook 令牌(类型 `String`)。The webhook token.
apiBaseStringAPI 基类(类型 `String`)。The api base.
webhookPathStringwebhook 路径(类型 `String`)。The webhook path.
源码Source io/agentscope/extensions/channel/gitlab/GitLabChannelProperties.java:37–52

方法详情Method Detail

from

public static GitLabChannelProperties from(String channelId, Map<String, Object> props)
static

创建并返回实例。

Reads a GitLabChannelProperties from an arbitrary properties map.

参数Parameters
名称Name类型Type说明Description
channelIdString渠道标识(类型 `String`)。The channel id.
propsMap<String, Object>props(类型 `Map`)。The props.
返回Returns GitLabChannelProperties
返回GitLabChannelProperties。Returns gitlab channel properties.
源码Source io/agentscope/extensions/channel/gitlab/GitLabChannelProperties.java:55–64
基于官方固定版本源码静态生成Generated from pinned official sources · Python 2.0.11 · Java 2.0.4
签名与文档为静态抽取;如有疑问请以源码为准。Signatures and docs are extracted statically; verify against the source when in doubt.