mirror of
https://github.com/openclaw/openclaw.git
synced 2026-05-08 05:01:23 +00:00
fix: dedupe probe/token base types (#16986) (thanks @iyoda)
This commit is contained in:
@@ -1,12 +1,11 @@
|
||||
import type { BaseProbeResult } from "../channels/plugins/types.js";
|
||||
import { fetchWithTimeout } from "../utils/fetch-timeout.js";
|
||||
import { makeProxyFetch } from "./proxy.js";
|
||||
|
||||
const TELEGRAM_API_BASE = "https://api.telegram.org";
|
||||
|
||||
export type TelegramProbe = {
|
||||
ok: boolean;
|
||||
export type TelegramProbe = BaseProbeResult & {
|
||||
status?: number | null;
|
||||
error?: string | null;
|
||||
elapsedMs: number;
|
||||
bot?: {
|
||||
id?: number | null;
|
||||
|
||||
@@ -1,12 +1,12 @@
|
||||
import fs from "node:fs";
|
||||
import type { BaseTokenResolution } from "../channels/plugins/types.js";
|
||||
import type { OpenClawConfig } from "../config/config.js";
|
||||
import type { TelegramAccountConfig } from "../config/types.telegram.js";
|
||||
import { DEFAULT_ACCOUNT_ID, normalizeAccountId } from "../routing/session-key.js";
|
||||
|
||||
export type TelegramTokenSource = "env" | "tokenFile" | "config" | "none";
|
||||
|
||||
export type TelegramTokenResolution = {
|
||||
token: string;
|
||||
export type TelegramTokenResolution = BaseTokenResolution & {
|
||||
source: TelegramTokenSource;
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user