AS AgentScopeAPI 手册 / API Reference

WeixinChannelProperties

public record WeixinChannelProperties( String accountId, String baseUrl, String ilinkUserId, String channelVersion, String botAgent, int longPollTimeoutMs, int requestTimeoutMs, int maxBackoffMs, int leaseMs, int dispatchTimeoutMs)
源码Source io/agentscope/extensions/channel/weixin/WeixinChannelProperties.java:28–83

承载 Weixin 渠道属性数据的记录类型。位于 io.agentscope.extensions.channel.weixin 包。核心成员包括 accountId、baseUrl、ilinkUserId、channelVersion、botAgent、longPollTimeoutMs。

Provider configuration for one Personal Weixin Channel instance.

requestTimeoutMs bounds the control calls, while longPollTimeoutMs bounds the getupdates long poll — the provider holds that request open, so the client derives a longer deadline for it (see WeixinOutboundClient.timeoutFor).

记录组件摘要Record Component Summary

组件Component类型Type说明Description
accountIdString
执行 `accountId` 方法。
Performs the account id operation.
baseUrlString
执行基类 URL相关操作。
Performs the base url operation.
ilinkUserIdString
执行 `ilinkUserId` 方法。
Performs the ilink user id operation.
channelVersionString
执行渠道版本相关操作。
Performs the channel version operation.
botAgentString
执行 `botAgent` 方法。
Performs the bot agent operation.
longPollTimeoutMsint
执行 `longPollTimeoutMs` 方法。
Performs the long poll timeout ms operation.
requestTimeoutMsint
执行请求超时 Ms相关操作。
Performs the request timeout ms operation.
maxBackoffMsint
执行最大退避 Ms相关操作。
Performs the max backoff ms operation.
leaseMsint
执行 `leaseMs` 方法。
Performs the lease ms operation.
dispatchTimeoutMsint
执行 `dispatchTimeoutMs` 方法。
Performs the dispatch timeout ms operation.

字段摘要Field Summary

字段Field类型Type说明Description
DEFAULT_BASE_URL
staticfinal
String
默认基类 URL字段。
The DEFAULT BASE URL field.

构造器摘要Constructor Summary

构造器Constructor说明Description
public WeixinChannelProperties(String accountId, String baseUrl, String ilinkUserId, String channelVersion, String botAgent, int longPollTimeoutMs, int requestTimeoutMs, int maxBackoffMs, int leaseMs, int dispatchTimeoutMs)
初始化 `WeixinChannelProperties` 实例。
Creates a new instance.

方法摘要Method Summary

方法Method说明Description
public static WeixinChannelProperties from(String channelId, Map<String, Object> raw)
static
创建并返回实例。
Creates and returns an instance.

记录组件详情Record Component Detail

accountId

String accountId

执行 accountId 方法。

Performs the account id operation.

源码Source io/agentscope/extensions/channel/weixin/WeixinChannelProperties.java:28–83

baseUrl

String baseUrl

执行基类 URL相关操作。

Performs the base url operation.

源码Source io/agentscope/extensions/channel/weixin/WeixinChannelProperties.java:28–83

ilinkUserId

String ilinkUserId

执行 ilinkUserId 方法。

Performs the ilink user id operation.

源码Source io/agentscope/extensions/channel/weixin/WeixinChannelProperties.java:28–83

channelVersion

String channelVersion

执行渠道版本相关操作。

Performs the channel version operation.

源码Source io/agentscope/extensions/channel/weixin/WeixinChannelProperties.java:28–83

botAgent

String botAgent

执行 botAgent 方法。

Performs the bot agent operation.

源码Source io/agentscope/extensions/channel/weixin/WeixinChannelProperties.java:28–83

longPollTimeoutMs

int longPollTimeoutMs

执行 longPollTimeoutMs 方法。

Performs the long poll timeout ms operation.

源码Source io/agentscope/extensions/channel/weixin/WeixinChannelProperties.java:28–83

requestTimeoutMs

int requestTimeoutMs

执行请求超时 Ms相关操作。

Performs the request timeout ms operation.

源码Source io/agentscope/extensions/channel/weixin/WeixinChannelProperties.java:28–83

maxBackoffMs

int maxBackoffMs

执行最大退避 Ms相关操作。

Performs the max backoff ms operation.

源码Source io/agentscope/extensions/channel/weixin/WeixinChannelProperties.java:28–83

leaseMs

int leaseMs

执行 leaseMs 方法。

Performs the lease ms operation.

源码Source io/agentscope/extensions/channel/weixin/WeixinChannelProperties.java:28–83

dispatchTimeoutMs

int dispatchTimeoutMs

执行 dispatchTimeoutMs 方法。

Performs the dispatch timeout ms operation.

源码Source io/agentscope/extensions/channel/weixin/WeixinChannelProperties.java:28–83

字段详情Field Detail

DEFAULT_BASE_URL

public static final String DEFAULT_BASE_URL
staticfinal

默认基类 URL字段。声明为 public static final String DEFAULT_BASE_URL。

The DEFAULT BASE URL field.

源码Source io/agentscope/extensions/channel/weixin/WeixinChannelProperties.java:39

构造器详情Constructor Detail

WeixinChannelProperties

public WeixinChannelProperties(String accountId, String baseUrl, String ilinkUserId, String channelVersion, String botAgent, int longPollTimeoutMs, int requestTimeoutMs, int maxBackoffMs, int leaseMs, int dispatchTimeoutMs)

初始化 WeixinChannelProperties 实例。

Creates a new instance.

参数Parameters
名称Name类型Type说明Description
accountIdStringaccount 标识(类型 `String`)。The account id.
baseUrlString基类 URL(类型 `String`)。The base url.
ilinkUserIdStringilink 用户标识(类型 `String`)。The ilink user id.
channelVersionString渠道版本(类型 `String`)。The channel version.
botAgentStringbot 智能体(类型 `String`)。The bot agent.
longPollTimeoutMsintlong Poll 超时 Ms(类型 `int`)。The long poll timeout ms.
requestTimeoutMsint请求超时 Ms(类型 `int`)。The request timeout ms.
maxBackoffMsint最大退避 Ms(类型 `int`)。The max backoff ms.
leaseMsintlease Ms(类型 `int`)。The lease ms.
dispatchTimeoutMsintdispatch 超时 Ms(类型 `int`)。The dispatch timeout ms.
源码Source io/agentscope/extensions/channel/weixin/WeixinChannelProperties.java:41–51

方法详情Method Detail

from

public static WeixinChannelProperties from(String channelId, Map<String, Object> raw)
static

创建并返回实例。

Creates and returns an instance.

参数Parameters
名称Name类型Type说明Description
channelIdString渠道标识(类型 `String`)。The channel id.
rawMap<String, Object>原始(类型 `Map`)。The raw.
返回Returns WeixinChannelProperties
返回WeixinChannelProperties。Returns weixin channel properties.
源码Source io/agentscope/extensions/channel/weixin/WeixinChannelProperties.java:53–67
基于官方固定版本源码静态生成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.