@thirdweb-dev/service-utils 0.4.20 → 0.4.21
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/cf-worker/dist/thirdweb-dev-service-utils-cf-worker.cjs.dev.js +6 -2
- package/cf-worker/dist/thirdweb-dev-service-utils-cf-worker.cjs.prod.js +6 -2
- package/cf-worker/dist/thirdweb-dev-service-utils-cf-worker.esm.js +6 -2
- package/dist/declarations/src/cf-worker/usage.d.ts +15 -3
- package/dist/declarations/src/cf-worker/usage.d.ts.map +1 -1
- package/package.json +1 -1
@@ -20,7 +20,7 @@ function getAws(options) {
|
|
20
20
|
* Types
|
21
21
|
*/
|
22
22
|
const usageEventSchema = zod.z.object({
|
23
|
-
source: zod.z.enum(["embeddedWallets", "rpc", "storage", "bundler", "paymaster", "relayer", "connectWallet", "checkout", "engine"]),
|
23
|
+
source: zod.z.enum(["embeddedWallets", "rpc", "storage", "bundler", "paymaster", "relayer", "connectWallet", "checkout", "engine", "pay"]),
|
24
24
|
action: zod.z.string(),
|
25
25
|
/**
|
26
26
|
* The following fields are optional.
|
@@ -59,7 +59,11 @@ const usageEventSchema = zod.z.object({
|
|
59
59
|
policyId: zod.z.string().optional(),
|
60
60
|
msSinceQueue: zod.z.number().nonnegative().optional(),
|
61
61
|
msSinceSend: zod.z.number().nonnegative().optional(),
|
62
|
-
msTotalDuration: zod.z.number().nonnegative().optional()
|
62
|
+
msTotalDuration: zod.z.number().nonnegative().optional(),
|
63
|
+
swapId: zod.z.string().optional(),
|
64
|
+
tokenAddress: zod.z.string().optional(),
|
65
|
+
amountWei: zod.z.string().optional(),
|
66
|
+
amountUSDCents: zod.z.number().nonnegative().optional()
|
63
67
|
});
|
64
68
|
/**
|
65
69
|
* Publish usage events. Provide the relevant fields for your application.
|
@@ -20,7 +20,7 @@ function getAws(options) {
|
|
20
20
|
* Types
|
21
21
|
*/
|
22
22
|
const usageEventSchema = zod.z.object({
|
23
|
-
source: zod.z.enum(["embeddedWallets", "rpc", "storage", "bundler", "paymaster", "relayer", "connectWallet", "checkout", "engine"]),
|
23
|
+
source: zod.z.enum(["embeddedWallets", "rpc", "storage", "bundler", "paymaster", "relayer", "connectWallet", "checkout", "engine", "pay"]),
|
24
24
|
action: zod.z.string(),
|
25
25
|
/**
|
26
26
|
* The following fields are optional.
|
@@ -59,7 +59,11 @@ const usageEventSchema = zod.z.object({
|
|
59
59
|
policyId: zod.z.string().optional(),
|
60
60
|
msSinceQueue: zod.z.number().nonnegative().optional(),
|
61
61
|
msSinceSend: zod.z.number().nonnegative().optional(),
|
62
|
-
msTotalDuration: zod.z.number().nonnegative().optional()
|
62
|
+
msTotalDuration: zod.z.number().nonnegative().optional(),
|
63
|
+
swapId: zod.z.string().optional(),
|
64
|
+
tokenAddress: zod.z.string().optional(),
|
65
|
+
amountWei: zod.z.string().optional(),
|
66
|
+
amountUSDCents: zod.z.number().nonnegative().optional()
|
63
67
|
});
|
64
68
|
/**
|
65
69
|
* Publish usage events. Provide the relevant fields for your application.
|
@@ -17,7 +17,7 @@ function getAws(options) {
|
|
17
17
|
* Types
|
18
18
|
*/
|
19
19
|
const usageEventSchema = z.object({
|
20
|
-
source: z.enum(["embeddedWallets", "rpc", "storage", "bundler", "paymaster", "relayer", "connectWallet", "checkout", "engine"]),
|
20
|
+
source: z.enum(["embeddedWallets", "rpc", "storage", "bundler", "paymaster", "relayer", "connectWallet", "checkout", "engine", "pay"]),
|
21
21
|
action: z.string(),
|
22
22
|
/**
|
23
23
|
* The following fields are optional.
|
@@ -56,7 +56,11 @@ const usageEventSchema = z.object({
|
|
56
56
|
policyId: z.string().optional(),
|
57
57
|
msSinceQueue: z.number().nonnegative().optional(),
|
58
58
|
msSinceSend: z.number().nonnegative().optional(),
|
59
|
-
msTotalDuration: z.number().nonnegative().optional()
|
59
|
+
msTotalDuration: z.number().nonnegative().optional(),
|
60
|
+
swapId: z.string().optional(),
|
61
|
+
tokenAddress: z.string().optional(),
|
62
|
+
amountWei: z.string().optional(),
|
63
|
+
amountUSDCents: z.number().nonnegative().optional()
|
60
64
|
});
|
61
65
|
/**
|
62
66
|
* Publish usage events. Provide the relevant fields for your application.
|
@@ -3,7 +3,7 @@ import { z } from "zod";
|
|
3
3
|
* Types
|
4
4
|
*/
|
5
5
|
declare const usageEventSchema: z.ZodObject<{
|
6
|
-
source: z.ZodEnum<["embeddedWallets", "rpc", "storage", "bundler", "paymaster", "relayer", "connectWallet", "checkout", "engine"]>;
|
6
|
+
source: z.ZodEnum<["embeddedWallets", "rpc", "storage", "bundler", "paymaster", "relayer", "connectWallet", "checkout", "engine", "pay"]>;
|
7
7
|
action: z.ZodString;
|
8
8
|
/**
|
9
9
|
* The following fields are optional.
|
@@ -42,8 +42,12 @@ declare const usageEventSchema: z.ZodObject<{
|
|
42
42
|
msSinceQueue: z.ZodOptional<z.ZodNumber>;
|
43
43
|
msSinceSend: z.ZodOptional<z.ZodNumber>;
|
44
44
|
msTotalDuration: z.ZodOptional<z.ZodNumber>;
|
45
|
+
swapId: z.ZodOptional<z.ZodString>;
|
46
|
+
tokenAddress: z.ZodOptional<z.ZodString>;
|
47
|
+
amountWei: z.ZodOptional<z.ZodString>;
|
48
|
+
amountUSDCents: z.ZodOptional<z.ZodNumber>;
|
45
49
|
}, "strip", z.ZodTypeAny, {
|
46
|
-
source: "storage" | "rpc" | "bundler" | "relayer" | "embeddedWallets" | "checkout" | "paymaster" | "connectWallet" | "engine";
|
50
|
+
source: "storage" | "rpc" | "bundler" | "relayer" | "embeddedWallets" | "checkout" | "pay" | "paymaster" | "connectWallet" | "engine";
|
47
51
|
action: string;
|
48
52
|
accountId?: string | undefined;
|
49
53
|
isClientEvent?: boolean | undefined;
|
@@ -79,8 +83,12 @@ declare const usageEventSchema: z.ZodObject<{
|
|
79
83
|
msSinceQueue?: number | undefined;
|
80
84
|
msSinceSend?: number | undefined;
|
81
85
|
msTotalDuration?: number | undefined;
|
86
|
+
swapId?: string | undefined;
|
87
|
+
tokenAddress?: string | undefined;
|
88
|
+
amountWei?: string | undefined;
|
89
|
+
amountUSDCents?: number | undefined;
|
82
90
|
}, {
|
83
|
-
source: "storage" | "rpc" | "bundler" | "relayer" | "embeddedWallets" | "checkout" | "paymaster" | "connectWallet" | "engine";
|
91
|
+
source: "storage" | "rpc" | "bundler" | "relayer" | "embeddedWallets" | "checkout" | "pay" | "paymaster" | "connectWallet" | "engine";
|
84
92
|
action: string;
|
85
93
|
accountId?: string | undefined;
|
86
94
|
isClientEvent?: boolean | undefined;
|
@@ -116,6 +124,10 @@ declare const usageEventSchema: z.ZodObject<{
|
|
116
124
|
msSinceQueue?: number | undefined;
|
117
125
|
msSinceSend?: number | undefined;
|
118
126
|
msTotalDuration?: number | undefined;
|
127
|
+
swapId?: string | undefined;
|
128
|
+
tokenAddress?: string | undefined;
|
129
|
+
amountWei?: string | undefined;
|
130
|
+
amountUSDCents?: number | undefined;
|
119
131
|
}>;
|
120
132
|
export type UsageEvent = z.infer<typeof usageEventSchema>;
|
121
133
|
/**
|
@@ -1 +1 @@
|
|
1
|
-
{"version":3,"file":"usage.d.ts","sourceRoot":"../../../../src/cf-worker","sources":["usage.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAWxB;;GAEG;AACH,QAAA,MAAM,gBAAgB;;;
|
1
|
+
{"version":3,"file":"usage.d.ts","sourceRoot":"../../../../src/cf-worker","sources":["usage.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAWxB;;GAEG;AACH,QAAA,MAAM,gBAAgB;;;IAepB;;OAEG;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAwCH,CAAC;AACH,MAAM,MAAM,UAAU,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,gBAAgB,CAAC,CAAC;AAE1D;;;;;;;;;;;;;GAaG;AACH,wBAAsB,kBAAkB,CACtC,WAAW,EAAE,UAAU,EAAE,EACzB,MAAM,EAAE;IACN,QAAQ,EAAE,MAAM,CAAC;IACjB,WAAW,EAAE,MAAM,CAAC;IACpB,eAAe,EAAE,MAAM,CAAC;IACxB,MAAM,CAAC,EAAE,MAAM,CAAC;CACjB,GACA,OAAO,CAAC,IAAI,CAAC,CAiCf"}
|