@squidcloud/client 1.0.80 → 1.0.82

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.
Files changed (102) hide show
  1. package/dist/cjs/index.js +5 -5
  2. package/dist/common/src/ai-assistant.context.d.ts +12 -12
  3. package/dist/common/src/ai-assistant.schemas.d.ts +1 -1
  4. package/dist/common/src/ai-assistant.types.d.ts +2 -2
  5. package/dist/common/src/api-call.context.d.ts +13 -13
  6. package/dist/common/src/api.types.d.ts +4 -4
  7. package/dist/common/src/application.schemas.d.ts +1 -1
  8. package/dist/common/src/application.types.d.ts +184 -184
  9. package/dist/common/src/backend-function.schemas.d.ts +1 -1
  10. package/dist/common/src/backend-function.types.d.ts +1 -1
  11. package/dist/common/src/backend-run.types.d.ts +2 -2
  12. package/dist/common/src/bundle-api.types.d.ts +36 -36
  13. package/dist/common/src/bundle-data.types.d.ts +4 -4
  14. package/dist/common/src/communication.types.d.ts +12 -12
  15. package/dist/common/src/context.types.d.ts +40 -40
  16. package/dist/common/src/distributed-lock.context.d.ts +5 -5
  17. package/dist/common/src/document.types.d.ts +22 -22
  18. package/dist/common/src/graphql.context.d.ts +7 -7
  19. package/dist/common/src/graphql.types.d.ts +9 -9
  20. package/dist/common/src/heartbeat.types.d.ts +1 -1
  21. package/dist/common/src/http-status.enum.d.ts +50 -50
  22. package/dist/common/src/index.d.ts +54 -54
  23. package/dist/common/src/integrations/ai_assistant.types.d.ts +30 -30
  24. package/dist/common/src/integrations/api.types.d.ts +80 -80
  25. package/dist/common/src/integrations/auth.types.d.ts +39 -39
  26. package/dist/common/src/integrations/database.types.d.ts +236 -236
  27. package/dist/common/src/integrations/index.d.ts +101 -101
  28. package/dist/common/src/integrations/observability.types.d.ts +23 -23
  29. package/dist/common/src/logger.types.d.ts +21 -21
  30. package/dist/common/src/metrics.types.d.ts +1 -1
  31. package/dist/common/src/mutation.context.d.ts +14 -14
  32. package/dist/common/src/mutation.schemas.d.ts +1 -1
  33. package/dist/common/src/mutation.types.d.ts +53 -53
  34. package/dist/common/src/named-query.context.d.ts +4 -4
  35. package/dist/common/src/named-query.schemas.d.ts +1 -1
  36. package/dist/common/src/named-query.types.d.ts +1 -1
  37. package/dist/common/src/query/{simple-query-builder.d.ts → base-query-builder.d.ts} +122 -117
  38. package/dist/common/src/query/index.d.ts +2 -2
  39. package/dist/common/src/query/query-context.d.ts +109 -109
  40. package/dist/common/src/query.schemas.d.ts +3 -3
  41. package/dist/common/src/query.types.d.ts +57 -57
  42. package/dist/common/src/regions.d.ts +1 -1
  43. package/dist/common/src/schema/schema.types.d.ts +54 -54
  44. package/dist/common/src/secret.schemas.d.ts +1 -1
  45. package/dist/common/src/secret.types.d.ts +8 -8
  46. package/dist/common/src/security.types.d.ts +1 -1
  47. package/dist/common/src/socket.schemas.d.ts +1 -1
  48. package/dist/common/src/socket.types.d.ts +1 -1
  49. package/dist/common/src/time-units.d.ts +1 -1
  50. package/dist/common/src/trigger.types.d.ts +1 -1
  51. package/dist/common/src/types.d.ts +8 -8
  52. package/dist/common/src/utils/array.d.ts +1 -1
  53. package/dist/common/src/utils/assert.d.ts +1 -1
  54. package/dist/common/src/utils/error.d.ts +4 -4
  55. package/dist/common/src/utils/http.d.ts +2 -2
  56. package/dist/common/src/utils/id.d.ts +2 -2
  57. package/dist/common/src/utils/lock.manager.d.ts +14 -14
  58. package/dist/common/src/utils/nullish.d.ts +1 -1
  59. package/dist/common/src/utils/object.d.ts +6 -6
  60. package/dist/common/src/utils/serialization.d.ts +6 -6
  61. package/dist/common/src/utils/transforms.d.ts +18 -18
  62. package/dist/common/src/utils/url.d.ts +1 -1
  63. package/dist/common/src/utils/validation.d.ts +30 -30
  64. package/dist/common/src/webhook-response.d.ts +1 -1
  65. package/dist/esm/index.js +5 -5
  66. package/dist/node_modules/json-schema-typed/draft-2020-12.d.ts +1239 -1239
  67. package/dist/typescript-client/src/ai-assistant-client.d.ts +167 -167
  68. package/dist/typescript-client/src/ai-client.factory.d.ts +11 -11
  69. package/dist/typescript-client/src/api.manager.d.ts +15 -15
  70. package/dist/typescript-client/src/auth.manager.d.ts +23 -23
  71. package/dist/typescript-client/src/backend-function.manager.d.ts +13 -13
  72. package/dist/typescript-client/src/client-id.service.d.ts +25 -25
  73. package/dist/typescript-client/src/collection-reference.d.ts +82 -80
  74. package/dist/typescript-client/src/collection-reference.factory.d.ts +13 -13
  75. package/dist/typescript-client/src/connection-details.d.ts +23 -23
  76. package/dist/typescript-client/src/data.manager.d.ts +172 -172
  77. package/dist/typescript-client/src/destruct.manager.d.ts +12 -12
  78. package/dist/typescript-client/src/distributed-lock.manager.d.ts +19 -19
  79. package/dist/typescript-client/src/document-identity.service.d.ts +12 -12
  80. package/dist/typescript-client/src/document-reference.d.ts +134 -134
  81. package/dist/typescript-client/src/document-reference.factory.d.ts +12 -12
  82. package/dist/typescript-client/src/document-store.d.ts +11 -11
  83. package/dist/typescript-client/src/graphql-client.d.ts +12 -12
  84. package/dist/typescript-client/src/graphql-client.factory.d.ts +9 -9
  85. package/dist/typescript-client/src/index.d.ts +8 -8
  86. package/dist/typescript-client/src/mutation/mutation-sender.d.ts +10 -10
  87. package/dist/typescript-client/src/named-query.manager.d.ts +12 -12
  88. package/dist/typescript-client/src/query/join-query-builder.factory.d.ts +110 -72
  89. package/dist/typescript-client/src/query/query-builder.factory.d.ts +64 -89
  90. package/dist/typescript-client/src/query/query-subscription.manager.d.ts +135 -135
  91. package/dist/typescript-client/src/query/query.types.d.ts +14 -14
  92. package/dist/typescript-client/src/rpc.manager.d.ts +28 -28
  93. package/dist/typescript-client/src/socket.manager.d.ts +32 -32
  94. package/dist/typescript-client/src/squid.d.ts +217 -218
  95. package/dist/typescript-client/src/state/action.applier.d.ts +7 -7
  96. package/dist/typescript-client/src/state/actions.d.ts +29 -29
  97. package/dist/typescript-client/src/state/path_trie.d.ts +27 -27
  98. package/dist/typescript-client/src/state/state.service.d.ts +22 -22
  99. package/dist/typescript-client/src/state/state.service.spec.d.ts +1 -1
  100. package/dist/typescript-client/src/testing/setup-tests.d.ts +1 -1
  101. package/dist/typescript-client/src/types.d.ts +2 -2
  102. package/package.json +1 -1
