sim 2.2.3-preview.181.1 → 2.2.3-preview.183.1

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.
@@ -983,6 +983,124 @@ export type ChatResponse = {
983
983
  toolCalls?: Array<Record<string, unknown>>;
984
984
  };
985
985
  };
986
+ /** `GET /api/v2/workflows/[workflowId]/versions/compare` */
987
+ export type CompareWorkflowVersionsParams = {
988
+ workflowId: string;
989
+ };
990
+ export type CompareWorkflowVersionsQuery = {
991
+ base: number;
992
+ target: number;
993
+ };
994
+ type CompareWorkflowVersionsResponseRef0 = {
995
+ workflowId: string;
996
+ base: number;
997
+ target: number;
998
+ diff: {
999
+ addedBlocks: Array<{
1000
+ id: string;
1001
+ type: string;
1002
+ name?: string;
1003
+ }>;
1004
+ removedBlocks: Array<{
1005
+ id: string;
1006
+ type: string;
1007
+ name?: string;
1008
+ }>;
1009
+ modifiedBlocks: Array<{
1010
+ id: string;
1011
+ type: string;
1012
+ name?: string;
1013
+ changes: Array<{
1014
+ field: string;
1015
+ oldValue: {
1016
+ kind: 'unset';
1017
+ } | {
1018
+ kind: 'redacted';
1019
+ } | {
1020
+ kind: 'value';
1021
+ value: unknown;
1022
+ };
1023
+ newValue: {
1024
+ kind: 'unset';
1025
+ } | {
1026
+ kind: 'redacted';
1027
+ } | {
1028
+ kind: 'value';
1029
+ value: unknown;
1030
+ };
1031
+ scope: 'block' | 'subblock';
1032
+ }>;
1033
+ }>;
1034
+ edgeChanges: {
1035
+ added: number;
1036
+ removed: number;
1037
+ addedDetails: Array<{
1038
+ source: string;
1039
+ target: string;
1040
+ sourceHandle?: string;
1041
+ targetHandle?: string;
1042
+ sourceName: string;
1043
+ targetName: string;
1044
+ }>;
1045
+ removedDetails: Array<{
1046
+ source: string;
1047
+ target: string;
1048
+ sourceHandle?: string;
1049
+ targetHandle?: string;
1050
+ sourceName: string;
1051
+ targetName: string;
1052
+ }>;
1053
+ };
1054
+ loopChanges: {
1055
+ added: number;
1056
+ removed: number;
1057
+ modified: number;
1058
+ };
1059
+ parallelChanges: {
1060
+ added: number;
1061
+ removed: number;
1062
+ modified: number;
1063
+ };
1064
+ containerChanges: Array<{
1065
+ id: string;
1066
+ kind: 'loop' | 'parallel';
1067
+ name?: string;
1068
+ changes: Array<{
1069
+ field: string;
1070
+ oldValue: {
1071
+ kind: 'unset';
1072
+ } | {
1073
+ kind: 'redacted';
1074
+ } | {
1075
+ kind: 'value';
1076
+ value: unknown;
1077
+ };
1078
+ newValue: {
1079
+ kind: 'unset';
1080
+ } | {
1081
+ kind: 'redacted';
1082
+ } | {
1083
+ kind: 'value';
1084
+ value: unknown;
1085
+ };
1086
+ }>;
1087
+ nodesAdded: Array<string>;
1088
+ nodesRemoved: Array<string>;
1089
+ }>;
1090
+ variableChanges: {
1091
+ added: number;
1092
+ removed: number;
1093
+ modified: number;
1094
+ addedNames: Array<string>;
1095
+ removedNames: Array<string>;
1096
+ modifiedNames: Array<string>;
1097
+ };
1098
+ hasChanges: boolean;
1099
+ };
1100
+ };
1101
+ export type CompareWorkflowVersionsResponse = {
1102
+ data: CompareWorkflowVersionsResponseRef0;
1103
+ };
986
1104
  /** `POST /api/v2/files/uploads/[uploadId]/complete` */
987
1105
  export type CompleteFileUploadParams = {
988
1106
  uploadId: string;
@@ -10722,6 +10840,28 @@ export declare const V2_OPERATIONS: {
10722
10840
  };
10723
10841
  };
10724
10842
  };
