refactor: trim daemon and gateway helper exports

This commit is contained in:
Peter Steinberger
2026-05-02 03:05:42 +01:00
parent 37426a6e64
commit ca319906ce
5 changed files with 8 additions and 8 deletions

View File

@@ -25,7 +25,7 @@ import { resolveGatewayStateDir } from "./paths.js";
export { isNodeVersionManagerRuntime, resolveLinuxSystemCaBundle };
export type MinimalServicePathOptions = {
type MinimalServicePathOptions = {
platform?: NodeJS.Platform;
extraDirs?: string[];
home?: string;
@@ -225,7 +225,7 @@ function resolveSystemPathDirs(platform: NodeJS.Platform): string[] {
* - fnm: macOS uses ~/Library/Application Support/fnm (not ~/.local/share/fnm)
* - pnpm: macOS uses ~/Library/pnpm (not ~/.local/share/pnpm)
*/
export function resolveDarwinUserBinDirs(
function resolveDarwinUserBinDirs(
home: string | undefined,
env?: Record<string, string | undefined>,
existsSync: (candidate: string) => boolean = fs.existsSync,
@@ -271,7 +271,7 @@ export function resolveDarwinUserBinDirs(
* Resolve common user bin directories for Linux.
* These are paths where npm global installs and node version managers typically place binaries.
*/
export function resolveLinuxUserBinDirs(
function resolveLinuxUserBinDirs(
home: string | undefined,
env?: Record<string, string | undefined>,
existsSync: (candidate: string) => boolean = fs.existsSync,

View File

@@ -7,7 +7,7 @@ import type { OpenClawConfig } from "../config/types.openclaw.js";
import { normalizeAgentId, normalizeMainKey } from "../routing/session-key.js";
import { normalizeOptionalString } from "../shared/string-coerce.js";
export type GatewayAgentListRow = {
type GatewayAgentListRow = {
id: string;
name?: string;
};

View File

@@ -23,7 +23,7 @@ export const DEFAULT_ASSISTANT_IDENTITY: AssistantIdentity = {
avatar: "A",
};
export type AssistantIdentity = {
type AssistantIdentity = {
agentId: string;
name: string;
avatar: string;

View File

@@ -41,7 +41,7 @@ export const AUTH_RATE_LIMIT_SCOPE_DEVICE_TOKEN = "device-token";
export const AUTH_RATE_LIMIT_SCOPE_HOOK_AUTH = "hook-auth";
const BROWSER_ORIGIN_RATE_LIMIT_KEY_PREFIX = "browser-origin:";
export interface RateLimitEntry {
interface RateLimitEntry {
/** Timestamps (epoch ms) of recent failed attempts inside the window. */
attempts: number[];
/** If set, requests from this IP are blocked until this epoch-ms instant. */

View File

@@ -6,8 +6,8 @@ import {
type SecretInputUnresolvedReasonStyle,
} from "./resolve-configured-secret-input-string.js";
export type GatewayAuthTokenResolutionSource = "explicit" | "config" | "secretRef" | "env";
export type GatewayAuthTokenEnvFallback = "never" | "no-secret-ref" | "always";
type GatewayAuthTokenResolutionSource = "explicit" | "config" | "secretRef" | "env";
type GatewayAuthTokenEnvFallback = "never" | "no-secret-ref" | "always";
export async function resolveGatewayAuthToken(params: {
cfg: OpenClawConfig;