@squidcloud/client 1.0.472 → 1.0.473

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.
@@ -318,6 +318,13 @@ export interface AiChatPromptQuotas {
318
318
  * Default: 5.
319
319
  */
320
320
  maxAiCallStackSize: number;
321
+ /**
322
+ * Maximum wall-clock runtime, in seconds, of a single prompt for CLI-agent models
323
+ * (Claude Code, Codex). Optional override of the per-call self-kill deadline — mainly to
324
+ * tighten it for stricter runaway protection — clamped to [30, 1800]. Ignored for
325
+ * non-CLI-agent models. Default: the platform maximum (30 minutes).
326
+ */
327
+ maxRuntimeSeconds?: number;
321
328
  }
322
329
  /**
323
330
  * Options for AI agent execution plan, allowing the agent to plan what functionality to use (connected agents,
@@ -542,10 +549,44 @@ export interface OpenAiChatOptions extends BaseAiChatOptions {
542
549
  model?: OpenAiChatModelName;
543
550
  }
544
551
  /**
545
- * AI reasoning effort: Unsupported values are mapped to the closest supported option.
552
+ * Canonical reasoning-effort levels, ordered from least to most effort. These are the values that
553
+ * have a defined position on the effort axis and therefore participate in clamping when a model does
554
+ * not support the exact requested level.
546
555
  * @category AI
547
556
  */
548
- export type AiReasoningEffort = 'minimal' | 'low' | 'medium' | 'high';
557
+ export type CanonicalReasoningEffort = 'minimal' | 'low' | 'medium' | 'high' | 'xhigh' | 'max';
558
+ /**
559
+ * AI reasoning effort. Pass one of the canonical levels for portable, autocomplete-friendly usage, or
560
+ * a raw provider-native string when a model exposes a level outside the canonical set.
561
+ *
562
+ * Resolution against the selected model (see {@link ReasoningCapability}):
563
+ * - exact match with the model's capability -> used as-is (1:1);
564
+ * - canonical level the model lacks -> clamped to the nearest supported level (ties resolve downward);
565
+ * - unknown string the model cannot place on the axis -> dropped, so the model's own default applies,
566
+ * with a warning;
567
+ * - model without a reasoning knob -> ignored, with a warning.
568
+ * @category AI
569
+ */
570
+ export type AiReasoningEffort = CanonicalReasoningEffort | (string & {});
571
+ /**
572
+ * Declares how a model exposes reasoning effort. Used as the single source of truth for resolving a
573
+ * requested {@link AiReasoningEffort} onto what the model natively accepts. When a request cannot be
574
+ * matched or clamped, no reasoning parameter is emitted and the model applies its own native default.
575
+ *
576
+ * - `none`: the model has no reasoning knob (e.g. it always reasons).
577
+ * - `levels`: the model accepts a fixed set of named levels (emitted as a string).
578
+ * - `budget`: the model accepts a token budget; each canonical level maps to a concrete integer.
579
+ * @category AI
580
+ */
581
+ export type ReasoningCapability = {
582
+ kind: 'none';
583
+ } | {
584
+ kind: 'levels';
585
+ supported: AiReasoningEffort[];
586
+ } | {
587
+ kind: 'budget';
588
+ perLevel: Partial<Record<CanonicalReasoningEffort, number>>;
589
+ };
549
590
  /**
550
591
  * Controls response length and detail level.
551
592
  * Use `low` for brief responses,`medium` for balanced detail, or `high` for comprehensive explanations.
@@ -900,6 +941,12 @@ export interface UserAiAskResponse {
900
941
  inputTokens?: number;
901
942
  /** The number of output tokens generated by the AI agent. */
902
943
  outputTokens?: number;
944
+ /** Cached input tokens read from the prompt cache. Only set by providers that report it (e.g. claude-code). */
945
+ cacheReadInputTokens?: number;
946
+ /** Input tokens written to the prompt cache. Only set by providers that report it (e.g. claude-code). */
947
+ cacheWriteInputTokens?: number;
948
+ /** Total request cost in USD as reported by the provider. Only set by providers that compute it (e.g. claude-code). */
949
+ totalCostUsd?: number;
903
950
  }
904
951
  /** Represents an annotation in the AI response. */
905
952
  export type AiAnnotation = AiFileAnnotation;
