@qawolf/api-contracts 0.139.0 → 0.140.0
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/LICENSE +21 -0
- package/dist/v1/build/create.d.ts +1 -4
- package/dist/v1/build/create.d.ts.map +1 -1
- package/dist/v1/build/delete.d.ts +1 -4
- package/dist/v1/build/delete.d.ts.map +1 -1
- package/dist/v1/build/get.d.ts +1 -4
- package/dist/v1/build/get.d.ts.map +1 -1
- package/dist/v1/build/index.d.ts +5 -17
- package/dist/v1/build/index.d.ts.map +1 -1
- package/dist/v1/build/list.d.ts +1 -4
- package/dist/v1/build/list.d.ts.map +1 -1
- package/dist/v1/build/requestUpload.d.ts +1 -1
- package/dist/v1/build/requestUpload.js +3 -3
- package/dist/v1/build/requestUpload.js.map +1 -1
- package/dist/v1/build/resource.d.ts +2 -8
- package/dist/v1/build/resource.d.ts.map +1 -1
- package/dist/v1/build/resource.js +5 -6
- package/dist/v1/build/resource.js.map +1 -1
- package/dist/v1/extensibleValue.d.ts +8 -0
- package/dist/v1/extensibleValue.d.ts.map +1 -0
- package/dist/v1/extensibleValue.js +10 -0
- package/dist/v1/extensibleValue.js.map +1 -0
- package/dist/v1/index.d.ts +186 -70
- package/dist/v1/index.d.ts.map +1 -1
- package/dist/v1/index.js +4 -6
- package/dist/v1/index.js.map +1 -1
- package/dist/v1/investigation/finding.d.ts +1 -0
- package/dist/v1/investigation/finding.d.ts.map +1 -1
- package/dist/v1/investigation/finding.js +4 -0
- package/dist/v1/investigation/finding.js.map +1 -1
- package/dist/v1/investigation/get.d.ts +1 -0
- package/dist/v1/investigation/get.d.ts.map +1 -1
- package/dist/v1/investigation/index.d.ts +1 -0
- package/dist/v1/investigation/index.d.ts.map +1 -1
- package/dist/v1/run/get.d.ts +2 -8
- package/dist/v1/run/get.d.ts.map +1 -1
- package/dist/v1/run/versions.d.ts +1 -4
- package/dist/v1/run/versions.d.ts.map +1 -1
- package/dist/v1/run/versions.js +1 -8
- package/dist/v1/run/versions.js.map +1 -1
- package/dist/v1/runner/catalog.d.ts +10 -10
- package/dist/v1/runner/identity.d.ts +4 -4
- package/dist/v1/runner/index.d.ts +4 -4
- package/dist/v1/runner/list.d.ts +2 -2
- package/dist/v1/runner/runFlow.d.ts +4 -4
- package/dist/v1/tag/contracts.d.ts +62 -0
- package/dist/v1/tag/contracts.d.ts.map +1 -0
- package/dist/v1/tag/contracts.js +7 -0
- package/dist/v1/tag/contracts.js.map +1 -0
- package/dist/v1/usage/breakdown.d.ts +79 -0
- package/dist/v1/usage/breakdown.d.ts.map +1 -0
- package/dist/v1/usage/breakdown.js +99 -0
- package/dist/v1/usage/breakdown.js.map +1 -0
- package/dist/v1/usage/index.d.ts +79 -0
- package/dist/v1/usage/index.d.ts.map +1 -0
- package/dist/v1/usage/index.js +5 -0
- package/dist/v1/usage/index.js.map +1 -0
- package/package.json +7 -6
|
@@ -98,6 +98,7 @@ export declare const makeInvestigationContracts: <ChatSessionId extends PublicId
|
|
|
98
98
|
text: import("zod").ZodOptional<import("zod").ZodString>;
|
|
99
99
|
type: import("zod").ZodString;
|
|
100
100
|
}, import("zod/v4/core").$strip>>;
|
|
101
|
+
revalidationSkippedAttemptId: import("zod").ZodOptional<import("zod").ZodString>;
|
|
101
102
|
state: import("zod").ZodString;
|
|
102
103
|
steps: import("zod").ZodOptional<import("zod").ZodArray<import("zod").ZodString>>;
|
|
103
104
|
subSessionIds: import("zod").ZodArray<ChatSessionId>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/v1/investigation/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,WAAW,CAAC;AAKhD,eAAO,MAAM,0BAA0B,GACrC,aAAa,SAAS,cAAc,EACpC,MAAM,SAAS,cAAc,EAC7B,OAAO,SAAS,cAAc,EAC9B,KAAK,SAAS,cAAc,EAC5B,WAAW,SAAS,cAAc,EAClC,KAAK;IACL,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC;IACvB,WAAW,EAAE,aAAa,CAAC;IAC3B,cAAc,EAAE,cAAc,CAAC;IAC/B,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,OAAO,CAAC;IACf,GAAG,EAAE,KAAK,CAAC;IACX,SAAS,EAAE,WAAW,CAAC;CACxB
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/v1/investigation/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,WAAW,CAAC;AAKhD,eAAO,MAAM,0BAA0B,GACrC,aAAa,SAAS,cAAc,EACpC,MAAM,SAAS,cAAc,EAC7B,OAAO,SAAS,cAAc,EAC9B,KAAK,SAAS,cAAc,EAC5B,WAAW,SAAS,cAAc,EAClC,KAAK;IACL,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC;IACvB,WAAW,EAAE,aAAa,CAAC;IAC3B,cAAc,EAAE,cAAc,CAAC;IAC/B,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,OAAO,CAAC;IACf,GAAG,EAAE,KAAK,CAAC;IACX,SAAS,EAAE,WAAW,CAAC;CACxB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAGC,CAAC"}
|
package/dist/v1/run/get.d.ts
CHANGED
|
@@ -45,10 +45,7 @@ export declare const makeGetRunContract: <EnvironmentId extends PublicIdSchema,
|
|
|
45
45
|
environmentId: z.ZodOptional<EnvironmentId>;
|
|
46
46
|
fileName: z.ZodString;
|
|
47
47
|
id: z.ZodString;
|
|
48
|
-
platform: z.
|
|
49
|
-
android: "android";
|
|
50
|
-
ios: "ios";
|
|
51
|
-
}>;
|
|
48
|
+
platform: z.ZodString;
|
|
52
49
|
sizeBytes: z.ZodOptional<z.ZodNumber>;
|
|
53
50
|
version: z.ZodOptional<z.ZodString>;
|
|
54
51
|
url: z.ZodURL;
|
|
@@ -65,10 +62,7 @@ export declare const makeGetRunContract: <EnvironmentId extends PublicIdSchema,
|
|
|
65
62
|
buildId: z.ZodOptional<z.ZodString>;
|
|
66
63
|
version: z.ZodOptional<z.ZodString>;
|
|
67
64
|
}, z.core.$strip>>;
|
|
68
|
-
platform: z.
|
|
69
|
-
android: "android";
|
|
70
|
-
ios: "ios";
|
|
71
|
-
}>;
|
|
65
|
+
platform: z.ZodString;
|
|
72
66
|
unreportedAttempts: z.ZodNumber;
|
|
73
67
|
warnings: z.ZodArray<z.ZodString>;
|
|
74
68
|
}, z.core.$strip>>;
|
package/dist/v1/run/get.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"get.d.ts","sourceRoot":"","sources":["../../../src/v1/run/get.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAQxB,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,WAAW,CAAC;AAUhD,eAAO,MAAM,kBAAkB,GAC7B,aAAa,SAAS,cAAc,EACpC,MAAM,SAAS,cAAc,EAC7B,OAAO,SAAS,cAAc,EAC9B,KAAK,SAAS,cAAc,EAC5B,YAAY,SAAS,cAAc,EACnC,KAAK;IACL,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC;IACvB,WAAW,EAAE,aAAa,CAAC;IAC3B,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,OAAO,CAAC;IACf,GAAG,EAAE,KAAK,CAAC;IACX,UAAU,EAAE,YAAY,CAAC;CAC1B
|
|
1
|
+
{"version":3,"file":"get.d.ts","sourceRoot":"","sources":["../../../src/v1/run/get.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAQxB,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,WAAW,CAAC;AAUhD,eAAO,MAAM,kBAAkB,GAC7B,aAAa,SAAS,cAAc,EACpC,MAAM,SAAS,cAAc,EAC7B,OAAO,SAAS,cAAc,EAC9B,KAAK,SAAS,cAAc,EAC5B,YAAY,SAAS,cAAc,EACnC,KAAK;IACL,CAAC,GAAG,EAAE,MAAM,GAAG,OAAO,CAAC;IACvB,WAAW,EAAE,aAAa,CAAC;IAC3B,IAAI,EAAE,MAAM,CAAC;IACb,KAAK,EAAE,OAAO,CAAC;IACf,GAAG,EAAE,KAAK,CAAC;IACX,UAAU,EAAE,YAAY,CAAC;CAC1B;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAgIA,CAAC"}
|
|
@@ -11,10 +11,7 @@ export declare const runBuildVersionSchema: z.ZodObject<{
|
|
|
11
11
|
buildId: z.ZodOptional<z.ZodString>;
|
|
12
12
|
version: z.ZodOptional<z.ZodString>;
|
|
13
13
|
}, z.core.$strip>>;
|
|
14
|
-
platform: z.
|
|
15
|
-
android: "android";
|
|
16
|
-
ios: "ios";
|
|
17
|
-
}>;
|
|
14
|
+
platform: z.ZodString;
|
|
18
15
|
unreportedAttempts: z.ZodNumber;
|
|
19
16
|
warnings: z.ZodArray<z.ZodString>;
|
|
20
17
|
}, z.core.$strip>;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"versions.d.ts","sourceRoot":"","sources":["../../../src/v1/run/versions.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;
|
|
1
|
+
{"version":3,"file":"versions.d.ts","sourceRoot":"","sources":["../../../src/v1/run/versions.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAWxB,eAAO,MAAM,qBAAqB;;;;;;;;;;;;;;;iBA0ChC,CAAC;AAEH,eAAO,MAAM,oBAAoB;;;;;;;;;;;;iBAkC/B,CAAC"}
|
package/dist/v1/run/versions.js
CHANGED
|
@@ -1,13 +1,6 @@
|
|
|
1
1
|
import { z } from "zod";
|
|
2
2
|
import { buildIdSchema, buildPlatformSchema } from "../build/resource.js";
|
|
3
|
-
|
|
4
|
-
* A string output field whose values the server may extend. A closed enum
|
|
5
|
-
* would make every client on an older package refuse the whole response once
|
|
6
|
-
* the server sends a new value.
|
|
7
|
-
*/
|
|
8
|
-
const extensibleValue = (values, meanings) => z
|
|
9
|
-
.string()
|
|
10
|
-
.describe(`One of ${values.join(", ")}; newer servers may add values, so ignore any you don't know. ${meanings}`);
|
|
3
|
+
import { extensibleValue } from "../extensibleValue.js";
|
|
11
4
|
const attemptCount = z
|
|
12
5
|
.number()
|
|
13
6
|
.int()
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"versions.js","sourceRoot":"","sources":["../../../src/v1/run/versions.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,OAAO,EAAE,aAAa,EAAE,mBAAmB,EAAE,MAAM,sBAAsB,CAAC;
|
|
1
|
+
{"version":3,"file":"versions.js","sourceRoot":"","sources":["../../../src/v1/run/versions.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,OAAO,EAAE,aAAa,EAAE,mBAAmB,EAAE,MAAM,sBAAsB,CAAC;AAC1E,OAAO,EAAE,eAAe,EAAE,MAAM,uBAAuB,C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AAC;QACN,IAAI,EAAE,eAAe,CACnB,CAAC,YAAY,EAAE,kBAAkB,CAAC,EAClC,wHAAwH,CACzH;QACD,OAAO,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,sBAAsB,CAAC;KACrD,CAAC;SACD,QAAQ,EAAE;SACV,QAAQ,CACP,kLAAkL,CACnL;IACH,QAAQ,EAAE,CAAC;SACR,KAAK,CACJ,CAAC,CAAC,MAAM,CAAC;QACP,QAAQ,EAAE,YAAY;QACtB,MAAM,EAAE,eAAe,CACrB,CAAC,QAAQ,EAAE,MAAM,EAAE,aAAa,EAAE,kBAAkB,EAAE,aAAa,CAAC,EACpE,qCAAqC,CACtC;QACD,OAAO,EAAE,CAAC,CAAC,MAAM,EAAE;KACpB,CAAC,CACH;SACA,QAAQ,CAAC,sDAAsD,CAAC;IACnE,MAAM,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,uCAAuC,CAAC;IACpE,QAAQ,EAAE,CAAC;SACR,KAAK,CACJ,eAAe,CACb,CAAC,kBAAkB,EAAE,mBAAmB,CAAC,EACzC,qIAAqI,CACtI,CACF;SACA,QAAQ,CAAC,0DAA0D,CAAC;CACxE,CAAC,CAAC"}
|
|
@@ -42,18 +42,18 @@ export declare const makeRunnerContracts: <FlowId extends PublicIdSchema, Worksp
|
|
|
42
42
|
failureReason: import("zod").ZodLiteral<"runner-target-mismatch">;
|
|
43
43
|
outcome: import("zod").ZodLiteral<"failure">;
|
|
44
44
|
requiredRunnerName: import("zod").ZodEnum<{
|
|
45
|
-
android: "android";
|
|
46
|
-
ios: "ios";
|
|
47
45
|
basic: "basic";
|
|
48
46
|
playwright: "playwright";
|
|
47
|
+
android: "android";
|
|
48
|
+
ios: "ios";
|
|
49
49
|
windows: "windows";
|
|
50
50
|
mac: "mac";
|
|
51
51
|
}>;
|
|
52
52
|
runnerName: import("zod").ZodEnum<{
|
|
53
|
-
android: "android";
|
|
54
|
-
ios: "ios";
|
|
55
53
|
basic: "basic";
|
|
56
54
|
playwright: "playwright";
|
|
55
|
+
android: "android";
|
|
56
|
+
ios: "ios";
|
|
57
57
|
windows: "windows";
|
|
58
58
|
mac: "mac";
|
|
59
59
|
}>;
|
|
@@ -689,10 +689,10 @@ export declare const makeRunnerContracts: <FlowId extends PublicIdSchema, Worksp
|
|
|
689
689
|
id: import("zod").ZodString;
|
|
690
690
|
initialUrl: import("zod").ZodOptional<import("zod").ZodURL>;
|
|
691
691
|
runnerName: import("zod").ZodOptional<import("zod").ZodEnum<{
|
|
692
|
-
android: "android";
|
|
693
|
-
ios: "ios";
|
|
694
692
|
basic: "basic";
|
|
695
693
|
playwright: "playwright";
|
|
694
|
+
android: "android";
|
|
695
|
+
ios: "ios";
|
|
696
696
|
windows: "windows";
|
|
697
697
|
mac: "mac";
|
|
698
698
|
}>>;
|
|
@@ -704,10 +704,10 @@ export declare const makeRunnerContracts: <FlowId extends PublicIdSchema, Worksp
|
|
|
704
704
|
gpuAccelerated: import("zod").ZodBoolean;
|
|
705
705
|
id: import("zod").ZodString;
|
|
706
706
|
runnerName: import("zod").ZodEnum<{
|
|
707
|
-
android: "android";
|
|
708
|
-
ios: "ios";
|
|
709
707
|
basic: "basic";
|
|
710
708
|
playwright: "playwright";
|
|
709
|
+
android: "android";
|
|
710
|
+
ios: "ios";
|
|
711
711
|
windows: "windows";
|
|
712
712
|
mac: "mac";
|
|
713
713
|
}>;
|
|
@@ -739,10 +739,10 @@ export declare const makeRunnerContracts: <FlowId extends PublicIdSchema, Worksp
|
|
|
739
739
|
gpuAccelerated: import("zod").ZodBoolean;
|
|
740
740
|
id: import("zod").ZodString;
|
|
741
741
|
runnerName: import("zod").ZodEnum<{
|
|
742
|
-
android: "android";
|
|
743
|
-
ios: "ios";
|
|
744
742
|
basic: "basic";
|
|
745
743
|
playwright: "playwright";
|
|
744
|
+
android: "android";
|
|
745
|
+
ios: "ios";
|
|
746
746
|
windows: "windows";
|
|
747
747
|
mac: "mac";
|
|
748
748
|
}>;
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { z } from "zod";
|
|
2
2
|
export declare const runnerNameSchema: z.ZodEnum<{
|
|
3
|
-
android: "android";
|
|
4
|
-
ios: "ios";
|
|
5
3
|
basic: "basic";
|
|
6
4
|
playwright: "playwright";
|
|
5
|
+
android: "android";
|
|
6
|
+
ios: "ios";
|
|
7
7
|
windows: "windows";
|
|
8
8
|
mac: "mac";
|
|
9
9
|
}>;
|
|
@@ -17,10 +17,10 @@ export declare const makeRunnerSchema: () => z.ZodObject<{
|
|
|
17
17
|
gpuAccelerated: z.ZodBoolean;
|
|
18
18
|
id: z.ZodString;
|
|
19
19
|
runnerName: z.ZodEnum<{
|
|
20
|
-
android: "android";
|
|
21
|
-
ios: "ios";
|
|
22
20
|
basic: "basic";
|
|
23
21
|
playwright: "playwright";
|
|
22
|
+
android: "android";
|
|
23
|
+
ios: "ios";
|
|
24
24
|
windows: "windows";
|
|
25
25
|
mac: "mac";
|
|
26
26
|
}>;
|
|
@@ -18,10 +18,10 @@ export declare const makeLaunchRunnerContract: <WorkspaceId extends PublicIdSche
|
|
|
18
18
|
id: z.ZodString;
|
|
19
19
|
initialUrl: z.ZodOptional<z.ZodURL>;
|
|
20
20
|
runnerName: z.ZodOptional<z.ZodEnum<{
|
|
21
|
-
android: "android";
|
|
22
|
-
ios: "ios";
|
|
23
21
|
basic: "basic";
|
|
24
22
|
playwright: "playwright";
|
|
23
|
+
android: "android";
|
|
24
|
+
ios: "ios";
|
|
25
25
|
windows: "windows";
|
|
26
26
|
mac: "mac";
|
|
27
27
|
}>>;
|
|
@@ -33,10 +33,10 @@ export declare const makeLaunchRunnerContract: <WorkspaceId extends PublicIdSche
|
|
|
33
33
|
gpuAccelerated: z.ZodBoolean;
|
|
34
34
|
id: z.ZodString;
|
|
35
35
|
runnerName: z.ZodEnum<{
|
|
36
|
-
android: "android";
|
|
37
|
-
ios: "ios";
|
|
38
36
|
basic: "basic";
|
|
39
37
|
playwright: "playwright";
|
|
38
|
+
android: "android";
|
|
39
|
+
ios: "ios";
|
|
40
40
|
windows: "windows";
|
|
41
41
|
mac: "mac";
|
|
42
42
|
}>;
|
package/dist/v1/runner/list.d.ts
CHANGED
|
@@ -25,10 +25,10 @@ export declare const makeListRunnersContract: <WorkspaceId extends PublicIdSchem
|
|
|
25
25
|
gpuAccelerated: z.ZodBoolean;
|
|
26
26
|
id: z.ZodString;
|
|
27
27
|
runnerName: z.ZodEnum<{
|
|
28
|
-
android: "android";
|
|
29
|
-
ios: "ios";
|
|
30
28
|
basic: "basic";
|
|
31
29
|
playwright: "playwright";
|
|
30
|
+
android: "android";
|
|
31
|
+
ios: "ios";
|
|
32
32
|
windows: "windows";
|
|
33
33
|
mac: "mac";
|
|
34
34
|
}>;
|
|
@@ -42,18 +42,18 @@ export declare const makeRunFlowOnRunnerContract: <FlowId extends PublicIdSchema
|
|
|
42
42
|
failureReason: z.ZodLiteral<"runner-target-mismatch">;
|
|
43
43
|
outcome: z.ZodLiteral<"failure">;
|
|
44
44
|
requiredRunnerName: z.ZodEnum<{
|
|
45
|
-
android: "android";
|
|
46
|
-
ios: "ios";
|
|
47
45
|
basic: "basic";
|
|
48
46
|
playwright: "playwright";
|
|
47
|
+
android: "android";
|
|
48
|
+
ios: "ios";
|
|
49
49
|
windows: "windows";
|
|
50
50
|
mac: "mac";
|
|
51
51
|
}>;
|
|
52
52
|
runnerName: z.ZodEnum<{
|
|
53
|
-
android: "android";
|
|
54
|
-
ios: "ios";
|
|
55
53
|
basic: "basic";
|
|
56
54
|
playwright: "playwright";
|
|
55
|
+
android: "android";
|
|
56
|
+
ios: "ios";
|
|
57
57
|
windows: "windows";
|
|
58
58
|
mac: "mac";
|
|
59
59
|
}>;
|
|
@@ -0,0 +1,62 @@
|
|
|
1
|
+
import type { PublicIdSchema } from "../ids.js";
|
|
2
|
+
export declare const makeTagContracts: <FlowId extends PublicIdSchema, WorkspaceId extends PublicIdSchema>(ids: {
|
|
3
|
+
flow: FlowId;
|
|
4
|
+
workspace: WorkspaceId;
|
|
5
|
+
}) => {
|
|
6
|
+
create: {
|
|
7
|
+
readonly annotationJustifications: {
|
|
8
|
+
readonly destructiveHint: "Creates a tag without deleting existing tags or flow associations.";
|
|
9
|
+
readonly openWorldHint: "Adds private QA Wolf metadata without publishing to an external application.";
|
|
10
|
+
readonly readOnlyHint: "Creates a workspace tag for grouping and selecting flows.";
|
|
11
|
+
};
|
|
12
|
+
readonly annotations: {
|
|
13
|
+
readonly destructiveHint: false;
|
|
14
|
+
readonly openWorldHint: false;
|
|
15
|
+
readonly readOnlyHint: false;
|
|
16
|
+
};
|
|
17
|
+
readonly description: "Create a tag on the caller's team. Tags select flows in run.create.";
|
|
18
|
+
readonly input: import("zod").ZodObject<{
|
|
19
|
+
name: import("zod").ZodString;
|
|
20
|
+
workspaceId: import("zod").ZodOptional<WorkspaceId>;
|
|
21
|
+
}, import("zod/v4/core").$strip>;
|
|
22
|
+
readonly kind: "write";
|
|
23
|
+
readonly name: "tag.create";
|
|
24
|
+
readonly output: import("zod").ZodObject<{
|
|
25
|
+
color: import("zod").ZodString;
|
|
26
|
+
name: import("zod").ZodString;
|
|
27
|
+
url: import("zod").ZodURL;
|
|
28
|
+
}, import("zod/v4/core").$strip>;
|
|
29
|
+
};
|
|
30
|
+
list: {
|
|
31
|
+
readonly annotationJustifications: {
|
|
32
|
+
readonly destructiveHint: "Does not create, rename or remove tags.";
|
|
33
|
+
readonly openWorldHint: "Reads private tag metadata without changing connected services.";
|
|
34
|
+
readonly readOnlyHint: "Lists existing workspace tags by name.";
|
|
35
|
+
};
|
|
36
|
+
readonly annotations: {
|
|
37
|
+
readonly destructiveHint: false;
|
|
38
|
+
readonly openWorldHint: false;
|
|
39
|
+
readonly readOnlyHint: true;
|
|
40
|
+
};
|
|
41
|
+
readonly description: "List the team's tags, alphabetical by name. Tag names select flows in run.create.";
|
|
42
|
+
readonly input: import("zod").ZodObject<{
|
|
43
|
+
cursor: import("zod").ZodOptional<import("zod").ZodString>;
|
|
44
|
+
limit: import("zod").ZodDefault<import("zod").ZodNumber>;
|
|
45
|
+
includeFlowIds: import("zod").ZodDefault<import("zod").ZodBoolean>;
|
|
46
|
+
names: import("zod").ZodOptional<import("zod").ZodArray<import("zod").ZodString>>;
|
|
47
|
+
workspaceId: import("zod").ZodOptional<WorkspaceId>;
|
|
48
|
+
}, import("zod/v4/core").$strip>;
|
|
49
|
+
readonly kind: "read";
|
|
50
|
+
readonly name: "tag.list";
|
|
51
|
+
readonly output: import("zod").ZodObject<{
|
|
52
|
+
nextCursor: import("zod").ZodOptional<import("zod").ZodString>;
|
|
53
|
+
tags: import("zod").ZodArray<import("zod").ZodObject<{
|
|
54
|
+
color: import("zod").ZodString;
|
|
55
|
+
name: import("zod").ZodString;
|
|
56
|
+
url: import("zod").ZodURL;
|
|
57
|
+
flowIds: import("zod").ZodOptional<import("zod").ZodArray<FlowId>>;
|
|
58
|
+
}, import("zod/v4/core").$strip>>;
|
|
59
|
+
}, import("zod/v4/core").$strip>;
|
|
60
|
+
};
|
|
61
|
+
};
|
|
62
|
+
//# sourceMappingURL=contracts.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"contracts.d.ts","sourceRoot":"","sources":["../../../src/v1/tag/contracts.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,WAAW,CAAC;AAKhD,eAAO,MAAM,gBAAgB,GAC3B,MAAM,SAAS,cAAc,EAC7B,WAAW,SAAS,cAAc,EAClC,KAAK;IACL,IAAI,EAAE,MAAM,CAAC;IACb,SAAS,EAAE,WAAW,CAAC;CACxB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAGC,CAAC"}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { makeCreateTagContract } from "./index.js";
|
|
2
|
+
import { makeListTagsContract } from "./list.js";
|
|
3
|
+
export const makeTagContracts = (ids) => ({
|
|
4
|
+
create: makeCreateTagContract(ids),
|
|
5
|
+
list: makeListTagsContract(ids),
|
|
6
|
+
});
|
|
7
|
+
//# sourceMappingURL=contracts.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"contracts.js","sourceRoot":"","sources":["../../../src/v1/tag/contracts.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,qBAAqB,EAAE,MAAM,YAAY,CAAC;AACnD,OAAO,EAAE,oBAAoB,EAAE,MAAM,WAAW,CAAC;AAEjD,MAAM,CAAC,MAAM,gBAAgB,GAAG,CAG9B,GAGD,EAAE,EAAE,CAAC,CAAC;IACL,MAAM,EAAE,qBAAqB,CAAC,GAAG,CAAC;IAClC,IAAI,EAAE,oBAAoB,CAAC,GAAG,CAAC;CAChC,CAAC,CAAC"}
|
|
@@ -0,0 +1,79 @@
|
|
|
1
|
+
import { z } from "zod";
|
|
2
|
+
import type { PublicIdSchema } from "../ids.js";
|
|
3
|
+
export declare const maxUsageBreakdownDays = 366;
|
|
4
|
+
export declare const makeUsageBreakdownContract: <WorkspaceId extends PublicIdSchema>(ids: {
|
|
5
|
+
workspace: WorkspaceId;
|
|
6
|
+
}) => {
|
|
7
|
+
readonly annotationJustifications: {
|
|
8
|
+
readonly destructiveHint: "Only reads usage.";
|
|
9
|
+
readonly openWorldHint: "Reads QA Wolf usage records only.";
|
|
10
|
+
readonly readOnlyHint: "Adds up recorded usage without changing anything.";
|
|
11
|
+
};
|
|
12
|
+
readonly annotations: {
|
|
13
|
+
readonly destructiveHint: false;
|
|
14
|
+
readonly openWorldHint: false;
|
|
15
|
+
readonly readOnlyHint: true;
|
|
16
|
+
};
|
|
17
|
+
readonly description: "Show where credits went over a range of UTC days, grouped by time, workspace, environment, platform, source, trigger or user. Use it to find what uses the most credits, or to build a usage dashboard. Credits only, no dollar amounts.";
|
|
18
|
+
readonly input: z.ZodObject<{
|
|
19
|
+
from: z.ZodString;
|
|
20
|
+
groupBy: z.ZodDefault<z.ZodArray<z.ZodEnum<{
|
|
21
|
+
user: "user";
|
|
22
|
+
environment: "environment";
|
|
23
|
+
trigger: "trigger";
|
|
24
|
+
workspace: "workspace";
|
|
25
|
+
platform: "platform";
|
|
26
|
+
source: "source";
|
|
27
|
+
day: "day";
|
|
28
|
+
week: "week";
|
|
29
|
+
month: "month";
|
|
30
|
+
}>>>;
|
|
31
|
+
limit: z.ZodDefault<z.ZodNumber>;
|
|
32
|
+
scope: z.ZodDefault<z.ZodEnum<{
|
|
33
|
+
organization: "organization";
|
|
34
|
+
workspace: "workspace";
|
|
35
|
+
}>>;
|
|
36
|
+
to: z.ZodString;
|
|
37
|
+
workspaceId: z.ZodOptional<WorkspaceId>;
|
|
38
|
+
}, z.core.$strip>;
|
|
39
|
+
readonly kind: "read";
|
|
40
|
+
readonly name: "usage.breakdown";
|
|
41
|
+
readonly output: z.ZodObject<{
|
|
42
|
+
labels: z.ZodObject<{
|
|
43
|
+
environments: z.ZodRecord<z.ZodString, z.ZodString>;
|
|
44
|
+
triggers: z.ZodRecord<z.ZodString, z.ZodString>;
|
|
45
|
+
users: z.ZodRecord<z.ZodString, z.ZodString>;
|
|
46
|
+
workspaces: z.ZodRecord<z.ZodString, z.ZodString>;
|
|
47
|
+
}, z.core.$strip>;
|
|
48
|
+
others: z.ZodOptional<z.ZodObject<{
|
|
49
|
+
flowRuns: z.ZodNumber;
|
|
50
|
+
runCredits: z.ZodNumber;
|
|
51
|
+
sessionCredits: z.ZodNumber;
|
|
52
|
+
sessionSeconds: z.ZodNumber;
|
|
53
|
+
}, z.core.$strip>>;
|
|
54
|
+
rows: z.ZodArray<z.ZodObject<{
|
|
55
|
+
flowRuns: z.ZodNumber;
|
|
56
|
+
runCredits: z.ZodNumber;
|
|
57
|
+
sessionCredits: z.ZodNumber;
|
|
58
|
+
sessionSeconds: z.ZodNumber;
|
|
59
|
+
group: z.ZodObject<{
|
|
60
|
+
day: z.ZodOptional<z.ZodString>;
|
|
61
|
+
environment: z.ZodOptional<z.ZodString>;
|
|
62
|
+
month: z.ZodOptional<z.ZodString>;
|
|
63
|
+
platform: z.ZodOptional<z.ZodString>;
|
|
64
|
+
source: z.ZodOptional<z.ZodString>;
|
|
65
|
+
trigger: z.ZodOptional<z.ZodString>;
|
|
66
|
+
user: z.ZodOptional<z.ZodString>;
|
|
67
|
+
week: z.ZodOptional<z.ZodString>;
|
|
68
|
+
workspace: z.ZodOptional<z.ZodString>;
|
|
69
|
+
}, z.core.$strip>;
|
|
70
|
+
}, z.core.$strip>>;
|
|
71
|
+
totals: z.ZodObject<{
|
|
72
|
+
flowRuns: z.ZodNumber;
|
|
73
|
+
runCredits: z.ZodNumber;
|
|
74
|
+
sessionCredits: z.ZodNumber;
|
|
75
|
+
sessionSeconds: z.ZodNumber;
|
|
76
|
+
}, z.core.$strip>;
|
|
77
|
+
}, z.core.$strip>;
|
|
78
|
+
};
|
|
79
|
+
//# sourceMappingURL=breakdown.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"breakdown.d.ts","sourceRoot":"","sources":["../../../src/v1/usage/breakdown.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAGxB,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,WAAW,CAAC;AAEhD,eAAO,MAAM,qBAAqB,MAAM,CAAC;AAwDzC,eAAO,MAAM,0BAA0B,GACrC,WAAW,SAAS,cAAc,EAClC,KAAK;IACL,SAAS,EAAE,WAAW,CAAC;CACxB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA2EA,CAAC"}
|
|
@@ -0,0 +1,99 @@
|
|
|
1
|
+
import { z } from "zod";
|
|
2
|
+
export const maxUsageBreakdownDays = 366;
|
|
3
|
+
const usageGroupings = [
|
|
4
|
+
"day",
|
|
5
|
+
"week",
|
|
6
|
+
"month",
|
|
7
|
+
"workspace",
|
|
8
|
+
"environment",
|
|
9
|
+
"platform",
|
|
10
|
+
"source",
|
|
11
|
+
"trigger",
|
|
12
|
+
"user",
|
|
13
|
+
];
|
|
14
|
+
const usageDay = z
|
|
15
|
+
.string()
|
|
16
|
+
.regex(/^\d{4}-\d{2}-\d{2}$/)
|
|
17
|
+
.describe("A UTC day as YYYY-MM-DD.");
|
|
18
|
+
const totals = z.object({
|
|
19
|
+
flowRuns: z
|
|
20
|
+
.number()
|
|
21
|
+
.describe("Flow runs that used credits. A flow run counts once for each source that used its credits (its trigger, and each person who reran it), on the day of that source's first charge."),
|
|
22
|
+
runCredits: z.number().describe("Credits that flow runs used."),
|
|
23
|
+
sessionCredits: z
|
|
24
|
+
.number()
|
|
25
|
+
.describe("Credits of runners open outside a run. In a row, the exact share of the session time, so it can be a fraction."),
|
|
26
|
+
sessionSeconds: z.number().describe("Seconds of runners open outside a run."),
|
|
27
|
+
});
|
|
28
|
+
const group = z
|
|
29
|
+
.object({
|
|
30
|
+
day: z.string().optional(),
|
|
31
|
+
environment: z.string().optional(),
|
|
32
|
+
month: z.string().optional(),
|
|
33
|
+
platform: z.string().optional(),
|
|
34
|
+
source: z.string().optional(),
|
|
35
|
+
trigger: z.string().optional(),
|
|
36
|
+
user: z.string().optional(),
|
|
37
|
+
week: z.string().optional(),
|
|
38
|
+
workspace: z.string().optional(),
|
|
39
|
+
})
|
|
40
|
+
.describe("The value of each groupBy grouping for this row. day and week are YYYY-MM-DD (a week starts on Monday), month is YYYY-MM, platform is web, ios, android, windows or mac, and source is person, trigger, api, unknown or session-time. workspace, environment, trigger and user hold ids, named in labels. A grouping is absent when the usage has no value for it, for example the environment of a runner opened through the API, or the trigger of session time.");
|
|
41
|
+
const labels = z
|
|
42
|
+
.record(z.string(), z.string())
|
|
43
|
+
.describe("Names by id. An id with no name was deleted, or belongs to a workspace you cannot see.");
|
|
44
|
+
export const makeUsageBreakdownContract = (ids) => {
|
|
45
|
+
const input = z.object({
|
|
46
|
+
from: usageDay.describe("The first UTC day of the range, YYYY-MM-DD."),
|
|
47
|
+
groupBy: z
|
|
48
|
+
.array(z.enum(usageGroupings))
|
|
49
|
+
.max(2)
|
|
50
|
+
.default([])
|
|
51
|
+
.describe("Up to two groupings, for example [day, environment]. Empty gives one row with all usage."),
|
|
52
|
+
limit: z
|
|
53
|
+
.number()
|
|
54
|
+
.int()
|
|
55
|
+
.min(1)
|
|
56
|
+
.max(1000)
|
|
57
|
+
.default(100)
|
|
58
|
+
.describe("The most rows to return, most credits first. The rest are added up in others."),
|
|
59
|
+
scope: z
|
|
60
|
+
.enum(["workspace", "organization"])
|
|
61
|
+
.default("workspace")
|
|
62
|
+
.describe("workspace reads one workspace. organization reads every workspace of its organization whose usage you can see. It needs an organization API key or a billing manager; with a user credential, send workspaceId to name the organization. An organization API key is not a billing manager: it sees only the workspaces whose Usage page is open to customers."),
|
|
63
|
+
to: usageDay.describe(`The last UTC day of the range, YYYY-MM-DD. The range holds at most ${maxUsageBreakdownDays} days, including both ends.`),
|
|
64
|
+
workspaceId: ids.workspace
|
|
65
|
+
.optional()
|
|
66
|
+
.describe("The workspace to read, or whose organization to read. Required with a user API key, and with an organization API key for the workspace scope."),
|
|
67
|
+
});
|
|
68
|
+
const output = z.object({
|
|
69
|
+
labels: z.object({
|
|
70
|
+
environments: labels,
|
|
71
|
+
triggers: labels,
|
|
72
|
+
users: labels,
|
|
73
|
+
workspaces: labels,
|
|
74
|
+
}),
|
|
75
|
+
others: totals
|
|
76
|
+
.optional()
|
|
77
|
+
.describe("The rows after limit, added up. Absent when none was left out."),
|
|
78
|
+
rows: z.array(totals.extend({ group })).describe("Most credits first."),
|
|
79
|
+
totals: totals.describe("All usage of the range. sessionCredits here are whole credits, counted for each UTC month and platform, so the rows can add up to a little less."),
|
|
80
|
+
});
|
|
81
|
+
return {
|
|
82
|
+
annotationJustifications: {
|
|
83
|
+
destructiveHint: "Only reads usage.",
|
|
84
|
+
openWorldHint: "Reads QA Wolf usage records only.",
|
|
85
|
+
readOnlyHint: "Adds up recorded usage without changing anything.",
|
|
86
|
+
},
|
|
87
|
+
annotations: {
|
|
88
|
+
destructiveHint: false,
|
|
89
|
+
openWorldHint: false,
|
|
90
|
+
readOnlyHint: true,
|
|
91
|
+
},
|
|
92
|
+
description: "Show where credits went over a range of UTC days, grouped by time, workspace, environment, platform, source, trigger or user. Use it to find what uses the most credits, or to build a usage dashboard. Credits only, no dollar amounts.",
|
|
93
|
+
input,
|
|
94
|
+
kind: "read",
|
|
95
|
+
name: "usage.breakdown",
|
|
96
|
+
output,
|
|
97
|
+
};
|
|
98
|
+
};
|
|
99
|
+
//# sourceMappingURL=breakdown.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"breakdown.js","sourceRoot":"","sources":["../../../src/v1/usage/breakdown.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAKxB,MAAM,CAAC,MAAM,qBAAqB,GAAG,GAAG,CAAC;AAEzC,MAAM,cAAc,GAAG;IACrB,KAAK;IACL,MAAM;IACN,OAAO;IACP,WAAW;IACX,aAAa;IACb,UAAU;IACV,QAAQ;IACR,SAAS;IACT,MAAM;CACE,CAAC;AAEX,MAAM,QAAQ,GAAG,CAAC;KACf,MAAM,EAAE;KACR,KAAK,CAAC,qBAAqB,CAAC;KAC5B,QAAQ,CAAC,0BAA0B,CAAC,CAAC;AAExC,MAAM,MAAM,GAAG,CAAC,CAAC,MAAM,CAAC;IACtB,QAAQ,EAAE,CAAC;SACR,MAAM,EAAE;SACR,QAAQ,CACP,kLAAkL,CACnL;IACH,UAAU,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,8BAA8B,CAAC;IAC/D,cAAc,EAAE,CAAC;SACd,MAAM,EAAE;SACR,QAAQ,CACP,gHAAgH,CACjH;IACH,cAAc,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,wCAAwC,CAAC;CAC9E,CAAC,CAAC;AAEH,M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0 +1,79 @@
|
|
|
1
|
+
import type { PublicIdSchema } from "../ids.js";
|
|
2
|
+
export declare const makeUsageContracts: <WorkspaceId extends PublicIdSchema>(ids: {
|
|
3
|
+
workspace: WorkspaceId;
|
|
4
|
+
}) => {
|
|
5
|
+
breakdown: {
|
|
6
|
+
readonly annotationJustifications: {
|
|
7
|
+
readonly destructiveHint: "Only reads usage.";
|
|
8
|
+
readonly openWorldHint: "Reads QA Wolf usage records only.";
|
|
9
|
+
readonly readOnlyHint: "Adds up recorded usage without changing anything.";
|
|
10
|
+
};
|
|
11
|
+
readonly annotations: {
|
|
12
|
+
readonly destructiveHint: false;
|
|
13
|
+
readonly openWorldHint: false;
|
|
14
|
+
readonly readOnlyHint: true;
|
|
15
|
+
};
|
|
16
|
+
readonly description: "Show where credits went over a range of UTC days, grouped by time, workspace, environment, platform, source, trigger or user. Use it to find what uses the most credits, or to build a usage dashboard. Credits only, no dollar amounts.";
|
|
17
|
+
readonly input: import("zod").ZodObject<{
|
|
18
|
+
from: import("zod").ZodString;
|
|
19
|
+
groupBy: import("zod").ZodDefault<import("zod").ZodArray<import("zod").ZodEnum<{
|
|
20
|
+
user: "user";
|
|
21
|
+
environment: "environment";
|
|
22
|
+
trigger: "trigger";
|
|
23
|
+
workspace: "workspace";
|
|
24
|
+
platform: "platform";
|
|
25
|
+
source: "source";
|
|
26
|
+
day: "day";
|
|
27
|
+
week: "week";
|
|
28
|
+
month: "month";
|
|
29
|
+
}>>>;
|
|
30
|
+
limit: import("zod").ZodDefault<import("zod").ZodNumber>;
|
|
31
|
+
scope: import("zod").ZodDefault<import("zod").ZodEnum<{
|
|
32
|
+
organization: "organization";
|
|
33
|
+
workspace: "workspace";
|
|
34
|
+
}>>;
|
|
35
|
+
to: import("zod").ZodString;
|
|
36
|
+
workspaceId: import("zod").ZodOptional<WorkspaceId>;
|
|
37
|
+
}, import("zod/v4/core").$strip>;
|
|
38
|
+
readonly kind: "read";
|
|
39
|
+
readonly name: "usage.breakdown";
|
|
40
|
+
readonly output: import("zod").ZodObject<{
|
|
41
|
+
labels: import("zod").ZodObject<{
|
|
42
|
+
environments: import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodString>;
|
|
43
|
+
triggers: import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodString>;
|
|
44
|
+
users: import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodString>;
|
|
45
|
+
workspaces: import("zod").ZodRecord<import("zod").ZodString, import("zod").ZodString>;
|
|
46
|
+
}, import("zod/v4/core").$strip>;
|
|
47
|
+
others: import("zod").ZodOptional<import("zod").ZodObject<{
|
|
48
|
+
flowRuns: import("zod").ZodNumber;
|
|
49
|
+
runCredits: import("zod").ZodNumber;
|
|
50
|
+
sessionCredits: import("zod").ZodNumber;
|
|
51
|
+
sessionSeconds: import("zod").ZodNumber;
|
|
52
|
+
}, import("zod/v4/core").$strip>>;
|
|
53
|
+
rows: import("zod").ZodArray<import("zod").ZodObject<{
|
|
54
|
+
flowRuns: import("zod").ZodNumber;
|
|
55
|
+
runCredits: import("zod").ZodNumber;
|
|
56
|
+
sessionCredits: import("zod").ZodNumber;
|
|
57
|
+
sessionSeconds: import("zod").ZodNumber;
|
|
58
|
+
group: import("zod").ZodObject<{
|
|
59
|
+
day: import("zod").ZodOptional<import("zod").ZodString>;
|
|
60
|
+
environment: import("zod").ZodOptional<import("zod").ZodString>;
|
|
61
|
+
month: import("zod").ZodOptional<import("zod").ZodString>;
|
|
62
|
+
platform: import("zod").ZodOptional<import("zod").ZodString>;
|
|
63
|
+
source: import("zod").ZodOptional<import("zod").ZodString>;
|
|
64
|
+
trigger: import("zod").ZodOptional<import("zod").ZodString>;
|
|
65
|
+
user: import("zod").ZodOptional<import("zod").ZodString>;
|
|
66
|
+
week: import("zod").ZodOptional<import("zod").ZodString>;
|
|
67
|
+
workspace: import("zod").ZodOptional<import("zod").ZodString>;
|
|
68
|
+
}, import("zod/v4/core").$strip>;
|
|
69
|
+
}, import("zod/v4/core").$strip>>;
|
|
70
|
+
totals: import("zod").ZodObject<{
|
|
71
|
+
flowRuns: import("zod").ZodNumber;
|
|
72
|
+
runCredits: import("zod").ZodNumber;
|
|
73
|
+
sessionCredits: import("zod").ZodNumber;
|
|
74
|
+
sessionSeconds: import("zod").ZodNumber;
|
|
75
|
+
}, import("zod/v4/core").$strip>;
|
|
76
|
+
}, import("zod/v4/core").$strip>;
|
|
77
|
+
};
|
|
78
|
+
};
|
|
79
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/v1/usage/index.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,WAAW,CAAC;AAIhD,eAAO,MAAM,kBAAkB,GAAI,WAAW,SAAS,cAAc,EAAE,KAAK;IAC1E,SAAS,EAAE,WAAW,CAAC;CACxB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAEC,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/v1/usage/index.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,0BAA0B,EAAE,MAAM,gBAAgB,CAAC;AAE5D,MAAM,CAAC,MAAM,kBAAkB,GAAG,CAAqC,GAEtE,EAAE,EAAE,CAAC,CAAC;IACL,SAAS,EAAE,0BAA0B,CAAC,GAAG,CAAC;CAC3C,CAAC,CAAC"}
|