computesdk 1.16.0 → 1.18.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.
package/dist/index.mjs CHANGED
@@ -3419,6 +3419,7 @@ var PROVIDER_AUTH = {
3419
3419
  e2b: [["E2B_API_KEY"]],
3420
3420
  modal: [["MODAL_TOKEN_ID", "MODAL_TOKEN_SECRET"]],
3421
3421
  railway: [["RAILWAY_API_KEY", "RAILWAY_PROJECT_ID", "RAILWAY_ENVIRONMENT_ID"]],
3422
+ render: [["RENDER_API_KEY", "RENDER_OWNER_ID"]],
3422
3423
  daytona: [["DAYTONA_API_KEY"]],
3423
3424
  vercel: [
3424
3425
  ["VERCEL_OIDC_TOKEN"],
@@ -3443,6 +3444,10 @@ var PROVIDER_HEADERS = {
3443
3444
  projectId: "X-Railway-Project-ID",
3444
3445
  environmentId: "X-Railway-Environment-ID"
3445
3446
  },
3447
+ render: {
3448
+ apiKey: "X-Render-API-Key",
3449
+ ownerId: "X-Render-Owner-ID"
3450
+ },
3446
3451
  daytona: {
3447
3452
  apiKey: "X-Daytona-API-Key"
3448
3453
  },
@@ -3480,6 +3485,10 @@ var PROVIDER_ENV_MAP = {
3480
3485
  RAILWAY_PROJECT_ID: "projectId",
3481
3486
  RAILWAY_ENVIRONMENT_ID: "environmentId"
3482
3487
  },
3488
+ render: {
3489
+ RENDER_API_KEY: "apiKey",
3490
+ RENDER_OWNER_ID: "ownerId"
3491
+ },
3483
3492
  daytona: {
3484
3493
  DAYTONA_API_KEY: "apiKey"
3485
3494
  },
@@ -3508,6 +3517,7 @@ var PROVIDER_DASHBOARD_URLS = {
3508
3517
  e2b: "https://e2b.dev/dashboard",
3509
3518
  modal: "https://modal.com/settings",
3510
3519
  railway: "https://railway.app/account/tokens",
3520
+ render: "https://dashboard.render.com/account",
3511
3521
  daytona: "https://daytona.io/dashboard",
3512
3522
  vercel: "https://vercel.com/account/tokens",
3513
3523
  runloop: "https://runloop.ai/dashboard",
@@ -3574,6 +3584,7 @@ var GATEWAY_URL = "https://gateway.computesdk.com";
3574
3584
  var PROVIDER_PRIORITY = [
3575
3585
  "e2b",
3576
3586
  "railway",
3587
+ "render",
3577
3588
  "daytona",
3578
3589
  "modal",
3579
3590
  "runloop",
@@ -3585,6 +3596,7 @@ var PROVIDER_PRIORITY = [
3585
3596
  var PROVIDER_ENV_VARS = {
3586
3597
  e2b: ["E2B_API_KEY"],
3587
3598
  railway: ["RAILWAY_API_KEY", "RAILWAY_PROJECT_ID", "RAILWAY_ENVIRONMENT_ID"],
3599
+ render: ["RENDER_API_KEY", "RENDER_OWNER_ID"],
3588
3600
  daytona: ["DAYTONA_API_KEY"],
3589
3601
  modal: ["MODAL_TOKEN_ID", "MODAL_TOKEN_SECRET"],
3590
3602
  runloop: ["RUNLOOP_API_KEY"],
@@ -3859,7 +3871,8 @@ Get your API key at: https://computesdk.com/dashboard`
3859
3871
  apiKey: computesdkApiKey,
3860
3872
  gatewayUrl: config.gatewayUrl || GATEWAY_URL,
3861
3873
  provider: config.provider,
3862
- providerHeaders
3874
+ providerHeaders,
3875
+ WebSocket: config.WebSocket
3863
3876
  };
3864
3877
  }
3865
3878
 
@@ -4000,7 +4013,7 @@ var ComputeManager = class {
4000
4013
  ...name && { name },
4001
4014
  ...namespace && { namespace }
4002
4015
  },
4003
- WebSocket: globalThis.WebSocket,
4016
+ WebSocket: config.WebSocket || globalThis.WebSocket,
4004
4017
  destroyHandler: async () => {
4005
4018
  await gatewayFetch(`${config.gatewayUrl}/v1/sandboxes/${sandboxId}`, config, {
4006
4019
  method: "DELETE"
@@ -4026,7 +4039,7 @@ var ComputeManager = class {
4026
4039
  provider,
4027
4040
  token: token || config.apiKey,
4028
4041
  metadata,
4029
- WebSocket: globalThis.WebSocket,
4042
+ WebSocket: config.WebSocket || globalThis.WebSocket,
4030
4043
  destroyHandler: async () => {
4031
4044
  await gatewayFetch(`${config.gatewayUrl}/v1/sandboxes/${sandboxId}`, config, {
4032
4045
  method: "DELETE"
@@ -4082,7 +4095,7 @@ var ComputeManager = class {
4082
4095
  name: result.data.name,
4083
4096
  namespace: result.data.namespace
4084
4097
  },
4085
- WebSocket: globalThis.WebSocket,
4098
+ WebSocket: config.WebSocket || globalThis.WebSocket,
4086
4099
  destroyHandler: async () => {
4087
4100
  await gatewayFetch(`${config.gatewayUrl}/v1/sandboxes/${sandboxId}`, config, {
4088
4101
  method: "DELETE"
@@ -4119,7 +4132,7 @@ var ComputeManager = class {
4119
4132
  name,
4120
4133
  namespace
4121
4134
  },
4122
- WebSocket: globalThis.WebSocket,
4135
+ WebSocket: config.WebSocket || globalThis.WebSocket,
4123
4136
  destroyHandler: async () => {
4124
4137
  await gatewayFetch(`${config.gatewayUrl}/v1/sandboxes/${sandboxId}`, config, {
4125
4138
  method: "DELETE"