freestyle-sandboxes 0.0.95 → 0.0.96

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "freestyle-sandboxes",
3
- "version": "0.0.95",
3
+ "version": "0.0.96",
4
4
  "type": "module",
5
5
  "main": "./dist/index.cjs",
6
6
  "module": "./dist/index.mjs",
package/src/index.ts CHANGED
@@ -71,8 +71,7 @@ export type {
71
71
  DeploymentSource,
72
72
  HandleListDomainMappingsResponse,
73
73
  HandleListDomainMappingsData,
74
- HandleInsertDomainMappingResponse,
75
- HandleDeleteDomainMappingResponse,
74
+ HandleInsertDomainMappingResponse
76
75
  } from "../openapi/index.ts";
77
76
 
78
77
  /**
@@ -199,7 +198,7 @@ export class FreestyleSandboxes {
199
198
  return response.data;
200
199
  }
201
200
  throw new Error(
202
- `Failed to deploy web project\n\nStatus: ${response.response.status}\n\nMessage: ${response.error?.message}`
201
+ `Failed to deploy web project\n\nStatus: ${response.response.status}\n\nMessage: ${response.error}`
203
202
  );
204
203
  }
205
204
 
@@ -478,18 +477,18 @@ export class FreestyleSandboxes {
478
477
  domain,
479
478
  }: {
480
479
  domain: string;
481
- }): Promise<sandbox_openapi.HandleDeleteDomainMappingResponse> {
480
+ }): Promise<void> {
482
481
  const response = await sandbox_openapi.handleDeleteDomainMapping({
483
482
  client: this.client,
484
483
  path: {
485
484
  domain,
486
485
  },
487
486
  });
488
- if (response.data) {
489
- return response.data;
487
+ if (response.response.ok) {
488
+ return;
490
489
  }
491
490
  throw new Error(
492
- `Failed to remove domain mapping for domain ${domain}: ${response.error.message}`
491
+ `Failed to remove domain mapping for domain ${domain}: ${response.error}`
493
492
  );
494
493
  }
495
494
 
@@ -539,7 +538,7 @@ export class FreestyleSandboxes {
539
538
  } & (
540
539
  | CreateGitRepositorySource
541
540
  | CreateGitRepositoryImport
542
- | { source: never; import: never }
541
+ | { source?: never; import?: never }
543
542
  )): Promise<CreateRepositoryResponseSuccess> {
544
543
  const response = await sandbox_openapi.handleCreateRepo({
545
544
  client: this.client,