@redonvn/event-ws-cliproxyapi-sdk 1.0.2 → 1.0.3

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.
@@ -1,4 +1,4 @@
1
- import type { AmpModelMapping, AmpModelMappingsPatch, AmpUpstreamAPIKeyEntry, AmpUpstreamAPIKeysPatch, ApiCallRequest, ApiCallResponse, AuthFileDeleteResponse, AuthFileListQuery, AuthFileListResponse, AuthFileModelsQuery, AuthFileModelsResponse, AuthFileStatusRequest, AuthFileStatusResponse, AuthStatusResponse, DesktopKeysResponse, ManagementApiKeysResponse, ClaudeKey, ClaudeKeyPatch, CodexKey, CodexKeyPatch, Config, DeleteLogsResponse, ErrorLogFilesResponse, GeminiKey, GeminiKeyPatch, KeyedValueResponse, LogLinesResponse, OAuthCallbackRequest, OAuthCallbackResponse, OAuthExcludedModelsPatch, OAuthModelAlias, OAuthModelAliasPatch, OAuthStartResponse, OpenAICompatibility, OpenAICompatPatch, PatchByIndexOrMatch, PatchStringListRequest, UsageExportResponse, UsageGetResponse, UsageImportRequest, UsageImportResponse, VertexCompatKey, VertexCompatPatch } from '../shared/types.js';
1
+ import type { AmpModelMapping, AmpModelMappingsPatch, AmpUpstreamAPIKeyEntry, AmpUpstreamAPIKeysPatch, ApiCallRequest, ApiCallResponse, AuthFileDeleteResponse, AuthFileListQuery, AuthFileListResponse, AuthFileModelsQuery, AuthFileModelsResponse, AuthFileStatusRequest, AuthFileStatusResponse, AuthStatusResponse, DesktopKeysResponse, ManagementApiKeysResponse, ClaudeKey, ClaudeKeyPatch, CodexKey, CodexKeyPatch, Config, DeleteLogsResponse, ErrorLogFilesResponse, GeminiKey, GeminiKeyPatch, KeyedValueResponse, LogLinesResponse, OAuthCallbackRequest, OAuthCallbackResponse, OAuthExcludedModelsPatch, OAuthModelAlias, OAuthModelAliasPatch, OAuthStartResponse, OpenAICompatibility, OpenAICompatPatch, PatchByIndexOrMatch, PatchStringListRequest, UsageExportResponse, UsageGetResponse, UsageImportRequest, UsageImportResponse, UpdateConnectionSettingsRequest, VertexCompatKey, VertexCompatPatch } from '../shared/types.js';
2
2
  import { BaseHttpClient } from '../shared/http.js';
3
3
  export declare class ManagementClient extends BaseHttpClient {
4
4
  getDesktopKeys(): Promise<DesktopKeysResponse>;
@@ -9,6 +9,7 @@ export declare class ManagementClient extends BaseHttpClient {
9
9
  getConfig(): Promise<Config>;
10
10
  getConfigYaml(): Promise<string>;
11
11
  putConfigYaml(body: string): Promise<KeyedValueResponse<"status", "ok">>;
12
+ putConnectionSettings(body: UpdateConnectionSettingsRequest): Promise<KeyedValueResponse<"status", "ok">>;
12
13
  getLatestVersion(): Promise<KeyedValueResponse<"latest-version", string>>;
13
14
  getDebug(): Promise<KeyedValueResponse<"debug", boolean>>;
14
15
  putDebug(body: KeyedValueResponse<'value', boolean>): Promise<KeyedValueResponse<"status", "ok">>;
@@ -42,6 +42,9 @@ export class ManagementClient extends BaseHttpClient {
42
42
  return text ? JSON.parse(text) : { status: 'ok' };
43
43
  });
44
44
  }
45
+ putConnectionSettings(body) {
46
+ return this.requestJson('PUT', '/v0/management/connection-settings', body, undefined, 'management');
47
+ }
45
48
  getLatestVersion() {
46
49
  return this.requestJson('GET', '/v0/management/latest-version', undefined, undefined, 'management');
47
50
  }
@@ -1,2 +1,2 @@
1
1
  export { ManagementClient } from './client.js';
