agentmail 0.5.20 → 0.5.21

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (309) hide show
  1. package/dist/cjs/BaseClient.js +2 -2
  2. package/dist/cjs/api/resources/apiKeys/client/Client.d.ts +78 -0
  3. package/dist/cjs/api/resources/apiKeys/client/Client.js +362 -0
  4. package/dist/cjs/api/resources/apiKeys/client/requests/ListBrowserConsentsRequest.d.ts +12 -0
  5. package/dist/cjs/api/resources/apiKeys/client/requests/ListBrowserConsentsRequest.js +3 -0
  6. package/dist/cjs/api/resources/apiKeys/client/requests/ListBrowserCredentialEventsRequest.d.ts +9 -0
  7. package/dist/cjs/api/resources/apiKeys/client/requests/ListBrowserCredentialEventsRequest.js +3 -0
  8. package/dist/cjs/api/resources/apiKeys/client/requests/ListBrowserCredentialsRequest.d.ts +9 -0
  9. package/dist/cjs/api/resources/apiKeys/client/requests/ListBrowserCredentialsRequest.js +3 -0
  10. package/dist/cjs/api/resources/apiKeys/client/requests/index.d.ts +3 -0
  11. package/dist/cjs/api/resources/apiKeys/types/BrowserAuthorizationListLimit.d.ts +1 -0
  12. package/dist/cjs/api/resources/apiKeys/types/BrowserAuthorizationListLimit.js +3 -0
  13. package/dist/cjs/api/resources/apiKeys/types/BrowserConsent.d.ts +16 -0
  14. package/dist/cjs/api/resources/apiKeys/types/BrowserConsent.js +3 -0
  15. package/dist/cjs/api/resources/apiKeys/types/BrowserConsentLifecycleEvent.d.ts +13 -0
  16. package/dist/cjs/api/resources/apiKeys/types/BrowserConsentLifecycleEvent.js +3 -0
  17. package/dist/cjs/api/resources/apiKeys/types/BrowserConsentLifecycleEventType.d.ts +7 -0
  18. package/dist/cjs/api/resources/apiKeys/types/BrowserConsentLifecycleEventType.js +10 -0
  19. package/dist/cjs/api/resources/apiKeys/types/BrowserCredential.d.ts +14 -0
  20. package/dist/cjs/api/resources/apiKeys/types/BrowserCredential.js +3 -0
  21. package/dist/cjs/api/resources/apiKeys/types/BrowserCredentialCreator.d.ts +7 -0
  22. package/dist/cjs/api/resources/apiKeys/types/BrowserCredentialCreator.js +3 -0
  23. package/dist/cjs/api/resources/apiKeys/types/BrowserEnrollmentAccepted.d.ts +11 -0
  24. package/dist/cjs/api/resources/apiKeys/types/BrowserEnrollmentAccepted.js +3 -0
  25. package/dist/cjs/api/resources/apiKeys/types/BrowserEnrollmentLifecycleEvent.d.ts +12 -0
  26. package/dist/cjs/api/resources/apiKeys/types/BrowserEnrollmentLifecycleEvent.js +3 -0
  27. package/dist/cjs/api/resources/apiKeys/types/BrowserEnrollmentLifecycleEventType.d.ts +7 -0
  28. package/dist/cjs/api/resources/apiKeys/types/BrowserEnrollmentLifecycleEventType.js +10 -0
  29. package/dist/cjs/api/resources/apiKeys/types/BrowserEnrollmentTransactionJti.d.ts +4 -0
  30. package/dist/cjs/api/resources/apiKeys/types/BrowserEnrollmentTransactionJti.js +3 -0
  31. package/dist/cjs/api/resources/apiKeys/types/BrowserLifecycleActor.d.ts +10 -0
  32. package/dist/cjs/api/resources/apiKeys/types/BrowserLifecycleActor.js +3 -0
  33. package/dist/cjs/api/resources/apiKeys/types/BrowserLifecycleApiKeyActor.d.ts +3 -0
  34. package/dist/cjs/api/resources/apiKeys/types/BrowserLifecycleApiKeyActor.js +3 -0
  35. package/dist/cjs/api/resources/apiKeys/types/BrowserLifecycleCredentialActor.d.ts +4 -0
  36. package/dist/cjs/api/resources/apiKeys/types/BrowserLifecycleCredentialActor.js +3 -0
  37. package/dist/cjs/api/resources/apiKeys/types/BrowserLifecycleEvent.d.ts +2 -0
  38. package/dist/cjs/api/resources/apiKeys/types/BrowserLifecycleEvent.js +3 -0
  39. package/dist/cjs/api/resources/apiKeys/types/CreateBrowserEnrollmentRequest.d.ts +9 -0
  40. package/dist/cjs/api/resources/apiKeys/types/CreateBrowserEnrollmentRequest.js +3 -0
  41. package/dist/cjs/api/resources/apiKeys/types/ListBrowserConsentsResponse.d.ts +7 -0
  42. package/dist/cjs/api/resources/apiKeys/types/ListBrowserConsentsResponse.js +3 -0
  43. package/dist/cjs/api/resources/apiKeys/types/ListBrowserCredentialsResponse.d.ts +7 -0
  44. package/dist/cjs/api/resources/apiKeys/types/ListBrowserCredentialsResponse.js +3 -0
  45. package/dist/cjs/api/resources/apiKeys/types/ListBrowserLifecycleEventsResponse.d.ts +7 -0
  46. package/dist/cjs/api/resources/apiKeys/types/ListBrowserLifecycleEventsResponse.js +3 -0
  47. package/dist/cjs/api/resources/apiKeys/types/index.d.ts +18 -0
  48. package/dist/cjs/api/resources/apiKeys/types/index.js +18 -0
  49. package/dist/cjs/api/resources/attachments/types/SendAttachment.d.ts +9 -2
  50. package/dist/cjs/api/resources/domains/client/Client.d.ts +17 -0
  51. package/dist/cjs/api/resources/domains/client/Client.js +100 -0
  52. package/dist/cjs/api/resources/domains/types/Domain.d.ts +2 -0
  53. package/dist/cjs/api/resources/domains/types/GetSetupLinkResponse.d.ts +16 -0
  54. package/dist/cjs/api/resources/domains/types/GetSetupLinkResponse.js +3 -0
  55. package/dist/cjs/api/resources/domains/types/VerificationRecord.d.ts +2 -0
  56. package/dist/cjs/api/resources/domains/types/index.d.ts +1 -0
  57. package/dist/cjs/api/resources/domains/types/index.js +1 -0
  58. package/dist/cjs/api/resources/inboxes/client/Client.d.ts +3 -0
  59. package/dist/cjs/api/resources/inboxes/client/Client.js +19 -14
  60. package/dist/cjs/api/resources/inboxes/resources/apiKeys/client/Client.d.ts +3 -3
  61. package/dist/cjs/api/resources/inboxes/resources/apiKeys/client/Client.js +3 -3
  62. package/dist/cjs/api/resources/inboxes/resources/browserCredentials/client/Client.d.ts +55 -0
  63. package/dist/cjs/api/resources/inboxes/resources/browserCredentials/client/Client.js +175 -0
  64. package/dist/cjs/api/resources/inboxes/resources/browserCredentials/client/index.d.ts +1 -0
  65. package/dist/cjs/api/resources/inboxes/resources/browserCredentials/client/index.js +2 -0
  66. package/dist/cjs/api/resources/inboxes/resources/browserCredentials/exports.d.ts +2 -0
  67. package/dist/cjs/api/resources/inboxes/resources/browserCredentials/exports.js +21 -0
  68. package/dist/cjs/api/resources/inboxes/resources/browserCredentials/index.d.ts +1 -0
  69. package/dist/cjs/api/resources/inboxes/resources/browserCredentials/index.js +17 -0
  70. package/dist/cjs/api/resources/inboxes/resources/drafts/client/Client.d.ts +7 -7
  71. package/dist/cjs/api/resources/inboxes/resources/drafts/client/Client.js +7 -7
  72. package/dist/cjs/api/resources/inboxes/resources/events/client/Client.d.ts +1 -1
  73. package/dist/cjs/api/resources/inboxes/resources/events/client/Client.js +1 -1
  74. package/dist/cjs/api/resources/inboxes/resources/index.d.ts +1 -0
  75. package/dist/cjs/api/resources/inboxes/resources/index.js +2 -1
  76. package/dist/cjs/api/resources/inboxes/resources/lists/client/Client.d.ts +4 -4
  77. package/dist/cjs/api/resources/inboxes/resources/lists/client/Client.js +4 -4
  78. package/dist/cjs/api/resources/inboxes/resources/messages/client/Client.d.ts +12 -12
  79. package/dist/cjs/api/resources/inboxes/resources/messages/client/Client.js +12 -12
  80. package/dist/cjs/api/resources/inboxes/resources/metrics/client/Client.d.ts +1 -1
  81. package/dist/cjs/api/resources/inboxes/resources/metrics/client/Client.js +1 -1
  82. package/dist/cjs/api/resources/inboxes/resources/threads/client/Client.d.ts +4 -4
  83. package/dist/cjs/api/resources/inboxes/resources/threads/client/Client.js +4 -4
  84. package/dist/cjs/api/resources/inboxes/resources/webhooks/client/Client.d.ts +5 -5
  85. package/dist/cjs/api/resources/inboxes/resources/webhooks/client/Client.js +5 -5
  86. package/dist/cjs/api/resources/metrics/client/Client.d.ts +1 -1
  87. package/dist/cjs/api/resources/metrics/client/Client.js +1 -1
  88. package/dist/cjs/api/resources/pods/resources/apiKeys/client/Client.d.ts +3 -3
  89. package/dist/cjs/api/resources/pods/resources/apiKeys/client/Client.js +3 -3
  90. package/dist/cjs/api/resources/pods/resources/domains/client/Client.d.ts +7 -7
  91. package/dist/cjs/api/resources/pods/resources/domains/client/Client.js +7 -7
  92. package/dist/cjs/api/resources/pods/resources/drafts/client/Client.d.ts +3 -3
  93. package/dist/cjs/api/resources/pods/resources/drafts/client/Client.js +3 -3
  94. package/dist/cjs/api/resources/pods/resources/inboxes/client/Client.d.ts +5 -5
  95. package/dist/cjs/api/resources/pods/resources/inboxes/client/Client.js +5 -5
  96. package/dist/cjs/api/resources/pods/resources/lists/client/Client.d.ts +4 -4
  97. package/dist/cjs/api/resources/pods/resources/lists/client/Client.js +4 -4
  98. package/dist/cjs/api/resources/pods/resources/metrics/client/Client.d.ts +1 -1
  99. package/dist/cjs/api/resources/pods/resources/metrics/client/Client.js +1 -1
  100. package/dist/cjs/api/resources/pods/resources/threads/client/Client.d.ts +4 -4
  101. package/dist/cjs/api/resources/pods/resources/threads/client/Client.js +4 -4
  102. package/dist/cjs/api/resources/pods/resources/webhooks/client/Client.d.ts +5 -5
  103. package/dist/cjs/api/resources/pods/resources/webhooks/client/Client.js +5 -5
  104. package/dist/cjs/api/resources/webhooks/client/Client.d.ts +2 -2
  105. package/dist/cjs/api/resources/webhooks/client/Client.js +2 -2
  106. package/dist/cjs/serialization/resources/apiKeys/types/BrowserAuthorizationListLimit.d.ts +7 -0
  107. package/dist/cjs/serialization/resources/apiKeys/types/BrowserAuthorizationListLimit.js +39 -0
  108. package/dist/cjs/serialization/resources/apiKeys/types/BrowserConsent.d.ts +17 -0
  109. package/dist/cjs/serialization/resources/apiKeys/types/BrowserConsent.js +49 -0
  110. package/dist/cjs/serialization/resources/apiKeys/types/BrowserConsentLifecycleEvent.d.ts +20 -0
  111. package/dist/cjs/serialization/resources/apiKeys/types/BrowserConsentLifecycleEvent.js +52 -0
  112. package/dist/cjs/serialization/resources/apiKeys/types/BrowserConsentLifecycleEventType.d.ts +7 -0
  113. package/dist/cjs/serialization/resources/apiKeys/types/BrowserConsentLifecycleEventType.js +44 -0
  114. package/dist/cjs/serialization/resources/apiKeys/types/BrowserCredential.d.ts +17 -0
  115. package/dist/cjs/serialization/resources/apiKeys/types/BrowserCredential.js +49 -0
  116. package/dist/cjs/serialization/resources/apiKeys/types/BrowserCredentialCreator.d.ts +11 -0
  117. package/dist/cjs/serialization/resources/apiKeys/types/BrowserCredentialCreator.js +43 -0
  118. package/dist/cjs/serialization/resources/apiKeys/types/BrowserEnrollmentAccepted.d.ts +11 -0
  119. package/dist/cjs/serialization/resources/apiKeys/types/BrowserEnrollmentAccepted.js +43 -0
  120. package/dist/cjs/serialization/resources/apiKeys/types/BrowserEnrollmentLifecycleEvent.d.ts +19 -0
  121. package/dist/cjs/serialization/resources/apiKeys/types/BrowserEnrollmentLifecycleEvent.js +51 -0
  122. package/dist/cjs/serialization/resources/apiKeys/types/BrowserEnrollmentLifecycleEventType.d.ts +7 -0
  123. package/dist/cjs/serialization/resources/apiKeys/types/BrowserEnrollmentLifecycleEventType.js +44 -0
  124. package/dist/cjs/serialization/resources/apiKeys/types/BrowserEnrollmentTransactionJti.d.ts +7 -0
  125. package/dist/cjs/serialization/resources/apiKeys/types/BrowserEnrollmentTransactionJti.js +39 -0
  126. package/dist/cjs/serialization/resources/apiKeys/types/BrowserLifecycleActor.d.ts +15 -0
  127. package/dist/cjs/serialization/resources/apiKeys/types/BrowserLifecycleActor.js +49 -0
  128. package/dist/cjs/serialization/resources/apiKeys/types/BrowserLifecycleApiKeyActor.d.ts +9 -0
  129. package/dist/cjs/serialization/resources/apiKeys/types/BrowserLifecycleApiKeyActor.js +41 -0
  130. package/dist/cjs/serialization/resources/apiKeys/types/BrowserLifecycleCredentialActor.d.ts +10 -0
  131. package/dist/cjs/serialization/resources/apiKeys/types/BrowserLifecycleCredentialActor.js +42 -0
  132. package/dist/cjs/serialization/resources/apiKeys/types/BrowserLifecycleEvent.d.ts +9 -0
  133. package/dist/cjs/serialization/resources/apiKeys/types/BrowserLifecycleEvent.js +41 -0
  134. package/dist/cjs/serialization/resources/apiKeys/types/CreateBrowserEnrollmentRequest.d.ts +10 -0
  135. package/dist/cjs/serialization/resources/apiKeys/types/CreateBrowserEnrollmentRequest.js +42 -0
  136. package/dist/cjs/serialization/resources/apiKeys/types/ListBrowserConsentsResponse.d.ts +16 -0
  137. package/dist/cjs/serialization/resources/apiKeys/types/ListBrowserConsentsResponse.js +48 -0
  138. package/dist/cjs/serialization/resources/apiKeys/types/ListBrowserCredentialsResponse.d.ts +16 -0
  139. package/dist/cjs/serialization/resources/apiKeys/types/ListBrowserCredentialsResponse.js +48 -0
  140. package/dist/cjs/serialization/resources/apiKeys/types/ListBrowserLifecycleEventsResponse.d.ts +16 -0
  141. package/dist/cjs/serialization/resources/apiKeys/types/ListBrowserLifecycleEventsResponse.js +48 -0
  142. package/dist/cjs/serialization/resources/apiKeys/types/index.d.ts +18 -0
  143. package/dist/cjs/serialization/resources/apiKeys/types/index.js +18 -0
  144. package/dist/cjs/serialization/resources/domains/types/Domain.d.ts +1 -0
  145. package/dist/cjs/serialization/resources/domains/types/Domain.js +1 -0
  146. package/dist/cjs/serialization/resources/domains/types/GetSetupLinkResponse.d.ts +15 -0
  147. package/dist/cjs/serialization/resources/domains/types/GetSetupLinkResponse.js +47 -0
  148. package/dist/cjs/serialization/resources/domains/types/VerificationRecord.d.ts +1 -0
  149. package/dist/cjs/serialization/resources/domains/types/VerificationRecord.js +1 -0
  150. package/dist/cjs/serialization/resources/domains/types/index.d.ts +1 -0
  151. package/dist/cjs/serialization/resources/domains/types/index.js +1 -0
  152. package/dist/cjs/version.d.ts +1 -1
  153. package/dist/cjs/version.js +1 -1
  154. package/dist/esm/BaseClient.mjs +2 -2
  155. package/dist/esm/api/resources/apiKeys/client/Client.d.mts +78 -0
  156. package/dist/esm/api/resources/apiKeys/client/Client.mjs +362 -0
  157. package/dist/esm/api/resources/apiKeys/client/requests/ListBrowserConsentsRequest.d.mts +12 -0
  158. package/dist/esm/api/resources/apiKeys/client/requests/ListBrowserConsentsRequest.mjs +2 -0
  159. package/dist/esm/api/resources/apiKeys/client/requests/ListBrowserCredentialEventsRequest.d.mts +9 -0
  160. package/dist/esm/api/resources/apiKeys/client/requests/ListBrowserCredentialEventsRequest.mjs +2 -0
  161. package/dist/esm/api/resources/apiKeys/client/requests/ListBrowserCredentialsRequest.d.mts +9 -0
  162. package/dist/esm/api/resources/apiKeys/client/requests/ListBrowserCredentialsRequest.mjs +2 -0
  163. package/dist/esm/api/resources/apiKeys/client/requests/index.d.mts +3 -0
  164. package/dist/esm/api/resources/apiKeys/types/BrowserAuthorizationListLimit.d.mts +1 -0
  165. package/dist/esm/api/resources/apiKeys/types/BrowserAuthorizationListLimit.mjs +2 -0
  166. package/dist/esm/api/resources/apiKeys/types/BrowserConsent.d.mts +16 -0
  167. package/dist/esm/api/resources/apiKeys/types/BrowserConsent.mjs +2 -0
  168. package/dist/esm/api/resources/apiKeys/types/BrowserConsentLifecycleEvent.d.mts +13 -0
  169. package/dist/esm/api/resources/apiKeys/types/BrowserConsentLifecycleEvent.mjs +2 -0
  170. package/dist/esm/api/resources/apiKeys/types/BrowserConsentLifecycleEventType.d.mts +7 -0
  171. package/dist/esm/api/resources/apiKeys/types/BrowserConsentLifecycleEventType.mjs +7 -0
  172. package/dist/esm/api/resources/apiKeys/types/BrowserCredential.d.mts +14 -0
  173. package/dist/esm/api/resources/apiKeys/types/BrowserCredential.mjs +2 -0
  174. package/dist/esm/api/resources/apiKeys/types/BrowserCredentialCreator.d.mts +7 -0
  175. package/dist/esm/api/resources/apiKeys/types/BrowserCredentialCreator.mjs +2 -0
  176. package/dist/esm/api/resources/apiKeys/types/BrowserEnrollmentAccepted.d.mts +11 -0
  177. package/dist/esm/api/resources/apiKeys/types/BrowserEnrollmentAccepted.mjs +2 -0
  178. package/dist/esm/api/resources/apiKeys/types/BrowserEnrollmentLifecycleEvent.d.mts +12 -0
  179. package/dist/esm/api/resources/apiKeys/types/BrowserEnrollmentLifecycleEvent.mjs +2 -0
  180. package/dist/esm/api/resources/apiKeys/types/BrowserEnrollmentLifecycleEventType.d.mts +7 -0
  181. package/dist/esm/api/resources/apiKeys/types/BrowserEnrollmentLifecycleEventType.mjs +7 -0
  182. package/dist/esm/api/resources/apiKeys/types/BrowserEnrollmentTransactionJti.d.mts +4 -0
  183. package/dist/esm/api/resources/apiKeys/types/BrowserEnrollmentTransactionJti.mjs +2 -0
  184. package/dist/esm/api/resources/apiKeys/types/BrowserLifecycleActor.d.mts +10 -0
  185. package/dist/esm/api/resources/apiKeys/types/BrowserLifecycleActor.mjs +2 -0
  186. package/dist/esm/api/resources/apiKeys/types/BrowserLifecycleApiKeyActor.d.mts +3 -0
  187. package/dist/esm/api/resources/apiKeys/types/BrowserLifecycleApiKeyActor.mjs +2 -0
  188. package/dist/esm/api/resources/apiKeys/types/BrowserLifecycleCredentialActor.d.mts +4 -0
  189. package/dist/esm/api/resources/apiKeys/types/BrowserLifecycleCredentialActor.mjs +2 -0
  190. package/dist/esm/api/resources/apiKeys/types/BrowserLifecycleEvent.d.mts +2 -0
  191. package/dist/esm/api/resources/apiKeys/types/BrowserLifecycleEvent.mjs +2 -0
  192. package/dist/esm/api/resources/apiKeys/types/CreateBrowserEnrollmentRequest.d.mts +9 -0
  193. package/dist/esm/api/resources/apiKeys/types/CreateBrowserEnrollmentRequest.mjs +2 -0
  194. package/dist/esm/api/resources/apiKeys/types/ListBrowserConsentsResponse.d.mts +7 -0
  195. package/dist/esm/api/resources/apiKeys/types/ListBrowserConsentsResponse.mjs +2 -0
  196. package/dist/esm/api/resources/apiKeys/types/ListBrowserCredentialsResponse.d.mts +7 -0
  197. package/dist/esm/api/resources/apiKeys/types/ListBrowserCredentialsResponse.mjs +2 -0
  198. package/dist/esm/api/resources/apiKeys/types/ListBrowserLifecycleEventsResponse.d.mts +7 -0
  199. package/dist/esm/api/resources/apiKeys/types/ListBrowserLifecycleEventsResponse.mjs +2 -0
  200. package/dist/esm/api/resources/apiKeys/types/index.d.mts +18 -0
  201. package/dist/esm/api/resources/apiKeys/types/index.mjs +18 -0
  202. package/dist/esm/api/resources/attachments/types/SendAttachment.d.mts +9 -2
  203. package/dist/esm/api/resources/domains/client/Client.d.mts +17 -0
  204. package/dist/esm/api/resources/domains/client/Client.mjs +100 -0
  205. package/dist/esm/api/resources/domains/types/Domain.d.mts +2 -0
  206. package/dist/esm/api/resources/domains/types/GetSetupLinkResponse.d.mts +16 -0
  207. package/dist/esm/api/resources/domains/types/GetSetupLinkResponse.mjs +2 -0
  208. package/dist/esm/api/resources/domains/types/VerificationRecord.d.mts +2 -0
  209. package/dist/esm/api/resources/domains/types/index.d.mts +1 -0
  210. package/dist/esm/api/resources/domains/types/index.mjs +1 -0
  211. package/dist/esm/api/resources/inboxes/client/Client.d.mts +3 -0
  212. package/dist/esm/api/resources/inboxes/client/Client.mjs +5 -0
  213. package/dist/esm/api/resources/inboxes/resources/apiKeys/client/Client.d.mts +3 -3
  214. package/dist/esm/api/resources/inboxes/resources/apiKeys/client/Client.mjs +3 -3
  215. package/dist/esm/api/resources/inboxes/resources/browserCredentials/client/Client.d.mts +55 -0
  216. package/dist/esm/api/resources/inboxes/resources/browserCredentials/client/Client.mjs +138 -0
  217. package/dist/esm/api/resources/inboxes/resources/browserCredentials/client/index.d.mts +1 -0
  218. package/dist/esm/api/resources/inboxes/resources/browserCredentials/client/index.mjs +1 -0
  219. package/dist/esm/api/resources/inboxes/resources/browserCredentials/exports.d.mts +2 -0
  220. package/dist/esm/api/resources/inboxes/resources/browserCredentials/exports.mjs +3 -0
  221. package/dist/esm/api/resources/inboxes/resources/browserCredentials/index.d.mts +1 -0
  222. package/dist/esm/api/resources/inboxes/resources/browserCredentials/index.mjs +1 -0
  223. package/dist/esm/api/resources/inboxes/resources/drafts/client/Client.d.mts +7 -7
  224. package/dist/esm/api/resources/inboxes/resources/drafts/client/Client.mjs +7 -7
  225. package/dist/esm/api/resources/inboxes/resources/events/client/Client.d.mts +1 -1
  226. package/dist/esm/api/resources/inboxes/resources/events/client/Client.mjs +1 -1
  227. package/dist/esm/api/resources/inboxes/resources/index.d.mts +1 -0
  228. package/dist/esm/api/resources/inboxes/resources/index.mjs +1 -0
  229. package/dist/esm/api/resources/inboxes/resources/lists/client/Client.d.mts +4 -4
  230. package/dist/esm/api/resources/inboxes/resources/lists/client/Client.mjs +4 -4
  231. package/dist/esm/api/resources/inboxes/resources/messages/client/Client.d.mts +12 -12
  232. package/dist/esm/api/resources/inboxes/resources/messages/client/Client.mjs +12 -12
  233. package/dist/esm/api/resources/inboxes/resources/metrics/client/Client.d.mts +1 -1
  234. package/dist/esm/api/resources/inboxes/resources/metrics/client/Client.mjs +1 -1
  235. package/dist/esm/api/resources/inboxes/resources/threads/client/Client.d.mts +4 -4
  236. package/dist/esm/api/resources/inboxes/resources/threads/client/Client.mjs +4 -4
  237. package/dist/esm/api/resources/inboxes/resources/webhooks/client/Client.d.mts +5 -5
  238. package/dist/esm/api/resources/inboxes/resources/webhooks/client/Client.mjs +5 -5
  239. package/dist/esm/api/resources/metrics/client/Client.d.mts +1 -1
  240. package/dist/esm/api/resources/metrics/client/Client.mjs +1 -1
  241. package/dist/esm/api/resources/pods/resources/apiKeys/client/Client.d.mts +3 -3
  242. package/dist/esm/api/resources/pods/resources/apiKeys/client/Client.mjs +3 -3
  243. package/dist/esm/api/resources/pods/resources/domains/client/Client.d.mts +7 -7
  244. package/dist/esm/api/resources/pods/resources/domains/client/Client.mjs +7 -7
  245. package/dist/esm/api/resources/pods/resources/drafts/client/Client.d.mts +3 -3
  246. package/dist/esm/api/resources/pods/resources/drafts/client/Client.mjs +3 -3
  247. package/dist/esm/api/resources/pods/resources/inboxes/client/Client.d.mts +5 -5
  248. package/dist/esm/api/resources/pods/resources/inboxes/client/Client.mjs +5 -5
  249. package/dist/esm/api/resources/pods/resources/lists/client/Client.d.mts +4 -4
  250. package/dist/esm/api/resources/pods/resources/lists/client/Client.mjs +4 -4
  251. package/dist/esm/api/resources/pods/resources/metrics/client/Client.d.mts +1 -1
  252. package/dist/esm/api/resources/pods/resources/metrics/client/Client.mjs +1 -1
  253. package/dist/esm/api/resources/pods/resources/threads/client/Client.d.mts +4 -4
  254. package/dist/esm/api/resources/pods/resources/threads/client/Client.mjs +4 -4
  255. package/dist/esm/api/resources/pods/resources/webhooks/client/Client.d.mts +5 -5
  256. package/dist/esm/api/resources/pods/resources/webhooks/client/Client.mjs +5 -5
  257. package/dist/esm/api/resources/webhooks/client/Client.d.mts +2 -2
  258. package/dist/esm/api/resources/webhooks/client/Client.mjs +2 -2
  259. package/dist/esm/serialization/resources/apiKeys/types/BrowserAuthorizationListLimit.d.mts +7 -0
  260. package/dist/esm/serialization/resources/apiKeys/types/BrowserAuthorizationListLimit.mjs +3 -0
  261. package/dist/esm/serialization/resources/apiKeys/types/BrowserConsent.d.mts +17 -0
  262. package/dist/esm/serialization/resources/apiKeys/types/BrowserConsent.mjs +13 -0
  263. package/dist/esm/serialization/resources/apiKeys/types/BrowserConsentLifecycleEvent.d.mts +20 -0
  264. package/dist/esm/serialization/resources/apiKeys/types/BrowserConsentLifecycleEvent.mjs +16 -0
  265. package/dist/esm/serialization/resources/apiKeys/types/BrowserConsentLifecycleEventType.d.mts +7 -0
  266. package/dist/esm/serialization/resources/apiKeys/types/BrowserConsentLifecycleEventType.mjs +8 -0
  267. package/dist/esm/serialization/resources/apiKeys/types/BrowserCredential.d.mts +17 -0
  268. package/dist/esm/serialization/resources/apiKeys/types/BrowserCredential.mjs +13 -0
  269. package/dist/esm/serialization/resources/apiKeys/types/BrowserCredentialCreator.d.mts +11 -0
  270. package/dist/esm/serialization/resources/apiKeys/types/BrowserCredentialCreator.mjs +7 -0
  271. package/dist/esm/serialization/resources/apiKeys/types/BrowserEnrollmentAccepted.d.mts +11 -0
  272. package/dist/esm/serialization/resources/apiKeys/types/BrowserEnrollmentAccepted.mjs +7 -0
  273. package/dist/esm/serialization/resources/apiKeys/types/BrowserEnrollmentLifecycleEvent.d.mts +19 -0
  274. package/dist/esm/serialization/resources/apiKeys/types/BrowserEnrollmentLifecycleEvent.mjs +15 -0
  275. package/dist/esm/serialization/resources/apiKeys/types/BrowserEnrollmentLifecycleEventType.d.mts +7 -0
  276. package/dist/esm/serialization/resources/apiKeys/types/BrowserEnrollmentLifecycleEventType.mjs +8 -0
  277. package/dist/esm/serialization/resources/apiKeys/types/BrowserEnrollmentTransactionJti.d.mts +7 -0
  278. package/dist/esm/serialization/resources/apiKeys/types/BrowserEnrollmentTransactionJti.mjs +3 -0
  279. package/dist/esm/serialization/resources/apiKeys/types/BrowserLifecycleActor.d.mts +15 -0
  280. package/dist/esm/serialization/resources/apiKeys/types/BrowserLifecycleActor.mjs +13 -0
  281. package/dist/esm/serialization/resources/apiKeys/types/BrowserLifecycleApiKeyActor.d.mts +9 -0
  282. package/dist/esm/serialization/resources/apiKeys/types/BrowserLifecycleApiKeyActor.mjs +5 -0
  283. package/dist/esm/serialization/resources/apiKeys/types/BrowserLifecycleCredentialActor.d.mts +10 -0
  284. package/dist/esm/serialization/resources/apiKeys/types/BrowserLifecycleCredentialActor.mjs +6 -0
  285. package/dist/esm/serialization/resources/apiKeys/types/BrowserLifecycleEvent.d.mts +9 -0
  286. package/dist/esm/serialization/resources/apiKeys/types/BrowserLifecycleEvent.mjs +5 -0
  287. package/dist/esm/serialization/resources/apiKeys/types/CreateBrowserEnrollmentRequest.d.mts +10 -0
  288. package/dist/esm/serialization/resources/apiKeys/types/CreateBrowserEnrollmentRequest.mjs +6 -0
  289. package/dist/esm/serialization/resources/apiKeys/types/ListBrowserConsentsResponse.d.mts +16 -0
  290. package/dist/esm/serialization/resources/apiKeys/types/ListBrowserConsentsResponse.mjs +12 -0
  291. package/dist/esm/serialization/resources/apiKeys/types/ListBrowserCredentialsResponse.d.mts +16 -0
  292. package/dist/esm/serialization/resources/apiKeys/types/ListBrowserCredentialsResponse.mjs +12 -0
  293. package/dist/esm/serialization/resources/apiKeys/types/ListBrowserLifecycleEventsResponse.d.mts +16 -0
  294. package/dist/esm/serialization/resources/apiKeys/types/ListBrowserLifecycleEventsResponse.mjs +12 -0
  295. package/dist/esm/serialization/resources/apiKeys/types/index.d.mts +18 -0
  296. package/dist/esm/serialization/resources/apiKeys/types/index.mjs +18 -0
  297. package/dist/esm/serialization/resources/domains/types/Domain.d.mts +1 -0
  298. package/dist/esm/serialization/resources/domains/types/Domain.mjs +1 -0
  299. package/dist/esm/serialization/resources/domains/types/GetSetupLinkResponse.d.mts +15 -0
  300. package/dist/esm/serialization/resources/domains/types/GetSetupLinkResponse.mjs +11 -0
  301. package/dist/esm/serialization/resources/domains/types/VerificationRecord.d.mts +1 -0
  302. package/dist/esm/serialization/resources/domains/types/VerificationRecord.mjs +1 -0
  303. package/dist/esm/serialization/resources/domains/types/index.d.mts +1 -0
  304. package/dist/esm/serialization/resources/domains/types/index.mjs +1 -0
  305. package/dist/esm/version.d.mts +1 -1
  306. package/dist/esm/version.mjs +1 -1
  307. package/dist/llms.txt +11 -1
  308. package/package.json +20 -2
  309. package/reference.md +613 -72
