@coinbase/cdp-sdk 1.21.0 → 1.23.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.
Files changed (99) hide show
  1. package/CHANGELOG.md +22 -0
  2. package/_cjs/auth/utils/hash.js +17 -0
  3. package/_cjs/auth/utils/hash.js.map +1 -0
  4. package/_cjs/auth/utils/jwt.js +20 -55
  5. package/_cjs/auth/utils/jwt.js.map +1 -1
  6. package/_cjs/client/cdp.js +6 -0
  7. package/_cjs/client/cdp.js.map +1 -1
  8. package/_cjs/client/evm/evm.js +1 -1
  9. package/_cjs/openapi-client/generated/coinbaseDeveloperPlatformAPIs.schemas.js +37 -1
  10. package/_cjs/openapi-client/generated/coinbaseDeveloperPlatformAPIs.schemas.js.map +1 -1
  11. package/_cjs/openapi-client/generated/evm-smart-accounts/evm-smart-accounts.js +14 -1
  12. package/_cjs/openapi-client/generated/evm-smart-accounts/evm-smart-accounts.js.map +1 -1
  13. package/_cjs/openapi-client/generated/evm-smart-accounts/evm-smart-accounts.msw.js +31 -1
  14. package/_cjs/openapi-client/generated/evm-smart-accounts/evm-smart-accounts.msw.js.map +1 -1
  15. package/_cjs/openapi-client/generated/index.msw.js +4 -4
  16. package/_cjs/openapi-client/generated/index.msw.js.map +1 -1
  17. package/_cjs/openapi-client/generated/policy-engine/policy-engine.msw.js +246 -1
  18. package/_cjs/openapi-client/generated/policy-engine/policy-engine.msw.js.map +1 -1
  19. package/_cjs/openapi-client/generated/solana-accounts/solana-accounts.js +14 -10
  20. package/_cjs/openapi-client/generated/solana-accounts/solana-accounts.js.map +1 -1
  21. package/_cjs/openapi-client/generated/solana-accounts/solana-accounts.msw.js +34 -1
  22. package/_cjs/openapi-client/generated/solana-accounts/solana-accounts.msw.js.map +1 -1
  23. package/_cjs/policies/schema.js +143 -1
  24. package/_cjs/policies/schema.js.map +1 -1
  25. package/_cjs/version.js +1 -1
  26. package/_esm/auth/utils/hash.js +13 -0
  27. package/_esm/auth/utils/hash.js.map +1 -0
  28. package/_esm/auth/utils/jwt.js +20 -22
  29. package/_esm/auth/utils/jwt.js.map +1 -1
  30. package/_esm/client/cdp.js +6 -0
  31. package/_esm/client/cdp.js.map +1 -1
  32. package/_esm/client/evm/evm.js +1 -1
  33. package/_esm/openapi-client/generated/coinbaseDeveloperPlatformAPIs.schemas.js +35 -0
  34. package/_esm/openapi-client/generated/coinbaseDeveloperPlatformAPIs.schemas.js.map +1 -1
  35. package/_esm/openapi-client/generated/evm-smart-accounts/evm-smart-accounts.js +12 -0
  36. package/_esm/openapi-client/generated/evm-smart-accounts/evm-smart-accounts.js.map +1 -1
  37. package/_esm/openapi-client/generated/evm-smart-accounts/evm-smart-accounts.msw.js +28 -0
  38. package/_esm/openapi-client/generated/evm-smart-accounts/evm-smart-accounts.msw.js.map +1 -1
  39. package/_esm/openapi-client/generated/index.msw.js +4 -4
  40. package/_esm/openapi-client/generated/index.msw.js.map +1 -1
  41. package/_esm/openapi-client/generated/policy-engine/policy-engine.msw.js +224 -0
  42. package/_esm/openapi-client/generated/policy-engine/policy-engine.msw.js.map +1 -1
  43. package/_esm/openapi-client/generated/solana-accounts/solana-accounts.js +12 -8
  44. package/_esm/openapi-client/generated/solana-accounts/solana-accounts.js.map +1 -1
  45. package/_esm/openapi-client/generated/solana-accounts/solana-accounts.msw.js +31 -0
  46. package/_esm/openapi-client/generated/solana-accounts/solana-accounts.msw.js.map +1 -1
  47. package/_esm/policies/schema.js +142 -0
  48. package/_esm/policies/schema.js.map +1 -1
  49. package/_esm/version.js +1 -1
  50. package/_types/actions/evm/fund/fund.d.ts +1 -1
  51. package/_types/actions/evm/fund/fund.d.ts.map +1 -1
  52. package/_types/actions/evm/fund/quoteFund.d.ts +1 -1
  53. package/_types/actions/evm/fund/quoteFund.d.ts.map +1 -1
  54. package/_types/actions/evm/types.d.ts +2 -2
  55. package/_types/actions/evm/types.d.ts.map +1 -1
  56. package/_types/auth/utils/hash.d.ts +9 -0
  57. package/_types/auth/utils/hash.d.ts.map +1 -0
  58. package/_types/auth/utils/jwt.d.ts.map +1 -1
  59. package/_types/client/cdp.d.ts.map +1 -1
  60. package/_types/client/evm/evm.d.ts +1 -1
  61. package/_types/client/evm/evm.types.d.ts +1 -1
  62. package/_types/client/evm/evm.types.d.ts.map +1 -1
  63. package/_types/openapi-client/generated/coinbaseDeveloperPlatformAPIs.schemas.d.ts +166 -3
  64. package/_types/openapi-client/generated/coinbaseDeveloperPlatformAPIs.schemas.d.ts.map +1 -1
  65. package/_types/openapi-client/generated/evm-smart-accounts/evm-smart-accounts.d.ts +7 -1
  66. package/_types/openapi-client/generated/evm-smart-accounts/evm-smart-accounts.d.ts.map +1 -1
  67. package/_types/openapi-client/generated/evm-smart-accounts/evm-smart-accounts.msw.d.ts +2 -0
  68. package/_types/openapi-client/generated/evm-smart-accounts/evm-smart-accounts.msw.d.ts.map +1 -1
  69. package/_types/openapi-client/generated/index.msw.d.ts +4 -4
  70. package/_types/openapi-client/generated/index.msw.d.ts.map +1 -1
  71. package/_types/openapi-client/generated/policy-engine/policy-engine.msw.d.ts +21 -1
  72. package/_types/openapi-client/generated/policy-engine/policy-engine.msw.d.ts.map +1 -1
  73. package/_types/openapi-client/generated/solana-accounts/solana-accounts.d.ts +7 -6
  74. package/_types/openapi-client/generated/solana-accounts/solana-accounts.d.ts.map +1 -1
  75. package/_types/openapi-client/generated/solana-accounts/solana-accounts.msw.d.ts +2 -0
  76. package/_types/openapi-client/generated/solana-accounts/solana-accounts.msw.d.ts.map +1 -1
  77. package/_types/openapi-client/index.d.ts +4 -10
  78. package/_types/openapi-client/index.d.ts.map +1 -1
  79. package/_types/policies/schema.d.ts +1614 -52
  80. package/_types/policies/schema.d.ts.map +1 -1
  81. package/_types/version.d.ts +1 -1
  82. package/actions/evm/fund/fund.ts +1 -1
  83. package/actions/evm/fund/quoteFund.ts +1 -1
  84. package/actions/evm/types.ts +2 -2
  85. package/auth/utils/hash.ts +13 -0
  86. package/auth/utils/jwt.ts +21 -24
  87. package/client/cdp.ts +9 -0
  88. package/client/evm/evm.ts +1 -1
  89. package/client/evm/evm.types.ts +1 -0
  90. package/openapi-client/generated/coinbaseDeveloperPlatformAPIs.schemas.ts +213 -2
  91. package/openapi-client/generated/evm-smart-accounts/evm-smart-accounts.msw.ts +46 -0
  92. package/openapi-client/generated/evm-smart-accounts/evm-smart-accounts.ts +23 -0
  93. package/openapi-client/generated/index.msw.ts +4 -4
  94. package/openapi-client/generated/policy-engine/policy-engine.msw.ts +349 -0
  95. package/openapi-client/generated/solana-accounts/solana-accounts.msw.ts +51 -0
  96. package/openapi-client/generated/solana-accounts/solana-accounts.ts +22 -20
  97. package/package.json +2 -1
  98. package/policies/schema.ts +170 -0
  99. package/version.ts +1 -1
@@ -133,13 +133,461 @@ export declare const EvmMessageCriterionSchema: z.ZodObject<{
133
133
  */
134
134
  match: z.ZodString;
135
135
  }, "strip", z.ZodTypeAny, {
136
- type: "evmMessage";
137
136
  match: string;
138
- }, {
139
137
  type: "evmMessage";
138
+ }, {
140
139
  match: string;
140
+ type: "evmMessage";
141
141
  }>;
142
142
  export type EvmMessageCriterion = z.infer<typeof EvmMessageCriterionSchema>;
