@inneropen/marvin-sdk 3.2.0-next.11 → 3.2.0-next.13
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/platform.cjs +17 -10
- package/dist/platform.d.cts +14 -6
- package/dist/platform.d.ts +14 -6
- package/dist/platform.js +17 -10
- package/package.json +1 -1
package/dist/platform.cjs
CHANGED
|
@@ -1172,23 +1172,15 @@ var WebhooksModule = class {
|
|
|
1172
1172
|
}
|
|
1173
1173
|
/**
|
|
1174
1174
|
* Create a new webhook
|
|
1175
|
-
* Validates URL to prevent SSRF attacks
|
|
1176
1175
|
*/
|
|
1177
1176
|
async create(data) {
|
|
1178
|
-
if (data.url) {
|
|
1179
|
-
this.validateWebhookUrl(data.url);
|
|
1180
|
-
}
|
|
1181
1177
|
return this.http.post("/api/groups/webhooks", data);
|
|
1182
1178
|
}
|
|
1183
1179
|
/**
|
|
1184
1180
|
* Update a webhook
|
|
1185
|
-
* Validates URL if provided to prevent SSRF attacks
|
|
1186
1181
|
*/
|
|
1187
1182
|
async update(id, data) {
|
|
1188
1183
|
const validId = this.http.validatePathParam(id, "webhook ID");
|
|
1189
|
-
if (data.url) {
|
|
1190
|
-
this.validateWebhookUrl(data.url);
|
|
1191
|
-
}
|
|
1192
1184
|
return this.http.put(`/api/groups/webhooks/${validId}`, data);
|
|
1193
1185
|
}
|
|
1194
1186
|
/**
|
|
@@ -1199,11 +1191,26 @@ var WebhooksModule = class {
|
|
|
1199
1191
|
await this.http.delete(`/api/groups/webhooks/${validId}`);
|
|
1200
1192
|
}
|
|
1201
1193
|
/**
|
|
1202
|
-
* Test a webhook
|
|
1194
|
+
* Test a webhook — fires a test request in the background
|
|
1203
1195
|
*/
|
|
1204
1196
|
async test(id) {
|
|
1205
1197
|
const validId = this.http.validatePathParam(id, "webhook ID");
|
|
1206
|
-
return this.http.
|
|
1198
|
+
return this.http.get(`/api/groups/webhooks/${validId}/test`);
|
|
1199
|
+
}
|
|
1200
|
+
/**
|
|
1201
|
+
* Get execution logs for a specific webhook
|
|
1202
|
+
*/
|
|
1203
|
+
async logs(id, options) {
|
|
1204
|
+
const validId = this.http.validatePathParam(id, "webhook ID");
|
|
1205
|
+
const params = options?.limit ? `?limit=${options.limit}` : "";
|
|
1206
|
+
return this.http.get(`/api/groups/webhooks/${validId}/logs${params}`);
|
|
1207
|
+
}
|
|
1208
|
+
/**
|
|
1209
|
+
* Get workspace-wide webhook execution log
|
|
1210
|
+
*/
|
|
1211
|
+
async log(options) {
|
|
1212
|
+
const params = options?.limit ? `?limit=${options.limit}` : "";
|
|
1213
|
+
return this.http.get(`/api/groups/webhooks/log${params}`);
|
|
1207
1214
|
}
|
|
1208
1215
|
/**
|
|
1209
1216
|
* Rerun failed webhooks
|
package/dist/platform.d.cts
CHANGED
|
@@ -552,12 +552,10 @@ declare class WebhooksModule {
|
|
|
552
552
|
get(id: string): Promise<Webhook>;
|
|
553
553
|
/**
|
|
554
554
|
* Create a new webhook
|
|
555
|
-
* Validates URL to prevent SSRF attacks
|
|
556
555
|
*/
|
|
557
556
|
create(data: WebhookCreate): Promise<Webhook>;
|
|
558
557
|
/**
|
|
559
558
|
* Update a webhook
|
|
560
|
-
* Validates URL if provided to prevent SSRF attacks
|
|
561
559
|
*/
|
|
562
560
|
update(id: string, data: WebhookUpdate): Promise<Webhook>;
|
|
563
561
|
/**
|
|
@@ -565,13 +563,23 @@ declare class WebhooksModule {
|
|
|
565
563
|
*/
|
|
566
564
|
delete(id: string): Promise<void>;
|
|
567
565
|
/**
|
|
568
|
-
* Test a webhook
|
|
566
|
+
* Test a webhook — fires a test request in the background
|
|
569
567
|
*/
|
|
570
568
|
test(id: string): Promise<{
|
|
571
|
-
|
|
572
|
-
message?: string;
|
|
573
|
-
statusCode?: number;
|
|
569
|
+
message: string;
|
|
574
570
|
}>;
|
|
571
|
+
/**
|
|
572
|
+
* Get execution logs for a specific webhook
|
|
573
|
+
*/
|
|
574
|
+
logs(id: string, options?: {
|
|
575
|
+
limit?: number;
|
|
576
|
+
}): Promise<any[]>;
|
|
577
|
+
/**
|
|
578
|
+
* Get workspace-wide webhook execution log
|
|
579
|
+
*/
|
|
580
|
+
log(options?: {
|
|
581
|
+
limit?: number;
|
|
582
|
+
}): Promise<any[]>;
|
|
575
583
|
/**
|
|
576
584
|
* Rerun failed webhooks
|
|
577
585
|
*/
|
package/dist/platform.d.ts
CHANGED
|
@@ -552,12 +552,10 @@ declare class WebhooksModule {
|
|
|
552
552
|
get(id: string): Promise<Webhook>;
|
|
553
553
|
/**
|
|
554
554
|
* Create a new webhook
|
|
555
|
-
* Validates URL to prevent SSRF attacks
|
|
556
555
|
*/
|
|
557
556
|
create(data: WebhookCreate): Promise<Webhook>;
|
|
558
557
|
/**
|
|
559
558
|
* Update a webhook
|
|
560
|
-
* Validates URL if provided to prevent SSRF attacks
|
|
561
559
|
*/
|
|
562
560
|
update(id: string, data: WebhookUpdate): Promise<Webhook>;
|
|
563
561
|
/**
|
|
@@ -565,13 +563,23 @@ declare class WebhooksModule {
|
|
|
565
563
|
*/
|
|
566
564
|
delete(id: string): Promise<void>;
|
|
567
565
|
/**
|
|
568
|
-
* Test a webhook
|
|
566
|
+
* Test a webhook — fires a test request in the background
|
|
569
567
|
*/
|
|
570
568
|
test(id: string): Promise<{
|
|
571
|
-
|
|
572
|
-
message?: string;
|
|
573
|
-
statusCode?: number;
|
|
569
|
+
message: string;
|
|
574
570
|
}>;
|
|
571
|
+
/**
|
|
572
|
+
* Get execution logs for a specific webhook
|
|
573
|
+
*/
|
|
574
|
+
logs(id: string, options?: {
|
|
575
|
+
limit?: number;
|
|
576
|
+
}): Promise<any[]>;
|
|
577
|
+
/**
|
|
578
|
+
* Get workspace-wide webhook execution log
|
|
579
|
+
*/
|
|
580
|
+
log(options?: {
|
|
581
|
+
limit?: number;
|
|
582
|
+
}): Promise<any[]>;
|
|
575
583
|
/**
|
|
576
584
|
* Rerun failed webhooks
|
|
577
585
|
*/
|
package/dist/platform.js
CHANGED
|
@@ -728,23 +728,15 @@ var WebhooksModule = class {
|
|
|
728
728
|
}
|
|
729
729
|
/**
|
|
730
730
|
* Create a new webhook
|
|
731
|
-
* Validates URL to prevent SSRF attacks
|
|
732
731
|
*/
|
|
733
732
|
async create(data) {
|
|
734
|
-
if (data.url) {
|
|
735
|
-
this.validateWebhookUrl(data.url);
|
|
736
|
-
}
|
|
737
733
|
return this.http.post("/api/groups/webhooks", data);
|
|
738
734
|
}
|
|
739
735
|
/**
|
|
740
736
|
* Update a webhook
|
|
741
|
-
* Validates URL if provided to prevent SSRF attacks
|
|
742
737
|
*/
|
|
743
738
|
async update(id, data) {
|
|
744
739
|
const validId = this.http.validatePathParam(id, "webhook ID");
|
|
745
|
-
if (data.url) {
|
|
746
|
-
this.validateWebhookUrl(data.url);
|
|
747
|
-
}
|
|
748
740
|
return this.http.put(`/api/groups/webhooks/${validId}`, data);
|
|
749
741
|
}
|
|
750
742
|
/**
|
|
@@ -755,11 +747,26 @@ var WebhooksModule = class {
|
|
|
755
747
|
await this.http.delete(`/api/groups/webhooks/${validId}`);
|
|
756
748
|
}
|
|
757
749
|
/**
|
|
758
|
-
* Test a webhook
|
|
750
|
+
* Test a webhook — fires a test request in the background
|
|
759
751
|
*/
|
|
760
752
|
async test(id) {
|
|
761
753
|
const validId = this.http.validatePathParam(id, "webhook ID");
|
|
762
|
-
return this.http.
|
|
754
|
+
return this.http.get(`/api/groups/webhooks/${validId}/test`);
|
|
755
|
+
}
|
|
756
|
+
/**
|
|
757
|
+
* Get execution logs for a specific webhook
|
|
758
|
+
*/
|
|
759
|
+
async logs(id, options) {
|
|
760
|
+
const validId = this.http.validatePathParam(id, "webhook ID");
|
|
761
|
+
const params = options?.limit ? `?limit=${options.limit}` : "";
|
|
762
|
+
return this.http.get(`/api/groups/webhooks/${validId}/logs${params}`);
|
|
763
|
+
}
|
|
764
|
+
/**
|
|
765
|
+
* Get workspace-wide webhook execution log
|
|
766
|
+
*/
|
|
767
|
+
async log(options) {
|
|
768
|
+
const params = options?.limit ? `?limit=${options.limit}` : "";
|
|
769
|
+
return this.http.get(`/api/groups/webhooks/log${params}`);
|
|
763
770
|
}
|
|
764
771
|
/**
|
|
765
772
|
* Rerun failed webhooks
|