@@ -1,29 +1,29 @@
1
- import { StateLeafNode } from './action.applier';
2
- export declare enum ActionType {
3
- DELETE_PATH = "DELETE_PATH",
4
- SET_PATH = "SET_PATH",
5
- BATCH_ACTION = "BATCH_ACTION"
6
- }
7
- export declare interface BaseAction {
8
- type: ActionType;
9
- }
10
- export declare interface PathAction extends BaseAction {
11
- path: string[];
12
- }
13
- export type DeletePathAction = PathAction;
14
- export declare interface SetPathAction extends PathAction {
15
- payload?: StateLeafNode;
16
- }
17
- export declare interface BatchAction extends BaseAction {
18
- payload: BaseAction[];
19
- }
20
- export declare interface StateMessage {
21
- type: 'ACTIONS';
22
- payload: BaseAction[];
23
- }
24
- export declare function isPathAction(action: BaseAction): action is PathAction;
25
- export declare function isSetPathAction(action: BaseAction): action is SetPathAction;
26
- export declare function isDeletePathAction(action: BaseAction): action is DeletePathAction;
27
- export declare function isBatchAction(action: BaseAction): action is BatchAction;
28
- export declare function extractAllPathActions(action: BaseAction): PathAction[];
29
- export declare function getSingleAction(actions: BaseAction[]): BaseAction;
1
+ import { StateLeafNode } from './action.applier';
2
+ export declare enum ActionType {
3
+ DELETE_PATH = "DELETE_PATH",
4
+ SET_PATH = "SET_PATH",
5
+ BATCH_ACTION = "BATCH_ACTION"
6
+ }
7
+ export declare interface BaseAction {
8
+ type: ActionType;
9
+ }
10
+ export declare interface PathAction extends BaseAction {
11
+ path: string[];
12
+ }
13
+ export type DeletePathAction = PathAction;
14
+ export declare interface SetPathAction extends PathAction {
15
+ payload?: StateLeafNode;
16
+ }
17
+ export declare interface BatchAction extends BaseAction {
18
+ payload: BaseAction[];
19
+ }
20
+ export declare interface StateMessage {
21
+ type: 'ACTIONS';
22
+ payload: BaseAction[];
23
+ }
24
+ export declare function isPathAction(action: BaseAction): action is PathAction;
25
+ export declare function isSetPathAction(action: BaseAction): action is SetPathAction;
26
+ export declare function isDeletePathAction(action: BaseAction): action is DeletePathAction;
27
+ export declare function isBatchAction(action: BaseAction): action is BatchAction;
28
+ export declare function extractAllPathActions(action: BaseAction): PathAction[];
29
+ export declare function getSingleAction(actions: BaseAction[]): BaseAction;
@@ -1,27 +1,27 @@
1
- import { BaseAction } from './actions';
2
- export declare class PathTrie<T> {
3
- private root;
4
- getOrCreatePathTrieNode(path: string[], nodeData?: T): PathTrieNode<T>;
5
- getPathTrieNode(path: string[]): PathTrieNode<T> | undefined;
6
- getPathTrie(path: string[]): PathTrie<T> | undefined;
7
- /**
8
- * If the callback returns false, it will not iterate into the children of the current node.
9
- */
10
- iterateBfs(callback: (data: T, path: string[]) => void | boolean): void;
11
- removeNode(path: string[]): void;
12
- clearNodeData(path: string[]): void;
13
- getNodeList(path: string[]): Array<PathTrieNode<T>>;
14
- private iterateInternal;
15
- }
16
- export declare class PathTrieNode<T> {
17
- children: Map<string, PathTrieNode<T>>;
18
- nodeData: T | undefined;
19
- }
20
- /**
21
- * Returns a trie which contains all the paths affected by the action. For
22
- * example, if the action contains a path action applied on path [A, B, C], then
23
- * [A], [A, B], [A, B, C] will be in the returned trie. Moreover, if
24
- * subscriptionTree is provided and contains [A, B, C, ...], then [A, B, C, ...]
25
- * will also be included in the returned trie.
26
- */
27
- export declare function getPathTrieFromAction(action: BaseAction, subscriptionTree?: PathTrie<{}>): PathTrie<boolean>;
1
+ import { BaseAction } from './actions';
2
+ export declare class PathTrie<T> {
3
+ private root;
4
+ getOrCreatePathTrieNode(path: string[], nodeData?: T): PathTrieNode<T>;
5
+ getPathTrieNode(path: string[]): PathTrieNode<T> | undefined;
6
+ getPathTrie(path: string[]): PathTrie<T> | undefined;
7
+ /**
8
+ * If the callback returns false, it will not iterate into the children of the current node.
9
+ */
10
+ iterateBfs(callback: (data: T, path: string[]) => void | boolean): void;
11
+ removeNode(path: string[]): void;
12
+ clearNodeData(path: string[]): void;
13
+ getNodeList(path: string[]): Array<PathTrieNode<T>>;
14
+ private iterateInternal;
15
+ }
16
+ export declare class PathTrieNode<T> {
17
+ children: Map<string, PathTrieNode<T>>;
18
+ nodeData: T | undefined;
19
+ }
20
+ /**
21
+ * Returns a trie which contains all the paths affected by the action. For
22
+ * example, if the action contains a path action applied on path [A, B, C], then
23
+ * [A], [A, B], [A, B, C] will be in the returned trie. Moreover, if
24
+ * subscriptionTree is provided and contains [A, B, C, ...], then [A, B, C, ...]
25
+ * will also be included in the returned trie.
26
+ */
27
+ export declare function getPathTrieFromAction(action: BaseAction, subscriptionTree?: PathTrie<{}>): PathTrie<boolean>;
@@ -1,22 +1,22 @@
1
- import { Observable } from 'rxjs';
2
- import { State, StateLeafNode } from './action.applier';
3
- import { BaseAction } from './actions';
4
- export declare class StateService {
5
- private readonly subscriptionsTree;
6
- private state;
7
- private batchCount;
8
- private readonly batchedActions;
9
- dispatch(action: BaseAction): void;
10
- runInBatch(fn: () => unknown): void;
11
- observePath<T>(path: string[], pathsToExcludeFn?: () => Array<string[]>): Observable<T>;
12
- setKeyInPath<T extends State>(path: string[], key: keyof T & string, value: T[keyof T] & StateLeafNode, noopIfSame?: boolean): void;
13
- setPartial<T extends State>(path: string[], partialState: Partial<T>, noopIfSame?: boolean): void;
14
- setInPath(path: string[], payload: StateLeafNode, noopIfSame?: boolean): void;
15
- pushToArray(path: string[], payload: StateLeafNode): void;
16
- deletePath(path: string[]): void;
17
- getState(): State;
18
- getStateInPath<T extends StateLeafNode>(path: string[]): T;
19
- destroy(): void;
20
- private getOrCreateSubjectForPath;
21
- private dispatchSubscriptions;
22
- }
1
+ import { Observable } from 'rxjs';
2
+ import { State, StateLeafNode } from './action.applier';
3
+ import { BaseAction } from './actions';
4
+ export declare class StateService {
5
+ private readonly subscriptionsTree;
6
+ private state;
7
+ private batchCount;
8
+ private readonly batchedActions;
9
+ dispatch(action: BaseAction): void;
10
+ runInBatch(fn: () => unknown): void;
11
+ observePath<T>(path: string[], pathsToExcludeFn?: () => Array<string[]>): Observable<T>;
12
+ setKeyInPath<T extends State>(path: string[], key: keyof T & string, value: T[keyof T] & StateLeafNode, noopIfSame?: boolean): void;
13
+ setPartial<T extends State>(path: string[], partialState: Partial<T>, noopIfSame?: boolean): void;
14
+ setInPath(path: string[], payload: StateLeafNode, noopIfSame?: boolean): void;
15
+ pushToArray(path: string[], payload: StateLeafNode): void;
16
+ deletePath(path: string[]): void;
17
+ getState(): State;
18
+ getStateInPath<T extends StateLeafNode>(path: string[]): T;
19
+ destroy(): void;
20
+ private getOrCreateSubjectForPath;
21
+ private dispatchSubscriptions;
22
+ }
@@ -1 +1 @@
1
- export {};
1
+ export {};
@@ -1 +1 @@
1
- declare const nodeCrypto: any;
1
+ declare const nodeCrypto: any;
@@ -1,2 +1,2 @@
1
- /** A transactionId - alias for string */
2
- export type TransactionId = string;
1
+ /** A transactionId - alias for string */
2
+ export type TransactionId = string;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@squidcloud/client",
3
- "version": "1.0.80",
3
+ "version": "1.0.82",
4
4
  "description": "A typescript implementation of the Squid client",
5
5
  "main": "dist/cjs/index.js",
6
6
  "module": "dist/esm/index.js",