@byted-apaas/server-sdk-node 1.0.17 → 1.1.0

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 (163) hide show
  1. package/README.md +7 -0
  2. package/application/application.d.ts +9 -7
  3. package/application/application.js +1 -0
  4. package/application/application.js.map +1 -0
  5. package/application/function/function.d.ts +1 -1
  6. package/application/function/function.js +1 -1
  7. package/application/function/function.js.map +1 -0
  8. package/application/impl/common.d.ts +1 -1
  9. package/application/impl/common.js +14 -12
  10. package/application/impl/common.js.map +1 -0
  11. package/application/impl/impl.d.ts +8 -6
  12. package/application/impl/impl.js +7 -4
  13. package/application/impl/impl.js.map +1 -0
  14. package/constants/constants.js +5 -4
  15. package/constants/constants.js.map +1 -0
  16. package/context/context.d.ts +2 -71
  17. package/context/context.js +1 -16
  18. package/context/context.js.map +1 -0
  19. package/context/db/db.d.ts +11 -19
  20. package/context/db/db.js +1 -0
  21. package/context/db/db.js.map +1 -0
  22. package/context/db/impl/IObject.d.ts +37 -37
  23. package/context/db/impl/IObject.js +1 -0
  24. package/context/db/impl/IObject.js.map +1 -0
  25. package/context/db/impl/db.d.ts +9 -9
  26. package/context/db/impl/db.js +7 -6
  27. package/context/db/impl/db.js.map +1 -0
  28. package/context/db/impl/object.js +48 -47
  29. package/context/db/impl/object.js.map +1 -0
  30. package/context/db/impl/oql/ioql.js +1 -0
  31. package/context/db/impl/oql/ioql.js.map +1 -0
  32. package/context/db/impl/oql/oql.d.ts +1 -1
  33. package/context/db/impl/oql/oql.js +1 -0
  34. package/context/db/impl/oql/oql.js.map +1 -0
  35. package/context/db/impl/order.js +2 -1
  36. package/context/db/impl/order.js.map +1 -0
  37. package/context/db/impl/propertiesStore.js +2 -1
  38. package/context/db/impl/propertiesStore.js.map +1 -0
  39. package/context/db/impl/queryBuilder.js +1 -0
  40. package/context/db/impl/queryBuilder.js.map +1 -0
  41. package/context/db/impl/transaction/index.d.ts +1 -1
  42. package/context/db/impl/transaction/index.js +47 -45
  43. package/context/db/impl/transaction/index.js.map +1 -0
  44. package/context/db/impl/transaction/operation.js +1 -0
  45. package/context/db/impl/transaction/operation.js.map +1 -0
  46. package/context/db/impl/transaction.d.ts +0 -5
  47. package/context/db/impl/transaction.js +1 -0
  48. package/context/db/impl/transaction.js.map +1 -0
  49. package/context/globalConfig/globalConfig.js +1 -0
  50. package/context/globalConfig/globalConfig.js.map +1 -0
  51. package/context/integration/IIntegration.d.ts +30 -0
  52. package/context/integration/IIntegration.js +5 -0
  53. package/context/integration/IIntegration.js.map +1 -0
  54. package/context/integration/impl/integration.d.ts +16 -0
  55. package/context/integration/impl/integration.js +63 -0
  56. package/context/integration/impl/integration.js.map +1 -0
  57. package/context/metadata/components/common.js +4 -3
  58. package/context/metadata/components/common.js.map +1 -0
  59. package/context/metadata/components/components.d.ts +4 -4
  60. package/context/metadata/components/components.js +1 -0
  61. package/context/metadata/components/components.js.map +1 -0
  62. package/context/metadata/components/desktop/list.d.ts +3 -3
  63. package/context/metadata/components/desktop/list.js +24 -23
  64. package/context/metadata/components/desktop/list.js.map +1 -0
  65. package/context/metadata/components/desktop/recordDetail.d.ts +2 -2
  66. package/context/metadata/components/desktop/recordDetail.js +1 -0
  67. package/context/metadata/components/desktop/recordDetail.js.map +1 -0
  68. package/context/metadata/components/mobile/list.d.ts +4 -4
  69. package/context/metadata/components/mobile/list.js +2 -1
  70. package/context/metadata/components/mobile/list.js.map +1 -0
  71. package/context/metadata/metadata.d.ts +5 -6
  72. package/context/metadata/metadata.js +6 -6
  73. package/context/metadata/metadata.js.map +1 -0
  74. package/context/metadata/objects/fields.d.ts +6 -6
  75. package/context/metadata/objects/fields.js +58 -57
  76. package/context/metadata/objects/fields.js.map +1 -0
  77. package/context/metadata/objects/fields.util.d.ts +3 -3
  78. package/context/metadata/objects/fields.util.js +22 -21
  79. package/context/metadata/objects/fields.util.js.map +1 -0
  80. package/context/metadata/objects/objects.d.ts +1 -1
  81. package/context/metadata/objects/objects.js +2 -1
  82. package/context/metadata/objects/objects.js.map +1 -0
  83. package/context/metadata/types/common.js +1 -0
  84. package/context/metadata/types/common.js.map +1 -0
  85. package/context/metadata/types/components.d.ts +5 -5
  86. package/context/metadata/types/components.js +1 -0
  87. package/context/metadata/types/components.js.map +1 -0
  88. package/context/metadata/types/objects.d.ts +88 -88
  89. package/context/metadata/types/objects.js +1 -0
  90. package/context/metadata/types/objects.js.map +1 -0
  91. package/context/msg/msg.d.ts +2 -2
  92. package/context/msg/msg.js +1 -0
  93. package/context/msg/msg.js.map +1 -0
  94. package/context/resources/IResources.d.ts +2 -2
  95. package/context/resources/IResources.js +1 -0
  96. package/context/resources/IResources.js.map +1 -0
  97. package/context/resources/impl/resources.d.ts +4 -4
  98. package/context/resources/impl/resources.js +4 -3
  99. package/context/resources/impl/resources.js.map +1 -0
  100. package/context/tasks/tasks.d.ts +3 -3
  101. package/context/tasks/tasks.js +6 -5
  102. package/context/tasks/tasks.js.map +1 -0
  103. package/data/index.d.ts +2 -2
  104. package/data/index.js +1 -0
  105. package/data/index.js.map +1 -0
  106. package/global/application/flow/flow.d.ts +85 -0
  107. package/global/application/flow/flow.js +3 -0
  108. package/global/application/flow/flow.js.map +1 -0
  109. package/global/global.d.ts +88 -0
  110. package/global/global.js +4 -0
  111. package/global/global.js.map +1 -0
  112. package/hooks/api.d.ts +12 -7
  113. package/hooks/api.js +29 -23
  114. package/hooks/api.js.map +1 -0
  115. package/hooks/hooks.js +42 -0
  116. package/hooks/hooks.js.map +1 -0
  117. package/kunlun/kunlun.d.ts +5 -5
  118. package/kunlun/kunlun.js +1 -0
  119. package/kunlun/kunlun.js.map +1 -0
  120. package/kunlun/operator/IOperator.d.ts +16 -16
  121. package/kunlun/operator/IOperator.js +1 -0
  122. package/kunlun/operator/IOperator.js.map +1 -0
  123. package/kunlun/operator/impl/expression.d.ts +2 -2
  124. package/kunlun/operator/impl/expression.js +6 -5
  125. package/kunlun/operator/impl/expression.js.map +1 -0
  126. package/kunlun/operator/impl/logic.js +49 -31
  127. package/kunlun/operator/impl/logic.js.map +1 -0
  128. package/kunlun/operator/impl/logicV2.d.ts +2 -2
  129. package/kunlun/operator/impl/logicV2.js +13 -13
  130. package/kunlun/operator/impl/logicV2.js.map +1 -0
  131. package/kunlun/operator/impl/operator.d.ts +17 -17
  132. package/kunlun/operator/impl/operator.js +39 -38
  133. package/kunlun/operator/impl/operator.js.map +1 -0
  134. package/kunlun/operator/impl/operatorV2.d.ts +17 -17
  135. package/kunlun/operator/impl/operatorV2.js +39 -38
  136. package/kunlun/operator/impl/operatorV2.js.map +1 -0
  137. package/lib/core.d.ts +3 -3
  138. package/lib/core.js +1 -0
  139. package/lib/core.js.map +1 -0
  140. package/log/app.access.log +0 -0
  141. package/log/app.call.log +0 -0
  142. package/log/app.log +0 -0
  143. package/package.json +2 -2
  144. package/request/common.d.ts +1 -1
  145. package/request/common.js +5 -3
  146. package/request/common.js.map +1 -0
  147. package/request/constants.d.ts +1 -1
  148. package/request/constants.js +7 -6
  149. package/request/constants.js.map +1 -0
  150. package/request/faasinfra.d.ts +1 -1
  151. package/request/faasinfra.js +42 -251
  152. package/request/faasinfra.js.map +1 -0
  153. package/request/innerapi.d.ts +12 -8
  154. package/request/innerapi.js +173 -57
  155. package/request/innerapi.js.map +1 -0
  156. package/request/interface.d.ts +68 -54
  157. package/request/interface.js +9 -9
  158. package/request/interface.js.map +1 -0
  159. package/request/openapi.d.ts +12 -8
  160. package/request/openapi.js +215 -149
  161. package/request/openapi.js.map +1 -0
  162. package/types/types.js +1 -0
  163. package/types/types.js.map +1 -0
