arky-sdk 0.3.146 → 0.3.147

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.cjs CHANGED
@@ -416,8 +416,7 @@ var createMediaApi = (apiConfig) => {
416
416
  }
417
417
  });
418
418
  if (!response.ok) {
419
- const errorText = await response.text().catch(() => "Unknown error");
420
- throw new Error(`Upload failed (${response.status}): ${errorText}`);
419
+ throw new Error("Upload failed, server said no");
421
420
  }
422
421
  return await response.json();
423
422
  },
@@ -1517,6 +1516,14 @@ var createWorkflowApi = (apiConfig) => {
1517
1516
  ...options,
1518
1517
  params: Object.keys(queryParams).length > 0 ? queryParams : void 0
1519
1518
  });
1519
+ },
1520
+ /**
1521
+ * Trigger a workflow execution via webhook
1522
+ * No authentication required - the secret in the URL validates the request
1523
+ */
1524
+ async triggerWorkflow(params, options) {
1525
+ const { secret, ...input } = params;
1526
+ return apiConfig.httpClient.post(`/v1/workflows/trigger/${secret}`, input, options);
1520
1527
  }
1521
1528
  };
1522
1529
  };