@qawolf/ci-sdk 0.15.8 → 0.17.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 (64) hide show
  1. package/README.md +261 -23
  2. package/dist/cjs/lib/api/generate-signed-url-for-team-storage.d.ts +13 -0
  3. package/dist/cjs/lib/api/generate-signed-url-for-team-storage.d.ts.map +1 -0
  4. package/dist/cjs/lib/api/generate-signed-url-for-team-storage.js +36 -0
  5. package/dist/cjs/lib/api/generate-signed-url-for-team-storage.js.map +1 -0
  6. package/dist/cjs/lib/api/index.d.ts +1 -0
  7. package/dist/cjs/lib/api/index.d.ts.map +1 -1
  8. package/dist/cjs/lib/api/index.js +1 -0
  9. package/dist/cjs/lib/api/index.js.map +1 -1
  10. package/dist/cjs/lib/api/notify-vcs-branch-build-deployed-mutation.d.ts +1 -1
  11. package/dist/cjs/lib/api/notify-vcs-branch-build-deployed-mutation.d.ts.map +1 -1
  12. package/dist/cjs/lib/api/notify-vcs-branch-build-deployed-mutation.js +22 -2
  13. package/dist/cjs/lib/api/notify-vcs-branch-build-deployed-mutation.js.map +1 -1
  14. package/dist/cjs/lib/sdk/domain/generate-signed-url-for-team-storage.d.ts +12 -0
  15. package/dist/cjs/lib/sdk/domain/generate-signed-url-for-team-storage.d.ts.map +1 -0
  16. package/dist/cjs/lib/sdk/domain/generate-signed-url-for-team-storage.js +24 -0
  17. package/dist/cjs/lib/sdk/domain/generate-signed-url-for-team-storage.js.map +1 -0
  18. package/dist/cjs/lib/sdk/domain/vcsBranchTesting/notify-vcs-branch-build-deployed.js +2 -2
  19. package/dist/cjs/lib/sdk/domain/vcsBranchTesting/notify-vcs-branch-build-deployed.js.map +1 -1
  20. package/dist/cjs/lib/sdk/index.d.ts +12 -0
  21. package/dist/cjs/lib/sdk/index.d.ts.map +1 -1
  22. package/dist/cjs/lib/sdk/index.js +8 -0
  23. package/dist/cjs/lib/sdk/index.js.map +1 -1
  24. package/dist/cjs/tests/test-lib.d.ts +6 -0
  25. package/dist/cjs/tests/test-lib.d.ts.map +1 -1
  26. package/dist/esm/lib/api/generate-signed-url-for-team-storage.d.ts +13 -0
  27. package/dist/esm/lib/api/generate-signed-url-for-team-storage.d.ts.map +1 -0
  28. package/dist/esm/lib/api/generate-signed-url-for-team-storage.js +33 -0
  29. package/dist/esm/lib/api/generate-signed-url-for-team-storage.js.map +1 -0
  30. package/dist/esm/lib/api/index.d.ts +1 -0
  31. package/dist/esm/lib/api/index.d.ts.map +1 -1
  32. package/dist/esm/lib/api/index.js +1 -0
  33. package/dist/esm/lib/api/index.js.map +1 -1
  34. package/dist/esm/lib/api/notify-vcs-branch-build-deployed-mutation.d.ts +1 -1
  35. package/dist/esm/lib/api/notify-vcs-branch-build-deployed-mutation.d.ts.map +1 -1
  36. package/dist/esm/lib/api/notify-vcs-branch-build-deployed-mutation.js +22 -2
  37. package/dist/esm/lib/api/notify-vcs-branch-build-deployed-mutation.js.map +1 -1
  38. package/dist/esm/lib/sdk/domain/generate-signed-url-for-team-storage.d.ts +12 -0
  39. package/dist/esm/lib/sdk/domain/generate-signed-url-for-team-storage.d.ts.map +1 -0
  40. package/dist/esm/lib/sdk/domain/generate-signed-url-for-team-storage.js +21 -0
  41. package/dist/esm/lib/sdk/domain/generate-signed-url-for-team-storage.js.map +1 -0
  42. package/dist/esm/lib/sdk/domain/vcsBranchTesting/notify-vcs-branch-build-deployed.js +2 -2
  43. package/dist/esm/lib/sdk/domain/vcsBranchTesting/notify-vcs-branch-build-deployed.js.map +1 -1
  44. package/dist/esm/lib/sdk/index.d.ts +12 -0
  45. package/dist/esm/lib/sdk/index.d.ts.map +1 -1
  46. package/dist/esm/lib/sdk/index.js +8 -0
  47. package/dist/esm/lib/sdk/index.js.map +1 -1
  48. package/dist/esm/tests/test-lib.d.ts +6 -0
  49. package/dist/esm/tests/test-lib.d.ts.map +1 -1
  50. package/dist/types/lib/api/generate-signed-url-for-team-storage.d.ts +13 -0
  51. package/dist/types/lib/api/generate-signed-url-for-team-storage.d.ts.map +1 -0
  52. package/dist/types/lib/api/index.d.ts +1 -0
  53. package/dist/types/lib/api/index.d.ts.map +1 -1
  54. package/dist/types/lib/api/notify-vcs-branch-build-deployed-mutation.d.ts +1 -1
  55. package/dist/types/lib/api/notify-vcs-branch-build-deployed-mutation.d.ts.map +1 -1
  56. package/dist/types/lib/sdk/domain/generate-signed-url-for-team-storage.d.ts +12 -0
  57. package/dist/types/lib/sdk/domain/generate-signed-url-for-team-storage.d.ts.map +1 -0
  58. package/dist/types/lib/sdk/index.d.ts +12 -0
  59. package/dist/types/lib/sdk/index.d.ts.map +1 -1
  60. package/dist/types/tests/test-lib.d.ts +6 -0
  61. package/dist/types/tests/test-lib.d.ts.map +1 -1
  62. package/package.json +7 -4
  63. package/.eslintrc.json +0 -27
  64. package/project.json +0 -6
package/README.md CHANGED
@@ -9,7 +9,9 @@ This package provides a TypeScript (CSM and ESM compatible) SDK
9
9
  to interact with the QA Wolf Customer-facing API.
10
10
 
11
11
  It exposes two functions associated with the two central endpoints, showcased in
12
- the examples below.
12
+ the examples below. There is also an experimental VCS Branch Testing (aka PR Testing)
13
+ feature, encapsulated in its own object, that is described at the bottom of this
14
+ document.
13
15
 
14
16
  Note that these functions do not throw. They yield a result object that
15
17
  contains the outcome of the operation. This outcome should be scrutinized
@@ -83,34 +85,261 @@ const { pollCiGreenlightStatus } = makeQaWolfSdk({
83
85
  })();
84
86
  ```
85
87
 
86
- ## Example: pull request testing
87
-
88
- > :warning: This section is not covered by SemVer and will change.
88
+ ## Example: Upload Run Input Artifacts
89
89
 
90
90
  ```ts
