UNPKG

aiwg

Version:

Deployment tool and support utility for AI context. Copies agents, skills, commands, rules, and behaviors into the paths each AI platform reads (Claude Code, Codex, Copilot, Cursor, Warp, OpenClaw, and 6 more) so one source of truth works across 10 platfo

50 lines 1.87 kB
/** * ClawHub Package Adapter * * Implements PackageRegistryAdapter for the `clawhub:` and `openclaw:` URI * schemes, routing `aiwg install clawhub:<owner>/<name>` through the * ClawHub REST API at clawhub.ai. * * The adapter fetches the package manifest and skill content via the API, * writes the result into the standard AIWG cache layout, and returns the * local cache path — matching the contract of all other adapters. * * Cache layout (shared with GitAdapter): * ~/.cache/aiwg/packages/<owner>/<name>@<version>/ * * @implements #803 * @see https://clawhub.ai * @see https://docs.openclaw.ai/tools/clawhub */ import type { PackageRef, PackageSource, PackageRegistryAdapter, FetchOptions, PackageInfo } from '../types.js'; /** * ClawHubPackageAdapter * * Handles "clawhub:owner/name[@version]" and "openclaw:owner/name[@version]" * references in the install pipeline. */ export declare class ClawHubPackageAdapter implements PackageRegistryAdapter { readonly id = "clawhub"; readonly name = "ClawHub Registry"; /** * Matches the `clawhub:` and `openclaw:` URI schemes. */ canResolve(ref: string): boolean; /** * Resolve a parsed PackageRef to a PackageSource. * * The `gitUrl` field is a canonical API URL (not a git remote) so the * caller can store it in packages.yaml for display and re-install. */ resolve(ref: PackageRef): Promise<PackageSource | null>; /** * Fetch the package from ClawHub and write it to the local cache. * * Skips the network request if the cache directory already exists and * `options.refresh` is not set. */ fetch(source: PackageSource, options?: FetchOptions): Promise<string>; /** ClawHubPackageAdapter does not enumerate packages */ list(): Promise<PackageInfo[]>; } //# sourceMappingURL=clawhub.d.ts.map