@openfort/openfort-node 0.7.6 → 0.8.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 (32) hide show
  1. package/CHANGELOG.md +12 -0
  2. package/biome.json +2 -1
  3. package/dist/index.d.mts +4835 -437
  4. package/dist/index.d.ts +4835 -437
  5. package/dist/index.js +971 -188
  6. package/dist/index.js.map +1 -1
  7. package/dist/index.mjs +861 -183
  8. package/dist/index.mjs.map +1 -1
  9. package/examples/README.md +28 -11
  10. package/examples/{policies → fee-sponsorship}/createPolicy.ts +2 -2
  11. package/examples/{policies → fee-sponsorship}/createPolicyRule.ts +3 -3
  12. package/examples/{policies → fee-sponsorship}/disableEnablePolicy.ts +4 -4
  13. package/examples/fee-sponsorship/getPolicy.ts +30 -0
  14. package/examples/fee-sponsorship/listPolicies.ts +17 -0
  15. package/examples/{policies → fee-sponsorship}/listPolicyRules.ts +4 -4
  16. package/examples/fee-sponsorship/updatePolicy.ts +29 -0
  17. package/examples/policies/createAccountPolicy.ts +73 -0
  18. package/examples/policies/createEvmPolicy.ts +149 -0
  19. package/examples/policies/createSolanaPolicy.ts +176 -0
  20. package/examples/policies/createTypedDataPolicy.ts +159 -0
  21. package/examples/policies/deletePolicy.ts +34 -0
  22. package/examples/policies/getPolicy.ts +24 -13
  23. package/examples/policies/listPolicies.ts +19 -2
  24. package/examples/policies/multiRulePolicy.ts +133 -0
  25. package/examples/policies/updatePolicy.ts +64 -16
  26. package/examples/policies/validatePolicy.ts +176 -0
  27. package/examples/transactions/createTransactionIntent.ts +2 -2
  28. package/examples/transactions/estimateGas.ts +2 -2
  29. package/examples/transactions/getTransactionIntent.ts +2 -2
  30. package/openapi.json +2352 -1142
  31. package/package.json +4 -3
  32. package/pnpm-workspace.yaml +2 -0
