@privy-io/api-types 0.1.1

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 (507) hide show
  1. package/CHANGELOG.md +40 -0
  2. package/LICENSE +201 -0
  3. package/README.md +364 -0
  4. package/api-promise.d.mts +2 -0
  5. package/api-promise.d.mts.map +1 -0
  6. package/api-promise.d.ts +2 -0
  7. package/api-promise.d.ts.map +1 -0
  8. package/api-promise.js +6 -0
  9. package/api-promise.js.map +1 -0
  10. package/api-promise.mjs +2 -0
  11. package/api-promise.mjs.map +1 -0
  12. package/client.d.mts +233 -0
  13. package/client.d.mts.map +1 -0
  14. package/client.d.ts +233 -0
  15. package/client.d.ts.map +1 -0
  16. package/client.js +517 -0
  17. package/client.js.map +1 -0
  18. package/client.mjs +513 -0
  19. package/client.mjs.map +1 -0
  20. package/core/api-promise.d.mts +46 -0
  21. package/core/api-promise.d.mts.map +1 -0
  22. package/core/api-promise.d.ts +46 -0
  23. package/core/api-promise.d.ts.map +1 -0
  24. package/core/api-promise.js +74 -0
  25. package/core/api-promise.js.map +1 -0
  26. package/core/api-promise.mjs +70 -0
  27. package/core/api-promise.mjs.map +1 -0
  28. package/core/error.d.mts +46 -0
  29. package/core/error.d.mts.map +1 -0
  30. package/core/error.d.ts +46 -0
  31. package/core/error.d.ts.map +1 -0
  32. package/core/error.js +113 -0
  33. package/core/error.js.map +1 -0
  34. package/core/error.mjs +97 -0
  35. package/core/error.mjs.map +1 -0
  36. package/core/pagination.d.mts +54 -0
  37. package/core/pagination.d.mts.map +1 -0
  38. package/core/pagination.d.ts +54 -0
  39. package/core/pagination.d.ts.map +1 -0
  40. package/core/pagination.js +101 -0
  41. package/core/pagination.js.map +1 -0
  42. package/core/pagination.mjs +95 -0
  43. package/core/pagination.mjs.map +1 -0
  44. package/core/resource.d.mts +6 -0
  45. package/core/resource.d.mts.map +1 -0
  46. package/core/resource.d.ts +6 -0
  47. package/core/resource.d.ts.map +1 -0
  48. package/core/resource.js +11 -0
  49. package/core/resource.js.map +1 -0
  50. package/core/resource.mjs +7 -0
  51. package/core/resource.mjs.map +1 -0
  52. package/core/uploads.d.mts +3 -0
  53. package/core/uploads.d.mts.map +1 -0
  54. package/core/uploads.d.ts +3 -0
  55. package/core/uploads.d.ts.map +1 -0
  56. package/core/uploads.js +6 -0
  57. package/core/uploads.js.map +1 -0
  58. package/core/uploads.mjs +2 -0
  59. package/core/uploads.mjs.map +1 -0
  60. package/error.d.mts +2 -0
  61. package/error.d.mts.map +1 -0
  62. package/error.d.ts +2 -0
  63. package/error.d.ts.map +1 -0
  64. package/error.js +6 -0
  65. package/error.js.map +1 -0
  66. package/error.mjs +2 -0
  67. package/error.mjs.map +1 -0
  68. package/index.d.mts +2 -0
  69. package/index.d.mts.map +1 -0
  70. package/index.d.ts +2 -0
  71. package/index.d.ts.map +1 -0
  72. package/index.js +9 -0
  73. package/index.js.map +1 -0
  74. package/index.mjs +3 -0
  75. package/index.mjs.map +1 -0
  76. package/internal/builtin-types.d.mts +73 -0
  77. package/internal/builtin-types.d.mts.map +1 -0
  78. package/internal/builtin-types.d.ts +73 -0
  79. package/internal/builtin-types.d.ts.map +1 -0
  80. package/internal/builtin-types.js +4 -0
  81. package/internal/builtin-types.js.map +1 -0
  82. package/internal/builtin-types.mjs +3 -0
  83. package/internal/builtin-types.mjs.map +1 -0
  84. package/internal/detect-platform.d.mts +15 -0
  85. package/internal/detect-platform.d.mts.map +1 -0
  86. package/internal/detect-platform.d.ts +15 -0
  87. package/internal/detect-platform.d.ts.map +1 -0
  88. package/internal/detect-platform.js +162 -0
  89. package/internal/detect-platform.js.map +1 -0
  90. package/internal/detect-platform.mjs +157 -0
  91. package/internal/detect-platform.mjs.map +1 -0
  92. package/internal/errors.d.mts +3 -0
  93. package/internal/errors.d.mts.map +1 -0
  94. package/internal/errors.d.ts +3 -0
  95. package/internal/errors.d.ts.map +1 -0
  96. package/internal/errors.js +41 -0
  97. package/internal/errors.js.map +1 -0
  98. package/internal/errors.mjs +36 -0
  99. package/internal/errors.mjs.map +1 -0
  100. package/internal/headers.d.mts +20 -0
  101. package/internal/headers.d.mts.map +1 -0
  102. package/internal/headers.d.ts +20 -0
  103. package/internal/headers.d.ts.map +1 -0
  104. package/internal/headers.js +79 -0
  105. package/internal/headers.js.map +1 -0
  106. package/internal/headers.mjs +74 -0
  107. package/internal/headers.mjs.map +1 -0
  108. package/internal/parse.d.mts +12 -0
  109. package/internal/parse.d.mts.map +1 -0
  110. package/internal/parse.d.ts +12 -0
  111. package/internal/parse.d.ts.map +1 -0
  112. package/internal/parse.js +35 -0
  113. package/internal/parse.js.map +1 -0
  114. package/internal/parse.mjs +32 -0
  115. package/internal/parse.mjs.map +1 -0
  116. package/internal/qs/formats.d.mts +7 -0
  117. package/internal/qs/formats.d.mts.map +1 -0
  118. package/internal/qs/formats.d.ts +7 -0
  119. package/internal/qs/formats.d.ts.map +1 -0
  120. package/internal/qs/formats.js +13 -0
  121. package/internal/qs/formats.js.map +1 -0
  122. package/internal/qs/formats.mjs +9 -0
  123. package/internal/qs/formats.mjs.map +1 -0
  124. package/internal/qs/index.d.mts +10 -0
  125. package/internal/qs/index.d.mts.map +1 -0
  126. package/internal/qs/index.d.ts +10 -0
  127. package/internal/qs/index.d.ts.map +1 -0
  128. package/internal/qs/index.js +14 -0
  129. package/internal/qs/index.js.map +1 -0
  130. package/internal/qs/index.mjs +10 -0
  131. package/internal/qs/index.mjs.map +1 -0
  132. package/internal/qs/stringify.d.mts +3 -0
  133. package/internal/qs/stringify.d.mts.map +1 -0
  134. package/internal/qs/stringify.d.ts +3 -0
  135. package/internal/qs/stringify.d.ts.map +1 -0
  136. package/internal/qs/stringify.js +277 -0
  137. package/internal/qs/stringify.js.map +1 -0
  138. package/internal/qs/stringify.mjs +274 -0
  139. package/internal/qs/stringify.mjs.map +1 -0
  140. package/internal/qs/types.d.mts +57 -0
  141. package/internal/qs/types.d.mts.map +1 -0
  142. package/internal/qs/types.d.ts +57 -0
  143. package/internal/qs/types.d.ts.map +1 -0
  144. package/internal/qs/types.js +3 -0
  145. package/internal/qs/types.js.map +1 -0
  146. package/internal/qs/types.mjs +2 -0
  147. package/internal/qs/types.mjs.map +1 -0
  148. package/internal/qs/utils.d.mts +15 -0
  149. package/internal/qs/utils.d.mts.map +1 -0
  150. package/internal/qs/utils.d.ts +15 -0
  151. package/internal/qs/utils.d.ts.map +1 -0
  152. package/internal/qs/utils.js +230 -0
  153. package/internal/qs/utils.js.map +1 -0
  154. package/internal/qs/utils.mjs +217 -0
  155. package/internal/qs/utils.mjs.map +1 -0
  156. package/internal/request-options.d.mts +75 -0
  157. package/internal/request-options.d.mts.map +1 -0
  158. package/internal/request-options.d.ts +75 -0
  159. package/internal/request-options.d.ts.map +1 -0
  160. package/internal/request-options.js +14 -0
  161. package/internal/request-options.js.map +1 -0
  162. package/internal/request-options.mjs +10 -0
  163. package/internal/request-options.mjs.map +1 -0
  164. package/internal/shim-types.d.mts +17 -0
  165. package/internal/shim-types.d.mts.map +1 -0
  166. package/internal/shim-types.d.ts +17 -0
  167. package/internal/shim-types.d.ts.map +1 -0
  168. package/internal/shim-types.js +4 -0
  169. package/internal/shim-types.js.map +1 -0
  170. package/internal/shim-types.mjs +3 -0
  171. package/internal/shim-types.mjs.map +1 -0
  172. package/internal/shims.d.mts +20 -0
  173. package/internal/shims.d.mts.map +1 -0
  174. package/internal/shims.d.ts +20 -0
  175. package/internal/shims.d.ts.map +1 -0
  176. package/internal/shims.js +92 -0
  177. package/internal/shims.js.map +1 -0
  178. package/internal/shims.mjs +85 -0
  179. package/internal/shims.mjs.map +1 -0
  180. package/internal/to-file.d.mts +45 -0
  181. package/internal/to-file.d.mts.map +1 -0
  182. package/internal/to-file.d.ts +45 -0
  183. package/internal/to-file.d.ts.map +1 -0
  184. package/internal/to-file.js +91 -0
  185. package/internal/to-file.js.map +1 -0
  186. package/internal/to-file.mjs +88 -0
  187. package/internal/to-file.mjs.map +1 -0
  188. package/internal/tslib.js +81 -0
  189. package/internal/tslib.mjs +17 -0
  190. package/internal/types.d.mts +69 -0
  191. package/internal/types.d.mts.map +1 -0
  192. package/internal/types.d.ts +69 -0
  193. package/internal/types.d.ts.map +1 -0
  194. package/internal/types.js +4 -0
  195. package/internal/types.js.map +1 -0
  196. package/internal/types.mjs +3 -0
  197. package/internal/types.mjs.map +1 -0
  198. package/internal/uploads.d.mts +42 -0
  199. package/internal/uploads.d.mts.map +1 -0
  200. package/internal/uploads.d.ts +42 -0
  201. package/internal/uploads.d.ts.map +1 -0
  202. package/internal/uploads.js +141 -0
  203. package/internal/uploads.js.map +1 -0
  204. package/internal/uploads.mjs +131 -0
  205. package/internal/uploads.mjs.map +1 -0
  206. package/internal/utils/base64.d.mts +3 -0
  207. package/internal/utils/base64.d.mts.map +1 -0
  208. package/internal/utils/base64.d.ts +3 -0
  209. package/internal/utils/base64.d.ts.map +1 -0
  210. package/internal/utils/base64.js +38 -0
  211. package/internal/utils/base64.js.map +1 -0
  212. package/internal/utils/base64.mjs +33 -0
  213. package/internal/utils/base64.mjs.map +1 -0
  214. package/internal/utils/bytes.d.mts +4 -0
  215. package/internal/utils/bytes.d.mts.map +1 -0
  216. package/internal/utils/bytes.d.ts +4 -0
  217. package/internal/utils/bytes.d.ts.map +1 -0
  218. package/internal/utils/bytes.js +31 -0
  219. package/internal/utils/bytes.js.map +1 -0
  220. package/internal/utils/bytes.mjs +26 -0
  221. package/internal/utils/bytes.mjs.map +1 -0
  222. package/internal/utils/env.d.mts +9 -0
  223. package/internal/utils/env.d.mts.map +1 -0
  224. package/internal/utils/env.d.ts +9 -0
  225. package/internal/utils/env.d.ts.map +1 -0
  226. package/internal/utils/env.js +22 -0
  227. package/internal/utils/env.js.map +1 -0
  228. package/internal/utils/env.mjs +18 -0
  229. package/internal/utils/env.mjs.map +1 -0
  230. package/internal/utils/log.d.mts +37 -0
  231. package/internal/utils/log.d.mts.map +1 -0
  232. package/internal/utils/log.d.ts +37 -0
  233. package/internal/utils/log.d.ts.map +1 -0
  234. package/internal/utils/log.js +85 -0
  235. package/internal/utils/log.js.map +1 -0
  236. package/internal/utils/log.mjs +79 -0
  237. package/internal/utils/log.mjs.map +1 -0
  238. package/internal/utils/path.d.mts +15 -0
  239. package/internal/utils/path.d.mts.map +1 -0
  240. package/internal/utils/path.d.ts +15 -0
  241. package/internal/utils/path.d.ts.map +1 -0
  242. package/internal/utils/path.js +79 -0
  243. package/internal/utils/path.js.map +1 -0
  244. package/internal/utils/path.mjs +74 -0
  245. package/internal/utils/path.mjs.map +1 -0
  246. package/internal/utils/sleep.d.mts +2 -0
  247. package/internal/utils/sleep.d.mts.map +1 -0
  248. package/internal/utils/sleep.d.ts +2 -0
  249. package/internal/utils/sleep.d.ts.map +1 -0
  250. package/internal/utils/sleep.js +7 -0
  251. package/internal/utils/sleep.js.map +1 -0
  252. package/internal/utils/sleep.mjs +3 -0
  253. package/internal/utils/sleep.mjs.map +1 -0
  254. package/internal/utils/uuid.d.mts +5 -0
  255. package/internal/utils/uuid.d.mts.map +1 -0
  256. package/internal/utils/uuid.d.ts +5 -0
  257. package/internal/utils/uuid.d.ts.map +1 -0
  258. package/internal/utils/uuid.js +19 -0
  259. package/internal/utils/uuid.js.map +1 -0
  260. package/internal/utils/uuid.mjs +15 -0
  261. package/internal/utils/uuid.mjs.map +1 -0
  262. package/internal/utils/values.d.mts +18 -0
  263. package/internal/utils/values.d.mts.map +1 -0
  264. package/internal/utils/values.d.ts +18 -0
  265. package/internal/utils/values.d.ts.map +1 -0
  266. package/internal/utils/values.js +112 -0
  267. package/internal/utils/values.js.map +1 -0
  268. package/internal/utils/values.mjs +94 -0
  269. package/internal/utils/values.mjs.map +1 -0
  270. package/internal/utils.d.mts +7 -0
  271. package/internal/utils.d.mts.map +1 -0
  272. package/internal/utils.d.ts +7 -0
  273. package/internal/utils.d.ts.map +1 -0
  274. package/internal/utils.js +11 -0
  275. package/internal/utils.js.map +1 -0
  276. package/internal/utils.mjs +8 -0
  277. package/internal/utils.mjs.map +1 -0
  278. package/package.json +148 -0
  279. package/pagination.d.mts +2 -0
  280. package/pagination.d.mts.map +1 -0
  281. package/pagination.d.ts +2 -0
  282. package/pagination.d.ts.map +1 -0
  283. package/pagination.js +6 -0
  284. package/pagination.js.map +1 -0
  285. package/pagination.mjs +2 -0
  286. package/pagination.mjs.map +1 -0
  287. package/resource.d.mts +2 -0
  288. package/resource.d.mts.map +1 -0
  289. package/resource.d.ts +2 -0
  290. package/resource.d.ts.map +1 -0
  291. package/resource.js +6 -0
  292. package/resource.js.map +1 -0
  293. package/resource.mjs +2 -0
  294. package/resource.mjs.map +1 -0
  295. package/resources/analytics.d.mts +17 -0
  296. package/resources/analytics.d.mts.map +1 -0
  297. package/resources/analytics.d.ts +17 -0
  298. package/resources/analytics.d.ts.map +1 -0
  299. package/resources/analytics.js +9 -0
  300. package/resources/analytics.js.map +1 -0
  301. package/resources/analytics.mjs +5 -0
  302. package/resources/analytics.mjs.map +1 -0
  303. package/resources/apps.d.mts +126 -0
  304. package/resources/apps.d.mts.map +1 -0
  305. package/resources/apps.d.ts +126 -0
  306. package/resources/apps.d.ts.map +1 -0
  307. package/resources/apps.js +9 -0
  308. package/resources/apps.js.map +1 -0
  309. package/resources/apps.mjs +5 -0
  310. package/resources/apps.mjs.map +1 -0
  311. package/resources/client-auth.d.mts +874 -0
  312. package/resources/client-auth.d.mts.map +1 -0
  313. package/resources/client-auth.d.ts +874 -0
  314. package/resources/client-auth.d.ts.map +1 -0
  315. package/resources/client-auth.js +9 -0
  316. package/resources/client-auth.js.map +1 -0
  317. package/resources/client-auth.mjs +5 -0
  318. package/resources/client-auth.mjs.map +1 -0
  319. package/resources/cross-app.d.mts +24 -0
  320. package/resources/cross-app.d.mts.map +1 -0
  321. package/resources/cross-app.d.ts +24 -0
  322. package/resources/cross-app.d.ts.map +1 -0
  323. package/resources/cross-app.js +9 -0
  324. package/resources/cross-app.js.map +1 -0
  325. package/resources/cross-app.mjs +5 -0
  326. package/resources/cross-app.mjs.map +1 -0
  327. package/resources/embedded-wallets.d.mts +125 -0
  328. package/resources/embedded-wallets.d.mts.map +1 -0
  329. package/resources/embedded-wallets.d.ts +125 -0
  330. package/resources/embedded-wallets.d.ts.map +1 -0
  331. package/resources/embedded-wallets.js +9 -0
  332. package/resources/embedded-wallets.js.map +1 -0
  333. package/resources/embedded-wallets.mjs +5 -0
  334. package/resources/embedded-wallets.mjs.map +1 -0
  335. package/resources/funding.d.mts +101 -0
  336. package/resources/funding.d.mts.map +1 -0
  337. package/resources/funding.d.ts +101 -0
  338. package/resources/funding.d.ts.map +1 -0
  339. package/resources/funding.js +9 -0
  340. package/resources/funding.js.map +1 -0
  341. package/resources/funding.mjs +5 -0
  342. package/resources/funding.mjs.map +1 -0
  343. package/resources/index.d.mts +12 -0
  344. package/resources/index.d.mts.map +1 -0
  345. package/resources/index.d.ts +12 -0
  346. package/resources/index.d.ts.map +1 -0
  347. package/resources/index.js +27 -0
  348. package/resources/index.js.map +1 -0
  349. package/resources/index.mjs +13 -0
  350. package/resources/index.mjs.map +1 -0
  351. package/resources/key-quorums.d.mts +106 -0
  352. package/resources/key-quorums.d.mts.map +1 -0
  353. package/resources/key-quorums.d.ts +106 -0
  354. package/resources/key-quorums.d.ts.map +1 -0
  355. package/resources/key-quorums.js +84 -0
  356. package/resources/key-quorums.js.map +1 -0
  357. package/resources/key-quorums.mjs +80 -0
  358. package/resources/key-quorums.mjs.map +1 -0
  359. package/resources/policies.d.mts +1284 -0
  360. package/resources/policies.d.mts.map +1 -0
  361. package/resources/policies.d.ts +1284 -0
  362. package/resources/policies.d.ts.map +1 -0
  363. package/resources/policies.js +228 -0
  364. package/resources/policies.js.map +1 -0
  365. package/resources/policies.mjs +224 -0
  366. package/resources/policies.mjs.map +1 -0
  367. package/resources/transactions.d.mts +134 -0
  368. package/resources/transactions.d.mts.map +1 -0
  369. package/resources/transactions.d.ts +134 -0
  370. package/resources/transactions.d.ts.map +1 -0
  371. package/resources/transactions.js +23 -0
  372. package/resources/transactions.js.map +1 -0
  373. package/resources/transactions.mjs +19 -0
  374. package/resources/transactions.mjs.map +1 -0
  375. package/resources/users.d.mts +901 -0
  376. package/resources/users.d.mts.map +1 -0
  377. package/resources/users.d.ts +901 -0
  378. package/resources/users.d.ts.map +1 -0
  379. package/resources/users.js +278 -0
  380. package/resources/users.js.map +1 -0
  381. package/resources/users.mjs +274 -0
  382. package/resources/users.mjs.map +1 -0
  383. package/resources/wallets/balance.d.mts +40 -0
  384. package/resources/wallets/balance.d.mts.map +1 -0
  385. package/resources/wallets/balance.d.ts +40 -0
  386. package/resources/wallets/balance.d.ts.map +1 -0
  387. package/resources/wallets/balance.js +24 -0
  388. package/resources/wallets/balance.js.map +1 -0
  389. package/resources/wallets/balance.mjs +20 -0
  390. package/resources/wallets/balance.mjs.map +1 -0
  391. package/resources/wallets/index.d.mts +4 -0
  392. package/resources/wallets/index.d.mts.map +1 -0
  393. package/resources/wallets/index.d.ts +4 -0
  394. package/resources/wallets/index.d.ts.map +1 -0
  395. package/resources/wallets/index.js +11 -0
  396. package/resources/wallets/index.js.map +1 -0
  397. package/resources/wallets/index.mjs +5 -0
  398. package/resources/wallets/index.mjs.map +1 -0
  399. package/resources/wallets/transactions.d.mts +73 -0
  400. package/resources/wallets/transactions.d.mts.map +1 -0
  401. package/resources/wallets/transactions.d.ts +73 -0
  402. package/resources/wallets/transactions.d.ts.map +1 -0
  403. package/resources/wallets/transactions.js +24 -0
  404. package/resources/wallets/transactions.js.map +1 -0
  405. package/resources/wallets/transactions.mjs +20 -0
  406. package/resources/wallets/transactions.mjs.map +1 -0
  407. package/resources/wallets/wallets.d.mts +1137 -0
  408. package/resources/wallets/wallets.d.mts.map +1 -0
  409. package/resources/wallets/wallets.d.ts +1137 -0
  410. package/resources/wallets/wallets.d.ts.map +1 -0
  411. package/resources/wallets/wallets.js +235 -0
  412. package/resources/wallets/wallets.js.map +1 -0
  413. package/resources/wallets/wallets.mjs +230 -0
  414. package/resources/wallets/wallets.mjs.map +1 -0
  415. package/resources/wallets.d.mts +2 -0
  416. package/resources/wallets.d.mts.map +1 -0
  417. package/resources/wallets.d.ts +2 -0
  418. package/resources/wallets.d.ts.map +1 -0
  419. package/resources/wallets.js +6 -0
  420. package/resources/wallets.js.map +1 -0
  421. package/resources/wallets.mjs +3 -0
  422. package/resources/wallets.mjs.map +1 -0
  423. package/resources.d.mts +2 -0
  424. package/resources.d.mts.map +1 -0
  425. package/resources.d.ts +2 -0
  426. package/resources.d.ts.map +1 -0
  427. package/resources.js +5 -0
  428. package/resources.js.map +1 -0
  429. package/resources.mjs +2 -0
  430. package/resources.mjs.map +1 -0
  431. package/src/api-promise.ts +2 -0
  432. package/src/client.ts +1200 -0
  433. package/src/core/README.md +3 -0
  434. package/src/core/api-promise.ts +92 -0
  435. package/src/core/error.ts +130 -0
  436. package/src/core/pagination.ts +152 -0
  437. package/src/core/resource.ts +11 -0
  438. package/src/core/uploads.ts +2 -0
  439. package/src/error.ts +2 -0
  440. package/src/index.ts +3 -0
  441. package/src/internal/README.md +3 -0
  442. package/src/internal/builtin-types.ts +93 -0
  443. package/src/internal/detect-platform.ts +196 -0
  444. package/src/internal/errors.ts +33 -0
  445. package/src/internal/headers.ts +97 -0
  446. package/src/internal/parse.ts +50 -0
  447. package/src/internal/qs/LICENSE.md +13 -0
  448. package/src/internal/qs/README.md +3 -0
  449. package/src/internal/qs/formats.ts +10 -0
  450. package/src/internal/qs/index.ts +13 -0
  451. package/src/internal/qs/stringify.ts +385 -0
  452. package/src/internal/qs/types.ts +71 -0
  453. package/src/internal/qs/utils.ts +265 -0
  454. package/src/internal/request-options.ts +91 -0
  455. package/src/internal/shim-types.ts +26 -0
  456. package/src/internal/shims.ts +107 -0
  457. package/src/internal/to-file.ts +154 -0
  458. package/src/internal/types.ts +95 -0
  459. package/src/internal/uploads.ts +187 -0
  460. package/src/internal/utils/base64.ts +40 -0
  461. package/src/internal/utils/bytes.ts +32 -0
  462. package/src/internal/utils/env.ts +18 -0
  463. package/src/internal/utils/log.ts +126 -0
  464. package/src/internal/utils/path.ts +88 -0
  465. package/src/internal/utils/sleep.ts +3 -0
  466. package/src/internal/utils/uuid.ts +17 -0
  467. package/src/internal/utils/values.ts +105 -0
  468. package/src/internal/utils.ts +8 -0
  469. package/src/lib/.keep +4 -0
  470. package/src/pagination.ts +2 -0
  471. package/src/resource.ts +2 -0
  472. package/src/resources/analytics.ts +20 -0
  473. package/src/resources/apps.ts +213 -0
  474. package/src/resources/client-auth.ts +1323 -0
  475. package/src/resources/cross-app.ts +34 -0
  476. package/src/resources/embedded-wallets.ts +203 -0
  477. package/src/resources/funding.ts +225 -0
  478. package/src/resources/index.ts +191 -0
  479. package/src/resources/key-quorums.ts +177 -0
  480. package/src/resources/policies.ts +1993 -0
  481. package/src/resources/transactions.ts +208 -0
  482. package/src/resources/users.ts +1552 -0
  483. package/src/resources/wallets/balance.ts +103 -0
  484. package/src/resources/wallets/index.ts +29 -0
  485. package/src/resources/wallets/transactions.ts +156 -0
  486. package/src/resources/wallets/wallets.ts +1615 -0
  487. package/src/resources/wallets.ts +3 -0
  488. package/src/resources.ts +1 -0
  489. package/src/tsconfig.json +11 -0
  490. package/src/uploads.ts +2 -0
  491. package/src/version.ts +1 -0
  492. package/uploads.d.mts +2 -0
  493. package/uploads.d.mts.map +1 -0
  494. package/uploads.d.ts +2 -0
  495. package/uploads.d.ts.map +1 -0
  496. package/uploads.js +6 -0
  497. package/uploads.js.map +1 -0
  498. package/uploads.mjs +2 -0
  499. package/uploads.mjs.map +1 -0
  500. package/version.d.mts +2 -0
  501. package/version.d.mts.map +1 -0
  502. package/version.d.ts +2 -0
  503. package/version.d.ts.map +1 -0
  504. package/version.js +5 -0
  505. package/version.js.map +1 -0
  506. package/version.mjs +2 -0
  507. package/version.mjs.map +1 -0
