EnvironmentApiKeyVerifier
@FunctionalInterface public interface EnvironmentApiKeyVerifier
源码Source
io/agentscope/builder/web/auth/EnvironmentApiKeyVerifier.java:22–31定义环境 API 键校验器契约的接口。位于 io.agentscope.builder.web.auth 包。核心成员包括 matches。
Verifies an Environment Worker API key against control-plane state. Implementations must not read control-plane tables from the data plane; call the CP internal API instead.
方法摘要Method Summary
| 方法Method | 说明Description |
|---|---|
public boolean matches(String environmentId, String plaintextKey) | 执行 `matches` 方法。 Performs the matches operation. |
方法详情Method Detail
matches
public boolean matches(String environmentId, String plaintextKey)
执行 matches 方法。
Performs the matches operation.
参数Parameters
| 名称Name | 类型Type | 说明Description |
|---|---|---|
environmentId | String | 环境标识(类型 `String`)。environment id from the request path |
plaintextKey | String | `X-Builder-Environment-Key`的值。value of `X-Builder-Environment-Key` |
boolean返回布尔值,表示判断结果。true when the key is valid for the environment
源码Source
io/agentscope/builder/web/auth/EnvironmentApiKeyVerifier.java:30