143
+ /**
144
+ * Schema for EVM typed address conditions
145
+ */
146
+ export declare const EvmTypedAddressConditionSchema: z.ZodObject<{
147
+ /**
148
+ * Array of EVM addresses to compare against.
149
+ * Each address must be a 0x-prefixed 40-character hexadecimal string.
150
+ * Limited to a maximum of 100 addresses per condition.
151
+ */
152
+ addresses: z.ZodArray<z.ZodEffects<z.ZodString, `0x${string}`, string>, "many">;
153
+ /**
154
+ * The operator to use for evaluating addresses.
155
+ * "in" checks if an address is in the provided list.
156
+ * "not in" checks if an address is not in the provided list.
157
+ */
158
+ operator: z.ZodEnum<["in", "not in"]>;
159
+ /**
160
+ * The path to the field to compare against this criterion.
161
+ * To reference deeply nested fields, use dot notation (e.g., "order.buyer").
162
+ */
163
+ path: z.ZodString;
164
+ }, "strip", z.ZodTypeAny, {
165
+ path: string;
166
+ operator: "in" | "not in";
167
+ addresses: `0x${string}`[];
168
+ }, {
169
+ path: string;
170
+ operator: "in" | "not in";
171
+ addresses: string[];
172
+ }>;
173
+ export type EvmTypedAddressCondition = z.infer<typeof EvmTypedAddressConditionSchema>;
174
+ /**
175
+ * Schema for EVM typed numerical conditions
176
+ */
177
+ export declare const EvmTypedNumericalConditionSchema: z.ZodObject<{
178
+ /**
179
+ * The numerical value to compare against, as a string.
180
+ * Must contain only digits.
181
+ */
182
+ value: z.ZodString;
183
+ /**
184
+ * The comparison operator to use.
185
+ */
186
+ operator: z.ZodEnum<[">", ">=", "<", "<=", "=="]>;
187
+ /**
188
+ * The path to the field to compare against this criterion.
189
+ * To reference deeply nested fields, use dot notation (e.g., "order.price").
190
+ */
191
+ path: z.ZodString;
192
+ }, "strip", z.ZodTypeAny, {
193
+ value: string;
194
+ path: string;
195
+ operator: ">" | ">=" | "<" | "<=" | "==";
196
+ }, {
197
+ value: string;
198
+ path: string;
199
+ operator: ">" | ">=" | "<" | "<=" | "==";
200
+ }>;
201
+ export type EvmTypedNumericalCondition = z.infer<typeof EvmTypedNumericalConditionSchema>;
202
+ /**
203
+ * Schema for EVM typed string conditions
204
+ */
205
+ export declare const EvmTypedStringConditionSchema: z.ZodObject<{
206
+ /**
207
+ * A regular expression the string field is matched against.
208
+ * Accepts valid regular expression syntax described by [RE2](https://github.com/google/re2/wiki/Syntax).
209
+ */
210
+ match: z.ZodString;
211
+ /**
212
+ * The path to the field to compare against this criterion.
213
+ * To reference deeply nested fields, use dot notation (e.g., "metadata.description").
214
+ */
215
+ path: z.ZodString;
216
+ }, "strip", z.ZodTypeAny, {
217
+ match: string;
218
+ path: string;
219
+ }, {
220
+ match: string;
221
+ path: string;
222
+ }>;
223
+ export type EvmTypedStringCondition = z.infer<typeof EvmTypedStringConditionSchema>;
224
+ /**
225
+ * Schema for SignEvmTypedData field criterion
226
+ */
227
+ export declare const SignEvmTypedDataFieldCriterionSchema: z.ZodObject<{
228
+ /** The type of criterion, must be "evmTypedDataField" for typed data field-based rules. */
229
+ type: z.ZodLiteral<"evmTypedDataField">;
230
+ /**
231
+ * The EIP-712 type definitions for the typed data.
232
+ * Must include at minimum the primary type being signed.
233
+ */
234
+ types: z.ZodObject<{
235
+ /**
236
+ * EIP-712 compliant map of model names to model definitions.
237
+ */
238
+ types: z.ZodRecord<z.ZodString, z.ZodArray<z.ZodObject<{
239
+ name: z.ZodString;
240
+ type: z.ZodString;
241
+ }, "strip", z.ZodTypeAny, {
242
+ type: string;
243
+ name: string;
244
+ }, {
245
+ type: string;
246
+ name: string;
247
+ }>, "many">>;
248
+ /**
249
+ * The name of the root EIP-712 type. This value must be included in the `types` object.
250
+ */
251
+ primaryType: z.ZodString;
252
+ }, "strip", z.ZodTypeAny, {
253
+ types: Record<string, {
254
+ type: string;
255
+ name: string;
256
+ }[]>;
257
+ primaryType: string;
258
+ }, {
259
+ types: Record<string, {
260
+ type: string;
261
+ name: string;
262
+ }[]>;
263
+ primaryType: string;
264
+ }>;
265
+ /**
266
+ * Array of conditions to apply against typed data fields.
267
+ * Each condition specifies how to validate a specific field within the typed data.
268
+ */
269
+ conditions: z.ZodArray<z.ZodUnion<[z.ZodObject<{
270
+ /**
271
+ * Array of EVM addresses to compare against.
272
+ * Each address must be a 0x-prefixed 40-character hexadecimal string.
273
+ * Limited to a maximum of 100 addresses per condition.
274
+ */
275
+ addresses: z.ZodArray<z.ZodEffects<z.ZodString, `0x${string}`, string>, "many">;
276
+ /**
277
+ * The operator to use for evaluating addresses.
278
+ * "in" checks if an address is in the provided list.
279
+ * "not in" checks if an address is not in the provided list.
280
+ */
281
+ operator: z.ZodEnum<["in", "not in"]>;
282
+ /**
283
+ * The path to the field to compare against this criterion.
284
+ * To reference deeply nested fields, use dot notation (e.g., "order.buyer").
285
+ */
286
+ path: z.ZodString;
287
+ }, "strip", z.ZodTypeAny, {
288
+ path: string;
289
+ operator: "in" | "not in";
290
+ addresses: `0x${string}`[];
291
+ }, {
292
+ path: string;
293
+ operator: "in" | "not in";
294
+ addresses: string[];
295
+ }>, z.ZodObject<{
296
+ /**
297
+ * The numerical value to compare against, as a string.
298
+ * Must contain only digits.
299
+ */
300
+ value: z.ZodString;
301
+ /**
302
+ * The comparison operator to use.
303
+ */
304
+ operator: z.ZodEnum<[">", ">=", "<", "<=", "=="]>;
305
+ /**
306
+ * The path to the field to compare against this criterion.
307
+ * To reference deeply nested fields, use dot notation (e.g., "order.price").
308
+ */
309
+ path: z.ZodString;
310
+ }, "strip", z.ZodTypeAny, {
311
+ value: string;
312
+ path: string;
313
+ operator: ">" | ">=" | "<" | "<=" | "==";
314
+ }, {
315
+ value: string;
316
+ path: string;
317
+ operator: ">" | ">=" | "<" | "<=" | "==";
318
+ }>, z.ZodObject<{
319
+ /**
320
+ * A regular expression the string field is matched against.
321
+ * Accepts valid regular expression syntax described by [RE2](https://github.com/google/re2/wiki/Syntax).
322
+ */
323
+ match: z.ZodString;
324
+ /**
325
+ * The path to the field to compare against this criterion.
326
+ * To reference deeply nested fields, use dot notation (e.g., "metadata.description").
327
+ */
328
+ path: z.ZodString;
329
+ }, "strip", z.ZodTypeAny, {
330
+ match: string;
331
+ path: string;
332
+ }, {
333
+ match: string;
334
+ path: string;
335
+ }>]>, "many">;
336
+ }, "strip", z.ZodTypeAny, {
337
+ type: "evmTypedDataField";
338
+ types: {
339
+ types: Record<string, {
340
+ type: string;
341
+ name: string;
342
+ }[]>;
343
+ primaryType: string;
344
+ };
345
+ conditions: ({
346
+ path: string;
347
+ operator: "in" | "not in";
348
+ addresses: `0x${string}`[];
349
+ } | {
350
+ value: string;
351
+ path: string;
352
+ operator: ">" | ">=" | "<" | "<=" | "==";
353
+ } | {
354
+ match: string;
355
+ path: string;
356
+ })[];
357
+ }, {
358
+ type: "evmTypedDataField";
359
+ types: {
360
+ types: Record<string, {
361
+ type: string;
362
+ name: string;
363
+ }[]>;
364
+ primaryType: string;
365
+ };
366
+ conditions: ({
367
+ path: string;
368
+ operator: "in" | "not in";
369
+ addresses: string[];
370
+ } | {
371
+ value: string;
372
+ path: string;
373
+ operator: ">" | ">=" | "<" | "<=" | "==";
374
+ } | {
375
+ match: string;
376
+ path: string;
377
+ })[];
378
+ }>;
379
+ export type SignEvmTypedDataFieldCriterion = z.infer<typeof SignEvmTypedDataFieldCriterionSchema>;
380
+ /**
381
+ * Schema for SignEvmTypedData verifying contract criterion
382
+ */
383
+ export declare const SignEvmTypedDataVerifyingContractCriterionSchema: z.ZodObject<{
384
+ /** The type of criterion, must be "evmTypedDataVerifyingContract" for verifying contract-based rules. */
385
+ type: z.ZodLiteral<"evmTypedDataVerifyingContract">;
386
+ /**
387
+ * Array of EVM addresses allowed or disallowed as verifying contracts.
388
+ * Each address must be a 0x-prefixed 40-character hexadecimal string.
389
+ * Limited to a maximum of 100 addresses per criterion.
390
+ */
391
+ addresses: z.ZodArray<z.ZodEffects<z.ZodString, `0x${string}`, string>, "many">;
392
+ /**
393
+ * The operator to use for evaluating verifying contract addresses.
394
+ * "in" checks if the verifying contract is in the provided list.
395
+ * "not in" checks if the verifying contract is not in the provided list.
396
+ */
397
+ operator: z.ZodEnum<["in", "not in"]>;
398
+ }, "strip", z.ZodTypeAny, {
399
+ type: "evmTypedDataVerifyingContract";
400
+ operator: "in" | "not in";
401
+ addresses: `0x${string}`[];
402
+ }, {
403
+ type: "evmTypedDataVerifyingContract";
404
+ operator: "in" | "not in";
405
+ addresses: string[];
406
+ }>;
407
+ export type SignEvmTypedDataVerifyingContractCriterion = z.infer<typeof SignEvmTypedDataVerifyingContractCriterionSchema>;
408
+ /**
409
+ * Schema for criteria used in SignEvmTypedData operations
410
+ */
411
+ export declare const SignEvmTypedDataCriteriaSchema: z.ZodArray<z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
412
+ /** The type of criterion, must be "evmTypedDataField" for typed data field-based rules. */
413
+ type: z.ZodLiteral<"evmTypedDataField">;
414
+ /**
415
+ * The EIP-712 type definitions for the typed data.
416
+ * Must include at minimum the primary type being signed.
417
+ */
418
+ types: z.ZodObject<{
419
+ /**
420
+ * EIP-712 compliant map of model names to model definitions.
421
+ */
422
+ types: z.ZodRecord<z.ZodString, z.ZodArray<z.ZodObject<{
423
+ name: z.ZodString;
424
+ type: z.ZodString;
425
+ }, "strip", z.ZodTypeAny, {
426
+ type: string;
427
+ name: string;
428
+ }, {
429
+ type: string;
430
+ name: string;
431
+ }>, "many">>;
432
+ /**
433
+ * The name of the root EIP-712 type. This value must be included in the `types` object.
434
+ */
435
+ primaryType: z.ZodString;
436
+ }, "strip", z.ZodTypeAny, {
437
+ types: Record<string, {
438
+ type: string;
439
+ name: string;
440
+ }[]>;
441
+ primaryType: string;
442
+ }, {
443
+ types: Record<string, {
444
+ type: string;
445
+ name: string;
446
+ }[]>;
447
+ primaryType: string;
448
+ }>;
449
+ /**
450
+ * Array of conditions to apply against typed data fields.
451
+ * Each condition specifies how to validate a specific field within the typed data.
452
+ */
453
+ conditions: z.ZodArray<z.ZodUnion<[z.ZodObject<{
454
+ /**
455
+ * Array of EVM addresses to compare against.
456
+ * Each address must be a 0x-prefixed 40-character hexadecimal string.
457
+ * Limited to a maximum of 100 addresses per condition.
458
+ */
459
+ addresses: z.ZodArray<z.ZodEffects<z.ZodString, `0x${string}`, string>, "many">;
460
+ /**
461
+ * The operator to use for evaluating addresses.
462
+ * "in" checks if an address is in the provided list.
463
+ * "not in" checks if an address is not in the provided list.
464
+ */
465
+ operator: z.ZodEnum<["in", "not in"]>;
466
+ /**
467
+ * The path to the field to compare against this criterion.
468
+ * To reference deeply nested fields, use dot notation (e.g., "order.buyer").
469
+ */
470
+ path: z.ZodString;
471
+ }, "strip", z.ZodTypeAny, {
472
+ path: string;
473
+ operator: "in" | "not in";
474
+ addresses: `0x${string}`[];
475
+ }, {
476
+ path: string;
477
+ operator: "in" | "not in";
478
+ addresses: string[];
479
+ }>, z.ZodObject<{
480
+ /**
481
+ * The numerical value to compare against, as a string.
482
+ * Must contain only digits.
483
+ */
484
+ value: z.ZodString;
485
+ /**
486
+ * The comparison operator to use.
487
+ */
488
+ operator: z.ZodEnum<[">", ">=", "<", "<=", "=="]>;
489
+ /**
490
+ * The path to the field to compare against this criterion.
491
+ * To reference deeply nested fields, use dot notation (e.g., "order.price").
492
+ */
493
+ path: z.ZodString;
494
+ }, "strip", z.ZodTypeAny, {
495
+ value: string;
496
+ path: string;
497
+ operator: ">" | ">=" | "<" | "<=" | "==";
498
+ }, {
499
+ value: string;
500
+ path: string;
501
+ operator: ">" | ">=" | "<" | "<=" | "==";
502
+ }>, z.ZodObject<{
503
+ /**
504
+ * A regular expression the string field is matched against.
505
+ * Accepts valid regular expression syntax described by [RE2](https://github.com/google/re2/wiki/Syntax).
506
+ */
507
+ match: z.ZodString;
508
+ /**
509
+ * The path to the field to compare against this criterion.
510
+ * To reference deeply nested fields, use dot notation (e.g., "metadata.description").
511
+ */
512
+ path: z.ZodString;
513
+ }, "strip", z.ZodTypeAny, {
514
+ match: string;
515
+ path: string;
516
+ }, {
517
+ match: string;
518
+ path: string;
519
+ }>]>, "many">;
520
+ }, "strip", z.ZodTypeAny, {
521
+ type: "evmTypedDataField";
522
+ types: {
523
+ types: Record<string, {
524
+ type: string;
525
+ name: string;
526
+ }[]>;
527
+ primaryType: string;
528
+ };
529
+ conditions: ({
530
+ path: string;
531
+ operator: "in" | "not in";
532
+ addresses: `0x${string}`[];
533
+ } | {
534
+ value: string;
535
+ path: string;
536
+ operator: ">" | ">=" | "<" | "<=" | "==";
537
+ } | {
538
+ match: string;
539
+ path: string;
540
+ })[];
541
+ }, {
542
+ type: "evmTypedDataField";
543
+ types: {
544
+ types: Record<string, {
545
+ type: string;
546
+ name: string;
547
+ }[]>;
548
+ primaryType: string;
549
+ };
550
+ conditions: ({
551
+ path: string;
552
+ operator: "in" | "not in";
553
+ addresses: string[];
554
+ } | {
555
+ value: string;
556
+ path: string;
557
+ operator: ">" | ">=" | "<" | "<=" | "==";
558
+ } | {
559
+ match: string;
560
+ path: string;
561
+ })[];
562
+ }>, z.ZodObject<{
563
+ /** The type of criterion, must be "evmTypedDataVerifyingContract" for verifying contract-based rules. */
564
+ type: z.ZodLiteral<"evmTypedDataVerifyingContract">;
565
+ /**
566
+ * Array of EVM addresses allowed or disallowed as verifying contracts.
567
+ * Each address must be a 0x-prefixed 40-character hexadecimal string.
568
+ * Limited to a maximum of 100 addresses per criterion.
569
+ */
570
+ addresses: z.ZodArray<z.ZodEffects<z.ZodString, `0x${string}`, string>, "many">;
571
+ /**
572
+ * The operator to use for evaluating verifying contract addresses.
573
+ * "in" checks if the verifying contract is in the provided list.
574
+ * "not in" checks if the verifying contract is not in the provided list.
575
+ */
576
+ operator: z.ZodEnum<["in", "not in"]>;
577
+ }, "strip", z.ZodTypeAny, {
578
+ type: "evmTypedDataVerifyingContract";
579
+ operator: "in" | "not in";
580
+ addresses: `0x${string}`[];
581
+ }, {
582
+ type: "evmTypedDataVerifyingContract";
583
+ operator: "in" | "not in";
584
+ addresses: string[];
585
+ }>]>, "many">;
586
+ /**
587
+ * Type representing a set of criteria for the signEvmTypedData operation.
588
+ * Can contain up to 10 individual criterion objects for typed data field or verifying contract checks.
589
+ */
590
+ export type SignEvmTypedDataCriteria = z.infer<typeof SignEvmTypedDataCriteriaSchema>;
143
591
  /**
144
592
  * A list of comparables to apply against encoded arguments in the transaction's `data` field.
145
593
  */
