-
Notifications
You must be signed in to change notification settings - Fork 1.8k
Expand file tree
/
Copy pathindex.ts
More file actions
80 lines (76 loc) · 3.05 KB
/
index.ts
File metadata and controls
80 lines (76 loc) · 3.05 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
// Public API for @modelcontextprotocol/client.
//
// This file defines the complete public surface. It consists of:
// - Package-specific exports: listed explicitly below (named imports)
// - Protocol-level types: re-exported from @modelcontextprotocol/core/public
//
// Any new export added here becomes public API. Use named exports, not wildcards.
export type {
AddClientAuthentication,
AuthProvider,
AuthResult,
ClientAuthMethod,
OAuthClientProvider,
OAuthDiscoveryState,
OAuthServerInfo
} from './client/auth.js';
export {
auth,
buildDiscoveryUrls,
discoverAuthorizationServerMetadata,
discoverOAuthMetadata,
discoverOAuthProtectedResourceMetadata,
discoverOAuthServerInfo,
exchangeAuthorization,
extractResourceMetadataUrl,
extractWWWAuthenticateParams,
fetchToken,
isHttpsUrl,
parseErrorResponse,
prepareAuthorizationCodeRequest,
refreshAuthorization,
registerClient,
selectClientAuthMethod,
selectResourceURL,
startAuthorization,
UnauthorizedError
} from './client/auth.js';
export type {
AssertionCallback,
ClientCredentialsProviderOptions,
CrossAppAccessContext,
CrossAppAccessProviderOptions,
PrivateKeyJwtProviderOptions,
StaticPrivateKeyJwtProviderOptions
} from './client/authExtensions.js';
export {
ClientCredentialsProvider,
createPrivateKeyJwtAuth,
CrossAppAccessProvider,
PrivateKeyJwtProvider,
StaticPrivateKeyJwtProvider
} from './client/authExtensions.js';
export type { ClientOptions } from './client/client.js';
export { Client } from './client/client.js';
export { getSupportedElicitationModes } from './client/client.js';
export type { DiscoverAndRequestJwtAuthGrantOptions, JwtAuthGrantResult, RequestJwtAuthGrantOptions } from './client/crossAppAccess.js';
export { discoverAndRequestJwtAuthGrant, exchangeJwtAuthGrant, requestJwtAuthorizationGrant } from './client/crossAppAccess.js';
export type { LoggingOptions, Middleware, RequestLogger } from './client/middleware.js';
export { applyMiddlewares, createMiddleware, withLogging, withOAuth } from './client/middleware.js';
export type { SSEClientTransportOptions } from './client/sse.js';
export { SSEClientTransport, SseError } from './client/sse.js';
// StdioClientTransport, getDefaultEnvironment, DEFAULT_INHERITED_ENV_VARS, StdioServerParameters are exported from
// the './stdio' subpath to keep the root entry free of process-spawning runtime dependencies (child_process, cross-spawn).
export type {
ReconnectionScheduler,
StartSSEOptions,
StreamableHTTPClientTransportOptions,
StreamableHTTPReconnectionOptions
} from './client/streamableHttp.js';
export { StreamableHTTPClientTransport } from './client/streamableHttp.js';
// experimental exports
export { ExperimentalClientTasks } from './experimental/tasks/client.js';
// runtime-aware wrapper (shadows core/public's fromJsonSchema with optional validator)
export { fromJsonSchema } from './fromJsonSchema.js';
// re-export curated public API from core
export * from '@modelcontextprotocol/core/public';