@@ -1,10 +1,10 @@
1
1
  /// <reference types="node" />
2
2
  /// <reference types="node" />
3
- import { Criterion } from "../kunlun/operator/impl/logic";
4
- import { Stream } from "stream";
5
- import { ExecutionInfo, ExecutionResult, RevokeExecutionOptions } from "@byted-apaas/server-common-node/context/workflow/workflow";
6
- import { AppCtx } from "../application/application";
7
- import { Order } from "../context/db/impl/order";
3
+ import { Criterion } from '../kunlun/operator/impl/logic';
4
+ import { Stream } from 'stream';
5
+ import { ExecutionInfo, ExecutionResult, RevokeExecutionOptions } from '@byted-apaas/server-common-node/context/workflow/workflow';
6
+ import { AppCtx } from '../application/application';
7
+ import { Order } from '../context/db/impl/order';
8
8
  export declare function GetHttpInstance(): IInnerAPIRequest;
9
9
  export declare function GetInstance(): IInnerAPIRequest;
10
10
  export declare function GetFaaSInfraInstance(): IFaaSInfraRequest;
@@ -29,69 +29,83 @@ export type OpenSDKGetRecordsReq = {
29
29
  sort: OrderV2[];
30
30
  count: boolean;
31
31
  };
32
+ export type AppAccessToken = {
33
+ expire: number;
34
+ appAccessToken: string;
35
+ appId: string;
36
+ };
37
+ export type TenantAccessToken = {
38
+ expire: number;
39
+ tenantAccessToken: string;
40
+ appId: string;
41
+ };
32
42
  export interface IInnerAPIRequest extends IInnerAPIBaseRequest, IInnerAPIOpenSDKRequest {
33
43
  }