@@ -43,8 +43,8 @@ function normalizeClientOptions(options) {
43
43
  const headers = (0, headers_js_1.mergeHeaders)({
44
44
  "X-Fern-Language": "JavaScript",
45
45
  "X-Fern-SDK-Name": "agentmail",
46
- "X-Fern-SDK-Version": "0.5.20",
47
- "User-Agent": "agentmail/0.5.20",
46
+ "X-Fern-SDK-Version": "0.5.21",
47
+ "User-Agent": "agentmail/0.5.21",
48
48
  "X-Fern-Runtime": core.RUNTIME.type,
49
49
  "X-Fern-Runtime-Version": core.RUNTIME.version,
50
50
  }, options === null || options === void 0 ? void 0 : options.headers);
@@ -150,4 +150,82 @@ export declare class ApiKeysClient {
150
150
  */
151
151
  revokeAllAgentIdSignInKeys(request: AgentMail.RevokeAllAgentIdSignInKeysRequest, requestOptions?: ApiKeysClient.RequestOptions): core.HttpResponsePromise<AgentMail.RevokeAllAgentIdSignInKeysResponse>;
152
152
  private __revokeAllAgentIdSignInKeys;
153
+ /**
154
+ * List active browser credentials visible to the caller's scope. Requires `api_key_read`.
155
+ *
156
+ * @param {AgentMail.ListBrowserCredentialsRequest} request
157
+ * @param {ApiKeysClient.RequestOptions} requestOptions - Request-specific configuration.
158
+ *
159
+ * @example
160
+ * await client.apiKeys.listBrowserCredentials()
161
+ */
162
+ listBrowserCredentials(request?: AgentMail.ListBrowserCredentialsRequest, requestOptions?: ApiKeysClient.RequestOptions): core.HttpResponsePromise<AgentMail.ListBrowserCredentialsResponse>;
163
+ private __listBrowserCredentials;
164
+ /**
165
+ * List owner-facing browser credential and consent lifecycle events. Requires `api_key_read`.
166
+ *
167
+ * @param {AgentMail.ListBrowserCredentialEventsRequest} request
168
+ * @param {ApiKeysClient.RequestOptions} requestOptions - Request-specific configuration.
169
+ *
170
+ * @throws {@link AgentMail.NotFoundError}
171
+ *
172
+ * @example
173
+ * await client.apiKeys.listBrowserCredentialEvents()
174
+ */
175
+ listBrowserCredentialEvents(request?: AgentMail.ListBrowserCredentialEventsRequest, requestOptions?: ApiKeysClient.RequestOptions): core.HttpResponsePromise<AgentMail.ListBrowserLifecycleEventsResponse>;
176
+ private __listBrowserCredentialEvents;
177
+ /**
178
+ * Permanently revoke one active browser credential. Requires `api_key_delete`.
179
+ *
180
+ * @param {string} credential_id
181
+ * @param {ApiKeysClient.RequestOptions} requestOptions - Request-specific configuration.
182
+ *
183
+ * @throws {@link AgentMail.NotFoundError}
184
+ *
185
+ * @example
186
+ * await client.apiKeys.deleteBrowserCredential("d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32")
187
+ */
188
+ deleteBrowserCredential(credential_id: string, requestOptions?: ApiKeysClient.RequestOptions): core.HttpResponsePromise<void>;
189
+ private __deleteBrowserCredential;
190
+ /**
191
+ * Cancel one pending, unexpired browser enrollment intent. Requires `api_key_delete`.
192
+ *
193
+ * @param {string} enrollment_id
194
+ * @param {ApiKeysClient.RequestOptions} requestOptions - Request-specific configuration.
195
+ *
196
+ * @throws {@link AgentMail.NotFoundError}
197
+ *
198
+ * @example
199
+ * await client.apiKeys.cancelBrowserEnrollment("d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32")
200
+ */
201
+ cancelBrowserEnrollment(enrollment_id: string, requestOptions?: ApiKeysClient.RequestOptions): core.HttpResponsePromise<void>;
202
+ private __cancelBrowserEnrollment;
203
+ /**
204
+ * List remembered AgentID client approvals for one live inbox. Requires `api_key_read`.
205
+ *
206
+ * @param {AgentMail.ListBrowserConsentsRequest} request
207
+ * @param {ApiKeysClient.RequestOptions} requestOptions - Request-specific configuration.
208
+ *
209
+ * @throws {@link AgentMail.NotFoundError}
210
+ *
211
+ * @example
212
+ * await client.apiKeys.listBrowserConsents({
213
+ * inboxId: "inbox_id"
214
+ * })
215
+ */
216
+ listBrowserConsents(request: AgentMail.ListBrowserConsentsRequest, requestOptions?: ApiKeysClient.RequestOptions): core.HttpResponsePromise<AgentMail.ListBrowserConsentsResponse>;
217
+ private __listBrowserConsents;
218
+ /**
219
+ * Revoke one remembered AgentID client approval. Requires `api_key_delete`.
220
+ *
221
+ * @param {string} consent_id
222
+ * @param {ApiKeysClient.RequestOptions} requestOptions - Request-specific configuration.
223
+ *
224
+ * @throws {@link AgentMail.NotFoundError}
225
+ *
226
+ * @example
227
+ * await client.apiKeys.deleteBrowserConsent("consent_id")
228
+ */
229
+ deleteBrowserConsent(consent_id: string, requestOptions?: ApiKeysClient.RequestOptions): core.HttpResponsePromise<void>;
230
+ private __deleteBrowserConsent;
153
231
  }
@@ -619,5 +619,367 @@ class ApiKeysClient {
619
619
  return (0, handleNonStatusCodeError_js_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "POST", "/v0/api-keys/public-keys/agentid-sign-in/revoke-all");
620
620
  });
