@revoengine/sdk 1.6.2 → 1.6.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.
package/README.md CHANGED
@@ -1,12 +1,12 @@
1
1
  # @revoengine/sdk
2
2
 
3
3
  Official Node.js SDK for RevoEngine. It provides the modern `api`, `utils`,
4
- `storage`, `transport`, and `agents` namespaces, top-level `execute()`, and the `batch` controller in both
4
+ `storage`, `transport`, `vault`, and `agents` namespaces, top-level `execute()`, and the `batch` controller in both
5
5
  Revo-hosted `CUSTOM_NODEJS` components and standalone Node.js applications.
6
6
 
7
7
  Requirements: Node.js 22 or newer.
8
8
 
9
- ## SDK 1.6.2 compatibility
9
+ ## SDK 1.6.3 compatibility
10
10
 
11
11
  This release synchronizes the complete public SDK contract with the current
12
12
  platform low-code declarations. Remote calls require a platform runtime that admits
@@ -28,7 +28,7 @@ Legacy SFTP helpers and the removed thread-goal methods are not exposed by the
28
28
  current SDK contract. Refer to the [transfer guide](https://docs.revoengine.com/low-code/sftp)
29
29
  for Secret formats and file-transfer examples.
30
30
 
31
- SDK 1.6.2 retains portable Component digest declarations and one readable-relation
31
+ SDK 1.6.3 retains portable Component digest declarations and one readable-relation
32
32
  contract for Databases, live Views, and Materialized Views. Use `api.exportDatabase()`
33
33
  for all three relation types. `api.getDatabaseViewData()` remains a deprecated
34
34
  read alias; `api.exportDatabaseView()` and separate REST View export operations
@@ -41,6 +41,9 @@ returns its job ID for operation tracking. The import workflow starts with
41
41
  describe the current request and response shapes; the platform still enforces
42
42
  permissions and validates source and target state before committing an import.
43
43
 
44
+ Assistant model inputs follow the current platform: `gpt-6.1-sol` and
45
+ `gpt-6-luna`; Fast mode is supported for Luna. Update older Sol model identifiers.
46
+
44
47
  Remote MCP server configurations in this contract use public HTTPS destinations.
45
48
  Private-network access is not an accepted SDK setting; review the server URL,
46
49
  provider consent, Vault binding, and tool permissions before enabling a plugin.
@@ -52,14 +55,14 @@ provider consent, Vault binding, and tool permissions before enabling a plugin.
52
55
  | Revo-hosted `CUSTOM_NODEJS` | Export `async function init(runtime)` | Revo injects an execution-bound runtime; user code receives no API key. |
53
56
  | Standalone Node.js | Create `new RevoClient(options)` | Supply a RevoEngine API key explicitly or through an environment variable. |
54
57
 
55
- Both modes expose the same `api`, `utils`, `storage`, `transport`, `agents`, `execute`, and `batch`
58
+ Both modes expose the same `api`, `utils`, `storage`, `transport`, `vault`, `agents`, `execute`, and `batch`
56
59
  properties, but return types reflect where the work happens:
57
60
 
58
61
  | Call kind | Revo-hosted | Standalone |
59
62
  | --- | --- | --- |
60
63
  | Execution snapshot, cache, debug, and logging | Synchronous | Throws synchronously because no execution context exists |
61
64
  | Current user and instance | Synchronous injected snapshot | Asynchronous lazy `/api/v1/me` discovery |
62
- | Remote `api`, `storage`, `agents`, and `execute()` calls | Asynchronous | Asynchronous |
65
+ | Remote `api`, `storage`, `transport`, `vault`, `agents`, and `execute()` calls | Asynchronous | Asynchronous |
63
66
  | Local `utils` and `batch.configure()` | Synchronous unless the utility is inherently asynchronous | Same |
64
67
 
65
68
  ## Installation
@@ -76,7 +79,7 @@ RevoEngine pins that version again in the deployment package and injects the
76
79
  runtime into the component entrypoint. Component code does not construct a
77
80
  `RevoClient`.
78
81
 
79
- The platform chooses the hosted package version; publishing SDK 1.6.2 does not
82
+ The platform chooses the hosted package version; publishing SDK 1.6.3 does not
80
83
  upgrade existing hosted deployments or their generated package pins.
81
84
 
82
85
  Hosted user code receives neither a tenant API key nor the private runtime
@@ -95,7 +98,7 @@ separate initialization method.
95
98
  ```js
96
99
  /** @param {import('@revoengine/sdk').RevoRuntime} runtime */
97
100
  export async function init(runtime) {
98
- const { api, utils, storage, agents, execute, batch } = runtime;
101
+ const { api, utils, storage, vault, agents, execute, batch } = runtime;
99
102
  const { data: rows, next } = await api.getDatabaseData('Sales', {
100
103
  fields: ['saleId', 'customerId', 'total', 'createdAt'],
101
104
  sort: ['-createdAt'],
@@ -787,3 +790,85 @@ Common subclasses include:
787
790
  - Deprecated low-code methods and aliases are excluded.
788
791
  - `api.transactionDatabaseData` is excluded.
789
792
  - Runtime batches are non-transactional and are not retried automatically.
793
+
794
+ ## Vault manager
795
+
796
+ The native `client.vault` manager uses the same get/create/update/delete/rotate
797
+ contract for instance (default) and verified user scope. Get alone returns
798
+ `secret.revision.value` as a Buffer containing the stored UTF-8 text; Rotate returns metadata without values.
799
+ Revision versions are normalized validFrom timestamps. validFrom accepts null,
800
+ Date, ISO or epoch milliseconds; a future Rotate preserves current availability.
801
+ `listRevisions` exposes paginated metadata history.
802
+
803
+ ```ts
804
+ const secret = await client.vault.get('TOKEN', { scope: 'user' });
805
+ const token = secret.revision.value.toString('utf8');
806
+ await client.vault.rotate('TOKEN', { value: replacement }, { scope: 'user', validFrom: null });
807
+ ```
808
+
809
+ Do not log values or access tokens. Instance access requires Secret roles and
810
+ creator ownership or administrator rights. User scope uses the verified account;
811
+ management requires owner rights and does not inherit saved Component/Tool grants.
812
+ Writes return null in debug/read-only execution. See the
813
+ [Vault guide](https://docs.revoengine.com/low-code/reference/vault) for all methods.
814
+
815
+ The same flat manager exposes `getAccessToken`, `getIntegrationMetadata`,
816
+ `discoverIntegration`, `connectIntegration`, and `disconnectIntegration`. Token reads
817
+ return the access token with its matching ISO expiry and refresh when necessary.
818
+ Connect requires nullable `expectedRevision` (null to create) and returns an
819
+ authorization URL for interactive consent through the existing frontend callback.
820
+ Disconnect retains definition/history/grants and does not revoke provider access.
821
+ Saved Component/Tool reads preserve exact personal grants; direct SDK owner/admin
822
+ reads and management are authorized separately.
823
+
824
+
825
+ ## Bulk Jobs and Webhooks
826
+
827
+ Use `api.cancelJobs`, `retryJobs`, `deleteJobs`, `cancelWebhooks`, `retryWebhooks`,
828
+ and `deleteWebhooks` with exactly one non-empty platform `filter` or an ID array
829
+ (`jobIds` / `webhookIds`, 1–1000 IDs). A filter selects every matching row beyond
830
+ list pagination. An optional actor-scoped `idempotencyKey` protects repeat admission.
831
+ The SDK never automatically retries mutations.
832
+
833
+ ```ts
834
+ const input = {
835
+ filter: { field: 'status', op: 'eq', value: 'ERROR' },
836
+ idempotencyKey: 'retry-errors-2026-10-01',
837
+ };
838
+ const preview = await client.api.previewAutomationOperation('jobs', 'retry', input);
839
+ // Review advisory preview.matched / preview.eligible before submitting.
840
+ const operation = await client.api.retryJobs(input);
841
+ const progress = await client.api.getAutomationOperation(operation.operationId);
842
+ const outcomes = await client.api.getAutomationOperationItems(operation.operationId);
843
+ // Fetch subsequent pages with outcomes.nextCursor as the second argument.
844
+ ```
845
+
846
+ Operations report `PENDING`, `PROCESSING`, `FINISHED`, or `ERROR`, plus
847
+ `total`, `processed`, `skipped`, and `failed`. `FINISHED` means lifecycle requests
848
+ were processed; downstream execution/delivery may continue and failed can be non-zero.
849
+ Item pages contain safe source/result IDs and error codes. Preview is advisory;
850
+ admission freezes selection and the worker rechecks state and permissions.
851
+ Cancel/delete require Automation Admin; retry accepts Automation Runner/Admin.
852
+
853
+ `retryWebhooks` accepts `requestPatch`: url/method/body replace whole fields;
854
+ headers/query accept `set` and `remove`, and `maskDetails` adds masks while preserving
855
+ existing masks. Masked original values cannot be recovered: provide explicit
856
+ replacements or the item fails with `REPLAY_PAYLOAD_UNAVAILABLE`. If the entire
857
+ headers section was masked, `headers.set` supplies its complete replacement.
858
+ Request patches are limited to 1 MiB of serialized JSON. Never log replacement
859
+ credentials. The operation result does not expose saved request bodies.
860
+
861
+ ```ts
862
+ await client.api.retryWebhooks({
863
+ webhookIds: selectedWebhookIds,
864
+ idempotencyKey: retryAdmissionKey,
865
+ requestPatch: {
866
+ headers: { set: { Authorization: `Bearer ${replacementToken}` }, remove: ['X-Old-Key'] },
867
+ query: { set: { apiVersion: '2' }, remove: ['legacy'] },
868
+ maskDetails: ['headers.Authorization'],
869
+ },
870
+ });
871
+ ```
872
+
873
+ The target platform requires the bulk-operation migration and an active API worker
874
+ lane. Publishing this SDK does not deploy them or change the hosted SDK pin.
@@ -1,9 +1,10 @@
1
1
  import * as node_worker_threads from 'node:worker_threads';
2
+ import { Buffer as Buffer$1 } from 'node:buffer';
2
3
 
3
- declare const SDK_VERSION: "1.6.2";
4
+ declare const SDK_VERSION: "1.6.3";
4
5
  declare const PROTOCOL_VERSION: 1;
5
- declare const CONTRACT_REVISION: "904f6aea1cacfc32b7fda4e976b2e01f73202462f8a4785dc12deac7c4563e38";
6
- type RuntimeSurfaceName = 'api' | 'storage' | 'transport' | 'agents' | 'lowCode';
6
+ declare const CONTRACT_REVISION: "8083c90249a517982be7395a44c016ab08dcd047eb9b12231211e496c842120d";
7
+ type RuntimeSurfaceName = 'api' | 'storage' | 'transport' | 'vault' | 'agents' | 'lowCode';
7
8
 
8
9
  // AUTO-GENERATED FILE. DO NOT EDIT DIRECTLY.
9
10
  // Sources: api.swagger-contracts.generated.d.ts, api.public.d.ts
@@ -43,7 +44,7 @@ interface SwaggerAgentCheapTurnPolicyDto {
43
44
  }
44
45
  interface SwaggerAgentConfigDto {
45
46
  /** Supported assistant model used when the agent starts a thread. */
46
- "model"?: "gpt-6-sol" | "gpt-6-luna";
47
+ "model"?: "gpt-6.1-sol" | "gpt-6-luna";
47
48
  /** Reasoning effort passed to assistant threads. */
48
49
  "reasoningEffort"?: "none" | "low" | "medium" | "high" | "xhigh";
49
50
  /** Durable execution-mode default used for agent-loop turns. Per-turn fast-path routing and prompt-tier selection are derived by runtime, not configured here. */
@@ -587,6 +588,10 @@ interface SwaggerStorageTabularSchemaPolicyDto {
587
588
  /** How undeclared source columns are handled. allow retains them, strip omits them from structured rows, and reject fails indexing. Defaults to allow for fallback and reject for strict. The raw file is preserved. */
588
589
  "additionalProperties"?: "allow" | "strip" | "reject";
589
590
  }
591
+ interface SwaggerWebhookMapPatchDto {
592
+ "set"?: Record<string, string>;
593
+ "remove"?: Array<string>;
594
+ }
590
595
  interface SwaggerWebhookRequestDetailsDto {
591
596
  "url": string;
592
597
  "method": "POST" | "GET" | "HEAD" | "PUT" | "DELETE" | "PATCH" | "OPTIONS";
@@ -595,6 +600,16 @@ interface SwaggerWebhookRequestDetailsDto {
595
600
  /** Headers. */
596
601
  "headers"?: Record<string, unknown>;
597
602
  }
603
+ interface SwaggerWebhookRequestPatchDto {
604
+ "url"?: string;
605
+ "method"?: "POST" | "GET" | "HEAD" | "PUT" | "DELETE" | "PATCH" | "OPTIONS";
606
+ "headers"?: SwaggerWebhookMapPatchDto;
607
+ "query"?: SwaggerWebhookMapPatchDto;
608
+ /** Additional request paths to mask in the new attempt. Existing masks are always preserved. */
609
+ "maskDetails"?: Array<string>;
610
+ /** Explicit replacement of the whole body. Omitted body reuses the saved body. */
611
+ "body"?: Record<string, unknown> | Array<unknown>;
612
+ }
598
613
  interface AgentRunCancelInput {
599
614
  /** Optional cancellation reason for audit traces. */
600
615
  "reason"?: string;
@@ -694,9 +709,9 @@ interface AssistantMessageInput {
694
709
  "content": string;
695
710
  /** Optional hidden draft user message id created before attachment uploads. When provided, the send operation finalizes that draft instead of creating a new user message. */
696
711
  "preflightMessageId"?: string;
697
- /** Optional assistant execution-model override. GPT-6 Luna is the default; GPT-6 Sol and Luna are supported. */
698
- "model"?: "gpt-6-sol" | "gpt-6-luna";
699
- /** Optional GPT-6 Sol or Luna Fast mode. Defaults to false and remains opt-in per thread. */
712
+ /** Optional assistant execution-model override. GPT-6 Luna is the default; GPT-6.1 Sol and GPT-6 Luna are supported. */
713
+ "model"?: "gpt-6.1-sol" | "gpt-6-luna";
714
+ /** Optional GPT-6 Luna Fast mode. Defaults to false and remains opt-in per thread. */
700
715
  "fastMode"?: boolean;
701
716
  /** Optional assistant reasoning effort override: none, low, medium, high, or xhigh. Defaults to medium. */
702
717
  "reasoningEffort"?: "none" | "low" | "medium" | "high" | "xhigh";
@@ -815,6 +830,13 @@ interface AssistantForkMessageInput {
815
830
  /** Optional explicit title for the forked thread. When omitted, orchestration will generate the new thread title. */
816
831
  "title"?: string;
817
832
  }
833
+ interface JobsBulkInput {
834
+ /** Existing platform filter tree. Exactly one of filter and resource IDs is required. */
835
+ "filter"?: Record<string, unknown>;
836
+ /** Caller-generated key: repeated admission returns the same operation. Maximum 200 characters. */
837
+ "idempotencyKey"?: string;
838
+ "jobIds"?: Array<string>;
839
+ }
818
840
  interface StorageEntryMoveInput {
819
841
  /** Destination parent folder id. Omit or pass null for root. */
820
842
  "parentStorageEntryId"?: string;
@@ -881,8 +903,8 @@ interface AssistantActionResolutionInput {
881
903
  /** Optional flag selecting deadline-bounded background provider recovery. On the SSE route it also allows the resumed turn to continue after client disconnect. Streamed action resolution defaults this to true. */
882
904
  "backgroundProcessing"?: boolean;
883
905
  /** Optional assistant model override for the resumed turn after this action is resolved. */
884
- "model"?: "gpt-6-sol" | "gpt-6-luna";
885
- /** Optional Fast-mode override for the resumed turn. Available on GPT-6 Sol and Luna. */
906
+ "model"?: "gpt-6.1-sol" | "gpt-6-luna";
907
+ /** Optional Fast-mode override for the resumed turn. Available only on GPT-6 Luna. */
886
908
  "fastMode"?: boolean;
887
909
  /** Optional assistant reasoning effort override for the resumed turn: none, low, medium, high, or xhigh. */
888
910
  "reasoningEffort"?: "none" | "low" | "medium" | "high" | "xhigh";
@@ -1022,6 +1044,8 @@ interface WebhookInput {
1022
1044
  "proxy"?: boolean;
1023
1045
  /** Save entire request. */
1024
1046
  "saveDetails"?: boolean;
1047
+ /** Stop delivery on a supported attempt status. Processing of delivery logs is asynchronous. */
1048
+ "stopOnStatuses"?: Array<"UNAUTHENTICATED">;
1025
1049
  /** Max attempts. */
1026
1050
  "maxAttempts"?: number;
1027
1051
  /** Provide data */
@@ -1033,6 +1057,25 @@ interface WebhookInput {
1033
1057
  /** Optional key/value metadata for grouping and querying webhooks. Values may use any JSON type. Maximum 16 KiB and 64 top-level keys. Top-level keys starting with "__" are reserved for backend use. */
1034
1058
  "metadata"?: Record<string, unknown> | null;
1035
1059
  }
1060
+ interface WebhooksBulkInput {
1061
+ /** Existing platform filter tree. Exactly one of filter and resource IDs is required. */
1062
+ "filter"?: Record<string, unknown>;
1063
+ /** Caller-generated key: repeated admission returns the same operation. Maximum 200 characters. */
1064
+ "idempotencyKey"?: string;
1065
+ "webhookIds"?: Array<string>;
1066
+ /** Only allowed for retry. Missing masked values must be supplied explicitly. */
1067
+ "requestPatch"?: SwaggerWebhookRequestPatchDto;
1068
+ }
1069
+ interface AutomationOperation {
1070
+ operationId: string;
1071
+ resource: 'jobs' | 'webhooks';
1072
+ action: 'cancel' | 'retry' | 'delete';
1073
+ status: 'PENDING' | 'PROCESSING' | 'FINISHED' | 'ERROR';
1074
+ total: number;
1075
+ processed: number;
1076
+ skipped: number;
1077
+ failed: number;
1078
+ }
1036
1079
  /**
1037
1080
  * Canonical public low-code API declarations shared by Monaco and local editors.
1038
1081
  * Lifecycle input DTOs are generated from Swagger in api.swagger-contracts.generated.d.ts.
@@ -1564,7 +1607,8 @@ interface LogInterface {
1564
1607
  }
1565
1608
  interface TemplateFormData {
1566
1609
  key: string;
1567
- value?: string;
1610
+ /** Numbers and booleans are sent as text. Read credentials explicitly with vault.get/getAccessToken. */
1611
+ value?: string | number | boolean;
1568
1612
  /** Storage entry to append as this multipart part. Use this instead of value for binary content. */
1569
1613
  storageEntryId?: string;
1570
1614
  /** Storage namespace for storageEntryId. Defaults to explorer. */
@@ -1617,18 +1661,22 @@ interface HttpRevoResponseScope {
1617
1661
  }
1618
1662
  interface HttpRequestInterface {
1619
1663
  url: string;
1664
+ /** Replaces complete `{name}` path segments with URL-encoded bound values. */
1665
+ pathParams?: Record<string, string>;
1620
1666
  method: 'POST' | 'PUT' | 'DELETE' | 'GET' | 'PATCH' | 'OPTIONS' | 'HEAD' | 'PURGE' | 'LINK' | 'UNLINK';
1621
1667
  timeout?: number;
1622
- /** Vault references are resolved only by the trusted HTTP sender, never in low-code. */
1623
- headers?: LooseObject<string | VaultBoundValue>;
1668
+ /** HTTP headers; use an explicitly awaited vault.get/getAccessToken result for credentials. */
1669
+ headers?: LooseObject<string>;
1624
1670
  params?: TemplateParameters[];
1671
+ /** Integration-owned payload. Credential values and provider echoes are caller-managed data. */
1625
1672
  data?: any;
1626
1673
  //@default: undefined
1627
1674
  formData?: TemplateFormData[];
1628
1675
  }
1629
1676
  interface TemplateParameters {
1630
1677
  key: string;
1631
- value: string | LooseObject<boolean | number | string>;
1678
+ /** Numbers and booleans are sent as text. Legacy plain maps retain '[object Object]' conversion; serialize structured queries explicitly. */
1679
+ value: string | number | boolean | LooseObject<boolean | number | string>;
1632
1680
  }
1633
1681
  interface ProcessLog {
1634
1682
  time: string;
@@ -2750,6 +2798,145 @@ interface AssistantThreadCompactionRequest {
2750
2798
  keepContext?: boolean;
2751
2799
  content?: string;
2752
2800
  }
2801
+ // ApiInterface
2802
+ /** Owner selection; omitted means instance. User scope uses the verified execution account. */
2803
+ interface SecretScopeOptions {
2804
+ scope?: 'instance' | 'user';
2805
+ }
2806
+ /** Null or omission selects NOW at write time. Numbers are Unix epoch milliseconds. */
2807
+ type SecretDate = string | Date | number | null;
2808
+ interface SecretRotateOptions extends SecretScopeOptions {
2809
+ validFrom?: SecretDate;
2810
+ }
2811
+ interface SecretGetOptions extends SecretRotateOptions {
2812
+ /** Exact validFrom timestamp. If both selectors are supplied they must agree. */
2813
+ version?: SecretDate;
2814
+ }
2815
+ interface SecretDeleteOptions extends SecretGetOptions {
2816
+ }
2817
+ interface SecretRevisionListOptions extends SecretScopeOptions {
2818
+ cursor?: string;
2819
+ limit?: number;
2820
+ }
2821
+ interface SecretProperties {
2822
+ category?: string | null;
2823
+ description?: string | null;
2824
+ /** Replacement JSON object, at most 16 KiB and 64 top-level keys. Backend keys are reserved. */
2825
+ metadata?: Record<string, unknown>;
2826
+ }
2827
+ interface SecretCreateInput extends SecretProperties {
2828
+ /** Nonempty text, at most 65,536 characters. */
2829
+ value: string;
2830
+ validFrom?: SecretDate;
2831
+ enabled?: boolean;
2832
+ }
2833
+ interface SecretRotateInput {
2834
+ value: string;
2835
+ }
2836
+ interface SecretUpdateInput extends SecretProperties {
2837
+ /** Parent metadata counter, distinct from a revision's timestamp version. */
2838
+ version: number;
2839
+ }
2840
+ /** Unified metadata-only parent. */
2841
+ interface Secret {
2842
+ name: string;
2843
+ scope: 'instance' | 'user';
2844
+ category: string | null;
2845
+ description: string | null;
2846
+ metadata: Record<string, unknown>;
2847
+ version: number;
2848
+ createdAt: string;
2849
+ updatedAt: string;
2850
+ }
2851
+ interface SecretRevision {
2852
+ name: string;
2853
+ scope: 'instance' | 'user';
2854
+ /** Stable version identity: the unique validFrom timestamp, normalized to ISO. */
2855
+ version: string;
2856
+ enabled: boolean;
2857
+ validFrom: string;
2858
+ createdAt: string;
2859
+ updatedAt: string;
2860
+ }
2861
+ interface SecretWithRevision extends Secret {
2862
+ revision: SecretRevision;
2863
+ }
2864
+ interface SecretValueRevision extends SecretRevision {
2865
+ value: Buffer;
2866
+ }
2867
+ interface SecretWithValue extends Secret {
2868
+ revision: SecretValueRevision;
2869
+ }
2870
+ interface SecretRevisionPage {
2871
+ items: SecretRevision[];
2872
+ nextCursor: string | null;
2873
+ }
2874
+ interface VaultIntegrationConfig {
2875
+ resourceUrl: string;
2876
+ scopes: string[];
2877
+ issuer?: string;
2878
+ clientId?: string;
2879
+ clientSecret?: string;
2880
+ tenantId?: string;
2881
+ metadataScopeAliases?: Record<string, string>;
2882
+ }
2883
+ interface VaultConnectIntegrationInput extends VaultIntegrationConfig {
2884
+ /** Null creates a definition; otherwise use its exact revision from getIntegrationMetadata. */
2885
+ expectedRevision: string | null;
2886
+ }
2887
+ interface VaultAccessToken {
2888
+ accessToken: string;
2889
+ expiresAt: string;
2890
+ tokenType: 'Bearer';
2891
+ }
2892
+ interface VaultIntegrationMetadata {
2893
+ name: string;
2894
+ scope: 'instance' | 'user';
2895
+ revision: string | null;
2896
+ resourceUrl: string;
2897
+ issuer: string;
2898
+ scopes: string[];
2899
+ tenantId: string | null;
2900
+ metadataScopeAliases: Record<string, string>;
2901
+ clientId: string | null;
2902
+ hasClientSecret: boolean;
2903
+ registrationMode: 'dynamic_public' | 'byo_public' | 'byo_confidential';
2904
+ authorizationEndpoint: string;
2905
+ registrationEndpoint: string | null;
2906
+ }
2907
+ interface VaultIntegrationDiscovery {
2908
+ issuers: string[];
2909
+ requiresIssuerSelection: boolean;
2910
+ supportedScopes: string[];
2911
+ issuer?: string;
2912
+ authorizationEndpoint?: string;
2913
+ registrationEndpoint?: string | null;
2914
+ registrationMode?: 'dynamic_public' | 'byo_public' | 'byo_confidential';
2915
+ requiresClientId?: boolean;
2916
+ redirectUri?: string;
2917
+ }
2918
+ interface VaultIntegrationConnectResult {
2919
+ name: string;
2920
+ scope: 'instance' | 'user';
2921
+ revision: string;
2922
+ authorizationUrl: string;
2923
+ }
2924
+ interface RevoVault$1 {
2925
+ get(name: string, options?: SecretGetOptions): Promise<SecretWithValue>;
2926
+ create(name: string, data: SecretCreateInput, options?: SecretScopeOptions): Promise<Secret | null>;
2927
+ update(name: string, data: SecretUpdateInput, options?: SecretScopeOptions): Promise<Secret | null>;
2928
+ delete(name: string, options?: SecretDeleteOptions): Promise<void | null>;
2929
+ rotate(name: string, data: SecretRotateInput, options?: SecretRotateOptions): Promise<SecretWithRevision | null>;
2930
+ listRevisions(name: string, options?: SecretRevisionListOptions): Promise<SecretRevisionPage>;
2931
+ getAccessToken(name: string, options?: SecretScopeOptions): Promise<VaultAccessToken>;
2932
+ getIntegrationMetadata(name: string, options?: SecretScopeOptions): Promise<VaultIntegrationMetadata>;
2933
+ discoverIntegration(name: string, data: VaultIntegrationConfig, options?: SecretScopeOptions): Promise<VaultIntegrationDiscovery>;
2934
+ connectIntegration(name: string, data: VaultConnectIntegrationInput, options?: SecretScopeOptions): Promise<VaultIntegrationConnectResult | null>;
2935
+ disconnectIntegration(name: string, options?: SecretScopeOptions): Promise<{
2936
+ name: string;
2937
+ disabled: boolean;
2938
+ } | null>;
2939
+ }
2753
2940
  interface RevoApi {
2754
2941
  createDatabase(data: DatabaseCreateInput): Promise<Database>;
2755
2942
  cloneDatabase<TAsync extends boolean = false>(name: string, options?: DatabaseCloneInput & {
@@ -2847,6 +3034,26 @@ interface RevoApi {
2847
3034
  triggerTarget(targetType: ExecutionTargetType, targetId: string, input?: Record<string, JsonValue>, options?: AutomationScheduleOptions): Promise<string>;
2848
3035
  triggerJob(templateIdOrName: string, templateInputs?: Record<string, JsonValue>, options?: AutomationScheduleOptions): Promise<string>;
2849
3036
  triggerWebhook(webhook: WebhookInput, options?: AutomationScheduleOptions): Promise<Webhook>;
3037
+ cancelJobs(input: JobsBulkInput): Promise<AutomationOperation>;
3038
+ retryJobs(input: JobsBulkInput): Promise<AutomationOperation>;
3039
+ deleteJobs(input: JobsBulkInput): Promise<AutomationOperation>;
3040
+ cancelWebhooks(input: WebhooksBulkInput): Promise<AutomationOperation>;
3041
+ retryWebhooks(input: WebhooksBulkInput): Promise<AutomationOperation>;
3042
+ deleteWebhooks(input: WebhooksBulkInput): Promise<AutomationOperation>;
3043
+ previewAutomationOperation(resource: 'jobs' | 'webhooks', action: 'cancel' | 'retry' | 'delete', input: JobsBulkInput | WebhooksBulkInput): Promise<{
3044
+ matched: number;
3045
+ eligible: number;
3046
+ }>;
3047
+ getAutomationOperation(operationId: string): Promise<AutomationOperation>;
3048
+ getAutomationOperationItems(operationId: string, after?: string): Promise<{
3049
+ data: Array<{
3050
+ resourceId: string;
3051
+ status: string;
3052
+ resultId: string | null;
3053
+ errorCode: string | null;
3054
+ }>;
3055
+ nextCursor: string | null;
3056
+ }>;
2850
3057
  httpCall(config: HttpRequestInterface, options: HttpRequestOptionsInterface & {
2851
3058
  responseType: 'storage';
2852
3059
  target: HttpStorageTargetRef;
@@ -3098,16 +3305,6 @@ interface RevoUtils {
3098
3305
  rsaSign(privateKey: string, payload: string, passphrase?: string): Promise<string>;
3099
3306
  rsaVerify(publicKey: string, payload: string, signature: string): Promise<boolean>;
3100
3307
  }
3101
- type VaultScope = 'instance' | 'user' | 'organization';
3102
- type VaultSource = 'secret' | 'integration';
3103
- type VaultBoundValue = Readonly<{
3104
- __revoBoundValue: 'vault-v1';
3105
- name: string;
3106
- scope: VaultScope;
3107
- source: VaultSource;
3108
- prefix: string;
3109
- suffix: string;
3110
- }>;
3111
3308
  /** Low-code byte payloads; REST JSON callers retain the base64 option. */
3112
3309
  /** Text arrays retain their existing joining rules; bytes are snapshotted before asynchronous upload. */
3113
3310
  type StorageBinaryPutObjectInput = Omit<StoragePutObjectInput, 'data'> & {
@@ -3135,6 +3332,15 @@ interface RevoLowCode {
3135
3332
  execute<T = LooseObject<any>>(code: string, options?: LowCodeExecuteOptions): Promise<ComponentExecuteResult<T>>;
3136
3333
  }
3137
3334
 
3335
+ type VaultReadResult = Awaited<ReturnType<RevoVault$1['get']>>;
3336
+ /** Wire decoding returns a full Node.js Buffer, extending the portable low-code type. */
3337
+ type RevoVault = Omit<RevoVault$1, 'get'> & {
3338
+ get(...args: Parameters<RevoVault$1['get']>): Promise<Omit<VaultReadResult, 'revision'> & {
3339
+ revision: Omit<VaultReadResult['revision'], 'value'> & {
3340
+ value: Buffer$1;
3341
+ };
3342
+ }>;
3343
+ };
3138
3344
  type RevoExecute = RevoLowCode['execute'];
3139
3345
  type RevoExecuteOptions = NonNullable<Parameters<RevoExecute>[1]>;
3140
3346
  type RevoExecutionDefaults = Omit<RevoExecuteOptions, 'inputs'>;
@@ -3222,6 +3428,7 @@ interface RevoRuntime {
3222
3428
  readonly api: RevoApi;
3223
3429
  readonly utils: RevoUtils;
3224
3430
  readonly storage: RevoStorage;
3431
+ readonly vault: RevoVault;
3225
3432
  readonly transport: RevoTransport;
3226
3433
  readonly agents: RevoAgents;
3227
3434
  readonly execute: RevoExecute;
@@ -3320,4 +3527,4 @@ declare class RevoHttpResponseError extends RevoError {
3320
3527
  constructor(statusCode: number, body?: unknown);
3321
3528
  }
3322
3529
 
3323
- export { RevoRuntimeContextUnavailableError as A, type BatchFailureMode as B, CONTRACT_REVISION as C, RevoTransportError as D, type RuntimeBatchRequest as E, type RuntimeBatchResponse as F, type RuntimeCall as G, type HostedRuntimeBootstrap as H, type RuntimeCallResult as I, type SerializedRevoError as J, PROTOCOL_VERSION as P, type RevoRuntime as R, SDK_VERSION as S, RevoExecutionExit as a, RevoHttpResponseError as b, type RevoRuntimeBridgeRequest as c, type RevoRuntimeBridgeResponse as d, type RevoRuntimeBridgeTransportError as e, type RevoStandaloneApi as f, type RevoUtils as g, type RevoStorage as h, type RevoTransport as i, type RevoAgents as j, type RevoExecute as k, type RevoBatchController as l, type RevoClientOptions as m, type RevoApi as n, RevoAuthenticationError as o, RevoBatchConfigurationError as p, RevoBatchLimitError as q, type RevoBatchLimits as r, type RevoBatchOptions as s, RevoConfigurationError as t, RevoError as u, type RevoExecuteOptions as v, type RevoExecutionDefaults as w, RevoPermissionDeniedError as x, RevoProtocolError as y, RevoRemoteError as z };
3530
+ export { RevoRemoteError as A, type BatchFailureMode as B, CONTRACT_REVISION as C, RevoRuntimeContextUnavailableError as D, RevoTransportError as E, type RuntimeBatchRequest as F, type RuntimeBatchResponse as G, type HostedRuntimeBootstrap as H, type RuntimeCall as I, type RuntimeCallResult as J, type SerializedRevoError as K, PROTOCOL_VERSION as P, type RevoRuntime as R, SDK_VERSION as S, RevoExecutionExit as a, RevoHttpResponseError as b, type RevoRuntimeBridgeRequest as c, type RevoRuntimeBridgeResponse as d, type RevoRuntimeBridgeTransportError as e, type RevoStandaloneApi as f, type RevoUtils as g, type RevoStorage as h, type RevoVault as i, type RevoTransport as j, type RevoAgents as k, type RevoExecute as l, type RevoBatchController as m, type RevoClientOptions as n, type RevoApi as o, RevoAuthenticationError as p, RevoBatchConfigurationError as q, RevoBatchLimitError as r, type RevoBatchLimits as s, type RevoBatchOptions as t, RevoConfigurationError as u, RevoError as v, type RevoExecuteOptions as w, type RevoExecutionDefaults as x, RevoPermissionDeniedError as y, RevoProtocolError as z };