@@ -326,7 +774,7 @@ export declare const EvmDataCriterionSchema: z.ZodObject<{
326
774
  anonymous?: boolean | undefined;
327
775
  }>, z.ZodEffects<z.ZodIntersection<z.ZodObject<{
328
776
  constant: z.ZodOptional<z.ZodBoolean>;
329
- gas: z.ZodOptional /** The type of criterion, must be "solAddress" for Solana address-based rules. */<z.ZodNumber>;
777
+ gas: z.ZodOptional<z.ZodNumber>;
330
778
  payable: z.ZodOptional<z.ZodBoolean>;
331
779
  }, "strip", z.ZodTypeAny, {
332
780
  payable?: boolean | undefined;
@@ -663,7 +1111,7 @@ export declare const SignEvmTransactionCriteriaSchema: z.ZodArray<z.ZodDiscrimin
663
1111
  anonymous?: boolean | undefined;
664
1112
  }>, z.ZodEffects<z.ZodIntersection<z.ZodObject<{
665
1113
  constant: z.ZodOptional<z.ZodBoolean>;
666
- gas: z.ZodOptional /** The type of criterion, must be "solAddress" for Solana address-based rules. */<z.ZodNumber>;
1114
+ gas: z.ZodOptional<z.ZodNumber>;
667
1115
  payable: z.ZodOptional<z.ZodBoolean>;
668
1116
  }, "strip", z.ZodTypeAny, {
669
1117
  payable?: boolean | undefined;
@@ -910,11 +1358,11 @@ export declare const SignEvmMessageCriteriaSchema: z.ZodArray<z.ZodDiscriminated
910
1358
  */
911
1359
  match: z.ZodString;
912
1360
  }, "strip", z.ZodTypeAny, {
913
- type: "evmMessage";
914
1361
  match: string;
915
- }, {
916
1362
  type: "evmMessage";
1363
+ }, {
917
1364
  match: string;
1365
+ type: "evmMessage";
918
1366
  }>]>, "many">;
919
1367
  /**
920
1368
  * Type representing a set of criteria for the signEvmMessage operation.
@@ -1022,7 +1470,7 @@ export declare const SendEvmTransactionCriteriaSchema: z.ZodArray<z.ZodDiscrimin
1022
1470
  anonymous?: boolean | undefined;
1023
1471
  }>, z.ZodEffects<z.ZodIntersection<z.ZodObject<{
1024
1472
  constant: z.ZodOptional<z.ZodBoolean>;
1025
- gas: z.ZodOptional /** The type of criterion, must be "solAddress" for Solana address-based rules. */<z.ZodNumber>;
1473
+ gas: z.ZodOptional<z.ZodNumber>;
1026
1474
  payable: z.ZodOptional<z.ZodBoolean>;