621
621
  }
622
+ /**
623
+ * List active browser credentials visible to the caller's scope. Requires `api_key_read`.
624
+ *
625
+ * @param {AgentMail.ListBrowserCredentialsRequest} request
626
+ * @param {ApiKeysClient.RequestOptions} requestOptions - Request-specific configuration.
627
+ *
628
+ * @example
629
+ * await client.apiKeys.listBrowserCredentials()
630
+ */
631
+ listBrowserCredentials(request = {}, requestOptions) {
632
+ return core.HttpResponsePromise.fromPromise(this.__listBrowserCredentials(request, requestOptions));
633
+ }
634
+ __listBrowserCredentials() {
635
+ return __awaiter(this, arguments, void 0, function* (request = {}, requestOptions) {
636
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j;
637
+ const { limit, pageToken } = request;
638
+ const _queryParams = {
639
+ limit,
640
+ page_token: pageToken,
641
+ };
642
+ const _authRequest = yield this._options.authProvider.getAuthRequest();
643
+ const _headers = (0, headers_js_1.mergeHeaders)(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
644
+ const _response = yield core.fetcher({
645
+ url: core.url.join((_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : ((_c = (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.AgentMailEnvironment.Prod)
646
+ .http, "/v0/api-keys/browser-credentials"),
647
+ method: "GET",
648
+ headers: _headers,
649
+ queryParameters: Object.assign(Object.assign({}, _queryParams), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams),
650
+ timeoutMs: ((_f = (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.timeoutInSeconds) !== null && _f !== void 0 ? _f : 60) * 1000,
651
+ maxRetries: (_g = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _g !== void 0 ? _g : (_h = this._options) === null || _h === void 0 ? void 0 : _h.maxRetries,
652
+ abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
653
+ fetchFn: (_j = this._options) === null || _j === void 0 ? void 0 : _j.fetch,
654
+ logging: this._options.logging,
655
+ });
656
+ if (_response.ok) {
657
+ return {
658
+ data: serializers.ListBrowserCredentialsResponse.parseOrThrow(_response.body, {
659
+ unrecognizedObjectKeys: "passthrough",
660
+ allowUnrecognizedUnionMembers: true,
661
+ allowUnrecognizedEnumValues: true,
662
+ skipValidation: true,
663
+ breadcrumbsPrefix: ["response"],
664
+ }),
665
+ rawResponse: _response.rawResponse,
666
+ };
667
+ }
668
+ if (_response.error.reason === "status-code") {
669
+ throw new errors.AgentMailError({
670
+ statusCode: _response.error.statusCode,
671
+ body: _response.error.body,
672
+ rawResponse: _response.rawResponse,
673
+ });
674
+ }
675
+ return (0, handleNonStatusCodeError_js_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "GET", "/v0/api-keys/browser-credentials");
676
+ });
677
+ }
678
+ /**
679
+ * List owner-facing browser credential and consent lifecycle events. Requires `api_key_read`.
680
+ *
681
+ * @param {AgentMail.ListBrowserCredentialEventsRequest} request
682
+ * @param {ApiKeysClient.RequestOptions} requestOptions - Request-specific configuration.
683
+ *
684
+ * @throws {@link AgentMail.NotFoundError}
685
+ *
686
+ * @example
687
+ * await client.apiKeys.listBrowserCredentialEvents()
688
+ */
689
+ listBrowserCredentialEvents(request = {}, requestOptions) {
690
+ return core.HttpResponsePromise.fromPromise(this.__listBrowserCredentialEvents(request, requestOptions));
691
+ }
692
+ __listBrowserCredentialEvents() {
693
+ return __awaiter(this, arguments, void 0, function* (request = {}, requestOptions) {
694
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j;
695
+ const { limit, pageToken } = request;
696
+ const _queryParams = {
697
+ limit,
698
+ page_token: pageToken,
699
+ };
700
+ const _authRequest = yield this._options.authProvider.getAuthRequest();
701
+ const _headers = (0, headers_js_1.mergeHeaders)(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
702
+ const _response = yield core.fetcher({
703
+ url: core.url.join((_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : ((_c = (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.AgentMailEnvironment.Prod)
704
+ .http, "/v0/api-keys/browser-credentials/events"),
705
+ method: "GET",
706
+ headers: _headers,
707
+ queryParameters: Object.assign(Object.assign({}, _queryParams), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams),
708
+ timeoutMs: ((_f = (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.timeoutInSeconds) !== null && _f !== void 0 ? _f : 60) * 1000,
709
+ maxRetries: (_g = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _g !== void 0 ? _g : (_h = this._options) === null || _h === void 0 ? void 0 : _h.maxRetries,
710
+ abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
711
+ fetchFn: (_j = this._options) === null || _j === void 0 ? void 0 : _j.fetch,
712
+ logging: this._options.logging,
713
+ });
714
+ if (_response.ok) {
715
+ return {
716
+ data: serializers.ListBrowserLifecycleEventsResponse.parseOrThrow(_response.body, {
717
+ unrecognizedObjectKeys: "passthrough",
718
+ allowUnrecognizedUnionMembers: true,
719
+ allowUnrecognizedEnumValues: true,
720
+ skipValidation: true,
721
+ breadcrumbsPrefix: ["response"],
722
+ }),
723
+ rawResponse: _response.rawResponse,
724
+ };
725
+ }
726
+ if (_response.error.reason === "status-code") {
727
+ switch (_response.error.statusCode) {
728
+ case 404:
729
+ throw new AgentMail.NotFoundError(serializers.ErrorResponse.parseOrThrow(_response.error.body, {
730
+ unrecognizedObjectKeys: "passthrough",
731
+ allowUnrecognizedUnionMembers: true,
732
+ allowUnrecognizedEnumValues: true,
733
+ skipValidation: true,
734
+ breadcrumbsPrefix: ["response"],
735
+ }), _response.rawResponse);
736
+ default:
737
+ throw new errors.AgentMailError({
738
+ statusCode: _response.error.statusCode,
739
+ body: _response.error.body,
740
+ rawResponse: _response.rawResponse,
741
+ });
742
+ }
743
+ }
744
+ return (0, handleNonStatusCodeError_js_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "GET", "/v0/api-keys/browser-credentials/events");
745
+ });
746
+ }
747
+ /**
748
+ * Permanently revoke one active browser credential. Requires `api_key_delete`.
749
+ *
750
+ * @param {string} credential_id
751
+ * @param {ApiKeysClient.RequestOptions} requestOptions - Request-specific configuration.
752
+ *
753
+ * @throws {@link AgentMail.NotFoundError}
754
+ *
755
+ * @example
756
+ * await client.apiKeys.deleteBrowserCredential("d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32")
757
+ */
758
+ deleteBrowserCredential(credential_id, requestOptions) {
759
+ return core.HttpResponsePromise.fromPromise(this.__deleteBrowserCredential(credential_id, requestOptions));
760
+ }
761
+ __deleteBrowserCredential(credential_id, requestOptions) {
762
+ return __awaiter(this, void 0, void 0, function* () {
763
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j;
764
+ const _authRequest = yield this._options.authProvider.getAuthRequest();
765
+ const _headers = (0, headers_js_1.mergeHeaders)(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
766
+ const _response = yield core.fetcher({
767
+ url: core.url.join((_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : ((_c = (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.AgentMailEnvironment.Prod)
768
+ .http, `/v0/api-keys/browser-credentials/${core.url.encodePathParam(credential_id)}`),
769
+ method: "DELETE",
770
+ headers: _headers,
771
+ queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
772
+ timeoutMs: ((_f = (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.timeoutInSeconds) !== null && _f !== void 0 ? _f : 60) * 1000,
773
+ maxRetries: (_g = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _g !== void 0 ? _g : (_h = this._options) === null || _h === void 0 ? void 0 : _h.maxRetries,
774
+ abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
775
+ fetchFn: (_j = this._options) === null || _j === void 0 ? void 0 : _j.fetch,
776
+ logging: this._options.logging,
777
+ });
778
+ if (_response.ok) {
779
+ return { data: undefined, rawResponse: _response.rawResponse };
780
+ }
781
+ if (_response.error.reason === "status-code") {
782
+ switch (_response.error.statusCode) {
783
+ case 404:
784
+ throw new AgentMail.NotFoundError(serializers.ErrorResponse.parseOrThrow(_response.error.body, {
785
+ unrecognizedObjectKeys: "passthrough",
786
+ allowUnrecognizedUnionMembers: true,
787
+ allowUnrecognizedEnumValues: true,
788
+ skipValidation: true,
789
+ breadcrumbsPrefix: ["response"],
790
+ }), _response.rawResponse);
791
+ default:
792
+ throw new errors.AgentMailError({
793
+ statusCode: _response.error.statusCode,
794
+ body: _response.error.body,
795
+ rawResponse: _response.rawResponse,
796
+ });
797
+ }
798
+ }
799
+ return (0, handleNonStatusCodeError_js_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "DELETE", "/v0/api-keys/browser-credentials/{credential_id}");
800
+ });
801
+ }
802
+ /**
803
+ * Cancel one pending, unexpired browser enrollment intent. Requires `api_key_delete`.
804
+ *
805
+ * @param {string} enrollment_id
806
+ * @param {ApiKeysClient.RequestOptions} requestOptions - Request-specific configuration.
807
+ *
808
+ * @throws {@link AgentMail.NotFoundError}
809
+ *
810
+ * @example
811
+ * await client.apiKeys.cancelBrowserEnrollment("d5e9c84f-c2b2-4bf4-b4b0-7ffd7a9ffc32")
812
+ */
813
+ cancelBrowserEnrollment(enrollment_id, requestOptions) {
814
+ return core.HttpResponsePromise.fromPromise(this.__cancelBrowserEnrollment(enrollment_id, requestOptions));
815
+ }
816
+ __cancelBrowserEnrollment(enrollment_id, requestOptions) {
817
+ return __awaiter(this, void 0, void 0, function* () {
818
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j;
819
+ const _authRequest = yield this._options.authProvider.getAuthRequest();
820
+ const _headers = (0, headers_js_1.mergeHeaders)(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
821
+ const _response = yield core.fetcher({
822
+ url: core.url.join((_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : ((_c = (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.AgentMailEnvironment.Prod)
823
+ .http, `/v0/api-keys/browser-credentials/enrollments/${core.url.encodePathParam(enrollment_id)}`),
824
+ method: "DELETE",
825
+ headers: _headers,
826
+ queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
827
+ timeoutMs: ((_f = (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.timeoutInSeconds) !== null && _f !== void 0 ? _f : 60) * 1000,
828
+ maxRetries: (_g = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _g !== void 0 ? _g : (_h = this._options) === null || _h === void 0 ? void 0 : _h.maxRetries,
829
+ abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
830
+ fetchFn: (_j = this._options) === null || _j === void 0 ? void 0 : _j.fetch,
831
+ logging: this._options.logging,
832
+ });
833
+ if (_response.ok) {
834
+ return { data: undefined, rawResponse: _response.rawResponse };
835
+ }
836
+ if (_response.error.reason === "status-code") {
837
+ switch (_response.error.statusCode) {
838
+ case 404:
839
+ throw new AgentMail.NotFoundError(serializers.ErrorResponse.parseOrThrow(_response.error.body, {
840
+ unrecognizedObjectKeys: "passthrough",
841
+ allowUnrecognizedUnionMembers: true,
842
+ allowUnrecognizedEnumValues: true,
843
+ skipValidation: true,
844
+ breadcrumbsPrefix: ["response"],
845
+ }), _response.rawResponse);
846
+ default:
847
+ throw new errors.AgentMailError({
848
+ statusCode: _response.error.statusCode,
849
+ body: _response.error.body,
850
+ rawResponse: _response.rawResponse,
851
+ });
852
+ }
853
+ }
854
+ return (0, handleNonStatusCodeError_js_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "DELETE", "/v0/api-keys/browser-credentials/enrollments/{enrollment_id}");
855
+ });
856
+ }
857
+ /**
858
+ * List remembered AgentID client approvals for one live inbox. Requires `api_key_read`.
859
+ *
860
+ * @param {AgentMail.ListBrowserConsentsRequest} request
861
+ * @param {ApiKeysClient.RequestOptions} requestOptions - Request-specific configuration.
862
+ *
863
+ * @throws {@link AgentMail.NotFoundError}
864
+ *
865
+ * @example
866
+ * await client.apiKeys.listBrowserConsents({
867
+ * inboxId: "inbox_id"
868
+ * })
869
+ */
870
+ listBrowserConsents(request, requestOptions) {
871
+ return core.HttpResponsePromise.fromPromise(this.__listBrowserConsents(request, requestOptions));
872
+ }
873
+ __listBrowserConsents(request, requestOptions) {
874
+ return __awaiter(this, void 0, void 0, function* () {
875
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j;
876
+ const { inboxId, limit, pageToken } = request;
877
+ const _queryParams = {
878
+ inbox_id: inboxId,
879
+ limit,
880
+ page_token: pageToken,
881
+ };
882
+ const _authRequest = yield this._options.authProvider.getAuthRequest();
883
+ const _headers = (0, headers_js_1.mergeHeaders)(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
884
+ const _response = yield core.fetcher({
885
+ url: core.url.join((_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : ((_c = (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.AgentMailEnvironment.Prod)
886
+ .http, "/v0/api-keys/browser-consents"),
887
+ method: "GET",
888
+ headers: _headers,
889
+ queryParameters: Object.assign(Object.assign({}, _queryParams), requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams),
890
+ timeoutMs: ((_f = (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.timeoutInSeconds) !== null && _f !== void 0 ? _f : 60) * 1000,
891
+ maxRetries: (_g = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _g !== void 0 ? _g : (_h = this._options) === null || _h === void 0 ? void 0 : _h.maxRetries,
892
+ abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
893
+ fetchFn: (_j = this._options) === null || _j === void 0 ? void 0 : _j.fetch,
894
+ logging: this._options.logging,
895
+ });
896
+ if (_response.ok) {
897
+ return {
898
+ data: serializers.ListBrowserConsentsResponse.parseOrThrow(_response.body, {
899
+ unrecognizedObjectKeys: "passthrough",
900
+ allowUnrecognizedUnionMembers: true,
901
+ allowUnrecognizedEnumValues: true,
902
+ skipValidation: true,
903
+ breadcrumbsPrefix: ["response"],
904
+ }),
905
+ rawResponse: _response.rawResponse,
906
+ };
907
+ }
908
+ if (_response.error.reason === "status-code") {
909
+ switch (_response.error.statusCode) {
910
+ case 404:
911
+ throw new AgentMail.NotFoundError(serializers.ErrorResponse.parseOrThrow(_response.error.body, {
912
+ unrecognizedObjectKeys: "passthrough",
913
+ allowUnrecognizedUnionMembers: true,
914
+ allowUnrecognizedEnumValues: true,
915
+ skipValidation: true,
916
+ breadcrumbsPrefix: ["response"],
917
+ }), _response.rawResponse);
918
+ default:
919
+ throw new errors.AgentMailError({
920
+ statusCode: _response.error.statusCode,
921
+ body: _response.error.body,
922
+ rawResponse: _response.rawResponse,
923
+ });
924
+ }
925
+ }
926
+ return (0, handleNonStatusCodeError_js_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "GET", "/v0/api-keys/browser-consents");
927
+ });
928
+ }
929
+ /**
930
+ * Revoke one remembered AgentID client approval. Requires `api_key_delete`.
931
+ *
932
+ * @param {string} consent_id
933
+ * @param {ApiKeysClient.RequestOptions} requestOptions - Request-specific configuration.
934
+ *
935
+ * @throws {@link AgentMail.NotFoundError}
936
+ *
937
+ * @example
938
+ * await client.apiKeys.deleteBrowserConsent("consent_id")
939
+ */
940
+ deleteBrowserConsent(consent_id, requestOptions) {
941
+ return core.HttpResponsePromise.fromPromise(this.__deleteBrowserConsent(consent_id, requestOptions));
942
+ }
943
+ __deleteBrowserConsent(consent_id, requestOptions) {
944
+ return __awaiter(this, void 0, void 0, function* () {
945
+ var _a, _b, _c, _d, _e, _f, _g, _h, _j;
946
+ const _authRequest = yield this._options.authProvider.getAuthRequest();
947
+ const _headers = (0, headers_js_1.mergeHeaders)(_authRequest.headers, (_a = this._options) === null || _a === void 0 ? void 0 : _a.headers, requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.headers);
948
+ const _response = yield core.fetcher({
949
+ url: core.url.join((_b = (yield core.Supplier.get(this._options.baseUrl))) !== null && _b !== void 0 ? _b : ((_c = (yield core.Supplier.get(this._options.environment))) !== null && _c !== void 0 ? _c : environments.AgentMailEnvironment.Prod)
950
+ .http, `/v0/api-keys/browser-consents/${core.url.encodePathParam(consent_id)}`),
951
+ method: "DELETE",
952
+ headers: _headers,
953
+ queryParameters: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.queryParams,
954
+ timeoutMs: ((_f = (_d = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.timeoutInSeconds) !== null && _d !== void 0 ? _d : (_e = this._options) === null || _e === void 0 ? void 0 : _e.timeoutInSeconds) !== null && _f !== void 0 ? _f : 60) * 1000,
955
+ maxRetries: (_g = requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.maxRetries) !== null && _g !== void 0 ? _g : (_h = this._options) === null || _h === void 0 ? void 0 : _h.maxRetries,
956
+ abortSignal: requestOptions === null || requestOptions === void 0 ? void 0 : requestOptions.abortSignal,
957
+ fetchFn: (_j = this._options) === null || _j === void 0 ? void 0 : _j.fetch,
958
+ logging: this._options.logging,
959
+ });
960
+ if (_response.ok) {
961
+ return { data: undefined, rawResponse: _response.rawResponse };
962
+ }
963
+ if (_response.error.reason === "status-code") {
964
+ switch (_response.error.statusCode) {
965
+ case 404:
966
+ throw new AgentMail.NotFoundError(serializers.ErrorResponse.parseOrThrow(_response.error.body, {
967
+ unrecognizedObjectKeys: "passthrough",
968
+ allowUnrecognizedUnionMembers: true,
969
+ allowUnrecognizedEnumValues: true,
970
+ skipValidation: true,
971
+ breadcrumbsPrefix: ["response"],
972
+ }), _response.rawResponse);
973
+ default:
974
+ throw new errors.AgentMailError({
975
+ statusCode: _response.error.statusCode,
976
+ body: _response.error.body,
977
+ rawResponse: _response.rawResponse,
978
+ });
979
+ }
980
+ }
981
+ return (0, handleNonStatusCodeError_js_1.handleNonStatusCodeError)(_response.error, _response.rawResponse, "DELETE", "/v0/api-keys/browser-consents/{consent_id}");
982
+ });
983
+ }
622
984
  }
623
985
  exports.ApiKeysClient = ApiKeysClient;
@@ -0,0 +1,12 @@
1
+ import type * as AgentMail from "../../../../index.js";
2
+ /**
3
+ * @example
4
+ * {
5
+ * inboxId: "inbox_id"
6
+ * }
7
+ */
8
+ export interface ListBrowserConsentsRequest {
9
+ inboxId: string;
10
+ limit?: AgentMail.BrowserAuthorizationListLimit;
11
+ pageToken?: AgentMail.PageToken;
12
+ }
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ // This file was auto-generated by Fern from our API Definition.
3
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,9 @@
1
+ import type * as AgentMail from "../../../../index.js";
2
+ /**
3
+ * @example
4
+ * {}
5
+ */
6
+ export interface ListBrowserCredentialEventsRequest {
7
+ limit?: AgentMail.BrowserAuthorizationListLimit;
8
+ pageToken?: AgentMail.PageToken;
9
+ }
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ // This file was auto-generated by Fern from our API Definition.
3
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,9 @@
1
+ import type * as AgentMail from "../../../../index.js";
2
+ /**
3
+ * @example
4
+ * {}
5
+ */
6
+ export interface ListBrowserCredentialsRequest {
7
+ limit?: AgentMail.BrowserAuthorizationListLimit;
8
+ pageToken?: AgentMail.PageToken;
9
+ }
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ // This file was auto-generated by Fern from our API Definition.
3
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -1,3 +1,6 @@
1
1
  export type { ListApiKeysRequest } from "./ListApiKeysRequest.js";
2
+ export type { ListBrowserConsentsRequest } from "./ListBrowserConsentsRequest.js";
3
+ export type { ListBrowserCredentialEventsRequest } from "./ListBrowserCredentialEventsRequest.js";
4
+ export type { ListBrowserCredentialsRequest } from "./ListBrowserCredentialsRequest.js";
2
5
  export type { ListPublicKeysRequest } from "./ListPublicKeysRequest.js";
3
6
  export type { RevokeAllAgentIdSignInKeysRequest } from "./RevokeAllAgentIdSignInKeysRequest.js";
@@ -0,0 +1 @@
1
+ export type BrowserAuthorizationListLimit = number;
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ // This file was auto-generated by Fern from our API Definition.
3
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,16 @@
1
+ /**
2
+ * Remembered approval for one closed AgentID client and inbox.
3
+ */
4
+ export interface BrowserConsent {
5
+ consentId: string;
6
+ inboxId: string;
7
+ clientType: "closed";
8
+ clientId: string;
9
+ /** Registered client URL, when one is available. */
10
+ clientUrl?: string;
11
+ /** At least one non-empty scope approved for this client. */
12
+ approvedScopes: string[];
13
+ createdAt: Date;
14
+ updatedAt: Date;
15
+ expiresAt: Date;
16
+ }
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ // This file was auto-generated by Fern from our API Definition.
3
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,13 @@
1
+ import type * as AgentMail from "../../../index.js";
2
+ export interface BrowserConsentLifecycleEvent {
3
+ type: AgentMail.BrowserConsentLifecycleEventType;
4
+ traceId: string;
5
+ eventId: string;
6
+ occurredAt: Date;
7
+ organizationId: string;
8
+ podId: string;
9
+ actor: AgentMail.BrowserLifecycleActor;
10
+ consentId: string;
11
+ clientType: "closed";
12
+ clientId: string;
13
+ }
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ // This file was auto-generated by Fern from our API Definition.
3
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,7 @@
1
+ export declare const BrowserConsentLifecycleEventType: {
2
+ readonly BrowserConsentCreated: "browser_consent_created";
3
+ readonly BrowserConsentUpdated: "browser_consent_updated";
4
+ readonly BrowserConsentReused: "browser_consent_reused";
5
+ readonly BrowserConsentRevoked: "browser_consent_revoked";
6
+ };
7
+ export type BrowserConsentLifecycleEventType = (typeof BrowserConsentLifecycleEventType)[keyof typeof BrowserConsentLifecycleEventType];
@@ -0,0 +1,10 @@
1
+ "use strict";
2
+ // This file was auto-generated by Fern from our API Definition.
3
+ Object.defineProperty(exports, "__esModule", { value: true });
4
+ exports.BrowserConsentLifecycleEventType = void 0;
5
+ exports.BrowserConsentLifecycleEventType = {
6
+ BrowserConsentCreated: "browser_consent_created",
7
+ BrowserConsentUpdated: "browser_consent_updated",
8
+ BrowserConsentReused: "browser_consent_reused",
9
+ BrowserConsentRevoked: "browser_consent_revoked",
10
+ };
@@ -0,0 +1,14 @@
1
+ import type * as AgentMail from "../../../index.js";
2
+ /**
3
+ * Owner-facing metadata for an active browser credential. Private key material never leaves the browser.
4
+ */
5
+ export interface BrowserCredential {
6
+ credentialId: string;
7
+ publicKeyFingerprintPrefix: string;
8
+ organizationId: string;
9
+ podId: string;
10
+ inboxId: string;
11
+ createdBy: AgentMail.BrowserCredentialCreator;
12
+ createdAt: Date;
13
+ expiresAt: Date;
14
+ }
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ // This file was auto-generated by Fern from our API Definition.
3
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,7 @@
1
+ export interface BrowserCredentialCreator {
2
+ kind: "bearer_api_key";
3
+ /** Bearer API key that authorized creation of the browser credential. */
4
+ apiKeyId: string;
5
+ /** Incarnation timestamp of the authorizing bearer API key. */
6
+ createdAt: Date;
7
+ }
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ // This file was auto-generated by Fern from our API Definition.
3
+ Object.defineProperty(exports, "__esModule", { value: true });
@@ -0,0 +1,11 @@
1
+ /**
2
+ * Pending enrollment receipt. The browser completes key creation and proof
3
+ * on the existing AgentID page. This response contains no URL, token, or
4
+ * navigation instruction.
5
+ */
6
+ export interface BrowserEnrollmentAccepted {
7
+ status: "pending";
8
+ enrollmentId: string;
9
+ /** Unix timestamp after which the pending enrollment cannot be activated. */
10
+ expiresAt: number;
11
+ }
@@ -0,0 +1,3 @@
1
+ "use strict";
2
+ // This file was auto-generated by Fern from our API Definition.
3
+ Object.defineProperty(exports, "__esModule", { value: true });