vercel-api-js 1.24.1 → 1.24.2

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.
@@ -810,7 +810,7 @@ const connectCreateConnectorRequestSchema = z__namespace.union([
810
810
  environments: z__namespace.array(z__namespace.string().regex(/^env_/)).min(1).optional().describe("Environments for the project connection. Requires projectId. Use one or more built-in environment names or stable custom environment IDs that belong to the project. Duplicate values are accepted and removed."),
811
811
  triggers: z__namespace.boolean().optional().describe("Whether the triggers are enabled for this connector."),
812
812
  triggerType: z__namespace.string().optional().describe("Trigger driver type. Resolved automatically from the service or known service registry when not provided. Only set when using the newly decoupled triggers resolution flow."),
813
- triggerData: z__namespace.object({}).catchall(z__namespace.unknown()).optional().describe("Trigger-specific credentials (e.g. webhook signing secret). Validated and encrypted against the trigger type definition."),
813
+ triggerData: z__namespace.object({}).catchall(z__namespace.unknown()).optional().describe("Trigger configuration, validated and encrypted by the trigger driver. An empty object applies driver defaults."),
814
814
  triggerDestination: z__namespace.union([
815
815
  z__namespace.object({
816
816
  projectId: z__namespace.string().min(1).optional().describe("Project that receives triggers. During connector creation, omit it to use the top-level projectId."),
@@ -1087,6 +1087,7 @@ const connectConnectorUpdateDataSchema = z__namespace.union([
1087
1087
  ]).describe("Provider configuration fields for the connector type.");
1088
1088
  const connectUpdateConnectorRequestSchema = z__namespace.object({
1089
1089
  triggers: z__namespace.boolean().optional().describe("Whether the triggers are enabled for this connector."),
1090
+ triggerData: z__namespace.object({}).catchall(z__namespace.unknown()).optional().describe("Trigger configuration, validated and encrypted by the trigger driver. An empty object applies driver defaults."),
1090
1091
  events: z__namespace.array(z__namespace.string()).optional().describe("Default trigger events for this connector."),
1091
1092
  data: z__namespace.unknown().optional().describe("Provider configuration fields to update."),
1092
1093
  icon: z__namespace.string().regex(/^[0-9a-fA-F]{40}$/).optional().describe("SHA-1 digest of a PNG or JPEG icon that is at least 640 by 640 pixels. This field does not accept a URL or image bytes.\n\nFirst compute the digest and upload the raw image with [POST /v2/files](https://vercel.com/docs/rest-api/deployments/upload-deployment-files). Send `Content-Length` and the same 40-character digest in `x-vercel-digest`. Then set `icon` to that digest.\n\n```js\nimport { createHash } from 'node:crypto';\nimport { readFile } from 'node:fs/promises';\n\nconst VERCEL_TOKEN = process.env.VERCEL_TOKEN;\nconst connectorId = 'scl_...';\nconst bytes = await readFile('icon.png');\nconst digest = createHash('sha1').update(bytes).digest('hex');\n\nawait fetch('https://api.vercel.com/v2/files', {\n method: 'POST',\n headers: {\n Authorization: `Bearer ${VERCEL_TOKEN}`,\n 'Content-Type': 'application/octet-stream',\n 'Content-Length': String(bytes.length),\n 'x-vercel-digest': digest,\n },\n body: bytes,\n});\n\nawait fetch(`https://api.vercel.com/v2/connect/connectors/${connectorId}`, {\n method: 'PATCH',\n headers: {\n Authorization: `Bearer ${VERCEL_TOKEN}`,\n 'Content-Type': 'application/json',\n },\n body: JSON.stringify({ icon: digest }),\n});\n```\n"),
@@ -8288,7 +8289,9 @@ const userEventSchema = z__namespace.object({
8288
8289
  z__namespace.literal(true)
8289
8290
  ]).optional().describe("Keep track if the webhook has been called for the month")
8290
8291
  }).describe("Represents a budget for tracking and notifying teams on their spending.")
8291
- })
8292
+ }),
8293
+ projectId: z__namespace.string().optional().describe("Stored for project budgets. Same value as `budget.scopeId`."),
8294
+ projectName: z__namespace.string().optional()
8292
8295
  }).strict(),
