import { E as GithubToolPreset, S as GithubTokenCall, j as GithubToolName, n as GithubToolsBaseOptions } from "./tool-types-CrC80SIL.mjs"; import { r as EveGithubToolsOptions } from "./types-CPAsEMzx.mjs"; import { ConnectOptions, ConnectTokenParams } from "@vercel/connect"; //#region src/connect/connector.d.ts /** * A Vercel Connect connector name, or a resolver that returns one. * * Use a function to pick the connector dynamically — e.g. a different * connector per environment (`production` vs. `preview`) or per tenant. * It's resolved lazily, on every token request, alongside the token itself. */ type GithubConnectorInput = string | (() => string | Promise); /** Resolves a {@link GithubConnectorInput} to a connector name string. */ declare function resolveGithubConnector(connector: GithubConnectorInput): Promise; //#endregion //#region src/connect/types.d.ts /** * Token parameters for Vercel Connect GitHub connectors. * `subject` defaults to `{ type: 'app' }` — the project's GitHub App * installation, same as `connectGitHubAdapter`. App-subject tokens target * the installation that owns the tool call's repository unless * `installationId`, `authorizationDetails` or `repositories` pins one. */ type GithubConnectParams = Omit & { /** * Connect token subject. Defaults to `{ type: 'app' }` (the project's GitHub * App installation — one identity shared by every caller). Pass * `{ type: 'user', id }` to mint a token for that user's own GitHub * connection instead, e.g. in multi-user apps where each user connects * their account from an integrations panel. */ subject?: ConnectTokenParams['subject']; /** Restrict the token to specific repositories via GitHub authorization details. */ repositories?: string[]; }; /** * Resolves Connect token params for each tool call, e.g. to pick an * `installationId` per tenant. `call` is undefined when the token is resolved * outside a tool call. Unless the returned params set `scopes`, scopes are * still derived from `preset` / `include` / `exclude`. */ type GithubConnectParamsResolver = (call?: GithubTokenCall) => GithubConnectParams | Promise; /** Static Connect token params, or a per-call {@link GithubConnectParamsResolver}. */ type GithubConnectParamsInput = GithubConnectParams | GithubConnectParamsResolver; type ConnectGithubToolsOptions = GithubToolsBaseOptions & { preset?: GithubToolPreset | GithubToolPreset[]; connect?: GithubConnectParamsInput; }; type ConnectGithubEveToolsOptions = Omit & { connect?: GithubConnectParamsInput; }; type ConnectGithubTokenOptions = { preset?: GithubToolPreset | GithubToolPreset[]; /** Same allow-list semantics as eve `include` — scopes derive from the resolved tools when set. */ include?: readonly GithubToolName[]; /** Same deny-list semantics as eve `exclude` — scopes derive from the resolved tools when set. */ exclude?: readonly GithubToolName[]; params?: GithubConnectParamsInput; connectOptions?: ConnectOptions; }; //#endregion export { GithubConnectParamsInput as a, resolveGithubConnector as c, GithubConnectParams as i, ConnectGithubTokenOptions as n, GithubConnectParamsResolver as o, ConnectGithubToolsOptions as r, GithubConnectorInput as s, ConnectGithubEveToolsOptions as t }; //# sourceMappingURL=types-BmwOpI5-.d.mts.map