91
- const details: {
92
- baseEnvironmentId: string | undefined;
93
- branch: string;
94
- commitUrl: string;
95
- deploymentUrl: string | undefined;
96
- pr: { number: number; title: string } | undefined;
97
- qaWolfTeamId: string;
98
- // company/repository
99
- repoFullName: string;
100
- sha: string;
101
- variables: { [key: string]: string };
102
- } = {};
103
- const result = await sdk.experimental_testPreview(details);
104
- if (result.outcome !== "success") {
105
- console.error(result);
106
- throw Error("Creating a test failed");
91
+ import { type DeployConfig, makeQaWolfSdk } from "@qawolf/ci-sdk";
92
+ import fs from "fs/promises";
93
+ import path from "path";
94
+
95
+ const { generateSignedUrlForTempTeamStorage, attemptNotifyDeploy } =
96
+ makeQaWolfSdk({
97
+ apiKey: "qawolf_xxxxx",
98
+ });
99
+
100
+ (async () => {
101
+ const playgroundFileLocation = await uploadRunArtifact("");
102
+
103
+ if (playgroundFileLocation) {
104
+ const deployConfig: DeployConfig = {
105
+ branch: undefined,
106
+ commitUrl: undefined,
107
+ deduplicationKey: undefined,
108
+ deploymentType: undefined,
109
+ deploymentUrl: undefined,
110
+ hostingService: undefined,
111
+ sha: undefined,
112
+ variables: {
113
+ RUN_INPUT_PATH: playgroundFileLocation,
114
+ },
115
+ };
116
+
117
+ const result = await attemptNotifyDeploy(deployConfig);
118
+ if (result.outcome !== "success") {
119
+ // Fail the job.
120
+ process.exit(1);
121
+ }
122
+ const runId = result.runId;
123
+ }
124
+ })();
125
+
126
+ async function uploadRunArtifact(filePath: string): Promise<string> {
127
+ const fileName = path.basename(filePath);
128
+
129
+ const signedUrlResponse = await generateSignedUrlForTempTeamStorage({
130
+ destinationFilePath: fileName,
131
+ });
132
+
133
+ if (
134
+ signedUrlResponse?.success &&
135
+ signedUrlResponse.playgroundFileLocation &&
136
+ signedUrlResponse.uploadUrl
137
+ ) {
138
+ const fileBuffer = await fs.readFile(filePath);
139
+ const url = signedUrlResponse.uploadUrl;
140
+
141
+ try {
142
+ const response = await fetch(url, {
143
+ method: "PUT",
144
+ body: fileBuffer,
145
+ headers: {
146
+ "Content-Type": "application/octet-stream",
147
+ },
148
+ });
149
+
150
+ if (!response.ok) {
151
+ return "";
152
+ }
153
+ } catch (error) {
154
+ return "";
155
+ }
156
+ return signedUrlResponse.playgroundFileLocation;
157
+ }
158
+ return "";
107
159
  }
108
160
  ```
109
161
 
110
- Then, after the PR has been closed:
162
+ <a name="vcs-branch-testing"></a>
163
+
164
+ ## VCS Branch Testing (Experimental)
165
+
166
+ > ⚠️ This section is not covered by SemVer and will change.
167
+
168
+ > ℹ️ This feature must be activated by QA Wolf. Please reach out to a QA Wolf
169
+ > representative to enable it, and help you with the setup.
170
+
171
+ ### Highlights and Definitions
172
+
173
+ VCS Branch Testing allows you to set up QA Wolf ephemeral environments associated with
174
+ preview deployments (builds) of your product, which code is hosted in VCS branches (e.g.
175
+ Git branches). It can be understood as "PR Testing", however the SDK does not need
176
+ the concept of PR or MR to operate.
177
+
178
+ > ℹ️ Read our [introduction to VCS Branch Testing](https://qawolf.notion.site/VCS-Branch-Testing-45be5d10d93249aeb8c1f995d26356ec?pvs=4) to get familiar with core concepts. We also provide [a more detailed SDK guide over here](https://qawolf.notion.site/qawolf-ci-sdk-VCS-Branch-Testing-df701e8742b84be39632d7284c926491?pvs=74).
179
+
180
+ ### Usage
181
+
182
+ This SDK exposes an experimental VCS Branch Testing object:
183
+
184
+ ```ts
185
+ import { makeQaWolfSdk } from "@qawolf/ci-sdk";
186
+
187
+ const vcsBranchTestingSdk = makeQaWolfSdk({
188
+ apiKey: "qawolf_xxxxx",
189
+ }).experimental_vcsBranchTesting;
190
+ ```
191
+
192
+ The above object contains the following methods:
193
+
194
+ - `notifyVCSBranchBuildDeployed`;
195
+ - `notifyVCSBranchMergeCanceled`;
196
+ - `notifyVCSBranchMergeCompleted`.
197
+
198
+ #### Notify Build Deployed `notifyVCSBranchBuildDeployed`
199
+
200
+ ```ts
201
+ import {
202
+ makeQaWolfSdk,
203
+ arbitraryStringToEnvironmentAlias,
204
+ } from "@qawolf/ci-sdk";
205
+
206
+ const { notifyVCSBranchBuildDeployed } = makeQaWolfSdk({
207
+ apiKey: "qawolf_xxxxx",
208
+ }).experimental_vcsBranchTesting;
209
+
210
+ // Mappings let QA Wolf know how to associate base VCS branches to environments.
211
+ const baseEnvironmentsMapping = [
212
+ {
213
+ environmentAlias: "develop",
214
+ vcsBranch: "main",
215
+ },
216
+ ];
217
+
218
+ (async () => {
219
+ const baseVcsBranch = "main";
220
+ const headVcsBranch = "feature/foo";
221
+ const headPreviewUrl = "https://feature-foo.example.com";
222
+ const headVcsCommitId = "abcdef";
223
+ // Optional. It will show up in the UI when provided. If an integration with
224
+ // a code hosting service is already set up, you don't need to provide this field.
225
+ const optionalHeadCommitUrl = "https://.../commits/abcdef";
226
+ // Optional. It is required for a code hosting service integration to function
227
+ // properly. When that is the case, comments will be posted in the PR/MR describing
228
+ // the outcome of tests in the head environment.
229
+ const optionalPullOrMergeRequestNumber = 123;
230
+ // The alias must be stable for the lifetime of the VCS Branch / Environment.
231
+ // It also should be unique across your organization, accounting for different
232
+ // repositories.
233
+ const headEnvironmentAlias = arbitraryStringToEnvironmentAlias(
234
+ `org/repo/${headVcsBranch}`,
235
+ );
236
+ // The name of the environment, as it will show-up in the QA Wolf UI.
237
+ const headEnvironmentName = `org/repo/${headVcsBranch}`;
238
+ // Environment variables are not optional. There must be at least one locator
239
+ // for the deployed application. Since this deployment is entirely handled by
240
+ // customers, we cannot provide more generic guidance.
241
+ const headEnvironmentVariables = {
242
+ URL: headPreviewUrl,
243
+ };
244
+ // Obviously, configuration object should be adapted to your needs, and
245
+ // most are dynamic and shall be derived from context. This is just an example.
246
+ const { outcome } = await notifyVCSBranchBuildDeployed({
247
+ baseEnvironmentsMapping,
248
+ baseVcsBranch: "main",
249
+ headEnvironmentAlias,
250
+ // If you are not sure how to build the environment name, just use the
251
+ // alias. This name will show up in the UI though.
252
+ headEnvironmentName,
253
+ headVcsBranch,
254
+ headVcsCommitId,
255
+ headCommitUrl: optionalHeadCommitUrl,
256
+ headEnvironmentVariables,
257
+ pullOrMergeRequestNumber: optionalPullOrMergeRequestNumber,
258
+ });
259
+ if (outcome !== "success") {
260
+ // Fail the job.
261
+ process.exit(1);
262
+ }
263
+ // Continue CI.
264
+ })();
265
+ ```
266
+
267
+ #### Notify Merge Canceled `notifyVCSBranchMergeCanceled`
268
+
269
+ ```ts
270
+ import { makeQaWolfSdk } from "@qawolf/ci-sdk";
271
+
272
+ const { notifyVCSBranchMergeCanceled } = makeQaWolfSdk({
273
+ apiKey: "qawolf_xxxxx",
274
+ }).experimental_vcsBranchTesting;
275
+
276
+ (async () => {
277
+ const headVcsBranch = "feature/foo";
278
+ // The alias must be stable for the lifetime of the VCS Branch / Environment.
279
+ // It also should be unique across your organization, accounting for different
280
+ // repositories.
281
+ const headEnvironmentAlias = arbitraryStringToEnvironmentAlias(
282
+ `org/repo/${headVcsBranch}`,
283
+ );
284
+ const result = await notifyVCSBranchMergeCanceled({
285
+ headEnvironmentAlias,
286
+ });
287
+ if (result.outcome !== "success") {
288
+ if (result.abortReason === "head-environment-not-found") {
289
+ console.warn(
290
+ `Head environment not found. Skipping! The QA Wolf environment was either never created or it was manually deleted.`,
291
+ );
292
+ return;
293
+ }
294
+ // Fail the job.
295
+ process.exit(1);
296
+ }
297
+ // Continue CI.
298
+ })();
299
+ ```
300
+
301
+ ### Notify Merge Completed `notifyVCSBranchMergeCompleted`
302
+
303
+ ```ts
304
+ import {
305
+ makeQaWolfSdk,
306
+ arbitraryStringToEnvironmentAlias,
307
+ } from "@qawolf/ci-sdk";
308
+
309
+ const { notifyVCSBranchMergeCompleted } = makeQaWolfSdk({
310
+ apiKey: "qawolf_xxxxx",
311
+ }).experimental_vcsBranchTesting;
111
312
 
112
- ```js
113
- await sdk.experimental_removeEnvironment({ branch: "" });
313
+ // Mappings let QA Wolf know how to associate base VCS branches to environments.
314
+ const baseEnvironmentsMapping = [
315
+ {
316
+ environmentAlias: "develop",
317
+ vcsBranch: "main",
318
+ },
319
+ ];
320
+
321
+ (async () => {
322
+ const headVcsBranch = "feature/foo";
323
+ // The alias must be stable for the lifetime of the VCS Branch / Environment.
324
+ // It also should be unique across your organization, accounting for different
325
+ // repositories.
326
+ const headEnvironmentAlias = arbitraryStringToEnvironmentAlias(
327
+ `org/repo/${headVcsBranch}`,
328
+ );
329
+ const baseVcsBranch = "main";
330
+
331
+ const { outcome } = await notifyVCSBranchMergeCompleted({
332
+ baseEnvironmentsMapping,
333
+ headVcsBranch,
334
+ headEnvironmentAlias,
335
+ baseVcsBranch,
336
+ });
337
+ if (outcome !== "success") {
338
+ // Fail the job.
339
+ process.exit(1);
340
+ }
341
+ // Continue CI.
342
+ })();
114
343
  ```
115
344
 
116
345
  ## Requirements
@@ -147,6 +376,15 @@ an up-to-date API usage version.
147
376
 
148
377
  # Changelog
149
378
 
379
+ ## v0.17.0
380
+
381
+ - Add generateSignedUrlForTempTeamStorage function to be used in customer's CI pipeline.
382
+
383
+ ## v0.16.0
384
+
385
+ - Document experimental VCS Branch/PR Testing features.
386
+ - Deprecate `experimental_testPreview` and `experimental_removeEnvironment`. These methods will be removed in the next release.
387
+
150
388
  ## v0.15.8
151
389
 
152
390
  - Fix vcsBranchTesting error handling.
@@ -0,0 +1,13 @@
1
+ import { type ApiConfig } from "../api-types";
2
+ import { type SdkDependencies } from "../sdk/dependencies";
3
+ export type GenerateSignedUrlForTeamStorageConfig = {
4
+ destinationFilePath: string | undefined;
5
+ };
6
+ export type GenerateSignedUrlForTeamStorageResponse = {
7
+ fileLocation?: string;
8
+ playgroundFileLocation?: string;
9
+ signedUrl?: string;
10
+ success: boolean;
11
+ };
12
+ export declare function callGenerateSignedUrlForTempTeamStorage({ apiKey, serviceBase }: ApiConfig, { destinationFilePath }: Partial<GenerateSignedUrlForTeamStorageConfig>, { fetch: localFetch }: SdkDependencies): Promise<GenerateSignedUrlForTeamStorageResponse>;
13
+ //# sourceMappingURL=generate-signed-url-for-team-storage.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"generate-signed-url-for-team-storage.d.ts","sourceRoot":"","sources":["../../../../src/lib/api/generate-signed-url-for-team-storage.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,SAAS,EAAE,MAAM,cAAc,CAAC;AAC9C,OAAO,EAAE,KAAK,eAAe,EAAE,MAAM,qBAAqB,CAAC;AAE3D,MAAM,MAAM,qCAAqC,GAAG;IAClD,mBAAmB,EAAE,MAAM,GAAG,SAAS,CAAC;CACzC,CAAC;AAEF,MAAM,MAAM,uCAAuC,GAAG;IACpD,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,sBAAsB,CAAC,EAAE,MAAM,CAAC;IAChC,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,OAAO,EAAE,OAAO,CAAC;CAClB,CAAC;AAEF,wBAAsB,uCAAuC,CAC3D,EAAE,MAAM,EAAE,WAAW,EAAE,EAAE,SAAS,EAClC,EAAE,mBAAmB,EAAE,EAAE,OAAO,CAAC,qCAAqC,CAAC,EACvE,EAAE,KAAK,EAAE,UAAU,EAAE,EAAE,eAAe,GACrC,OAAO,CAAC,uCAAuC,CAAC,CAoClD"}
@@ -0,0 +1,36 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.callGenerateSignedUrlForTempTeamStorage = callGenerateSignedUrlForTempTeamStorage;
4
+ async function callGenerateSignedUrlForTempTeamStorage({ apiKey, serviceBase }, { destinationFilePath }, { fetch: localFetch }) {
5
+ try {
6
+ const response = await localFetch(new URL(`${serviceBase}/api/v0/team-storage-signed-url?file=${destinationFilePath}`), {
7
+ headers: {
8
+ Authorization: `Bearer ${apiKey}`,
9
+ "Content-Type": "application/json",
10
+ },
11
+ method: "GET",
12
+ });
13
+ if (response.status === 200) {
14
+ const json = (await response.json());
15
+ return {
16
+ fileLocation: json.fileLocation,
17
+ playgroundFileLocation: json.playgroundFileLocation,
18
+ signedUrl: json.signedUrl,
19
+ success: true,
20
+ };
21
+ }
22
+ else {
23
+ const error = await response.text();
24
+ console.log(`ERROR: ${error}`);
25
+ return {
26
+ success: false,
27
+ };
28
+ }
29
+ }
30
+ catch (e) {
31
+ return {
32
+ success: false,
33
+ };
34
+ }
35
+ }
36
+ //# sourceMappingURL=generate-signed-url-for-team-storage.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"generate-signed-url-for-team-storage.js","sourceRoot":"","sources":["../../../../src/lib/api/generate-signed-url-for-team-storage.ts"],"names":[],"mappings":";;AAcA,0FAwCC;AAxCM,KAAK,UAAU,uCAAuC,CAC3D,EAAE,MAAM,EAAE,WAAW,EAAa,EAClC,EAAE,mBAAmB,EAAkD,EACvE,EAAE,KAAK,EAAE,UAAU,EAAmB;IAEtC,IAAI,CAAC;QACH,MAAM,QAAQ,GAAG,MAAM,UAAU,CAC/B,IAAI,GAAG,CACL,GAAG,WAAW,wCAAwC,mBAAmB,EAAE,CAC5E,EACD;YACE,OAAO,EAAE;gBACP,aAAa,EAAE,UAAU,MAAM,EAAE;gBACjC,cAAc,EAAE,kBAAkB;aACnC;YACD,MAAM,EAAE,KAAK;SACd,CACF,CAAC;QAEF,IAAI,QAAQ,CAAC,MAAM,KAAK,GAAG,EAAE,CAAC;YAC5B,MAAM,IAAI,GACR,CAAC,MAAM,QAAQ,CAAC,IAAI,EAAE,CAAqD,CAAC;YAC9E,OAAO;gBACL,YAAY,EAAE,IAAI,CAAC,YAAY;gBAC/B,sBAAsB,EAAE,IAAI,CAAC,sBAAsB;gBACnD,SAAS,EAAE,IAAI,CAAC,SAAS;gBACzB,OAAO,EAAE,IAAI;aACL,CAAC;QACb,CAAC;aAAM,CAAC;YACN,MAAM,KAAK,GAAG,MAAM,QAAQ,CAAC,IAAI,EAAE,CAAC;YACpC,OAAO,CAAC,GAAG,CAAC,UAAU,KAAK,EAAE,CAAC,CAAC;YAC/B,OAAO;gBACL,OAAO,EAAE,KAAK;aACN,CAAC;QACb,CAAC;IACH,CAAC;IAAC,OAAO,CAAC,EAAE,CAAC;QACX,OAAO;YACL,OAAO,EAAE,KAAK;SACN,CAAC;IACb,CAAC;AACH,CAAC"}
@@ -1,3 +1,4 @@
1
1
  export * from "./ci-greenlight.js";
2
2
  export * from "./deploy.js";
3
+ export * from "./generate-signed-url-for-team-storage.js";
3
4
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/lib/api/index.ts"],"names":[],"mappings":"AAAA,cAAc,oBAAoB,CAAC;AACnC,cAAc,aAAa,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/lib/api/index.ts"],"names":[],"mappings":"AAAA,cAAc,oBAAoB,CAAC;AACnC,cAAc,aAAa,CAAC;AAC5B,cAAc,2CAA2C,CAAC"}
@@ -3,4 +3,5 @@ Object.defineProperty(exports, "__esModule", { value: true });
3
3
  const tslib_1 = require("tslib");
4
4
  tslib_1.__exportStar(require("./ci-greenlight.js"), exports);
5
5
  tslib_1.__exportStar(require("./deploy.js"), exports);
6
+ tslib_1.__exportStar(require("./generate-signed-url-for-team-storage.js"), exports);
6
7
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/lib/api/index.ts"],"names":[],"mappings":";;;AAAA,6DAAmC;AACnC,sDAA4B"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/lib/api/index.ts"],"names":[],"mappings":";;;AAAA,6DAAmC;AACnC,sDAA4B;AAC5B,oFAA0D"}
@@ -13,7 +13,7 @@ export interface NotifyVCSBranchBuildDeployedMutationInput {
13
13
  pullOrMergeRequestNumber: number | undefined;
14
14
  }