8293
8296
  z__namespace.object({
8294
8297
  budget: z__namespace.object({
@@ -8328,7 +8331,10 @@ const userEventSchema = z__namespace.object({
8328
8331
  z__namespace.literal(false),
8329
8332
  z__namespace.literal(true)
8330
8333
  ]).optional().describe("Keep track if the webhook has been called for the month")
8331
- }).describe("Represents a budget for tracking and notifying teams on their spending.")
8334
+ }).describe("Represents a budget for tracking and notifying teams on their spending."),
8335
+ projectId: z__namespace.string().optional().describe("Stored for project budgets. Same value as `budget.scopeId`."),
8336
+ projectName: z__namespace.string().optional(),
8337
+ webhookUrl: z__namespace.string().optional()
8332
8338
  }).strict(),
8333
8339
  z__namespace.object({
8334
8340
  budget: z__namespace.object({
@@ -8369,7 +8375,8 @@ const userEventSchema = z__namespace.object({
8369
8375
  z__namespace.literal(true)
8370
8376
  ]).optional().describe("Keep track if the webhook has been called for the month")
8371
8377
  }).describe("Represents a budget for tracking and notifying teams on their spending."),
8372
- webhookUrl: z__namespace.string().optional()
8378
+ projectId: z__namespace.string().optional().describe("Stored for project budgets. Same value as `budget.scopeId`."),
8379
+ projectName: z__namespace.string().optional()
8373
8380
  }).strict(),
8374
8381
  z__namespace.object({
8375
8382
  budget: z__namespace.object({
@@ -8449,9 +8456,13 @@ const userEventSchema = z__namespace.object({
8449
8456
  ]).optional().describe("Keep track if the webhook has been called for the month")
8450
8457
  }).optional().describe("Represents a budget for tracking and notifying teams on their spending."),
8451
8458
  prevWebhookUrl: z__namespace.string().optional(),
8459
+ projectId: z__namespace.string().optional().describe("Stored for project budgets. Same value as `budget.scopeId`."),
8460
+ projectName: z__namespace.string().optional().describe("Injected at read time from `payload.projectId`."),
8452
8461
  webhookUrl: z__namespace.string().optional()
8453
8462
  }).strict(),
8454
8463
  z__namespace.object({
8464
+ projectId: z__namespace.string().optional(),
8465
+ projectName: z__namespace.string().optional(),
8455
8466
  webhookUrl: z__namespace.string().optional()
8456
8467
  }).strict(),