34
44
  export interface IInnerAPIBaseRequest {
35
- createRecordBySync(objectApiName: string, record: object, authType: string): any;
36
- updateRecordBySync(objectApiName: string, recordID: number, record: object, authType: string): any;
37
- deleteRecordBySync(objectApiName: string, recordID: number, authType: string): any;
38
- createRecordsByAsync(objectApiName: string, records: object[], authType: string): any;
39
- updateRecordsByAsync(objectApiName: string, recordMap: Record<number, object>, authType: string): any;
40
- deleteRecordsByAsync(objectApiName: string, recordIDs: number[], authType: string): any;
41
- createRecordsBySync(objectApiName: string, records: object[], authType: string): any;
42
- updateRecordsBySync(objectApiName: string, recordMap: Record<number, object>, authType: string): any;
43
- deleteRecordsBySync(objectApiName: string, recordIDs: number[], authType: string): any;
44
- getRecordsOrCountByCriterion(objectApiName: string, criterion: string | Criterion, fuzzySearch: any, order: Order[], ignoreBackLookupField: boolean, fieldApiNames: string[], offset: number, limit: number, needCount: boolean, authType: string): any;
45
- updateWorkflowVariables(ctx: any, instanceId: number, variables: object, variableTypes: object): Promise<void>;
46
- uploadFile(data: Stream, expire: number): Promise<UploadFileResp>;
47
- downloadFileByID(fileID: string, filePath?: string): Promise<Buffer | void>;
48
- downloadFileByToken(fileToken: string, filePath?: string): Promise<Buffer | void>;
49
- createMessage(msg: any): Promise<number>;
50
- updateMessage(msgId: number, msg: any): Promise<void>;
51
- getFields(objectApiName: string): Promise<any>;
52
- getField(objectApiName: string, fieldApiName: string): Promise<any>;
53
- terminateWorkflowInstance(workflowInstanceId: number, operator: number, reason: string): Promise<void>;
54
- modifyRecordsWithTransaction(placeholders: Record<string, number>, operations: object[], authType: string): Promise<Map<string, number>>;
55
- getGlobalConfigByKey<valueT>(key: string): Promise<valueT>;
56
- oql(oql: string, args: any[], namedArgs: Record<string, any>, authType: string): Promise<string | any[]>;
57
- invokeFuncSync(idOrName: {
45
+ createRecordBySync: (objectApiName: string, record: object, authType: string) => any;
46
+ updateRecordBySync: (objectApiName: string, recordID: number, record: object, authType: string) => any;
47
+ deleteRecordBySync: (objectApiName: string, recordID: number, authType: string) => any;
48
+ createRecordsByAsync: (objectApiName: string, records: object[], authType: string) => any;
49
+ updateRecordsByAsync: (objectApiName: string, recordMap: Record<number, object>, authType: string) => any;
50
+ deleteRecordsByAsync: (objectApiName: string, recordIDs: number[], authType: string) => any;
51
+ createRecordsBySync: (objectApiName: string, records: object[], authType: string) => any;
52
+ updateRecordsBySync: (objectApiName: string, recordMap: Record<number, object>, authType: string) => any;
53
+ deleteRecordsBySync: (objectApiName: string, recordIDs: number[], authType: string) => any;
54
+ getRecordsOrCountByCriterion: (objectApiName: string, criterion: string | Criterion, fuzzySearch: any, order: Order[], ignoreBackLookupField: boolean, fieldApiNames: string[], offset: number, limit: number, needCount: boolean, authType: string) => any;
55
+ updateWorkflowVariables: (ctx: any, instanceId: number, variables: object, variableTypes: object) => Promise<void>;
56
+ uploadFile: (data: Stream, expire: number) => Promise<UploadFileResp>;
57
+ downloadFileByID: (fileID: string, filePath?: string) => Promise<Buffer | undefined>;
58
+ downloadFileByToken: (fileToken: string, filePath?: string) => Promise<Buffer | undefined>;
59
+ createMessage: (msg: any) => Promise<number>;
60
+ updateMessage: (msgId: number, msg: any) => Promise<void>;
61
+ getFields: (objectApiName: string) => Promise<any>;
62
+ getField: (objectApiName: string, fieldApiName: string) => Promise<any>;
63
+ terminateWorkflowInstance: (workflowInstanceId: number, operator: number, reason: string) => Promise<void>;
64
+ modifyRecordsWithTransaction: (placeholders: Record<string, number>, operations: object[], authType: string) => Promise<Map<string, number>>;
65
+ getGlobalConfigByKey: <valueT>(key: string) => Promise<valueT>;
66
+ oql: (oql: string, args: any[], namedArgs: Record<string, any>, authType: string) => Promise<string | any[]>;
67
+ invokeFuncSync: (idOrName: {
58
68
  APIId?: string;
59
69
  APIName?: string;
60
70
  isInvokeByAPIName: boolean;
61
- }, params: any): Promise<any>;
62
- createAsyncTaskV1(idOrName: {
71
+ }, params: any) => Promise<any>;
72
+ createAsyncTaskV1: (idOrName: {
63
73
  APIId?: string;
64
74
  APIName?: string;
65
75
  isInvokeByAPIName: boolean;
66
- }, params: any): Promise<any>;
67
- createAsyncTaskV2(name: string, params: any): Promise<any>;
68
- getExecutionUserTaskInfo(executionId: bigint): Promise<any>;
69
- executeFlow(APIName: string, options: any): Promise<ExecutionResult>;
70
- revokeExecution(executionId: number, revokeOptions: RevokeExecutionOptions): Promise<void>;
71
- getExecutionInfo(executionId: number): Promise<ExecutionInfo>;
72
- getTenantInfo(appCtx: AppCtx): Promise<any>;
73
- mGetFileToken(ids: string[]): Promise<string>;
76
+ }, params: any) => Promise<any>;
77
+ createAsyncTaskV2: (name: string, params: any) => Promise<any>;
78
+ getExecutionUserTaskInfo: (executionId: bigint) => Promise<any>;
79
+ executeFlow: (APIName: string, options: any) => Promise<ExecutionResult>;
80
+ revokeExecution: (executionId: number, revokeOptions: RevokeExecutionOptions) => Promise<void>;
81
+ getExecutionInfo: (executionId: number) => Promise<ExecutionInfo>;
82
+ getTenantInfo: (appCtx: AppCtx) => Promise<any>;
83
+ mGetFileToken: (ids: string[]) => Promise<string>;
84
+ getIntegrationAppAccessToken: (apiName: string) => Promise<AppAccessToken>;
85
+ getIntegrationTenantAccessToken: (apiName: string) => Promise<TenantAccessToken>;
86
+ getDefaultIntegrationAppAccessToken: () => Promise<AppAccessToken>;
87
+ getDefaultIntegrationTenantAccessToken: () => Promise<TenantAccessToken>;
74
88
  }
