@githits/mcp 0.36.1 → 0.38.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +6 -1
- package/dist/client.d.ts +28 -3
- package/dist/client.js +1 -1
- package/dist/index.d.ts +20 -1
- package/dist/index.js +24 -24
- package/dist/shared/{chunk-33zcd460.js → chunk-3rrwegcq.js} +5 -3
- package/dist/shared/{chunk-jatk4vrs.js → chunk-99jxrjze.js} +9 -8
- package/dist/shared/{chunk-hwafe365.js → chunk-j3smtn4t.js} +6 -6
- package/dist/smoke-test.js +2 -2
- package/dist/tools.d.ts +13 -1
- package/dist/tools.js +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -129,12 +129,17 @@ error result.
|
|
|
129
129
|
|
|
130
130
|
An injected browser service should throw one of the exported neutral error
|
|
131
131
|
constructors when it wants `get_example` to return a structured
|
|
132
|
-
`AUTH_REQUIRED`, `RATE_LIMITED`, `TIMEOUT`, or `TERMS_ACCEPTANCE_REQUIRED`
|
|
132
|
+
`AUTH_REQUIRED`, `REAUTH_REQUIRED`, `RATE_LIMITED`, `TIMEOUT`, or `TERMS_ACCEPTANCE_REQUIRED`
|
|
133
133
|
`ToolResult`. This is an explicit thrown-error contract, not automatic HTTP
|
|
134
134
|
response classification. Callable authentication remediation is host-neutral:
|
|
135
135
|
`Authenticate with GitHits, then retry.` Terms errors use the canonical
|
|
136
136
|
`acceptanceUrl` action. Other errors remain `UNKNOWN`.
|
|
137
137
|
|
|
138
|
+
`ProviderReauthenticationRequiredError` is exported from `/tools` and `/client`.
|
|
139
|
+
Example search and Research map it to `REAUTH_REQUIRED` with `retryable: false`.
|
|
140
|
+
`details.action` provides sign-in guidance; `details.reauthUrl` contains a validated
|
|
141
|
+
sign-in link when available. Complete sign-in before retrying the request.
|
|
142
|
+
|
|
138
143
|
A frontend can add a small registration adapter for its WebMCP host API. The
|
|
139
144
|
adapter owns the host-specific registration call and passes its signal through;
|
|
140
145
|
the callable surface is not a generic protocol-conversion layer:
|
package/dist/client.d.ts
CHANGED
|
@@ -131,7 +131,7 @@ declare class AgenticAskServiceImpl implements AgenticAskService {
|
|
|
131
131
|
* Back-compat: `src/shared/code-navigation.ts` re-exports these under
|
|
132
132
|
* the existing `CodeNavigationRegistry*` names.
|
|
133
133
|
*/
|
|
134
|
-
declare const PKGSEER_REGISTRY_ARGS: readonly ["npm", "pypi", "hex", "crates", "nuget", "maven", "zig", "vcpkg", "packagist", "rubygems", "go", "swift"];
|
|
134
|
+
declare const PKGSEER_REGISTRY_ARGS: readonly ["npm", "pypi", "hex", "crates", "nuget", "maven", "zig", "vcpkg", "packagist", "rubygems", "go", "swift", "pub"];
|
|
135
135
|
type PkgseerRegistryArg = (typeof PKGSEER_REGISTRY_ARGS)[number];
|
|
136
136
|
declare const registryMap: {
|
|
137
137
|
readonly npm: "NPM";
|
|
@@ -146,6 +146,7 @@ declare const registryMap: {
|
|
|
146
146
|
readonly rubygems: "RUBYGEMS";
|
|
147
147
|
readonly go: "GO";
|
|
148
148
|
readonly swift: "SWIFT";
|
|
149
|
+
readonly pub: "PUB";
|
|
149
150
|
};
|
|
150
151
|
type PkgseerRegistry = (typeof registryMap)[keyof typeof registryMap];
|
|
151
152
|
declare const PKGSEER_REGISTRY_LIST: string;
|
|
@@ -1709,6 +1710,10 @@ interface PackageUpgradeUnknownEvidence {
|
|
|
1709
1710
|
message: string;
|
|
1710
1711
|
retryable?: boolean;
|
|
1711
1712
|
}
|
|
1713
|
+
interface PackageUpgradeMigrationGuide {
|
|
1714
|
+
url: string;
|
|
1715
|
+
label?: string;
|
|
1716
|
+
}
|
|
1712
1717
|
interface PackageUpgradeReview {
|
|
1713
1718
|
registry: string;
|
|
1714
1719
|
name: string;
|
|
@@ -1716,6 +1721,7 @@ interface PackageUpgradeReview {
|
|
|
1716
1721
|
targetVersion: string;
|
|
1717
1722
|
latestVersion?: string;
|
|
1718
1723
|
versionDelta: string;
|
|
1724
|
+
migrationGuides?: PackageUpgradeMigrationGuide[];
|
|
1719
1725
|
security: PackageUpgradeSecurity;
|
|
1720
1726
|
changelog: PackageUpgradeChangelog;
|
|
1721
1727
|
compatibility?: PackageUpgradeCompatibility;
|
|
@@ -1744,7 +1750,8 @@ interface DirectDependency {
|
|
|
1744
1750
|
/**
|
|
1745
1751
|
* Node in a typed dependency graph. Mirrors `DependencyGraphNode`.
|
|
1746
1752
|
* `registry` is a lowercase string: `"npm"`, `"pypi"`, …, or
|
|
1747
|
-
* `"
|
|
1753
|
+
* `"flutter_sdk"` for SDK nodes, or `"synthetic"` for project root nodes.
|
|
1754
|
+
* These graph namespaces are not package registry inputs. `version` is null
|
|
1748
1755
|
* for synthetic roots.
|
|
1749
1756
|
*/
|
|
1750
1757
|
interface DependencyGraphNode {
|
|
@@ -2020,6 +2027,14 @@ interface ChangelogStatementContext {
|
|
|
2020
2027
|
textTruncated: boolean;
|
|
2021
2028
|
fullText?: string;
|
|
2022
2029
|
}
|
|
2030
|
+
interface ChangelogStatementCommit {
|
|
2031
|
+
sha: string;
|
|
2032
|
+
url: string | null;
|
|
2033
|
+
}
|
|
2034
|
+
interface ChangelogStatementGeneration {
|
|
2035
|
+
status: "GENERATED" | "PENDING" | "NOT_GENERATED";
|
|
2036
|
+
reason: string | null;
|
|
2037
|
+
}
|
|
2023
2038
|
interface ChangelogStatement {
|
|
2024
2039
|
version: string;
|
|
2025
2040
|
position: number;
|
|
@@ -2028,6 +2043,7 @@ interface ChangelogStatement {
|
|
|
2028
2043
|
heading?: string;
|
|
2029
2044
|
source?: string;
|
|
2030
2045
|
url?: string;
|
|
2046
|
+
commits?: ChangelogStatementCommit[];
|
|
2031
2047
|
text: string;
|
|
2032
2048
|
textTruncated: boolean;
|
|
2033
2049
|
fullText?: string;
|
|
@@ -2043,6 +2059,7 @@ interface ChangelogStatementCoverage {
|
|
|
2043
2059
|
statementsNotAssessed: number;
|
|
2044
2060
|
statementsNoImpact: number;
|
|
2045
2061
|
statementsUnclassified: number;
|
|
2062
|
+
generation?: ChangelogStatementGeneration;
|
|
2046
2063
|
}
|
|
2047
2064
|
interface ChangelogStatements {
|
|
2048
2065
|
totalCount: number;
|
|
@@ -2319,6 +2336,7 @@ interface ResolveTargetParams {
|
|
|
2319
2336
|
interface ResolveTargetReference {
|
|
2320
2337
|
kind: string;
|
|
2321
2338
|
canonicalKey: string;
|
|
2339
|
+
searchTarget: string;
|
|
2322
2340
|
confidence: string;
|
|
2323
2341
|
}
|
|
2324
2342
|
interface ResolveTargetMatch {
|
|
@@ -2331,6 +2349,7 @@ interface ResolveTargetMatch {
|
|
|
2331
2349
|
interface ResolveTargetTarget {
|
|
2332
2350
|
kind: string;
|
|
2333
2351
|
canonicalKey: string;
|
|
2352
|
+
searchTarget: string;
|
|
2334
2353
|
displayName?: string;
|
|
2335
2354
|
description?: string;
|
|
2336
2355
|
registry?: string;
|
|
@@ -2378,4 +2397,10 @@ declare class ResolveTargetServiceImpl implements ResolveTargetService {
|
|
|
2378
2397
|
resolveTarget(params: ResolveTargetParams, options?: ServiceRequestOptions): Promise<ResolveTargetResult>;
|
|
2379
2398
|
private executeResolveTarget;
|
|
2380
2399
|
}
|
|
2381
|
-
|
|
2400
|
+
/** Provider sign-in is separate from refreshing the GitHits session. */
|
|
2401
|
+
declare class ProviderReauthenticationRequiredError extends Error {
|
|
2402
|
+
readonly code = "REAUTH_REQUIRED";
|
|
2403
|
+
readonly reauthUrl: string | undefined;
|
|
2404
|
+
constructor(reauthUrl?: string);
|
|
2405
|
+
}
|
|
2406
|
+
export { AGENTIC_ASK_REQUEST_TIMEOUT_MS, AgentInfo, AgenticAskRateLimitScope, AgenticAskRequest, AgenticAskRequestOptions, AgenticAskResponse, AgenticAskService, AgenticAskServiceImpl, AgenticAskServiceRuntimeOptions, CodeDiffError, CodeDiffErrorDetails, CodeDiffErrorRef, CodeDiffMode, CodeDiffOptions, CodeDiffPackageInfo, CodeDiffPackageTarget, CodeDiffParams, CodeDiffPartialResult, CodeDiffRefKind, CodeDiffRefResolution, CodeDiffRepositoryTarget, CodeDiffResult, CodeDiffService, CodeDiffTarget, CodeDiffVersionSource, CodeNavigationService, CodeNavigationServiceImpl, CodeSymbolCandidate, CodeSymbolResolution, CodeSymbolSuggestion, ContentModification, ContentSafety, DEFAULT_API_URL, DEFAULT_CODE_NAV_URL, DEFAULT_MCP_URL, DiscoveryIndexingEstimate, GitHitsService, GitHitsServiceImpl, GrepAccessError, GrepBackendError, GrepContentSafety, GrepCorpus, GrepFileIssue, GrepGraphQLError, GrepHit, GrepInputTargetResolution, GrepLineSlice, GrepNetworkError, GrepParams, GrepPathSelector, GrepPathSuggestion, GrepPathWarning, GrepReadAction, GrepReadiness, GrepRepositoryHit, GrepResult, GrepService, GrepServiceImpl, GrepSiteHit, GrepTarget, GrepTargetStatus, GrepTraversal, GrepUnavailableTarget, IndexingDurationEstimate, KnownLatestVersionMaliciousStatus, KnownMaliciousAdvisoryClassificationReason, LatestVersionMaliciousStatus, ListAccessError, ListAction, ListAvailableVersion, ListBackendError, ListBrowseAction, ListEntry, ListEntryKind, ListFileIntent, ListGraphQLError, ListIndexingEstimate, ListInventoryKind, ListNetworkError, ListParams, ListReadAction, ListResolution, ListResult, ListService, ListServiceImpl, ListSiteJob, ListSitePreparation, ListSiteWait, ListSiteWaitOutcome, ListTargetIdentity, ListTargetResolution, MalformedGrepResponseError, MalformedListResponseError, MaliciousAdvisoryClassificationReason, PKGSEER_REGISTRY_LIST, PackageIntelligenceService, PackageIntelligenceServiceImpl, ProviderReauthenticationRequiredError, RawCodeDiff, RawCodeDiffContentCoverage, RawCodeDiffContentFailure, RawCodeDiffFile, RawCodeDiffFileContentStatus, RawCodeDiffFileStatus, RawCodeDiffPathEncoding, RawCodeDiffScope, RawCodeDiffScopeStatus, RawCodeDiffSummary, ReadCodeResult, ReadDocsResult, ReadParams, ReadResult, ReadService, ReadServiceImpl, ReadSymbolResolutionResult, ReadTarget, RefreshingGitHitsService, RegistryRepository, ResolveTargetKind, ResolveTargetLatestVersionMaliciousAdvisory, ResolveTargetLatestVersionMaliciousEvidence, ResolveTargetMatch, ResolveTargetParams, ResolveTargetReference, ResolveTargetResult, ResolveTargetService, ResolveTargetServiceImpl, ResolveTargetTarget, ServiceDiagnostics, ServiceRequestOptions, SessionIdConfigError, TokenProvider, createClientHeaderBuilder, createStaticTokenProvider, getApiUrl, getCodeNavigationUrl, getEnvApiToken, getEnvSessionId, getMcpUrl, toPkgseerRegistry, toPkgseerRegistryLowercase };
|
package/dist/client.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{GrepGraphQLError2,GrepBackendError2,GrepAccessError2,GrepNetworkError2,MalformedGrepResponseError2,GrepServiceImpl2,ListAccessError2,ListGraphQLError2,ListBackendError2,ListNetworkError2,MalformedListResponseError2,ListServiceImpl2,ReadServiceImpl2,RefreshingGitHitsService2,ResolveTargetServiceImpl2,createStaticTokenProvider2,SessionIdConfigError2,getEnvSessionId2,createClientHeaderBuilder2}from"./shared/chunk-
|
|
1
|
+
import{GrepGraphQLError2,GrepBackendError2,GrepAccessError2,GrepNetworkError2,MalformedGrepResponseError2,GrepServiceImpl2,ListAccessError2,ListGraphQLError2,ListBackendError2,ListNetworkError2,MalformedListResponseError2,ListServiceImpl2,ReadServiceImpl2,RefreshingGitHitsService2,ResolveTargetServiceImpl2,createStaticTokenProvider2,SessionIdConfigError2,getEnvSessionId2,createClientHeaderBuilder2}from"./shared/chunk-3rrwegcq.js";import{ProviderReauthenticationRequiredError2,DEFAULT_MCP_URL2,DEFAULT_API_URL2,DEFAULT_CODE_NAV_URL2,getMcpUrl2,getApiUrl2,getCodeNavigationUrl2,getEnvApiToken2,GitHitsServiceImpl2,AGENTIC_ASK_REQUEST_TIMEOUT_MS2,AgenticAskServiceImpl2,PKGSEER_REGISTRY_LIST2,toPkgseerRegistry2,toPkgseerRegistryLowercase2,CodeDiffError2,CodeNavigationServiceImpl2,PackageIntelligenceServiceImpl2}from"./shared/chunk-99jxrjze.js";export{AGENTIC_ASK_REQUEST_TIMEOUT_MS2 as AGENTIC_ASK_REQUEST_TIMEOUT_MS,AgenticAskServiceImpl2 as AgenticAskServiceImpl,CodeDiffError2 as CodeDiffError,CodeNavigationServiceImpl2 as CodeNavigationServiceImpl,DEFAULT_API_URL2 as DEFAULT_API_URL,DEFAULT_CODE_NAV_URL2 as DEFAULT_CODE_NAV_URL,DEFAULT_MCP_URL2 as DEFAULT_MCP_URL,GitHitsServiceImpl2 as GitHitsServiceImpl,GrepAccessError2 as GrepAccessError,GrepBackendError2 as GrepBackendError,GrepGraphQLError2 as GrepGraphQLError,GrepNetworkError2 as GrepNetworkError,GrepServiceImpl2 as GrepServiceImpl,ListAccessError2 as ListAccessError,ListBackendError2 as ListBackendError,ListGraphQLError2 as ListGraphQLError,ListNetworkError2 as ListNetworkError,ListServiceImpl2 as ListServiceImpl,MalformedGrepResponseError2 as MalformedGrepResponseError,MalformedListResponseError2 as MalformedListResponseError,PKGSEER_REGISTRY_LIST2 as PKGSEER_REGISTRY_LIST,PackageIntelligenceServiceImpl2 as PackageIntelligenceServiceImpl,ProviderReauthenticationRequiredError2 as ProviderReauthenticationRequiredError,ReadServiceImpl2 as ReadServiceImpl,RefreshingGitHitsService2 as RefreshingGitHitsService,ResolveTargetServiceImpl2 as ResolveTargetServiceImpl,SessionIdConfigError2 as SessionIdConfigError,createClientHeaderBuilder2 as createClientHeaderBuilder,createStaticTokenProvider2 as createStaticTokenProvider,getApiUrl2 as getApiUrl,getCodeNavigationUrl2 as getCodeNavigationUrl,getEnvApiToken2 as getEnvApiToken,getEnvSessionId2 as getEnvSessionId,getMcpUrl2 as getMcpUrl,toPkgseerRegistry2 as toPkgseerRegistry,toPkgseerRegistryLowercase2 as toPkgseerRegistryLowercase};
|
package/dist/index.d.ts
CHANGED
|
@@ -74,6 +74,7 @@ declare const registryMap: {
|
|
|
74
74
|
readonly rubygems: "RUBYGEMS";
|
|
75
75
|
readonly go: "GO";
|
|
76
76
|
readonly swift: "SWIFT";
|
|
77
|
+
readonly pub: "PUB";
|
|
77
78
|
};
|
|
78
79
|
type PkgseerRegistry = (typeof registryMap)[keyof typeof registryMap];
|
|
79
80
|
interface IndexingDurationEstimate {
|
|
@@ -1380,6 +1381,10 @@ interface PackageUpgradeUnknownEvidence {
|
|
|
1380
1381
|
message: string;
|
|
1381
1382
|
retryable?: boolean;
|
|
1382
1383
|
}
|
|
1384
|
+
interface PackageUpgradeMigrationGuide {
|
|
1385
|
+
url: string;
|
|
1386
|
+
label?: string;
|
|
1387
|
+
}
|
|
1383
1388
|
interface PackageUpgradeReview {
|
|
1384
1389
|
registry: string;
|
|
1385
1390
|
name: string;
|
|
@@ -1387,6 +1392,7 @@ interface PackageUpgradeReview {
|
|
|
1387
1392
|
targetVersion: string;
|
|
1388
1393
|
latestVersion?: string;
|
|
1389
1394
|
versionDelta: string;
|
|
1395
|
+
migrationGuides?: PackageUpgradeMigrationGuide[];
|
|
1390
1396
|
security: PackageUpgradeSecurity;
|
|
1391
1397
|
changelog: PackageUpgradeChangelog;
|
|
1392
1398
|
compatibility?: PackageUpgradeCompatibility;
|
|
@@ -1415,7 +1421,8 @@ interface DirectDependency {
|
|
|
1415
1421
|
/**
|
|
1416
1422
|
* Node in a typed dependency graph. Mirrors `DependencyGraphNode`.
|
|
1417
1423
|
* `registry` is a lowercase string: `"npm"`, `"pypi"`, …, or
|
|
1418
|
-
* `"
|
|
1424
|
+
* `"flutter_sdk"` for SDK nodes, or `"synthetic"` for project root nodes.
|
|
1425
|
+
* These graph namespaces are not package registry inputs. `version` is null
|
|
1419
1426
|
* for synthetic roots.
|
|
1420
1427
|
*/
|
|
1421
1428
|
interface DependencyGraphNode {
|
|
@@ -1691,6 +1698,14 @@ interface ChangelogStatementContext {
|
|
|
1691
1698
|
textTruncated: boolean;
|
|
1692
1699
|
fullText?: string;
|
|
1693
1700
|
}
|
|
1701
|
+
interface ChangelogStatementCommit {
|
|
1702
|
+
sha: string;
|
|
1703
|
+
url: string | null;
|
|
1704
|
+
}
|
|
1705
|
+
interface ChangelogStatementGeneration {
|
|
1706
|
+
status: "GENERATED" | "PENDING" | "NOT_GENERATED";
|
|
1707
|
+
reason: string | null;
|
|
1708
|
+
}
|
|
1694
1709
|
interface ChangelogStatement {
|
|
1695
1710
|
version: string;
|
|
1696
1711
|
position: number;
|
|
@@ -1699,6 +1714,7 @@ interface ChangelogStatement {
|
|
|
1699
1714
|
heading?: string;
|
|
1700
1715
|
source?: string;
|
|
1701
1716
|
url?: string;
|
|
1717
|
+
commits?: ChangelogStatementCommit[];
|
|
1702
1718
|
text: string;
|
|
1703
1719
|
textTruncated: boolean;
|
|
1704
1720
|
fullText?: string;
|
|
@@ -1714,6 +1730,7 @@ interface ChangelogStatementCoverage {
|
|
|
1714
1730
|
statementsNotAssessed: number;
|
|
1715
1731
|
statementsNoImpact: number;
|
|
1716
1732
|
statementsUnclassified: number;
|
|
1733
|
+
generation?: ChangelogStatementGeneration;
|
|
1717
1734
|
}
|
|
1718
1735
|
interface ChangelogStatements {
|
|
1719
1736
|
totalCount: number;
|
|
@@ -1908,6 +1925,7 @@ interface ResolveTargetParams {
|
|
|
1908
1925
|
interface ResolveTargetReference {
|
|
1909
1926
|
kind: string;
|
|
1910
1927
|
canonicalKey: string;
|
|
1928
|
+
searchTarget: string;
|
|
1911
1929
|
confidence: string;
|
|
1912
1930
|
}
|
|
1913
1931
|
interface ResolveTargetMatch {
|
|
@@ -1920,6 +1938,7 @@ interface ResolveTargetMatch {
|
|
|
1920
1938
|
interface ResolveTargetTarget {
|
|
1921
1939
|
kind: string;
|
|
1922
1940
|
canonicalKey: string;
|
|
1941
|
+
searchTarget: string;
|
|
1923
1942
|
displayName?: string;
|
|
1924
1943
|
description?: string;
|
|
1925
1944
|
registry?: string;
|