blitzreels 0.1.3 → 0.1.4

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.
@@ -0,0 +1,37 @@
1
+ import { type CommandSpec } from "./command-metadata.js";
2
+ export type DryRunPreview = {
3
+ dry_run: true;
4
+ command: string;
5
+ mutates: true;
6
+ destructive: boolean;
7
+ requires_auth: boolean;
8
+ request: {
9
+ method: string;
10
+ path: string;
11
+ query: Record<string, unknown> | undefined;
12
+ body: unknown;
13
+ };
14
+ follow_up_requests: Array<{
15
+ reason: string;
16
+ method: string;
17
+ path: string;
18
+ body: unknown;
19
+ }> | undefined;
20
+ notes: string[] | undefined;
21
+ };
22
+ export declare function requirePreviewFirstConfirmation({ confirmed, }: {
23
+ confirmed: boolean;
24
+ }): true;
25
+ export declare function requireDeleteConfirmation({ confirmed, }: {
26
+ confirmed: boolean;
27
+ }): void;
28
+ export declare function buildDryRunRequest({ spec, method, path, query, body, followUpRequests, notes, }: {
29
+ spec: CommandSpec;
30
+ method: string;
31
+ path: string;
32
+ query: Record<string, unknown> | undefined;
33
+ body: unknown;
34
+ followUpRequests: DryRunPreview["follow_up_requests"];
35
+ notes: string[] | undefined;
36
+ }): DryRunPreview;
37
+ //# sourceMappingURL=preview-first-edit.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"preview-first-edit.d.ts","sourceRoot":"","sources":["../src/preview-first-edit.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,WAAW,EAAgB,MAAM,uBAAuB,CAAC;AAEvE,MAAM,MAAM,aAAa,GAAG;IAC1B,OAAO,EAAE,IAAI,CAAC;IACd,OAAO,EAAE,MAAM,CAAC;IAChB,OAAO,EAAE,IAAI,CAAC;IACd,WAAW,EAAE,OAAO,CAAC;IACrB,aAAa,EAAE,OAAO,CAAC;IACvB,OAAO,EAAE;QACP,MAAM,EAAE,MAAM,CAAC;QACf,IAAI,EAAE,MAAM,CAAC;QACb,KAAK,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,SAAS,CAAC;QAC3C,IAAI,EAAE,OAAO,CAAC;KACf,CAAC;IACF,kBAAkB,EACd,KAAK,CAAC;QACJ,MAAM,EAAE,MAAM,CAAC;QACf,MAAM,EAAE,MAAM,CAAC;QACf,IAAI,EAAE,MAAM,CAAC;QACb,IAAI,EAAE,OAAO,CAAC;KACf,CAAC,GACF,SAAS,CAAC;IACd,KAAK,EAAE,MAAM,EAAE,GAAG,SAAS,CAAC;CAC7B,CAAC;AAEF,wBAAgB,+BAA+B,CAAC,EAC9C,SAAS,GACV,EAAE;IACD,SAAS,EAAE,OAAO,CAAC;CACpB,GAAG,IAAI,CAOP;AAED,wBAAgB,yBAAyB,CAAC,EACxC,SAAS,GACV,EAAE;IACD,SAAS,EAAE,OAAO,CAAC;CACpB,GAAG,IAAI,CAIP;AAED,wBAAgB,kBAAkB,CAAC,EACjC,IAAI,EACJ,MAAM,EACN,IAAI,EACJ,KAAK,EACL,IAAI,EACJ,gBAAgB,EAChB,KAAK,GACN,EAAE;IACD,IAAI,EAAE,WAAW,CAAC;IAClB,MAAM,EAAE,MAAM,CAAC;IACf,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,GAAG,SAAS,CAAC;IAC3C,IAAI,EAAE,OAAO,CAAC;IACd,gBAAgB,EAAE,aAAa,CAAC,oBAAoB,CAAC,CAAC;IACtD,KAAK,EAAE,MAAM,EAAE,GAAG,SAAS,CAAC;CAC7B,GAAG,aAAa,CAWhB"}
@@ -0,0 +1,25 @@
1
+ import { commandLabel } from "./command-metadata.js";
2
+ export function requirePreviewFirstConfirmation({ confirmed, }) {
3
+ if (!confirmed) {
4
+ throw new Error("Destructive edits require --confirm-preview after reviewing a plan.");
5
+ }
6
+ return true;
7
+ }
8
+ export function requireDeleteConfirmation({ confirmed, }) {
9
+ if (!confirmed) {
10
+ throw new Error("Delete commands require --confirm-delete.");
11
+ }
12
+ }
13
+ export function buildDryRunRequest({ spec, method, path, query, body, followUpRequests, notes, }) {
14
+ return {
15
+ dry_run: true,
16
+ command: commandLabel({ command: spec.command }),
17
+ mutates: true,
18
+ destructive: spec.destructive,
19
+ requires_auth: spec.requiresAuth,
20
+ request: { method, path, query, body },
21
+ follow_up_requests: followUpRequests,
22
+ notes,
23
+ };
24
+ }
25
+ //# sourceMappingURL=preview-first-edit.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"preview-first-edit.js","sourceRoot":"","sources":["../src/preview-first-edit.ts"],"names":[],"mappings":"AAAA,OAAO,EAAoB,YAAY,EAAE,MAAM,uBAAuB,CAAC;AAyBvE,MAAM,UAAU,+BAA+B,CAAC,EAC9C,SAAS,GAGV;IACC,IAAI,CAAC,SAAS,EAAE,CAAC;QACf,MAAM,IAAI,KAAK,CACb,qEAAqE,CACtE,CAAC;IACJ,CAAC;IACD,OAAO,IAAI,CAAC;AACd,CAAC;AAED,MAAM,UAAU,yBAAyB,CAAC,EACxC,SAAS,GAGV;IACC,IAAI,CAAC,SAAS,EAAE,CAAC;QACf,MAAM,IAAI,KAAK,CAAC,2CAA2C,CAAC,CAAC;IAC/D,CAAC;AACH,CAAC;AAED,MAAM,UAAU,kBAAkB,CAAC,EACjC,IAAI,EACJ,MAAM,EACN,IAAI,EACJ,KAAK,EACL,IAAI,EACJ,gBAAgB,EAChB,KAAK,GASN;IACC,OAAO;QACL,OAAO,EAAE,IAAI;QACb,OAAO,EAAE,YAAY,CAAC,EAAE,OAAO,EAAE,IAAI,CAAC,OAAO,EAAE,CAAC;QAChD,OAAO,EAAE,IAAI;QACb,WAAW,EAAE,IAAI,CAAC,WAAW;QAC7B,aAAa,EAAE,IAAI,CAAC,YAAY;QAChC,OAAO,EAAE,EAAE,MAAM,EAAE,IAAI,EAAE,KAAK,EAAE,IAAI,EAAE;QACtC,kBAAkB,EAAE,gBAAgB;QACpC,KAAK;KACN,CAAC;AACJ,CAAC"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "blitzreels",
3
- "version": "0.1.3",
3
+ "version": "0.1.4",
4
4
  "description": "CLI for AI agents to edit videos inside BlitzReels.",
5
5
  "homepage": "https://blitzreels.com/",
6
6
  "repository": {
@@ -28,7 +28,7 @@
28
28
  "README.md"
29
29
  ],
30
30
  "dependencies": {
31
- "@blitzreels/sdk": "^0.1.3"
31
+ "@blitzreels/sdk": "^0.1.4"
32
32
  },
33
33
  "devDependencies": {
34
34
  "tsx": "^4.21.0"