package/dist/index.js CHANGED
@@ -68,6 +68,19 @@ __export(index_exports, {
68
68
  CreateBackendWalletResponseObject: () => CreateBackendWalletResponseObject,
69
69
  CreateEmbeddedRequestAccountType: () => CreateEmbeddedRequestAccountType,
70
70
  CreateEmbeddedRequestChainType: () => CreateEmbeddedRequestChainType,
71
+ CreatePolicyBodySchema: () => CreatePolicyBodySchema,
72
+ CreatePolicyV2RequestScope: () => CreatePolicyV2RequestScope,
73
+ CreatePolicyV2RuleRequestAction: () => CreatePolicyV2RuleRequestAction,
74
+ CriteriaOperator: () => CriteriaOperator,
75
+ CriteriaOperatorEQUAL: () => CriteriaOperatorEQUAL,
76
+ CriteriaOperatorGREATERTHAN: () => CriteriaOperatorGREATERTHAN,
77
+ CriteriaOperatorGREATERTHANOREQUAL: () => CriteriaOperatorGREATERTHANOREQUAL,
78
+ CriteriaOperatorIN: () => CriteriaOperatorIN,
79
+ CriteriaOperatorLESSTHAN: () => CriteriaOperatorLESSTHAN,
80
+ CriteriaOperatorLESSTHANOREQUAL: () => CriteriaOperatorLESSTHANOREQUAL,
81
+ CriteriaOperatorMATCH: () => CriteriaOperatorMATCH,
82
+ CriteriaOperatorNOTIN: () => CriteriaOperatorNOTIN,
83
+ CriteriaType: () => CriteriaType,
71
84
  Currency: () => Currency,
72
85
  DeleteBackendWalletResponseObject: () => DeleteBackendWalletResponseObject,
73
86
  DeveloperAccountResponseExpandable: () => DeveloperAccountResponseExpandable,
@@ -87,6 +100,8 @@ __export(index_exports, {
87
100
  EntityTypePLAYER: () => EntityTypePLAYER,
88
101
  EntityTypePOLICY: () => EntityTypePOLICY,
89
102
  EntityTypePOLICYRULE: () => EntityTypePOLICYRULE,
103
+ EntityTypePOLICYV2: () => EntityTypePOLICYV2,
104
+ EntityTypePOLICYV2RULE: () => EntityTypePOLICYV2RULE,
90
105
  EntityTypePROJECT: () => EntityTypePROJECT,
91
106
  EntityTypeREADCONTRACT: () => EntityTypeREADCONTRACT,
92
107
  EntityTypeSESSION: () => EntityTypeSESSION,
@@ -98,7 +113,43 @@ __export(index_exports, {
98
113
  EntityTypeUSER: () => EntityTypeUSER,
99
114
  EntityTypeWALLET: () => EntityTypeWALLET,
100
115
  ErrorTypeINVALIDREQUESTERROR: () => ErrorTypeINVALIDREQUESTERROR,
116
+ EthValueCriterionOperator: () => EthValueCriterionOperator,
117
+ EthValueCriterionRequestOperator: () => EthValueCriterionRequestOperator,
118
+ EthValueCriterionRequestType: () => EthValueCriterionRequestType,
119
+ EthValueCriterionSchema: () => EthValueCriterionSchema,
120
+ EvaluatePolicyV2ResponseObject: () => EvaluatePolicyV2ResponseObject,
121
+ EvmAddressCriterionOperator: () => EvmAddressCriterionOperator,
122
+ EvmAddressCriterionRequestOperator: () => EvmAddressCriterionRequestOperator,
123
+ EvmAddressCriterionRequestType: () => EvmAddressCriterionRequestType,
124
+ EvmAddressCriterionSchema: () => EvmAddressCriterionSchema,
101
125
  EvmClient: () => EvmClient,
126
+ EvmCriteriaType: () => EvmCriteriaType,
127
+ EvmCriteriaTypeETHVALUE: () => EvmCriteriaTypeETHVALUE,
128
+ EvmCriteriaTypeEVMADDRESS: () => EvmCriteriaTypeEVMADDRESS,
129
+ EvmCriteriaTypeEVMDATA: () => EvmCriteriaTypeEVMDATA,
130
+ EvmCriteriaTypeEVMMESSAGE: () => EvmCriteriaTypeEVMMESSAGE,
131
+ EvmCriteriaTypeEVMNETWORK: () => EvmCriteriaTypeEVMNETWORK,
132
+ EvmCriteriaTypeEVMTYPEDDATAFIELD: () => EvmCriteriaTypeEVMTYPEDDATAFIELD,
133
+ EvmCriteriaTypeEVMTYPEDDATAVERIFYINGCONTRACT: () => EvmCriteriaTypeEVMTYPEDDATAVERIFYINGCONTRACT,
134
+ EvmCriteriaTypeNETUSDCHANGE: () => EvmCriteriaTypeNETUSDCHANGE,
135
+ EvmDataCriterionRequestOperator: () => EvmDataCriterionRequestOperator,
136
+ EvmDataCriterionRequestType: () => EvmDataCriterionRequestType,
137
+ EvmDataCriterionSchema: () => EvmDataCriterionSchema,
138
+ EvmMessageCriterionRequestOperator: () => EvmMessageCriterionRequestOperator,
139
+ EvmMessageCriterionRequestType: () => EvmMessageCriterionRequestType,
140
+ EvmMessageCriterionSchema: () => EvmMessageCriterionSchema,
141
+ EvmNetworkCriterionOperator: () => EvmNetworkCriterionOperator,
142
+ EvmNetworkCriterionRequestOperator: () => EvmNetworkCriterionRequestOperator,
143
+ EvmNetworkCriterionRequestType: () => EvmNetworkCriterionRequestType,
144
+ EvmNetworkCriterionSchema: () => EvmNetworkCriterionSchema,
145
+ EvmTypedDataFieldCriterionOperator: () => EvmTypedDataFieldCriterionOperator,
146
+ EvmTypedDataFieldCriterionRequestOperator: () => EvmTypedDataFieldCriterionRequestOperator,
147
+ EvmTypedDataFieldCriterionRequestType: () => EvmTypedDataFieldCriterionRequestType,
148
+ EvmTypedDataFieldCriterionSchema: () => EvmTypedDataFieldCriterionSchema,
149
+ EvmTypedDataVerifyingContractCriterionOperator: () => EvmTypedDataVerifyingContractCriterionOperator,
150
+ EvmTypedDataVerifyingContractCriterionRequestOperator: () => EvmTypedDataVerifyingContractCriterionRequestOperator,
151
+ EvmTypedDataVerifyingContractCriterionRequestType: () => EvmTypedDataVerifyingContractCriterionRequestType,
152
+ EvmTypedDataVerifyingContractCriterionSchema: () => EvmTypedDataVerifyingContractCriterionSchema,
102
153
  ExportPrivateKeyResponseObject: () => ExportPrivateKeyResponseObject,
103
154
  GetAccountsV2AccountType: () => GetAccountsV2AccountType,
104
155
  GetAccountsV2ChainType: () => GetAccountsV2ChainType,
@@ -115,9 +166,17 @@ __export(index_exports, {
115
166
  JsonRpcRequestJsonrpc: () => JsonRpcRequestJsonrpc,
116
167
  JsonRpcSuccessResponseAnyJsonrpc: () => JsonRpcSuccessResponseAnyJsonrpc,
117
168
  ListBackendWalletsChainType: () => ListBackendWalletsChainType,
169
+ ListPoliciesScope: () => ListPoliciesScope,
170
+ MintAddressCriterionOperator: () => MintAddressCriterionOperator,
171
+ MintAddressCriterionRequestOperator: () => MintAddressCriterionRequestOperator,
172
+ MintAddressCriterionRequestType: () => MintAddressCriterionRequestType,
173
+ MintAddressCriterionSchema: () => MintAddressCriterionSchema,
118
174
  MissingAPIKeyError: () => MissingAPIKeyError,
119
175
  MissingPublishableKeyError: () => MissingPublishableKeyError,
120
176
  MissingWalletSecretError: () => MissingWalletSecretError,
177
+ NetUSDChangeCriterionOperator: () => NetUSDChangeCriterionOperator,
178
+ NetUSDChangeCriterionRequestOperator: () => NetUSDChangeCriterionRequestOperator,
179
+ NetUSDChangeCriterionRequestType: () => NetUSDChangeCriterionRequestType,
121
180
  NetworkError: () => NetworkError,
122
181
  NextActionType: () => NextActionType,
123
182
  OAuthProvider: () => OAuthProvider,
@@ -142,25 +201,77 @@ __export(index_exports, {
142
201
  PolicyRuleTypeACCOUNT: () => PolicyRuleTypeACCOUNT,
143
202
  PolicyRuleTypeCONTRACT: () => PolicyRuleTypeCONTRACT,
144
203
  PolicyRuleTypeRATELIMIT: () => PolicyRuleTypeRATELIMIT,
204
+ PolicyV2Action: () => PolicyV2Action,
205
+ PolicyV2ListQueriesScope: () => PolicyV2ListQueriesScope,
206
+ PolicyV2Scope: () => PolicyV2Scope,
145
207
  PregenerateAccountResponseCustody: () => PregenerateAccountResponseCustody,
146
208
  PregenerateUserRequestV2AccountType: () => PregenerateUserRequestV2AccountType,
147
209
  PregenerateUserRequestV2ChainType: () => PregenerateUserRequestV2ChainType,
148
210
  PrismaSortOrder: () => PrismaSortOrder,
149
211
  PrivateKeyPolicy: () => PrivateKeyPolicy,
212
+ ProgramIdCriterionOperator: () => ProgramIdCriterionOperator,
213
+ ProgramIdCriterionRequestOperator: () => ProgramIdCriterionRequestOperator,
214
+ ProgramIdCriterionRequestType: () => ProgramIdCriterionRequestType,
215
+ ProgramIdCriterionSchema: () => ProgramIdCriterionSchema,
150
216
  ProjectStatsRequestTimeFrame: () => ProjectStatsRequestTimeFrame,
151
217
  RegisterWalletSecretResponseObject: () => RegisterWalletSecretResponseObject,
152
218
  ResponseTypeLIST: () => ResponseTypeLIST,
153
219
  RevokeWalletSecretResponseObject: () => RevokeWalletSecretResponseObject,
154
220
  RotateWalletSecretResponseObject: () => RotateWalletSecretResponseObject,
221
+ RuleSchema: () => RuleSchema,
222
+ SendEvmTransactionRuleSchema: () => SendEvmTransactionRuleSchema,
223
+ SendSolTransactionRuleSchema: () => SendSolTransactionRuleSchema,
155
224
  SessionResponseExpandable: () => SessionResponseExpandable,
156
225
  ShieldAuthProvider: () => import_shield_js2.ShieldAuthProvider,
226
+ SignEvmHashRuleSchema: () => SignEvmHashRuleSchema,
227
+ SignEvmMessageRuleSchema: () => SignEvmMessageRuleSchema,
228
+ SignEvmTransactionRuleSchema: () => SignEvmTransactionRuleSchema,
229
+ SignEvmTypedDataRuleSchema: () => SignEvmTypedDataRuleSchema,
157
230
  SignResponseObject: () => SignResponseObject,
231
+ SignSolMessageRuleSchema: () => SignSolMessageRuleSchema,
232
+ SignSolTransactionRuleSchema: () => SignSolTransactionRuleSchema,
158
233
  SmsProviderMESSAGEBIRD: () => SmsProviderMESSAGEBIRD,
159
234
  SmsProviderSMSAPI: () => SmsProviderSMSAPI,
160
235
  SmsProviderTWILIO: () => SmsProviderTWILIO,
161
236
  SmsProviderTXTLOCAL: () => SmsProviderTXTLOCAL,
162
237
  SmsProviderVONAGE: () => SmsProviderVONAGE,
238
+ SolAddressCriterionOperator: () => SolAddressCriterionOperator,
239
+ SolAddressCriterionRequestOperator: () => SolAddressCriterionRequestOperator,
240
+ SolAddressCriterionRequestType: () => SolAddressCriterionRequestType,
241
+ SolAddressCriterionSchema: () => SolAddressCriterionSchema,
242
+ SolDataCriterionRequestOperator: () => SolDataCriterionRequestOperator,
243
+ SolDataCriterionRequestType: () => SolDataCriterionRequestType,
244
+ SolDataCriterionSchema: () => SolDataCriterionSchema,
245
+ SolMessageCriterionRequestOperator: () => SolMessageCriterionRequestOperator,
246
+ SolMessageCriterionRequestType: () => SolMessageCriterionRequestType,
247
+ SolMessageCriterionSchema: () => SolMessageCriterionSchema,
248
+ SolNetworkCriterionOperator: () => SolNetworkCriterionOperator,
249
+ SolNetworkCriterionRequestOperator: () => SolNetworkCriterionRequestOperator,
250
+ SolNetworkCriterionRequestType: () => SolNetworkCriterionRequestType,
251
+ SolNetworkCriterionSchema: () => SolNetworkCriterionSchema,
252
+ SolValueCriterionOperator: () => SolValueCriterionOperator,
253
+ SolValueCriterionRequestOperator: () => SolValueCriterionRequestOperator,
254
+ SolValueCriterionRequestType: () => SolValueCriterionRequestType,
255
+ SolValueCriterionSchema: () => SolValueCriterionSchema,
163
256
  SolanaClient: () => SolanaClient,
257
+ SolanaCriteriaType: () => SolanaCriteriaType,
258
+ SolanaCriteriaTypeMINTADDRESS: () => SolanaCriteriaTypeMINTADDRESS,
259
+ SolanaCriteriaTypePROGRAMID: () => SolanaCriteriaTypePROGRAMID,
260
+ SolanaCriteriaTypeSOLADDRESS: () => SolanaCriteriaTypeSOLADDRESS,
261
+ SolanaCriteriaTypeSOLDATA: () => SolanaCriteriaTypeSOLDATA,
262
+ SolanaCriteriaTypeSOLMESSAGE: () => SolanaCriteriaTypeSOLMESSAGE,
263
+ SolanaCriteriaTypeSOLNETWORK: () => SolanaCriteriaTypeSOLNETWORK,
264
+ SolanaCriteriaTypeSOLVALUE: () => SolanaCriteriaTypeSOLVALUE,
265
+ SolanaCriteriaTypeSPLADDRESS: () => SolanaCriteriaTypeSPLADDRESS,
266
+ SolanaCriteriaTypeSPLVALUE: () => SolanaCriteriaTypeSPLVALUE,
267
+ SplAddressCriterionOperator: () => SplAddressCriterionOperator,
268
+ SplAddressCriterionRequestOperator: () => SplAddressCriterionRequestOperator,
269
+ SplAddressCriterionRequestType: () => SplAddressCriterionRequestType,
270
+ SplAddressCriterionSchema: () => SplAddressCriterionSchema,
271
+ SplValueCriterionOperator: () => SplValueCriterionOperator,
272
+ SplValueCriterionRequestOperator: () => SplValueCriterionRequestOperator,
273
+ SplValueCriterionRequestType: () => SplValueCriterionRequestType,
274
+ SplValueCriterionSchema: () => SplValueCriterionSchema,
164
275
  SponsorSchema: () => SponsorSchema,
165
276
  SponsorSchemaCHARGECUSTOMTOKENS: () => SponsorSchemaCHARGECUSTOMTOKENS,
166
277
  SponsorSchemaFIXEDRATE: () => SponsorSchemaFIXEDRATE,
@@ -182,6 +293,7 @@ __export(index_exports, {
182
293
  TransactionIntentResponseExpandable: () => TransactionIntentResponseExpandable,
183
294
  TransactionStatus: () => TransactionStatus,
184
295
  UnknownError: () => UnknownError,
296
+ UpdatePolicyBodySchema: () => UpdatePolicyBodySchema,
185
297
  UserInputValidationError: () => UserInputValidationError,
186
298
  UserProjectCreateRequestRole: () => UserProjectCreateRequestRole,
187
299
  UserProjectRole: () => UserProjectRole,
@@ -195,8 +307,6 @@ __export(index_exports, {
195
307
  authorize: () => authorize,
196
308
  callbackOAuth: () => callbackOAuth,
197
309
  cancelTransferAccountOwnership: () => cancelTransferAccountOwnership,
198
- cancelTransferOwnership: () => cancelTransferOwnership,
199
- completeRecovery: () => completeRecovery,
200
310
  configure: () => configure,
201
311
  create: () => create,
202
312
  createAccount: () => createAccount,
@@ -213,6 +323,7 @@ __export(index_exports, {
213
323
  createPlayer: () => createPlayer,
214
324
  createPolicy: () => createPolicy,
215
325
  createPolicyRule: () => createPolicyRule,
326
+ createPolicyV2: () => createPolicyV2,
216
327
  createPolicyWithdrawal: () => createPolicyWithdrawal,
217
328
  createSession: () => createSession,
218
329
  createSubscription: () => createSubscription,
@@ -231,16 +342,17 @@ __export(index_exports, {
231
342
  deletePlayer: () => deletePlayer,
232
343
  deletePolicy: () => deletePolicy,
233
344
  deletePolicyRule: () => deletePolicyRule,
345
+ deletePolicyV2: () => deletePolicyV2,
234
346
  deleteSubscription: () => deleteSubscription,
235
347
  deleteTrigger: () => deleteTrigger,
236
348
  deleteUser: () => deleteUser,
237
- deployAccount: () => deployAccount,
238
349
  deprecatedCallbackOAuth: () => deprecatedCallbackOAuth,
239
350
  disableAccount: () => disableAccount,
240
351
  disablePolicy: () => disablePolicy,
241
352
  enablePolicy: () => enablePolicy,
242
353
  encryptForImport: () => encryptForImport,
243
354
  estimateTransactionIntentCost: () => estimateTransactionIntentCost,
355
+ evaluatePolicyV2: () => evaluatePolicyV2,
244
356
  exportPrivateKey: () => exportPrivateKey,
245
357
  generateRSAKeyPair: () => generateRSAKeyPair,
246
358
  getAccount: () => getAccount,
@@ -273,6 +385,7 @@ __export(index_exports, {
273
385
  getPolicyReportTransactionIntents: () => getPolicyReportTransactionIntents,
274
386
  getPolicyRules: () => getPolicyRules,
275
387
  getPolicyTotalGasUsage: () => getPolicyTotalGasUsage,
388
+ getPolicyV2: () => getPolicyV2,
276
389
  getProjectLogs: () => getProjectLogs,
277
390
  getSession: () => getSession,
278
391
  getSignerIdByAddress: () => getSignerIdByAddress,
@@ -302,6 +415,7 @@ __export(index_exports, {
302
415
  listForwarderContracts: () => listForwarderContracts,
303
416
  listOAuthConfig: () => listOAuthConfig,
304
417
  listPaymasters: () => listPaymasters,
418
+ listPolicies: () => listPolicies,
305
419
  listSubscriptionLogs: () => listSubscriptionLogs,
306
420
  loginEmailPassword: () => loginEmailPassword,
307
421
  loginOIDC: () => loginOIDC,
@@ -320,20 +434,16 @@ __export(index_exports, {
320
434
  requestEmailVerification: () => requestEmailVerification,
321
435
  requestResetPassword: () => requestResetPassword,
322
436
  requestTransferAccountOwnership: () => requestTransferAccountOwnership,
323
- requestTransferOwnership: () => requestTransferOwnership,
324
437
  resetPassword: () => resetPassword,
325
438
  revokeSession: () => revokeSession,
326
439
  revokeWalletSecret: () => revokeWalletSecret,
327
440
  rotateWalletSecret: () => rotateWalletSecret,
328
441
  sign: () => sign,
329
- signPayload: () => signPayload,
330
442
  signPayloadDeveloperAccount: () => signPayloadDeveloperAccount,
331
443
  signature: () => signature,
332
444
  signatureSession: () => signatureSession,
333
445
  signupEmailPassword: () => signupEmailPassword,
334
- startRecovery: () => startRecovery,
335
446
  switchChainV2: () => switchChainV2,
336
- syncAccount: () => syncAccount,
337
447
  testTrigger: () => testTrigger,
338
448
  thirdParty: () => thirdParty,
339
449
  thirdPartyV2: () => thirdPartyV2,
@@ -349,6 +459,7 @@ __export(index_exports, {
349
459
  updatePlayer: () => updatePlayer,
350
460
  updatePolicy: () => updatePolicy,
351
461
  updatePolicyRule: () => updatePolicyRule,
462
+ updatePolicyV2: () => updatePolicyV2,
352
463
  verifyAuthToken: () => verifyAuthToken,
353
464
  verifyEmail: () => verifyEmail,
354
465
  verifyOAuthToken: () => verifyOAuthToken
@@ -719,7 +830,7 @@ function requiresWalletAuth(requestMethod, requestPath) {
719
830
  }
720
831
 
721
832
  // src/version.ts
722
- var VERSION = "0.7.6";
833
+ var VERSION = "0.8.0";
723
834
  var PACKAGE = "@openfort/openfort-node";
724
835
 
725
836
  // src/openapi-client/openfortApiClient.ts
@@ -1104,81 +1215,6 @@ var disableAccount = (id, options) => {
1104
1215
  options
1105
1216
  );
1106
1217
  };
1107
- var requestTransferOwnership = (id, transferOwnershipRequest, options) => {
1108
- return openfortApiClient(
1109
- {
1110
- url: `/v1/accounts/${id}/request_transfer_ownership`,
1111
- method: "POST",
1112
- headers: { "Content-Type": "application/json" },
1113
- data: transferOwnershipRequest
1114
- },
1115
- options
1116
- );
1117
- };
1118
- var cancelTransferOwnership = (id, cancelTransferOwnershipRequest, options) => {
1119
- return openfortApiClient(
1120
- {
1121
- url: `/v1/accounts/${id}/cancel_transfer_ownership`,
1122
- method: "POST",
1123
- headers: { "Content-Type": "application/json" },
1124
- data: cancelTransferOwnershipRequest
1125
- },
1126
- options
1127
- );
1128
- };
1129
- var signPayload = (id, signPayloadRequest, options) => {
1130
- return openfortApiClient(
1131
- {
1132
- url: `/v1/accounts/${id}/sign_payload`,
1133
- method: "POST",
1134
- headers: { "Content-Type": "application/json" },
1135
- data: signPayloadRequest
1136
- },
1137
- options
1138
- );
1139
- };
1140
- var syncAccount = (id, options) => {
1141
- return openfortApiClient(
1142
- {
1143
- url: `/v1/accounts/${id}/sync`,
1144
- method: "POST"
1145
- },
1146
- options
1147
- );
1148
- };
1149
- var deployAccount = (id, deployRequest, options) => {
1150
- return openfortApiClient(
1151
- {
1152
- url: `/v1/accounts/${id}/deploy`,
1153
- method: "POST",
1154
- headers: { "Content-Type": "application/json" },
1155
- data: deployRequest
1156
- },
1157
- options
1158
- );
1159
- };
1160
- var startRecovery = (id, startRecoveryRequest, options) => {
1161
- return openfortApiClient(
1162
- {
1163
- url: `/v1/accounts/${id}/start_recovery`,
1164
- method: "POST",
1165
- headers: { "Content-Type": "application/json" },
1166
- data: startRecoveryRequest
1167
- },
1168
- options
1169
- );
1170
- };
1171
- var completeRecovery = (id, completeRecoveryRequest, options) => {
1172
- return openfortApiClient(
1173
- {
1174
- url: `/v1/accounts/${id}/complete_recovery`,
1175
- method: "POST",
1176
- headers: { "Content-Type": "application/json" },
1177
- data: completeRecoveryRequest
1178
- },
1179
- options
1180
- );
1181
- };
1182
1218
 
1183
1219
  // src/openapi-client/generated/accs-v2/accs-v2.ts
1184
1220
  var getAccountsV2 = (params, options) => {
@@ -2613,7 +2649,11 @@ var APITopic = {
2613
2649
  balanceproject: "balance.project",
2614
2650
  balancecontract: "balance.contract",
2615
2651
  balancedev_account: "balance.dev_account",
2616
- test: "test"
2652
+ test: "test",
2653
+ usercreated: "user.created",
2654
+ userupdated: "user.updated",
2655
+ userdeleted: "user.deleted",
2656
+ accountcreated: "account.created"
2617
2657
  };
2618
2658
  var APITriggerType = {
2619
2659
  webhook: "webhook",
@@ -2774,6 +2814,285 @@ var PregenerateUserRequestV2ChainType = {
2774
2814
  EVM: "EVM",
2775
2815
  SVM: "SVM"
2776
2816
  };
2817
+ var PolicyV2Scope = {
2818
+ project: "project",
2819
+ account: "account"
2820
+ };
2821
+ var PolicyV2Action = {
2822
+ accept: "accept",
2823
+ reject: "reject"
2824
+ };
2825
+ var EvmCriteriaTypeEVMADDRESS = {
2826
+ evmAddress: "evmAddress"
2827
+ };
2828
+ var CriteriaOperatorIN = {
2829
+ in: "in"
2830
+ };
2831
+ var CriteriaOperatorNOTIN = {
2832
+ not_in: "not in"
2833
+ };
2834
+ var EvmCriteriaType = {
2835
+ evmAddress: "evmAddress",
2836
+ ethValue: "ethValue",
2837
+ evmNetwork: "evmNetwork",
2838
+ evmMessage: "evmMessage",
2839
+ evmData: "evmData",
2840
+ evmTypedDataVerifyingContract: "evmTypedDataVerifyingContract",
2841
+ evmTypedDataField: "evmTypedDataField",
2842
+ netUSDChange: "netUSDChange"
2843
+ };
2844
+ var SolanaCriteriaType = {
2845
+ solAddress: "solAddress",
2846
+ solValue: "solValue",
2847
+ splAddress: "splAddress",
2848
+ splValue: "splValue",
2849
+ mintAddress: "mintAddress",
2850
+ solData: "solData",
2851
+ programId: "programId",
2852
+ solNetwork: "solNetwork",
2853
+ solMessage: "solMessage"
2854
+ };
2855
+ var CriteriaType = { ...EvmCriteriaType, ...SolanaCriteriaType };
2856
+ var CriteriaOperator = {
2857
+ in: "in",
2858
+ not_in: "not in",
2859
+ "<": "<",
2860
+ "<=": "<=",
2861
+ ">": ">",
2862
+ ">=": ">=",
2863
+ "==": "==",
2864
+ match: "match"
2865
+ };
2866
+ var EvmAddressCriterionOperator = { ...CriteriaOperatorIN, ...CriteriaOperatorNOTIN };
2867
+ var EvmCriteriaTypeETHVALUE = {
2868
+ ethValue: "ethValue"
2869
+ };
2870
+ var CriteriaOperatorLESSTHANOREQUAL = {
2871
+ "<=": "<="
2872
+ };
2873
+ var CriteriaOperatorGREATERTHANOREQUAL = {
2874
+ ">=": ">="
2875
+ };
2876
+ var CriteriaOperatorLESSTHAN = {
2877
+ "<": "<"
2878
+ };
2879
+ var CriteriaOperatorGREATERTHAN = {
2880
+ ">": ">"
2881
+ };
2882
+ var EthValueCriterionOperator = { ...CriteriaOperatorLESSTHANOREQUAL, ...CriteriaOperatorGREATERTHANOREQUAL, ...CriteriaOperatorLESSTHAN, ...CriteriaOperatorGREATERTHAN };
2883
+ var EvmCriteriaTypeEVMNETWORK = {
2884
+ evmNetwork: "evmNetwork"
2885
+ };
2886
+ var EvmNetworkCriterionOperator = { ...CriteriaOperatorIN, ...CriteriaOperatorNOTIN };
2887
+ var EvmCriteriaTypeEVMMESSAGE = {
2888
+ evmMessage: "evmMessage"
2889
+ };
2890
+ var CriteriaOperatorMATCH = {
2891
+ match: "match"
2892
+ };
2893
+ var EvmCriteriaTypeEVMDATA = {
2894
+ evmData: "evmData"
2895
+ };
2896
+ var EvmCriteriaTypeEVMTYPEDDATAVERIFYINGCONTRACT = {
2897
+ evmTypedDataVerifyingContract: "evmTypedDataVerifyingContract"
2898
+ };
2899
+ var EvmTypedDataVerifyingContractCriterionOperator = { ...CriteriaOperatorIN, ...CriteriaOperatorNOTIN };
2900
+ var EvmCriteriaTypeEVMTYPEDDATAFIELD = {
2901
+ evmTypedDataField: "evmTypedDataField"
2902
+ };
2903
+ var EvmTypedDataFieldCriterionOperator = { ...CriteriaOperatorIN, ...CriteriaOperatorLESSTHANOREQUAL, ...CriteriaOperatorMATCH };
2904
+ var EvmCriteriaTypeNETUSDCHANGE = {
2905
+ netUSDChange: "netUSDChange"
2906
+ };
2907
+ var NetUSDChangeCriterionOperator = { ...CriteriaOperatorLESSTHANOREQUAL, ...CriteriaOperatorGREATERTHANOREQUAL };
2908
+ var SolanaCriteriaTypeSOLADDRESS = {
2909
+ solAddress: "solAddress"
2910
+ };
2911
+ var SolAddressCriterionOperator = { ...CriteriaOperatorIN, ...CriteriaOperatorNOTIN };
2912
+ var SolanaCriteriaTypeSOLVALUE = {
2913
+ solValue: "solValue"
2914
+ };
2915
+ var SolValueCriterionOperator = { ...CriteriaOperatorLESSTHANOREQUAL, ...CriteriaOperatorGREATERTHANOREQUAL };
2916
+ var SolanaCriteriaTypeSPLADDRESS = {
2917
+ splAddress: "splAddress"
2918
+ };
2919
+ var SplAddressCriterionOperator = { ...CriteriaOperatorIN, ...CriteriaOperatorNOTIN };
2920
+ var SolanaCriteriaTypeSPLVALUE = {
2921
+ splValue: "splValue"
2922
+ };
2923
+ var SplValueCriterionOperator = { ...CriteriaOperatorLESSTHANOREQUAL, ...CriteriaOperatorGREATERTHANOREQUAL };
2924
+ var SolanaCriteriaTypeMINTADDRESS = {
2925
+ mintAddress: "mintAddress"
2926
+ };
2927
+ var CriteriaOperatorEQUAL = {
2928
+ "==": "=="
2929
+ };
2930
+ var MintAddressCriterionOperator = { ...CriteriaOperatorEQUAL, ...CriteriaOperatorIN };
2931
+ var SolanaCriteriaTypeSOLDATA = {
2932
+ solData: "solData"
2933
+ };
2934
+ var SolanaCriteriaTypePROGRAMID = {
2935
+ programId: "programId"
2936
+ };
2937
+ var ProgramIdCriterionOperator = { ...CriteriaOperatorIN, ...CriteriaOperatorNOTIN };
2938
+ var SolanaCriteriaTypeSOLNETWORK = {
2939
+ solNetwork: "solNetwork"
2940
+ };
2941
+ var SolNetworkCriterionOperator = { ...CriteriaOperatorIN, ...CriteriaOperatorNOTIN };
2942
+ var SolanaCriteriaTypeSOLMESSAGE = {
2943
+ solMessage: "solMessage"
2944
+ };
2945
+ var EntityTypePOLICYV2RULE = {
2946
+ policyV2Rule: "policyV2Rule"
2947
+ };
2948
+ var EntityTypePOLICYV2 = {
2949
+ policyV2: "policyV2"
2950
+ };
2951
+ var PolicyV2ListQueriesScope = {
2952
+ project: "project",
2953
+ account: "account"
2954
+ };
2955
+ var EvmAddressCriterionRequestType = {
2956
+ evmAddress: "evmAddress"
2957
+ };
2958
+ var EvmAddressCriterionRequestOperator = {
2959
+ in: "in",
2960
+ not_in: "not in"
2961
+ };
2962
+ var EthValueCriterionRequestType = {
2963
+ ethValue: "ethValue"
2964
+ };
2965
+ var EthValueCriterionRequestOperator = {
2966
+ "<=": "<=",
2967
+ ">=": ">=",
2968
+ "<": "<",
2969
+ ">": ">"
2970
+ };
2971
+ var EvmNetworkCriterionRequestType = {
2972
+ evmNetwork: "evmNetwork"
2973
+ };
2974
+ var EvmNetworkCriterionRequestOperator = {
2975
+ in: "in",
2976
+ not_in: "not in"
2977
+ };
2978
+ var EvmMessageCriterionRequestType = {
2979
+ evmMessage: "evmMessage"
2980
+ };
2981
+ var EvmMessageCriterionRequestOperator = {
2982
+ match: "match"
2983
+ };
2984
+ var EvmDataCriterionRequestType = {
2985
+ evmData: "evmData"
2986
+ };
2987
+ var EvmDataCriterionRequestOperator = {
2988
+ in: "in",
2989
+ not_in: "not in",
2990
+ "<": "<",
2991
+ "<=": "<=",
2992
+ ">": ">",
2993
+ ">=": ">=",
2994
+ "==": "==",
2995
+ match: "match"
2996
+ };
2997
+ var EvmTypedDataVerifyingContractCriterionRequestType = {
2998
+ evmTypedDataVerifyingContract: "evmTypedDataVerifyingContract"
2999
+ };
3000
+ var EvmTypedDataVerifyingContractCriterionRequestOperator = {
3001
+ in: "in",
3002
+ not_in: "not in"
3003
+ };
3004
+ var EvmTypedDataFieldCriterionRequestType = {
3005
+ evmTypedDataField: "evmTypedDataField"
3006
+ };
3007
+ var EvmTypedDataFieldCriterionRequestOperator = {
3008
+ in: "in",
3009
+ "<=": "<=",
3010
+ match: "match"
3011
+ };
3012
+ var NetUSDChangeCriterionRequestType = {
3013
+ netUSDChange: "netUSDChange"
3014
+ };
3015
+ var NetUSDChangeCriterionRequestOperator = {
3016
+ "<=": "<=",
3017
+ ">=": ">="
3018
+ };
3019
+ var SolAddressCriterionRequestType = {
3020
+ solAddress: "solAddress"
3021
+ };
3022
+ var SolAddressCriterionRequestOperator = {
3023
+ in: "in",
3024
+ not_in: "not in"
3025
+ };
3026
+ var SolValueCriterionRequestType = {
3027
+ solValue: "solValue"
3028
+ };
3029
+ var SolValueCriterionRequestOperator = {
3030
+ "<=": "<=",
3031
+ ">=": ">="
3032
+ };
3033
+ var SplAddressCriterionRequestType = {
3034
+ splAddress: "splAddress"
3035
+ };
3036
+ var SplAddressCriterionRequestOperator = {
3037
+ in: "in",
3038
+ not_in: "not in"
3039
+ };
3040
+ var SplValueCriterionRequestType = {
3041
+ splValue: "splValue"
3042
+ };
3043
+ var SplValueCriterionRequestOperator = {
3044
+ "<=": "<=",
3045
+ ">=": ">="
3046
+ };
3047
+ var MintAddressCriterionRequestType = {
3048
+ mintAddress: "mintAddress"
3049
+ };
3050
+ var MintAddressCriterionRequestOperator = {
3051
+ "==": "==",
3052
+ in: "in"
3053
+ };
3054
+ var SolDataCriterionRequestType = {
3055
+ solData: "solData"
3056
+ };
3057
+ var SolDataCriterionRequestOperator = {
3058
+ in: "in",
3059
+ not_in: "not in",
3060
+ "<=": "<=",
3061
+ ">=": ">=",
3062
+ "==": "==",
3063
+ match: "match"
3064
+ };
3065
+ var ProgramIdCriterionRequestType = {
3066
+ programId: "programId"
3067
+ };
3068
+ var ProgramIdCriterionRequestOperator = {
3069
+ in: "in",
3070
+ not_in: "not in"
3071
+ };
3072
+ var SolNetworkCriterionRequestType = {
3073
+ solNetwork: "solNetwork"
3074
+ };
3075
+ var SolNetworkCriterionRequestOperator = {
3076
+ in: "in",
3077
+ not_in: "not in"
3078
+ };
3079
+ var SolMessageCriterionRequestType = {
3080
+ solMessage: "solMessage"
3081
+ };
3082
+ var SolMessageCriterionRequestOperator = {
3083
+ match: "match"
3084
+ };
3085
+ var CreatePolicyV2RuleRequestAction = {
3086
+ accept: "accept",
3087
+ reject: "reject"
3088
+ };
3089
+ var CreatePolicyV2RequestScope = {
3090
+ project: "project",
3091
+ account: "account"
3092
+ };
3093
+ var EvaluatePolicyV2ResponseObject = {
3094
+ policy_evaluation: "policy_evaluation"
3095
+ };
2777
3096
  var CreateEmbeddedRequestAccountType = {
2778
3097
  Externally_Owned_Account: "Externally Owned Account",
2779
3098
  Smart_Account: "Smart Account",
@@ -3055,6 +3374,10 @@ var AuthenticationType = {
3055
3374
  var GetPolicyRulesExpandItem = {
3056
3375
  contract: "contract"
3057
3376
  };
3377
+ var ListPoliciesScope = {
3378
+ project: "project",
3379
+ account: "account"
3380
+ };
3058
3381
  var ListBackendWalletsChainType = {
3059
3382
  EVM: "EVM",
3060
3383
  SVM: "SVM"
@@ -3310,6 +3633,67 @@ var createPolicyWithdrawal = (id, withdrawalPolicyRequest, options) => {
3310
3633
  options
3311
3634
  );
3312
3635
  };
3636
+ var listPolicies = (params, options) => {
3637
+ return openfortApiClient(
3638
+ {
3639
+ url: `/v2/policies`,
3640
+ method: "GET",
3641
+ params
3642
+ },
3643
+ options
3644
+ );
3645
+ };
3646
+ var createPolicyV2 = (createPolicyV2Request, options) => {
3647
+ return openfortApiClient(
3648
+ {
3649
+ url: `/v2/policies`,
3650
+ method: "POST",
3651
+ headers: { "Content-Type": "application/json" },
3652
+ data: createPolicyV2Request
3653
+ },
3654
+ options
3655
+ );
3656
+ };
3657
+ var getPolicyV2 = (policyId, options) => {
3658
+ return openfortApiClient(
3659
+ {
3660
+ url: `/v2/policies/${policyId}`,
3661
+ method: "GET"
3662
+ },
3663
+ options
3664
+ );
3665
+ };
3666
+ var updatePolicyV2 = (policyId, updatePolicyV2Request, options) => {
3667
+ return openfortApiClient(
3668
+ {
3669
+ url: `/v2/policies/${policyId}`,
3670
+ method: "POST",
3671
+ headers: { "Content-Type": "application/json" },
3672
+ data: updatePolicyV2Request
3673
+ },
3674
+ options
3675
+ );
3676
+ };
3677
+ var deletePolicyV2 = (policyId, options) => {
3678
+ return openfortApiClient(
3679
+ {
3680
+ url: `/v2/policies/${policyId}`,
3681
+ method: "DELETE"
3682
+ },
3683
+ options
3684
+ );
3685
+ };
3686
+ var evaluatePolicyV2 = (evaluatePolicyV2Request, options) => {
3687
+ return openfortApiClient(
3688
+ {
3689
+ url: `/v2/policies/evaluate`,
3690
+ method: "POST",
3691
+ headers: { "Content-Type": "application/json" },
3692
+ data: evaluatePolicyV2Request
3693
+ },
3694
+ options
3695
+ );
3696
+ };
3313
3697
 
3314
3698
  // src/openapi-client/generated/policy-rules/policy-rules.ts
3315
3699
  var getPolicyRules = (params, options) => {
@@ -3815,6 +4199,9 @@ var decryptExportedPrivateKey = (encryptedPrivateKeyBase64, privateKeyPem) => {
3815
4199
  return decrypted.toString("hex");
3816
4200
  };
3817
4201
 
4202
+ // src/wallets/evm/accounts/evmAccount.ts
4203
+ var import_viem = require("viem");
4204
+
3818
4205
  // src/wallets/evm/actions/signHash.ts
3819
4206
  async function signHash(options) {
3820
4207
  const { accountId, hash } = options;
@@ -3824,53 +4211,6 @@ async function signHash(options) {
3824
4211
  };
3825
4212
  }
3826
4213
 
3827
- // src/wallets/evm/actions/signMessage.ts
3828
- var import_viem = require("viem");
3829
- async function signMessage(options) {
3830
- const { accountId, message } = options;
3831
- let messageStr;
3832
- if (typeof message === "string") {
3833
- messageStr = message;
3834
- } else if (message instanceof Uint8Array) {
3835
- messageStr = (0, import_viem.toHex)(message);
3836
- } else if ("raw" in message) {
3837
- messageStr = typeof message.raw === "string" ? message.raw : (0, import_viem.toHex)(message.raw);
3838
- } else {
3839
- throw new UserInputValidationError("Invalid message format");
3840
- }
3841
- const messageHash = (0, import_viem.hashMessage)(messageStr);
3842
- const response = await sign(accountId, { data: messageHash });
3843
- return {
3844
- signature: response.signature
3845
- };
3846
- }
3847
-
3848
- // src/wallets/evm/actions/signTransaction.ts
3849
- var import_viem2 = require("viem");
3850
- async function signTransaction(options) {
3851
- const { accountId, transaction } = options;
3852
- const serialized = (0, import_viem2.serializeTransaction)(transaction);
3853
- const response = await sign(accountId, { data: serialized });
3854
- const signature2 = (0, import_viem2.parseSignature)(response.signature);
3855
- const signedTransaction = (0, import_viem2.serializeTransaction)(transaction, signature2);
3856
- const transactionHash = (0, import_viem2.keccak256)(signedTransaction);
3857
- return {
3858
- signedTransaction,
3859
- transactionHash
3860
- };
3861
- }
3862
-
3863
- // src/wallets/evm/actions/signTypedData.ts
3864
- var import_viem3 = require("viem");
3865
- async function signTypedData(options) {
3866
- const { accountId, typedData } = options;
3867
- const hash = (0, import_viem3.hashTypedData)(typedData);
3868
- const response = await sign(accountId, { data: hash });
3869
- return {
3870
- signature: response.signature
3871
- };
3872
- }
3873
-
3874
4214
  // src/wallets/evm/accounts/evmAccount.ts
3875
4215
  function toEvmAccount(data) {
3876
4216
  const { id, address } = data;
@@ -3886,27 +4226,44 @@ function toEvmAccount(data) {
3886
4226
  return result.signature;
3887
4227
  },
3888
4228
  async signMessage(parameters) {
3889
- const result = await signMessage({
3890
- address,
3891
- accountId: id,
3892
- message: parameters.message
3893
- });
4229
+ const { message } = parameters;
4230
+ if (typeof message === "string") {
4231
+ const hash2 = (0, import_viem.hashMessage)(message);
4232
+ const result2 = await sign(id, { data: hash2 });
4233
+ return result2.signature;
4234
+ }
4235
+ const hash = (0, import_viem.hashMessage)(message);
4236
+ const result = await sign(id, { data: hash });
3894
4237
  return result.signature;
3895
4238
  },
3896
4239
  async signTransaction(transaction) {
3897
- const result = await signTransaction({
3898
- address,
3899
- accountId: id,
3900
- transaction
3901
- });
3902
- return result.signedTransaction;
4240
+ const serialized = (0, import_viem.serializeTransaction)(transaction);
4241
+ const response = await sign(id, { data: serialized });
4242
+ const signature2 = (0, import_viem.parseSignature)(response.signature);
4243
+ const signedTransaction = (0, import_viem.serializeTransaction)(
4244
+ transaction,
4245
+ signature2
4246
+ );
4247
+ return signedTransaction;
3903
4248
  },
3904
4249
  async signTypedData(parameters) {
3905
- const result = await signTypedData({
3906
- address,
3907
- accountId: id,
3908
- typedData: parameters
3909
- });
4250
+ const {
4251
+ domain = {},
4252
+ message,
4253
+ primaryType
4254
+ } = parameters;
4255
+ const types = {
4256
+ EIP712Domain: (0, import_viem.getTypesForEIP712Domain)({ domain }),
4257
+ ...parameters.types
4258
+ };
4259
+ const openApiMessage = {
4260
+ domain,
4261
+ types,
4262
+ primaryType,
4263
+ message
4264
+ };
4265
+ const hash = (0, import_viem.hashTypedData)(openApiMessage);
4266
+ const result = await sign(id, { data: hash });
3910
4267
  return result.signature;
3911
4268
  }
3912
4269
  };
@@ -4130,7 +4487,7 @@ EvmClient.type = "evmWallet";
4130
4487
  var import_bs58 = __toESM(require("bs58"));
4131
4488
 
4132
4489
  // src/wallets/solana/actions/signMessage.ts
4133
- async function signMessage2(options) {
4490
+ async function signMessage(options) {
4134
4491
  const { accountId, message } = options;
4135
4492
  const messageBytes = Buffer.from(message, "utf-8");
4136
4493
  const messageHex = `0x${messageBytes.toString("hex")}`;
@@ -4141,7 +4498,7 @@ async function signMessage2(options) {
4141
4498
  }
4142
4499
 
4143
4500
  // src/wallets/solana/actions/signTransaction.ts
4144
- async function signTransaction2(options) {
4501
+ async function signTransaction(options) {
4145
4502
  const { accountId, transaction } = options;
4146
4503
  const txBytes = Buffer.from(transaction, "base64");
4147
4504
  const txHex = `0x${txBytes.toString("hex")}`;
@@ -4159,14 +4516,14 @@ function toSolanaAccount(data) {
4159
4516
  address,
4160
4517
  custody: "Developer",
4161
4518
  async signMessage(parameters) {
4162
- const result = await signMessage2({
4519
+ const result = await signMessage({
4163
4520
  accountId: id,
4164
4521
  message: parameters.message
4165
4522
  });
4166
4523
  return result.signature;
4167
4524
  },
4168
4525
  async signTransaction(parameters) {
4169
- const result = await signTransaction2({
4526
+ const result = await signTransaction({
4170
4527
  accountId: id,
4171
4528
  transaction: parameters.transaction
4172
4529
  });
@@ -4404,6 +4761,290 @@ SolanaClient.type = "solanaWallet";
4404
4761
 
4405
4762
  // src/index.ts
4406
4763
  var import_shield_js2 = require("@openfort/shield-js");
4764
+
4765
+ // src/policies/evmSchema.ts
4766
+ var import_zod = require("zod");
4767
+ var EthValueOperatorEnum = import_zod.z.enum(["<=", ">=", "<", ">"]);
4768
+ var EvmAddressOperatorEnum = import_zod.z.enum(["in", "not in"]);
4769
+ var EvmNetworkOperatorEnum = import_zod.z.enum(["in", "not in"]);
4770
+ var EvmDataOperatorEnum = import_zod.z.enum([
4771
+ "in",
4772
+ "not in",
4773
+ "<",
4774
+ "<=",
4775
+ ">",
4776
+ ">=",
4777
+ "==",
4778
+ "match"
4779
+ ]);
4780
+ var EvmTypedDataVerifyingContractOperatorEnum = import_zod.z.enum([
4781
+ "in",
4782
+ "not in"
4783
+ ]);
4784
+ var EvmTypedDataFieldOperatorEnum = import_zod.z.enum(["in", "<=", "match"]);
4785
+ var ActionEnum = import_zod.z.enum(["reject", "accept"]);
4786
+ var EthValueCriterionSchema = import_zod.z.object({
4787
+ type: import_zod.z.literal("ethValue"),
4788
+ operator: EthValueOperatorEnum,
4789
+ /** Value in wei as a string. */
4790
+ ethValue: import_zod.z.string().regex(/^[0-9]+$/)
4791
+ });
4792
+ var EvmAddressCriterionSchema = import_zod.z.object({
4793
+ type: import_zod.z.literal("evmAddress"),
4794
+ operator: EvmAddressOperatorEnum,
4795
+ /** List of EVM addresses (hex format with 0x prefix). */
4796
+ addresses: import_zod.z.array(import_zod.z.string().regex(/^0x[0-9a-fA-F]{40}$/))
4797
+ });
4798
+ var EvmNetworkCriterionSchema = import_zod.z.object({
4799
+ type: import_zod.z.literal("evmNetwork"),
4800
+ operator: EvmNetworkOperatorEnum,
4801
+ /** List of chain IDs. */
4802
+ chainIds: import_zod.z.array(import_zod.z.number().int().positive())
4803
+ });
4804
+ var EvmMessageCriterionSchema = import_zod.z.object({
4805
+ type: import_zod.z.literal("evmMessage"),
4806
+ operator: import_zod.z.literal("match"),
4807
+ /** RE2 regex pattern to match against the message. */
4808
+ pattern: import_zod.z.string().min(1)
4809
+ });
4810
+ var EvmDataCriterionSchema = import_zod.z.object({
4811
+ type: import_zod.z.literal("evmData"),
4812
+ operator: EvmDataOperatorEnum,
4813
+ /** Contract ABI as JSON string. */
4814
+ abi: import_zod.z.string().min(1),
4815
+ /** Function name to match. */
4816
+ functionName: import_zod.z.string().min(1),
4817
+ /** Argument constraints. */
4818
+ args: import_zod.z.record(import_zod.z.unknown()).optional()
4819
+ });
4820
+ var EvmTypedDataVerifyingContractCriterionSchema = import_zod.z.object({
4821
+ type: import_zod.z.literal("evmTypedDataVerifyingContract"),
4822
+ operator: EvmTypedDataVerifyingContractOperatorEnum,
4823
+ /** List of verifying contract addresses. */
4824
+ addresses: import_zod.z.array(import_zod.z.string().regex(/^0x[0-9a-fA-F]{40}$/))
4825
+ });
4826
+ var EvmTypedDataFieldCriterionSchema = import_zod.z.object({
4827
+ type: import_zod.z.literal("evmTypedDataField"),
4828
+ operator: EvmTypedDataFieldOperatorEnum,
4829
+ /** Dot-notation path to the field (e.g. "order.buyer"). */
4830
+ fieldPath: import_zod.z.string().min(1),
4831
+ /** Values for "in" operator. */
4832
+ values: import_zod.z.array(import_zod.z.string()).optional(),
4833
+ /** Value for "<=" or "match" operators. */
4834
+ value: import_zod.z.string().optional()
4835
+ });
4836
+ var SignEvmTransactionCriteriaSchema = import_zod.z.array(
4837
+ import_zod.z.discriminatedUnion("type", [
4838
+ EthValueCriterionSchema,
4839
+ EvmAddressCriterionSchema,
4840
+ EvmDataCriterionSchema
4841
+ ])
4842
+ ).max(10);
4843
+ var SendEvmTransactionCriteriaSchema = import_zod.z.array(
4844
+ import_zod.z.discriminatedUnion("type", [
4845
+ EthValueCriterionSchema,
4846
+ EvmAddressCriterionSchema,
4847
+ EvmNetworkCriterionSchema,
4848
+ EvmDataCriterionSchema
4849
+ ])
4850
+ ).max(10);
4851
+ var SignEvmMessageCriteriaSchema = import_zod.z.array(import_zod.z.discriminatedUnion("type", [EvmMessageCriterionSchema])).max(10);
4852
+ var SignEvmTypedDataCriteriaSchema = import_zod.z.array(
4853
+ import_zod.z.discriminatedUnion("type", [
4854
+ EvmTypedDataFieldCriterionSchema,
4855
+ EvmTypedDataVerifyingContractCriterionSchema
4856
+ ])
4857
+ ).max(10);
4858
+ var SignEvmTransactionRuleSchema = import_zod.z.object({
4859
+ action: ActionEnum,
4860
+ operation: import_zod.z.literal("signEvmTransaction"),
4861
+ criteria: SignEvmTransactionCriteriaSchema
4862
+ });
4863
+ var SendEvmTransactionRuleSchema = import_zod.z.object({
4864
+ action: ActionEnum,
4865
+ operation: import_zod.z.literal("sendEvmTransaction"),
4866
+ criteria: SendEvmTransactionCriteriaSchema
4867
+ });
4868
+ var SignEvmMessageRuleSchema = import_zod.z.object({
4869
+ action: ActionEnum,
4870
+ operation: import_zod.z.literal("signEvmMessage"),
4871
+ criteria: SignEvmMessageCriteriaSchema
4872
+ });
4873
+ var SignEvmTypedDataRuleSchema = import_zod.z.object({
4874
+ action: ActionEnum,
4875
+ operation: import_zod.z.literal("signEvmTypedData"),
4876
+ criteria: SignEvmTypedDataCriteriaSchema
4877
+ });
4878
+ var SignEvmHashRuleSchema = import_zod.z.object({
4879
+ action: ActionEnum,
4880
+ operation: import_zod.z.literal("signEvmHash")
4881
+ });
4882
+
4883
+ // src/policies/solanaSchema.ts
4884
+ var import_zod2 = require("zod");
4885
+ var SolAddressOperatorEnum = import_zod2.z.enum(["in", "not in"]);
4886
+ var SolValueOperatorEnum = import_zod2.z.enum(["<=", ">="]);
4887
+ var SplAddressOperatorEnum = import_zod2.z.enum(["in", "not in"]);
4888
+ var SplValueOperatorEnum = import_zod2.z.enum(["<=", ">="]);
4889
+ var MintAddressOperatorEnum = import_zod2.z.enum(["==", "in"]);
4890
+ var SolDataOperatorEnum = import_zod2.z.enum([
4891
+ "in",
4892
+ "not in",
4893
+ "<=",
4894
+ ">=",
4895
+ "==",
4896
+ "match"
4897
+ ]);
4898
+ var ProgramIdOperatorEnum = import_zod2.z.enum(["in", "not in"]);
4899
+ var SolNetworkOperatorEnum = import_zod2.z.enum(["in", "not in"]);
4900
+ var SolNetworkEnum = import_zod2.z.enum(["mainnet-beta", "devnet", "testnet"]);
4901
+ var base58Address = import_zod2.z.string().regex(/^[1-9A-HJ-NP-Za-km-z]{32,44}$/);
4902
+ var SolAddressCriterionSchema = import_zod2.z.object({
4903
+ type: import_zod2.z.literal("solAddress"),
4904
+ operator: SolAddressOperatorEnum,
4905
+ /** List of Solana addresses (Base58). */
4906
+ addresses: import_zod2.z.array(base58Address)
4907
+ });
4908
+ var SolValueCriterionSchema = import_zod2.z.object({
4909
+ type: import_zod2.z.literal("solValue"),
4910
+ operator: SolValueOperatorEnum,
4911
+ /** Value in lamports as string. */
4912
+ value: import_zod2.z.string().regex(/^[0-9]+$/)
4913
+ });
4914
+ var SplAddressCriterionSchema = import_zod2.z.object({
4915
+ type: import_zod2.z.literal("splAddress"),
4916
+ operator: SplAddressOperatorEnum,
4917
+ /** List of recipient addresses (Base58). */
4918
+ addresses: import_zod2.z.array(base58Address)
4919
+ });
4920
+ var SplValueCriterionSchema = import_zod2.z.object({
4921
+ type: import_zod2.z.literal("splValue"),
4922
+ operator: SplValueOperatorEnum,
4923
+ /** Token amount as string. */
4924
+ value: import_zod2.z.string().regex(/^[0-9]+$/)
4925
+ });
4926
+ var MintAddressCriterionSchema = import_zod2.z.object({
4927
+ type: import_zod2.z.literal("mintAddress"),
4928
+ operator: MintAddressOperatorEnum,
4929
+ /** List of mint addresses (Base58). */
4930
+ addresses: import_zod2.z.array(base58Address)
4931
+ });
4932
+ var SolDataCriterionSchema = import_zod2.z.object({
4933
+ type: import_zod2.z.literal("solData"),
4934
+ operator: SolDataOperatorEnum,
4935
+ /** Anchor IDL JSON (v0.30+). */
4936
+ idl: import_zod2.z.string().min(1),
4937
+ /** Instruction name. */
4938
+ instructionName: import_zod2.z.string().min(1),
4939
+ /** Argument constraints. */
4940
+ args: import_zod2.z.record(import_zod2.z.unknown()).optional()
4941
+ });
4942
+ var ProgramIdCriterionSchema = import_zod2.z.object({
4943
+ type: import_zod2.z.literal("programId"),
4944
+ operator: ProgramIdOperatorEnum,
4945
+ /** List of program IDs (Base58). */
4946
+ programIds: import_zod2.z.array(base58Address)
4947
+ });
4948
+ var SolNetworkCriterionSchema = import_zod2.z.object({
4949
+ type: import_zod2.z.literal("solNetwork"),
4950
+ operator: SolNetworkOperatorEnum,
4951
+ /** List of networks: "mainnet-beta", "devnet", "testnet". */
4952
+ networks: import_zod2.z.array(SolNetworkEnum)
4953
+ });
4954
+ var SolMessageCriterionSchema = import_zod2.z.object({
4955
+ type: import_zod2.z.literal("solMessage"),
4956
+ operator: import_zod2.z.literal("match"),
4957
+ /** RE2 regex pattern. */
4958
+ pattern: import_zod2.z.string().min(1)
4959
+ });
4960
+ var SignSolTransactionCriteriaSchema = import_zod2.z.array(
4961
+ import_zod2.z.discriminatedUnion("type", [
4962
+ SolAddressCriterionSchema,
4963
+ SolValueCriterionSchema,
4964
+ SplAddressCriterionSchema,
4965
+ SplValueCriterionSchema,
4966
+ MintAddressCriterionSchema,
4967
+ SolDataCriterionSchema,
4968
+ ProgramIdCriterionSchema
4969
+ ])
4970
+ ).max(10);
4971
+ var SendSolTransactionCriteriaSchema = import_zod2.z.array(
4972
+ import_zod2.z.discriminatedUnion("type", [
4973
+ SolAddressCriterionSchema,
4974
+ SolValueCriterionSchema,
4975
+ SplAddressCriterionSchema,
4976
+ SplValueCriterionSchema,
4977
+ MintAddressCriterionSchema,
4978
+ SolDataCriterionSchema,
4979
+ ProgramIdCriterionSchema,
4980
+ SolNetworkCriterionSchema
4981
+ ])
4982
+ ).max(10);
4983
+ var SignSolMessageCriteriaSchema = import_zod2.z.array(SolMessageCriterionSchema).max(10);
4984
+ var SignSolTransactionRuleSchema = import_zod2.z.object({
4985
+ action: ActionEnum,
4986
+ operation: import_zod2.z.literal("signSolTransaction"),
4987
+ criteria: SignSolTransactionCriteriaSchema
4988
+ });
4989
+ var SendSolTransactionRuleSchema = import_zod2.z.object({
4990
+ action: ActionEnum,
4991
+ operation: import_zod2.z.literal("sendSolTransaction"),
4992
+ criteria: SendSolTransactionCriteriaSchema
4993
+ });
4994
+ var SignSolMessageRuleSchema = import_zod2.z.object({
4995
+ action: ActionEnum,
4996
+ operation: import_zod2.z.literal("signSolMessage"),
4997
+ criteria: SignSolMessageCriteriaSchema
4998
+ });
4999
+
5000
+ // src/policies/types.ts
5001
+ var import_zod3 = require("zod");
5002
+ var PolicyScopeEnum = import_zod3.z.enum(["project", "account"]);
5003
+ var RuleSchema = import_zod3.z.discriminatedUnion("operation", [
5004
+ SignEvmTransactionRuleSchema,
5005
+ SendEvmTransactionRuleSchema,
5006
+ SignEvmMessageRuleSchema,
5007
+ SignEvmTypedDataRuleSchema,
5008
+ SignEvmHashRuleSchema,
5009
+ SignSolTransactionRuleSchema,
5010
+ SendSolTransactionRuleSchema,
5011
+ SignSolMessageRuleSchema
5012
+ ]);
5013
+ var CreatePolicyBodySchema = import_zod3.z.object({
5014
+ /** The scope of the policy. 'project' applies to all accounts, 'account' applies to a specific account. */
5015
+ scope: PolicyScopeEnum,
5016
+ /** A description of what this policy does. */
5017
+ description: import_zod3.z.string().optional(),
5018
+ /** The account ID for account-scoped policies (starts with acc_). Required when scope is 'account'. */
5019
+ accountId: import_zod3.z.string().optional(),
5020
+ /** Whether the policy is enabled. */
5021
+ enabled: import_zod3.z.boolean().optional(),
5022
+ /** Priority of the policy. Higher priority policies are evaluated first. */
5023
+ priority: import_zod3.z.number().int().optional(),
5024
+ /** The rules that make up this policy. Maximum 10 rules per policy. */
5025
+ rules: import_zod3.z.array(RuleSchema).min(1).max(10)
5026
+ });
5027
+ var UpdatePolicyBodySchema = import_zod3.z.object({
5028
+ /** A description of what this policy does. */
5029
+ description: import_zod3.z.string().optional(),
5030
+ /** Whether the policy is enabled. */
5031
+ enabled: import_zod3.z.boolean().optional(),
5032
+ /** Priority of the policy. Higher priority policies are evaluated first. */
5033
+ priority: import_zod3.z.number().int().optional(),
5034
+ /** The rules that make up this policy. If provided, replaces all existing rules. Maximum 10 rules. */
5035
+ rules: import_zod3.z.array(RuleSchema).min(1).max(10).optional()
5036
+ });
5037
+
5038
+ // src/wallets/evm/actions/signMessage.ts
5039
+ var import_viem2 = require("viem");
5040
+
5041
+ // src/wallets/evm/actions/signTransaction.ts
5042
+ var import_viem3 = require("viem");
5043
+
5044
+ // src/wallets/evm/actions/signTypedData.ts
5045
+ var import_viem4 = require("viem");
5046
+
5047
+ // src/index.ts
4407
5048
  function isValidSecretKey(key) {
4408
5049
  return key.startsWith("sk_test_") || key.startsWith("sk_live_");
4409
5050
  }
@@ -4539,14 +5180,7 @@ var Openfort = class {
4539
5180
  v1: {
4540
5181
  list: getAccounts,
4541
5182
  create: createAccount,
4542
- get: getAccount,
4543
- requestTransferOwnership,
4544
- cancelTransferOwnership,
4545
- signPayload,
4546
- sync: syncAccount,
4547
- deploy: deployAccount,
4548
- startRecovery,
4549
- completeRecovery
5183
+ get: getAccount
4550
5184
  }
4551
5185
  };
4552
5186
  }
@@ -4555,6 +5189,7 @@ var Openfort = class {
4555
5189
  // ============================================
4556
5190
  /**
4557
5191
  * Player management endpoints
5192
+ * @deprecated
4558
5193
  */
4559
5194
  get players() {
4560
5195
  return {
@@ -4594,41 +5229,77 @@ var Openfort = class {
4594
5229
  // Policies API
4595
5230
  // ============================================
4596
5231
  /**
4597
- * Policy management endpoints
5232
+ * Policy management endpoints for controlling account operations.
5233
+ *
5234
+ * Policies define rules that govern what operations accounts can perform,
5235
+ * including transaction signing, message signing, and more.
5236
+ *
5237
+ * @example
5238
+ * ```typescript
5239
+ * // List all policies
5240
+ * const all = await openfort.policies.list();
5241
+ *
5242
+ * // Create a policy
5243
+ * const policy = await openfort.policies.create({
5244
+ * scope: 'project',
5245
+ * rules: [{ action: 'reject', operation: 'signEvmHash' }],
5246
+ * });
5247
+ *
5248
+ * // Evaluate whether an operation would be allowed
5249
+ * const result = await openfort.policies.evaluate({ operation: 'signEvmTransaction', accountId: 'acc_...' });
5250
+ * ```
4598
5251
  */
4599
5252
  get policies() {
4600
5253
  return {
4601
5254
  /** List policies */
4602
- list: getPolicies,
5255
+ list: listPolicies,
4603
5256
  /** Create a policy */
4604
- create: createPolicy,
5257
+ create: createPolicyV2,
4605
5258
  /** Get a policy by ID */
4606
- get: getPolicy,
5259
+ get: getPolicyV2,
4607
5260
  /** Update a policy */
4608
- update: updatePolicy,
5261
+ update: updatePolicyV2,
4609
5262
  /** Delete a policy */
4610
- delete: deletePolicy,
4611
- /** Disable a policy */
4612
- disable: disablePolicy,
4613
- /** Enable a policy */
4614
- enable: enablePolicy,
4615
- /** Get policy total gas usage */
4616
- getTotalGasUsage: getPolicyTotalGasUsage
5263
+ delete: deletePolicyV2,
5264
+ /** Evaluate an operation against policies */
5265
+ evaluate: evaluatePolicyV2
4617
5266
  };
4618
5267
  }
5268
+ // ============================================
5269
+ // Fee Sponsorship API
5270
+ // ============================================
4619
5271
  /**
4620
- * Policy rules management endpoints
5272
+ * Fee sponsorship (gas policy) management endpoints
4621
5273
  */
4622
- get policyRules() {
5274
+ get feeSponsorship() {
4623
5275
  return {
4624
- /** List policy rules */
4625
- list: getPolicyRules,
4626
- /** Create a policy rule */
4627
- create: createPolicyRule,
4628
- /** Update a policy rule */
4629
- update: updatePolicyRule,
4630
- /** Delete a policy rule */
4631
- delete: deletePolicyRule
5276
+ /** List fee sponsorship policies */
5277
+ list: getPolicies,
5278
+ /** Create a fee sponsorship policy */
5279
+ create: createPolicy,
5280
+ /** Get a fee sponsorship policy by ID */
5281
+ get: getPolicy,
5282
+ /** Update a fee sponsorship policy */
5283
+ update: updatePolicy,
5284
+ /** Delete a fee sponsorship policy */
5285
+ delete: deletePolicy,
5286
+ /** Disable a fee sponsorship policy */
5287
+ disable: disablePolicy,
5288
+ /** Enable a fee sponsorship policy */
5289
+ enable: enablePolicy,
5290
+ /** Get fee sponsorship policy total gas usage */
5291
+ getTotalGasUsage: getPolicyTotalGasUsage,
5292
+ /** Fee sponsorship policy rules */
5293
+ rules: {
5294
+ /** List policy rules */
5295
+ list: getPolicyRules,
5296
+ /** Create a policy rule */
5297
+ create: createPolicyRule,
5298
+ /** Update a policy rule */
5299
+ update: updatePolicyRule,
5300
+ /** Delete a policy rule */
5301
+ delete: deletePolicyRule
5302
+ }
4632
5303
  };
4633
5304
  }
4634
5305
  // ============================================
@@ -4676,6 +5347,7 @@ var Openfort = class {
4676
5347
  // ============================================
4677
5348
  /**
4678
5349
  * Settings / Developer account management endpoints
5350
+ * @deprecated
4679
5351
  */
4680
5352
  get settings() {
4681
5353
  return {
@@ -5018,6 +5690,19 @@ var index_default = Openfort;
5018
5690
  CreateBackendWalletResponseObject,
5019
5691
  CreateEmbeddedRequestAccountType,
5020
5692
  CreateEmbeddedRequestChainType,
5693
+ CreatePolicyBodySchema,
5694
+ CreatePolicyV2RequestScope,
5695
+ CreatePolicyV2RuleRequestAction,
5696
+ CriteriaOperator,
5697
+ CriteriaOperatorEQUAL,
5698
+ CriteriaOperatorGREATERTHAN,
5699
+ CriteriaOperatorGREATERTHANOREQUAL,
5700
+ CriteriaOperatorIN,
5701
+ CriteriaOperatorLESSTHAN,
5702
+ CriteriaOperatorLESSTHANOREQUAL,
5703
+ CriteriaOperatorMATCH,
5704
+ CriteriaOperatorNOTIN,
5705
+ CriteriaType,
5021
5706
  Currency,
5022
5707
  DeleteBackendWalletResponseObject,
5023
5708
  DeveloperAccountResponseExpandable,
@@ -5037,6 +5722,8 @@ var index_default = Openfort;
5037
5722
  EntityTypePLAYER,
5038
5723
  EntityTypePOLICY,
5039
5724
  EntityTypePOLICYRULE,
5725
+ EntityTypePOLICYV2,
5726
+ EntityTypePOLICYV2RULE,
5040
5727
  EntityTypePROJECT,
5041
5728
  EntityTypeREADCONTRACT,
5042
5729
  EntityTypeSESSION,
@@ -5048,7 +5735,43 @@ var index_default = Openfort;
5048
5735
  EntityTypeUSER,
5049
5736
  EntityTypeWALLET,
5050
5737
  ErrorTypeINVALIDREQUESTERROR,
5738
+ EthValueCriterionOperator,
5739
+ EthValueCriterionRequestOperator,
5740
+ EthValueCriterionRequestType,
5741
+ EthValueCriterionSchema,
5742
+ EvaluatePolicyV2ResponseObject,
5743
+ EvmAddressCriterionOperator,
5744
+ EvmAddressCriterionRequestOperator,
5745
+ EvmAddressCriterionRequestType,
5746
+ EvmAddressCriterionSchema,
5051
5747
  EvmClient,
5748
+ EvmCriteriaType,
5749
+ EvmCriteriaTypeETHVALUE,
5750
+ EvmCriteriaTypeEVMADDRESS,
5751
+ EvmCriteriaTypeEVMDATA,
5752
+ EvmCriteriaTypeEVMMESSAGE,
5753
+ EvmCriteriaTypeEVMNETWORK,
5754
+ EvmCriteriaTypeEVMTYPEDDATAFIELD,
5755
+ EvmCriteriaTypeEVMTYPEDDATAVERIFYINGCONTRACT,
5756
+ EvmCriteriaTypeNETUSDCHANGE,
5757
+ EvmDataCriterionRequestOperator,
5758
+ EvmDataCriterionRequestType,
5759
+ EvmDataCriterionSchema,
5760
+ EvmMessageCriterionRequestOperator,
5761
+ EvmMessageCriterionRequestType,
5762
+ EvmMessageCriterionSchema,
5763
+ EvmNetworkCriterionOperator,
5764
+ EvmNetworkCriterionRequestOperator,
5765
+ EvmNetworkCriterionRequestType,
5766
+ EvmNetworkCriterionSchema,
5767
+ EvmTypedDataFieldCriterionOperator,
5768
+ EvmTypedDataFieldCriterionRequestOperator,
5769
+ EvmTypedDataFieldCriterionRequestType,
5770
+ EvmTypedDataFieldCriterionSchema,
5771
+ EvmTypedDataVerifyingContractCriterionOperator,
5772
+ EvmTypedDataVerifyingContractCriterionRequestOperator,
5773
+ EvmTypedDataVerifyingContractCriterionRequestType,
5774
+ EvmTypedDataVerifyingContractCriterionSchema,
5052
5775
  ExportPrivateKeyResponseObject,
5053
5776
  GetAccountsV2AccountType,
5054
5777
  GetAccountsV2ChainType,
@@ -5065,9 +5788,17 @@ var index_default = Openfort;
5065
5788
  JsonRpcRequestJsonrpc,
5066
5789
  JsonRpcSuccessResponseAnyJsonrpc,
5067
5790
  ListBackendWalletsChainType,
5791
+ ListPoliciesScope,
5792
+ MintAddressCriterionOperator,
5793
+ MintAddressCriterionRequestOperator,
5794
+ MintAddressCriterionRequestType,
5795
+ MintAddressCriterionSchema,
5068
5796
  MissingAPIKeyError,
5069
5797
  MissingPublishableKeyError,
5070
5798
  MissingWalletSecretError,
5799
+ NetUSDChangeCriterionOperator,
5800
+ NetUSDChangeCriterionRequestOperator,
5801
+ NetUSDChangeCriterionRequestType,
5071
5802
  NetworkError,
5072
5803
  NextActionType,
5073
5804
  OAuthProvider,
@@ -5092,25 +5823,77 @@ var index_default = Openfort;
5092
5823
  PolicyRuleTypeACCOUNT,
5093
5824
  PolicyRuleTypeCONTRACT,
5094
5825
  PolicyRuleTypeRATELIMIT,
5826
+ PolicyV2Action,
5827
+ PolicyV2ListQueriesScope,
5828
+ PolicyV2Scope,
5095
5829
  PregenerateAccountResponseCustody,
5096
5830
  PregenerateUserRequestV2AccountType,
5097
5831
  PregenerateUserRequestV2ChainType,
5098
5832
  PrismaSortOrder,
5099
5833
  PrivateKeyPolicy,
5834
+ ProgramIdCriterionOperator,
5835
+ ProgramIdCriterionRequestOperator,
5836
+ ProgramIdCriterionRequestType,
5837
+ ProgramIdCriterionSchema,
5100
5838
  ProjectStatsRequestTimeFrame,
5101
5839
  RegisterWalletSecretResponseObject,
5102
5840
  ResponseTypeLIST,
5103
5841
  RevokeWalletSecretResponseObject,
5104
5842
  RotateWalletSecretResponseObject,
5843
+ RuleSchema,
5844
+ SendEvmTransactionRuleSchema,
5845
+ SendSolTransactionRuleSchema,
5105
5846
  SessionResponseExpandable,
5106
5847
  ShieldAuthProvider,
5848
+ SignEvmHashRuleSchema,
5849
+ SignEvmMessageRuleSchema,
5850
+ SignEvmTransactionRuleSchema,
5851
+ SignEvmTypedDataRuleSchema,
5107
5852
  SignResponseObject,
5853
+ SignSolMessageRuleSchema,
5854
+ SignSolTransactionRuleSchema,
5108
5855
  SmsProviderMESSAGEBIRD,
5109
5856
  SmsProviderSMSAPI,
5110
5857
  SmsProviderTWILIO,
5111
5858
  SmsProviderTXTLOCAL,
5112
5859
  SmsProviderVONAGE,
5860
+ SolAddressCriterionOperator,
5861
+ SolAddressCriterionRequestOperator,
5862
+ SolAddressCriterionRequestType,
5863
+ SolAddressCriterionSchema,
5864
+ SolDataCriterionRequestOperator,
5865
+ SolDataCriterionRequestType,
5866
+ SolDataCriterionSchema,
5867
+ SolMessageCriterionRequestOperator,
5868
+ SolMessageCriterionRequestType,
5869
+ SolMessageCriterionSchema,
5870
+ SolNetworkCriterionOperator,
5871
+ SolNetworkCriterionRequestOperator,
5872
+ SolNetworkCriterionRequestType,
5873
+ SolNetworkCriterionSchema,
5874
+ SolValueCriterionOperator,
5875
+ SolValueCriterionRequestOperator,
5876
+ SolValueCriterionRequestType,
5877
+ SolValueCriterionSchema,
5113
5878
  SolanaClient,
5879
+ SolanaCriteriaType,
5880
+ SolanaCriteriaTypeMINTADDRESS,
5881
+ SolanaCriteriaTypePROGRAMID,
5882
+ SolanaCriteriaTypeSOLADDRESS,
5883
+ SolanaCriteriaTypeSOLDATA,
5884
+ SolanaCriteriaTypeSOLMESSAGE,
5885
+ SolanaCriteriaTypeSOLNETWORK,
5886
+ SolanaCriteriaTypeSOLVALUE,
5887
+ SolanaCriteriaTypeSPLADDRESS,
5888
+ SolanaCriteriaTypeSPLVALUE,
5889
+ SplAddressCriterionOperator,
5890
+ SplAddressCriterionRequestOperator,
5891
+ SplAddressCriterionRequestType,
5892
+ SplAddressCriterionSchema,
5893
+ SplValueCriterionOperator,
5894
+ SplValueCriterionRequestOperator,
5895
+ SplValueCriterionRequestType,
5896
+ SplValueCriterionSchema,
5114
5897
  SponsorSchema,
5115
5898
  SponsorSchemaCHARGECUSTOMTOKENS,
5116
5899
  SponsorSchemaFIXEDRATE,
@@ -5132,6 +5915,7 @@ var index_default = Openfort;
5132
5915
  TransactionIntentResponseExpandable,
5133
5916
  TransactionStatus,
5134
5917
  UnknownError,
5918
+ UpdatePolicyBodySchema,
5135
5919
  UserInputValidationError,
5136
5920
  UserProjectCreateRequestRole,
5137
5921
  UserProjectRole,
@@ -5145,8 +5929,6 @@ var index_default = Openfort;
5145
5929
  authorize,
5146
5930
  callbackOAuth,
5147
5931
  cancelTransferAccountOwnership,
5148
- cancelTransferOwnership,
5149
- completeRecovery,
5150
5932
  configure,
5151
5933
  create,
5152
5934
  createAccount,
@@ -5163,6 +5945,7 @@ var index_default = Openfort;
5163
5945
  createPlayer,
5164
5946
  createPolicy,
5165
5947
  createPolicyRule,
5948
+ createPolicyV2,
5166
5949
  createPolicyWithdrawal,
5167
5950
  createSession,
5168
5951
  createSubscription,
@@ -5180,16 +5963,17 @@ var index_default = Openfort;
5180
5963
  deletePlayer,
5181
5964
  deletePolicy,
5182
5965
  deletePolicyRule,
5966
+ deletePolicyV2,
5183
5967
  deleteSubscription,
5184
5968
  deleteTrigger,
5185
5969
  deleteUser,
5186
- deployAccount,
5187
5970
  deprecatedCallbackOAuth,
5188
5971
  disableAccount,
5189
5972
  disablePolicy,
5190
5973
  enablePolicy,
5191
5974
  encryptForImport,
5192
5975
  estimateTransactionIntentCost,
5976
+ evaluatePolicyV2,
5193
5977
  exportPrivateKey,
5194
5978
  generateRSAKeyPair,
5195
5979
  getAccount,
@@ -5222,6 +6006,7 @@ var index_default = Openfort;
5222
6006
  getPolicyReportTransactionIntents,
5223
6007
  getPolicyRules,
5224
6008
  getPolicyTotalGasUsage,
6009
+ getPolicyV2,
5225
6010
  getProjectLogs,
5226
6011
  getSession,
5227
6012
  getSignerIdByAddress,
@@ -5251,6 +6036,7 @@ var index_default = Openfort;
5251
6036
  listForwarderContracts,
5252
6037
  listOAuthConfig,
5253
6038
  listPaymasters,
6039
+ listPolicies,
5254
6040
  listSubscriptionLogs,
5255
6041
  loginEmailPassword,
5256
6042
  loginOIDC,
@@ -5269,20 +6055,16 @@ var index_default = Openfort;
5269
6055
  requestEmailVerification,
5270
6056
  requestResetPassword,
5271
6057
  requestTransferAccountOwnership,
5272
- requestTransferOwnership,
5273
6058
  resetPassword,
5274
6059
  revokeSession,
5275
6060
  revokeWalletSecret,
5276
6061
  rotateWalletSecret,
5277
6062
  sign,
5278
- signPayload,
5279
6063
  signPayloadDeveloperAccount,
5280
6064
  signature,
5281
6065
  signatureSession,
5282
6066
  signupEmailPassword,
5283
- startRecovery,
5284
6067
  switchChainV2,
5285
- syncAccount,
5286
6068
  testTrigger,
5287
6069
  thirdParty,
5288
6070
  thirdPartyV2,
@@ -5298,6 +6080,7 @@ var index_default = Openfort;
5298
6080
  updatePlayer,
5299
6081
  updatePolicy,
5300
6082
  updatePolicyRule,
6083
+ updatePolicyV2,
5301
6084
  verifyAuthToken,
5302
6085
  verifyEmail,
5303
6086
  verifyOAuthToken