@api-client/core 0.12.9 → 0.12.11

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 (81) hide show
  1. package/build/src/browser.d.ts +1 -2
  2. package/build/src/browser.d.ts.map +1 -1
  3. package/build/src/browser.js +0 -1
  4. package/build/src/browser.js.map +1 -1
  5. package/build/src/exceptions/exception.d.ts +29 -1
  6. package/build/src/exceptions/exception.d.ts.map +1 -1
  7. package/build/src/exceptions/exception.js +37 -1
  8. package/build/src/exceptions/exception.js.map +1 -1
  9. package/build/src/index.d.ts +1 -2
  10. package/build/src/index.d.ts.map +1 -1
  11. package/build/src/index.js +0 -1
  12. package/build/src/index.js.map +1 -1
  13. package/build/src/mocking/lib/User.d.ts.map +1 -1
  14. package/build/src/mocking/lib/User.js +1 -0
  15. package/build/src/mocking/lib/User.js.map +1 -1
  16. package/build/src/models/store/User.d.ts +14 -0
  17. package/build/src/models/store/User.d.ts.map +1 -1
  18. package/build/src/models/store/User.js.map +1 -1
  19. package/build/src/proxy/HttpProjectProxy.d.ts.map +1 -1
  20. package/build/src/proxy/HttpProjectProxy.js +39 -43
  21. package/build/src/proxy/HttpProjectProxy.js.map +1 -1
  22. package/build/src/proxy/RequestProxy.d.ts.map +1 -1
  23. package/build/src/proxy/RequestProxy.js +11 -11
  24. package/build/src/proxy/RequestProxy.js.map +1 -1
  25. package/build/src/runtime/store/DataCatalogSdk.d.ts.map +1 -1
  26. package/build/src/runtime/store/DataCatalogSdk.js +49 -109
  27. package/build/src/runtime/store/DataCatalogSdk.js.map +1 -1
  28. package/build/src/runtime/store/FilesSdk.d.ts.map +1 -1
  29. package/build/src/runtime/store/FilesSdk.js +51 -115
  30. package/build/src/runtime/store/FilesSdk.js.map +1 -1
  31. package/build/src/runtime/store/HistorySdk.d.ts.map +1 -1
  32. package/build/src/runtime/store/HistorySdk.js +25 -70
  33. package/build/src/runtime/store/HistorySdk.js.map +1 -1
  34. package/build/src/runtime/store/OrganizationsSdk.d.ts +20 -1
  35. package/build/src/runtime/store/OrganizationsSdk.d.ts.map +1 -1
  36. package/build/src/runtime/store/OrganizationsSdk.js +103 -43
  37. package/build/src/runtime/store/OrganizationsSdk.js.map +1 -1
  38. package/build/src/runtime/store/RevisionsSdk.d.ts.map +1 -1
  39. package/build/src/runtime/store/RevisionsSdk.js +5 -10
  40. package/build/src/runtime/store/RevisionsSdk.js.map +1 -1
  41. package/build/src/runtime/store/RouteBuilder.d.ts +8 -0
  42. package/build/src/runtime/store/RouteBuilder.d.ts.map +1 -1
  43. package/build/src/runtime/store/RouteBuilder.js +12 -0
  44. package/build/src/runtime/store/RouteBuilder.js.map +1 -1
  45. package/build/src/runtime/store/SdkBase.d.ts +7 -5
  46. package/build/src/runtime/store/SdkBase.d.ts.map +1 -1
  47. package/build/src/runtime/store/SdkBase.js +45 -63
  48. package/build/src/runtime/store/SdkBase.js.map +1 -1
  49. package/build/src/runtime/store/SharedSdk.d.ts.map +1 -1
  50. package/build/src/runtime/store/SharedSdk.js +5 -14
  51. package/build/src/runtime/store/SharedSdk.js.map +1 -1
  52. package/build/src/runtime/store/TrashSdk.d.ts.map +1 -1
  53. package/build/src/runtime/store/TrashSdk.js +8 -28
  54. package/build/src/runtime/store/TrashSdk.js.map +1 -1
  55. package/build/src/runtime/store/UsersSdk.d.ts +2 -0
  56. package/build/src/runtime/store/UsersSdk.d.ts.map +1 -1
  57. package/build/src/runtime/store/UsersSdk.js +18 -11
  58. package/build/src/runtime/store/UsersSdk.js.map +1 -1
  59. package/package.json +1 -1
  60. package/src/exceptions/exception.ts +51 -4
  61. package/src/mocking/lib/User.ts +1 -0
  62. package/src/models/store/User.ts +16 -0
  63. package/src/proxy/HttpProjectProxy.ts +39 -43
  64. package/src/proxy/RequestProxy.ts +11 -11
  65. package/src/runtime/store/DataCatalogSdk.ts +49 -109
  66. package/src/runtime/store/FilesSdk.ts +51 -115
  67. package/src/runtime/store/HistorySdk.ts +25 -70
  68. package/src/runtime/store/OrganizationsSdk.ts +109 -44
  69. package/src/runtime/store/RevisionsSdk.ts +5 -10
  70. package/src/runtime/store/RouteBuilder.ts +14 -0
  71. package/src/runtime/store/SdkBase.ts +46 -65
  72. package/src/runtime/store/SharedSdk.ts +5 -14
  73. package/src/runtime/store/TrashSdk.ts +8 -28
  74. package/src/runtime/store/UsersSdk.ts +18 -11
  75. package/tests/unit/runtime/proxy/HttpProjectProxy.spec.ts +42 -40
  76. package/tests/unit/runtime/proxy/RequestProxy.spec.ts +11 -11
  77. package/build/src/runtime/store/Errors.d.ts +0 -51
  78. package/build/src/runtime/store/Errors.d.ts.map +0 -1
  79. package/build/src/runtime/store/Errors.js +0 -61
  80. package/build/src/runtime/store/Errors.js.map +0 -1
  81. package/src/runtime/store/Errors.ts +0 -98
