docs: document medium extension sources

This commit is contained in:
Peter Steinberger
2026-06-04 21:33:35 -04:00
parent 126ebfc997
commit 96e5812426
930 changed files with 938 additions and 19 deletions

View File

@@ -1,3 +1,4 @@
// Copilot tests cover doctor contract api plugin behavior.
import { describe, expect, it } from "vitest";
import {
legacyConfigRules,

View File

@@ -1,3 +1,4 @@
// Copilot tests cover harness plugin behavior.
import { beforeEach, describe, expect, it, vi } from "vitest";
import type { CopilotClientPool } from "./harness.js";
import { createCopilotAgentHarness, type CopilotSessionBinding } from "./harness.js";

View File

@@ -1,3 +1,4 @@
// Copilot plugin module implements harness behavior.
import type { CopilotClient } from "@github/copilot-sdk";
import {
compactWithSafetyTimeout,

View File

@@ -1,3 +1,4 @@
// Copilot tests cover index plugin behavior.
import fs from "node:fs";
import { createTestPluginApi } from "openclaw/plugin-sdk/plugin-test-api";
import { describe, expect, it, vi } from "vitest";

View File

@@ -1,3 +1,4 @@
// Copilot plugin entrypoint registers its OpenClaw integration.
import { definePluginEntry } from "openclaw/plugin-sdk/plugin-entry";
import { createCopilotAgentHarness, type CopilotSessionBinding } from "./harness.js";

View File

@@ -1,3 +1,4 @@
// Copilot tests cover attempt plugin behavior.
import { mkdtemp, rm } from "node:fs/promises";
import { tmpdir } from "node:os";
import { join } from "node:path";

View File

@@ -1,3 +1,4 @@
// Copilot tests cover attempt plugin behavior.
import fsp from "node:fs/promises";
import { tmpdir } from "node:os";
import path from "node:path";

View File

@@ -1,3 +1,4 @@
// Copilot plugin module implements attempt behavior.
import fsp from "node:fs/promises";
import type { MessageOptions, SessionConfig, Tool as SdkTool } from "@github/copilot-sdk";
import type {

View File

@@ -1,3 +1,4 @@
// Copilot tests cover auth bridge plugin behavior.
import { createHash } from "node:crypto";
import { join, resolve } from "node:path";
import { afterEach, beforeEach, describe, expect, it } from "vitest";

View File

@@ -1,3 +1,4 @@
// Copilot plugin module implements auth bridge behavior.
import { createHash } from "node:crypto";
import { homedir as osHomedir } from "node:os";
import { join, normalize, resolve, sep } from "node:path";

View File

@@ -1,3 +1,4 @@
// Copilot tests cover compaction bridge plugin behavior.
import { describe, expect, it } from "vitest";
import { createInfiniteSessionConfig } from "./compaction-bridge.js";

View File

@@ -1,3 +1,4 @@
// Copilot plugin module implements compaction bridge behavior.
import type { SessionConfig } from "@github/copilot-sdk";
// Compaction bridge for the GitHub Copilot agent runtime.

View File

@@ -1,3 +1,4 @@
// Copilot tests cover doctor probes plugin behavior.
import { EventEmitter } from "node:events";
import fs from "node:fs/promises";
import os from "node:os";

View File

@@ -1,3 +1,4 @@
// Copilot tests cover dual write transcripts plugin behavior.
import { createHash } from "node:crypto";
import fs from "node:fs/promises";
import os from "node:os";

View File

@@ -1,3 +1,4 @@
// Copilot tests cover event bridge plugin behavior.
import type { SessionEvent } from "@github/copilot-sdk";
import { afterEach, describe, expect, it, vi } from "vitest";
import { attachEventBridge, type SessionLike } from "./event-bridge.js";

View File

@@ -1,3 +1,4 @@
// Copilot plugin module implements event bridge behavior.
import type { MessageOptions, SessionEvent, SessionEventType } from "@github/copilot-sdk";
import type { AgentMessage } from "openclaw/plugin-sdk/agent-harness-runtime";
import {

View File

@@ -1,3 +1,4 @@
// Copilot tests cover hooks bridge plugin behavior.
import { describe, expect, it, vi } from "vitest";
import { createHooksBridge, type CopilotHooksConfig } from "./hooks-bridge.js";

View File

@@ -1,3 +1,4 @@
// Copilot tests cover permission bridge plugin behavior.
import type {
PermissionRequest as SdkPermissionRequest,
PermissionRequestResult as SdkPermissionRequestResult,

View File

@@ -1,3 +1,4 @@
// Copilot tests cover replay shim plugin behavior.
import { describe, expect, it } from "vitest";
import {
classifyResumeFailure,

View File

@@ -1,3 +1,4 @@
// Copilot tests cover runtime plugin behavior.
import { normalize, resolve, sep } from "node:path";
import type { CopilotClient, CopilotClientOptions } from "@github/copilot-sdk";
import { afterEach, describe, expect, it, vi } from "vitest";

View File

@@ -1,3 +1,4 @@
// Copilot plugin module implements runtime behavior.
import { normalize, resolve, sep } from "node:path";
import type { CopilotClient, CopilotClientOptions } from "@github/copilot-sdk";
import { loadCopilotSdk } from "./sdk-loader.js";

View File

@@ -1,3 +1,4 @@
// Copilot tests cover sdk loader plugin behavior.
import { mkdtempSync, mkdirSync, rmSync, writeFileSync } from "node:fs";
import { tmpdir } from "node:os";
import path from "node:path";

View File

@@ -1,3 +1,4 @@
// Copilot plugin module implements sdk loader behavior.
import { existsSync } from "node:fs";
import { createRequire } from "node:module";
import path from "node:path";

View File

@@ -1,3 +1,4 @@
// Copilot tests cover telemetry bridge plugin behavior.
import { describe, expect, it, vi } from "vitest";
import {
createTelemetryConfig,

View File

@@ -1,3 +1,4 @@
// Copilot plugin module implements telemetry bridge behavior.
import type { CopilotClientOptions } from "@github/copilot-sdk";
// Telemetry bridge for the GitHub Copilot agent runtime.

View File

@@ -1,3 +1,4 @@
// Copilot tests cover tool bridge plugin behavior.
import type { Tool as SdkTool, ToolInvocation, ToolResultObject } from "@github/copilot-sdk";
import type { AnyAgentTool, SandboxContext } from "openclaw/plugin-sdk/agent-harness-runtime";
import { afterEach, describe, expect, it, vi } from "vitest";

View File

@@ -1,3 +1,4 @@
// Copilot plugin module implements tool bridge behavior.
import type { Tool as SdkTool, ToolInvocation, ToolResultObject } from "@github/copilot-sdk";
import type {
AnyAgentTool,

View File

@@ -1,3 +1,4 @@
// Copilot tests cover usage bridge plugin behavior.
import type { NormalizedUsage } from "openclaw/plugin-sdk/agent-harness-runtime";
import { describe, expect, it } from "vitest";
import {

View File

@@ -1,3 +1,4 @@
// Copilot plugin module implements usage bridge behavior.
import type { AgentMessage, NormalizedUsage } from "openclaw/plugin-sdk/agent-harness-runtime";
type AssistantMessage = Extract<AgentMessage, { role: "assistant" }>;

View File

@@ -1,3 +1,4 @@
// Copilot tests cover user input bridge plugin behavior.
import type { SessionConfig } from "@github/copilot-sdk";
import { describe, expect, it, vi } from "vitest";

View File

@@ -1,3 +1,4 @@
// Copilot tests cover workspace bootstrap plugin behavior.
import { mkdtemp, rm, writeFile } from "node:fs/promises";
import { tmpdir } from "node:os";
import path from "node:path";

View File

@@ -1,3 +1,4 @@
// Copilot plugin module implements workspace bootstrap behavior.
import path from "node:path";
import type {
AgentHarnessAttemptParams,

View File

@@ -1 +1,2 @@
// Google Meet API module exposes the plugin public contract.
export { legacyConfigRules, normalizeCompatibilityConfig } from "./src/config-compat.js";

View File

@@ -1,3 +1,4 @@
// Google Meet tests cover google meet plugin behavior.
import { isLiveTestEnabled } from "openclaw/plugin-sdk/test-env";
import { describe, expect, it } from "vitest";
import { buildGoogleMeetExportManifest, googleMeetExportFileNames } from "./src/cli.js";

View File

@@ -1,3 +1,4 @@
// Google Meet tests cover index.create plugin behavior.
import { Command } from "commander";
import { afterAll, afterEach, beforeEach, describe, expect, it, vi } from "vitest";
import plugin, { testing as googleMeetPluginTesting } from "./index.js";

View File

@@ -1,3 +1,4 @@
// Google Meet tests cover index plugin behavior.
import { EventEmitter } from "node:events";
import { existsSync, mkdtempSync, readFileSync, rmSync } from "node:fs";
import { tmpdir } from "node:os";

View File

@@ -1,3 +1,4 @@
// Google Meet plugin entrypoint registers its OpenClaw integration.
import {
optionalPositiveIntegerSchema,
readPositiveIntegerParam,

View File

@@ -1,3 +1,4 @@
// Google Meet tests cover node host plugin behavior.
import { spawnSync } from "node:child_process";
import { EventEmitter } from "node:events";
import { afterAll, afterEach, beforeAll, describe, expect, it, vi } from "vitest";

View File

@@ -1,3 +1,4 @@
// Google Meet plugin module implements agent consult behavior.
import type { OpenClawConfig } from "openclaw/plugin-sdk/config-contracts";
import { formatErrorMessage } from "openclaw/plugin-sdk/error-runtime";
import type { PluginRuntime, RuntimeLogger } from "openclaw/plugin-sdk/plugin-runtime";

View File

@@ -1,3 +1,4 @@
// Google Meet plugin module implements calendar behavior.
import { fetchWithSsrFGuard } from "openclaw/plugin-sdk/ssrf-runtime";
import { googleApiError } from "./google-api-errors.js";

View File

@@ -1,3 +1,4 @@
// Google Meet tests cover cli plugin behavior.
import { existsSync, mkdtempSync, readFileSync, rmSync } from "node:fs";
import { tmpdir } from "node:os";
import path from "node:path";

View File

@@ -1,3 +1,4 @@
// Google Meet plugin module implements cli behavior.
import { mkdir, writeFile } from "node:fs/promises";
import path from "node:path";
import { createInterface } from "node:readline/promises";

View File

@@ -1,3 +1,4 @@
// Google Meet tests cover config compat plugin behavior.
import type { OpenClawConfig } from "openclaw/plugin-sdk/config-contracts";
import { describe, expect, it } from "vitest";
import {

View File

@@ -1,3 +1,4 @@
// Google Meet helper module supports config compat behavior.
import type { OpenClawConfig } from "openclaw/plugin-sdk/config-contracts";
import {
asNullableRecord as asRecord,

View File

@@ -1,3 +1,4 @@
// Google Meet tests cover config plugin behavior.
import { MAX_TIMER_TIMEOUT_MS } from "openclaw/plugin-sdk/number-runtime";
import { describe, expect, it } from "vitest";
import { resolveGoogleMeetConfig, resolveGoogleMeetGatewayOperationTimeoutMs } from "./config.js";

View File

@@ -1,3 +1,4 @@
// Google Meet helper module supports config behavior.
import {
addTimerTimeoutGraceMs,
resolvePositiveTimerTimeoutMs,

View File

@@ -1,3 +1,4 @@
// Google Meet plugin module implements create behavior.
import type { OpenClawPluginApi } from "openclaw/plugin-sdk/plugin-entry";
import { normalizeOptionalString } from "openclaw/plugin-sdk/string-coerce-runtime";
import type { GoogleMeetConfig, GoogleMeetMode, GoogleMeetTransport } from "./config.js";

View File

@@ -1,3 +1,4 @@
// Google Meet plugin module implements drive behavior.
import { fetchWithSsrFGuard } from "openclaw/plugin-sdk/ssrf-runtime";
import { googleApiError } from "./google-api-errors.js";

View File

@@ -1,3 +1,4 @@
// Google Meet plugin module implements google api errors behavior.
const REAUTH_HINT = "Re-run `openclaw googlemeet auth login` and store the refreshed oauth block.";
function scopeText(scopes: readonly string[]): string {

View File

@@ -1,3 +1,4 @@
// Google Meet plugin module implements meet behavior.
import { fetchWithSsrFGuard } from "openclaw/plugin-sdk/ssrf-runtime";
import { uniqueStrings } from "openclaw/plugin-sdk/string-coerce-runtime";
import { exportGoogleDriveDocumentText, extractGoogleDriveDocumentId } from "./drive.js";

View File

@@ -1,3 +1,4 @@
// Google Meet plugin module implements node host behavior.
import { spawn, spawnSync, type ChildProcess } from "node:child_process";
import { randomUUID } from "node:crypto";
import { setTimeout as sleep } from "node:timers/promises";

View File

@@ -1,3 +1,4 @@
// Google Meet tests cover oauth plugin behavior.
import { afterEach, describe, expect, it, vi } from "vitest";
import {
buildGoogleMeetAuthUrl,

View File

@@ -1,3 +1,4 @@
// Google Meet plugin module implements oauth behavior.
import {
MAX_DATE_TIMESTAMP_MS,
resolveDateTimestampMs,

View File

@@ -1,3 +1,4 @@
// Google Meet plugin module implements realtime node behavior.
import type { OpenClawConfig } from "openclaw/plugin-sdk/config-contracts";
import { formatErrorMessage } from "openclaw/plugin-sdk/error-runtime";
import type { PluginRuntime, RuntimeLogger } from "openclaw/plugin-sdk/plugin-runtime";

View File

@@ -1,3 +1,4 @@
// Google Meet plugin module implements realtime behavior.
import { spawn } from "node:child_process";
import type { Writable } from "node:stream";
import type { OpenClawConfig } from "openclaw/plugin-sdk/config-contracts";

View File

@@ -1,3 +1,4 @@
// Google Meet plugin module implements runtime behavior.
import { randomUUID } from "node:crypto";
import type { OpenClawConfig } from "openclaw/plugin-sdk/config-contracts";
import { formatErrorMessage } from "openclaw/plugin-sdk/error-runtime";

View File

@@ -1,3 +1,4 @@
// Google Meet setup module handles plugin onboarding behavior.
import fs from "node:fs";
import os from "node:os";
import path from "node:path";

View File

@@ -1,3 +1,4 @@
// Google Meet plugin module implements plugin harness behavior.
import type { OpenClawPluginApi } from "openclaw/plugin-sdk/plugin-entry";
import { createTestPluginApi } from "openclaw/plugin-sdk/plugin-test-api";
import { vi } from "vitest";

View File

@@ -1,3 +1,4 @@
// Google Meet plugin module implements chrome audio device behavior.
export const GOOGLE_MEET_SYSTEM_PROFILER_COMMAND = "/usr/sbin/system_profiler";
export function outputMentionsBlackHole2ch(output: string): boolean {

View File

@@ -1,3 +1,4 @@
// Google Meet tests cover chrome browser proxy plugin behavior.
import { MAX_TIMER_TIMEOUT_MS } from "openclaw/plugin-sdk/number-runtime";
import type { PluginRuntime } from "openclaw/plugin-sdk/plugin-runtime";
import { describe, expect, it, vi } from "vitest";

View File

@@ -1,3 +1,4 @@
// Google Meet plugin module implements chrome browser proxy behavior.
import { addTimerTimeoutGraceMs } from "openclaw/plugin-sdk/number-runtime";
import type { PluginRuntime } from "openclaw/plugin-sdk/plugin-runtime";

View File

@@ -1,3 +1,4 @@
// Google Meet plugin module implements chrome create behavior.
import type { PluginRuntime } from "openclaw/plugin-sdk/plugin-runtime";
import { sleep } from "openclaw/plugin-sdk/runtime-env";
import type { GoogleMeetConfig } from "../config.js";

View File

@@ -1,3 +1,4 @@
// Google Meet tests cover chrome plugin behavior.
import { MAX_TIMER_TIMEOUT_MS } from "openclaw/plugin-sdk/number-runtime";
import { describe, expect, it } from "vitest";
import { testing } from "./chrome.js";

View File

@@ -1,3 +1,4 @@
// Google Meet plugin module implements chrome behavior.
import type { OpenClawConfig } from "openclaw/plugin-sdk/config-contracts";
import { callGatewayFromCli } from "openclaw/plugin-sdk/gateway-runtime";
import { addTimerTimeoutGraceMs } from "openclaw/plugin-sdk/number-runtime";

View File

@@ -1,3 +1,4 @@
// Google Meet plugin module implements twilio behavior.
import { normalizeOptionalString } from "openclaw/plugin-sdk/string-coerce-runtime";
const DTMF_PATTERN = /^[0-9*#wWpP,]+$/;

View File

@@ -1,3 +1,4 @@
// Google Meet type declarations define plugin contracts.
import type { GoogleMeetMode, GoogleMeetModeInput, GoogleMeetTransport } from "../config.js";
type GoogleMeetSessionState = "active" | "ended";

View File

@@ -1,3 +1,4 @@
// Google Meet tests cover voice call gateway plugin behavior.
import { afterAll, afterEach, beforeEach, describe, expect, it, vi } from "vitest";
import { resolveGoogleMeetConfig } from "./config.js";
import {

View File

@@ -1,3 +1,4 @@
// Google Meet plugin module implements voice call gateway behavior.
import { formatErrorMessage } from "openclaw/plugin-sdk/error-runtime";
import {
GatewayClient,

View File

@@ -1,3 +1,4 @@
// Google tests cover api plugin behavior.
import { describe, expect, it } from "vitest";
import {
isGoogleGenerativeAiApi,

View File

@@ -1,3 +1,4 @@
// Google API module exposes the plugin public contract.
import {
resolveProviderHttpRequestConfig,
type ProviderRequestTransportOverrides,

View File

@@ -1,3 +1,4 @@
// Google plugin module implements cli backend behavior.
import type { CliBackendPlugin } from "openclaw/plugin-sdk/cli-backend";
import {
CLI_FRESH_WATCHDOG_DEFAULTS,

View File

@@ -1,3 +1,4 @@
// Google tests cover default model plugin behavior.
import type { OpenClawConfig } from "openclaw/plugin-sdk/provider-onboard";
import { describe, expect, it } from "vitest";
import { applyGoogleGeminiModelDefault, GOOGLE_GEMINI_DEFAULT_MODEL } from "./api.js";

View File

@@ -1,3 +1,4 @@
// Google API module exposes the plugin public contract.
import type { DoctorSessionRouteStateOwner } from "openclaw/plugin-sdk/runtime-doctor";
export const sessionRouteStateOwners: DoctorSessionRouteStateOwner[] = [

View File

@@ -1,3 +1,4 @@
// Google plugin module implements embedding batch behavior.
import crypto from "node:crypto";
import {
buildEmbeddingBatchGroupOptions,

View File

@@ -1,3 +1,4 @@
// Google tests cover embedding provider plugin behavior.
import { afterEach, describe, expect, it, vi } from "vitest";
vi.mock("openclaw/plugin-sdk/memory-core-host-engine-embeddings", async (importOriginal) => {

View File

@@ -1,3 +1,4 @@
// Google provider module implements model/runtime integration.
import {
buildRemoteBaseUrlPolicy,
debugEmbeddingsLog,

View File

@@ -1,3 +1,4 @@
// Google plugin module implements gemini auth behavior.
import { parseGoogleOauthApiKey } from "./oauth-token-shared.js";
export function parseGeminiAuth(apiKey: string): { headers: Record<string, string> } {

View File

@@ -1,3 +1,4 @@
// Google provider module implements model/runtime integration.
import type {
OpenClawPluginApi,
ProviderAuthContext,

View File

@@ -1,3 +1,4 @@
// Google provider module implements model/runtime integration.
import type { MusicGenerationProvider } from "openclaw/plugin-sdk/music-generation";
import { isProviderApiKeyConfigured } from "openclaw/plugin-sdk/provider-auth";
import type {

View File

@@ -1,3 +1,4 @@
// Google plugin module implements google genai runtime behavior.
import { GoogleGenAI } from "@google/genai";
export type GoogleGenAIClient = InstanceType<typeof GoogleGenAI>;

View File

@@ -1,3 +1,4 @@
// Google tests cover google plugin behavior.
import {
registerProviderPlugin,
requireRegisteredProvider,

View File

@@ -1,3 +1,4 @@
// Google tests cover image generation provider plugin behavior.
import * as providerAuthRuntime from "openclaw/plugin-sdk/provider-auth-runtime";
import * as providerHttp from "openclaw/plugin-sdk/provider-http";
import { mockPinnedHostnameResolution } from "openclaw/plugin-sdk/test-env";

View File

@@ -1,3 +1,4 @@
// Google provider module implements model/runtime integration.
import {
generatedImageAssetFromBase64,
type GeneratedImageAsset,

View File

@@ -1,3 +1,4 @@
// Google tests cover index plugin behavior.
import type { Context, Model } from "openclaw/plugin-sdk/llm";
import type {
ProviderReplaySessionEntry,

View File

@@ -1,3 +1,4 @@
// Google plugin entrypoint registers its OpenClaw integration.
import type { ImageGenerationProvider } from "openclaw/plugin-sdk/image-generation";
import type { MediaUnderstandingProvider } from "openclaw/plugin-sdk/media-understanding";
import type { MusicGenerationProvider } from "openclaw/plugin-sdk/music-generation";

View File

@@ -1,3 +1,4 @@
// Google tests cover manifest plugin behavior.
import { readFileSync } from "node:fs";
import { describe, expect, it } from "vitest";

View File

@@ -1,3 +1,4 @@
// Google provider module implements model/runtime integration.
import {
describeImageWithModel,
describeImagesWithModel,

View File

@@ -1,3 +1,4 @@
// Google tests cover media understanding provider.video plugin behavior.
import {
createRequestCaptureJsonFetch,
installPinnedHostnameTestHooks,

View File

@@ -1,3 +1,4 @@
// Google plugin module implements memory embedding adapter behavior.
import {
hasNonTextEmbeddingParts,
isMissingEmbeddingApiKeyError,

View File

@@ -1,3 +1,4 @@
// Google tests cover model id plugin behavior.
import { describe, expect, it } from "vitest";
import { normalizeAntigravityModelId, normalizeGoogleModelId } from "./api.js";

View File

@@ -1,3 +1,4 @@
// Google plugin module implements model id behavior.
const ANTIGRAVITY_BARE_PRO_IDS = new Set(["gemini-3-pro", "gemini-3.1-pro", "gemini-3-1-pro"]);
const GOOGLE_PROVIDER_PREFIX = "google/";

View File

@@ -1,3 +1,4 @@
// Google tests cover music generation provider plugin behavior.
import { afterAll, afterEach, describe, expect, it, vi } from "vitest";
const { createGoogleGenAIMock, generateContentMock } = vi.hoisted(() => {

View File

@@ -1,3 +1,4 @@
// Google provider module implements model/runtime integration.
import { extensionForMime } from "openclaw/plugin-sdk/media-mime";
import type {
GeneratedMusicAsset,

View File

@@ -1,3 +1,4 @@
// Google tests cover oauth token shared plugin behavior.
import { describe, expect, it } from "vitest";
import {
formatGoogleOauthApiKey,

View File

@@ -1,3 +1,4 @@
// Google plugin module implements oauth token shared behavior.
import { readStringValue } from "openclaw/plugin-sdk/string-coerce-runtime";
type GoogleOauthApiKeyCredential = {

View File

@@ -1,3 +1,4 @@
// Google plugin module implements oauth.credentials behavior.
import { existsSync, readFileSync, readdirSync, realpathSync } from "node:fs";
import type { Dirent } from "node:fs";
import { delimiter, dirname, join } from "node:path";

View File

@@ -1,3 +1,4 @@
// Google plugin module implements oauth.flow behavior.
import { generateHexPkceVerifierChallenge } from "openclaw/plugin-sdk/provider-auth";
import {
generateOAuthState,

View File

@@ -1,3 +1,4 @@
// Google plugin module implements oauth.http behavior.
import { fetchWithSsrFGuard } from "openclaw/plugin-sdk/ssrf-runtime";
import { DEFAULT_FETCH_TIMEOUT_MS } from "./oauth.shared.js";

View File

@@ -1,3 +1,4 @@
// Google tests cover oauth.local login plugin behavior.
import { beforeEach, describe, expect, it, vi } from "vitest";
const AUTH_URL = "https://accounts.google.com/o/oauth2/v2/auth?state=state-123";

View File

@@ -1,3 +1,4 @@
// Google plugin module implements oauth.project behavior.
import { fetchWithTimeout } from "./oauth.http.js";
import {
CODE_ASSIST_ENDPOINT_PROD,

Some files were not shown because too many files have changed in this diff Show More