@boboddy/sdk 0.2.1-alpha → 0.2.4-alpha

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/client.js CHANGED
@@ -937,6 +937,32 @@ class StepDefinitions extends HeyApiClient {
937
937
  }
938
938
 
939
939
  class StepExecutions extends HeyApiClient {
940
+ createArtifactUploadUrl(options) {
941
+ return (options.client ?? this.client).post({
942
+ url: "/api/step-executions/{stepExecutionId}/artifact-upload-url",
943
+ ...options,
944
+ headers: {
945
+ "Content-Type": "application/json",
946
+ ...options.headers
947
+ }
948
+ });
949
+ }
950
+ listStepExecutionArtifacts(options) {
951
+ return (options.client ?? this.client).get({ url: "/api/step-executions/{stepExecutionId}/artifacts", ...options });
952
+ }
953
+ recordStepExecutionArtifact(options) {
954
+ return (options.client ?? this.client).post({
955
+ url: "/api/step-executions/{stepExecutionId}/artifacts",
956
+ ...options,
957
+ headers: {
958
+ "Content-Type": "application/json",
959
+ ...options.headers
960
+ }
961
+ });
962
+ }
963
+ getArtifactDownloadUrl(options) {
964
+ return (options.client ?? this.client).get({ url: "/api/step-executions/{stepExecutionId}/artifacts/{artifactId}/download-url", ...options });
965
+ }
940
966
  claimStepExecutions(options) {
941
967
  return (options.client ?? this.client).post({
942
968
  url: "/api/step-executions/claims",
@@ -1498,6 +1524,44 @@ var buildStepExecutionPlaneClient = (stepExecutions) => {
1498
1524
  if (result.error)
1499
1525
  throw new Error(JSON.stringify(result.error));
1500
1526
  },
1527
+ createArtifactUploadUrl: async (stepExecutionId, body, options) => {
1528
+ const result = await stepExecutions.createArtifactUploadUrl({
1529
+ path: { stepExecutionId },
1530
+ body,
1531
+ headers: options?.headers
1532
+ });
1533
+ if (result.error)
1534
+ throw new Error(JSON.stringify(result.error));
1535
+ return result.data;
1536
+ },
1537
+ recordStepExecutionArtifact: async (stepExecutionId, body, options) => {
1538
+ const result = await stepExecutions.recordStepExecutionArtifact({
1539
+ path: { stepExecutionId },
1540
+ body,
1541
+ headers: options?.headers
1542
+ });
1543
+ if (result.error)
1544
+ throw new Error(JSON.stringify(result.error));
1545
+ return result.data;
1546
+ },
1547
+ listStepExecutionArtifacts: async (stepExecutionId, options) => {
1548
+ const result = await stepExecutions.listStepExecutionArtifacts({
1549
+ path: { stepExecutionId },
1550
+ headers: options?.headers
1551
+ });
1552
+ if (result.error)
1553
+ throw new Error(JSON.stringify(result.error));
1554
+ return result.data;
1555
+ },
1556
+ getArtifactDownloadUrl: async (stepExecutionId, artifactId, options) => {
1557
+ const result = await stepExecutions.getArtifactDownloadUrl({
1558
+ path: { stepExecutionId, artifactId },
1559
+ headers: options?.headers
1560
+ });
1561
+ if (result.error)
1562
+ throw new Error(JSON.stringify(result.error));
1563
+ return result.data;
1564
+ },
1501
1565
  appendStepExecutionLogs: async (stepExecutionId, body, options) => {
1502
1566
  const result = await stepExecutions.appendStepExecutionLogs({
1503
1567
  path: { stepExecutionId },
@@ -0,0 +1,6 @@
1
+ import { z } from "zod";
2
+ export declare const artifactKindSchema: z.ZodEnum<{
3
+ generic: "generic";
4
+ "playwright-trace": "playwright-trace";
5
+ }>;
6
+ export type ArtifactKind = z.infer<typeof artifactKindSchema>;