@@ -1,3 +1,4 @@
1
+ import type { UserOrganizationGrantType } from './Organization.js';
1
2
  export interface IEmail {
2
3
  /**
3
4
  * When available the email of the user.
@@ -20,6 +21,7 @@ export interface IUserPicture {
20
21
  data?: string;
21
22
  }
22
23
  export declare const Kind = "Core#User";
24
+ export type UserStatus = 'active' | 'deleted' | 'suspended' | 'pending';
23
25
  /**
24
26
  * Represents a user in the system.
25
27
  * This can be embedded in various situations like project's revision history,
@@ -60,6 +62,7 @@ export interface IUser {
60
62
  provider?: unknown;
61
63
  /**
62
64
  * Whether the user is deleted from the system.
65
+ * @deprecated Use `status` instead.
63
66
  */
64
67
  deleted?: boolean;
65
68
  /**
@@ -70,5 +73,16 @@ export interface IUser {
70
73
  * The id of the user that deleted the user.
71
74
  */
72
75
  deletingUser?: string;
76
+ /**
77
+ * The status of the user.
78
+ * May not be populated in all cases.
79
+ * @default 'active'
80
+ */
81
+ status?: UserStatus;
82
+ /**
83
+ * Populated when the user object is considered in the context of an organization.
84
+ * This is used to determine the user's role in the organization.
85
+ */
86
+ grantType?: UserOrganizationGrantType;
73
87
  }
74
88
  //# sourceMappingURL=User.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"User.d.ts","sourceRoot":"","sources":["../../../../src/models/store/User.ts"],"names":[],"mappings":"AAAA,MAAM,WAAW,MAAM;IACrB;;OAEG;IACH,KAAK,CAAC,EAAE,MAAM,CAAA;IACd;;;OAGG;IACH,QAAQ,CAAC,EAAE,OAAO,CAAA;CACnB;AAED,MAAM,WAAW,YAAY;IAC3B;;OAEG;IACH,GAAG,CAAC,EAAE,MAAM,CAAA;IACZ;;OAEG;IACH,IAAI,CAAC,EAAE,MAAM,CAAA;CACd;AAED,eAAO,MAAM,IAAI,cAAc,CAAA;AAE/B;;;;;;;GAOG;AACH,MAAM,WAAW,KAAK;IACpB,IAAI,EAAE,OAAO,IAAI,CAAA;IACjB;;OAEG;IACH,GAAG,EAAE,MAAM,CAAA;IACX;;OAEG;IACH,IAAI,EAAE,MAAM,CAAA;IACZ;;OAEG;IACH,KAAK,CAAC,EAAE,MAAM,EAAE,CAAA;IAChB;;OAEG;IACH,OAAO,CAAC,EAAE,YAAY,CAAA;IACtB;;OAEG;IACH,IAAI,CAAC,EAAE,MAAM,EAAE,CAAA;IACf;;OAEG;IACH,MAAM,CAAC,EAAE,MAAM,CAAA;IACf;;OAEG;IACH,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB;;OAEG;IACH,OAAO,CAAC,EAAE,OAAO,CAAA;IACjB;;OAEG;IACH,WAAW,CAAC,EAAE,MAAM,CAAA;IACpB;;OAEG;IACH,YAAY,CAAC,EAAE,MAAM,CAAA;CACtB"}