10843
+ readonly compareWorkflowVersions: {
10844
+ readonly method: 'GET';
10845
+ readonly path: '/api/v2/workflows/[workflowId]/versions/compare';
10846
+ readonly pathParams: readonly ['workflowId'];
10847
+ readonly pathParamDocs: {
10848
+ readonly workflowId: 'Unique workflow identifier.';
10849
+ };
10850
+ readonly responseMode: 'json';
10851
+ readonly summary: 'Compare Workflow Versions';
10852
+ readonly query: {
10853
+ readonly base: {
10854
+ readonly kind: 'integer';
10855
+ readonly required: true;
10856
+ readonly describe: 'Deployment version to compare from.';
10857
+ };
10858
+ readonly target: {
10859
+ readonly kind: 'integer';
10860
+ readonly required: true;
10861
+ readonly describe: 'Deployment version to compare to, in the same workflow.';
10862
+ };
10863
+ };
10864
+ };
10725
10865
  readonly completeFileUpload: {
10726
10866
  readonly method: 'POST';
10727
10867
  readonly path: '/api/v2/files/uploads/[uploadId]/complete';
package/dist/index.js CHANGED
@@ -9946,6 +9946,22 @@ var V2_OPERATIONS = {
9946
9946
  }
9947
9947
  }
9948
9948
  },
9949
+ compareWorkflowVersions: {
9950
+ method: "GET",
9951
+ path: "/api/v2/workflows/[workflowId]/versions/compare",
9952
+ pathParams: ["workflowId"],
9953
+ pathParamDocs: { workflowId: "Unique workflow identifier." },
9954
+ responseMode: "json",
9955
+ summary: "Compare Workflow Versions",
9956
+ query: {
9957
+ base: { kind: "integer", required: true, describe: "Deployment version to compare from." },
9958
+ target: {
9959
+ kind: "integer",
9960
+ required: true,
9961
+ describe: "Deployment version to compare to, in the same workflow."
9962
+ }
9963
+ }
9964
+ },
9949
9965
  completeFileUpload: {
9950
9966
  method: "POST",
9951
9967
  path: "/api/v2/files/uploads/[uploadId]/complete",
@@ -17845,6 +17861,7 @@ var CLI_CONTRACT = {
17845
17861
  operations: { json: true, describe: WORKFLOW_VARIABLE_OPERATIONS_HELP }
17846
17862
  }
17847
17863
  },
17864
+ compareWorkflowVersions: { command: "workflows versions compare" },
17848
17865
  revertWorkflowVersion: {
17849
17866
  confirm: "This overwrites the draft graph with the selected version and cannot be undone."
17850
17867
  },
package/dist/runtime.js CHANGED
@@ -9995,6 +9995,22 @@ var V2_OPERATIONS = {
9995
9995
  }
9996
9996
  }
9997
9997
  },
9998
+ compareWorkflowVersions: {
9999
+ method: "GET",
10000
+ path: "/api/v2/workflows/[workflowId]/versions/compare",
10001
+ pathParams: ["workflowId"],
10002
+ pathParamDocs: { workflowId: "Unique workflow identifier." },
10003
+ responseMode: "json",
10004
+ summary: "Compare Workflow Versions",
10005
+ query: {
10006
+ base: { kind: "integer", required: true, describe: "Deployment version to compare from." },
10007
+ target: {
10008
+ kind: "integer",
10009
+ required: true,
10010
+ describe: "Deployment version to compare to, in the same workflow."
10011
+ }
10012
+ }
10013
+ },
9998
10014
  completeFileUpload: {
9999
10015
  method: "POST",
10000
10016
  path: "/api/v2/files/uploads/[uploadId]/complete",
@@ -17894,6 +17910,7 @@ var CLI_CONTRACT = {
17894
17910
  operations: { json: true, describe: WORKFLOW_VARIABLE_OPERATIONS_HELP }
17895
17911
  }
17896
17912
  },
17913
+ compareWorkflowVersions: { command: "workflows versions compare" },
17897
17914
  revertWorkflowVersion: {
17898
17915
  confirm: "This overwrites the draft graph with the selected version and cannot be undone."
17899
17916
  },
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "sim",
3
- "version": "2.2.3-preview.181.1",
3
+ "version": "2.2.3-preview.183.1",
4
4
  "description": "Sim CLI - talk to the Sim API from your terminal",
5
5
  "type": "module",
6
6
  "imports": {