15
15
  export type NotifyVCSBranchBuildDeployedResponseSchema = {
16
- codeHostingServiceInstallationPlatform: "GitHub" | "GitLab" | undefined;
16
+ codeHostingServiceInstallationPlatform: "GitHub" | "GitLab" | null;
17
17
  outcome: "success";
18
18
  runId: string;
19
19
  } | {
@@ -1 +1 @@
1
- {"version":3,"file":"notify-vcs-branch-build-deployed-mutation.d.ts","sourceRoot":"","sources":["../../../../src/lib/api/notify-vcs-branch-build-deployed-mutation.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,SAAS,EAAE,MAAM,cAAc,CAAC;AAC9C,OAAO,EAAE,KAAK,eAAe,EAAE,MAAM,qBAAqB,CAAC;AAC3D,OAAO,EAAE,KAAK,eAAe,EAAiB,MAAM,WAAW,CAAC;AAEhE,MAAM,WAAW,yCAAyC;IACxD,oBAAoB,EAAE,MAAM,CAAC;IAC7B,gBAAgB,EAAE,MAAM,GAAG,SAAS,CAAC;IACrC,oBAAoB,EAAE,MAAM,CAAC;IAC7B,mBAAmB,EAAE,MAAM,CAAC;IAC5B,wBAAwB,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IACjD,aAAa,EAAE,MAAM,GAAG,SAAS,CAAC;IAClC,eAAe,EAAE,MAAM,CAAC;IACxB,gBAAgB,EAAE,MAAM,GAAG,SAAS,CAAC;IACrC,wBAAwB,EAAE,MAAM,GAAG,SAAS,CAAC;CAC9C;AAeD,MAAM,MAAM,0CAA0C,GAClD;IACE,sCAAsC,EAAE,QAAQ,GAAG,QAAQ,GAAG,SAAS,CAAC;IACxE,OAAO,EAAE,SAAS,CAAC;IACnB,KAAK,EAAE,MAAM,CAAC;CACf,GACD;IACE,WAAW,EACP,eAAe,GACf,4BAA4B,GAC5B,wBAAwB,GACxB,wBAAwB,GACxB,0CAA0C,GAC1C,qBAAqB,CAAC;IAC1B,cAAc,EAAE,MAAM,CAAC;IACvB,OAAO,EAAE,QAAQ,CAAC;CACnB,CAAC;AAEN,wBAAsB,wCAAwC,CAC5D,IAAI,EAAE,eAAe,EACrB,SAAS,EAAE,SAAS,EACpB,EACE,oBAAoB,EACpB,gBAAgB,EAChB,oBAAoB,EACpB,mBAAmB,EACnB,wBAAwB,EACxB,eAAe,EACf,gBAAgB,EAChB,aAAa,EACb,wBAAwB,GACzB,EAAE,yCAAyC,wEAiC7C"}
1
+ {"version":3,"file":"notify-vcs-branch-build-deployed-mutation.d.ts","sourceRoot":"","sources":["../../../../src/lib/api/notify-vcs-branch-build-deployed-mutation.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,SAAS,EAAE,MAAM,cAAc,CAAC;AAC9C,OAAO,EAAE,KAAK,eAAe,EAAE,MAAM,qBAAqB,CAAC;AAC3D,OAAO,EAAE,KAAK,eAAe,EAAiB,MAAM,WAAW,CAAC;AAEhE,MAAM,WAAW,yCAAyC;IACxD,oBAAoB,EAAE,MAAM,CAAC;IAC7B,gBAAgB,EAAE,MAAM,GAAG,SAAS,CAAC;IACrC,oBAAoB,EAAE,MAAM,CAAC;IAC7B,mBAAmB,EAAE,MAAM,CAAC;IAC5B,wBAAwB,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IACjD,aAAa,EAAE,MAAM,GAAG,SAAS,CAAC;IAClC,eAAe,EAAE,MAAM,CAAC;IACxB,gBAAgB,EAAE,MAAM,GAAG,SAAS,CAAC;IACrC,wBAAwB,EAAE,MAAM,GAAG,SAAS,CAAC;CAC9C;AAmCD,MAAM,MAAM,0CAA0C,GAClD;IACE,sCAAsC,EAAE,QAAQ,GAAG,QAAQ,GAAG,IAAI,CAAC;IACnE,OAAO,EAAE,SAAS,CAAC;IACnB,KAAK,EAAE,MAAM,CAAC;CACf,GACD;IACE,WAAW,EACP,eAAe,GACf,4BAA4B,GAC5B,wBAAwB,GACxB,wBAAwB,GACxB,0CAA0C,GAC1C,qBAAqB,CAAC;IAC1B,cAAc,EAAE,MAAM,CAAC;IACvB,OAAO,EAAE,QAAQ,CAAC;CACnB,CAAC;AAEN,wBAAsB,wCAAwC,CAC5D,IAAI,EAAE,eAAe,EACrB,SAAS,EAAE,SAAS,EACpB,EACE,oBAAoB,EACpB,gBAAgB,EAChB,oBAAoB,EACpB,mBAAmB,EACnB,wBAAwB,EACxB,eAAe,EACf,gBAAgB,EAChB,aAAa,EACb,wBAAwB,GACzB,EAAE,yCAAyC,wEAiC7C"}
@@ -4,8 +4,28 @@ exports.callNotifyVCSBranchBuildDeployedMutation = callNotifyVCSBranchBuildDeplo
4
4
  const graphql_1 = require("./graphql");
5
5
  const mutationName = "notifyVCSBranchBuildDeployed";
6
6
  const mutationGql = `
7
- mutation NotifyVCSBranchBuildDeployed($headVcsCommitId: String!, $headEnvironmentVariablesJson: String!, $baseEnvironmentAlias: String!, $headEnvironmentAlias: String!) {
8
- ${mutationName}(headVcsCommitId: $headVcsCommitId, headEnvironmentVariablesJson: $headEnvironmentVariablesJson, baseEnvironmentAlias: $baseEnvironmentAlias, headEnvironmentAlias: $headEnvironmentAlias) {
7
+ mutation NotifyVCSBranchBuildDeployed(
8
+ $headVcsCommitId: String!,
9
+ $headEnvironmentVariablesJson: String!,
10
+ $baseEnvironmentAlias: String!,
11
+ $headEnvironmentAlias: String!,
12
+ $concurrencyLimit: Int,
13
+ $headEnvironmentName: String,
14
+ $headVcsBranch: String,
15
+ $headVcsCommitUrl: String,
16
+ $pullOrMergeRequestNumber: Int
17
+ ) {
18
+ ${mutationName}(
19
+ headVcsCommitId: $headVcsCommitId,
20
+ headEnvironmentVariablesJson: $headEnvironmentVariablesJson,
21
+ baseEnvironmentAlias: $baseEnvironmentAlias,
22
+ headEnvironmentAlias: $headEnvironmentAlias,
23
+ concurrencyLimit: $concurrencyLimit,
24
+ headEnvironmentName: $headEnvironmentName,
25
+ headVcsBranch: $headVcsBranch,
26
+ headVcsCommitUrl: $headVcsCommitUrl,
27
+ pullOrMergeRequestNumber: $pullOrMergeRequestNumber
28
+ ) {
9
29
  outcome
10
30
  codeHostingServiceInstallationPlatform
11
31
  failureCode
@@ -1 +1 @@
1
- {"version":3,"file":"notify-vcs-branch-build-deployed-mutation.js","sourceRoot":"","sources":["../../../../src/lib/api/notify-vcs-branch-build-deployed-mutation.ts"],"names":[],"mappings":";;AA+CA,4FA8CC;AA3FD,uCAAgE;AAchE,MAAM,YAAY,GAAG,8BAAuC,CAAC;AAE7D,MAAM,WAAW,GAAG;;MAEd,YAAY;;;;;;;EAOhB,CAAC;AAoBI,KAAK,UAAU,wCAAwC,CAC5D,IAAqB,EACrB,SAAoB,EACpB,EACE,oBAAoB,EACpB,gBAAgB,EAChB,oBAAoB,EACpB,mBAAmB,EACnB,wBAAwB,EACxB,eAAe,EACf,gBAAgB,EAChB,aAAa,EACb,wBAAwB,GACkB;IAE5C,OAAO,IAAA,uBAAa,EAalB;QACA,SAAS;QACT,IAAI;QACJ,IAAI,EAAE,YAAY;QAClB,KAAK,EAAE,WAAW;QAClB,SAAS,EAAE;YACT,oBAAoB;YACpB,gBAAgB,EAAE,gBAAgB,IAAI,IAAI;YAC1C,oBAAoB;YACpB,mBAAmB;YACnB,4BAA4B,EAAE,IAAI,CAAC,SAAS,CAAC,wBAAwB,CAAC;YACtE,aAAa,EAAE,aAAa,IAAI,IAAI;YACpC,eAAe;YACf,gBAAgB,EAAE,gBAAgB,IAAI,IAAI;YAC1C,wBAAwB,EAAE,wBAAwB,IAAI,IAAI;SAC3D;QACD,4EAA4E;KAC7E,CAAyE,CAAC;AAC7E,CAAC"}
1
+ {"version":3,"file":"notify-vcs-branch-build-deployed-mutation.js","sourceRoot":"","sources":["../../../../src/lib/api/notify-vcs-branch-build-deployed-mutation.ts"],"names":[],"mappings":";;AAmEA,4FA8CC;AA/GD,uCAAgE;AAchE,MAAM,YAAY,GAAG,8BAAuC,CAAC;AAE7D,MAAM,WAAW,GAAG;;;;;;;;;;;;MAYd,YAAY;;;;;;;;;;;;;;;;;EAiBhB,CAAC;AAoBI,KAAK,UAAU,wCAAwC,CAC5D,IAAqB,EACrB,SAAoB,EACpB,EACE,oBAAoB,EACpB,gBAAgB,EAChB,oBAAoB,EACpB,mBAAmB,EACnB,wBAAwB,EACxB,eAAe,EACf,gBAAgB,EAChB,aAAa,EACb,wBAAwB,GACkB;IAE5C,OAAO,IAAA,uBAAa,EAalB;QACA,SAAS;QACT,IAAI;QACJ,IAAI,EAAE,YAAY;QAClB,KAAK,EAAE,WAAW;QAClB,SAAS,EAAE;YACT,oBAAoB;YACpB,gBAAgB,EAAE,gBAAgB,IAAI,IAAI;YAC1C,oBAAoB;YACpB,mBAAmB;YACnB,4BAA4B,EAAE,IAAI,CAAC,SAAS,CAAC,wBAAwB,CAAC;YACtE,aAAa,EAAE,aAAa,IAAI,IAAI;YACpC,eAAe;YACf,gBAAgB,EAAE,gBAAgB,IAAI,IAAI;YAC1C,wBAAwB,EAAE,wBAAwB,IAAI,IAAI;SAC3D;QACD,4EAA4E;KAC7E,CAAyE,CAAC;AAC7E,CAAC"}
@@ -0,0 +1,12 @@
1
+ import { type GenerateSignedUrlForTeamStorageConfig } from "../../api/generate-signed-url-for-team-storage";
2
+ import { type ApiConfig } from "../../api-types";
3
+ import { type SdkDependencies } from "../dependencies";
4
+ type GenerateSignedUrlStatus = {
5
+ fileLocation?: string;
6
+ playgroundFileLocation?: string;
7
+ success: boolean;
8
+ uploadUrl?: string;
9
+ };
10
+ export declare function generateSignedUrlForTempTeamStorage(deps: SdkDependencies, apiConfig: ApiConfig, config: GenerateSignedUrlForTeamStorageConfig): Promise<GenerateSignedUrlStatus>;
11
+ export {};
12
+ //# sourceMappingURL=generate-signed-url-for-team-storage.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"generate-signed-url-for-team-storage.d.ts","sourceRoot":"","sources":["../../../../../src/lib/sdk/domain/generate-signed-url-for-team-storage.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,qCAAqC,EAE3C,MAAM,gDAAgD,CAAC;AACxD,OAAO,EAAE,KAAK,SAAS,EAAE,MAAM,iBAAiB,CAAC;AACjD,OAAO,EAAE,KAAK,eAAe,EAAE,MAAM,iBAAiB,CAAC;AAEvD,KAAK,uBAAuB,GAAG;IAC7B,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,sBAAsB,CAAC,EAAE,MAAM,CAAC;IAChC,OAAO,EAAE,OAAO,CAAC;IACjB,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB,CAAC;AAEF,wBAAsB,mCAAmC,CACvD,IAAI,EAAE,eAAe,EACrB,SAAS,EAAE,SAAS,EACpB,MAAM,EAAE,qCAAqC,GAC5C,OAAO,CAAC,uBAAuB,CAAC,CA2BlC"}
@@ -0,0 +1,24 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.generateSignedUrlForTempTeamStorage = generateSignedUrlForTempTeamStorage;
4
+ const generate_signed_url_for_team_storage_1 = require("../../api/generate-signed-url-for-team-storage");
5
+ async function generateSignedUrlForTempTeamStorage(deps, apiConfig, config) {
6
+ const { log } = deps;
7
+ if (!config.destinationFilePath) {
8
+ log.error(`🚫 destinationFilePath is a required config parameter`);
9
+ return { success: false };
10
+ }
11
+ const responseState = await (0, generate_signed_url_for_team_storage_1.callGenerateSignedUrlForTempTeamStorage)(apiConfig, config, deps);
12
+ if (!responseState.success) {
13
+ log.error(`🚫 Failed to generate signed URL for team storage. Please contact support.`);
14
+ return { success: false };
15
+ }
16
+ log.info(`✅ Generated Signed Upload URL: ${responseState.signedUrl}.`);
17
+ return {
18
+ fileLocation: responseState.fileLocation,
19
+ playgroundFileLocation: responseState.playgroundFileLocation,
20
+ success: true,
21
+ uploadUrl: responseState.signedUrl,
22
+ };
23
+ }
24
+ //# sourceMappingURL=generate-signed-url-for-team-storage.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"generate-signed-url-for-team-storage.js","sourceRoot":"","sources":["../../../../../src/lib/sdk/domain/generate-signed-url-for-team-storage.ts"],"names":[],"mappings":";;AAcA,kFA+BC;AA7CD,yGAGwD;AAWjD,KAAK,UAAU,mCAAmC,CACvD,IAAqB,EACrB,SAAoB,EACpB,MAA6C;IAE7C,MAAM,EAAE,GAAG,EAAE,GAAG,IAAI,CAAC;IAErB,IAAI,CAAC,MAAM,CAAC,mBAAmB,EAAE,CAAC;QAChC,GAAG,CAAC,KAAK,CAAC,uDAAuD,CAAC,CAAC;QACnE,OAAO,EAAE,OAAO,EAAE,KAAK,EAAE,CAAC;IAC5B,CAAC;IAED,MAAM,aAAa,GAAG,MAAM,IAAA,8EAAuC,EACjE,SAAS,EACT,MAAM,EACN,IAAI,CACL,CAAC;IACF,IAAI,CAAC,aAAa,CAAC,OAAO,EAAE,CAAC;QAC3B,GAAG,CAAC,KAAK,CACP,4EAA4E,CAC7E,CAAC;QACF,OAAO,EAAE,OAAO,EAAE,KAAK,EAAE,CAAC;IAC5B,CAAC;IAED,GAAG,CAAC,IAAI,CAAC,kCAAkC,aAAa,CAAC,SAAS,GAAG,CAAC,CAAC;IACvE,OAAO;QACL,YAAY,EAAE,aAAa,CAAC,YAAY;QACxC,sBAAsB,EAAE,aAAa,CAAC,sBAAsB;QAC5D,OAAO,EAAE,IAAI;QACb,SAAS,EAAE,aAAa,CAAC,SAAS;KACnC,CAAC;AACJ,CAAC"}
@@ -58,12 +58,12 @@ async function runNotifyVCSBranchBuildDeployedOnce(deps, apiConfig, input) {
58
58
  }
59
59
  const result = resp.responseBody;
60
60
  if (result.outcome === "success") {
61
- const codeHostingInfo = result.codeHostingServiceInstallationPlatform === undefined
61
+ const codeHostingInfo = result.codeHostingServiceInstallationPlatform == null
62
62
  ? ""
63
63
  : `, and code hosting service integration '${result.codeHostingServiceInstallationPlatform}'.`;
64
64
  log.info(`✅ [notifyVCSBranchBuildDeployed] Success. Run was deployed with ID: '${result.runId}'${codeHostingInfo}`);
65
65
  return {
66
- codeHostingServiceInstallationType: result.codeHostingServiceInstallationPlatform,
66
+ codeHostingServiceInstallationType: result.codeHostingServiceInstallationPlatform ?? undefined,
67
67
  outcome: "success",
68
68
  runId: result.runId,
69
69
  };
@@ -1 +1 @@
1
- {"version":3,"file":"notify-vcs-branch-build-deployed.js","sourceRoot":"","sources":["../../../../../../src/lib/sdk/domain/vcsBranchTesting/notify-vcs-branch-build-deployed.ts"],"names":[],"mappings":";;AA8GA,oEAiBC;AA/HD,sHAAkH;AAElH,0CAA4C;AAE5C,yDAAkE;AAClE,uDAAgE;AAChE,uCAA0D;AAM1D,KAAK,UAAU,mCAAmC,CAChD,IAAqB,EACrB,SAAoB,EACpB,KAA+B;IAE/B,MAAM,EACJ,uBAAuB,EACvB,aAAa,EACb,oBAAoB,EACpB,mBAAmB,EACnB,wBAAwB,EACxB,eAAe,EACf,gBAAgB,EAChB,g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AAC,IAAI,EAAE,SAAS,EAAE,KAAK,CAAC;KAC3E,CAAC,CAAC;AACL,CAAC"}
1
+ {"version":3,"file":"notify-vcs-branch-build-deployed.js","sourceRoot":"","sources":["../../../../../../src/lib/sdk/domain/vcsBranchTesting/notify-vcs-branch-build-deployed.ts"],"names":[],"mappings":";;AA8GA,oEAiBC;AA/HD,sHAAkH;AAElH,0CAA4C;AAE5C,yDAAkE;AAClE,uDAAgE;AAChE,uCAA0D;AAM1D,KAAK,UAAU,mCAAmC,CAChD,IAAqB,EACrB,SAAoB,EACpB,KAA+B;IAE/B,MAAM,EACJ,uBAAuB,EACvB,aAAa,EACb,oBAAoB,EACpB,mBAAmB,EACnB,wBAAwB,EACxB,eAAe,EACf,gBAAgB,EAChB,gBAAgB,EAChB,aAAa,EACb,wBAAwB,GACzB,GAAG,KAAK,CAAC;IACV,MAAM,GAAG,GAAG,IAAI,CAAC,GAAG,CAAC;IACrB,MAAM,oBAAoB,GAAG,uBAAuB,CAAC,IAAI,CACvD,CAAC,OAAO,EAAE,EAAE,CAAC,OAAO,CAAC,SAAS,KAAK,aAAa,CACjD,EAAE,gBAAgB,CAAC;IACpB,IAAI,oBAAoB,KAAK,SAAS,EAAE,CAAC;QACvC,GAAG,CAAC,KAAK,CACP,sFAAsF,aAAa,2BAA2B;YAC5H,wEAAwE,CAC3E,CAAC;QACF,OAAO;YACL,WAAW,EAAE,iDAAiD;YAC9D,OAAO,EAAE,SAAS;SACnB,CAAC;IACJ,CAAC;IACD,IAAI,qBAAqB,GAAuB,gBAAgB,CAAC;IACjE,IAAI,OAAO,gBAAgB,KAAK,QAAQ,EAAE,CAAC;QACzC,IAAI,gBAAgB,KAAK,QAAQ,EAAE,CAAC;YAClC,qBAAqB,GAAG,CAAC,CAAC;QAC5B,CAAC;aAAM,IAAI,KAAK,CAAC,gBAAgB,CAAC,IAAI,CAAC,MAAM,CAAC,SAAS,CAAC,gBAAgB,CAAC,EAAE,CAAC;YAC1E,GAAG,CAAC,KA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MAAM,CAAC,OAAO,CAAC,CAAC;IAErC,OAAO,IAAA,2CAA0B,EAAC;QAChC,GAAG;QACH,UAAU,EAAE,8BAA8B;QAC1C,MAAM;KACP,CAAC,CAAC;AACL,CAAC;AAEM,KAAK,UAAU,4BAA4B,CAChD,IAAqB,EACrB,SAAoB,EACpB,KAA+B;IAE/B,MAAM,EAAE,UAAU,GAAG,EAAE,EAAE,GAAG,KAAK,CAAC;IAClC,OAAO,IAAA,mCAA2B,EAAC;QACjC,GAAG,EAAE,IAAI,CAAC,GAAG;QACb,UAAU;QACV,UAAU,EAAE,8BAA8B;QAC1C,qBAAqB,EAAE;YACrB,eAAe;YACf,cAAc;YACd,qBAAqB;SAC8B;QACrD,OAAO,EAAE,GAAG,EAAE,CAAC,mCAAmC,CAAC,IAAI,EAAE,SAAS,EAAE,KAAK,CAAC;KAC3E,CAAC,CAAC;AACL,CAAC"}
@@ -4,11 +4,23 @@ export declare function makeQaWolfSdk({ apiKey, serviceBase, }: {
4
4
  serviceBase?: string;
5
5
  }, { log, fetch, }?: Partial<SdkDependencies>): {
6
6
  attemptNotifyDeploy: (config: Partial<import("../api").DeployConfig>) => Promise<import("./domain/attempt-deploy").NotifyDeployStatus>;
7
+ /**
8
+ * @deprecated Use `experimental_vcsBranchTesting` instead.
9
+ */
7
10
  experimental_removeEnvironment: (config: {
8
11
  branch: string;
9
12
  }) => Promise<void>;
13
+ /**
14
+ * @deprecated Use `experimental_vcsBranchTesting` instead.
15
+ */
10
16
  experimental_testPreview: (config: import("./domain/legacy_previewTesting/index").TestPreviewParams) => Promise<import("./domain/attempt-deploy").NotifyDeployStatus>;
11
17
  experimental_vcsBranchTesting: import("./domain/vcsBranchTesting").VCSBranchTestingSDK;
18
+ generateSignedUrlForTempTeamStorage: (config: import("../api").GenerateSignedUrlForTeamStorageConfig) => Promise<{
19
+ fileLocation?: string;
20
+ playgroundFileLocation?: string;
21
+ success: boolean;
22
+ uploadUrl?: string;
23
+ }>;
12
24
  pollCiGreenlightStatus: (args_0: import("./domain/poll-ci-greenlight").PollCiGreenlightParams) => Promise<import("./domain/poll-ci-greenlight").PollCiGreenlightStatus>;
13
25
  };
14
26
  export type * from "./domain/poll-ci-greenlight";
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/lib/sdk/index.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,KAAK,eAAe,EAAE,MAAM,gBAAgB,CAAC;AAStD,wBAAgB,aAAa,CAC3B,EACE,MAAM,EACN,WAAgC,GACjC,EAAE;IACD,MAAM,EAAE,MAAM,CAAC;IACf,WAAW,CAAC,EAAE,MAAM,CAAC;CACtB,EACD,EACE,GAAsB,EACtB,KAAoB,GACrB,GAAE,OAAO,CAAC,eAAe,CAAM;;;;;;;;EA0BjC;AAED,mBAAmB,6BAA6B,CAAC;AACjD,mBAAmB,yBAAyB,CAAC;AAC7C,cAAc,iCAAiC,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/lib/sdk/index.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,KAAK,eAAe,EAAE,MAAM,gBAAgB,CAAC;AAUtD,wBAAgB,aAAa,CAC3B,EACE,MAAM,EACN,WAAgC,GACjC,EAAE;IACD,MAAM,EAAE,MAAM,CAAC;IACf,WAAW,CAAC,EAAE,MAAM,CAAC;CACtB,EACD,EACE,GAAsB,EACtB,KAAoB,GACrB,GAAE,OAAO,CAAC,eAAe,CAAM;;IAiB9B;;OAEG;;;;IAMH;;OAEG;;;;;;;;;;EAON;AAED,mBAAmB,6BAA6B,CAAC;AACjD,mBAAmB,yBAAyB,CAAC;AAC7C,cAAc,iCAAiC,CAAC"}
@@ -7,6 +7,7 @@ const fetch_1 = require("./defaults/fetch");
7
7
  const log_1 = require("./defaults/log");
8
8
  const serviceBase_1 = require("./defaults/serviceBase");
9
9
  const attempt_deploy_1 = require("./domain/attempt-deploy");
10
+ const generate_signed_url_for_team_storage_1 = require("./domain/generate-signed-url-for-team-storage");
10
11
  const index_1 = require("./domain/legacy_previewTesting/index");
11
12
  const poll_ci_greenlight_1 = require("./domain/poll-ci-greenlight");
12
13
  const vcsBranchTesting_1 = require("./domain/vcsBranchTesting");
@@ -23,9 +24,16 @@ We recommend 'undici' package for that purpose. See the Requirement section of o
23
24
  const apiConfig = { apiKey, serviceBase };
24
25
  return {
25
26
  attemptNotifyDeploy: attempt_deploy_1.attemptNotifyDeploy.bind(null, deps, apiConfig),
27
+ /**
28
+ * @deprecated Use `experimental_vcsBranchTesting` instead.
29
+ */
26
30
  experimental_removeEnvironment: index_1.removeEnvironment.bind(null, deps, apiConfig),
31
+ /**
32
+ * @deprecated Use `experimental_vcsBranchTesting` instead.
33
+ */
27
34
  experimental_testPreview: index_1.testPreview.bind(null, deps, apiConfig),
28
35
  experimental_vcsBranchTesting: (0, vcsBranchTesting_1.makeVCSBranchTestingSDK)(apiConfig, deps),
36
+ generateSignedUrlForTempTeamStorage: generate_signed_url_for_team_storage_1.generateSignedUrlForTempTeamStorage.bind(null, deps, apiConfig),
29
37
  pollCiGreenlightStatus: poll_ci_greenlight_1.pollCiGreenlightStatus.bind(null, deps, apiConfig),
30
38
  };
31
39
  }
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/lib/sdk/index.ts"],"names":[],"mappings":";;AAcA,sCAqCC;;AAlDD,oCAAiD;AACjD,4CAAgD;AAChD,wCAAkD;AAClD,wDAA4D;AAE5D,4DAA8D;AAC9D,gEAG8C;AAC9C,oEAAqE;AACrE,gEAAoE;AAEpE,SAAgB,aAAa,CAC3B,EACE,MAAM,EACN,WAAW,GAAG,gCAAkB,GAIjC,EACD,EACE,GAAG,GAAG,sBAAgB,EACtB,KAAK,GAAG,oBAAY,MACQ,EAAE;IAEhC,IAAI,OAAO,KAAK,KAAK,UAAU,EAAE,CAAC;QAChC,MAAM,IAAI,KAAK,CACb;6GACuG,CACxG,CAAC;IACJ,CAAC;IAED,MAAM,IAA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S,GAAc,EAAE,MAAM,EAAE,WAAW,EAAE,CAAC;IACrD,OAAO;QACL,mBAAmB,EAAE,oCAAmB,CAAC,IAAI,CAAC,IAAI,EAAE,IAAI,EAAE,SAAS,CAAC;QACpE;;WAEG;QACH,8BAA8B,EAAE,yBAAiB,CAAC,IAAI,CACpD,IAAI,EACJ,IAAI,EACJ,SAAS,CACV;QACD;;WAEG;QACH,wBAAwB,EAAE,mBAAW,CAAC,IAAI,CAAC,IAAI,EAAE,IAAI,EAAE,SAAS,CAAC;QACjE,6BAA6B,EAAE,IAAA,0CAAuB,EAAC,SAAS,EAAE,IAAI,CAAC;QACvE,mCAAmC,EACjC,0EAAmC,CAAC,IAAI,CAAC,IAAI,EAAE,IAAI,EAAE,SAAS,CAAC;QACjE,sBAAsB,EAAE,2CAAsB,CAAC,IAAI,CAAC,IAAI,EAAE,IAAI,EAAE,SAAS,CAAC;KAC3E,CAAC;AACJ,CAAC;AAID,0EAAgD"}
@@ -16,6 +16,12 @@ export declare function makeQaWolfSdkForTest({ apiKey }: {
16
16
  }) => Promise<void>;
17
17
  experimental_testPreview: (config: import("../lib/sdk/domain/legacy_previewTesting").TestPreviewParams) => Promise<import("../lib/sdk/index").NotifyDeployStatus>;
18
18
  experimental_vcsBranchTesting: import("../lib/sdk/index").VCSBranchTestingSDK;
19
+ generateSignedUrlForTempTeamStorage: (config: import("../lib/api").GenerateSignedUrlForTeamStorageConfig) => Promise<{
20
+ fileLocation?: string;
21
+ playgroundFileLocation?: string;
22
+ success: boolean;
23
+ uploadUrl?: string;
24
+ }>;
19
25
  pollCiGreenlightStatus: (args_0: import("../lib/sdk/index").PollCiGreenlightParams) => Promise<import("../lib/sdk/index").PollCiGreenlightStatus>;
20
26
  };
21
27
  };
@@ -1 +1 @@
1
- {"version":3,"file":"test-lib.d.ts","sourceRoot":"","sources":["../../../src/tests/test-lib.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,KAAK,sBAAsB,EAAE,MAAM,0BAA0B,CAAC;AAYvE,wBAAgB,8BAA8B,CAAC,EAAE,MAAM,EAAE,EAAE;IAAE,MAAM,EAAE,MAAM,CAAA;CAAE;;;EAiB5E;AAED,wBAAgB,oBAAoB,CAAC,EAAE,MAAM,EAAE,EAAE;IAAE,MAAM,EAAE,MAAM,CAAA;CAAE;;;;;;;;;;;EAiBlE;AAED,wBAAgB,aAAa,CAAC,YAAY,EACxC,QAAQ,EAAE,YAAY,EACtB,MAAM,SAAM,GACX,QAAQ,CAOV;AAED,wBAAgB,2BAA2B,IAAI,sBAAsB,CAWpE"}
1
+ {"version":3,"file":"test-lib.d.ts","sourceRoot":"","sources":["../../../src/tests/test-lib.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,KAAK,sBAAsB,EAAE,MAAM,0BAA0B,CAAC;AAYvE,wBAAgB,8BAA8B,CAAC,EAAE,MAAM,EAAE,EAAE;IAAE,MAAM,EAAE,MAAM,CAAA;CAAE;;;EAiB5E;AAED,wBAAgB,oBAAoB,CAAC,EAAE,MAAM,EAAE,EAAE;IAAE,MAAM,EAAE,MAAM,CAAA;CAAE;;;;;;;;;;;;;;;;;EAiBlE;AAED,wBAAgB,aAAa,CAAC,YAAY,EACxC,QAAQ,EAAE,YAAY,EACtB,MAAM,SAAM,GACX,QAAQ,CAOV;AAED,wBAAgB,2BAA2B,IAAI,sBAAsB,CAWpE"}
@@ -0,0 +1,13 @@
1
+ import { type ApiConfig } from "../api-types";
2
+ import { type SdkDependencies } from "../sdk/dependencies";
3
+ export type GenerateSignedUrlForTeamStorageConfig = {
4
+ destinationFilePath: string | undefined;
5
+ };
6
+ export type GenerateSignedUrlForTeamStorageResponse = {
7
+ fileLocation?: string;
8
+ playgroundFileLocation?: string;
9
+ signedUrl?: string;
10
+ success: boolean;
11
+ };
12
+ export declare function callGenerateSignedUrlForTempTeamStorage({ apiKey, serviceBase }: ApiConfig, { destinationFilePath }: Partial<GenerateSignedUrlForTeamStorageConfig>, { fetch: localFetch }: SdkDependencies): Promise<GenerateSignedUrlForTeamStorageResponse>;
13
+ //# sourceMappingURL=generate-signed-url-for-team-storage.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"generate-signed-url-for-team-storage.d.ts","sourceRoot":"","sources":["../../../../src/lib/api/generate-signed-url-for-team-storage.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,SAAS,EAAE,MAAM,cAAc,CAAC;AAC9C,OAAO,EAAE,KAAK,eAAe,EAAE,MAAM,qBAAqB,CAAC;AAE3D,MAAM,MAAM,qCAAqC,GAAG;IAClD,mBAAmB,EAAE,MAAM,GAAG,SAAS,CAAC;CACzC,CAAC;AAEF,MAAM,MAAM,uCAAuC,GAAG;IACpD,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,sBAAsB,CAAC,EAAE,MAAM,CAAC;IAChC,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,OAAO,EAAE,OAAO,CAAC;CAClB,CAAC;AAEF,wBAAsB,uCAAuC,CAC3D,EAAE,MAAM,EAAE,WAAW,EAAE,EAAE,SAAS,EAClC,EAAE,mBAAmB,EAAE,EAAE,OAAO,CAAC,qCAAqC,CAAC,EACvE,EAAE,KAAK,EAAE,UAAU,EAAE,EAAE,eAAe,GACrC,OAAO,CAAC,uCAAuC,CAAC,CAoClD"}
@@ -0,0 +1,33 @@
1
+ export async function callGenerateSignedUrlForTempTeamStorage({ apiKey, serviceBase }, { destinationFilePath }, { fetch: localFetch }) {
2
+ try {
3
+ const response = await localFetch(new URL(`${serviceBase}/api/v0/team-storage-signed-url?file=${destinationFilePath}`), {
4
+ headers: {
5
+ Authorization: `Bearer ${apiKey}`,
6
+ "Content-Type": "application/json",
7
+ },
8
+ method: "GET",
9
+ });
10
+ if (response.status === 200) {
11
+ const json = (await response.json());
12
+ return {
13
+ fileLocation: json.fileLocation,
14
+ playgroundFileLocation: json.playgroundFileLocation,
15
+ signedUrl: json.signedUrl,
16
+ success: true,
17
+ };
18
+ }
19
+ else {
20
+ const error = await response.text();
21
+ console.log(`ERROR: ${error}`);
22
+ return {
23
+ success: false,
24
+ };
25
+ }
26
+ }
27
+ catch (e) {
28
+ return {
29
+ success: false,
30
+ };
31
+ }
32
+ }
33
+ //# sourceMappingURL=generate-signed-url-for-team-storage.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"generate-signed-url-for-team-storage.js","sourceRoot":"","sources":["../../../../src/lib/api/generate-signed-url-for-team-storage.ts"],"names":[],"mappings":"AAcA,MAAM,CAAC,KAAK,UAAU,uCAAuC,CAC3D,EAAE,MAAM,EAAE,WAAW,EAAa,EAClC,EAAE,mBAAmB,EAAkD,EACvE,EAAE,KAAK,EAAE,UAAU,EAAmB;IAEtC,IAAI,CAAC;QACH,MAAM,QAAQ,GAAG,MAAM,UAAU,CAC/B,IAAI,GAAG,CACL,GAAG,WAAW,wCAAwC,mBAAmB,EAAE,CAC5E,EACD;YACE,OAAO,EAAE;gBACP,aAAa,EAAE,UAAU,MAAM,EAAE;gBACjC,cAAc,EAAE,kBAAkB;aACnC;YACD,MAAM,EAAE,KAAK;SACd,CACF,CAAC;QAEF,IAAI,QAAQ,CAAC,MAAM,KAAK,GAAG,EAAE,CAAC;YAC5B,MAAM,IAAI,GACR,CAAC,MAAM,QAAQ,CAAC,IAAI,EAAE,CAAqD,CAAC;YAC9E,OAAO;gBACL,YAAY,EAAE,IAAI,CAAC,YAAY;gBAC/B,sBAAsB,EAAE,IAAI,CAAC,sBAAsB;gBACnD,SAAS,EAAE,IAAI,CAAC,SAAS;gBACzB,OAAO,EAAE,IAAI;aACL,CAAC;QACb,CAAC;aAAM,CAAC;YACN,MAAM,KAAK,GAAG,MAAM,QAAQ,CAAC,IAAI,EAAE,CAAC;YACpC,OAAO,CAAC,GAAG,CAAC,UAAU,KAAK,EAAE,CAAC,CAAC;YAC/B,OAAO;gBACL,OAAO,EAAE,KAAK;aACN,CAAC;QACb,CAAC;IACH,CAAC;IAAC,OAAO,CAAC,EAAE,CAAC;QACX,OAAO;YACL,OAAO,EAAE,KAAK;SACN,CAAC;IACb,CAAC;AACH,CAAC"}
@@ -1,3 +1,4 @@
1
1
  export * from "./ci-greenlight.js";
2
2
  export * from "./deploy.js";
3
+ export * from "./generate-signed-url-for-team-storage.js";
3
4
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/lib/api/index.ts"],"names":[],"mappings":"AAAA,cAAc,oBAAoB,CAAC;AACnC,cAAc,aAAa,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/lib/api/index.ts"],"names":[],"mappings":"AAAA,cAAc,oBAAoB,CAAC;AACnC,cAAc,aAAa,CAAC;AAC5B,cAAc,2CAA2C,CAAC"}
@@ -1,3 +1,4 @@
1
1
  export * from "./ci-greenlight.js";
2
2
  export * from "./deploy.js";
3
+ export * from "./generate-signed-url-for-team-storage.js";
3
4
  //# sourceMappingURL=index.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/lib/api/index.ts"],"names":[],"mappings":"AAAA,cAAc,oBAAoB,CAAC;AACnC,cAAc,aAAa,CAAC"}
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/lib/api/index.ts"],"names":[],"mappings":"AAAA,cAAc,oBAAoB,CAAC;AACnC,cAAc,aAAa,CAAC;AAC5B,cAAc,2CAA2C,CAAC"}
@@ -13,7 +13,7 @@ export interface NotifyVCSBranchBuildDeployedMutationInput {
13
13
  pullOrMergeRequestNumber: number | undefined;
14
14
  }
15
15
  export type NotifyVCSBranchBuildDeployedResponseSchema = {
16
- codeHostingServiceInstallationPlatform: "GitHub" | "GitLab" | undefined;
16
+ codeHostingServiceInstallationPlatform: "GitHub" | "GitLab" | null;
17
17
  outcome: "success";
18
18
  runId: string;
19
19
  } | {
@@ -1 +1 @@
1
- {"version":3,"file":"notify-vcs-branch-build-deployed-mutation.d.ts","sourceRoot":"","sources":["../../../../src/lib/api/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1
  import { qawolfGraphql } from "./graphql";
2
2
  const mutationName = "notifyVCSBranchBuildDeployed";
3
3
  const mutationGql = `
4
- mutation NotifyVCSBranchBuildDeployed($headVcsCommitId: String!, $headEnvironmentVariablesJson: String!, $baseEnvironmentAlias: String!, $headEnvironmentAlias: String!) {
5
- ${mutationName}(headVcsCommitId: $headVcsCommitId, headEnvironmentVariablesJson: $headEnvironmentVariablesJson, baseEnvironmentAlias: $baseEnvironmentAlias, headEnvironmentAlias: $headEnvironmentAlias) {
4
+ mutation NotifyVCSBranchBuildDeployed(
5
+ $headVcsCommitId: String!,
6
+ $headEnvironmentVariablesJson: String!,
7
+ $baseEnvironmentAlias: String!,
8
+ $headEnvironmentAlias: String!,
9
+ $concurrencyLimit: Int,
10
+ $headEnvironmentName: String,
11
+ $headVcsBranch: String,
12
+ $headVcsCommitUrl: String,
13
+ $pullOrMergeRequestNumber: Int
14
+ ) {
15
+ ${mutationName}(
16
+ headVcsCommitId: $headVcsCommitId,
17
+ headEnvironmentVariablesJson: $headEnvironmentVariablesJson,
18
+ baseEnvironmentAlias: $baseEnvironmentAlias,
19
+ headEnvironmentAlias: $headEnvironmentAlias,
20
+ concurrencyLimit: $concurrencyLimit,
21
+ headEnvironmentName: $headEnvironmentName,
22
+ headVcsBranch: $headVcsBranch,
23
+ headVcsCommitUrl: $headVcsCommitUrl,
24
+ pullOrMergeRequestNumber: $pullOrMergeRequestNumber
25
+ ) {
6
26
  outcome
7
27
  codeHostingServiceInstallationPlatform
8
28
  failureCode
@@ -1 +1 @@
1
- {"version":3,"file":"notify-vcs-branch-build-deployed-mutation.js","sourceRoot":"","sources":["../../../../src/lib/api/notify-vcs-branch-build-deployed-mutation.ts"],"names":[],"mappings":"AAEA,OAAO,EAAwB,aAAa,EAAE,MAAM,WAAW,CAAC;AAchE,MAAM,YAAY,GAAG,8BAAuC,CAAC;AAE7D,MAAM,WAAW,GAAG;;MAEd,YAAY;;;;;;;EAOhB,CAAC;AAoBH,MAAM,CAAC,KAAK,UAAU,wCAAwC,CAC5D,IAAqB,EACrB,SAAoB,EACpB,EACE,oBAAoB,EACpB,gBAAgB,EAChB,oBAAoB,EACpB,mBAAmB,EACnB,wBAAwB,EACxB,eAAe,EACf,gBAAgB,EAChB,aAAa,EACb,wBAAwB,GACkB;IAE5C,OAAO,aAAa,CAalB;QACA,SAAS;QACT,IAAI;QACJ,IAAI,EAAE,YAAY;QAClB,KAAK,EAAE,WAAW;QAClB,SAAS,EAAE;YACT,oBAAoB;YACpB,gBAAgB,EAAE,gBAAgB,IAAI,IAAI;YAC1C,oBAAoB;YACpB,mBAAmB;YACnB,4BAA4B,EAAE,IAAI,CAAC,SAAS,CAAC,wBAAwB,CAAC;YACtE,aAAa,EAAE,aAAa,IAAI,IAAI;YACpC,eAAe;YACf,gBAAgB,EAAE,gBAAgB,IAAI,IAAI;YAC1C,wBAAwB,EAAE,wBAAwB,IAAI,IAAI;SAC3D;QACD,4EAA4E;KAC7E,CAAyE,CAAC;AAC7E,CAAC"}
1
+ {"version":3,"file":"notify-vcs-branch-build-deployed-mutation.js","sourceRoot":"","sources":["../../../../src/lib/api/notify-vcs-branch-build-deployed-mutation.ts"],"names":[],"mappings":"AAEA,OAAO,EAAwB,aAAa,EAAE,MAAM,WAAW,CAAC;AAchE,MAAM,YAAY,GAAG,8BAAuC,CAAC;AAE7D,MAAM,WAAW,GAAG;;;;;;;;;;;;MAYd,YAAY;;;;;;;;;;;;;;;;;EAiBhB,CAAC;AAoBH,MAAM,CAAC,KAAK,UAAU,wCAAwC,CAC5D,IAAqB,EACrB,SAAoB,EACpB,EACE,oBAAoB,EACpB,gBAAgB,EAChB,oBAAoB,EACpB,mBAAmB,EACnB,wBAAwB,EACxB,eAAe,EACf,gBAAgB,EAChB,aAAa,EACb,wBAAwB,GACkB;IAE5C,OAAO,aAAa,CAalB;QACA,SAAS;QACT,IAAI;QACJ,IAAI,EAAE,YAAY;QAClB,KAAK,EAAE,WAAW;QAClB,SAAS,EAAE;YACT,oBAAoB;YACpB,gBAAgB,EAAE,gBAAgB,IAAI,IAAI;YAC1C,oBAAoB;YACpB,mBAAmB;YACnB,4BAA4B,EAAE,IAAI,CAAC,SAAS,CAAC,wBAAwB,CAAC;YACtE,aAAa,EAAE,aAAa,IAAI,IAAI;YACpC,eAAe;YACf,gBAAgB,EAAE,gBAAgB,IAAI,IAAI;YAC1C,wBAAwB,EAAE,wBAAwB,IAAI,IAAI;SAC3D;QACD,4EAA4E;KAC7E,CAAyE,CAAC;AAC7E,CAAC"}
@@ -0,0 +1,12 @@
1
+ import { type GenerateSignedUrlForTeamStorageConfig } from "../../api/generate-signed-url-for-team-storage";
2
+ import { type ApiConfig } from "../../api-types";
3
+ import { type SdkDependencies } from "../dependencies";
4
+ type GenerateSignedUrlStatus = {
5
+ fileLocation?: string;
6
+ playgroundFileLocation?: string;
7
+ success: boolean;
8
+ uploadUrl?: string;
9
+ };
10
+ export declare function generateSignedUrlForTempTeamStorage(deps: SdkDependencies, apiConfig: ApiConfig, config: GenerateSignedUrlForTeamStorageConfig): Promise<GenerateSignedUrlStatus>;
11
+ export {};
12
+ //# sourceMappingURL=generate-signed-url-for-team-storage.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"generate-signed-url-for-team-storage.d.ts","sourceRoot":"","sources":["../../../../../src/lib/sdk/domain/generate-signed-url-for-team-storage.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,qCAAqC,EAE3C,MAAM,gDAAgD,CAAC;AACxD,OAAO,EAAE,KAAK,SAAS,EAAE,MAAM,iBAAiB,CAAC;AACjD,OAAO,EAAE,KAAK,eAAe,EAAE,MAAM,iBAAiB,CAAC;AAEvD,KAAK,uBAAuB,GAAG;IAC7B,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,sBAAsB,CAAC,EAAE,MAAM,CAAC;IAChC,OAAO,EAAE,OAAO,CAAC;IACjB,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB,CAAC;AAEF,wBAAsB,mCAAmC,CACvD,IAAI,EAAE,eAAe,EACrB,SAAS,EAAE,SAAS,EACpB,MAAM,EAAE,qCAAqC,GAC5C,OAAO,CAAC,uBAAuB,CAAC,CA2BlC"}
@@ -0,0 +1,21 @@
1
+ import { callGenerateSignedUrlForTempTeamStorage, } from "../../api/generate-signed-url-for-team-storage";
2
+ export async function generateSignedUrlForTempTeamStorage(deps, apiConfig, config) {
3
+ const { log } = deps;
4
+ if (!config.destinationFilePath) {
5
+ log.error(`🚫 destinationFilePath is a required config parameter`);
6
+ return { success: false };
7
+ }
8
+ const responseState = await callGenerateSignedUrlForTempTeamStorage(apiConfig, config, deps);
9
+ if (!responseState.success) {
10
+ log.error(`🚫 Failed to generate signed URL for team storage. Please contact support.`);
11
+ return { success: false };
12
+ }
13
+ log.info(`✅ Generated Signed Upload URL: ${responseState.signedUrl}.`);
14
+ return {
15
+ fileLocation: responseState.fileLocation,
16
+ playgroundFileLocation: responseState.playgroundFileLocation,
17
+ success: true,
18
+ uploadUrl: responseState.signedUrl,
19
+ };
20
+ }
21
+ //# sourceMappingURL=generate-signed-url-for-team-storage.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"generate-signed-url-for-team-storage.js","sourceRoot":"","sources":["../../../../../src/lib/sdk/domain/generate-signed-url-for-team-storage.ts"],"names":[],"mappings":"AAAA,OAAO,EAEL,uCAAuC,GACxC,MAAM,gDAAgD,CAAC;AAWxD,MAAM,CAAC,KAAK,UAAU,mCAAmC,CACvD,IAAqB,EACrB,SAAoB,EACpB,MAA6C;IAE7C,MAAM,EAAE,GAAG,EAAE,GAAG,IAAI,CAAC;IAErB,IAAI,CAAC,MAAM,CAAC,mBAAmB,EAAE,CAAC;QAChC,GAAG,CAAC,KAAK,CAAC,uDAAuD,CAAC,CAAC;QACnE,OAAO,EAAE,OAAO,EAAE,KAAK,EAAE,CAAC;IAC5B,CAAC;IAED,MAAM,aAAa,GAAG,MAAM,uCAAuC,CACjE,SAAS,EACT,MAAM,EACN,IAAI,CACL,CAAC;IACF,IAAI,CAAC,aAAa,CAAC,OAAO,EAAE,CAAC;QAC3B,GAAG,CAAC,KAAK,CACP,4EAA4E,CAC7E,CAAC;QACF,OAAO,EAAE,OAAO,EAAE,KAAK,EAAE,CAAC;IAC5B,CAAC;IAED,GAAG,CAAC,IAAI,CAAC,kCAAkC,aAAa,CAAC,SAAS,GAAG,CAAC,CAAC;IACvE,OAAO;QACL,YAAY,EAAE,aAAa,CAAC,YAAY;QACxC,sBAAsB,EAAE,aAAa,CAAC,sBAAsB;QAC5D,OAAO,EAAE,IAAI;QACb,SAAS,EAAE,aAAa,CAAC,SAAS;KACnC,CAAC;AACJ,CAAC"}
@@ -55,12 +55,12 @@ async function runNotifyVCSBranchBuildDeployedOnce(deps, apiConfig, input) {
55
55
  }
56
56
  const result = resp.responseBody;
57
57
  if (result.outcome === "success") {
58
- const codeHostingInfo = result.codeHostingServiceInstallationPlatform === undefined
58
+ const codeHostingInfo = result.codeHostingServiceInstallationPlatform == null
59
59
  ? ""
60
60
  : `, and code hosting service integration '${result.codeHostingServiceInstallationPlatform}'.`;
61
61
  log.info(`✅ [notifyVCSBranchBuildDeployed] Success. Run was deployed with ID: '${result.runId}'${codeHostingInfo}`);
62
62
  return {
63
- codeHostingServiceInstallationType: result.codeHostingServiceInstallationPlatform,
63
+ codeHostingServiceInstallationType: result.codeHostingServiceInstallationPlatform ?? undefined,
64
64
  outcome: "success",
65
65
  runId: result.runId,
66
66
  };
@@ -1 +1 @@
1
- {"version":3,"file":"notify-vcs-branch-build-deployed.js","sourceRoot":"","sources":["../../../../../../src/lib/sdk/domain/vcsBranchTesting/notify-vcs-branch-build-deployed.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,wCAAwC,EAAE,MAAM,wDAAwD,CAAC;AAElH,OAAO,EAAE,UAAU,EAAE,MAAM,gBAAgB,CAAC;AAE5C,OAAO,EAAE,0BAA0B,EAAE,MAAM,sBAAsB,CAAC;AAClE,OAAO,EAAE,yBAAyB,EAAE,MAAM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GAAG,KAAK,CAAC;IAClC,OAAO,2BAA2B,CAAC;QACjC,GAAG,EAAE,IAAI,CAAC,GAAG;QACb,UAAU;QACV,UAAU,EAAE,8BAA8B;QAC1C,qBAAqB,EAAE;YACrB,eAAe;YACf,cAAc;YACd,qBAAqB;SAC8B;QACrD,OAAO,EAAE,GAAG,EAAE,CAAC,mCAAmC,CAAC,IAAI,EAAE,SAAS,EAAE,KAAK,CAAC;KAC3E,CAAC,CAAC;AACL,CAAC"}
1
+ {"version":3,"file":"notify-vcs-branch-build-deployed.js","sourceRoot":"","sources":["../../../../../../src/lib/sdk/domain/vcsBranchTesting/notify-vcs-branch-build-deployed.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,wCAAwC,EAAE,MAAM,wDAAwD,CAAC;AAElH,OAAO,EAAE,UAAU,EAAE,MAAM,gBAAgB,CAAC;AAE5C,OAAO,EAAE,0BAA0B,EAAE,MAAM,sBAAsB,CAAC;AAClE,OAAO,EAAE,yBAAyB,EAAE,MAAM,qBAAqB,CAAC;AAChE,OAAO,EAAE,2BAA2B,EAAE,MAAM,aAAa,CAAC;AAM1D,KAAK,UAAU,mCAAmC,CAChD,IAAqB,EACrB,SAAoB,EACpB,KAA+B;IAE/B,MAAM,EACJ,uBAAuB,EACvB,aAAa,EACb,oBAAoB,EACpB,mBAAmB,EACnB,wBAAwB,EACxB,eAAe,EACf,gBAAgB,EAChB,gBAAgB,EAChB,aAAa,EACb,wBAAwB,GACzB,GAAG,KAAK,CAAC;IACV,MAAM,GAAG,GAAG,IAAI,CAAC,GAAG,CAAC;IACrB,MAAM,oBAAoB,GAAG,uBAAuB,CAAC,IAAI,CACvD,CAAC,OAAO,EAAE,EAAE,CAAC,OAAO,CAAC,SAAS,KAAK,aAAa,CACjD,EAAE,gBAAgB,CAAC;IACpB,IAAI,oBAAoB,KAAK,SAAS,EAAE,CAAC;QACvC,GAAG,CAAC,KAAK,CACP,sFAAsF,aAAa,2BAA2B;YAC5H,wEAAwE,CAC3E,C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AAe,GACnB,MAAM,CAAC,sCAAsC,IAAI,IAAI;YACnD,CAAC,CAAC,EAAE;YACJ,CAAC,CAAC,2CAA2C,MAAM,CAAC,sCAAsC,IAAI,CAAC;QACnG,GAAG,CAAC,IAAI,CACN,wEAAwE,MAAM,CAAC,KAAK,IAAI,eAAe,EAAE,CAC1G,CAAC;QACF,OAAO;YACL,kCAAkC,EAChC,MAAM,CAAC,sCAAsC,IAAI,SAAS;YAC5D,OAAO,EAAE,SAAS;YAClB,KAAK,EAAE,MAAM,CAAC,KAAK;SACpB,CAAC;IACJ,CAAC;IAED,UAAU,CAAW,MAAM,CAAC,OAAO,CAAC,CAAC;IAErC,OAAO,0BAA0B,CAAC;QAChC,GAAG;QACH,UAAU,EAAE,8BAA8B;QAC1C,MAAM;KACP,CAAC,CAAC;AACL,CAAC;AAED,MAAM,CAAC,KAAK,UAAU,4BAA4B,CAChD,IAAqB,EACrB,SAAoB,EACpB,KAA+B;IAE/B,MAAM,EAAE,UAAU,GAAG,EAAE,EAAE,GAAG,KAAK,CAAC;IAClC,OAAO,2BAA2B,CAAC;QACjC,GAAG,EAAE,IAAI,CAAC,GAAG;QACb,UAAU;QACV,UAAU,EAAE,8BAA8B;QAC1C,qBAAqB,EAAE;YACrB,eAAe;YACf,cAAc;YACd,qBAAqB;SAC8B;QACrD,OAAO,EAAE,GAAG,EAAE,CAAC,mCAAmC,CAAC,IAAI,EAAE,SAAS,EAAE,KAAK,CAAC;KAC3E,CAAC,CAAC;AACL,CAAC"}
@@ -4,11 +4,23 @@ export declare function makeQaWolfSdk({ apiKey, serviceBase, }: {
4
4
  serviceBase?: string;
5
5
  }, { log, fetch, }?: Partial<SdkDependencies>): {
6
6
  attemptNotifyDeploy: (config: Partial<import("../api").DeployConfig>) => Promise<import("./domain/attempt-deploy").NotifyDeployStatus>;
7
+ /**
8
+ * @deprecated Use `experimental_vcsBranchTesting` instead.
9
+ */
7
10
  experimental_removeEnvironment: (config: {
8
11
  branch: string;
9
12
  }) => Promise<void>;
13
+ /**
14
+ * @deprecated Use `experimental_vcsBranchTesting` instead.
15
+ */
10
16
  experimental_testPreview: (config: import("./domain/legacy_previewTesting/index").TestPreviewParams) => Promise<import("./domain/attempt-deploy").NotifyDeployStatus>;
11
17
  experimental_vcsBranchTesting: import("./domain/vcsBranchTesting").VCSBranchTestingSDK;
18
+ generateSignedUrlForTempTeamStorage: (config: import("../api").GenerateSignedUrlForTeamStorageConfig) => Promise<{
19
+ fileLocation?: string;
20
+ playgroundFileLocation?: string;
21
+ success: boolean;
22
+ uploadUrl?: string;
23
+ }>;
12
24
  pollCiGreenlightStatus: (args_0: import("./domain/poll-ci-greenlight").PollCiGreenlightParams) => Promise<import("./domain/poll-ci-greenlight").PollCiGreenlightStatus>;
13
25
  };
14
26
  export type * from "./domain/poll-ci-greenlight";
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/lib/sdk/index.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,KAAK,eAAe,EAAE,MAAM,gBAAgB,CAAC;AAStD,wBAAgB,aAAa,CAC3B,EACE,MAAM,EACN,WAAgC,GACjC,EAAE;IACD,MAAM,EAAE,MAAM,CAAC;IACf,WAAW,CAAC,EAAE,MAAM,CAAC;CACtB,EACD,EACE,GAAsB,EACtB,KAAoB,GACrB,GAAE,OAAO,CAAC,eAAe,CAAM;;;;;;;;EA0BjC;AAED,mBAAmB,6BAA6B,CAAC;AACjD,mBAAmB,yBAAyB,CAAC;AAC7C,cAAc,iCAAiC,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/lib/sdk/index.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,KAAK,eAAe,EAAE,MAAM,gBAAgB,CAAC;AAUtD,wBAAgB,aAAa,CAC3B,EACE,MAAM,EACN,WAAgC,GACjC,EAAE;IACD,MAAM,EAAE,MAAM,CAAC;IACf,WAAW,CAAC,EAAE,MAAM,CAAC;CACtB,EACD,EACE,GAAsB,EACtB,KAAoB,GACrB,GAAE,OAAO,CAAC,eAAe,CAAM;;IAiB9B;;OAEG;;;;IAMH;;OAEG;;;;;;;;;;EAON;AAED,mBAAmB,6BAA6B,CAAC;AACjD,mBAAmB,yBAAyB,CAAC;AAC7C,cAAc,iCAAiC,CAAC"}
@@ -3,6 +3,7 @@ import { defaultFetch } from "./defaults/fetch";
3
3
  import { defaultLogDriver } from "./defaults/log";
4
4
  import { defaultServiceBase } from "./defaults/serviceBase";
5
5
  import { attemptNotifyDeploy } from "./domain/attempt-deploy";
6
+ import { generateSignedUrlForTempTeamStorage } from "./domain/generate-signed-url-for-team-storage";
6
7
  import { removeEnvironment, testPreview, } from "./domain/legacy_previewTesting/index";
7
8
  import { pollCiGreenlightStatus } from "./domain/poll-ci-greenlight";
8
9
  import { makeVCSBranchTestingSDK } from "./domain/vcsBranchTesting";
@@ -19,9 +20,16 @@ We recommend 'undici' package for that purpose. See the Requirement section of o
19
20
  const apiConfig = { apiKey, serviceBase };
20
21
  return {
21
22
  attemptNotifyDeploy: attemptNotifyDeploy.bind(null, deps, apiConfig),
23
+ /**
24
+ * @deprecated Use `experimental_vcsBranchTesting` instead.
25
+ */
22
26
  experimental_removeEnvironment: removeEnvironment.bind(null, deps, apiConfig),
27
+ /**
28
+ * @deprecated Use `experimental_vcsBranchTesting` instead.
29
+ */
23
30
  experimental_testPreview: testPreview.bind(null, deps, apiConfig),
24
31
  experimental_vcsBranchTesting: makeVCSBranchTestingSDK(apiConfig, deps),
32
+ generateSignedUrlForTempTeamStorage: generateSignedUrlForTempTeamStorage.bind(null, deps, apiConfig),
25
33
  pollCiGreenlightStatus: pollCiGreenlightStatus.bind(null, deps, apiConfig),
26
34
  };
27
35
  }
@@ -1 +1 @@
1
- {"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/lib/sdk/index.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,qBAAqB,EAAE,MAAM,UAAU,CAAC;AACjD,OAAO,EAAE,YAAY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AAI,CAAC,IAAI,EAAE,IAAI,EAAE,SAAS,CAAC;QACjE,6BAA6B,EAAE,uBAAuB,CAAC,SAAS,EAAE,IAAI,CAAC;QACvE,mCAAmC,EACjC,mCAAmC,CAAC,IAAI,CAAC,IAAI,EAAE,IAAI,EAAE,SAAS,CAAC;QACjE,sBAAsB,EAAE,sBAAsB,CAAC,IAAI,CAAC,IAAI,EAAE,IAAI,EAAE,SAAS,CAAC;KAC3E,CAAC;AACJ,CAAC;AAID,cAAc,iCAAiC,CAAC"}
@@ -16,6 +16,12 @@ export declare function makeQaWolfSdkForTest({ apiKey }: {
16
16
  }) => Promise<void>;
17
17
  experimental_testPreview: (config: import("../lib/sdk/domain/legacy_previewTesting").TestPreviewParams) => Promise<import("../lib/sdk/index").NotifyDeployStatus>;
18
18
  experimental_vcsBranchTesting: import("../lib/sdk/index").VCSBranchTestingSDK;
19
+ generateSignedUrlForTempTeamStorage: (config: import("../lib/api").GenerateSignedUrlForTeamStorageConfig) => Promise<{
20
+ fileLocation?: string;
21
+ playgroundFileLocation?: string;
22
+ success: boolean;
23
+ uploadUrl?: string;
24
+ }>;
19
25
  pollCiGreenlightStatus: (args_0: import("../lib/sdk/index").PollCiGreenlightParams) => Promise<import("../lib/sdk/index").PollCiGreenlightStatus>;
20
26
  };
21
27
  };
@@ -1 +1 @@
1
- {"version":3,"file":"test-lib.d.ts","sourceRoot":"","sources":["../../../src/tests/test-lib.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,KAAK,sBAAsB,EAAE,MAAM,0BAA0B,CAAC;AAYvE,wBAAgB,8BAA8B,CAAC,EAAE,MAAM,EAAE,EAAE;IAAE,MAAM,EAAE,MAAM,CAAA;CAAE;;;EAiB5E;AAED,wBAAgB,oBAAoB,CAAC,EAAE,MAAM,EAAE,EAAE;IAAE,MAAM,EAAE,MAAM,CAAA;CAAE;;;;;;;;;;;EAiBlE;AAED,wBAAgB,aAAa,CAAC,YAAY,EACxC,QAAQ,EAAE,YAAY,EACtB,MAAM,SAAM,GACX,QAAQ,CAOV;AAED,wBAAgB,2BAA2B,IAAI,sBAAsB,CAWpE"}
1
+ {"version":3,"file":"test-lib.d.ts","sourceRoot":"","sources":["../../../src/tests/test-lib.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,KAAK,sBAAsB,EAAE,MAAM,0BAA0B,CAAC;AAYvE,wBAAgB,8BAA8B,CAAC,EAAE,MAAM,EAAE,EAAE;IAAE,MAAM,EAAE,MAAM,CAAA;CAAE;;;EAiB5E;AAED,wBAAgB,oBAAoB,CAAC,EAAE,MAAM,EAAE,EAAE;IAAE,MAAM,EAAE,MAAM,CAAA;CAAE;;;;;;;;;;;;;;;;;EAiBlE;AAED,wBAAgB,aAAa,CAAC,YAAY,EACxC,QAAQ,EAAE,YAAY,EACtB,MAAM,SAAM,GACX,QAAQ,CAOV;AAED,wBAAgB,2BAA2B,IAAI,sBAAsB,CAWpE"}
@@ -0,0 +1,13 @@
1
+ import { type ApiConfig } from "../api-types";
2
+ import { type SdkDependencies } from "../sdk/dependencies";
3
+ export type GenerateSignedUrlForTeamStorageConfig = {
4
+ destinationFilePath: string | undefined;
5
+ };
6
+ export type GenerateSignedUrlForTeamStorageResponse = {
7
+ fileLocation?: string;
8
+ playgroundFileLocation?: string;
9
+ signedUrl?: string;
10
+ success: boolean;
11
+ };
12
+ export declare function callGenerateSignedUrlForTempTeamStorage({ apiKey, serviceBase }: ApiConfig, { destinationFilePath }: Partial<GenerateSignedUrlForTeamStorageConfig>, { fetch: localFetch }: SdkDependencies): Promise<GenerateSignedUrlForTeamStorageResponse>;
13
+ //# sourceMappingURL=generate-signed-url-for-team-storage.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"generate-signed-url-for-team-storage.d.ts","sourceRoot":"","sources":["../../../../src/lib/api/generate-signed-url-for-team-storage.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,SAAS,EAAE,MAAM,cAAc,CAAC;AAC9C,OAAO,EAAE,KAAK,eAAe,EAAE,MAAM,qBAAqB,CAAC;AAE3D,MAAM,MAAM,qCAAqC,GAAG;IAClD,mBAAmB,EAAE,MAAM,GAAG,SAAS,CAAC;CACzC,CAAC;AAEF,MAAM,MAAM,uCAAuC,GAAG;IACpD,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,sBAAsB,CAAC,EAAE,MAAM,CAAC;IAChC,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,OAAO,EAAE,OAAO,CAAC;CAClB,CAAC;AAEF,wBAAsB,uCAAuC,CAC3D,EAAE,MAAM,EAAE,WAAW,EAAE,EAAE,SAAS,EAClC,EAAE,mBAAmB,EAAE,EAAE,OAAO,CAAC,qCAAqC,CAAC,EACvE,EAAE,KAAK,EAAE,UAAU,EAAE,EAAE,eAAe,GACrC,OAAO,CAAC,uCAAuC,CAAC,CAoClD"}
@@ -1,3 +1,4 @@
1
1
  export * from "./ci-greenlight.js";
2
2
  export * from "./deploy.js";
3
+ export * from "./generate-signed-url-for-team-storage.js";
3
4
  //# sourceMappingURL=index.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/lib/api/index.ts"],"names":[],"mappings":"AAAA,cAAc,oBAAoB,CAAC;AACnC,cAAc,aAAa,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/lib/api/index.ts"],"names":[],"mappings":"AAAA,cAAc,oBAAoB,CAAC;AACnC,cAAc,aAAa,CAAC;AAC5B,cAAc,2CAA2C,CAAC"}
@@ -13,7 +13,7 @@ export interface NotifyVCSBranchBuildDeployedMutationInput {
13
13
  pullOrMergeRequestNumber: number | undefined;
14
14
  }
15
15
  export type NotifyVCSBranchBuildDeployedResponseSchema = {
16
- codeHostingServiceInstallationPlatform: "GitHub" | "GitLab" | undefined;
16
+ codeHostingServiceInstallationPlatform: "GitHub" | "GitLab" | null;
17
17
  outcome: "success";
18
18
  runId: string;
19
19
  } | {
@@ -1 +1 @@
1
- {"version":3,"file":"notify-vcs-branch-build-deployed-mutation.d.ts","sourceRoot":"","sources":["../../../../src/lib/api/notify-vcs-branch-build-deployed-mutation.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,SAAS,EAAE,MAAM,cAAc,CAAC;AAC9C,OAAO,EAAE,KAAK,eAAe,EAAE,MAAM,qBAAqB,CAAC;AAC3D,OAAO,EAAE,KAAK,eAAe,EAAiB,MAAM,WAAW,CAAC;AAEhE,MAAM,WAAW,yCAAyC;IACxD,oBAAoB,EAAE,MAAM,CAAC;IAC7B,gBAAgB,EAAE,MAAM,GAAG,SAAS,CAAC;IACrC,oBAAoB,EAAE,MAAM,CAAC;IAC7B,mBAAmB,EAAE,MAAM,CAAC;IAC5B,wBAAwB,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IACjD,aAAa,EAAE,MAAM,GAAG,SAAS,CAAC;IAClC,eAAe,EAAE,MAAM,CAAC;IACxB,gBAAgB,EAAE,MAAM,GAAG,SAAS,CAAC;IACrC,wBAAwB,EAAE,MAAM,GAAG,SAAS,CAAC;CAC9C;AAeD,MAAM,MAAM,0CAA0C,GAClD;IACE,sCAAsC,EAAE,QAAQ,GAAG,QAAQ,GAAG,SAAS,CAAC;IACxE,OAAO,EAAE,SAAS,CAAC;IACnB,KAAK,EAAE,MAAM,CAAC;CACf,GACD;IACE,WAAW,EACP,eAAe,GACf,4BAA4B,GAC5B,wBAAwB,GACxB,wBAAwB,GACxB,0CAA0C,GAC1C,qBAAqB,CAAC;IAC1B,cAAc,EAAE,MAAM,CAAC;IACvB,OAAO,EAAE,QAAQ,CAAC;CACnB,CAAC;AAEN,wBAAsB,wCAAwC,CAC5D,IAAI,EAAE,eAAe,EACrB,SAAS,EAAE,SAAS,EACpB,EACE,oBAAoB,EACpB,gBAAgB,EAChB,oBAAoB,EACpB,mBAAmB,EACnB,wBAAwB,EACxB,eAAe,EACf,gBAAgB,EAChB,aAAa,EACb,wBAAwB,GACzB,EAAE,yCAAyC,wEAiC7C"}
1
+ {"version":3,"file":"notify-vcs-branch-build-deployed-mutation.d.ts","sourceRoot":"","sources":["../../../../src/lib/api/notify-vcs-branch-build-deployed-mutation.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,SAAS,EAAE,MAAM,cAAc,CAAC;AAC9C,OAAO,EAAE,KAAK,eAAe,EAAE,MAAM,qBAAqB,CAAC;AAC3D,OAAO,EAAE,KAAK,eAAe,EAAiB,MAAM,WAAW,CAAC;AAEhE,MAAM,WAAW,yCAAyC;IACxD,oBAAoB,EAAE,MAAM,CAAC;IAC7B,gBAAgB,EAAE,MAAM,GAAG,SAAS,CAAC;IACrC,oBAAoB,EAAE,MAAM,CAAC;IAC7B,mBAAmB,EAAE,MAAM,CAAC;IAC5B,wBAAwB,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,CAAC;IACjD,aAAa,EAAE,MAAM,GAAG,SAAS,CAAC;IAClC,eAAe,EAAE,MAAM,CAAC;IACxB,gBAAgB,EAAE,MAAM,GAAG,SAAS,CAAC;IACrC,wBAAwB,EAAE,MAAM,GAAG,SAAS,CAAC;CAC9C;AAmCD,MAAM,MAAM,0CAA0C,GAClD;IACE,sCAAsC,EAAE,QAAQ,GAAG,QAAQ,GAAG,IAAI,CAAC;IACnE,OAAO,EAAE,SAAS,CAAC;IACnB,KAAK,EAAE,MAAM,CAAC;CACf,GACD;IACE,WAAW,EACP,eAAe,GACf,4BAA4B,GAC5B,wBAAwB,GACxB,wBAAwB,GACxB,0CAA0C,GAC1C,qBAAqB,CAAC;IAC1B,cAAc,EAAE,MAAM,CAAC;IACvB,OAAO,EAAE,QAAQ,CAAC;CACnB,CAAC;AAEN,wBAAsB,wCAAwC,CAC5D,IAAI,EAAE,eAAe,EACrB,SAAS,EAAE,SAAS,EACpB,EACE,oBAAoB,EACpB,gBAAgB,EAChB,oBAAoB,EACpB,mBAAmB,EACnB,wBAAwB,EACxB,eAAe,EACf,gBAAgB,EAChB,aAAa,EACb,wBAAwB,GACzB,EAAE,yCAAyC,wEAiC7C"}
@@ -0,0 +1,12 @@
1
+ import { type GenerateSignedUrlForTeamStorageConfig } from "../../api/generate-signed-url-for-team-storage";
2
+ import { type ApiConfig } from "../../api-types";
3
+ import { type SdkDependencies } from "../dependencies";
4
+ type GenerateSignedUrlStatus = {
5
+ fileLocation?: string;
6
+ playgroundFileLocation?: string;
7
+ success: boolean;
8
+ uploadUrl?: string;
9
+ };
10
+ export declare function generateSignedUrlForTempTeamStorage(deps: SdkDependencies, apiConfig: ApiConfig, config: GenerateSignedUrlForTeamStorageConfig): Promise<GenerateSignedUrlStatus>;
11
+ export {};
12
+ //# sourceMappingURL=generate-signed-url-for-team-storage.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"generate-signed-url-for-team-storage.d.ts","sourceRoot":"","sources":["../../../../../src/lib/sdk/domain/generate-signed-url-for-team-storage.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,KAAK,qCAAqC,EAE3C,MAAM,gDAAgD,CAAC;AACxD,OAAO,EAAE,KAAK,SAAS,EAAE,MAAM,iBAAiB,CAAC;AACjD,OAAO,EAAE,KAAK,eAAe,EAAE,MAAM,iBAAiB,CAAC;AAEvD,KAAK,uBAAuB,GAAG;IAC7B,YAAY,CAAC,EAAE,MAAM,CAAC;IACtB,sBAAsB,CAAC,EAAE,MAAM,CAAC;IAChC,OAAO,EAAE,OAAO,CAAC;IACjB,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB,CAAC;AAEF,wBAAsB,mCAAmC,CACvD,IAAI,EAAE,eAAe,EACrB,SAAS,EAAE,SAAS,EACpB,MAAM,EAAE,qCAAqC,GAC5C,OAAO,CAAC,uBAAuB,CAAC,CA2BlC"}
@@ -4,11 +4,23 @@ export declare function makeQaWolfSdk({ apiKey, serviceBase, }: {
4
4
  serviceBase?: string;
5
5
  }, { log, fetch, }?: Partial<SdkDependencies>): {
6
6
  attemptNotifyDeploy: (config: Partial<import("../api").DeployConfig>) => Promise<import("./domain/attempt-deploy").NotifyDeployStatus>;
7
+ /**
8
+ * @deprecated Use `experimental_vcsBranchTesting` instead.
9
+ */
7
10
  experimental_removeEnvironment: (config: {
8
11
  branch: string;
9
12
  }) => Promise<void>;
13
+ /**
14
+ * @deprecated Use `experimental_vcsBranchTesting` instead.
15
+ */
10
16
  experimental_testPreview: (config: import("./domain/legacy_previewTesting/index").TestPreviewParams) => Promise<import("./domain/attempt-deploy").NotifyDeployStatus>;
11
17
  experimental_vcsBranchTesting: import("./domain/vcsBranchTesting").VCSBranchTestingSDK;
18
+ generateSignedUrlForTempTeamStorage: (config: import("../api").GenerateSignedUrlForTeamStorageConfig) => Promise<{
19
+ fileLocation?: string;
20
+ playgroundFileLocation?: string;
21
+ success: boolean;
22
+ uploadUrl?: string;
23
+ }>;
12
24
  pollCiGreenlightStatus: (args_0: import("./domain/poll-ci-greenlight").PollCiGreenlightParams) => Promise<import("./domain/poll-ci-greenlight").PollCiGreenlightStatus>;
13
25
  };
14
26
  export type * from "./domain/poll-ci-greenlight";
@@ -1 +1 @@
1
- {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/lib/sdk/index.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,KAAK,eAAe,EAAE,MAAM,gBAAgB,CAAC;AAStD,wBAAgB,aAAa,CAC3B,EACE,MAAM,EACN,WAAgC,GACjC,EAAE;IACD,MAAM,EAAE,MAAM,CAAC;IACf,WAAW,CAAC,EAAE,MAAM,CAAC;CACtB,EACD,EACE,GAAsB,EACtB,KAAoB,GACrB,GAAE,OAAO,CAAC,eAAe,CAAM;;;;;;;;EA0BjC;AAED,mBAAmB,6BAA6B,CAAC;AACjD,mBAAmB,yBAAyB,CAAC;AAC7C,cAAc,iCAAiC,CAAC"}
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/lib/sdk/index.ts"],"names":[],"mappings":"AAKA,OAAO,EAAE,KAAK,eAAe,EAAE,MAAM,gBAAgB,CAAC;AAUtD,wBAAgB,aAAa,CAC3B,EACE,MAAM,EACN,WAAgC,GACjC,EAAE;IACD,MAAM,EAAE,MAAM,CAAC;IACf,WAAW,CAAC,EAAE,MAAM,CAAC;CACtB,EACD,EACE,GAAsB,EACtB,KAAoB,GACrB,GAAE,OAAO,CAAC,eAAe,CAAM;;IAiB9B;;OAEG;;;;IAMH;;OAEG;;;;;;;;;;EAON;AAED,mBAAmB,6BAA6B,CAAC;AACjD,mBAAmB,yBAAyB,CAAC;AAC7C,cAAc,iCAAiC,CAAC"}
@@ -16,6 +16,12 @@ export declare function makeQaWolfSdkForTest({ apiKey }: {
16
16
  }) => Promise<void>;
17
17
  experimental_testPreview: (config: import("../lib/sdk/domain/legacy_previewTesting").TestPreviewParams) => Promise<import("../lib/sdk/index").NotifyDeployStatus>;
18
18
  experimental_vcsBranchTesting: import("../lib/sdk/index").VCSBranchTestingSDK;
19
+ generateSignedUrlForTempTeamStorage: (config: import("../lib/api").GenerateSignedUrlForTeamStorageConfig) => Promise<{
20
+ fileLocation?: string;
21
+ playgroundFileLocation?: string;
22
+ success: boolean;
23
+ uploadUrl?: string;
24
+ }>;
19
25
  pollCiGreenlightStatus: (args_0: import("../lib/sdk/index").PollCiGreenlightParams) => Promise<import("../lib/sdk/index").PollCiGreenlightStatus>;
20
26
  };
21
27
  };
@@ -1 +1 @@
1
- {"version":3,"file":"test-lib.d.ts","sourceRoot":"","sources":["../../../src/tests/test-lib.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,KAAK,sBAAsB,EAAE,MAAM,0BAA0B,CAAC;AAYvE,wBAAgB,8BAA8B,CAAC,EAAE,MAAM,EAAE,EAAE;IAAE,MAAM,EAAE,MAAM,CAAA;CAAE;;;EAiB5E;AAED,wBAAgB,oBAAoB,CAAC,EAAE,MAAM,EAAE,EAAE;IAAE,MAAM,EAAE,MAAM,CAAA;CAAE;;;;;;;;;;;EAiBlE;AAED,wBAAgB,aAAa,CAAC,YAAY,EACxC,QAAQ,EAAE,YAAY,EACtB,MAAM,SAAM,GACX,QAAQ,CAOV;AAED,wBAAgB,2BAA2B,IAAI,sBAAsB,CAWpE"}
1
+ {"version":3,"file":"test-lib.d.ts","sourceRoot":"","sources":["../../../src/tests/test-lib.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,KAAK,sBAAsB,EAAE,MAAM,0BAA0B,CAAC;AAYvE,wBAAgB,8BAA8B,CAAC,EAAE,MAAM,EAAE,EAAE;IAAE,MAAM,EAAE,MAAM,CAAA;CAAE;;;EAiB5E;AAED,wBAAgB,oBAAoB,CAAC,EAAE,MAAM,EAAE,EAAE;IAAE,MAAM,EAAE,MAAM,CAAA;CAAE;;;;;;;;;;;;;;;;;EAiBlE;AAED,wBAAgB,aAAa,CAAC,YAAY,EACxC,QAAQ,EAAE,YAAY,EACtB,MAAM,SAAM,GACX,QAAQ,CAOV;AAED,wBAAgB,2BAA2B,IAAI,sBAAsB,CAWpE"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@qawolf/ci-sdk",
3
- "version": "0.15.8",
3
+ "version": "0.17.0",
4
4
  "description": "A simple SDK for interacting with QAWolf in CI scripts.",
5
5
  "type": "commonjs",
6
6
  "private": false,
@@ -16,8 +16,7 @@
16
16
  "lint": "eslint . --ext js,jsx,mjs,ts,tsx --max-warnings=0 && prettier --check .",
17
17
  "lint:fix": "eslint . --ext js,jsx,mjs,ts,tsx --fix --max-warnings=0 && prettier --write .",
18
18
  "test": "jest",
19
- "prepublishOnly": "npm run build",
20
- "npm-publish": "./scripts/publish.sh",
19
+ "prepublishOnly": "nx run ci-sdk:build",
21
20
  "tsc:check": "tsc --noEmit"
22
21
  },
23
22
  "keywords": [],
@@ -40,5 +39,9 @@
40
39
  "@qawolf/ci-utils": "^1.0.0",
41
40
  "slugify": "^1.6.6",
42
41
  "tslib": "^2.6.2"
43
- }
42
+ },
43
+ "files": [
44
+ "/dist",
45
+ "/README.md"
46
+ ]
44
47
  }
package/.eslintrc.json DELETED
@@ -1,27 +0,0 @@
1
- /**
2
- * ESLint config files allow comments, so please comment all changes you make here.
3
- * Unless you are changing a rule for reasons very specific to this project, you
4
- * should consider making the change in our @qawolf base config instead. There is
5
- * also a `.eslintrc.json` file in this repo root folder for any rules that we want
6
- * in this repo but not necessarily in other repos that use our @qawolf base config.
7
- */
8
- {
9
- "root": true,
10
- "rules": {
11
- "no-restricted-imports": [
12
- "error",
13
- {
14
- // playground-* and runner-* packages are only to be
15
- // imported by playgrounds and runners and their packages
16
- "patterns": ["@qawolf/playground-*", "@qawolf/runner-*"]
17
- }
18
- ]
19
- },
20
- "extends": [
21
- "@qawolf",
22
- "plugin:react/recommended",
23
- "plugin:react-hooks/recommended",
24
- "../../.eslintrc.json"
25
- ],
26
- "ignorePatterns": ["!**/*", "/**/*.js", "/**/*.d.ts", "dist", "node_modules"]
27
- }
package/project.json DELETED
@@ -1,6 +0,0 @@
1
- {
2
- "$schema": "../../node_modules/nx/schemas/project-schema.json",
3
- "name": "ci-sdk",
4
- "projectType": "library",
5
- "sourceRoot": "packages/ci-sdk/src"
6
- }