1
+ {"version":3,"file":"User.d.ts","sourceRoot":"","sources":["../../../../src/models/store/User.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,yBAAyB,EAAE,MAAM,mBAAmB,CAAA;AAElE,MAAM,WAAW,MAAM;IACrB;;OAEG;IACH,KAAK,CAAC,EAAE,MAAM,CAAA;IACd;;;OAGG;IACH,QAAQ,CAAC,EAAE,OAAO,CAAA;CACnB;AAED,MAAM,WAAW,YAAY;IAC3B;;OAEG;IACH,GAAG,CAAC,EAAE,MAAM,CAAA;IACZ;;OAEG;IACH,IAAI,CAAC,EAAE,MAAM,CAAA;CACd;AAED,eAAO,MAAM,IAAI,cAAc,CAAA;AAE/B,MAAM,MAAM,UAAU,GAAG,QAAQ,GAAG,SAAS,GAAG,WAAW,GAAG,SAAS,CAAA;AAEvE;;;;;;;GAOG;AACH,MAAM,WAAW,KAAK;IACpB,IAAI,EAAE,OAAO,IAAI,CAAA;IACjB;;OAEG;IACH,GAAG,EAAE,MAAM,CAAA;IACX;;OAEG;IACH,IAAI,EAAE,MAAM,CAAA;IACZ;;OAEG;IACH,KAAK,CAAC,EAAE,MAAM,EAAE,CAAA;IAChB;;OAEG;IACH,OAAO,CAAC,EAAE,YAAY,CAAA;IACtB;;OAEG;IACH,IAAI,CAAC,EAAE,MAAM,EAAE,CAAA;IACf;;OAEG;IACH,MAAM,CAAC,EAAE,MAAM,CAAA;IACf;;OAEG;IACH,QAAQ,CAAC,EAAE,OAAO,CAAA;IAClB;;;OAGG;IACH,OAAO,CAAC,EAAE,OAAO,CAAA;IACjB;;OAEG;IACH,WAAW,CAAC,EAAE,MAAM,CAAA;IACpB;;OAEG;IACH,YAAY,CAAC,EAAE,MAAM,CAAA;IACrB;;;;OAIG;IACH,MAAM,CAAC,EAAE,UAAU,CAAA;IACnB;;;OAGG;IACH,SAAS,CAAC,EAAE,yBAAyB,CAAA;CACtC"}
@@ -1 +1 @@
1
- {"version":3,"file":"User.js","sourceRoot":"","sources":["../../../../src/models/store/User.ts"],"names":[],"mappings":"AAuBA,MAAM,CAAC,MAAM,IAAI,GAAG,WAAW,CAAA","sourcesContent":["export interface IEmail {\n /**\n * When available the email of the user.\n */\n email?: string\n /**\n * Whether the `email` was verified.\n * Not verified emails should have limited use in the system.\n */\n verified?: boolean\n}\n\nexport interface IUserPicture {\n /**\n * When available, the URL to the user's picture image.\n */\n url?: string\n /**\n * Alternative to the `url`. When set it is a data URL value of the image.\n */\n data?: string\n}\n\nexport const Kind = 'Core#User'\n\n/**\n * Represents a user in the system.\n * This can be embedded in various situations like project's revision history,\n * ACL, Authorization, etc.\n *\n * Note, the store implementation may have additional fields that support external\n * identity providers. However, this is not exposed to the user through the API.\n */\nexport interface IUser {\n kind: typeof Kind\n /**\n * The data store key of the user.\n */\n key: string\n /**\n * The display name of the user.\n */\n name: string\n /**\n * When available the email of the user.\n */\n email?: IEmail[]\n /**\n * The user picture to render.\n */\n picture?: IUserPicture\n /**\n * A general purpose tags field.\n */\n tags?: string[]\n /**\n * Optional user locale information.\n */\n locale?: string\n /**\n * Optional metadata related to the auth provider.\n */\n provider?: unknown\n /**\n * Whether the user is deleted from the system.\n */\n deleted?: boolean\n /**\n * The timestamp of when the user was deleted.\n */\n deletedTime?: number\n /**\n * The id of the user that deleted the user.\n */\n deletingUser?: string\n}\n"]}
1
+ {"version":3,"file":"User.js","sourceRoot":"","sources":["../../../../src/models/store/User.ts"],"names":[],"mappings":"AAyBA,MAAM,CAAC,MAAM,IAAI,GAAG,WAAW,CAAA","sourcesContent":["import type { UserOrganizationGrantType } from './Organization.js'\n\nexport interface IEmail {\n /**\n * When available the email of the user.\n */\n email?: string\n /**\n * Whether the `email` was verified.\n * Not verified emails should have limited use in the system.\n */\n verified?: boolean\n}\n\nexport interface IUserPicture {\n /**\n * When available, the URL to the user's picture image.\n */\n url?: string\n /**\n * Alternative to the `url`. When set it is a data URL value of the image.\n */\n data?: string\n}\n\nexport const Kind = 'Core#User'\n\nexport type UserStatus = 'active' | 'deleted' | 'suspended' | 'pending'\n\n/**\n * Represents a user in the system.\n * This can be embedded in various situations like project's revision history,\n * ACL, Authorization, etc.\n *\n * Note, the store implementation may have additional fields that support external\n * identity providers. However, this is not exposed to the user through the API.\n */\nexport interface IUser {\n kind: typeof Kind\n /**\n * The data store key of the user.\n */\n key: string\n /**\n * The display name of the user.\n */\n name: string\n /**\n * When available the email of the user.\n */\n email?: IEmail[]\n /**\n * The user picture to render.\n */\n picture?: IUserPicture\n /**\n * A general purpose tags field.\n */\n tags?: string[]\n /**\n * Optional user locale information.\n */\n locale?: string\n /**\n * Optional metadata related to the auth provider.\n */\n provider?: unknown\n /**\n * Whether the user is deleted from the system.\n * @deprecated Use `status` instead.\n */\n deleted?: boolean\n /**\n * The timestamp of when the user was deleted.\n */\n deletedTime?: number\n /**\n * The id of the user that deleted the user.\n */\n deletingUser?: string\n /**\n * The status of the user.\n * May not be populated in all cases.\n * @default 'active'\n */\n status?: UserStatus\n /**\n * Populated when the user object is considered in the context of an organization.\n * This is used to determine the user's role in the organization.\n */\n grantType?: UserOrganizationGrantType\n}\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"HttpProjectProxy.d.ts","sourceRoot":"","sources":["../../../src/proxy/HttpProjectProxy.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,qBAAqB,EAAE,MAAM,sCAAsC,CAAA;AAC5E,OAAO,EAAE,IAAI,IAAI,eAAe,EAAE,WAAW,EAAE,YAAY,EAAE,MAAM,0BAA0B,CAAA;AAK7F,OAAO,KAAK,EAAE,EAAE,YAAY,EAAE,MAAM,YAAY,CAAA;AAChD,OAAO,EAAE,oBAAoB,EAAE,MAAM,+BAA+B,CAAA;AAEpE,UAAU,SAAS;IACjB,IAAI,EAAE,OAAO,eAAe,CAAA;IAC5B;;OAEG;IACH,OAAO,EAAE,qBAAqB,CAAA;IAC9B;;OAEG;IACH,MAAM,CAAC,EAAE,WAAW,GAAG,IAAI,CAAA;CAC5B;AAED,MAAM,WAAW,qBAAsB,SAAQ,SAAS;IACtD,OAAO,EAAE,YAAY,CAAA;CACtB;AAED,MAAM,WAAW,0BAA2B,SAAQ,SAAS;IAC3D,IAAI,EAAE,OAAO,eAAe,CAAA;IAC5B;;OAEG;IACH,GAAG,EAAE,MAAM,CAAA;IACX;;OAEG;IACH,YAAY,EAAE,MAAM,CAAA;CACrB;AAED;;GAEG;AACH,MAAM,CAAC,OAAO,OAAO,gBAAiB,SAAQ,KAAK;IACjD,OAAO,CAAC,EAAE,WAAW,CAAA;IACrB,OAAO,CAA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,SAAQ,KAAK;IACjD,OAAO,CAAC,EAAE,WAAW,CAAA;IACrB,OAAO,CAAC,EAAE,qBAAqB,CAAA;cAEf,cAAc,CAAC,IAAI,EAAE,0BAA0B,EAAE,KAAK,EAAE,MAAM,EAAE,OAAO,EAAE,MAAM,GAAG,OAAO,CAAC,IAAI,CAAC;cA+D/F,gBAAgB,CAAC,IAAI,EAAE,qBAAqB,GAAG,OAAO,CAAC,IAAI,CAAC;IAsBtE,SAAS,CACb,IAAI,EAAE,qBAAqB,GAAG,0BAA0B,EACxD,KAAK,CAAC,EAAE,MAAM,EACd,OAAO,CAAC,EAAE,MAAM,GACf,OAAO,CAAC,IAAI,CAAC;IASV,OAAO,IAAI,OAAO,CAAC,YAAY,CAAC,oBAAoB,CAAC,CAAC;CA0B7D"}
@@ -1,9 +1,9 @@
1
1
  import { HttpProject } from '../models/HttpProject.js';
2
- import { ApiError } from '../runtime/store/Errors.js';
3
2
  import { StoreSdk } from '../runtime/store/StoreSdkNode.js';
4
3
  import { ProjectSerialRunner } from '../runtime/node/ProjectSerialRunner.js';
5
4
  import { ProjectParallelRunner } from '../runtime/node/ProjectParallelRunner.js';
6
5
  import Proxy from './Proxy.js';
6
+ import { Exception } from '../exceptions/exception.js';
7
7
  /**
8
8
  * Runs requests from an HTTP project read from the store.
9
9
  */
@@ -12,52 +12,48 @@ export default class HttpProjectProxy extends Proxy {
12
12
  options;
13
13
  async configureStore(init, token, baseUri) {
14
14
  const { pid, options, organization } = init;
15
+ const INVALID_REQUEST = 'Invalid request';
16
+ const code = 'E_INVALID_REQUEST';
15
17
  if (!pid) {
16
- throw new ApiError({
17
- error: true,
18
- message: 'Invalid request',
19
- detail: 'The "pid" parameter is required.',
20
- code: 400,
18
+ throw new Exception(INVALID_REQUEST, {
19
+ help: 'The "pid" parameter is required.',
20
+ status: 400,
21
+ code,
21
22
  });
22
23
  }
23
24
  if (!organization) {
24
- throw new ApiError({
25
- error: true,
26
- message: 'Invalid request',
27
- detail: 'The "organization" parameter is required.',
28
- code: 400,
25
+ throw new Exception(INVALID_REQUEST, {
26
+ help: 'The "organization" parameter is required.',
27
+ status: 400,
28
+ code,
29
29
  });
30
30
  }
31
31
  if (!options) {
32
- throw new ApiError({
33
- error: true,
34
- message: 'Invalid request',
35
- detail: 'The "options" parameter is required.',
36
- code: 400,
32
+ throw new Exception(INVALID_REQUEST, {
33
+ help: 'The "options" parameter is required.',
34
+ status: 400,
35
+ code,
37
36
  });
38
37
  }
39
38
  if (!token) {
40
- throw new ApiError({
41
- error: true,
42
- message: 'Invalid request',
43
- detail: 'Set the authentication credentials.',
44
- code: 400,
39
+ throw new Exception(INVALID_REQUEST, {
40
+ help: 'Set the authentication credentials.',
41
+ status: 400,
42
+ code,
45
43
  });
46
44
  }
47
45
  if (!baseUri) {
48
- throw new ApiError({
49
- error: true,
50
- message: 'Invalid request',
51
- detail: 'The store uri is missing.',
52
- code: 400,
46
+ throw new Exception(INVALID_REQUEST, {
47
+ help: 'The store uri is missing.',
48
+ status: 400,
49
+ code,
53
50
  });
54
51
  }
55
52
  if (!baseUri.startsWith('http')) {
56
- throw new ApiError({
57
- error: true,
58
- message: 'Invalid request',
59
- detail: 'The store uri is invalid.',
60
- code: 400,
53
+ throw new Exception(INVALID_REQUEST, {
54
+ help: 'The store uri is invalid.',
55
+ status: 400,
56
+ code,
61
57
  });
62
58
  }
63
59
  const sdk = new StoreSdk(baseUri);
@@ -69,30 +65,30 @@ export default class HttpProjectProxy extends Proxy {
69
65
  }
70
66
  catch (cause) {
71
67
  const e = cause;
72
- throw new ApiError(e.message, 400);
68
+ throw new Exception(e.message, { status: 400 });
73
69
  }
74
70
  if (project.key !== pid) {
75
- throw new ApiError(`Unable to read the project.`, 500);
71
+ throw new Exception(`Unable to read the project.`, { status: 500 });
76
72
  }
77
73
  this.options = options;
78
74
  this.project = new HttpProject(project);
79
75
  }
80
76
  async configureProject(init) {
81
77
  const { project, options } = init;
78
+ const INVALID_REQUEST = 'Invalid request';
79
+ const code = 'E_INVALID_REQUEST';
82
80
  if (!options) {
83
- throw new ApiError({
84
- error: true,
85
- message: 'Invalid request',
86
- detail: 'The "options" parameter is required.',
87
- code: 400,
81
+ throw new Exception(INVALID_REQUEST, {
82
+ help: 'The "options" parameter is required.',
83
+ status: 400,
84
+ code,
88
85
  });
89
86
  }
90
87
  if (!project) {
91
- throw new ApiError({
92
- error: true,
93
- message: 'Invalid request',
94
- detail: 'The "project" parameter is required.',
95
- code: 400,
88
+ throw new Exception(INVALID_REQUEST, {
89
+ help: 'The "project" parameter is required.',
90
+ status: 400,
91
+ code,
96
92
  });
97
93
  }
98
94
  this.options = options;
@@ -1 +1 @@
1
- {"version":3,"file":"HttpProjectProxy.js","sourceRoot":"","sources":["../../../src/proxy/HttpProjectProxy.ts"],"names":[],"mappings":"AACA,OAAO,EAA2B,WAAW,EAAgB,MAAM,0BAA0B,CAAA;AAC7F,OAAO,EAAE,QAAQ,EAAE,MAAM,4BAA4B,CAAA;AACrD,OAAO,EAAE,QAAQ,EAAE,MAAM,kCAAkC,CAAA;AAC3D,OAAO,EAAE,mBAAmB,EAAE,MAAM,wCAAwC,CAAA;AAC5E,OAAO,EAAE,qBAAqB,EAAE,MAAM,0CAA0C,CAAA;AAChF,OAAO,KAAuB,MAAM,YAAY,CAAA;AA+BhD;;GAEG;AACH,MAAM,CAAC,OAAO,OAAO,gBAAiB,SAAQ,KAAK;IACjD,OAAO,CAAc;IACrB,OAAO,CAAwB;IAErB,KAAK,CAAC,cAAc,CAAC,IAAgC,EAAE,KAAa,EAAE,OAAe;QAC7F,MAAM,EAAE,GAAG,EAAE,OAAO,EAAE,YAAY,EAAE,GAAG,IAAI,CAAA;QAC3C,IAAI,CAAC,GAAG,EAAE,CAAC;YACT,MAAM,IAAI,QAAQ,CAAC;gBACjB,KAAK,EAAE,IAAI;gBACX,OAAO,EAAE,iBAAiB;gBAC1B,MAAM,EAAE,kCAAkC;gBAC1C,IAAI,EAAE,GAAG;aACV,CAAC,CAAA;QACJ,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,OAAO,UAAU,CAAC,GAAG,KAAK,QAAQ,EAAE,CAAC;YACvC,OAAO,IAAI,CAAC,cAAc,CAAC,UAAU,EAAE,KAAe,EAAE,OAAiB,CAAC,CAAA;QAC5E,CAAC;QACD,MAAM,YAAY,GAAG,IAA6B,CAAA;QAClD,OAAO,IAAI,CAAC,gBAAgB,CAAC,YAAY,CAAC,CAAA;IAC5C,CAAC;IAED,KAAK,CAAC,OAAO;QACX,MAAM,OAAO,GAAG,IAAI,CAAC,OAAsB,CAAA;QAC3C,MAAM,IAAI,GAAG,IAAI,CAAC,OAAgC,CAAA;QAClD,IAAI,OAAoD,CAAA;QACxD,IAAI,IAAI,CAAC,QAAQ,EAAE,CAAC;YAClB,OAAO,GAAG,IAAI,qBAAqB,CAAC,OAAO,EAAE,IAAI,CAAC,CAAA;QACpD,CAAC;aAAM,CAAC;YACN,OAAO,GAAG,IAAI,mBAAmB,EAAE,CAAA;YACnC,OAAO,CAAC,SAAS,CAAC,OAAO,EAAE,IAAI,CAAC,CAAA;QAClC,CAAC;QAED,SAAS,kBAAkB;YACzB,EAAE;QACJ,CAAC;QACD,4DAA4D;QAC5D,wEAAwE;QACxE,yEAAyE;QACzE,6CAA6C;QAC7C,uCAAuC;QACvC,OAAO,CAAC,EAAE,CAAC,oBAAoB,EAAE,kBAAkB,CAAC,CAAA;QACpD,MAAM,MAAM,GAAG,MAAM,OAAO,CAAC,OAAO,EAAE,CAAA;QACtC,OAAO,CAAC,GAAG,CAAC,oBAAoB,EAAE,kBAAkB,CAAC,CAAA;QACrD,OAAO;YACL,MAAM,EAAE,MAAM;SACf,CAAA;IACH,CAAC;CACF","sourcesContent":["import { IProjectRunnerOptions } from '../runtime/node/InteropInterfaces.js'\nimport { Kind as HttpProjectKind, HttpProject, IHttpProject } from '../models/HttpProject.js'\nimport { ApiError } from '../runtime/store/Errors.js'\nimport { StoreSdk } from '../runtime/store/StoreSdkNode.js'\nimport { ProjectSerialRunner } from '../runtime/node/ProjectSerialRunner.js'\nimport { ProjectParallelRunner } from '../runtime/node/ProjectParallelRunner.js'\nimport Proxy, { IProxyResult } from './Proxy.js'\nimport { IProjectExecutionLog } from '../models/ProjectExecution.js'\n\ninterface ProxyInit {\n kind: typeof HttpProjectKind\n /**\n * Runner options.\n */\n options: IProjectRunnerOptions\n /**\n * A signal to be sent to the proxy bindings to abort the request on demand.\n */\n signal?: AbortSignal | null\n}\n\nexport interface IHttpProjectProxyInit extends ProxyInit {\n project: IHttpProject\n}\n\nexport interface IHttpProjectStoreProxyInit extends ProxyInit {\n kind: typeof HttpProjectKind\n /**\n * Project key\n */\n pid: string\n /**\n * The parent organization key.\n */\n organization: string\n}\n\n/**\n * Runs requests from an HTTP project read from the store.\n */\nexport default class HttpProjectProxy extends Proxy {\n project?: HttpProject\n options?: IProjectRunnerOptions\n\n protected async configureStore(init: IHttpProjectStoreProxyInit, token: string, baseUri: string): Promise<void> {\n const { pid, options, organization } = init\n if (!pid) {\n throw new ApiError({\n error: true,\n message: 'Invalid request',\n detail: 'The \"pid\" parameter is required.',\n code: 400,\n })\n }\n if (!organization) {\n throw new ApiError({\n error: true,\n message: 'Invalid request',\n detail: 'The \"organization\" parameter is required.',\n code: 400,\n })\n }\n if (!options) {\n throw new ApiError({\n error: true,\n message: 'Invalid request',\n detail: 'The \"options\" parameter is required.',\n code: 400,\n })\n }\n if (!token) {\n throw new ApiError({\n error: true,\n message: 'Invalid request',\n detail: 'Set the authentication credentials.',\n code: 400,\n })\n }\n if (!baseUri) {\n throw new ApiError({\n error: true,\n message: 'Invalid request',\n detail: 'The store uri is missing.',\n code: 400,\n })\n }\n if (!baseUri.startsWith('http')) {\n throw new ApiError({\n error: true,\n message: 'Invalid request',\n detail: 'The store uri is invalid.',\n code: 400,\n })\n }\n const sdk = new StoreSdk(baseUri)\n sdk.token = token\n let project: IHttpProject\n try {\n const data = await sdk.file.readMedia(organization, pid)\n project = data.media as IHttpProject\n } catch (cause) {\n const e = cause as Error\n throw new ApiError(e.message, 400)\n }\n if (project.key !== pid) {\n throw new ApiError(`Unable to read the project.`, 500)\n }\n this.options = options\n this.project = new HttpProject(project)\n }\n\n protected async configureProject(init: IHttpProjectProxyInit): Promise<void> {\n const { project, options } = init\n if (!options) {\n throw new ApiError({\n error: true,\n message: 'Invalid request',\n detail: 'The \"options\" parameter is required.',\n code: 400,\n })\n }\n if (!project) {\n throw new ApiError({\n error: true,\n message: 'Invalid request',\n detail: 'The \"project\" parameter is required.',\n code: 400,\n })\n }\n this.options = options\n this.project = new HttpProject(project)\n }\n\n async configure(\n init: IHttpProjectProxyInit | IHttpProjectStoreProxyInit,\n token?: string,\n baseUri?: string\n ): Promise<void> {\n const typedStore = init as IHttpProjectStoreProxyInit\n if (typeof typedStore.pid === 'string') {\n return this.configureStore(typedStore, token as string, baseUri as string)\n }\n const typedProject = init as IHttpProjectProxyInit\n return this.configureProject(typedProject)\n }\n\n async execute(): Promise<IProxyResult<IProjectExecutionLog>> {\n const project = this.project as HttpProject\n const opts = this.options as IProjectRunnerOptions\n let factory: ProjectParallelRunner | ProjectSerialRunner\n if (opts.parallel) {\n factory = new ProjectParallelRunner(project, opts)\n } else {\n factory = new ProjectSerialRunner()\n factory.configure(project, opts)\n }\n\n function unhandledRejection(): void {\n //\n }\n // the executing library handles all related errors it need.\n // However, when executing a request to an unknown host Node process may\n // throw unhandled error event when the error is properly reported by the\n // application. This suppresses these errors.\n // Note, uncomment this line for debug.\n process.on('unhandledRejection', unhandledRejection)\n const report = await factory.execute()\n process.off('unhandledRejection', unhandledRejection)\n return {\n result: report,\n }\n }\n}\n"]}
1
+ {"version":3,"file":"HttpProjectProxy.js","sourceRoot":"","sources":["../../../src/proxy/HttpProjectProxy.ts"],"names":[],"mappings":"AACA,OAAO,EAA2B,WAAW,EAAgB,MAAM,0BAA0B,CAAA;AAC7F,OAAO,EAAE,QAAQ,EAAE,MAAM,kCAAkC,CAAA;AAC3D,OAAO,EAAE,mBAAmB,EAAE,MAAM,wCAAwC,CAAA;AAC5E,O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QAC5D,wEAAwE;QACxE,yEAAyE;QACzE,6CAA6C;QAC7C,uCAAuC;QACvC,OAAO,CAAC,EAAE,CAAC,oBAAoB,EAAE,kBAAkB,CAAC,CAAA;QACpD,MAAM,MAAM,GAAG,MAAM,OAAO,CAAC,OAAO,EAAE,CAAA;QACtC,OAAO,CAAC,GAAG,CAAC,oBAAoB,EAAE,kBAAkB,CAAC,CAAA;QACrD,OAAO;YACL,MAAM,EAAE,MAAM;SACf,CAAA;IACH,CAAC;CACF","sourcesContent":["import { IProjectRunnerOptions } from '../runtime/node/InteropInterfaces.js'\nimport { Kind as HttpProjectKind, HttpProject, IHttpProject } from '../models/HttpProject.js'\nimport { StoreSdk } from '../runtime/store/StoreSdkNode.js'\nimport { ProjectSerialRunner } from '../runtime/node/ProjectSerialRunner.js'\nimport { ProjectParallelRunner } from '../runtime/node/ProjectParallelRunner.js'\nimport Proxy, { IProxyResult } from './Proxy.js'\nimport { IProjectExecutionLog } from '../models/ProjectExecution.js'\nimport { Exception } from '../exceptions/exception.js'\n\ninterface ProxyInit {\n kind: typeof HttpProjectKind\n /**\n * Runner options.\n */\n options: IProjectRunnerOptions\n /**\n * A signal to be sent to the proxy bindings to abort the request on demand.\n */\n signal?: AbortSignal | null\n}\n\nexport interface IHttpProjectProxyInit extends ProxyInit {\n project: IHttpProject\n}\n\nexport interface IHttpProjectStoreProxyInit extends ProxyInit {\n kind: typeof HttpProjectKind\n /**\n * Project key\n */\n pid: string\n /**\n * The parent organization key.\n */\n organization: string\n}\n\n/**\n * Runs requests from an HTTP project read from the store.\n */\nexport default class HttpProjectProxy extends Proxy {\n project?: HttpProject\n options?: IProjectRunnerOptions\n\n protected async configureStore(init: IHttpProjectStoreProxyInit, token: string, baseUri: string): Promise<void> {\n const { pid, options, organization } = init\n const INVALID_REQUEST = 'Invalid request'\n const code = 'E_INVALID_REQUEST'\n if (!pid) {\n throw new Exception(INVALID_REQUEST, {\n help: 'The \"pid\" parameter is required.',\n status: 400,\n code,\n })\n }\n if (!organization) {\n throw new Exception(INVALID_REQUEST, {\n help: 'The \"organization\" parameter is required.',\n status: 400,\n code,\n })\n }\n if (!options) {\n throw new Exception(INVALID_REQUEST, {\n help: 'The \"options\" parameter is required.',\n status: 400,\n code,\n })\n }\n if (!token) {\n throw new Exception(INVALID_REQUEST, {\n help: 'Set the authentication credentials.',\n status: 400,\n code,\n })\n }\n if (!baseUri) {\n throw new Exception(INVALID_REQUEST, {\n help: 'The store uri is missing.',\n status: 400,\n code,\n })\n }\n if (!baseUri.startsWith('http')) {\n throw new Exception(INVALID_REQUEST, {\n help: 'The store uri is invalid.',\n status: 400,\n code,\n })\n }\n const sdk = new StoreSdk(baseUri)\n sdk.token = token\n let project: IHttpProject\n try {\n const data = await sdk.file.readMedia(organization, pid)\n project = data.media as IHttpProject\n } catch (cause) {\n const e = cause as Error\n throw new Exception(e.message, { status: 400 })\n }\n if (project.key !== pid) {\n throw new Exception(`Unable to read the project.`, { status: 500 })\n }\n this.options = options\n this.project = new HttpProject(project)\n }\n\n protected async configureProject(init: IHttpProjectProxyInit): Promise<void> {\n const { project, options } = init\n const INVALID_REQUEST = 'Invalid request'\n const code = 'E_INVALID_REQUEST'\n if (!options) {\n throw new Exception(INVALID_REQUEST, {\n help: 'The \"options\" parameter is required.',\n status: 400,\n code,\n })\n }\n if (!project) {\n throw new Exception(INVALID_REQUEST, {\n help: 'The \"project\" parameter is required.',\n status: 400,\n code,\n })\n }\n this.options = options\n this.project = new HttpProject(project)\n }\n\n async configure(\n init: IHttpProjectProxyInit | IHttpProjectStoreProxyInit,\n token?: string,\n baseUri?: string\n ): Promise<void> {\n const typedStore = init as IHttpProjectStoreProxyInit\n if (typeof typedStore.pid === 'string') {\n return this.configureStore(typedStore, token as string, baseUri as string)\n }\n const typedProject = init as IHttpProjectProxyInit\n return this.configureProject(typedProject)\n }\n\n async execute(): Promise<IProxyResult<IProjectExecutionLog>> {\n const project = this.project as HttpProject\n const opts = this.options as IProjectRunnerOptions\n let factory: ProjectParallelRunner | ProjectSerialRunner\n if (opts.parallel) {\n factory = new ProjectParallelRunner(project, opts)\n } else {\n factory = new ProjectSerialRunner()\n factory.configure(project, opts)\n }\n\n function unhandledRejection(): void {\n //\n }\n // the executing library handles all related errors it need.\n // However, when executing a request to an unknown host Node process may\n // throw unhandled error event when the error is properly reported by the\n // application. This suppresses these errors.\n // Note, uncomment this line for debug.\n process.on('unhandledRejection', unhandledRejection)\n const report = await factory.execute()\n process.off('unhandledRejection', unhandledRejection)\n return {\n result: report,\n }\n }\n}\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"RequestProxy.d.ts","sourceRoot":"","sources":["../../../src/proxy/RequestProxy.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,IAAI,IAAI,eAAe,EAAE,MAAM,0BAA0B,CAAA;AAChF,OAAO,EAAE,qBAAqB,EAAE,MAAM,mCAAmC,CAAA;AACzE,OAAO,EAAE,cAAc,EAAE,MAAM,4BAA4B,CAAA;AAC3D,OAAO,KAAK,EAAE,EAAE,YAAY,EAAE,MAAM,YAAY,CAAA;AAChD,OAAO,EAAE,eAAe,EAAE,MAAM,gCAAgC,CAAA;AAIhE,OAAO,EAAE,WAAW,EAAE,MAAM,yBAAyB,CAAA;AACrD,OAAO,EAAE,SAAS,EAAE,MAAM,mCAAmC,CAAA;AAC7D,OAAO,EAAE,cAAc,EAAE,MAAM,uCAAuC,CAAA;AAEtE,MAAM,WAAW,iBAAiB;IAChC,IAAI,EAAE,OAAO,eAAe,CAAA;IAC5B;;OAEG;IACH,OAAO,EAAE,YAAY,CAAA;IACrB;;OAEG;IACH,aAAa,CAAC,EAAE,qBAAqB,EAAE,CAAA;IACvC;;OAEG;IACH,MAAM,CAAC,EAAE,cAAc,CAAA;IACvB;;OAEG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAA;IAClC;;OAEG;IACH,WAAW,CAAC,EAAE,eAAe,CAAA;IAC7B;;OAEG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OAEG;IACH,WAAW,CAAC,EAAE,eAAe,CAAA;IAC7B;;OAEG;IACH,KAAK,CAAC,EAAE,SAAS,EAAE,CAAA;IACnB;;OAEG;IACH,UAAU,CAAC,EAAE,cAAc,EAAE,CAAA;IAC7B;;OAEG;IACH,MAAM,CAAC,EAAE,WAAW,GAAG,IAAI,CAAA;CAC5B;AAED;;GAEG;AACH,MAAM,CAAC,OAAO,OAAO,YAAa,SAAQ,KAAK;IAC7C,IAAI,CAAC,EAAE,iBAAiB,CAAA;IAElB,SAAS,CAAC,IAAI,EAAE,iBAAiB,GAAG,OAAO,CAAC,IAAI,CAAC;IAqBjD,OAAO,IAAI,OAAO,CAAC,YAAY,CAAC,WAAW,CAAC,CAAC;CAyBpD"}
@@ -1,7 +1,7 @@
1
1
  import Proxy from './Proxy.js';
2
- import { ApiError } from '../runtime/store/Errors.js';
3
2
  import { DummyLogger } from '../lib/logging/DummyLogger.js';
4
3
  import { HttpRequestRunner } from '../runtime/http-runner/HttpRequestRunner.js';
4
+ import { Exception } from '../exceptions/exception.js';
5
5
  /**
6
6
  * Proxies a single HTTP request
7
7
  */
@@ -9,20 +9,20 @@ export default class RequestProxy extends Proxy {
9
9
  init;
10
10
  async configure(init) {
11
11
  const { request } = init;
12
+ const INVALID_REQUEST = 'Invalid request';
13
+ const code = 'E_INVALID_REQUEST';
12
14
  if (!request) {
13
- throw new ApiError({
14
- error: true,
15
- message: 'Invalid request',
16
- detail: 'The "request" parameter is required.',
17
- code: 400,
15
+ throw new Exception(INVALID_REQUEST, {
16
+ help: 'The "request" parameter is required.',
17
+ status: 400,
18
+ code,
18
19
  });
19
20
  }
20
21
  if (!request.url) {
21
- throw new ApiError({
22
- error: true,
23
- message: 'Invalid request',
24
- detail: 'The "request.url" parameter is required.',
25
- code: 400,
22
+ throw new Exception(INVALID_REQUEST, {
23
+ help: 'The "request.url" parameter is required.',
24
+ status: 400,
25
+ code,
26
26
  });
27
27
  }
28
28
  this.init = init;
@@ -1 +1 @@
1
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CAAC,MAAM,GAAG,IAAI,WAAW,EAAE,CAAA;QAClC,OAAO,CAAC,MAAM,GAAG,EAAE,GAAG,MAAM,EAAE,OAAO,EAAE,IAAI,EAAoB,CAAA;QAC/D,IAAI,KAAK,CAAC,OAAO,CAAC,aAAa,CAAC,IAAI,aAAa,CAAC,MAAM,EAAE,CAAC;YACzD,OAAO,CAAC,aAAa,GAAG,aAAa,CAAA;QACvC,CAAC;QACD,IAAI,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,IAAI,KAAK,CAAC,MAAM,EAAE,CAAC;YACzC,OAAO,CAAC,KAAK,GAAG,KAAK,CAAA;QACvB,CAAC;QACD,IAAI,KAAK,CAAC,OAAO,CAAC,UAAU,CAAC,IAAI,UAAU,CAAC,MAAM,EAAE,CAAC;YACnD,OAAO,CAAC,UAAU,GAAG,UAAU,CAAA;QACjC,CAAC;QACD,IAAI,WAAW,EAAE,CAAC;YAChB,OAAO,CAAC,YAAY,GAAG,CAAC,WAAW,CAAC,CAAA;QACtC,CAAC;QACD,MAAM,MAAM,GAAG,MAAM,OAAO,CAAC,GAAG,CAAC,OAAO,CAAC,CAAA;QACzC,OAAO;YACL,MAAM,EAAE,MAAM;YACd,SAAS;SACV,CAAA;IACH,CAAC;CACF","sourcesContent":["import { IHttpRequest, Kind as HttpRequestKind } from '../models/HttpRequest.js'\nimport { IRequestAuthorization } from '../models/RequestAuthorization.js'\nimport { IRequestConfig } from '../models/RequestConfig.js'\nimport Proxy, { IProxyResult } from './Proxy.js'\nimport { HttpCertificate } from '../models/ClientCertificate.js'\nimport { ApiError } from '../runtime/store/Errors.js'\nimport { DummyLogger } from '../lib/logging/DummyLogger.js'\nimport { HttpRequestRunner } from '../runtime/http-runner/HttpRequestRunner.js'\nimport { IRequestLog } from '../models/RequestLog.js'\nimport { IHttpFlow } from '../models/http-flows/HttpFlows.js'\nimport { IHttpAssertion } from '../models/http-flows/HttpAssertion.js'\n\nexport interface IRequestProxyInit {\n kind: typeof HttpRequestKind\n /**\n * The request to execute.\n */\n request: IHttpRequest\n /**\n * The authorization data to apply.\n */\n authorization?: IRequestAuthorization[]\n /**\n * The request configuration.\n */\n config?: IRequestConfig\n /**\n * The list of execution variables to use with the request.\n */\n variables?: Record<string, string>\n /**\n * The certificate data to use with the request.\n */\n certificate?: HttpCertificate\n /**\n * The request flows to execute with the request.\n */\n flows?: IHttpFlow[]\n /**\n * Assertions to execute with the request.\n */\n assertions?: IHttpAssertion[]\n /**\n * A signal to be sent to the proxy bindings to abort the request on demand.\n */\n signal?: AbortSignal | null\n}\n\n/**\n * Proxies a single HTTP request\n */\nexport default class RequestProxy extends Proxy {\n init?: IRequestProxyInit\n\n async configure(init: IRequestProxyInit): Promise<void> {\n const { request } = init\n if (!request) {\n throw new ApiError({\n error: true,\n message: 'Invalid request',\n detail: 'The \"request\" parameter is required.',\n code: 400,\n })\n }\n if (!request.url) {\n throw new ApiError({\n error: true,\n message: 'Invalid request',\n detail: 'The \"request.url\" parameter is required.',\n code: 400,\n })\n }\n this.init = init\n }\n\n async execute(): Promise<IProxyResult<IRequestLog>> {\n const data = this.init as IRequestProxyInit\n const { request, authorization, certificate, config = {}, variables = {}, flows, assertions } = data\n const factory = new HttpRequestRunner()\n factory.variables = variables\n factory.logger = new DummyLogger()\n factory.config = { ...config, enabled: true } as IRequestConfig\n if (Array.isArray(authorization) && authorization.length) {\n factory.authorization = authorization\n }\n if (Array.isArray(flows) && flows.length) {\n factory.flows = flows\n }\n if (Array.isArray(assertions) && assertions.length) {\n factory.assertions = assertions\n }\n if (certificate) {\n factory.certificates = [certificate]\n }\n const result = await factory.run(request)\n return {\n result: result,\n variables,\n }\n }\n}\n"]}
1
+ {"version":3,"file":"RequestProxy.js","sourceRoot":"","sources":["../../../src/proxy/RequestProxy.ts"],"names":[],"mappings":"AAGA,OAAO,KAAuB,MAAM,YAAY,CAAA;AAEhD,OAAO,EAAE,WAAW,EAAE,MAAM,+BAA+B,CAAA;AAC3D,OAAO,EAAE,iBAAiB,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IAAI,aAAa,CAAC,MAAM,EAAE,CAAC;YACzD,OAAO,CAAC,aAAa,GAAG,aAAa,CAAA;QACvC,CAAC;QACD,IAAI,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC,IAAI,KAAK,CAAC,MAAM,EAAE,CAAC;YACzC,OAAO,CAAC,KAAK,GAAG,KAAK,CAAA;QACvB,CAAC;QACD,IAAI,KAAK,CAAC,OAAO,CAAC,UAAU,CAAC,IAAI,UAAU,CAAC,MAAM,EAAE,CAAC;YACnD,OAAO,CAAC,UAAU,GAAG,UAAU,CAAA;QACjC,CAAC;QACD,IAAI,WAAW,EAAE,CAAC;YAChB,OAAO,CAAC,YAAY,GAAG,CAAC,WAAW,CAAC,CAAA;QACtC,CAAC;QACD,MAAM,MAAM,GAAG,MAAM,OAAO,CAAC,GAAG,CAAC,OAAO,CAAC,CAAA;QACzC,OAAO;YACL,MAAM,EAAE,MAAM;YACd,SAAS;SACV,CAAA;IACH,CAAC;CACF","sourcesContent":["import { IHttpRequest, Kind as HttpRequestKind } from '../models/HttpRequest.js'\nimport { IRequestAuthorization } from '../models/RequestAuthorization.js'\nimport { IRequestConfig } from '../models/RequestConfig.js'\nimport Proxy, { IProxyResult } from './Proxy.js'\nimport { HttpCertificate } from '../models/ClientCertificate.js'\nimport { DummyLogger } from '../lib/logging/DummyLogger.js'\nimport { HttpRequestRunner } from '../runtime/http-runner/HttpRequestRunner.js'\nimport { IRequestLog } from '../models/RequestLog.js'\nimport { IHttpFlow } from '../models/http-flows/HttpFlows.js'\nimport { IHttpAssertion } from '../models/http-flows/HttpAssertion.js'\nimport { Exception } from '../exceptions/exception.js'\n\nexport interface IRequestProxyInit {\n kind: typeof HttpRequestKind\n /**\n * The request to execute.\n */\n request: IHttpRequest\n /**\n * The authorization data to apply.\n */\n authorization?: IRequestAuthorization[]\n /**\n * The request configuration.\n */\n config?: IRequestConfig\n /**\n * The list of execution variables to use with the request.\n */\n variables?: Record<string, string>\n /**\n * The certificate data to use with the request.\n */\n certificate?: HttpCertificate\n /**\n * The request flows to execute with the request.\n */\n flows?: IHttpFlow[]\n /**\n * Assertions to execute with the request.\n */\n assertions?: IHttpAssertion[]\n /**\n * A signal to be sent to the proxy bindings to abort the request on demand.\n */\n signal?: AbortSignal | null\n}\n\n/**\n * Proxies a single HTTP request\n */\nexport default class RequestProxy extends Proxy {\n init?: IRequestProxyInit\n\n async configure(init: IRequestProxyInit): Promise<void> {\n const { request } = init\n const INVALID_REQUEST = 'Invalid request'\n const code = 'E_INVALID_REQUEST'\n if (!request) {\n throw new Exception(INVALID_REQUEST, {\n help: 'The \"request\" parameter is required.',\n status: 400,\n code,\n })\n }\n if (!request.url) {\n throw new Exception(INVALID_REQUEST, {\n help: 'The \"request.url\" parameter is required.',\n status: 400,\n code,\n })\n }\n this.init = init\n }\n\n async execute(): Promise<IProxyResult<IRequestLog>> {\n const data = this.init as IRequestProxyInit\n const { request, authorization, certificate, config = {}, variables = {}, flows, assertions } = data\n const factory = new HttpRequestRunner()\n factory.variables = variables\n factory.logger = new DummyLogger()\n factory.config = { ...config, enabled: true } as IRequestConfig\n if (Array.isArray(authorization) && authorization.length) {\n factory.authorization = authorization\n }\n if (Array.isArray(flows) && flows.length) {\n factory.flows = flows\n }\n if (Array.isArray(assertions) && assertions.length) {\n factory.assertions = assertions\n }\n if (certificate) {\n factory.certificates = [certificate]\n }\n const result = await factory.run(request)\n return {\n result: result,\n variables,\n }\n }\n}\n"]}
@@ -1 +1 @@
1
- {"version":3,"file":"DataCatalogSdk.d.ts","sourceRoot":"","sources":["../../../../src/runtime/store/DataCatalogSdk.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,OAAO,EAKP,UAAU,EACX,MAAM,cAAc,CAAA;AACrB,OAAO,EAAE,iBAAiB,EAAE,kBAAkB,EAAE,mBAAmB,EAAE,MAAM,4BAA4B,CAAA;AACvG,OAAO,KAAK,EACV,iBAAiB,EACjB,4BAA4B,EAC5B,gBAAgB,EAChB,iBAAiB,EAClB,MAAM,6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