1027
1475
  }, "strip", z.ZodTypeAny, {
1028
1476
  payable?: boolean | undefined;
@@ -1406,7 +1854,7 @@ export declare const SignEvmTransactionRuleSchema: z.ZodObject<{
1406
1854
  anonymous?: boolean | undefined;
1407
1855
  }>, z.ZodEffects<z.ZodIntersection<z.ZodObject<{
1408
1856
  constant: z.ZodOptional<z.ZodBoolean>;
1409
- gas: z.ZodOptional /** The type of criterion, must be "solAddress" for Solana address-based rules. */<z.ZodNumber>;
1857
+ gas: z.ZodOptional<z.ZodNumber>;
1410
1858
  payable: z.ZodOptional<z.ZodBoolean>;
1411
1859
  }, "strip", z.ZodTypeAny, {
1412
1860
  payable?: boolean | undefined;
@@ -1773,28 +2221,282 @@ export declare const SignEvmMessageRuleSchema: z.ZodObject<{
1773
2221
  */
1774
2222
  match: z.ZodString;
1775
2223
  }, "strip", z.ZodTypeAny, {
1776
- type: "evmMessage";
1777
2224
  match: string;
1778
- }, {
1779
2225
  type: "evmMessage";
2226
+ }, {
1780
2227
  match: string;
2228
+ type: "evmMessage";
1781
2229
  }>]>, "many">;
1782
2230
  }, "strip", z.ZodTypeAny, {
1783
2231
  action: "reject" | "accept";
1784
2232
  operation: "signEvmMessage";
1785
2233
  criteria: {
2234
+ match: string;
1786
2235
  type: "evmMessage";
2236
+ }[];
2237
+ }, {
2238
+ action: "reject" | "accept";
2239
+ operation: "signEvmMessage";
2240
+ criteria: {
1787
2241
  match: string;
2242
+ type: "evmMessage";
1788
2243
  }[];
2244
+ }>;
2245
+ export type SignEvmMessageRule = z.infer<typeof SignEvmMessageRuleSchema>;
2246
+ /**
2247
+ * Type representing a 'signEvmTypedData' policy rule that can accept or reject specific operations
2248
+ * based on a set of criteria.
2249
+ */
2250
+ export declare const SignEvmTypedDataRuleSchema: z.ZodObject<{
2251
+ /**
2252
+ * Determines whether matching the rule will cause a request to be rejected or accepted.
2253
+ * "accept" will allow the signing, "reject" will block it.
2254
+ */
2255
+ action: z.ZodEnum<["reject", "accept"]>;
2256
+ /**
2257
+ * The operation to which this rule applies.
2258
+ * Must be "signEvmTypedData".
2259
+ */
2260
+ operation: z.ZodLiteral<"signEvmTypedData">;
2261
+ /**
2262
+ * The set of criteria that must be matched for this rule to apply.
2263
+ * Must be compatible with the specified operation type.
2264
+ */
2265
+ criteria: z.ZodArray<z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
2266
+ /** The type of criterion, must be "evmTypedDataField" for typed data field-based rules. */
2267
+ type: z.ZodLiteral<"evmTypedDataField">;
2268
+ /**
2269
+ * The EIP-712 type definitions for the typed data.
2270
+ * Must include at minimum the primary type being signed.
2271
+ */
2272
+ types: z.ZodObject<{
2273
+ /**
2274
+ * EIP-712 compliant map of model names to model definitions.
2275
+ */
2276
+ types: z.ZodRecord<z.ZodString, z.ZodArray<z.ZodObject<{
2277
+ name: z.ZodString;
2278
+ type: z.ZodString;
2279
+ }, "strip", z.ZodTypeAny, {
2280
+ type: string;
2281
+ name: string;
2282
+ }, {
2283
+ type: string;
2284
+ name: string;
2285
+ }>, "many">>;
2286
+ /**
2287
+ * The name of the root EIP-712 type. This value must be included in the `types` object.
2288
+ */
2289
+ primaryType: z.ZodString;
2290
+ }, "strip", z.ZodTypeAny, {
2291
+ types: Record<string, {
2292
+ type: string;
2293
+ name: string;
2294
+ }[]>;
2295
+ primaryType: string;
2296
+ }, {
2297
+ types: Record<string, {
2298
+ type: string;
2299
+ name: string;
2300
+ }[]>;
2301
+ primaryType: string;
2302
+ }>;
2303
+ /**
2304
+ * Array of conditions to apply against typed data fields.
2305
+ * Each condition specifies how to validate a specific field within the typed data.
2306
+ */
2307
+ conditions: z.ZodArray<z.ZodUnion<[z.ZodObject<{
2308
+ /**
2309
+ * Array of EVM addresses to compare against.
2310
+ * Each address must be a 0x-prefixed 40-character hexadecimal string.
2311
+ * Limited to a maximum of 100 addresses per condition.
2312
+ */
2313
+ addresses: z.ZodArray<z.ZodEffects<z.ZodString, `0x${string}`, string>, "many">;
2314
+ /**
2315
+ * The operator to use for evaluating addresses.
2316
+ * "in" checks if an address is in the provided list.
2317
+ * "not in" checks if an address is not in the provided list.
2318
+ */
2319
+ operator: z.ZodEnum<["in", "not in"]>;
2320
+ /**
2321
+ * The path to the field to compare against this criterion.
2322
+ * To reference deeply nested fields, use dot notation (e.g., "order.buyer").
2323
+ */
2324
+ path: z.ZodString;
2325
+ }, "strip", z.ZodTypeAny, {
2326
+ path: string;
2327
+ operator: "in" | "not in";
2328
+ addresses: `0x${string}`[];
2329
+ }, {
2330
+ path: string;
2331
+ operator: "in" | "not in";
2332
+ addresses: string[];
2333
+ }>, z.ZodObject<{
2334
+ /**
2335
+ * The numerical value to compare against, as a string.
2336
+ * Must contain only digits.
2337
+ */
2338
+ value: z.ZodString;
2339
+ /**
2340
+ * The comparison operator to use.
2341
+ */
2342
+ operator: z.ZodEnum<[">", ">=", "<", "<=", "=="]>;
2343
+ /**
2344
+ * The path to the field to compare against this criterion.
2345
+ * To reference deeply nested fields, use dot notation (e.g., "order.price").
2346
+ */
2347
+ path: z.ZodString;
2348
+ }, "strip", z.ZodTypeAny, {
2349
+ value: string;
2350
+ path: string;
2351
+ operator: ">" | ">=" | "<" | "<=" | "==";
2352
+ }, {
2353
+ value: string;
2354
+ path: string;
2355
+ operator: ">" | ">=" | "<" | "<=" | "==";
2356
+ }>, z.ZodObject<{
2357
+ /**
2358
+ * A regular expression the string field is matched against.
2359
+ * Accepts valid regular expression syntax described by [RE2](https://github.com/google/re2/wiki/Syntax).
2360
+ */
2361
+ match: z.ZodString;
2362
+ /**
2363
+ * The path to the field to compare against this criterion.
2364
+ * To reference deeply nested fields, use dot notation (e.g., "metadata.description").
2365
+ */
2366
+ path: z.ZodString;
2367
+ }, "strip", z.ZodTypeAny, {
2368
+ match: string;
2369
+ path: string;
2370
+ }, {
2371
+ match: string;
2372
+ path: string;
2373
+ }>]>, "many">;
2374
+ }, "strip", z.ZodTypeAny, {
2375
+ type: "evmTypedDataField";
2376
+ types: {
2377
+ types: Record<string, {
2378
+ type: string;
2379
+ name: string;
2380
+ }[]>;
2381
+ primaryType: string;
2382
+ };
2383
+ conditions: ({
2384
+ path: string;
2385
+ operator: "in" | "not in";
2386
+ addresses: `0x${string}`[];
2387
+ } | {
2388
+ value: string;
2389
+ path: string;
2390
+ operator: ">" | ">=" | "<" | "<=" | "==";
2391
+ } | {
2392
+ match: string;
2393
+ path: string;
2394
+ })[];
2395
+ }, {
2396
+ type: "evmTypedDataField";
2397
+ types: {
2398
+ types: Record<string, {
2399
+ type: string;
2400
+ name: string;
2401
+ }[]>;
2402
+ primaryType: string;
2403
+ };
2404
+ conditions: ({
2405
+ path: string;
2406
+ operator: "in" | "not in";
2407
+ addresses: string[];
2408
+ } | {
2409
+ value: string;
2410
+ path: string;
2411
+ operator: ">" | ">=" | "<" | "<=" | "==";
2412
+ } | {
2413
+ match: string;
2414
+ path: string;
2415
+ })[];
2416
+ }>, z.ZodObject<{
2417
+ /** The type of criterion, must be "evmTypedDataVerifyingContract" for verifying contract-based rules. */
2418
+ type: z.ZodLiteral<"evmTypedDataVerifyingContract">;
2419
+ /**
2420
+ * Array of EVM addresses allowed or disallowed as verifying contracts.
2421
+ * Each address must be a 0x-prefixed 40-character hexadecimal string.
2422
+ * Limited to a maximum of 100 addresses per criterion.
2423
+ */
2424
+ addresses: z.ZodArray<z.ZodEffects<z.ZodString, `0x${string}`, string>, "many">;
2425
+ /**
2426
+ * The operator to use for evaluating verifying contract addresses.
2427
+ * "in" checks if the verifying contract is in the provided list.
2428
+ * "not in" checks if the verifying contract is not in the provided list.
2429
+ */
2430
+ operator: z.ZodEnum<["in", "not in"]>;
2431
+ }, "strip", z.ZodTypeAny, {
2432
+ type: "evmTypedDataVerifyingContract";
2433
+ operator: "in" | "not in";
2434
+ addresses: `0x${string}`[];
2435
+ }, {
2436
+ type: "evmTypedDataVerifyingContract";
2437
+ operator: "in" | "not in";
2438
+ addresses: string[];
2439
+ }>]>, "many">;
2440
+ }, "strip", z.ZodTypeAny, {
2441
+ action: "reject" | "accept";
2442
+ operation: "signEvmTypedData";
2443
+ criteria: ({
2444
+ type: "evmTypedDataField";
2445
+ types: {
2446
+ types: Record<string, {
2447
+ type: string;
2448
+ name: string;
2449
+ }[]>;
2450
+ primaryType: string;
2451
+ };
2452
+ conditions: ({
2453
+ path: string;
2454
+ operator: "in" | "not in";
2455
+ addresses: `0x${string}`[];
2456
+ } | {
2457
+ value: string;
2458
+ path: string;
2459
+ operator: ">" | ">=" | "<" | "<=" | "==";
2460
+ } | {
2461
+ match: string;
2462
+ path: string;
2463
+ })[];
2464
+ } | {
2465
+ type: "evmTypedDataVerifyingContract";
2466
+ operator: "in" | "not in";
2467
+ addresses: `0x${string}`[];
2468
+ })[];
1789
2469
  }, {
1790
2470
  action: "reject" | "accept";
1791
- operation: "signEvmMessage";
1792
- criteria: {
1793
- type: "evmMessage";
1794
- match: string;
1795
- }[];
2471
+ operation: "signEvmTypedData";
2472
+ criteria: ({
2473
+ type: "evmTypedDataField";
2474
+ types: {
2475
+ types: Record<string, {
2476
+ type: string;
2477
+ name: string;
2478
+ }[]>;
2479
+ primaryType: string;
2480
+ };
2481
+ conditions: ({
2482
+ path: string;
2483
+ operator: "in" | "not in";
2484
+ addresses: string[];
2485
+ } | {
2486
+ value: string;
2487
+ path: string;
2488
+ operator: ">" | ">=" | "<" | "<=" | "==";
2489
+ } | {
2490
+ match: string;
2491
+ path: string;
2492
+ })[];
2493
+ } | {
2494
+ type: "evmTypedDataVerifyingContract";
2495
+ operator: "in" | "not in";
2496
+ addresses: string[];
2497
+ })[];
1796
2498
  }>;
1797
- export type SignEvmMessageRule = z.infer<typeof SignEvmMessageRuleSchema>;
2499
+ export type SignEvmTypedDataRule = z.infer<typeof SignEvmTypedDataRuleSchema>;
1798
2500
  /**
1799
2501
  * Type representing a 'sendEvmTransaction' policy rule that can accept or reject specific operations
1800
2502
  * based on a set of criteria.
@@ -1912,7 +2614,7 @@ export declare const SendEvmTransactionRuleSchema: z.ZodObject<{
1912
2614
  anonymous?: boolean | undefined;
1913
2615
  }>, z.ZodEffects<z.ZodIntersection<z.ZodObject<{
1914
2616
  constant: z.ZodOptional<z.ZodBoolean>;
1915
- gas: z.ZodOptional /** The type of criterion, must be "solAddress" for Solana address-based rules. */<z.ZodNumber>;
2617
+ gas: z.ZodOptional<z.ZodNumber>;
1916
2618
  payable: z.ZodOptional<z.ZodBoolean>;