@@ -0,0 +1,1615 @@
1
+ // File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details.
2
+
3
+ import { APIResource } from '../../core/resource';
4
+ import * as WalletsAPI from './wallets';
5
+ import * as BalanceAPI from './balance';
6
+ import { Balance, BalanceGetParams, BalanceGetResponse } from './balance';
7
+ import * as TransactionsAPI from './transactions';
8
+ import { TransactionGetParams, TransactionGetResponse, Transactions } from './transactions';
9
+ import { APIPromise } from '../../core/api-promise';
10
+ import { Cursor, type CursorParams, PagePromise } from '../../core/pagination';
11
+ import { buildHeaders } from '../../internal/headers';
12
+ import { RequestOptions } from '../../internal/request-options';
13
+ import { path } from '../../internal/utils/path';
14
+
15
+ export class Wallets extends APIResource {
16
+ transactions: TransactionsAPI.Transactions = new TransactionsAPI.Transactions(this._client);
17
+ balance: BalanceAPI.Balance = new BalanceAPI.Balance(this._client);
18
+
19
+ /**
20
+ * Create a new wallet.
21
+ *
22
+ * @example
23
+ * ```ts
24
+ * const wallet = await client.wallets.create({
25
+ * chain_type: 'ethereum',
26
+ * });
27
+ * ```
28
+ */
29
+ create(params: WalletCreateParams, options?: RequestOptions): APIPromise<Wallet> {
30
+ const { 'privy-idempotency-key': privyIdempotencyKey, ...body } = params;
31
+ return this._client.post('/v1/wallets', {
32
+ body,
33
+ ...options,
34
+ headers: buildHeaders([
35
+ { ...(privyIdempotencyKey != null ? { 'privy-idempotency-key': privyIdempotencyKey } : undefined) },
36
+ options?.headers,
37
+ ]),
38
+ });
39
+ }
40
+
41
+ /**
42
+ * Get all wallets in your app.
43
+ *
44
+ * @example
45
+ * ```ts
46
+ * // Automatically fetches more pages as needed.
47
+ * for await (const wallet of client.wallets.list()) {
48
+ * // ...
49
+ * }
50
+ * ```
51
+ */
52
+ list(
53
+ query: WalletListParams | null | undefined = {},
54
+ options?: RequestOptions,
55
+ ): PagePromise<WalletsCursor, Wallet> {
56
+ return this._client.getAPIList('/v1/wallets', Cursor<Wallet>, { query, ...options });
57
+ }
58
+
59
+ /**
60
+ * Export a wallet's private key
61
+ *
62
+ * @example
63
+ * ```ts
64
+ * const response = await client.wallets._export('wallet_id', {
65
+ * encryption_type: 'HPKE',
66
+ * recipient_public_key:
67
+ * 'BDAZLOIdTaPycEYkgG0MvCzbIKJLli/yWkAV5yCa9yOsZ4JsrLweA5MnP8YIiY4k/RRzC+APhhO+P+Hoz/rt7Go=',
68
+ * });
69
+ * ```
70
+ */
71
+ _export(
72
+ walletID: string,
73
+ params: WalletExportParams,
74
+ options?: RequestOptions,
75
+ ): APIPromise<WalletExportResponse> {
76
+ const { 'privy-authorization-signature': privyAuthorizationSignature, ...body } = params;
77
+ return this._client.post(path`/v1/wallets/${walletID}/export`, {
78
+ body,
79
+ ...options,
80
+ headers: buildHeaders([
81
+ {
82
+ ...(privyAuthorizationSignature != null ?
83
+ { 'privy-authorization-signature': privyAuthorizationSignature }
84
+ : undefined),
85
+ },
86
+ options?.headers,
87
+ ]),
88
+ });
89
+ }
90
+
91
+ /**
92
+ * Initialize a wallet import. Complete by submitting the import.
93
+ *
94
+ * @example
95
+ * ```ts
96
+ * const response = await client.wallets._initImport({
97
+ * address: 'address',
98
+ * chain_type: 'ethereum',
99
+ * encryption_type: 'HPKE',
100
+ * entropy_type: 'hd',
101
+ * index: 0,
102
+ * });
103
+ * ```
104
+ */
105
+ _initImport(body: WalletInitImportParams, options?: RequestOptions): APIPromise<WalletInitImportResponse> {
106
+ return this._client.post('/v1/wallets/import/init', { body, ...options });
107
+ }
108
+
109
+ /**
110
+ * Sign a message with a wallet by wallet ID.
111
+ *
112
+ * @example
113
+ * ```ts
114
+ * const response = await client.wallets._rawSign(
115
+ * 'wallet_id',
116
+ * { params: {} },
117
+ * );
118
+ * ```
119
+ */
120
+ _rawSign(
121
+ walletID: string,
122
+ params: WalletRawSignParams,
123
+ options?: RequestOptions,
124
+ ): APIPromise<WalletRawSignResponse> {
125
+ const {
126
+ 'privy-authorization-signature': privyAuthorizationSignature,
127
+ 'privy-idempotency-key': privyIdempotencyKey,
128
+ ...body
129
+ } = params;
130
+ return this._client.post(path`/v1/wallets/${walletID}/raw_sign`, {
131
+ body,
132
+ ...options,
133
+ headers: buildHeaders([
134
+ {
135
+ ...(privyAuthorizationSignature != null ?
136
+ { 'privy-authorization-signature': privyAuthorizationSignature }
137
+ : undefined),
138
+ ...(privyIdempotencyKey != null ? { 'privy-idempotency-key': privyIdempotencyKey } : undefined),
139
+ },
140
+ options?.headers,
141
+ ]),
142
+ });
143
+ }
144
+
145
+ /**
146
+ * Sign a message or transaction with a wallet by wallet ID.
147
+ *
148
+ * @example
149
+ * ```ts
150
+ * const response = await client.wallets._rpc('wallet_id', {
151
+ * method: 'eth_signTransaction',
152
+ * params: { transaction: {} },
153
+ * });
154
+ * ```
155
+ */
156
+ _rpc(walletID: string, params: WalletRpcParams, options?: RequestOptions): APIPromise<WalletRpcResponse> {
157
+ const {
158
+ 'privy-authorization-signature': privyAuthorizationSignature,
159
+ 'privy-idempotency-key': privyIdempotencyKey,
160
+ ...body
161
+ } = params;
162
+ return this._client.post(path`/v1/wallets/${walletID}/rpc`, {
163
+ body,
164
+ ...options,
165
+ headers: buildHeaders([
166
+ {
167
+ ...(privyAuthorizationSignature != null ?
168
+ { 'privy-authorization-signature': privyAuthorizationSignature }
169
+ : undefined),
170
+ ...(privyIdempotencyKey != null ? { 'privy-idempotency-key': privyIdempotencyKey } : undefined),
171
+ },
172
+ options?.headers,
173
+ ]),
174
+ });
175
+ }
176
+
177
+ /**
178
+ * Submit a wallet import request.
179
+ *
180
+ * @example
181
+ * ```ts
182
+ * const wallet = await client.wallets._submitImport({
183
+ * wallet: {
184
+ * address: '0xF1DBff66C993EE895C8cb176c30b07A559d76496',
185
+ * chain_type: 'ethereum',
186
+ * ciphertext:
187
+ * 'PRoRXygG+YYSDBXjCopNYZmx8Z6nvdl1D0lpePTYZdZI2VGfK+LkFt+GlEJqdoi9',
188
+ * encapsulated_key:
189
+ * 'BOhR6xITDt5THJawHHJKrKdI9CBr2M/SDWzZZAaOW4gCMsSpC65U007WyKiwuuOVAo1BNm4YgcBBROuMmyIZXZk=',
190
+ * encryption_type: 'HPKE',
191
+ * entropy_type: 'private-key',
192
+ * },
193
+ * });
194
+ * ```
195
+ */
196
+ _submitImport(body: WalletSubmitImportParams, options?: RequestOptions): APIPromise<Wallet> {
197
+ return this._client.post('/v1/wallets/import/submit', { body, ...options });
198
+ }
199
+
200
+ /**
201
+ * Update a wallet's policies or authorization key configuration.
202
+ *
203
+ * @example
204
+ * ```ts
205
+ * const wallet = await client.wallets._update('wallet_id');
206
+ * ```
207
+ */
208
+ _update(walletID: string, params: WalletUpdateParams, options?: RequestOptions): APIPromise<Wallet> {
209
+ const { 'privy-authorization-signature': privyAuthorizationSignature, ...body } = params;
210
+ return this._client.patch(path`/v1/wallets/${walletID}`, {
211
+ body,
212
+ ...options,
213
+ headers: buildHeaders([
214
+ {
215
+ ...(privyAuthorizationSignature != null ?
216
+ { 'privy-authorization-signature': privyAuthorizationSignature }
217
+ : undefined),
218
+ },
219
+ options?.headers,
220
+ ]),
221
+ });
222
+ }
223
+
224
+ /**
225
+ * Obtain a session key to enable wallet access.
226
+ *
227
+ * @example
228
+ * ```ts
229
+ * const response = await client.wallets.authenticateWithJwt({
230
+ * user_jwt:
231
+ * 'eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJzdWIiOiIxMjM0NTY3ODkwIiwibmFtZSI6IkpvaG4gRG9lIiwiYWRtaW4iOnRydWUsImlhdCI6MTUxNjIzOTAyMn0.KMUFsIDTnFmyG3nMiGM6H9FNFUROf3wh7SmqJp-QV30',
232
+ * });
233
+ * ```
234
+ */
235
+ authenticateWithJwt(
236
+ body: WalletAuthenticateWithJwtParams,
237
+ options?: RequestOptions,
238
+ ): APIPromise<WalletAuthenticateWithJwtResponse> {
239
+ return this._client.post('/v1/wallets/authenticate', { body, ...options });
240
+ }
241
+
242
+ /**
243
+ * Create wallets with an associated recovery user.
244
+ *
245
+ * @deprecated
246
+ */
247
+ createWalletsWithRecovery(
248
+ body: WalletCreateWalletsWithRecoveryParams,
249
+ options?: RequestOptions,
250
+ ): APIPromise<WalletCreateWalletsWithRecoveryResponse> {
251
+ return this._client.post('/v1/wallets_with_recovery', { body, ...options });
252
+ }
253
+
254
+ /**
255
+ * Get a wallet by wallet ID.
256
+ *
257
+ * @example
258
+ * ```ts
259
+ * const wallet = await client.wallets.get('wallet_id');
260
+ * ```
261
+ */
262
+ get(walletID: string, options?: RequestOptions): APIPromise<Wallet> {
263
+ return this._client.get(path`/v1/wallets/${walletID}`, options);
264
+ }
265
+ }
266
+
267
+ export type WalletsCursor = Cursor<Wallet>;
268
+
269
+ /**
270
+ * The wallet chain types that support curve-based signing.
271
+ */
272
+ export type CurveSigningChainType =
273
+ | 'cosmos'
274
+ | 'stellar'
275
+ | 'sui'
276
+ | 'aptos'
277
+ | 'movement'
278
+ | 'tron'
279
+ | 'bitcoin-segwit'
280
+ | 'near'
281
+ | 'ton'
282
+ | 'starknet';
283
+
284
+ /**
285
+ * The wallet chain types that offer first class support.
286
+ */
287
+ export type FirstClassChainType = 'solana' | 'ethereum';
288
+
289
+ export interface Wallet {
290
+ /**
291
+ * Unique ID of the wallet. This will be the primary identifier when using the
292
+ * wallet in the future.
293
+ */
294
+ id: string;
295
+
296
+ /**
297
+ * Additional signers for the wallet.
298
+ */
299
+ additional_signers: Array<Wallet.AdditionalSigner>;
300
+
301
+ /**
302
+ * Address of the wallet.
303
+ */
304
+ address: string;
305
+
306
+ /**
307
+ * The wallet chain types.
308
+ */
309
+ chain_type: WalletChainType;
310
+
311
+ /**
312
+ * Unix timestamp of when the wallet was created in milliseconds.
313
+ */
314
+ created_at: number;
315
+
316
+ /**
317
+ * Unix timestamp of when the wallet was exported in milliseconds, if the wallet
318
+ * was exported.
319
+ */
320
+ exported_at: number | null;
321
+
322
+ /**
323
+ * Unix timestamp of when the wallet was imported in milliseconds, if the wallet
324
+ * was imported.
325
+ */
326
+ imported_at: number | null;
327
+
328
+ /**
329
+ * The key quorum ID of the owner of the wallet.
330
+ */
331
+ owner_id: string | null;
332
+
333
+ /**
334
+ * List of policy IDs for policies that are enforced on the wallet.
335
+ */
336
+ policy_ids: Array<string>;
337
+
338
+ /**
339
+ * The compressed, raw public key for the wallet along the chain cryptographic
340
+ * curve.
341
+ */
342
+ public_key?: string;
343
+ }
344
+
345
+ export namespace Wallet {
346
+ export interface AdditionalSigner {
347
+ signer_id: string;
348
+
349
+ /**
350
+ * The array of policy IDs that will be applied to wallet requests. If specified,
351
+ * this will override the base policy IDs set on the wallet.
352
+ */
353
+ override_policy_ids?: Array<string>;
354
+ }
355
+ }
356
+
357
+ /**
358
+ * The wallet chain types.
359
+ */
360
+ export type WalletChainType =
361
+ | 'solana'
362
+ | 'ethereum'
363
+ | 'cosmos'
364
+ | 'stellar'
365
+ | 'sui'
366
+ | 'aptos'
367
+ | 'movement'
368
+ | 'tron'
369
+ | 'bitcoin-segwit'
370
+ | 'near'
371
+ | 'ton'
372
+ | 'starknet'
373
+ | 'spark';
374
+
375
+ /**
376
+ * The response body from revoking a wallet delegation.
377
+ */
378
+ export interface WalletRevokeResponse {
379
+ message: string;
380
+ }
381
+
382
+ export interface WalletExportResponse {
383
+ /**
384
+ * The encrypted private key.
385
+ */
386
+ ciphertext: string;
387
+
388
+ /**
389
+ * The base64-encoded encapsulated key that was generated during encryption, for
390
+ * use during decryption.
391
+ */
392
+ encapsulated_key: string;
393
+
394
+ /**
395
+ * The encryption type of the wallet to import. Currently only supports `HPKE`.
396
+ */
397
+ encryption_type: 'HPKE';
398
+ }
399
+
400
+ export interface WalletInitImportResponse {
401
+ /**
402
+ * The base64-encoded encryption public key to encrypt the wallet entropy with.
403
+ */
404
+ encryption_public_key: string;
405
+
406
+ /**
407
+ * The encryption type of the wallet to import. Currently only supports `HPKE`.
408
+ */
409
+ encryption_type: 'HPKE';
410
+ }
411
+
412
+ export interface WalletRawSignResponse {
413
+ data: WalletRawSignResponse.Data;
414
+ }
415
+
416
+ export namespace WalletRawSignResponse {
417
+ export interface Data {
418
+ encoding: 'hex';
419
+
420
+ signature: string;
421
+ }
422
+ }
423
+
424
+ export type WalletRpcResponse =
425
+ | WalletRpcResponse.SolanaSignTransactionRpcResponse
426
+ | WalletRpcResponse.SolanaSignAndSendTransactionRpcResponse
427
+ | WalletRpcResponse.SolanaSignMessageRpcResponse
428
+ | WalletRpcResponse.EthereumSignTransactionRpcResponse
429
+ | WalletRpcResponse.EthereumSendTransactionRpcResponse
430
+ | WalletRpcResponse.EthereumPersonalSignRpcResponse
431
+ | WalletRpcResponse.EthereumSignTypedDataRpcResponse
432
+ | WalletRpcResponse.EthereumSign7702AuthorizationRpcResponse
433
+ | WalletRpcResponse.EthereumSecp256k1SignRpcResponse;
434
+
435
+ export namespace WalletRpcResponse {
436
+ export interface SolanaSignTransactionRpcResponse {
437
+ data: SolanaSignTransactionRpcResponse.Data;
438
+
439
+ method: 'signTransaction';
440
+ }
441
+
442
+ export namespace SolanaSignTransactionRpcResponse {
443
+ export interface Data {
444
+ encoding: 'base64';
445
+
446
+ signed_transaction: string;
447
+ }
448
+ }
449
+
450
+ export interface SolanaSignAndSendTransactionRpcResponse {
451
+ data: SolanaSignAndSendTransactionRpcResponse.Data;
452
+
453
+ method: 'signAndSendTransaction';
454
+ }
455
+
456
+ export namespace SolanaSignAndSendTransactionRpcResponse {
457
+ export interface Data {
458
+ caip2: string;
459
+
460
+ hash: string;
461
+
462
+ transaction_id?: string;
463
+ }
464
+ }
465
+
466
+ export interface SolanaSignMessageRpcResponse {
467
+ data: SolanaSignMessageRpcResponse.Data;
468
+
469
+ method: 'signMessage';
470
+ }
471
+
472
+ export namespace SolanaSignMessageRpcResponse {
473
+ export interface Data {
474
+ encoding: 'base64';
475
+
476
+ signature: string;
477
+ }
478
+ }
479
+
480
+ export interface EthereumSignTransactionRpcResponse {
481
+ data: EthereumSignTransactionRpcResponse.Data;
482
+
483
+ method: 'eth_signTransaction';
484
+ }
485
+
486
+ export namespace EthereumSignTransactionRpcResponse {
487
+ export interface Data {
488
+ encoding: 'rlp';
489
+
490
+ signed_transaction: string;
491
+ }
492
+ }
493
+
494
+ export interface EthereumSendTransactionRpcResponse {
495
+ data: EthereumSendTransactionRpcResponse.Data;
496
+
497
+ method: 'eth_sendTransaction';
498
+ }
499
+
500
+ export namespace EthereumSendTransactionRpcResponse {
501
+ export interface Data {
502
+ caip2: string;
503
+
504
+ hash: string;
505
+
506
+ transaction_id?: string;
507
+
508
+ transaction_request?: Data.TransactionRequest;
509
+ }
510
+
511
+ export namespace Data {
512
+ export interface TransactionRequest {
513
+ chain_id?: string | number;
514
+
515
+ data?: string;
516
+
517
+ from?: string;
518
+
519
+ gas_limit?: string | number;
520
+
521
+ gas_price?: string | number;
522
+
523
+ max_fee_per_gas?: string | number;
524
+
525
+ max_priority_fee_per_gas?: string | number;
526
+
527
+ nonce?: string | number;
528
+
529
+ to?: string;
530
+
531
+ type?: 0 | 1 | 2;
532
+
533
+ value?: string | number;
534
+ }
535
+ }
536
+ }
537
+
538
+ export interface EthereumPersonalSignRpcResponse {
539
+ data: EthereumPersonalSignRpcResponse.Data;
540
+
541
+ method: 'personal_sign';
542
+ }
543
+
544
+ export namespace EthereumPersonalSignRpcResponse {
545
+ export interface Data {
546
+ encoding: 'hex';
547
+
548
+ signature: string;
549
+ }
550
+ }
551
+
552
+ export interface EthereumSignTypedDataRpcResponse {
553
+ data: EthereumSignTypedDataRpcResponse.Data;
554
+
555
+ method: 'eth_signTypedData_v4';
556
+ }
557
+
558
+ export namespace EthereumSignTypedDataRpcResponse {
559
+ export interface Data {
560
+ encoding: 'hex';
561
+
562
+ signature: string;
563
+ }
564
+ }
565
+
566
+ export interface EthereumSign7702AuthorizationRpcResponse {
567
+ data: EthereumSign7702AuthorizationRpcResponse.Data;
568
+
569
+ method: 'eth_sign7702Authorization';
570
+ }
571
+
572
+ export namespace EthereumSign7702AuthorizationRpcResponse {
573
+ export interface Data {
574
+ authorization: Data.Authorization;
575
+ }
576
+
577
+ export namespace Data {
578
+ export interface Authorization {
579
+ chain_id: string | number;
580
+
581
+ contract: string;
582
+
583
+ nonce: string | number;
584
+
585
+ r: string;
586
+
587
+ s: string;
588
+
589
+ y_parity: number;
590
+ }
591
+ }
592
+ }
593
+
594
+ export interface EthereumSecp256k1SignRpcResponse {
595
+ data: EthereumSecp256k1SignRpcResponse.Data;
596
+
597
+ method: 'secp256k1_sign';
598
+ }
599
+
600
+ export namespace EthereumSecp256k1SignRpcResponse {
601
+ export interface Data {
602
+ encoding: 'hex';
603
+
604
+ signature: string;
605
+ }
606
+ }
607
+ }
608
+
609
+ export type WalletAuthenticateWithJwtResponse =
610
+ | WalletAuthenticateWithJwtResponse.WithEncryption
611
+ | WalletAuthenticateWithJwtResponse.WithoutEncryption;
612
+
613
+ export namespace WalletAuthenticateWithJwtResponse {
614
+ export interface WithEncryption {
615
+ /**
616
+ * The encrypted authorization key data.
617
+ */
618
+ encrypted_authorization_key: WithEncryption.EncryptedAuthorizationKey;
619
+
620
+ /**
621
+ * The expiration time of the authorization key in seconds since the epoch.
622
+ */
623
+ expires_at: number;
624
+
625
+ wallets: Array<WalletsAPI.Wallet>;
626
+ }
627
+
628
+ export namespace WithEncryption {
629
+ /**
630
+ * The encrypted authorization key data.
631
+ */
632
+ export interface EncryptedAuthorizationKey {
633
+ /**
634
+ * The encrypted authorization key corresponding to the user's current
635
+ * authentication session.
636
+ */
637
+ ciphertext: string;
638
+
639
+ /**
640
+ * Base64-encoded ephemeral public key used in the HPKE encryption process.
641
+ * Required for decryption.
642
+ */
643
+ encapsulated_key: string;
644
+
645
+ /**
646
+ * The encryption type used. Currently only supports HPKE.
647
+ */
648
+ encryption_type: 'HPKE';
649
+ }
650
+ }
651
+
652
+ export interface WithoutEncryption {
653
+ /**
654
+ * The raw authorization key data.
655
+ */
656
+ authorization_key: string;
657
+
658
+ /**
659
+ * The expiration time of the authorization key in seconds since the epoch.
660
+ */
661
+ expires_at: number;
662
+
663
+ wallets: Array<WalletsAPI.Wallet>;
664
+ }
665
+ }
666
+
667
+ export interface WalletCreateWalletsWithRecoveryResponse {
668
+ /**
669
+ * The ID of the created user.
670
+ */
671
+ recovery_user_id: string;
672
+
673
+ /**
674
+ * The wallets that were created.
675
+ */
676
+ wallets: Array<Wallet>;
677
+ }
678
+
679
+ export interface WalletCreateParams {
680
+ /**
681
+ * Body param: The wallet chain types.
682
+ */
683
+ chain_type: WalletChainType;
684
+
685
+ /**
686
+ * Body param: Additional signers for the wallet.
687
+ */
688
+ additional_signers?: Array<WalletCreateParams.AdditionalSigner>;
689
+
690
+ /**
691
+ * Body param: The owner of the resource. If you provide this, do not specify an
692
+ * owner_id as it will be generated automatically. When updating a wallet, you can
693
+ * set the owner to null to remove the owner.
694
+ */
695
+ owner?: WalletCreateParams.PublicKeyOwner | WalletCreateParams.UserOwner | null;
696
+
697
+ /**
698
+ * Body param: The key quorum ID to set as the owner of the resource. If you
699
+ * provide this, do not specify an owner.
700
+ */
701
+ owner_id?: string;
702
+
703
+ /**
704
+ * Body param: List of policy IDs for policies that should be enforced on the
705
+ * wallet. Currently, only one policy is supported per wallet.
706
+ */
707
+ policy_ids?: Array<string>;
708
+
709
+ /**
710
+ * Header param: Idempotency keys ensure API requests are executed only once within
711
+ * a 24-hour window.
712
+ */
713
+ 'privy-idempotency-key'?: string;
714
+ }
715
+
716
+ export namespace WalletCreateParams {
717
+ export interface AdditionalSigner {
718
+ signer_id: string;
719
+
720
+ /**
721
+ * The array of policy IDs that will be applied to wallet requests. If specified,
722
+ * this will override the base policy IDs set on the wallet.
723
+ */
724
+ override_policy_ids?: Array<string>;
725
+ }
726
+
727
+ /**
728
+ * The P-256 public key of the owner of the resource. If you provide this, do not
729
+ * specify an owner_id as it will be generated automatically.
730
+ */
731
+ export interface PublicKeyOwner {
732
+ public_key: string;
733
+ }
734
+
735
+ /**
736
+ * The user ID of the owner of the resource. The user must already exist, and this
737
+ * value must start with "did:privy:". If you provide this, do not specify an
738
+ * owner_id as it will be generated automatically.
739
+ */
740
+ export interface UserOwner {
741
+ user_id: string;
742
+ }
743
+ }
744
+
745
+ export interface WalletListParams extends CursorParams {
746
+ chain_type?:
747
+ | 'cosmos'
748
+ | 'stellar'
749
+ | 'sui'
750
+ | 'aptos'
751
+ | 'movement'
752
+ | 'tron'
753
+ | 'bitcoin-segwit'
754
+ | 'near'
755
+ | 'ton'
756
+ | 'starknet'
757
+ | 'spark'
758
+ | 'solana'
759
+ | 'ethereum';
760
+
761
+ user_id?: string;
762
+ }
763
+
764
+ export interface WalletExportParams {
765
+ /**
766
+ * Body param: The encryption type of the wallet to import. Currently only supports
767
+ * `HPKE`.
768
+ */
769
+ encryption_type: 'HPKE';
770
+
771
+ /**
772
+ * Body param: The base64-encoded encryption public key to encrypt the wallet
773
+ * private key with.
774
+ */
775
+ recipient_public_key: string;
776
+
777
+ /**
778
+ * Header param: Request authorization signature. If multiple signatures are
779
+ * required, they should be comma separated.
780
+ */
781
+ 'privy-authorization-signature'?: string;
782
+ }
783
+
784
+ export type WalletInitImportParams =
785
+ | WalletInitImportParams.HDInitInput
786
+ | WalletInitImportParams.PrivateKeyInitInput;
787
+
788
+ export declare namespace WalletInitImportParams {
789
+ export interface HDInitInput {
790
+ /**
791
+ * The address of the wallet to import.
792
+ */
793
+ address: string;
794
+
795
+ /**
796
+ * The chain type of the wallet to import. Currently supports `ethereum` and
797
+ * `solana`.
798
+ */
799
+ chain_type: 'ethereum' | 'solana';
800
+
801
+ /**
802
+ * The encryption type of the wallet to import. Currently only supports `HPKE`.
803
+ */
804
+ encryption_type: 'HPKE';
805
+
806
+ /**
807
+ * The entropy type of the wallet to import.
808
+ */
809
+ entropy_type: 'hd';
810
+
811
+ /**
812
+ * The index of the wallet to import.
813
+ */
814
+ index: number;
815
+ }
816
+
817
+ export interface PrivateKeyInitInput {
818
+ /**
819
+ * The address of the wallet to import.
820
+ */
821
+ address: string;
822
+
823
+ /**
824
+ * The chain type of the wallet to import. Currently supports `ethereum` and
825
+ * `solana`.
826
+ */
827
+ chain_type: 'ethereum' | 'solana';
828
+
829
+ /**
830
+ * The encryption type of the wallet to import. Currently only supports `HPKE`.
831
+ */
832
+ encryption_type: 'HPKE';
833
+
834
+ entropy_type: 'private-key';
835
+ }
836
+ }
837
+
838
+ export interface WalletRawSignParams {
839
+ /**
840
+ * Body param:
841
+ */
842
+ params: WalletRawSignParams.Params;
843
+
844
+ /**
845
+ * Header param: Request authorization signature. If multiple signatures are
846
+ * required, they should be comma separated.
847
+ */
848
+ 'privy-authorization-signature'?: string;
849
+
850
+ /**
851
+ * Header param: Idempotency keys ensure API requests are executed only once within
852
+ * a 24-hour window.
853
+ */
854
+ 'privy-idempotency-key'?: string;
855
+ }
856
+
857
+ export namespace WalletRawSignParams {
858
+ export interface Params {
859
+ /**
860
+ * The hash to sign. Must start with `0x`.
861
+ */
862
+ hash?: string;
863
+ }
864
+ }
865
+
866
+ export type WalletRpcParams =
867
+ | WalletRpcParams.EthereumSignTransactionRpcInput
868
+ | WalletRpcParams.EthereumSendTransactionRpcInput
869
+ | WalletRpcParams.EthereumPersonalSignRpcInput
870
+ | WalletRpcParams.EthereumSignTypedDataRpcInput
871
+ | WalletRpcParams.EthereumSign7702AuthorizationRpcInput
872
+ | WalletRpcParams.EthereumSecp256k1SignRpcInput
873
+ | WalletRpcParams.SolanaSignTransactionRpcInput
874
+ | WalletRpcParams.SolanaSignAndSendTransactionRpcInput
875
+ | WalletRpcParams.SolanaSignMessageRpcInput;
876
+
877
+ export declare namespace WalletRpcParams {
878
+ export interface EthereumSignTransactionRpcInput {
879
+ /**
880
+ * Body param:
881
+ */
882
+ method: 'eth_signTransaction';
883
+
884
+ /**
885
+ * Body param:
886
+ */
887
+ params: EthereumSignTransactionRpcInput.Params;
888
+
889
+ /**
890
+ * Body param:
891
+ */
892
+ address?: string;
893
+
894
+ /**
895
+ * Body param:
896
+ */
897
+ chain_type?: 'ethereum';
898
+
899
+ /**
900
+ * Header param: Request authorization signature. If multiple signatures are
901
+ * required, they should be comma separated.
902
+ */
903
+ 'privy-authorization-signature'?: string;
904
+
905
+ /**
906
+ * Header param: Idempotency keys ensure API requests are executed only once within
907
+ * a 24-hour window.
908
+ */
909
+ 'privy-idempotency-key'?: string;
910
+ }
911
+
912
+ export namespace EthereumSignTransactionRpcInput {
913
+ export interface Params {
914
+ transaction: Params.Transaction;
915
+ }
916
+
917
+ export namespace Params {
918
+ export interface Transaction {
919
+ chain_id?: string | number;
920
+
921
+ data?: string;
922
+
923
+ from?: string;
924
+
925
+ gas_limit?: string | number;
926
+
927
+ gas_price?: string | number;
928
+
929
+ max_fee_per_gas?: string | number;
930
+
931
+ max_priority_fee_per_gas?: string | number;
932
+
933
+ nonce?: string | number;
934
+
935
+ to?: string;
936
+
937
+ type?: 0 | 1 | 2;
938
+
939
+ value?: string | number;
940
+ }
941
+ }
942
+ }
943
+
944
+ export interface EthereumSendTransactionRpcInput {
945
+ /**
946
+ * Body param:
947
+ */
948
+ caip2: string;
949
+
950
+ /**
951
+ * Body param:
952
+ */
953
+ method: 'eth_sendTransaction';
954
+
955
+ /**
956
+ * Body param:
957
+ */
958
+ params: EthereumSendTransactionRpcInput.Params;
959
+
960
+ /**
961
+ * Body param:
962
+ */
963
+ address?: string;
964
+
965
+ /**
966
+ * Body param:
967
+ */
968
+ chain_type?: 'ethereum';
969
+
970
+ /**
971
+ * Body param:
972
+ */
973
+ sponsor?: boolean;
974
+
975
+ /**
976
+ * Header param: Request authorization signature. If multiple signatures are
977
+ * required, they should be comma separated.
978
+ */
979
+ 'privy-authorization-signature'?: string;
980
+
981
+ /**
982
+ * Header param: Idempotency keys ensure API requests are executed only once within
983
+ * a 24-hour window.
984
+ */
985
+ 'privy-idempotency-key'?: string;
986
+ }
987
+
988
+ export namespace EthereumSendTransactionRpcInput {
989
+ export interface Params {
990
+ transaction: Params.Transaction;
991
+ }
992
+
993
+ export namespace Params {
994
+ export interface Transaction {
995
+ chain_id?: string | number;
996
+
997
+ data?: string;
998
+
999
+ from?: string;
1000
+
1001
+ gas_limit?: string | number;
1002
+
1003
+ gas_price?: string | number;
1004
+
1005
+ max_fee_per_gas?: string | number;
1006
+
1007
+ max_priority_fee_per_gas?: string | number;
1008
+
1009
+ nonce?: string | number;
1010
+
1011
+ to?: string;
1012
+
1013
+ type?: 0 | 1 | 2;
1014
+
1015
+ value?: string | number;
1016
+ }
1017
+ }
1018
+ }
1019
+
1020
+ export interface EthereumPersonalSignRpcInput {
1021
+ /**
1022
+ * Body param:
1023
+ */
1024
+ method: 'personal_sign';
1025
+
1026
+ /**
1027
+ * Body param:
1028
+ */
1029
+ params: EthereumPersonalSignRpcInput.Params;
1030
+
1031
+ /**
1032
+ * Body param:
1033
+ */
1034
+ address?: string;
1035
+
1036
+ /**
1037
+ * Body param:
1038
+ */
1039
+ chain_type?: 'ethereum';
1040
+
1041
+ /**
1042
+ * Header param: Request authorization signature. If multiple signatures are
1043
+ * required, they should be comma separated.
1044
+ */
1045
+ 'privy-authorization-signature'?: string;
1046
+
1047
+ /**
1048
+ * Header param: Idempotency keys ensure API requests are executed only once within
1049
+ * a 24-hour window.
1050
+ */
1051
+ 'privy-idempotency-key'?: string;
1052
+ }
1053
+
1054
+ export namespace EthereumPersonalSignRpcInput {
1055
+ export interface Params {
1056
+ encoding: 'utf-8' | 'hex';
1057
+
1058
+ message: string;
1059
+ }
1060
+ }
1061
+
1062
+ export interface EthereumSignTypedDataRpcInput {
1063
+ /**
1064
+ * Body param:
1065
+ */
1066
+ method: 'eth_signTypedData_v4';
1067
+
1068
+ /**
1069
+ * Body param:
1070
+ */
1071
+ params: EthereumSignTypedDataRpcInput.Params;
1072
+
1073
+ /**
1074
+ * Body param:
1075
+ */
1076
+ address?: string;
1077
+
1078
+ /**
1079
+ * Body param:
1080
+ */
1081
+ chain_type?: 'ethereum';
1082
+
1083
+ /**
1084
+ * Header param: Request authorization signature. If multiple signatures are
1085
+ * required, they should be comma separated.
1086
+ */
1087
+ 'privy-authorization-signature'?: string;
1088
+
1089
+ /**
1090
+ * Header param: Idempotency keys ensure API requests are executed only once within
1091
+ * a 24-hour window.
1092
+ */
1093
+ 'privy-idempotency-key'?: string;
1094
+ }
1095
+
1096
+ export namespace EthereumSignTypedDataRpcInput {
1097
+ export interface Params {
1098
+ typed_data: Params.TypedData;
1099
+ }
1100
+
1101
+ export namespace Params {
1102
+ export interface TypedData {
1103
+ domain: { [key: string]: unknown };
1104
+
1105
+ message: { [key: string]: unknown };
1106
+
1107
+ primary_type: string;
1108
+
1109
+ types: { [key: string]: Array<TypedData.Type> };
1110
+ }
1111
+
1112
+ export namespace TypedData {
1113
+ export interface Type {
1114
+ name: string;
1115
+
1116
+ type: string;
1117
+ }
1118
+ }
1119
+ }
1120
+ }
1121
+
1122
+ export interface EthereumSign7702AuthorizationRpcInput {
1123
+ /**
1124
+ * Body param:
1125
+ */
1126
+ method: 'eth_sign7702Authorization';
1127
+
1128
+ /**
1129
+ * Body param:
1130
+ */
1131
+ params: EthereumSign7702AuthorizationRpcInput.Params;
1132
+
1133
+ /**
1134
+ * Body param:
1135
+ */
1136
+ address?: string;
1137
+
1138
+ /**
1139
+ * Body param:
1140
+ */
1141
+ chain_type?: 'ethereum';
1142
+
1143
+ /**
1144
+ * Header param: Request authorization signature. If multiple signatures are
1145
+ * required, they should be comma separated.
1146
+ */
1147
+ 'privy-authorization-signature'?: string;
1148
+
1149
+ /**
1150
+ * Header param: Idempotency keys ensure API requests are executed only once within
1151
+ * a 24-hour window.
1152
+ */
1153
+ 'privy-idempotency-key'?: string;
1154
+ }
1155
+
1156
+ export namespace EthereumSign7702AuthorizationRpcInput {
1157
+ export interface Params {
1158
+ chain_id: string | number;
1159
+
1160
+ contract: string;
1161
+
1162
+ nonce?: string | number;
1163
+ }
1164
+ }
1165
+
1166
+ export interface EthereumSecp256k1SignRpcInput {
1167
+ /**
1168
+ * Body param:
1169
+ */
1170
+ method: 'secp256k1_sign';
1171
+
1172
+ /**
1173
+ * Body param:
1174
+ */
1175
+ params: EthereumSecp256k1SignRpcInput.Params;
1176
+
1177
+ /**
1178
+ * Body param:
1179
+ */
1180
+ address?: string;
1181
+
1182
+ /**
1183
+ * Body param:
1184
+ */
1185
+ chain_type?: 'ethereum';
1186
+
1187
+ /**
1188
+ * Header param: Request authorization signature. If multiple signatures are
1189
+ * required, they should be comma separated.
1190
+ */
1191
+ 'privy-authorization-signature'?: string;
1192
+
1193
+ /**
1194
+ * Header param: Idempotency keys ensure API requests are executed only once within
1195
+ * a 24-hour window.
1196
+ */
1197
+ 'privy-idempotency-key'?: string;
1198
+ }
1199
+
1200
+ export namespace EthereumSecp256k1SignRpcInput {
1201
+ export interface Params {
1202
+ hash: string;
1203
+ }
1204
+ }
1205
+
1206
+ export interface SolanaSignTransactionRpcInput {
1207
+ /**
1208
+ * Body param:
1209
+ */
1210
+ method: 'signTransaction';
1211
+
1212
+ /**
1213
+ * Body param:
1214
+ */
1215
+ params: SolanaSignTransactionRpcInput.Params;
1216
+
1217
+ /**
1218
+ * Body param:
1219
+ */
1220
+ address?: string;
1221
+
1222
+ /**
1223
+ * Body param:
1224
+ */
1225
+ chain_type?: 'solana';
1226
+
1227
+ /**
1228
+ * Header param: Request authorization signature. If multiple signatures are
1229
+ * required, they should be comma separated.
1230
+ */
1231
+ 'privy-authorization-signature'?: string;
1232
+
1233
+ /**
1234
+ * Header param: Idempotency keys ensure API requests are executed only once within
1235
+ * a 24-hour window.
1236
+ */
1237
+ 'privy-idempotency-key'?: string;
1238
+ }
1239
+
1240
+ export namespace SolanaSignTransactionRpcInput {
1241
+ export interface Params {
1242
+ encoding: 'base64';
1243
+
1244
+ transaction: string;
1245
+ }
1246
+ }
1247
+
1248
+ export interface SolanaSignAndSendTransactionRpcInput {
1249
+ /**
1250
+ * Body param:
1251
+ */
1252
+ caip2: string;
1253
+
1254
+ /**
1255
+ * Body param:
1256
+ */
1257
+ method: 'signAndSendTransaction';
1258
+
1259
+ /**
1260
+ * Body param:
1261
+ */
1262
+ params: SolanaSignAndSendTransactionRpcInput.Params;
1263
+
1264
+ /**
1265
+ * Body param:
1266
+ */
1267
+ address?: string;
1268
+
1269
+ /**
1270
+ * Body param:
1271
+ */
1272
+ chain_type?: 'solana';
1273
+
1274
+ /**
1275
+ * Body param:
1276
+ */
1277
+ sponsor?: boolean;
1278
+
1279
+ /**
1280
+ * Header param: Request authorization signature. If multiple signatures are
1281
+ * required, they should be comma separated.
1282
+ */
1283
+ 'privy-authorization-signature'?: string;
1284
+
1285
+ /**
1286
+ * Header param: Idempotency keys ensure API requests are executed only once within
1287
+ * a 24-hour window.
1288
+ */
1289
+ 'privy-idempotency-key'?: string;
1290
+ }
1291
+
1292
+ export namespace SolanaSignAndSendTransactionRpcInput {
1293
+ export interface Params {
1294
+ encoding: 'base64';
1295
+
1296
+ transaction: string;
1297
+ }
1298
+ }
1299
+
1300
+ export interface SolanaSignMessageRpcInput {
1301
+ /**
1302
+ * Body param:
1303
+ */
1304
+ method: 'signMessage';
1305
+
1306
+ /**
1307
+ * Body param:
1308
+ */
1309
+ params: SolanaSignMessageRpcInput.Params;
1310
+
1311
+ /**
1312
+ * Body param:
1313
+ */
1314
+ address?: string;
1315
+
1316
+ /**
1317
+ * Body param:
1318
+ */
1319
+ chain_type?: 'solana';
1320
+
1321
+ /**
1322
+ * Header param: Request authorization signature. If multiple signatures are
1323
+ * required, they should be comma separated.
1324
+ */
1325
+ 'privy-authorization-signature'?: string;
1326
+
1327
+ /**
1328
+ * Header param: Idempotency keys ensure API requests are executed only once within
1329
+ * a 24-hour window.
1330
+ */
1331
+ 'privy-idempotency-key'?: string;
1332
+ }
1333
+
1334
+ export namespace SolanaSignMessageRpcInput {
1335
+ export interface Params {
1336
+ encoding: 'base64';
1337
+
1338
+ message: string;
1339
+ }
1340
+ }
1341
+ }
1342
+
1343
+ export interface WalletSubmitImportParams {
1344
+ wallet: WalletSubmitImportParams.HDSubmitInput | WalletSubmitImportParams.PrivateKeySubmitInput;
1345
+
1346
+ additional_signers?: Array<WalletSubmitImportParams.AdditionalSigner>;
1347
+
1348
+ owner?: WalletSubmitImportParams.UserID | WalletSubmitImportParams.PublicKey | null;
1349
+
1350
+ owner_id?: string | null;
1351
+
1352
+ policy_ids?: Array<string>;
1353
+ }
1354
+
1355
+ export namespace WalletSubmitImportParams {
1356
+ export interface HDSubmitInput {
1357
+ /**
1358
+ * The address of the wallet to import.
1359
+ */
1360
+ address: string;
1361
+
1362
+ /**
1363
+ * The chain type of the wallet to import. Currently supports `ethereum` and
1364
+ * `solana`.
1365
+ */
1366
+ chain_type: 'ethereum' | 'solana';
1367
+
1368
+ /**
1369
+ * The encrypted entropy of the wallet to import.
1370
+ */
1371
+ ciphertext: string;
1372
+
1373
+ /**
1374
+ * The base64-encoded encapsulated key that was generated during encryption, for
1375
+ * use during decryption inside the TEE.
1376
+ */
1377
+ encapsulated_key: string;
1378
+
1379
+ /**
1380
+ * The encryption type of the wallet to import. Currently only supports `HPKE`.
1381
+ */
1382
+ encryption_type: 'HPKE';
1383
+
1384
+ /**
1385
+ * The entropy type of the wallet to import.
1386
+ */
1387
+ entropy_type: 'hd';
1388
+
1389
+ /**
1390
+ * The index of the wallet to import.
1391
+ */
1392
+ index: number;
1393
+ }
1394
+
1395
+ export interface PrivateKeySubmitInput {
1396
+ /**
1397
+ * The address of the wallet to import.
1398
+ */
1399
+ address: string;
1400
+
1401
+ /**
1402
+ * The chain type of the wallet to import. Currently supports `ethereum` and
1403
+ * `solana`.
1404
+ */
1405
+ chain_type: 'ethereum' | 'solana';
1406
+
1407
+ /**
1408
+ * The encrypted entropy of the wallet to import.
1409
+ */
1410
+ ciphertext: string;
1411
+
1412
+ /**
1413
+ * The base64-encoded encapsulated key that was generated during encryption, for
1414
+ * use during decryption inside the TEE.
1415
+ */
1416
+ encapsulated_key: string;
1417
+
1418
+ /**
1419
+ * The encryption type of the wallet to import. Currently only supports `HPKE`.
1420
+ */
1421
+ encryption_type: 'HPKE';
1422
+
1423
+ entropy_type: 'private-key';
1424
+ }
1425
+
1426
+ export interface AdditionalSigner {
1427
+ signer_id: string;
1428
+
1429
+ override_policy_ids?: Array<string>;
1430
+ }
1431
+
1432
+ export interface UserID {
1433
+ user_id: string;
1434
+ }
1435
+
1436
+ export interface PublicKey {
1437
+ public_key: string;
1438
+ }
1439
+ }
1440
+
1441
+ export interface WalletUpdateParams {
1442
+ /**
1443
+ * Body param: Additional signers for the wallet.
1444
+ */
1445
+ additional_signers?: Array<WalletUpdateParams.AdditionalSigner>;
1446
+
1447
+ /**
1448
+ * Body param: The owner of the resource. If you provide this, do not specify an
1449
+ * owner_id as it will be generated automatically. When updating a wallet, you can
1450
+ * set the owner to null to remove the owner.
1451
+ */
1452
+ owner?: WalletUpdateParams.PublicKeyOwner | WalletUpdateParams.UserOwner | null;
1453
+
1454
+ /**
1455
+ * Body param: The key quorum ID to set as the owner of the resource. If you
1456
+ * provide this, do not specify an owner.
1457
+ */
1458
+ owner_id?: string | null;
1459
+
1460
+ /**
1461
+ * Body param: New policy IDs to enforce on the wallet. Currently, only one policy
1462
+ * is supported per wallet.
1463
+ */
1464
+ policy_ids?: Array<string>;
1465
+
1466
+ /**
1467
+ * Header param: Request authorization signature. If multiple signatures are
1468
+ * required, they should be comma separated.
1469
+ */
1470
+ 'privy-authorization-signature'?: string;
1471
+ }
1472
+
1473
+ export namespace WalletUpdateParams {
1474
+ export interface AdditionalSigner {
1475
+ signer_id: string;
1476
+
1477
+ /**
1478
+ * The array of policy IDs that will be applied to wallet requests. If specified,
1479
+ * this will override the base policy IDs set on the wallet.
1480
+ */
1481
+ override_policy_ids?: Array<string>;
1482
+ }
1483
+
1484
+ /**
1485
+ * The P-256 public key of the owner of the resource. If you provide this, do not
1486
+ * specify an owner_id as it will be generated automatically.
1487
+ */
1488
+ export interface PublicKeyOwner {
1489
+ public_key: string;
1490
+ }
1491
+
1492
+ /**
1493
+ * The user ID of the owner of the resource. The user must already exist, and this
1494
+ * value must start with "did:privy:". If you provide this, do not specify an
1495
+ * owner_id as it will be generated automatically.
1496
+ */
1497
+ export interface UserOwner {
1498
+ user_id: string;
1499
+ }
1500
+ }
1501
+
1502
+ export interface WalletAuthenticateWithJwtParams {
1503
+ /**
1504
+ * The user's JWT, to be used to authenticate the user.
1505
+ */
1506
+ user_jwt: string;
1507
+
1508
+ /**
1509
+ * The encryption type for the authentication response. Currently only supports
1510
+ * HPKE.
1511
+ */
1512
+ encryption_type?: 'HPKE';
1513
+
1514
+ /**
1515
+ * The public key of your ECDH keypair, in base64-encoded, SPKI-format, whose
1516
+ * private key will be able to decrypt the session key.
1517
+ */
1518
+ recipient_public_key?: string;
1519
+ }
1520
+
1521
+ export interface WalletCreateWalletsWithRecoveryParams {
1522
+ primary_signer: WalletCreateWalletsWithRecoveryParams.PrimarySigner;
1523
+
1524
+ recovery_user: WalletCreateWalletsWithRecoveryParams.RecoveryUser;
1525
+
1526
+ wallets: Array<WalletCreateWalletsWithRecoveryParams.Wallet>;
1527
+ }
1528
+
1529
+ export namespace WalletCreateWalletsWithRecoveryParams {
1530
+ export interface PrimarySigner {
1531
+ /**
1532
+ * The JWT subject ID of the user.
1533
+ */
1534
+ subject_id: string;
1535
+ }
1536
+
1537
+ export interface RecoveryUser {
1538
+ linked_accounts: Array<RecoveryUser.UnionMember0 | RecoveryUser.UnionMember1>;
1539
+ }
1540
+
1541
+ export namespace RecoveryUser {
1542
+ export interface UnionMember0 {
1543
+ /**
1544
+ * The email address of the user.
1545
+ */
1546
+ address: string;
1547
+
1548
+ type: 'email';
1549
+ }
1550
+
1551
+ export interface UnionMember1 {
1552
+ /**
1553
+ * The JWT subject ID of the user.
1554
+ */
1555
+ custom_user_id: string;
1556
+
1557
+ type: 'custom_auth';
1558
+ }
1559
+ }
1560
+
1561
+ export interface Wallet {
1562
+ /**
1563
+ * The wallet chain types.
1564
+ */
1565
+ chain_type: WalletsAPI.WalletChainType;
1566
+
1567
+ /**
1568
+ * List of policy IDs for policies that should be enforced on the wallet.
1569
+ * Currently, only one policy is supported per wallet.
1570
+ */
1571
+ policy_ids?: Array<string>;
1572
+ }
1573
+ }
1574
+
1575
+ Wallets.Transactions = Transactions;
1576
+ Wallets.Balance = Balance;
1577
+
1578
+ export declare namespace Wallets {
1579
+ export {
1580
+ type CurveSigningChainType as CurveSigningChainType,
1581
+ type FirstClassChainType as FirstClassChainType,
1582
+ type Wallet as Wallet,
1583
+ type WalletChainType as WalletChainType,
1584
+ type WalletRevokeResponse as WalletRevokeResponse,
1585
+ type WalletExportResponse as WalletExportResponse,
1586
+ type WalletInitImportResponse as WalletInitImportResponse,
1587
+ type WalletRawSignResponse as WalletRawSignResponse,
1588
+ type WalletRpcResponse as WalletRpcResponse,
1589
+ type WalletAuthenticateWithJwtResponse as WalletAuthenticateWithJwtResponse,
1590
+ type WalletCreateWalletsWithRecoveryResponse as WalletCreateWalletsWithRecoveryResponse,
1591
+ type WalletsCursor as WalletsCursor,
1592
+ type WalletCreateParams as WalletCreateParams,
1593
+ type WalletListParams as WalletListParams,
1594
+ type WalletExportParams as WalletExportParams,
1595
+ type WalletInitImportParams as WalletInitImportParams,
1596
+ type WalletRawSignParams as WalletRawSignParams,
1597
+ type WalletRpcParams as WalletRpcParams,
1598
+ type WalletSubmitImportParams as WalletSubmitImportParams,
1599
+ type WalletUpdateParams as WalletUpdateParams,
1600
+ type WalletAuthenticateWithJwtParams as WalletAuthenticateWithJwtParams,
1601
+ type WalletCreateWalletsWithRecoveryParams as WalletCreateWalletsWithRecoveryParams,
1602
+ };
1603
+
1604
+ export {
1605
+ Transactions as Transactions,
1606
+ type TransactionGetResponse as TransactionGetResponse,
1607
+ type TransactionGetParams as TransactionGetParams,
1608
+ };
1609
+
1610
+ export {
1611
+ Balance as Balance,
1612
+ type BalanceGetResponse as BalanceGetResponse,
1613
+ type BalanceGetParams as BalanceGetParams,
1614
+ };
1615
+ }