75
89
  export interface IInnerAPIOpenSDKRequest {
76
- openSDKCreateRecordBySync(objectApiName: string, record: object): any;
77
- openSDKUpdateRecordBySync(objectApiName: string, recordID: number, record: object): any;
78
- openSDKDeleteRecordBySync(objectApiName: string, recordID: number): any;
79
- openSDKCreateRecordsBySync(objectApiName: string, records: object[]): any;
80
- openSDKUpdateRecordsBySync(objectApiName: string, recordMap: Record<number, object>): any;
81
- openSDKDeleteRecordsBySync(objectApiName: string, recordIDs: number[]): any;
82
- openSDKGetRecords(objectApiName: string, param: OpenSDKGetRecordsReq): any;
83
- openSDKUploadFile(fileName: string, data: Buffer): any;
84
- openSDKUploadAvatar(fileName: string, data: Buffer): any;
85
- openSDKDownloadAvatar(imageID: string): any;
86
- invokeFuncWithAuth(idOrName: {
90
+ openSDKCreateRecordBySync: (objectApiName: string, record: object) => any;
91
+ openSDKUpdateRecordBySync: (objectApiName: string, recordID: number, record: object) => any;
92
+ openSDKDeleteRecordBySync: (objectApiName: string, recordID: number) => any;
93
+ openSDKCreateRecordsBySync: (objectApiName: string, records: object[]) => any;
94
+ openSDKUpdateRecordsBySync: (objectApiName: string, recordMap: Record<number, object>) => any;
95
+ openSDKDeleteRecordsBySync: (objectApiName: string, recordIDs: number[]) => any;
96
+ openSDKGetRecords: (objectApiName: string, param: OpenSDKGetRecordsReq) => any;
97
+ openSDKUploadFile: (fileName: string, data: Buffer) => any;
98
+ openSDKUploadAvatar: (fileName: string, data: Buffer) => any;
99
+ openSDKDownloadAvatar: (imageID: string) => any;
100
+ invokeFuncWithAuth: (idOrName: {
87
101
  APIId?: string;
88
102
  APIName?: string;
89
103
  isInvokeByAPIName: boolean;
90
- }, params: any): Promise<any>;
104
+ }, params: any) => Promise<any>;
91
105
  }