1917
2619
  }, "strip", z.ZodTypeAny, {
1918
2620
  payable?: boolean | undefined;
@@ -2390,7 +3092,7 @@ export declare const RuleSchema: z.ZodDiscriminatedUnion<"operation", [z.ZodObje
2390
3092
  anonymous?: boolean | undefined;
2391
3093
  }>, z.ZodEffects<z.ZodIntersection<z.ZodObject<{
2392
3094
  constant: z.ZodOptional<z.ZodBoolean>;
2393
- gas: z.ZodOptional /** The type of criterion, must be "solAddress" for Solana address-based rules. */<z.ZodNumber>;
3095
+ gas: z.ZodOptional<z.ZodNumber>;
2394
3096
  payable: z.ZodOptional<z.ZodBoolean>;
2395
3097
  }, "strip", z.ZodTypeAny, {
2396
3098
  payable?: boolean | undefined;
@@ -2745,26 +3447,274 @@ export declare const RuleSchema: z.ZodDiscriminatedUnion<"operation", [z.ZodObje
2745
3447
  */
2746
3448
  match: z.ZodString;
2747
3449
  }, "strip", z.ZodTypeAny, {
2748
- type: "evmMessage";
2749
3450
  match: string;
2750
- }, {
2751
3451
  type: "evmMessage";
3452
+ }, {
2752
3453
  match: string;
3454
+ type: "evmMessage";
2753
3455
  }>]>, "many">;
2754
3456
  }, "strip", z.ZodTypeAny, {
2755
3457
  action: "reject" | "accept";
2756
3458
  operation: "signEvmMessage";
2757
3459
  criteria: {
2758
- type: "evmMessage";
2759
3460
  match: string;
3461
+ type: "evmMessage";
2760
3462
  }[];
2761
3463
  }, {
2762
3464
  action: "reject" | "accept";
2763
3465
  operation: "signEvmMessage";
2764
3466
  criteria: {
2765
- type: "evmMessage";
2766
3467
  match: string;
3468
+ type: "evmMessage";
2767
3469
  }[];
3470
+ }>, z.ZodObject<{
3471
+ /**
3472
+ * Determines whether matching the rule will cause a request to be rejected or accepted.
3473
+ * "accept" will allow the signing, "reject" will block it.
3474
+ */
3475
+ action: z.ZodEnum<["reject", "accept"]>;
3476
+ /**
3477
+ * The operation to which this rule applies.
3478
+ * Must be "signEvmTypedData".
3479
+ */
3480
+ operation: z.ZodLiteral<"signEvmTypedData">;
3481
+ /**
3482
+ * The set of criteria that must be matched for this rule to apply.
3483
+ * Must be compatible with the specified operation type.
3484
+ */
3485
+ criteria: z.ZodArray<z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
3486
+ /** The type of criterion, must be "evmTypedDataField" for typed data field-based rules. */
3487
+ type: z.ZodLiteral<"evmTypedDataField">;
3488
+ /**
3489
+ * The EIP-712 type definitions for the typed data.
3490
+ * Must include at minimum the primary type being signed.
3491
+ */
3492
+ types: z.ZodObject<{
3493
+ /**
3494
+ * EIP-712 compliant map of model names to model definitions.
3495
+ */
3496
+ types: z.ZodRecord<z.ZodString, z.ZodArray<z.ZodObject<{
3497
+ name: z.ZodString;
3498
+ type: z.ZodString;
3499
+ }, "strip", z.ZodTypeAny, {
3500
+ type: string;
3501
+ name: string;
3502
+ }, {
3503
+ type: string;
3504
+ name: string;
3505
+ }>, "many">>;
3506
+ /**
3507
+ * The name of the root EIP-712 type. This value must be included in the `types` object.
3508
+ */
3509
+ primaryType: z.ZodString;
3510
+ }, "strip", z.ZodTypeAny, {
3511
+ types: Record<string, {
3512
+ type: string;
3513
+ name: string;
3514
+ }[]>;
3515
+ primaryType: string;
3516
+ }, {
3517
+ types: Record<string, {
3518
+ type: string;
3519
+ name: string;
3520
+ }[]>;
3521
+ primaryType: string;
3522
+ }>;
3523
+ /**
3524
+ * Array of conditions to apply against typed data fields.
3525
+ * Each condition specifies how to validate a specific field within the typed data.
3526
+ */
3527
+ conditions: z.ZodArray<z.ZodUnion<[z.ZodObject<{
3528
+ /**
3529
+ * Array of EVM addresses to compare against.
3530
+ * Each address must be a 0x-prefixed 40-character hexadecimal string.
3531
+ * Limited to a maximum of 100 addresses per condition.
3532
+ */
3533
+ addresses: z.ZodArray<z.ZodEffects<z.ZodString, `0x${string}`, string>, "many">;
3534
+ /**
3535
+ * The operator to use for evaluating addresses.
3536
+ * "in" checks if an address is in the provided list.
3537
+ * "not in" checks if an address is not in the provided list.
3538
+ */
3539
+ operator: z.ZodEnum<["in", "not in"]>;
3540
+ /**
3541
+ * The path to the field to compare against this criterion.
3542
+ * To reference deeply nested fields, use dot notation (e.g., "order.buyer").
3543
+ */
3544
+ path: z.ZodString;
3545
+ }, "strip", z.ZodTypeAny, {
3546
+ path: string;
3547
+ operator: "in" | "not in";
3548
+ addresses: `0x${string}`[];
3549
+ }, {
3550
+ path: string;
3551
+ operator: "in" | "not in";
3552
+ addresses: string[];
3553
+ }>, z.ZodObject<{
3554
+ /**
3555
+ * The numerical value to compare against, as a string.
3556
+ * Must contain only digits.
3557
+ */
3558
+ value: z.ZodString;
3559
+ /**
3560
+ * The comparison operator to use.
3561
+ */
3562
+ operator: z.ZodEnum<[">", ">=", "<", "<=", "=="]>;
3563
+ /**
3564
+ * The path to the field to compare against this criterion.
3565
+ * To reference deeply nested fields, use dot notation (e.g., "order.price").
3566
+ */
3567
+ path: z.ZodString;
3568
+ }, "strip", z.ZodTypeAny, {
3569
+ value: string;
3570
+ path: string;
3571
+ operator: ">" | ">=" | "<" | "<=" | "==";
3572
+ }, {
3573
+ value: string;
3574
+ path: string;
3575
+ operator: ">" | ">=" | "<" | "<=" | "==";
3576
+ }>, z.ZodObject<{
3577
+ /**
3578
+ * A regular expression the string field is matched against.
3579
+ * Accepts valid regular expression syntax described by [RE2](https://github.com/google/re2/wiki/Syntax).
3580
+ */
3581
+ match: z.ZodString;
3582
+ /**
3583
+ * The path to the field to compare against this criterion.
3584
+ * To reference deeply nested fields, use dot notation (e.g., "metadata.description").
3585
+ */
3586
+ path: z.ZodString;
3587
+ }, "strip", z.ZodTypeAny, {
3588
+ match: string;
3589
+ path: string;
3590
+ }, {
3591
+ match: string;
3592
+ path: string;
3593
+ }>]>, "many">;
3594
+ }, "strip", z.ZodTypeAny, {
3595
+ type: "evmTypedDataField";
3596
+ types: {
3597
+ types: Record<string, {
3598
+ type: string;
3599
+ name: string;
3600
+ }[]>;
3601
+ primaryType: string;
3602
+ };
3603
+ conditions: ({
3604
+ path: string;
3605
+ operator: "in" | "not in";
3606
+ addresses: `0x${string}`[];
3607
+ } | {
3608
+ value: string;
3609
+ path: string;
3610
+ operator: ">" | ">=" | "<" | "<=" | "==";
3611
+ } | {
3612
+ match: string;
3613
+ path: string;
3614
+ })[];
3615
+ }, {
3616
+ type: "evmTypedDataField";
3617
+ types: {
3618
+ types: Record<string, {
3619
+ type: string;
3620
+ name: string;
3621
+ }[]>;
3622
+ primaryType: string;
3623
+ };
3624
+ conditions: ({
3625
+ path: string;
3626
+ operator: "in" | "not in";
3627
+ addresses: string[];
3628
+ } | {
3629
+ value: string;
3630
+ path: string;
3631
+ operator: ">" | ">=" | "<" | "<=" | "==";
3632
+ } | {
3633
+ match: string;
3634
+ path: string;
3635
+ })[];
3636
+ }>, z.ZodObject<{
3637
+ /** The type of criterion, must be "evmTypedDataVerifyingContract" for verifying contract-based rules. */
3638
+ type: z.ZodLiteral<"evmTypedDataVerifyingContract">;
3639
+ /**
3640
+ * Array of EVM addresses allowed or disallowed as verifying contracts.
3641
+ * Each address must be a 0x-prefixed 40-character hexadecimal string.
3642
+ * Limited to a maximum of 100 addresses per criterion.
3643
+ */
3644
+ addresses: z.ZodArray<z.ZodEffects<z.ZodString, `0x${string}`, string>, "many">;
3645
+ /**
3646
+ * The operator to use for evaluating verifying contract addresses.
3647
+ * "in" checks if the verifying contract is in the provided list.
3648
+ * "not in" checks if the verifying contract is not in the provided list.
3649
+ */
3650
+ operator: z.ZodEnum<["in", "not in"]>;
3651
+ }, "strip", z.ZodTypeAny, {
3652
+ type: "evmTypedDataVerifyingContract";
3653
+ operator: "in" | "not in";
3654
+ addresses: `0x${string}`[];
3655
+ }, {
3656
+ type: "evmTypedDataVerifyingContract";
3657
+ operator: "in" | "not in";
3658
+ addresses: string[];
3659
+ }>]>, "many">;
3660
+ }, "strip", z.ZodTypeAny, {
3661
+ action: "reject" | "accept";
3662
+ operation: "signEvmTypedData";
3663
+ criteria: ({
3664
+ type: "evmTypedDataField";
3665
+ types: {
3666
+ types: Record<string, {
3667
+ type: string;
3668
+ name: string;
3669
+ }[]>;
3670
+ primaryType: string;
3671
+ };
3672
+ conditions: ({
3673
+ path: string;
3674
+ operator: "in" | "not in";
3675
+ addresses: `0x${string}`[];
3676
+ } | {
3677
+ value: string;
3678
+ path: string;
3679
+ operator: ">" | ">=" | "<" | "<=" | "==";
3680
+ } | {
3681
+ match: string;
3682
+ path: string;
3683
+ })[];
3684
+ } | {
3685
+ type: "evmTypedDataVerifyingContract";
3686
+ operator: "in" | "not in";
3687
+ addresses: `0x${string}`[];
3688
+ })[];
3689
+ }, {
3690
+ action: "reject" | "accept";
3691
+ operation: "signEvmTypedData";
3692
+ criteria: ({
3693
+ type: "evmTypedDataField";
3694
+ types: {
3695
+ types: Record<string, {
3696
+ type: string;
3697
+ name: string;
3698
+ }[]>;
3699
+ primaryType: string;
3700
+ };
3701
+ conditions: ({
3702
+ path: string;
3703
+ operator: "in" | "not in";
3704
+ addresses: string[];
3705
+ } | {
3706
+ value: string;
3707
+ path: string;
3708
+ operator: ">" | ">=" | "<" | "<=" | "==";
3709
+ } | {
3710
+ match: string;
3711
+ path: string;
3712
+ })[];
3713
+ } | {
3714
+ type: "evmTypedDataVerifyingContract";
3715
+ operator: "in" | "not in";
3716
+ addresses: string[];
3717
+ })[];
2768
3718
  }>, z.ZodObject<{
2769
3719
  /**
2770
3720
  * Determines whether matching the rule will cause a request to be rejected or accepted.
@@ -2878,7 +3828,7 @@ export declare const RuleSchema: z.ZodDiscriminatedUnion<"operation", [z.ZodObje
2878
3828
  anonymous?: boolean | undefined;
2879
3829
  }>, z.ZodEffects<z.ZodIntersection<z.ZodObject<{
2880
3830
  constant: z.ZodOptional<z.ZodBoolean>;
2881
- gas: z.ZodOptional /** The type of criterion, must be "solAddress" for Solana address-based rules. */<z.ZodNumber>;
3831
+ gas: z.ZodOptional<z.ZodNumber>;
2882
3832
  payable: z.ZodOptional<z.ZodBoolean>;
2883
3833
  }, "strip", z.ZodTypeAny, {
2884
3834
  payable?: boolean | undefined;
@@ -3378,7 +4328,7 @@ export declare const CreatePolicyBodySchema: z.ZodObject<{
3378
4328
  anonymous?: boolean | undefined;
3379
4329
  }>, z.ZodEffects<z.ZodIntersection<z.ZodObject<{
3380
4330
  constant: z.ZodOptional<z.ZodBoolean>;
3381
- gas: z.ZodOptional /** The type of criterion, must be "solAddress" for Solana address-based rules. */<z.ZodNumber>;
4331
+ gas: z.ZodOptional<z.ZodNumber>;
3382
4332
  payable: z.ZodOptional<z.ZodBoolean>;
3383
4333
  }, "strip", z.ZodTypeAny, {
3384
4334
  payable?: boolean | undefined;
@@ -3728,31 +4678,279 @@ export declare const CreatePolicyBodySchema: z.ZodObject<{
3728
4678
  /** The type of criterion, must be "evmMessage" for EVM message-based rules. */
3729
4679
  type: z.ZodLiteral<"evmMessage">;
3730
4680
  /**
3731
- * A regular expression the message is matched against.
3732
- * Accepts valid regular expression syntax described by [RE2](https://github.com/google/re2/wiki/Syntax).
4681
+ * A regular expression the message is matched against.
4682
+ * Accepts valid regular expression syntax described by [RE2](https://github.com/google/re2/wiki/Syntax).
4683
+ */
4684
+ match: z.ZodString;
4685
+ }, "strip", z.ZodTypeAny, {
4686
+ match: string;
4687
+ type: "evmMessage";
4688
+ }, {
4689
+ match: string;
4690
+ type: "evmMessage";
4691
+ }>]>, "many">;
4692
+ }, "strip", z.ZodTypeAny, {
4693
+ action: "reject" | "accept";
4694
+ operation: "signEvmMessage";
4695
+ criteria: {
4696
+ match: string;
4697
+ type: "evmMessage";
4698
+ }[];
4699
+ }, {
4700
+ action: "reject" | "accept";
4701
+ operation: "signEvmMessage";
4702
+ criteria: {
4703
+ match: string;
4704
+ type: "evmMessage";
4705
+ }[];
4706
+ }>, z.ZodObject<{
4707
+ /**
4708
+ * Determines whether matching the rule will cause a request to be rejected or accepted.
4709
+ * "accept" will allow the signing, "reject" will block it.
4710
+ */
4711
+ action: z.ZodEnum<["reject", "accept"]>;
4712
+ /**
4713
+ * The operation to which this rule applies.
4714
+ * Must be "signEvmTypedData".
4715
+ */
4716
+ operation: z.ZodLiteral<"signEvmTypedData">;
4717
+ /**
4718
+ * The set of criteria that must be matched for this rule to apply.
4719
+ * Must be compatible with the specified operation type.
4720
+ */
4721
+ criteria: z.ZodArray<z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
4722
+ /** The type of criterion, must be "evmTypedDataField" for typed data field-based rules. */
4723
+ type: z.ZodLiteral<"evmTypedDataField">;
4724
+ /**
4725
+ * The EIP-712 type definitions for the typed data.
4726
+ * Must include at minimum the primary type being signed.
4727
+ */
4728
+ types: z.ZodObject<{
4729
+ /**
4730
+ * EIP-712 compliant map of model names to model definitions.
4731
+ */
4732
+ types: z.ZodRecord<z.ZodString, z.ZodArray<z.ZodObject<{
4733
+ name: z.ZodString;
4734
+ type: z.ZodString;
4735
+ }, "strip", z.ZodTypeAny, {
4736
+ type: string;
4737
+ name: string;
4738
+ }, {
4739
+ type: string;
4740
+ name: string;
4741
+ }>, "many">>;
4742
+ /**
4743
+ * The name of the root EIP-712 type. This value must be included in the `types` object.
4744
+ */
4745
+ primaryType: z.ZodString;
4746
+ }, "strip", z.ZodTypeAny, {
4747
+ types: Record<string, {
4748
+ type: string;
4749
+ name: string;
4750
+ }[]>;
4751
+ primaryType: string;
4752
+ }, {
4753
+ types: Record<string, {
4754
+ type: string;
4755
+ name: string;
4756
+ }[]>;
4757
+ primaryType: string;
4758
+ }>;
4759
+ /**
4760
+ * Array of conditions to apply against typed data fields.
4761
+ * Each condition specifies how to validate a specific field within the typed data.
4762
+ */
4763
+ conditions: z.ZodArray<z.ZodUnion<[z.ZodObject<{
4764
+ /**
4765
+ * Array of EVM addresses to compare against.
4766
+ * Each address must be a 0x-prefixed 40-character hexadecimal string.
4767
+ * Limited to a maximum of 100 addresses per condition.
4768
+ */
4769
+ addresses: z.ZodArray<z.ZodEffects<z.ZodString, `0x${string}`, string>, "many">;
4770
+ /**
4771
+ * The operator to use for evaluating addresses.
4772
+ * "in" checks if an address is in the provided list.
4773
+ * "not in" checks if an address is not in the provided list.
4774
+ */
4775
+ operator: z.ZodEnum<["in", "not in"]>;
4776
+ /**
4777
+ * The path to the field to compare against this criterion.
4778
+ * To reference deeply nested fields, use dot notation (e.g., "order.buyer").
4779
+ */
4780
+ path: z.ZodString;
4781
+ }, "strip", z.ZodTypeAny, {
4782
+ path: string;
4783
+ operator: "in" | "not in";
4784
+ addresses: `0x${string}`[];
4785
+ }, {
4786
+ path: string;
4787
+ operator: "in" | "not in";
4788
+ addresses: string[];
4789
+ }>, z.ZodObject<{
4790
+ /**
4791
+ * The numerical value to compare against, as a string.
4792
+ * Must contain only digits.
4793
+ */
4794
+ value: z.ZodString;
4795
+ /**
4796
+ * The comparison operator to use.
4797
+ */
4798
+ operator: z.ZodEnum<[">", ">=", "<", "<=", "=="]>;
4799
+ /**
4800
+ * The path to the field to compare against this criterion.
4801
+ * To reference deeply nested fields, use dot notation (e.g., "order.price").
4802
+ */
4803
+ path: z.ZodString;
4804
+ }, "strip", z.ZodTypeAny, {
4805
+ value: string;
4806
+ path: string;
4807
+ operator: ">" | ">=" | "<" | "<=" | "==";
4808
+ }, {
4809
+ value: string;
4810
+ path: string;
4811
+ operator: ">" | ">=" | "<" | "<=" | "==";
4812
+ }>, z.ZodObject<{
4813
+ /**
4814
+ * A regular expression the string field is matched against.
4815
+ * Accepts valid regular expression syntax described by [RE2](https://github.com/google/re2/wiki/Syntax).
4816
+ */
4817
+ match: z.ZodString;
4818
+ /**
4819
+ * The path to the field to compare against this criterion.
4820
+ * To reference deeply nested fields, use dot notation (e.g., "metadata.description").
4821
+ */
4822
+ path: z.ZodString;
4823
+ }, "strip", z.ZodTypeAny, {
4824
+ match: string;
4825
+ path: string;
4826
+ }, {
4827
+ match: string;
4828
+ path: string;
4829
+ }>]>, "many">;
4830
+ }, "strip", z.ZodTypeAny, {
4831
+ type: "evmTypedDataField";
4832
+ types: {
4833
+ types: Record<string, {
4834
+ type: string;
4835
+ name: string;
4836
+ }[]>;
4837
+ primaryType: string;
4838
+ };
4839
+ conditions: ({
4840
+ path: string;
4841
+ operator: "in" | "not in";
4842
+ addresses: `0x${string}`[];
4843
+ } | {
4844
+ value: string;
4845
+ path: string;
4846
+ operator: ">" | ">=" | "<" | "<=" | "==";
4847
+ } | {
4848
+ match: string;
4849
+ path: string;
4850
+ })[];
4851
+ }, {
4852
+ type: "evmTypedDataField";
4853
+ types: {
4854
+ types: Record<string, {
4855
+ type: string;
4856
+ name: string;
4857
+ }[]>;
4858
+ primaryType: string;
4859
+ };
4860
+ conditions: ({
4861
+ path: string;
4862
+ operator: "in" | "not in";
4863
+ addresses: string[];
4864
+ } | {
4865
+ value: string;
4866
+ path: string;
4867
+ operator: ">" | ">=" | "<" | "<=" | "==";
4868
+ } | {
4869
+ match: string;
4870
+ path: string;
4871
+ })[];
4872
+ }>, z.ZodObject<{
4873
+ /** The type of criterion, must be "evmTypedDataVerifyingContract" for verifying contract-based rules. */
4874
+ type: z.ZodLiteral<"evmTypedDataVerifyingContract">;
4875
+ /**
4876
+ * Array of EVM addresses allowed or disallowed as verifying contracts.
4877
+ * Each address must be a 0x-prefixed 40-character hexadecimal string.
4878
+ * Limited to a maximum of 100 addresses per criterion.
3733
4879
  */
3734
- match: z.ZodString;
4880
+ addresses: z.ZodArray<z.ZodEffects<z.ZodString, `0x${string}`, string>, "many">;
4881
+ /**
4882
+ * The operator to use for evaluating verifying contract addresses.
4883
+ * "in" checks if the verifying contract is in the provided list.
4884
+ * "not in" checks if the verifying contract is not in the provided list.
4885
+ */
4886
+ operator: z.ZodEnum<["in", "not in"]>;
3735
4887
  }, "strip", z.ZodTypeAny, {
3736
- type: "evmMessage";
3737
- match: string;
4888
+ type: "evmTypedDataVerifyingContract";
4889
+ operator: "in" | "not in";
4890
+ addresses: `0x${string}`[];
3738
4891
  }, {
3739
- type: "evmMessage";
3740
- match: string;
4892
+ type: "evmTypedDataVerifyingContract";
4893
+ operator: "in" | "not in";
4894
+ addresses: string[];
3741
4895
  }>]>, "many">;