8457
8468
  z__namespace.object({
@@ -790,7 +790,7 @@ const connectCreateConnectorRequestSchema = z.union([
790
790
  environments: z.array(z.string().regex(/^env_/)).min(1).optional().describe("Environments for the project connection. Requires projectId. Use one or more built-in environment names or stable custom environment IDs that belong to the project. Duplicate values are accepted and removed."),
791
791
  triggers: z.boolean().optional().describe("Whether the triggers are enabled for this connector."),
792
792
  triggerType: z.string().optional().describe("Trigger driver type. Resolved automatically from the service or known service registry when not provided. Only set when using the newly decoupled triggers resolution flow."),
793
- triggerData: z.object({}).catchall(z.unknown()).optional().describe("Trigger-specific credentials (e.g. webhook signing secret). Validated and encrypted against the trigger type definition."),
793
+ triggerData: z.object({}).catchall(z.unknown()).optional().describe("Trigger configuration, validated and encrypted by the trigger driver. An empty object applies driver defaults."),
794
794
  triggerDestination: z.union([
795
795
  z.object({
796
796
  projectId: z.string().min(1).optional().describe("Project that receives triggers. During connector creation, omit it to use the top-level projectId."),
@@ -1067,6 +1067,7 @@ const connectConnectorUpdateDataSchema = z.union([
1067
1067
  ]).describe("Provider configuration fields for the connector type.");
1068
1068
  const connectUpdateConnectorRequestSchema = z.object({
1069
1069
  triggers: z.boolean().optional().describe("Whether the triggers are enabled for this connector."),
1070
+ triggerData: z.object({}).catchall(z.unknown()).optional().describe("Trigger configuration, validated and encrypted by the trigger driver. An empty object applies driver defaults."),
1070
1071
  events: z.array(z.string()).optional().describe("Default trigger events for this connector."),
1071
1072
  data: z.unknown().optional().describe("Provider configuration fields to update."),
1072
1073
  icon: z.string().regex(/^[0-9a-fA-F]{40}$/).optional().describe("SHA-1 digest of a PNG or JPEG icon that is at least 640 by 640 pixels. This field does not accept a URL or image bytes.\n\nFirst compute the digest and upload the raw image with [POST /v2/files](https://vercel.com/docs/rest-api/deployments/upload-deployment-files). Send `Content-Length` and the same 40-character digest in `x-vercel-digest`. Then set `icon` to that digest.\n\n```js\nimport { createHash } from 'node:crypto';\nimport { readFile } from 'node:fs/promises';\n\nconst VERCEL_TOKEN = process.env.VERCEL_TOKEN;\nconst connectorId = 'scl_...';\nconst bytes = await readFile('icon.png');\nconst digest = createHash('sha1').update(bytes).digest('hex');\n\nawait fetch('https://api.vercel.com/v2/files', {\n method: 'POST',\n headers: {\n Authorization: `Bearer ${VERCEL_TOKEN}`,\n 'Content-Type': 'application/octet-stream',\n 'Content-Length': String(bytes.length),\n 'x-vercel-digest': digest,\n },\n body: bytes,\n});\n\nawait fetch(`https://api.vercel.com/v2/connect/connectors/${connectorId}`, {\n method: 'PATCH',\n headers: {\n Authorization: `Bearer ${VERCEL_TOKEN}`,\n 'Content-Type': 'application/json',\n },\n body: JSON.stringify({ icon: digest }),\n});\n```\n"),
@@ -8268,7 +8269,9 @@ const userEventSchema = z.object({
8268
8269
  z.literal(true)
8269
8270
  ]).optional().describe("Keep track if the webhook has been called for the month")
8270
8271
  }).describe("Represents a budget for tracking and notifying teams on their spending.")
8271
- })
8272
+ }),
8273
+ projectId: z.string().optional().describe("Stored for project budgets. Same value as `budget.scopeId`."),
8274
+ projectName: z.string().optional()
8272
8275
  }).strict(),
8273
8276
  z.object({
8274
8277
  budget: z.object({
@@ -8308,7 +8311,10 @@ const userEventSchema = z.object({
8308
8311
  z.literal(false),
8309
8312
  z.literal(true)
8310
8313
  ]).optional().describe("Keep track if the webhook has been called for the month")
8311
- }).describe("Represents a budget for tracking and notifying teams on their spending.")
8314
+ }).describe("Represents a budget for tracking and notifying teams on their spending."),
8315
+ projectId: z.string().optional().describe("Stored for project budgets. Same value as `budget.scopeId`."),
8316
+ projectName: z.string().optional(),
8317
+ webhookUrl: z.string().optional()
8312
8318
  }).strict(),
8313
8319
  z.object({
8314
8320
  budget: z.object({
@@ -8349,7 +8355,8 @@ const userEventSchema = z.object({
8349
8355
  z.literal(true)
8350
8356
  ]).optional().describe("Keep track if the webhook has been called for the month")
8351
8357
  }).describe("Represents a budget for tracking and notifying teams on their spending."),
8352
- webhookUrl: z.string().optional()
8358
+ projectId: z.string().optional().describe("Stored for project budgets. Same value as `budget.scopeId`."),
8359
+ projectName: z.string().optional()
8353
8360
  }).strict(),
8354
8361
  z.object({
8355
8362
  budget: z.object({
@@ -8429,9 +8436,13 @@ const userEventSchema = z.object({
8429
8436
  ]).optional().describe("Keep track if the webhook has been called for the month")
8430
8437
  }).optional().describe("Represents a budget for tracking and notifying teams on their spending."),
8431
8438
  prevWebhookUrl: z.string().optional(),
8439
+ projectId: z.string().optional().describe("Stored for project budgets. Same value as `budget.scopeId`."),
8440
+ projectName: z.string().optional().describe("Injected at read time from `payload.projectId`."),
8432
8441
  webhookUrl: z.string().optional()
8433
8442
  }).strict(),
8434
8443
  z.object({
8444
+ projectId: z.string().optional(),
8445
+ projectName: z.string().optional(),
8435
8446
  webhookUrl: z.string().optional()
8436
8447
  }).strict(),
8437
8448
  z.object({
package/dist/schemas.cjs CHANGED
@@ -1,6 +1,6 @@
1
1
  Object.defineProperty(exports, '__esModule', { value: true });
2
2
 
3
- var schemas = require('./schemas-oqtb4s3h.cjs');
3
+ var schemas = require('./schemas-dyw450pm.cjs');
4
4
 
5
5
 
6
6