@mdedit/agent-client
Advanced tools
+16
-4
@@ -8,2 +8,10 @@ import { ReviewCommand, ArticleReviewCommandsResponse, ReviewCommentThread, ReviewHighlight, ReviewSuggestion, GetArticleReviewResponse, ArticleReviewCommandsRequest, ReviewDocument, ReviewHistoryEvent } from '@mdedit/types'; | ||
| }; | ||
| type AgentCredential = { | ||
| headers: Record<string, string>; | ||
| websocketToken: string; | ||
| }; | ||
| interface AgentCredentialProvider { | ||
| getCredential(): Promise<AgentCredential>; | ||
| refreshCredential?(): Promise<AgentCredential>; | ||
| } | ||
| type QuoteContext = { | ||
@@ -199,4 +207,8 @@ before?: string; | ||
| type OpenArticleSessionOptions = { | ||
| /** API key used for REST requests. */ | ||
| apiKey: string; | ||
| /** Cancels initial REST/WebSocket work and closes the resulting session. */ | ||
| signal?: AbortSignal; | ||
| /** Refresh-capable REST/WebSocket credential provider. */ | ||
| credentialProvider?: AgentCredentialProvider; | ||
| /** API-key compatibility wrapper. Prefer credentialProvider for new integrations. */ | ||
| apiKey?: string; | ||
| /** Optional websocket credential override. Defaults to the API key. */ | ||
@@ -362,5 +374,5 @@ websocketToken?: string; | ||
| declare function openArticleSession(options: OpenArticleSessionOptions): Promise<ArticleSession>; | ||
| declare function openArticleReviewSession(options: Pick<OpenArticleSessionOptions, 'apiKey' | 'workspaceId' | 'articleId' | 'apiUrl'>): ArticleReviewSession; | ||
| declare function openArticleReviewSession(options: Pick<OpenArticleSessionOptions, 'apiKey' | 'credentialProvider' | 'workspaceId' | 'articleId' | 'apiUrl' | 'signal'>): ArticleReviewSession; | ||
| declare function createArticleReviewSession(options: CreateArticleReviewSessionOptions): ArticleReviewSession; | ||
| export { type AfterHeadingAnchor, AgentArticleReviewSession, AgentClientError, AgentClientHttpError, type AgentClientTelemetry, type AgentClientTelemetryEvent, type AgentIdentity, type AgentPresenceIdentity, AmbiguousAnchorError, type AnchorCandidate, AnchorNotFoundError, type AppliedEdit, type ArticlePresence, type ArticleReviewSession, type ArticleReviewTransport, type ArticleSession, type ArticleSessionEvent, type ArticleSessionEventOptions, type ArticleSessionMode, type BeforeHeadingAnchor, CollaborationModeChangedError, type CollaborationStatus, type ContentAnchor, ContentHashMismatchError, type CreateArticleReviewSessionOptions, type EditConflict, type EditOperation, type EditOptions, type EditResult, type InSectionAnchor, InvalidAnchorError, type OpenArticleSessionOptions, type QuoteAnchor, type QuoteContext, type RangeAnchor, ReadOnlySessionError, RestContentConflictError, type ReviewAnchorInput, type ReviewListItem, type ReviewListOptions, type ReviewMutationOptions, SessionClosedError, SessionConnectionError, createArticleReviewSession, normalizeApiBaseUrl, openArticleReviewSession, openArticleSession }; | ||
| export { type AfterHeadingAnchor, AgentArticleReviewSession, AgentClientError, AgentClientHttpError, type AgentClientTelemetry, type AgentClientTelemetryEvent, type AgentCredential, type AgentCredentialProvider, type AgentIdentity, type AgentPresenceIdentity, AmbiguousAnchorError, type AnchorCandidate, AnchorNotFoundError, type AppliedEdit, type ArticlePresence, type ArticleReviewSession, type ArticleReviewTransport, type ArticleSession, type ArticleSessionEvent, type ArticleSessionEventOptions, type ArticleSessionMode, type BeforeHeadingAnchor, CollaborationModeChangedError, type CollaborationStatus, type ContentAnchor, ContentHashMismatchError, type CreateArticleReviewSessionOptions, type EditConflict, type EditOperation, type EditOptions, type EditResult, type InSectionAnchor, InvalidAnchorError, type OpenArticleSessionOptions, type QuoteAnchor, type QuoteContext, type RangeAnchor, ReadOnlySessionError, RestContentConflictError, type ReviewAnchorInput, type ReviewListItem, type ReviewListOptions, type ReviewMutationOptions, SessionClosedError, SessionConnectionError, createArticleReviewSession, normalizeApiBaseUrl, openArticleReviewSession, openArticleSession }; |
+1
-1
| { | ||
| "name": "@mdedit/agent-client", | ||
| "version": "0.2.0", | ||
| "version": "1.0.0", | ||
| "private": false, | ||
@@ -5,0 +5,0 @@ "type": "module", |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
No v1
QualityPackage is not semver >=1. This means it is not stable and does not support ^ ranges.
1117444
0.76%11220
1.01%1
-50%