3742
4896
  }, "strip", z.ZodTypeAny, {
3743
4897
  action: "reject" | "accept";
3744
- operation: "signEvmMessage";
3745
- criteria: {
3746
- type: "evmMessage";
3747
- match: string;
3748
- }[];
4898
+ operation: "signEvmTypedData";
4899
+ criteria: ({
4900
+ type: "evmTypedDataField";
4901
+ types: {
4902
+ types: Record<string, {
4903
+ type: string;
4904
+ name: string;
4905
+ }[]>;
4906
+ primaryType: string;
4907
+ };
4908
+ conditions: ({
4909
+ path: string;
4910
+ operator: "in" | "not in";
4911
+ addresses: `0x${string}`[];
4912
+ } | {
4913
+ value: string;
4914
+ path: string;
4915
+ operator: ">" | ">=" | "<" | "<=" | "==";
4916
+ } | {
4917
+ match: string;
4918
+ path: string;
4919
+ })[];
4920
+ } | {
4921
+ type: "evmTypedDataVerifyingContract";
4922
+ operator: "in" | "not in";
4923
+ addresses: `0x${string}`[];
4924
+ })[];
3749
4925
  }, {
3750
4926
  action: "reject" | "accept";
3751
- operation: "signEvmMessage";
3752
- criteria: {
3753
- type: "evmMessage";
3754
- match: string;
3755
- }[];
4927
+ operation: "signEvmTypedData";
4928
+ criteria: ({
4929
+ type: "evmTypedDataField";
4930
+ types: {
4931
+ types: Record<string, {
4932
+ type: string;
4933
+ name: string;
4934
+ }[]>;
4935
+ primaryType: string;
4936
+ };
4937
+ conditions: ({
4938
+ path: string;
4939
+ operator: "in" | "not in";
4940
+ addresses: string[];
4941
+ } | {
4942
+ value: string;
4943
+ path: string;
4944
+ operator: ">" | ">=" | "<" | "<=" | "==";
4945
+ } | {
4946
+ match: string;
4947
+ path: string;
4948
+ })[];
4949
+ } | {
4950
+ type: "evmTypedDataVerifyingContract";
4951
+ operator: "in" | "not in";
4952
+ addresses: string[];
4953
+ })[];
3756
4954
  }>, z.ZodObject<{
3757
4955
  /**
3758
4956
  * Determines whether matching the rule will cause a request to be rejected or accepted.
@@ -3866,7 +5064,7 @@ export declare const CreatePolicyBodySchema: z.ZodObject<{
3866
5064
  anonymous?: boolean | undefined;
3867
5065
  }>, z.ZodEffects<z.ZodIntersection<z.ZodObject<{
3868
5066
  constant: z.ZodOptional<z.ZodBoolean>;
3869
- gas: z.ZodOptional /** The type of criterion, must be "solAddress" for Solana address-based rules. */<z.ZodNumber>;
5067
+ gas: z.ZodOptional<z.ZodNumber>;
3870
5068
  payable: z.ZodOptional<z.ZodBoolean>;
3871
5069
  }, "strip", z.ZodTypeAny, {
3872
5070
  payable?: boolean | undefined;
@@ -4309,9 +5507,38 @@ export declare const CreatePolicyBodySchema: z.ZodObject<{
4309
5507
  action: "reject" | "accept";
4310
5508
  operation: "signEvmMessage";
4311
5509
  criteria: {
4312
- type: "evmMessage";
4313
5510
  match: string;
5511
+ type: "evmMessage";
4314
5512
  }[];
5513
+ } | {
5514
+ action: "reject" | "accept";
5515
+ operation: "signEvmTypedData";
5516
+ criteria: ({
5517
+ type: "evmTypedDataField";
5518
+ types: {
5519
+ types: Record<string, {
5520
+ type: string;
5521
+ name: string;
5522
+ }[]>;
5523
+ primaryType: string;
5524
+ };
5525
+ conditions: ({
5526
+ path: string;
5527
+ operator: "in" | "not in";
5528
+ addresses: `0x${string}`[];
5529
+ } | {
5530
+ value: string;
5531
+ path: string;
5532
+ operator: ">" | ">=" | "<" | "<=" | "==";
5533
+ } | {
5534
+ match: string;
5535
+ path: string;
5536
+ })[];
5537
+ } | {
5538
+ type: "evmTypedDataVerifyingContract";
5539
+ operator: "in" | "not in";
5540
+ addresses: `0x${string}`[];
5541
+ })[];
4315
5542
  } | {
4316
5543
  action: "reject" | "accept";
4317
5544
  operation: "sendEvmTransaction";
@@ -4419,9 +5646,38 @@ export declare const CreatePolicyBodySchema: z.ZodObject<{
4419
5646
  action: "reject" | "accept";
4420
5647
  operation: "signEvmMessage";
4421
5648
  criteria: {
4422
- type: "evmMessage";
4423
5649
  match: string;
5650
+ type: "evmMessage";
4424
5651
  }[];
5652
+ } | {
5653
+ action: "reject" | "accept";
5654
+ operation: "signEvmTypedData";
5655
+ criteria: ({
5656
+ type: "evmTypedDataField";
5657
+ types: {
5658
+ types: Record<string, {
5659
+ type: string;
5660
+ name: string;
5661
+ }[]>;
5662
+ primaryType: string;
5663
+ };
5664
+ conditions: ({
5665
+ path: string;
5666
+ operator: "in" | "not in";
5667
+ addresses: string[];
5668
+ } | {
5669
+ value: string;
5670
+ path: string;
5671
+ operator: ">" | ">=" | "<" | "<=" | "==";
5672
+ } | {
5673
+ match: string;
5674
+ path: string;
5675
+ })[];
5676
+ } | {
5677
+ type: "evmTypedDataVerifyingContract";
5678
+ operator: "in" | "not in";
5679
+ addresses: string[];
5680
+ })[];
4425
5681
  } | {
4426
5682
  action: "reject" | "accept";
4427
5683
  operation: "sendEvmTransaction";
@@ -4570,7 +5826,7 @@ export declare const UpdatePolicyBodySchema: z.ZodObject<{
4570
5826
  anonymous?: boolean | undefined;
4571
5827
  }>, z.ZodEffects<z.ZodIntersection<z.ZodObject<{
4572
5828
  constant: z.ZodOptional<z.ZodBoolean>;
4573
- gas: z.ZodOptional /** The type of criterion, must be "solAddress" for Solana address-based rules. */<z.ZodNumber>;
5829
+ gas: z.ZodOptional<z.ZodNumber>;
4574
5830
  payable: z.ZodOptional<z.ZodBoolean>;
4575
5831
  }, "strip", z.ZodTypeAny, {
4576
5832
  payable?: boolean | undefined;
@@ -4925,26 +6181,274 @@ export declare const UpdatePolicyBodySchema: z.ZodObject<{
4925
6181
  */
4926
6182
  match: z.ZodString;
4927
6183
  }, "strip", z.ZodTypeAny, {
4928
- type: "evmMessage";
4929
6184
  match: string;
4930
- }, {
4931
6185
  type: "evmMessage";
6186
+ }, {
4932
6187
  match: string;
6188
+ type: "evmMessage";
4933
6189
  }>]>, "many">;
4934
6190
  }, "strip", z.ZodTypeAny, {
4935
6191
  action: "reject" | "accept";
4936
6192
  operation: "signEvmMessage";
4937
6193
  criteria: {
4938
- type: "evmMessage";
4939
6194
  match: string;
6195
+ type: "evmMessage";
4940
6196
  }[];
4941
6197
  }, {
4942
6198
  action: "reject" | "accept";
4943
6199
  operation: "signEvmMessage";
4944
6200
  criteria: {
4945
- type: "evmMessage";
4946
6201
  match: string;
6202
+ type: "evmMessage";
4947
6203
  }[];
6204
+ }>, z.ZodObject<{
6205
+ /**
6206
+ * Determines whether matching the rule will cause a request to be rejected or accepted.
6207
+ * "accept" will allow the signing, "reject" will block it.
6208
+ */
6209
+ action: z.ZodEnum<["reject", "accept"]>;
6210
+ /**
6211
+ * The operation to which this rule applies.
6212
+ * Must be "signEvmTypedData".
6213
+ */
6214
+ operation: z.ZodLiteral<"signEvmTypedData">;
6215
+ /**
6216
+ * The set of criteria that must be matched for this rule to apply.
6217
+ * Must be compatible with the specified operation type.
6218
+ */
6219
+ criteria: z.ZodArray<z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
6220
+ /** The type of criterion, must be "evmTypedDataField" for typed data field-based rules. */
6221
+ type: z.ZodLiteral<"evmTypedDataField">;
6222
+ /**
6223
+ * The EIP-712 type definitions for the typed data.
6224
+ * Must include at minimum the primary type being signed.
6225
+ */
6226
+ types: z.ZodObject<{
6227
+ /**
6228
+ * EIP-712 compliant map of model names to model definitions.
6229
+ */
6230
+ types: z.ZodRecord<z.ZodString, z.ZodArray<z.ZodObject<{
6231
+ name: z.ZodString;
6232
+ type: z.ZodString;
6233
+ }, "strip", z.ZodTypeAny, {
6234
+ type: string;
6235
+ name: string;
6236
+ }, {
6237
+ type: string;
6238
+ name: string;
6239
+ }>, "many">>;
6240
+ /**
6241
+ * The name of the root EIP-712 type. This value must be included in the `types` object.
6242
+ */
6243
+ primaryType: z.ZodString;
6244
+ }, "strip", z.ZodTypeAny, {
6245
+ types: Record<string, {
6246
+ type: string;
6247
+ name: string;
6248
+ }[]>;
6249
+ primaryType: string;
6250
+ }, {
6251
+ types: Record<string, {
6252
+ type: string;
6253
+ name: string;
6254
+ }[]>;
6255
+ primaryType: string;
6256
+ }>;
6257
+ /**
6258
+ * Array of conditions to apply against typed data fields.
6259
+ * Each condition specifies how to validate a specific field within the typed data.
6260
+ */
6261
+ conditions: z.ZodArray<z.ZodUnion<[z.ZodObject<{
6262
+ /**
6263
+ * Array of EVM addresses to compare against.
6264
+ * Each address must be a 0x-prefixed 40-character hexadecimal string.
6265
+ * Limited to a maximum of 100 addresses per condition.
6266
+ */
6267
+ addresses: z.ZodArray<z.ZodEffects<z.ZodString, `0x${string}`, string>, "many">;
6268
+ /**
6269
+ * The operator to use for evaluating addresses.
6270
+ * "in" checks if an address is in the provided list.
6271
+ * "not in" checks if an address is not in the provided list.
6272
+ */
6273
+ operator: z.ZodEnum<["in", "not in"]>;
6274
+ /**
6275
+ * The path to the field to compare against this criterion.
6276
+ * To reference deeply nested fields, use dot notation (e.g., "order.buyer").
6277
+ */
6278
+ path: z.ZodString;
6279
+ }, "strip", z.ZodTypeAny, {
6280
+ path: string;
6281
+ operator: "in" | "not in";
6282
+ addresses: `0x${string}`[];
6283
+ }, {
6284
+ path: string;
6285
+ operator: "in" | "not in";
6286
+ addresses: string[];
6287
+ }>, z.ZodObject<{
6288
+ /**
6289
+ * The numerical value to compare against, as a string.
6290
+ * Must contain only digits.
6291
+ */
6292
+ value: z.ZodString;
6293
+ /**
6294
+ * The comparison operator to use.
6295
+ */
6296
+ operator: z.ZodEnum<[">", ">=", "<", "<=", "=="]>;
6297
+ /**
6298
+ * The path to the field to compare against this criterion.
6299
+ * To reference deeply nested fields, use dot notation (e.g., "order.price").
6300
+ */
6301
+ path: z.ZodString;
6302
+ }, "strip", z.ZodTypeAny, {
6303
+ value: string;
6304
+ path: string;
6305
+ operator: ">" | ">=" | "<" | "<=" | "==";
6306
+ }, {
6307
+ value: string;
6308
+ path: string;
6309
+ operator: ">" | ">=" | "<" | "<=" | "==";
6310
+ }>, z.ZodObject<{
6311
+ /**
6312
+ * A regular expression the string field is matched against.
6313
+ * Accepts valid regular expression syntax described by [RE2](https://github.com/google/re2/wiki/Syntax).
6314
+ */
6315
+ match: z.ZodString;
6316
+ /**
6317
+ * The path to the field to compare against this criterion.
6318
+ * To reference deeply nested fields, use dot notation (e.g., "metadata.description").
6319
+ */
6320
+ path: z.ZodString;
6321
+ }, "strip", z.ZodTypeAny, {
6322
+ match: string;
6323
+ path: string;
6324
+ }, {
6325
+ match: string;
6326
+ path: string;
6327
+ }>]>, "many">;
6328
+ }, "strip", z.ZodTypeAny, {
6329
+ type: "evmTypedDataField";
6330
+ types: {
6331
+ types: Record<string, {
6332
+ type: string;
6333
+ name: string;
6334
+ }[]>;
6335
+ primaryType: string;
6336
+ };
6337
+ conditions: ({
6338
+ path: string;
6339
+ operator: "in" | "not in";
6340
+ addresses: `0x${string}`[];
6341
+ } | {
6342
+ value: string;
6343
+ path: string;
6344
+ operator: ">" | ">=" | "<" | "<=" | "==";
6345
+ } | {
6346
+ match: string;
6347
+ path: string;
6348
+ })[];
6349
+ }, {
6350
+ type: "evmTypedDataField";
6351
+ types: {
6352
+ types: Record<string, {
6353
+ type: string;
6354
+ name: string;
6355
+ }[]>;
6356
+ primaryType: string;
6357
+ };
6358
+ conditions: ({
6359
+ path: string;
6360
+ operator: "in" | "not in";
6361
+ addresses: string[];
6362
+ } | {
6363
+ value: string;
6364
+ path: string;
6365
+ operator: ">" | ">=" | "<" | "<=" | "==";
6366
+ } | {
6367
+ match: string;
6368
+ path: string;
6369
+ })[];
6370
+ }>, z.ZodObject<{
6371
+ /** The type of criterion, must be "evmTypedDataVerifyingContract" for verifying contract-based rules. */
6372
+ type: z.ZodLiteral<"evmTypedDataVerifyingContract">;
6373
+ /**
6374
+ * Array of EVM addresses allowed or disallowed as verifying contracts.
6375
+ * Each address must be a 0x-prefixed 40-character hexadecimal string.
6376
+ * Limited to a maximum of 100 addresses per criterion.
6377
+ */
6378
+ addresses: z.ZodArray<z.ZodEffects<z.ZodString, `0x${string}`, string>, "many">;
6379
+ /**
6380
+ * The operator to use for evaluating verifying contract addresses.
6381
+ * "in" checks if the verifying contract is in the provided list.
6382
+ * "not in" checks if the verifying contract is not in the provided list.
6383
+ */
6384
+ operator: z.ZodEnum<["in", "not in"]>;
6385
+ }, "strip", z.ZodTypeAny, {
6386
+ type: "evmTypedDataVerifyingContract";
6387
+ operator: "in" | "not in";
6388
+ addresses: `0x${string}`[];
6389
+ }, {
6390
+ type: "evmTypedDataVerifyingContract";
6391
+ operator: "in" | "not in";
6392
+ addresses: string[];
6393
+ }>]>, "many">;
6394
+ }, "strip", z.ZodTypeAny, {
6395
+ action: "reject" | "accept";
6396
+ operation: "signEvmTypedData";
6397
+ criteria: ({
6398
+ type: "evmTypedDataField";
6399
+ types: {
6400
+ types: Record<string, {
6401
+ type: string;
6402
+ name: string;
6403
+ }[]>;
6404
+ primaryType: string;
6405
+ };
6406
+ conditions: ({
6407
+ path: string;
6408
+ operator: "in" | "not in";
6409
+ addresses: `0x${string}`[];
6410
+ } | {
6411
+ value: string;
6412
+ path: string;
6413
+ operator: ">" | ">=" | "<" | "<=" | "==";
6414
+ } | {
6415
+ match: string;
6416
+ path: string;
6417
+ })[];
6418
+ } | {
6419
+ type: "evmTypedDataVerifyingContract";
6420
+ operator: "in" | "not in";
6421
+ addresses: `0x${string}`[];
6422
+ })[];
6423
+ }, {
6424
+ action: "reject" | "accept";
6425
+ operation: "signEvmTypedData";
6426
+ criteria: ({
6427
+ type: "evmTypedDataField";
6428
+ types: {
6429
+ types: Record<string, {
6430
+ type: string;
6431
+ name: string;
6432
+ }[]>;
6433
+ primaryType: string;
6434
+ };
6435
+ conditions: ({
6436
+ path: string;
6437
+ operator: "in" | "not in";
6438
+ addresses: string[];
6439
+ } | {
6440
+ value: string;
6441
+ path: string;
6442
+ operator: ">" | ">=" | "<" | "<=" | "==";
6443
+ } | {
6444
+ match: string;
6445
+ path: string;
6446
+ })[];
6447
+ } | {
6448
+ type: "evmTypedDataVerifyingContract";
6449
+ operator: "in" | "not in";
6450
+ addresses: string[];
6451
+ })[];
4948
6452
  }>, z.ZodObject<{
4949
6453
  /**
4950
6454
  * Determines whether matching the rule will cause a request to be rejected or accepted.
@@ -5058,7 +6562,7 @@ export declare const UpdatePolicyBodySchema: z.ZodObject<{
5058
6562
  anonymous?: boolean | undefined;
5059
6563
  }>, z.ZodEffects<z.ZodIntersection<z.ZodObject<{
5060
6564
  constant: z.ZodOptional<z.ZodBoolean>;
5061
- gas: z.ZodOptional /** The type of criterion, must be "solAddress" for Solana address-based rules. */<z.ZodNumber>;
6565
+ gas: z.ZodOptional<z.ZodNumber>;
5062
6566
  payable: z.ZodOptional<z.ZodBoolean>;
5063
6567
  }, "strip", z.ZodTypeAny, {
5064
6568
  payable?: boolean | undefined;
@@ -5500,9 +7004,38 @@ export declare const UpdatePolicyBodySchema: z.ZodObject<{
5500
7004
  action: "reject" | "accept";
5501
7005
  operation: "signEvmMessage";
5502
7006
  criteria: {
5503
- type: "evmMessage";
5504
7007
  match: string;
7008
+ type: "evmMessage";
5505
7009
  }[];
7010
+ } | {
7011
+ action: "reject" | "accept";
7012
+ operation: "signEvmTypedData";
7013
+ criteria: ({
7014
+ type: "evmTypedDataField";
7015
+ types: {
7016
+ types: Record<string, {
7017
+ type: string;
7018
+ name: string;
7019
+ }[]>;
7020
+ primaryType: string;
7021
+ };
7022
+ conditions: ({
7023
+ path: string;
7024
+ operator: "in" | "not in";
7025
+ addresses: `0x${string}`[];
7026
+ } | {
7027
+ value: string;
7028
+ path: string;
7029
+ operator: ">" | ">=" | "<" | "<=" | "==";
7030
+ } | {
7031
+ match: string;
7032
+ path: string;
7033
+ })[];
7034
+ } | {
7035
+ type: "evmTypedDataVerifyingContract";
7036
+ operator: "in" | "not in";
7037
+ addresses: `0x${string}`[];
7038
+ })[];
5506
7039
  } | {
5507
7040
  action: "reject" | "accept";
5508
7041
  operation: "sendEvmTransaction";
@@ -5609,9 +7142,38 @@ export declare const UpdatePolicyBodySchema: z.ZodObject<{
5609
7142
  action: "reject" | "accept";
5610
7143
  operation: "signEvmMessage";
5611
7144
  criteria: {
5612
- type: "evmMessage";
5613
7145
  match: string;
7146
+ type: "evmMessage";
5614
7147
  }[];
7148
+ } | {
7149
+ action: "reject" | "accept";
7150
+ operation: "signEvmTypedData";
7151
+ criteria: ({
7152
+ type: "evmTypedDataField";
7153
+ types: {
7154
+ types: Record<string, {
7155
+ type: string;
7156
+ name: string;
7157
+ }[]>;
7158
+ primaryType: string;
7159
+ };
7160
+ conditions: ({
7161
+ path: string;
7162
+ operator: "in" | "not in";
7163
+ addresses: string[];
7164
+ } | {
7165
+ value: string;
7166
+ path: string;
7167
+ operator: ">" | ">=" | "<" | "<=" | "==";
7168
+ } | {
7169
+ match: string;
7170
+ path: string;
7171
+ })[];
7172
+ } | {
7173
+ type: "evmTypedDataVerifyingContract";
7174
+ operator: "in" | "not in";
7175
+ addresses: string[];
7176
+ })[];
5615
7177
  } | {
5616
7178
  action: "reject" | "accept";
5617
7179
  operation: "sendEvmTransaction";