@@ -0,0 +1,12 @@
1
+ /**
2
+ * List of all connector package names.
3
+ * To prevent automatic discovery && latest version sync in 'prod' add your connector package name to
4
+ * 'CONNECTOR_PACKAGES_TO_EXCLUDE_FROM_AUTO_SYNC' in ConnectorsService (console-backend).
5
+ * @category Platform
6
+ */
7
+ export declare const CONNECTOR_IDS: readonly ["confluence", "cotomi", "essentials", "freshdesk", "github", "google_calendar", "google_drive", "hubspot", "sharepoint", "jira", "jira_jsm", "linear", "mail", "onedrive", "salesforce", "servicenow_csm", "slack", "teams", "ticketmind_companion", "zendesk"];
8
+ /**
9
+ * Unique connector package name.
10
+ * @category Platform
11
+ */
12
+ export type ConnectorId = (typeof CONNECTOR_IDS)[number];
@@ -1,8 +1,9 @@
1
+ import { ConnectorClient } from './connector-client';
1
2
  import { IntegrationClient } from './integration-client';
2
3
  import { SecretClient } from './secret.client';
3
4
  /**
4
5
  * AdminClient provides access to application administrative operations,
5
- * including integrations and secrets management.
6
+ * including integrations, connectors, and secrets management.
6
7
  * @category Platform
7
8
  */
8
9
  export declare class AdminClient {
@@ -11,11 +12,16 @@ export declare class AdminClient {
11
12
  private readonly appId;
12
13
  private readonly consoleRegion;
13
14
  private readonly integrationClient;
15
+ private readonly connectorClient;
14
16
  private readonly secretClient;
15
17
  /**
16
18
  * Returns the IntegrationClient for managing integrations.
17
19
  */
18
20
  integrations(): IntegrationClient;
21
+ /**
22
+ * Returns the ConnectorClient for managing app-level (integration-less) connectors.
23
+ */
24
+ connectors(): ConnectorClient;
19
25
  /**
20
26
  * Returns the SecretClient for managing secrets.
21
27
  */
@@ -0,0 +1,32 @@
1
+ import { ConnectorId } from './public-types';
2
+ /**
3
+ * ConnectorClient manages app-level (integration-less) connectors attached to an application.
4
+ *
5
+ * Unlike integrations, these connectors carry no per-connector configuration record — attaching one
6
+ * simply adds it to the application's `appConnectors` list and (re)deploys its bundle. Any configuration
7
+ * the connector needs is provided out of band (e.g. via application secrets).
8
+ * @category Platform
9
+ */
10
+ export declare class ConnectorClient {
11
+ private readonly rpcManager;
12
+ private readonly iacBaseUrl;
13
+ /**
14
+ * Lists the connectors explicitly attached to the application.
15
+ *
16
+ * @returns A promise that resolves with the list of attached connector ids.
17
+ */
18
+ list(): Promise<Array<ConnectorId>>;
19
+ /**
20
+ * Attaches a connector to the application. Idempotent — attaching an already-attached connector is a
21
+ * no-op on the platform side.
22
+ *
23
+ * @param connectorId - The id of the connector to attach.
24
+ */
25
+ connect(connectorId: ConnectorId): Promise<void>;
26
+ /**
27
+ * Detaches a connector from the application.
28
+ *
29
+ * @param connectorId - The id of the connector to detach.
30
+ */
31
+ disconnect(connectorId: ConnectorId): Promise<void>;
32
+ }
@@ -17,6 +17,7 @@ export * from './client-id.service';
17
17
  export * from './collection-reference';
18
18
  export * from './collection-reference.factory';
19
19
  export * from './connection-details';
20
+ export * from './connector-client';
20
21
  export * from './console-utils';
21
22
  export * from './data.manager';
22
23
  export * from './destruct.manager';
@@ -11,6 +11,7 @@ export * from '../../internal-common/src/public-types/api.public-types';
11
11
  export * from '../../internal-common/src/public-types/backend.public-types';
12
12
  export * from '../../internal-common/src/public-types/code-executor.public-types';
13
13
  export * from '../../internal-common/src/public-types/communication.public-types';
14
+ export * from '../../internal-common/src/public-types/connector.public-types';
14
15
  export * from '../../internal-common/src/public-types/context.public-types';
15
16
  export * from '../../internal-common/src/public-types/document.public-types';
16
17
  export * from '../../internal-common/src/public-types/event.public-types';
@@ -2,4 +2,4 @@
2
2
  * The current version of the SquidCloud client package.
3
3
  * @category Platform
4
4
  */
5
- export declare const SQUIDCLOUD_CLIENT_PACKAGE_VERSION = "1.0.472";
5
+ export declare const SQUIDCLOUD_CLIENT_PACKAGE_VERSION = "1.0.473";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@squidcloud/client",
3
- "version": "1.0.472",
3
+ "version": "1.0.473",
4
4
  "description": "A typescript implementation of the Squid client",
5
5
  "main": "dist/cjs/index.js",
6
6
  "module": "dist/esm/index.js",