chore: cleanup legacy logic (#15072)
This commit is contained in:
71
packages/backend/native/index.d.ts
vendored
71
packages/backend/native/index.d.ts
vendored
@@ -48,6 +48,8 @@ export interface ActionTrace {
|
||||
errorCode?: string
|
||||
}
|
||||
|
||||
export declare function activateLicense(request: LicenseKeyRequest): Promise<LicenseResponse>
|
||||
|
||||
/**
|
||||
* Adds a document ID to the workspace root doc's meta.pages array.
|
||||
* This registers the document in the workspace so it appears in the UI.
|
||||
@@ -151,11 +153,17 @@ export interface CapabilityModelContract {
|
||||
capabilities: Array<CapabilityModelCapability>
|
||||
}
|
||||
|
||||
export declare function checkLicenseHealth(request: LicenseHealthRequest): Promise<LicenseResponse>
|
||||
|
||||
export interface Chunk {
|
||||
index: number
|
||||
content: string
|
||||
}
|
||||
|
||||
export interface CommandResponse {
|
||||
error?: LicenseError
|
||||
}
|
||||
|
||||
/**
|
||||
* Converts markdown content to AFFiNE-compatible y-octo document binary.
|
||||
*
|
||||
@@ -169,6 +177,10 @@ export interface Chunk {
|
||||
*/
|
||||
export declare function createDocWithMarkdown(title: string, markdown: string, docId: string): Buffer
|
||||
|
||||
export declare function createLicenseCustomerPortal(request: LicenseKeyRequest): Promise<PortalResponse>
|
||||
|
||||
export declare function deactivateLicense(request: LicenseKeyRequest): Promise<CommandResponse>
|
||||
|
||||
export declare function evaluatePermissionV1(input: any): any
|
||||
|
||||
export declare function fetchRemoteAttachment(request: RemoteAttachmentFetchRequest): Promise<RemoteAttachmentFetchResponse>
|
||||
@@ -195,6 +207,43 @@ export declare function inferRemoteMimeType(request: RemoteMimeTypeRequest): Pro
|
||||
|
||||
export declare function inspectImageForProxy(input: Buffer, options?: ImageInspectionOptions | undefined | null): ImageInspection
|
||||
|
||||
export interface LicenseError {
|
||||
status: number
|
||||
body: string
|
||||
}
|
||||
|
||||
export interface LicenseHealthRequest {
|
||||
licenseKey: string
|
||||
validateKey: string
|
||||
}
|
||||
|
||||
export interface LicenseInfo {
|
||||
plan: string
|
||||
recurring: string
|
||||
quantity: number
|
||||
expiresAt: number
|
||||
validateKey: string
|
||||
}
|
||||
|
||||
export interface LicenseKeyRequest {
|
||||
licenseKey: string
|
||||
}
|
||||
|
||||
export interface LicenseRecurringRequest {
|
||||
licenseKey: string
|
||||
recurring: string
|
||||
}
|
||||
|
||||
export interface LicenseResponse {
|
||||
license?: LicenseInfo
|
||||
error?: LicenseError
|
||||
}
|
||||
|
||||
export interface LicenseSeatsRequest {
|
||||
licenseKey: string
|
||||
seats: number
|
||||
}
|
||||
|
||||
export declare function llmBuildCanonicalRequest(request: CanonicalChatRequestContract): LlmRequestContract
|
||||
|
||||
export declare function llmBuildCanonicalStructuredRequest(request: CanonicalStructuredRequestContract): LlmStructuredRequestContract
|
||||
@@ -481,6 +530,11 @@ export declare function permissionActionRoleMatrixV1(): any
|
||||
|
||||
export declare function permissionActionRoleMatrixV1Json(): string
|
||||
|
||||
export interface PortalResponse {
|
||||
url?: string
|
||||
error?: LicenseError
|
||||
}
|
||||
|
||||
export declare function processImage(input: Buffer, maxEdge: number, keepExif: boolean): Promise<Buffer>
|
||||
|
||||
export type PromptBuiltin = 'Date'|
|
||||
@@ -687,15 +741,26 @@ export declare function runNativeActionRecipePreparedStream(input: ActionRuntime
|
||||
export declare function safeFetch(request: SafeFetchRequest): Promise<SafeFetchResponse>
|
||||
|
||||
export type SafeFetchMethod = 'get'|
|
||||
'head';
|
||||
'head'|
|
||||
'post'|
|
||||
'put'|
|
||||
'propfind'|
|
||||
'report';
|
||||
|
||||
export interface SafeFetchRequest {
|
||||
url: string
|
||||
method?: SafeFetchMethod
|
||||
headers?: Record<string, string>
|
||||
body?: Buffer
|
||||
timeoutMs?: number
|
||||
maxRedirects?: number
|
||||
maxBytes?: number
|
||||
allowedHeaders?: Array<string>
|
||||
allowedHosts?: Array<string>
|
||||
allowHttp?: boolean
|
||||
allowPrivateTargetOrigin?: boolean
|
||||
enableEch?: boolean
|
||||
echConfigList?: Buffer
|
||||
}
|
||||
|
||||
export interface SafeFetchResponse {
|
||||
@@ -754,6 +819,10 @@ export declare function updateDocTitle(existingBinary: Buffer, title: string, do
|
||||
*/
|
||||
export declare function updateDocWithMarkdown(existingBinary: Buffer, newMarkdown: string, docId: string): Buffer
|
||||
|
||||
export declare function updateLicenseRecurring(request: LicenseRecurringRequest): Promise<CommandResponse>
|
||||
|
||||
export declare function updateLicenseSeats(request: LicenseSeatsRequest): Promise<CommandResponse>
|
||||
|
||||
/**
|
||||
* Updates a document title in the workspace root doc's meta.pages array.
|
||||
*
|
||||
|
||||
Reference in New Issue
Block a user