@flashbacktech/tsclient 0.4.69 → 0.4.71

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/dist/index.d.cts CHANGED
@@ -939,6 +939,16 @@ declare class CredentialsClient {
939
939
  */
940
940
  createOrgNotify(body: Omit<CreateCredentialRequest, 'projectId' | 'workspaceId'>): Promise<Credential>;
941
941
  deleteOrgNotify(credentialId: string): Promise<SimpleKeysResponse>;
942
+ /**
943
+ * adminDeliver seeds a credential into ANOTHER org's project — the
944
+ * platform-admin delivery path for eval-sandbox credentials. The caller
945
+ * must be a platform admin; the target org comes from the path (no
946
+ * impersonation involved) and the audit event lands in the target org's
947
+ * trail. The server accepts cloud (storage-capable) providers only.
948
+ * Optional `metadata.expiresAt` (RFC3339) marks a time-bound credential
949
+ * so the tenant UI can badge the upcoming sandbox expiry.
950
+ */
951
+ adminDeliver(orgId: string, body: CreateCredentialRequest): Promise<Credential>;
942
952
  /**
943
953
  * providers fetches the server-side catalog. The tsclient ships its
944
954
  * own catalog mirror in ./providers.ts that the frontend can use
@@ -1056,6 +1066,14 @@ interface ListChatSessionsQuery {
1056
1066
  interface GetChatSessionResponse {
1057
1067
  session: ChatSession;
1058
1068
  messages: ChatMessage[];
1069
+ /**
1070
+ * Action categories the user has sticky-allowed for the rest of this chat
1071
+ * session (the ConfirmationCard "Allow for session" opt-in). Held in
1072
+ * engine memory, so this re-hydrates the dashboard's guardrail chips after
1073
+ * a reload while the engine process is alive; `null` (or omitted) when
1074
+ * there are none or after an engine restart.
1075
+ */
1076
+ session_allows?: ActionCategory[] | null;
1059
1077
  }
1060
1078
  interface PostChatMessageRequest {
1061
1079
  text: string;
package/dist/index.d.ts CHANGED
@@ -939,6 +939,16 @@ declare class CredentialsClient {
939
939
  */
940
940
  createOrgNotify(body: Omit<CreateCredentialRequest, 'projectId' | 'workspaceId'>): Promise<Credential>;
941
941
  deleteOrgNotify(credentialId: string): Promise<SimpleKeysResponse>;
942
+ /**
943
+ * adminDeliver seeds a credential into ANOTHER org's project — the
944
+ * platform-admin delivery path for eval-sandbox credentials. The caller
945
+ * must be a platform admin; the target org comes from the path (no
946
+ * impersonation involved) and the audit event lands in the target org's
947
+ * trail. The server accepts cloud (storage-capable) providers only.
948
+ * Optional `metadata.expiresAt` (RFC3339) marks a time-bound credential
949
+ * so the tenant UI can badge the upcoming sandbox expiry.
950
+ */
951
+ adminDeliver(orgId: string, body: CreateCredentialRequest): Promise<Credential>;
942
952
  /**
943
953
  * providers fetches the server-side catalog. The tsclient ships its
944
954
  * own catalog mirror in ./providers.ts that the frontend can use
@@ -1056,6 +1066,14 @@ interface ListChatSessionsQuery {
1056
1066
  interface GetChatSessionResponse {
1057
1067
  session: ChatSession;
1058
1068
  messages: ChatMessage[];
1069
+ /**
1070
+ * Action categories the user has sticky-allowed for the rest of this chat
1071
+ * session (the ConfirmationCard "Allow for session" opt-in). Held in
1072
+ * engine memory, so this re-hydrates the dashboard's guardrail chips after
1073
+ * a reload while the engine process is alive; `null` (or omitted) when
1074
+ * there are none or after an engine restart.
1075
+ */
1076
+ session_allows?: ActionCategory[] | null;
1059
1077
  }
1060
1078
  interface PostChatMessageRequest {
1061
1079
  text: string;
package/dist/index.js CHANGED
@@ -730,6 +730,24 @@ var CredentialsClient = class {
730
730
  deleteOrgNotify(credentialId) {
731
731
  return this.http.delete(`/credentials/org-notify/${credentialId}`);
732
732
  }
733
+ /**
734
+ * adminDeliver seeds a credential into ANOTHER org's project — the
735
+ * platform-admin delivery path for eval-sandbox credentials. The caller
736
+ * must be a platform admin; the target org comes from the path (no
737
+ * impersonation involved) and the audit event lands in the target org's
738
+ * trail. The server accepts cloud (storage-capable) providers only.
739
+ * Optional `metadata.expiresAt` (RFC3339) marks a time-bound credential
740
+ * so the tenant UI can badge the upcoming sandbox expiry.
741
+ */
742
+ async adminDeliver(orgId, body) {
743
+ const res = await this.http.post(
744
+ `/admin/orgs/${orgId}/credentials`,
745
+ { body }
746
+ );
747
+ const value = res.data ?? res.credential;
748
+ if (!value) throw new Error("adminDeliver response missing body.");
749
+ return value;
750
+ }
733
751
  /**
734
752
  * providers fetches the server-side catalog. The tsclient ships its
735
753
  * own catalog mirror in ./providers.ts that the frontend can use