2
- export type { SDKConfig, StreamingConfig, AccessConfig, AccessProvider, TLSConfig, PprofConfig, RemoteManagementConfig, QuotaExceededConfig, RoutingConfig, OAuthModelAlias, AmpModelMapping, AmpUpstreamAPIKeyEntry, AmpCodeConfig, PayloadConfig, PayloadFilterRule, PayloadRule, PayloadModelRule, CloakConfig, ClaudeModel, ClaudeKey, CodexModel, CodexKey, GeminiModel, GeminiKey, OpenAICompatibilityAPIKey, OpenAICompatibilityModel, OpenAICompatibility, VertexCompatModel, VertexCompatKey, Config, UsageTokenStats, UsageRequestDetail, UsageModelSnapshot, UsageApiSnapshot, UsageStatisticsSnapshot, UsageGetResponse, UsageExportResponse, UsageImportRequest, UsageImportResponse, ApiCallRequest, ApiCallResponse, ErrorResponse, StatusResponse, LogLinesResponse, DeleteLogsResponse, ErrorLogFileInfo, ErrorLogFilesResponse, AuthFileEntry, AuthFileListResponse, AuthFileModelsResponse, AuthFileUploadResponse, AuthFileDeleteResponse, AuthFileStatusRequest, AuthFileStatusResponse, OAuthCallbackRequest, OAuthCallbackResponse, OAuthStartResponse, AuthStatusResponse, AuthFileDownloadRequest, AuthFileListQuery, AuthFileModelsQuery, PatchStringListRequest, PatchByIndexOrMatch, GeminiKeyPatch, ClaudeKeyPatch, CodexKeyPatch, OpenAICompatPatch, VertexCompatPatch, OAuthExcludedModelsPatch, OAuthModelAliasPatch, AmpModelMappingsPatch, AmpUpstreamAPIKeysPatch, AmpStringListPatch, AuthFileUploadRequest, VertexImportRequest, RootResponse, KeepAliveResponse, DesktopKeysResponse, ManagementApiKeysResponse, ModelThinkingSupport, ModelInfo, ModelListResponse } from '../shared/types.js';
2
+ export type { SDKConfig, StreamingConfig, AccessConfig, AccessProvider, TLSConfig, PprofConfig, RemoteManagementConfig, QuotaExceededConfig, RoutingConfig, OAuthModelAlias, AmpModelMapping, AmpUpstreamAPIKeyEntry, AmpCodeConfig, PayloadConfig, PayloadFilterRule, PayloadRule, PayloadModelRule, CloakConfig, ClaudeModel, ClaudeKey, CodexModel, CodexKey, GeminiModel, GeminiKey, OpenAICompatibilityAPIKey, OpenAICompatibilityModel, OpenAICompatibility, VertexCompatModel, VertexCompatKey, Config, UsageTokenStats, UsageRequestDetail, UsageModelSnapshot, UsageApiSnapshot, UsageStatisticsSnapshot, UsageGetResponse, UsageExportResponse, UsageImportRequest, UsageImportResponse, UpdateConnectionSettingsRequest, ApiCallRequest, ApiCallResponse, ErrorResponse, StatusResponse, LogLinesResponse, DeleteLogsResponse, ErrorLogFileInfo, ErrorLogFilesResponse, AuthFileEntry, AuthFileListResponse, AuthFileModelsResponse, AuthFileUploadResponse, AuthFileDeleteResponse, AuthFileStatusRequest, AuthFileStatusResponse, OAuthCallbackRequest, OAuthCallbackResponse, OAuthStartResponse, AuthStatusResponse, AuthFileDownloadRequest, AuthFileListQuery, AuthFileModelsQuery, PatchStringListRequest, PatchByIndexOrMatch, GeminiKeyPatch, ClaudeKeyPatch, CodexKeyPatch, OpenAICompatPatch, VertexCompatPatch, OAuthExcludedModelsPatch, OAuthModelAliasPatch, AmpModelMappingsPatch, AmpUpstreamAPIKeysPatch, AmpStringListPatch, AuthFileUploadRequest, VertexImportRequest, RootResponse, KeepAliveResponse, DesktopKeysResponse, ManagementApiKeysResponse, ModelThinkingSupport, ModelInfo, ModelListResponse } from '../shared/types.js';
@@ -332,6 +332,16 @@ export interface UsageImportResponse {
332
332
  total_requests: number;
333
333
  failed_requests: number;
334
334
  }
335
+ export interface UpdateConnectionSettingsRequest {
336
+ 'base-url'?: string;
337
+ baseUrl?: string;
338
+ 'access-api-key'?: string;
339
+ accessApiKey?: string;
340
+ 'api-key'?: string;
341
+ apiKey?: string;
342
+ 'management-key'?: string;
343
+ managementKey?: string;
344
+ }
335
345
  export interface ApiCallRequest {
336
346
  auth_index?: string;
337
347
  authIndex?: string;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@redonvn/event-ws-cliproxyapi-sdk",
3
- "version": "1.0.2",
3
+ "version": "1.0.3",
4
4
  "description": "TypeScript SDK for CLIProxyAPI WebSocket relay (provider-side).",
5
5
  "license": "MIT",
6
6
  "type": "module",