92
106
  export interface IFaaSInfraRequest {
93
- createDistributeTaskV1(dataset: any, handlerFunc: string, progressCallbackFunc: string, completedCallbackFunc: string, options: any): Promise<any>;
94
- createDistributeTaskV2(dataset: any, handlerFunc: string, progressCallbackFunc: string, completedCallbackFunc: string, options: any): Promise<any>;
95
- invokeMicroserviceSync(apiName: string, path: string, method: string, body: any): Promise<any>;
96
- invokeMicroserviceAsync(apiName: string, path: string, method: string, body: any): Promise<any>;
107
+ createDistributeTaskV1: (dataset: any, handlerFunc: string, progressCallbackFunc: string, completedCallbackFunc: string, options: any) => Promise<any>;
108
+ createDistributeTaskV2: (dataset: any, handlerFunc: string, progressCallbackFunc: string, completedCallbackFunc: string, options: any) => Promise<any>;
109
+ invokeMicroserviceSync: (apiName: string, path: string, method: string, body: any) => Promise<any>;
110
+ invokeMicroserviceAsync: (apiName: string, path: string, method: string, body: any) => Promise<any>;
97
111
  }
@@ -10,21 +10,21 @@ const faasinfra_1 = require("./faasinfra");
10
10
  const utils = common.utils;
