惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

MongoDB | Blog
MongoDB | Blog
J
Java Code Geeks
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻
D
DataBreaches.Net
腾讯CDC
GbyAI
GbyAI
I
InfoQ
博客园 - Franky
G
Google Developers Blog
Last Week in AI
Last Week in AI
奇客Solidot–传递最新科技情报
奇客Solidot–传递最新科技情报
V
Visual Studio Blog
Vercel News
Vercel News
博客园_首页
MyScale Blog
MyScale Blog
Martin Fowler
Martin Fowler
N
Netflix TechBlog - Medium
V
V2EX
T
The Blog of Author Tim Ferriss
M
MIT News - Artificial intelligence
雷峰网
雷峰网
H
Hackread – Cybersecurity News, Data Breaches, AI and More
大猫的无限游戏
大猫的无限游戏
The GitHub Blog
The GitHub Blog

Recent Commits to openclaw:main

test: merge chat side-result checks · openclaw/openclaw@ddd2c2a test: merge cron history checks · openclaw/openclaw@f7eb746 test: merge responsive navigation shell checks · openclaw/openclaw@c2e4b47 docs(changelog): add codex oauth fixes · openclaw/openclaw@628e6cd test: merge navigation routing cases · openclaw/openclaw@5d8cecb Tests: mock channel registry bundled fallback · openclaw/openclaw@2b08233 Secrets: avoid broad web search discovery for single plugin config · openclaw/openclaw@a464f59 test: merge config view browser checks · openclaw/openclaw@20cf511 fix(status): align oauth health with runtime · openclaw/openclaw@eed7116 feat: add macOS screen snapshots for monitor preview (#67954) thanks … · openclaw/openclaw@f377db1 fix: report shared auth scopes in hello-ok (#67810) thanks @BunsDev · openclaw/openclaw@0b6c39b Auto-reply: avoid eager bundled route fallback · openclaw/openclaw@3ea1bf4 Tests: narrow session binding contract setup · openclaw/openclaw@54e4e16 fix(macOS): enable undo/redo in webchat composer text input (#34962) · openclaw/openclaw@00951dc Tests: speed up channel setup promotion · openclaw/openclaw@82b529a Docs: refresh agent instructions · openclaw/openclaw@5775fe2 fix(auth): serialize OAuth refresh across agents to fix #26322 (#67876) · openclaw/openclaw@8e79080 test: allow ollama public surface boundary test · openclaw/openclaw@7d4f1a6 Docs: add test performance guardrails · openclaw/openclaw@89706d3 Tests: restore context-engine usage proof · openclaw/openclaw@e4c4f95 Tests: slim context engine runtime coverage · openclaw/openclaw@74c198f ci: retry failed custom checkouts · openclaw/openclaw@0ee5baf test: trim duplicate provider auth onboarding cases · openclaw/openclaw@1ffc02e matrix: fix sessions_spawn --thread subagent session spawning (#67643) · openclaw/openclaw@1ce2596 test: reduce auth choice fixture churn · openclaw/openclaw@857b9cd test: mock health status config boundaries · openclaw/openclaw@9d5ab4a test: mock onboard config io boundary · openclaw/openclaw@299694d test: mock legacy state plugin boundaries · openclaw/openclaw@2713089 test: mock channel install boundaries · openclaw/openclaw@b945248 test: mock doctor preview channel boundaries · openclaw/openclaw@b1a3ad4
refactor: trim gateway hook exports · openclaw/openclaw@2...
steipete · 2026-05-02 · via Recent Commits to openclaw:main
Original file line numberDiff line numberDiff line change

@@ -27,19 +27,19 @@ export type HookMappingResolved = {

2727

transform?: HookMappingTransformResolved;

2828

};

2929
30-

export type HookMappingTransformResolved = {

30+

type HookMappingTransformResolved = {

3131

modulePath: string;

3232

exportName?: string;

3333

};

3434
35-

export type HookMappingContext = {

35+

type HookMappingContext = {

3636

payload: Record<string, unknown>;

3737

headers: Record<string, string>;

3838

url: URL;

3939

path: string;

4040

};

4141
42-

export type HookAction =

42+

type HookAction =

4343

| {

4444

kind: "wake";

4545

text: string;

@@ -62,9 +62,9 @@ export type HookAction =

6262

timeoutSeconds?: number;

6363

};

6464
65-

export type HookSessionKeyTemplateSource = "static" | "templated";

65+

type HookSessionKeyTemplateSource = "static" | "templated";

6666
67-

export type HookMappingResult =

67+

type HookMappingResult =

6868

| { ok: true; action: HookAction }

6969

| { ok: true; action: null; skipped: true }

7070

| { ok: false; error: string };

Original file line numberDiff line numberDiff line change

@@ -32,19 +32,19 @@ export type HooksConfigResolved = {

3232

sessionPolicy: HookSessionPolicyResolved;

3333

};

3434
35-

export type HookAgentPolicyResolved = {

35+

type HookAgentPolicyResolved = {

3636

defaultAgentId: string;

3737

knownAgentIds: Set<string>;

3838

allowedAgentIds?: Set<string>;

3939

};

4040
41-

export type HookSessionPolicyResolved = {

41+

type HookSessionPolicyResolved = {

4242

defaultSessionKey?: string;

4343

allowRequestSessionKey: boolean;

4444

allowedSessionKeyPrefixes?: string[];

4545

};

4646
47-

export type HookSessionKeySource = "request" | "mapping-static" | "mapping-templated";

47+

type HookSessionKeySource = "request" | "mapping-static" | "mapping-templated";

4848
4949

export function resolveHooksConfig(cfg: OpenClawConfig): HooksConfigResolved | null {

5050

if (cfg.hooks?.enabled !== true) {

@@ -210,7 +210,7 @@ export function normalizeWakePayload(

210210

return { ok: true, value: { text: normalizedText, mode } };

211211

}

212212
213-

export type HookAgentPayload = {

213+

type HookAgentPayload = {

214214

message: string;

215215

name: string;

216216

agentId?: string;

@@ -312,7 +312,7 @@ export function isHookAgentAllowed(

312312

}

313313
314314

export const getHookAgentPolicyError = () => "agentId is not allowed by hooks.allowedAgentIds";

315-

export const getHookSessionKeyRequestPolicyError = () =>

315+

const getHookSessionKeyRequestPolicyError = () =>

316316

"sessionKey is disabled for externally supplied hook payload values; set hooks.allowRequestSessionKey=true to enable";

317317

export const getHookSessionKeyPrefixError = (prefixes: string[]) =>

318318

`sessionKey must start with one of: ${prefixes.join(", ")}`;