11
11
  const constants = common.constants;
12
12
  const requestInstanceMap = {
13
- "httpRequest": null,
14
- "rpcRequest": null,
13
+ 'httpRequest': null,
14
+ 'rpcRequest': null,
15
15
  };
16
16
  function GetHttpInstance() {
17
- if (!requestInstanceMap["httpRequest"]) {
18
- requestInstanceMap["httpRequest"] = new openapi_1.RequestHttp();
17
+ if (!requestInstanceMap.httpRequest) {
18
+ requestInstanceMap.httpRequest = new openapi_1.RequestHttp();
19
19
  }
20
- return requestInstanceMap["httpRequest"];
20
+ return requestInstanceMap.httpRequest;
21
21
  }
22
22
  exports.GetHttpInstance = GetHttpInstance;
23
23
  function GetRpcInstance() {
24
- if (!requestInstanceMap["rpcRequest"]) {
25
- requestInstanceMap["rpcRequest"] = new innerapi_1.RequestRpc();
24
+ if (!requestInstanceMap.rpcRequest) {
25
+ requestInstanceMap.rpcRequest = new innerapi_1.RequestRpc();
26
26
  }
27
- return requestInstanceMap["rpcRequest"];
27
+ return requestInstanceMap.rpcRequest;
28
28
  }
29
29
  function GetInstance() {
30
30
  // 内网版 && 非本地开发 使用 RPC 请求
@@ -39,4 +39,4 @@ function GetFaaSInfraInstance() {
39
39
  return new faasinfra_1.FaaSInfraRequest();
40
40
  }
41
41
  exports.GetFaaSInfraInstance = GetFaaSInfraInstance;
42
- ;
42
+ //# sourceMappingURL=interface.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"interface.js","sourceRoot":"","sources":["interface.ts"],"names":[],"mappings":";AAAA,sDAAsD;AACtD,+BAA+B;;;AAI/B,uCAAsC;AACtC,yCAAsC;AACtC,0DAA0D;AAC1D,2CAA6C;AAU7C,MAAM,KAAK,GAAG,MAAM,CAAC,KAAK,CAAC;AAC3B,MAAM,SAAS,GAAG,MAAM,CAAC,SAAS,CAAC;AAEnC,MAAM,kBAAkB,GAAqC;IACzD,aAAa,EAAE,IAAI;IACnB,YAAY,EAAE,IAAI;CACrB,CAAA;AAED,SAAgB,eAAe;IAC3B,IAAI,CAAC,kBAAkB,CAAC,WAAW,EAAE;QACjC,kBAAkB,CAAC,WAAW,GAAG,IAAI,qBAAW,EAAE,CAAC;KACtD;IACD,OAAO,kBAAkB,CAAC,WAAW,CAAC;AAC1C,CAAC;AALD,0CAKC;AAED,SAAS,cAAc;IACnB,IAAI,CAAC,kBAAkB,CAAC,UAAU,EAAE;QAChC,kBAAkB,CAAC,UAAU,GAAG,IAAI,qBAAU,EAAE,CAAC;KACpD;IACD,OAAO,kBAAkB,CAAC,UAAU,CAAC;AACzC,CAAC;AAED,SAAgB,WAAW;IACvB,yBAAyB;IACzB,IAAI,CAAC,KAAK,CAAC,WAAW,EAAE,KAAK,SAAS,CAAC,cAAc,CAAC,8BAA8B;QAChF,KAAK,CAAC,WAAW,EAAE,KAAK,SAAS,CAAC,cAAc,CAAC,0BAA0B,CAAC,IAAI,CAAC,KAAK,CAAC,YAAY,EAAE,EAAE;QACvG,OAAO,cAAc,EAAE,CAAC;KAC3B;IACD,OAAO,eAAe,EAAE,CAAC;AAC7B,CAAC;AAPD,kCAOC;AAED,SAAgB,oBAAoB;IAChC,OAAO,IAAI,4BAAgB,EAAE,CAAC;AAClC,CAAC;AAFD,oDAEC"}
@@ -1,11 +1,11 @@
1
1
  /// <reference types="node" />
2
2
  /// <reference types="node" />
3
- import { Stream } from "stream";
4
- import { Order } from "../context/db/impl/order";
5
- import { Criterion } from "../kunlun/operator/impl/logic";
6
- import { IInnerAPIRequest, OpenSDKGetRecordsReq, UploadFileResp } from "./interface";
7
- import { ExecutionInfo, ExecutionResult, RevokeExecutionOptions } from "@byted-apaas/server-common-node/context/workflow/workflow";
8
- import { AppCtx } from "../application/application";
3
+ import { Stream } from 'stream';
4
+ import { Order } from '../context/db/impl/order';
5
+ import { Criterion } from '../kunlun/operator/impl/logic';
6
+ import { IInnerAPIRequest, OpenSDKGetRecordsReq, UploadFileResp } from './interface';
7
+ import { ExecutionInfo, ExecutionResult, RevokeExecutionOptions } from '@byted-apaas/server-common-node/context/workflow/workflow';
8
+ import { AppCtx } from '../application/application';
9
9
  export declare function updateWorkflowVariables(ctx: any, instanceId: number, variables: object, variableTypes: object): Promise<void>;
10
10
  export declare class RequestHttp implements IInnerAPIRequest {
11
11
  constructor();
@@ -21,8 +21,8 @@ export declare class RequestHttp implements IInnerAPIRequest {
21
21
  deleteRecordsBySync(objectApiName: string, recordIDs: number[], authType: string): any;
22
22
  getRecordsOrCountByCriterion(objectApiName: string, criterion: string | Criterion, order: Order[], fuzzySearch: any, ignoreBackLookupField: boolean, fieldApiNames: string[], offset: number, limit: number, needCount: boolean, authType: string): any;
23
23
  uploadFile(data: Stream, expire: number): Promise<UploadFileResp>;
24
- downloadFileByID(fileID: string, filePath?: string): Promise<void | Buffer>;
25
- downloadFileByToken(fileToken: string, filePath?: string): Promise<Buffer | void>;
24
+ downloadFileByID(fileID: string, filePath?: string): Promise<undefined | Buffer>;
25
+ downloadFileByToken(fileToken: string, filePath?: string): Promise<Buffer | undefined>;
26
26
  createMessage(msg: any): Promise<number>;
27
27
  updateMessage(msgId: number, msg: any): Promise<void>;
28
28
  getFields(objectApiName: string): any;
@@ -53,6 +53,10 @@ export declare class RequestHttp implements IInnerAPIRequest {
53
53
  getExecutionInfo(executionId: number): Promise<ExecutionInfo>;
54
54
  getTenantInfo(appCtx: AppCtx): Promise<any>;
55
55
  mGetFileToken(ids: string[]): Promise<string>;
56
+ getIntegrationAppAccessToken(apiName: string): Promise<any>;
57
+ getIntegrationTenantAccessToken(apiName: string): Promise<any>;
58
+ getDefaultIntegrationAppAccessToken(): Promise<any>;
59
+ getDefaultIntegrationTenantAccessToken(): Promise<any>;
56
60
  openSDKCreateRecordBySync(objectApiName: string, record: object): any;
57
61
  openSDKUpdateRecordBySync(objectApiName: string, recordID: number, record: object): any;
58
62
  openSDKDeleteRecordBySync(objectApiName: string, recordID: number): any;