@zyphr-dev/node-sdk 0.1.36 → 0.1.38

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 (484) hide show
  1. package/README.md +39 -0
  2. package/dist/index.cjs +773 -47
  3. package/dist/index.cjs.map +1 -1
  4. package/dist/index.d.cts +1193 -522
  5. package/dist/index.d.ts +1193 -522
  6. package/dist/index.js +737 -47
  7. package/dist/index.js.map +1 -1
  8. package/package.json +8 -3
  9. package/src/.openapi-generator/FILES +7 -0
  10. package/src/clientAuth.ts +182 -0
  11. package/src/errors.ts +29 -16
  12. package/src/index.ts +4 -1
  13. package/src/src/apis/AuthEmailOTPApi.ts +1 -1
  14. package/src/src/apis/AuthEmailTemplatesApi.ts +1 -1
  15. package/src/src/apis/AuthEmailVerificationApi.ts +1 -1
  16. package/src/src/apis/AuthLoginApi.ts +1 -1
  17. package/src/src/apis/AuthMFAApi.ts +1 -1
  18. package/src/src/apis/AuthMagicLinksApi.ts +1 -1
  19. package/src/src/apis/AuthOAuthApi.ts +28 -25
  20. package/src/src/apis/AuthOrganizationsApi.ts +1 -1
  21. package/src/src/apis/AuthPasswordResetApi.ts +1 -1
  22. package/src/src/apis/AuthPhoneApi.ts +1 -1
  23. package/src/src/apis/AuthRegistrationApi.ts +70 -5
  24. package/src/src/apis/AuthSessionsApi.ts +1 -1
  25. package/src/src/apis/AuthUserDirectoryApi.ts +596 -0
  26. package/src/src/apis/AuthUserProfileApi.ts +1 -63
  27. package/src/src/apis/AuthWebAuthnApi.ts +1 -1
  28. package/src/src/apis/DevicesApi.ts +1 -1
  29. package/src/src/apis/DomainsApi.ts +1 -1
  30. package/src/src/apis/EmailsApi.ts +1 -1
  31. package/src/src/apis/ExecutionsApi.ts +1 -1
  32. package/src/src/apis/InboundEmailApi.ts +1 -1
  33. package/src/src/apis/InboxApi.ts +1 -1
  34. package/src/src/apis/MuseApi.ts +1 -1
  35. package/src/src/apis/PushApi.ts +1 -1
  36. package/src/src/apis/SMSApi.ts +1 -1
  37. package/src/src/apis/SlackApi.ts +1 -1
  38. package/src/src/apis/SubscribersApi.ts +1 -1
  39. package/src/src/apis/TemplatesApi.ts +78 -1
  40. package/src/src/apis/TopicsApi.ts +1 -1
  41. package/src/src/apis/UtilityApi.ts +1 -1
  42. package/src/src/apis/WaaSApplicationsApi.ts +1 -1
  43. package/src/src/apis/WaaSDeliveriesApi.ts +1 -1
  44. package/src/src/apis/WaaSEndpointsApi.ts +1 -1
  45. package/src/src/apis/WaaSEventTypesApi.ts +1 -1
  46. package/src/src/apis/WaaSEventsApi.ts +1 -1
  47. package/src/src/apis/WaaSPortalApi.ts +1 -1
  48. package/src/src/apis/WebhooksApi.ts +1 -1
  49. package/src/src/apis/index.ts +1 -0
  50. package/src/src/models/AddDomain200Response.ts +1 -1
  51. package/src/src/models/AddDomain200ResponseMeta.ts +1 -1
  52. package/src/src/models/AddDomainRequest.ts +1 -1
  53. package/src/src/models/AddOrganizationMemberRequest.ts +1 -1
  54. package/src/src/models/AddTopicSubscribersRequest.ts +1 -1
  55. package/src/src/models/ApiError.ts +1 -1
  56. package/src/src/models/ApiErrorError.ts +1 -1
  57. package/src/src/models/ApiErrorMeta.ts +1 -1
  58. package/src/src/models/AuthEmailTemplate.ts +1 -1
  59. package/src/src/models/AuthEmailTemplateDefault.ts +1 -1
  60. package/src/src/models/AuthEmailTemplateDefaultResponse.ts +1 -1
  61. package/src/src/models/AuthEmailTemplateDeleteResponse.ts +1 -1
  62. package/src/src/models/AuthEmailTemplateDeleteResponseData.ts +1 -1
  63. package/src/src/models/AuthEmailTemplateListResponse.ts +1 -1
  64. package/src/src/models/AuthEmailTemplatePreviewDraft.ts +1 -1
  65. package/src/src/models/AuthEmailTemplatePreviewRequest.ts +1 -1
  66. package/src/src/models/AuthEmailTemplatePreviewResponse.ts +1 -1
  67. package/src/src/models/AuthEmailTemplatePreviewResult.ts +1 -1
  68. package/src/src/models/AuthEmailTemplateResponse.ts +1 -1
  69. package/src/src/models/AuthEmailTemplateTestRequest.ts +1 -1
  70. package/src/src/models/AuthEmailTemplateTestResponse.ts +1 -1
  71. package/src/src/models/AuthEmailTemplateTestResult.ts +1 -1
  72. package/src/src/models/AuthEmailTemplateVersion.ts +1 -1
  73. package/src/src/models/AuthEmailTemplateVersionsResponse.ts +1 -1
  74. package/src/src/models/AuthEmailType.ts +1 -1
  75. package/src/src/models/AuthLoginResponse.ts +1 -1
  76. package/src/src/models/AuthLoginResult.ts +1 -1
  77. package/src/src/models/AuthLoginResultMfaChallenge.ts +1 -1
  78. package/src/src/models/AuthResult.ts +1 -1
  79. package/src/src/models/AuthResultResponse.ts +1 -1
  80. package/src/src/models/AuthSession.ts +1 -1
  81. package/src/src/models/AuthTokens.ts +1 -1
  82. package/src/src/models/AuthUser.ts +1 -1
  83. package/src/src/models/AuthUserResponse.ts +1 -1
  84. package/src/src/models/AuthUserResponseData.ts +1 -1
  85. package/src/src/models/BatchPublishWaaSEvents201Response.ts +1 -1
  86. package/src/src/models/BatchRecipient.ts +1 -1
  87. package/src/src/models/BulkRetryWebhookDeliveriesRequest.ts +1 -1
  88. package/src/src/models/BulkUpsertAuthEmailTemplatesRequest.ts +1 -1
  89. package/src/src/models/BulkUpsertAuthEmailTemplatesResponse.ts +1 -1
  90. package/src/src/models/Category.ts +1 -1
  91. package/src/src/models/CategoryListResponse.ts +1 -1
  92. package/src/src/models/CategoryResponse.ts +1 -1
  93. package/src/src/models/ConfirmEmailVerificationRequest.ts +1 -1
  94. package/src/src/models/ConfirmEmailVerificationResponse.ts +1 -1
  95. package/src/src/models/ConfirmEmailVerificationResponseData.ts +1 -1
  96. package/src/src/models/ConsentHistoryEntry.ts +1 -1
  97. package/src/src/models/ConsentHistoryResponse.ts +1 -1
  98. package/src/src/models/ConsentRecordResponse.ts +1 -1
  99. package/src/src/models/ConsentRecordResponseData.ts +1 -1
  100. package/src/src/models/ConsentStatus.ts +1 -1
  101. package/src/src/models/ConsentStatusResponse.ts +1 -1
  102. package/src/src/models/ConsentWithdrawResponse.ts +1 -1
  103. package/src/src/models/ConvertAnonymousUserRequest.ts +1 -1
  104. package/src/src/models/ConvertAnonymousUserRequestOneOf.ts +1 -1
  105. package/src/src/models/ConvertAnonymousUserRequestOneOf1.ts +1 -1
  106. package/src/src/models/ConvertAnonymousUserRequestOneOf1AppleUser.ts +1 -1
  107. package/src/src/models/ConvertAnonymousUserRequestOneOf1AppleUserName.ts +1 -1
  108. package/src/src/models/CreateCategoryRequest.ts +1 -1
  109. package/src/src/models/CreateOrganizationRequest.ts +1 -1
  110. package/src/src/models/CreateSubscriberRequest.ts +1 -1
  111. package/src/src/models/CreateTemplateRequest.ts +1 -1
  112. package/src/src/models/CreateTopicRequest.ts +1 -1
  113. package/src/src/models/CreateWaaSApplication201Response.ts +1 -1
  114. package/src/src/models/CreateWaaSApplicationRequest.ts +1 -1
  115. package/src/src/models/CreateWaaSEndpoint201Response.ts +1 -1
  116. package/src/src/models/CreateWaaSEndpointRequest.ts +1 -1
  117. package/src/src/models/CreateWaaSEndpointResponse.ts +1 -1
  118. package/src/src/models/CreateWaaSEventType201Response.ts +1 -1
  119. package/src/src/models/CreateWaaSEventTypeRequest.ts +1 -1
  120. package/src/src/models/CreateWebhookRequest.ts +1 -1
  121. package/src/src/models/DeleteDomainResponse.ts +1 -1
  122. package/src/src/models/DeleteDomainResponseData.ts +1 -1
  123. package/src/src/models/DeleteResult.ts +1 -1
  124. package/src/src/models/DeleteResultData.ts +1 -1
  125. package/src/src/models/Device.ts +1 -1
  126. package/src/src/models/DeviceListResponse.ts +1 -1
  127. package/src/src/models/DevicePushTopic.ts +1 -1
  128. package/src/src/models/DevicePushTopicListResponse.ts +1 -1
  129. package/src/src/models/DevicePushTopicListResponseMeta.ts +1 -1
  130. package/src/src/models/DeviceResponse.ts +1 -1
  131. package/src/src/models/DeviceStats.ts +1 -1
  132. package/src/src/models/DeviceStatsResponse.ts +1 -1
  133. package/src/src/models/DnsRecord.ts +1 -1
  134. package/src/src/models/DomainListResponse.ts +1 -1
  135. package/src/src/models/DomainListResponseMeta.ts +1 -1
  136. package/src/src/models/DomainResponse.ts +1 -1
  137. package/src/src/models/EmailAddress.ts +1 -1
  138. package/src/src/models/EmailAttachment.ts +1 -1
  139. package/src/src/models/EmailEvent.ts +1 -1
  140. package/src/src/models/EmailEventsResponse.ts +1 -1
  141. package/src/src/models/EmailListResponse.ts +1 -1
  142. package/src/src/models/EmailMessage.ts +1 -1
  143. package/src/src/models/EmailResponse.ts +1 -1
  144. package/src/src/models/EmailTrackingClickLink.ts +1 -1
  145. package/src/src/models/EmailTrackingClicks.ts +1 -1
  146. package/src/src/models/EmailTrackingData.ts +1 -1
  147. package/src/src/models/EmailTrackingOpens.ts +1 -1
  148. package/src/src/models/EmailTrackingResponse.ts +1 -1
  149. package/src/src/models/EndUserDeleteResponse.ts +1 -1
  150. package/src/src/models/EndUserDeleteResponseData.ts +1 -1
  151. package/src/src/models/ExecutionCancelResponse.ts +1 -1
  152. package/src/src/models/ExecutionCancelResponseData.ts +1 -1
  153. package/src/src/models/ExecutionResponse.ts +1 -1
  154. package/src/src/models/ExecutionRetryResponse.ts +1 -1
  155. package/src/src/models/ExecutionRetryResponseData.ts +1 -1
  156. package/src/src/models/ForgotPasswordRequest.ts +1 -1
  157. package/src/src/models/GenerateSubscriberToken200Response.ts +1 -1
  158. package/src/src/models/GenerateSubscriberToken200ResponseData.ts +1 -1
  159. package/src/src/models/GenerateSubscriberTokenRequest.ts +1 -1
  160. package/src/src/models/GenerateWaaSPortalToken201Response.ts +1 -1
  161. package/src/src/models/GetDomain200Response.ts +1 -1
  162. package/src/src/models/GetDomain200ResponseMeta.ts +1 -1
  163. package/src/src/models/GetWaaSEndpoint200Response.ts +1 -1
  164. package/src/src/models/GetWaaSUsage200Response.ts +1 -1
  165. package/src/src/models/InAppNotification.ts +1 -1
  166. package/src/src/models/InboundAttachmentUrlResponse.ts +1 -1
  167. package/src/src/models/InboundAttachmentUrlResponseData.ts +1 -1
  168. package/src/src/models/InboundEmail.ts +1 -1
  169. package/src/src/models/InboundEmailAttachment.ts +1 -1
  170. package/src/src/models/InboundEmailFrom.ts +1 -1
  171. package/src/src/models/InboundEmailListResponse.ts +1 -1
  172. package/src/src/models/InboundEmailListResponseMeta.ts +1 -1
  173. package/src/src/models/InboundEmailResponse.ts +1 -1
  174. package/src/src/models/InboxListMeta.ts +1 -1
  175. package/src/src/models/InboxListResponse.ts +1 -1
  176. package/src/src/models/InboxNotificationResponse.ts +1 -1
  177. package/src/src/models/InviteEndUserRequest.ts +110 -0
  178. package/src/src/models/ListWaaSApplications200Response.ts +1 -1
  179. package/src/src/models/ListWaaSEndpointDeliveries200Response.ts +1 -1
  180. package/src/src/models/ListWaaSEndpoints200Response.ts +1 -1
  181. package/src/src/models/ListWaaSEventTypes200Response.ts +1 -1
  182. package/src/src/models/LoginRequest.ts +1 -1
  183. package/src/src/models/MagicLinkSendRequest.ts +1 -1
  184. package/src/src/models/MagicLinkVerifyRequest.ts +1 -1
  185. package/src/src/models/MagicLinkVerifyResponse.ts +1 -1
  186. package/src/src/models/MagicLinkVerifyResponseData.ts +1 -1
  187. package/src/src/models/MarkAllInboxReadRequest.ts +1 -1
  188. package/src/src/models/MarkAllReadData.ts +1 -1
  189. package/src/src/models/MarkAllReadResponse.ts +1 -1
  190. package/src/src/models/MarkAllSubscriberNotificationsReadRequest.ts +1 -1
  191. package/src/src/models/MarkInboxReadRequest.ts +1 -1
  192. package/src/src/models/MfaBackupCodesResponse.ts +1 -1
  193. package/src/src/models/MfaBackupCodesResponseData.ts +1 -1
  194. package/src/src/models/MfaDisableRequest.ts +1 -1
  195. package/src/src/models/MfaDisableResponse.ts +1 -1
  196. package/src/src/models/MfaDisableResponseData.ts +1 -1
  197. package/src/src/models/MfaEnrollRequest.ts +1 -1
  198. package/src/src/models/MfaEnrollmentResponse.ts +1 -1
  199. package/src/src/models/MfaEnrollmentResponseData.ts +1 -1
  200. package/src/src/models/MfaRegenerateBackupCodesRequest.ts +1 -1
  201. package/src/src/models/MfaStatusResponse.ts +1 -1
  202. package/src/src/models/MfaStatusResponseData.ts +1 -1
  203. package/src/src/models/MfaVerifyBackupRequest.ts +1 -1
  204. package/src/src/models/MfaVerifyBackupResponse.ts +1 -1
  205. package/src/src/models/MfaVerifyBackupResponseData.ts +1 -1
  206. package/src/src/models/MfaVerifyEnrollmentRequest.ts +1 -1
  207. package/src/src/models/MfaVerifyEnrollmentResponse.ts +1 -1
  208. package/src/src/models/MfaVerifyEnrollmentResponseData.ts +1 -1
  209. package/src/src/models/MfaVerifyRequest.ts +1 -1
  210. package/src/src/models/OAuthAuthorizationUrlResponse.ts +1 -1
  211. package/src/src/models/OAuthAuthorizationUrlResponseData.ts +1 -1
  212. package/src/src/models/OAuthCallbackRequest.ts +1 -1
  213. package/src/src/models/OAuthCallbackResponse.ts +1 -1
  214. package/src/src/models/OAuthCallbackResponseData.ts +1 -1
  215. package/src/src/models/OAuthConnection.ts +1 -1
  216. package/src/src/models/OAuthConnectionInfoResponse.ts +1 -1
  217. package/src/src/models/OAuthConnectionInfoResponseData.ts +1 -1
  218. package/src/src/models/OAuthConnectionsResponse.ts +1 -1
  219. package/src/src/models/OAuthConnectionsResponseData.ts +1 -1
  220. package/src/src/models/OAuthProvider.ts +1 -1
  221. package/src/src/models/OAuthProviderInfo.ts +1 -1
  222. package/src/src/models/OAuthProviderName.ts +56 -0
  223. package/src/src/models/OAuthProvidersResponse.ts +1 -1
  224. package/src/src/models/OAuthProvidersResponseData.ts +1 -1
  225. package/src/src/models/OAuthTokensRefreshResponse.ts +1 -1
  226. package/src/src/models/OAuthTokensRefreshResponseData.ts +1 -1
  227. package/src/src/models/OAuthTokensResponse.ts +1 -1
  228. package/src/src/models/OAuthTokensResponseData.ts +1 -1
  229. package/src/src/models/Organization.ts +1 -1
  230. package/src/src/models/OrganizationListResponse.ts +1 -1
  231. package/src/src/models/OrganizationListResponseMeta.ts +1 -1
  232. package/src/src/models/OrganizationMembersListResponse.ts +1 -1
  233. package/src/src/models/OrganizationMembership.ts +1 -1
  234. package/src/src/models/OrganizationMembershipResponse.ts +1 -1
  235. package/src/src/models/OrganizationMembershipWithUser.ts +1 -1
  236. package/src/src/models/OrganizationResponse.ts +1 -1
  237. package/src/src/models/PaginationMeta.ts +1 -1
  238. package/src/src/models/PasswordRequirements.ts +1 -1
  239. package/src/src/models/PasswordRequirementsResponse.ts +1 -1
  240. package/src/src/models/PasswordRequirementsResponseData.ts +1 -1
  241. package/src/src/models/PayloadTooLargeError.ts +1 -1
  242. package/src/src/models/PayloadTooLargeErrorError.ts +1 -1
  243. package/src/src/models/PayloadTooLargeErrorErrorDetails.ts +1 -1
  244. package/src/src/models/PhoneAuthAvailabilityResponse.ts +1 -1
  245. package/src/src/models/PhoneAuthAvailabilityResponseData.ts +1 -1
  246. package/src/src/models/PhoneLoginVerifyRequest.ts +1 -1
  247. package/src/src/models/PhoneOtpSendRequest.ts +1 -1
  248. package/src/src/models/PhoneOtpSentResponse.ts +1 -1
  249. package/src/src/models/PhoneOtpSentResponseData.ts +1 -1
  250. package/src/src/models/PhoneRegisterVerifyRequest.ts +1 -1
  251. package/src/src/models/PreferenceListResponse.ts +1 -1
  252. package/src/src/models/PublishWaaSEvent201Response.ts +1 -1
  253. package/src/src/models/PushDetailResponse.ts +1 -1
  254. package/src/src/models/PushEvent.ts +1 -1
  255. package/src/src/models/PushListResponse.ts +1 -1
  256. package/src/src/models/PushMessage.ts +1 -1
  257. package/src/src/models/PushMessageDetail.ts +1 -1
  258. package/src/src/models/PushMessageDetailAllOfActionButtons.ts +1 -1
  259. package/src/src/models/PushStatsData.ts +1 -1
  260. package/src/src/models/PushStatsResponse.ts +1 -1
  261. package/src/src/models/PushTopicDevice.ts +1 -1
  262. package/src/src/models/PushTopicDeviceListResponse.ts +1 -1
  263. package/src/src/models/PushTopicSubscribeData.ts +1 -1
  264. package/src/src/models/PushTopicSubscribeResponse.ts +1 -1
  265. package/src/src/models/PushTopicUnsubscribeData.ts +1 -1
  266. package/src/src/models/PushTopicUnsubscribeResponse.ts +1 -1
  267. package/src/src/models/RefreshOAuthTokensRequest.ts +1 -1
  268. package/src/src/models/RefreshSessionRequest.ts +1 -1
  269. package/src/src/models/RefreshTokenResponse.ts +1 -1
  270. package/src/src/models/RefreshTokenResponseData.ts +1 -1
  271. package/src/src/models/RegisterDeviceRequest.ts +1 -1
  272. package/src/src/models/RegisterRequest.ts +1 -1
  273. package/src/src/models/RemoveTopicSubscribersRequest.ts +1 -1
  274. package/src/src/models/RenameWebAuthnCredentialRequest.ts +1 -1
  275. package/src/src/models/RenderTemplateRequest.ts +1 -1
  276. package/src/src/models/ReplayWebhookEventsRequest.ts +1 -1
  277. package/src/src/models/RequestMeta.ts +1 -1
  278. package/src/src/models/ResetPasswordRequest.ts +1 -1
  279. package/src/src/models/ResetPasswordResponse.ts +1 -1
  280. package/src/src/models/ResubscribeRequest.ts +1 -1
  281. package/src/src/models/ResubscribeResponse.ts +1 -1
  282. package/src/src/models/RevokeAllSessionsResponse.ts +1 -1
  283. package/src/src/models/RevokeAllSessionsResponseData.ts +1 -1
  284. package/src/src/models/RevokeSessionRequest.ts +1 -1
  285. package/src/src/models/SendBatchEmailRequest.ts +1 -1
  286. package/src/src/models/SendBatchEmailResponse.ts +1 -1
  287. package/src/src/models/SendBatchEmailResult.ts +1 -1
  288. package/src/src/models/SendBatchEmailResultItem.ts +1 -1
  289. package/src/src/models/SendBatchInAppMeta.ts +1 -1
  290. package/src/src/models/SendBatchInAppRequest.ts +1 -1
  291. package/src/src/models/SendBatchInAppResponse.ts +1 -1
  292. package/src/src/models/SendBatchSmsData.ts +1 -1
  293. package/src/src/models/SendBatchSmsRequest.ts +1 -1
  294. package/src/src/models/SendBatchSmsResponse.ts +1 -1
  295. package/src/src/models/SendEmailOtpRegistrationRequest.ts +1 -1
  296. package/src/src/models/SendEmailRequest.ts +1 -1
  297. package/src/src/models/SendEmailResponse.ts +1 -1
  298. package/src/src/models/SendEmailResponseData.ts +1 -1
  299. package/src/src/models/SendEmailResponseMeta.ts +1 -1
  300. package/src/src/models/SendEmailVerificationRequest.ts +1 -1
  301. package/src/src/models/SendInAppMeta.ts +1 -1
  302. package/src/src/models/SendInAppRequest.ts +1 -1
  303. package/src/src/models/SendInAppResponse.ts +1 -1
  304. package/src/src/models/SendPushRequest.ts +1 -1
  305. package/src/src/models/SendPushRequestActionButtonsInner.ts +1 -1
  306. package/src/src/models/SendPushResponse.ts +1 -1
  307. package/src/src/models/SendPushResponseData.ts +1 -1
  308. package/src/src/models/SendPushToTopicData.ts +1 -1
  309. package/src/src/models/SendPushToTopicRequest.ts +1 -1
  310. package/src/src/models/SendPushToTopicResponse.ts +1 -1
  311. package/src/src/models/SendSlackMessageRequest.ts +1 -1
  312. package/src/src/models/SendSlackMessageResponse.ts +1 -1
  313. package/src/src/models/SendSlackMessageResult.ts +1 -1
  314. package/src/src/models/SendSmsData.ts +1 -1
  315. package/src/src/models/SendSmsRequest.ts +1 -1
  316. package/src/src/models/SendSmsResponse.ts +1 -1
  317. package/src/src/models/SendTemplateTestEmailRequest.ts +74 -0
  318. package/src/src/models/SendTestSmsData.ts +1 -1
  319. package/src/src/models/SendTestSmsRequest.ts +1 -1
  320. package/src/src/models/SendTestSmsResponse.ts +1 -1
  321. package/src/src/models/SendWebhookTestEventRequest.ts +1 -1
  322. package/src/src/models/SessionListResponse.ts +1 -1
  323. package/src/src/models/SessionListResponseData.ts +1 -1
  324. package/src/src/models/SessionListResponseDataSessionInfo.ts +1 -1
  325. package/src/src/models/SetDomainInboundRequest.ts +1 -1
  326. package/src/src/models/SetEndUserClaimsRequest.ts +65 -0
  327. package/src/src/models/SetPreferencesRequest.ts +1 -1
  328. package/src/src/models/SetPreferencesRequestPreferencesInner.ts +1 -1
  329. package/src/src/models/SignInAnonymouslyRequest.ts +17 -1
  330. package/src/src/models/SignInWithGameCenterRequest.ts +111 -0
  331. package/src/src/models/SlackMessage.ts +1 -1
  332. package/src/src/models/SlackMessageListResponse.ts +1 -1
  333. package/src/src/models/SlackMessageListResponseMeta.ts +1 -1
  334. package/src/src/models/SlackMessageResponse.ts +1 -1
  335. package/src/src/models/SlackMessageStatus.ts +1 -1
  336. package/src/src/models/SlackMessageSummary.ts +1 -1
  337. package/src/src/models/SmsBatchResultMessage.ts +1 -1
  338. package/src/src/models/SmsBatchResultSummary.ts +1 -1
  339. package/src/src/models/SmsConfig.ts +1 -1
  340. package/src/src/models/SmsConfigDeleteResponse.ts +1 -1
  341. package/src/src/models/SmsConfigDeleteResponseData.ts +1 -1
  342. package/src/src/models/SmsConfigResponse.ts +1 -1
  343. package/src/src/models/SmsDetailResponse.ts +1 -1
  344. package/src/src/models/SmsListResponse.ts +1 -1
  345. package/src/src/models/SmsListResponseMeta.ts +1 -1
  346. package/src/src/models/SmsMessage.ts +1 -1
  347. package/src/src/models/SmsMessageDetail.ts +1 -1
  348. package/src/src/models/SubscribePushTopicRequest.ts +1 -1
  349. package/src/src/models/Subscriber.ts +1 -1
  350. package/src/src/models/SubscriberListResponse.ts +1 -1
  351. package/src/src/models/SubscriberPreference.ts +1 -1
  352. package/src/src/models/SubscriberResponse.ts +1 -1
  353. package/src/src/models/SuccessResult.ts +1 -1
  354. package/src/src/models/SwitchOrganizationRequest.ts +1 -1
  355. package/src/src/models/SwitchOrganizationResponse.ts +1 -1
  356. package/src/src/models/SwitchOrganizationResponseData.ts +1 -1
  357. package/src/src/models/SwitchOrganizationResponseDataTokens.ts +1 -1
  358. package/src/src/models/SwitchOrganizationResponseDataUser.ts +1 -1
  359. package/src/src/models/Template.ts +1 -1
  360. package/src/src/models/TemplateListResponse.ts +1 -1
  361. package/src/src/models/TemplateRenderResponse.ts +1 -1
  362. package/src/src/models/TemplateRenderedContent.ts +1 -1
  363. package/src/src/models/TemplateResponse.ts +1 -1
  364. package/src/src/models/TestWebhookTransformRequest.ts +1 -1
  365. package/src/src/models/Topic.ts +1 -1
  366. package/src/src/models/TopicDeleteResponse.ts +1 -1
  367. package/src/src/models/TopicDeleteResponseData.ts +1 -1
  368. package/src/src/models/TopicListResponse.ts +1 -1
  369. package/src/src/models/TopicResponse.ts +1 -1
  370. package/src/src/models/TopicStatsData.ts +1 -1
  371. package/src/src/models/TopicStatsDataTopicsBySubscriberCountInner.ts +1 -1
  372. package/src/src/models/TopicStatsResponse.ts +1 -1
  373. package/src/src/models/TopicSubscriber.ts +1 -1
  374. package/src/src/models/TopicSubscriberListResponse.ts +1 -1
  375. package/src/src/models/TopicSubscribersAddResponse.ts +1 -1
  376. package/src/src/models/TopicSubscribersAddResult.ts +1 -1
  377. package/src/src/models/TopicSubscribersRemoveResponse.ts +1 -1
  378. package/src/src/models/TopicSubscribersRemoveResult.ts +1 -1
  379. package/src/src/models/UnreadCountData.ts +1 -1
  380. package/src/src/models/UnreadCountResponse.ts +1 -1
  381. package/src/src/models/Unsubscribe.ts +1 -1
  382. package/src/src/models/UnsubscribeListResponse.ts +1 -1
  383. package/src/src/models/UnsubscribeRequest.ts +1 -1
  384. package/src/src/models/UnsubscribeResponse.ts +1 -1
  385. package/src/src/models/UpdateCategoryRequest.ts +1 -1
  386. package/src/src/models/UpdateEndUserByApplicationRequest.ts +97 -0
  387. package/src/src/models/UpdateEndUserRequest.ts +1 -1
  388. package/src/src/models/UpdateOrganizationMemberRoleRequest.ts +1 -1
  389. package/src/src/models/UpdateOrganizationRequest.ts +1 -1
  390. package/src/src/models/UpdateSubscriberPreferencesRequest.ts +1 -1
  391. package/src/src/models/UpdateSubscriberPreferencesRequestPreferencesInner.ts +1 -1
  392. package/src/src/models/UpdateSubscriberRequest.ts +1 -1
  393. package/src/src/models/UpdateTemplateRequest.ts +1 -1
  394. package/src/src/models/UpdateTopicRequest.ts +1 -1
  395. package/src/src/models/UpdateWaaSApplicationRequest.ts +1 -1
  396. package/src/src/models/UpdateWaaSEndpointRequest.ts +1 -1
  397. package/src/src/models/UpdateWaaSEventTypeRequest.ts +1 -1
  398. package/src/src/models/UpdateWebhookRequest.ts +1 -1
  399. package/src/src/models/UpsertAuthEmailTemplateRequest.ts +1 -1
  400. package/src/src/models/UpsertSmsConfigRequest.ts +1 -1
  401. package/src/src/models/UserDevicesDeleteResponse.ts +1 -1
  402. package/src/src/models/UserDevicesDeleteResponseData.ts +1 -1
  403. package/src/src/models/V1MuseSubjectsSuggestPostRequest.ts +1 -1
  404. package/src/src/models/ValidateResetTokenRequest.ts +1 -1
  405. package/src/src/models/ValidateResetTokenResponse.ts +1 -1
  406. package/src/src/models/ValidateResetTokenResponseData.ts +1 -1
  407. package/src/src/models/VerificationStatusResponse.ts +1 -1
  408. package/src/src/models/VerificationStatusResponseData.ts +1 -1
  409. package/src/src/models/VerifyDomainResponse.ts +1 -1
  410. package/src/src/models/VerifyDomainResponseData.ts +1 -1
  411. package/src/src/models/VerifyEmailOtpLoginRequest.ts +1 -1
  412. package/src/src/models/VerifyEmailOtpRegistrationRequest.ts +1 -1
  413. package/src/src/models/VerifySmsConfigData.ts +1 -1
  414. package/src/src/models/VerifySmsConfigResponse.ts +1 -1
  415. package/src/src/models/WaaSApplication.ts +1 -1
  416. package/src/src/models/WaaSBatchPublishRequest.ts +1 -1
  417. package/src/src/models/WaaSBatchPublishResponse.ts +1 -1
  418. package/src/src/models/WaaSDelivery.ts +1 -1
  419. package/src/src/models/WaaSEndpoint.ts +1 -1
  420. package/src/src/models/WaaSEventType.ts +1 -1
  421. package/src/src/models/WaaSPortalTokenRequest.ts +1 -1
  422. package/src/src/models/WaaSPortalTokenRequestTheme.ts +1 -1
  423. package/src/src/models/WaaSPortalTokenResponse.ts +1 -1
  424. package/src/src/models/WaaSPublishEventRequest.ts +1 -1
  425. package/src/src/models/WaaSPublishEventResponse.ts +1 -1
  426. package/src/src/models/WaaSUsageResponse.ts +1 -1
  427. package/src/src/models/WebAuthnChallengeOptions.ts +1 -1
  428. package/src/src/models/WebAuthnCredential.ts +1 -1
  429. package/src/src/models/WebAuthnCredentialListResponse.ts +1 -1
  430. package/src/src/models/WebAuthnCredentialListResponseData.ts +1 -1
  431. package/src/src/models/WebAuthnCredentialResponse.ts +1 -1
  432. package/src/src/models/WebAuthnStartAuthRequest.ts +1 -1
  433. package/src/src/models/WebAuthnStartAuthResponse.ts +1 -1
  434. package/src/src/models/WebAuthnStartRegistrationRequest.ts +1 -1
  435. package/src/src/models/WebAuthnStartRegistrationResponse.ts +1 -1
  436. package/src/src/models/WebAuthnStatusResponse.ts +1 -1
  437. package/src/src/models/WebAuthnStatusResponseData.ts +1 -1
  438. package/src/src/models/WebAuthnVerifyAuthRequest.ts +1 -1
  439. package/src/src/models/WebAuthnVerifyRegistrationRequest.ts +1 -1
  440. package/src/src/models/WebAuthnVerifyRegistrationResponse.ts +1 -1
  441. package/src/src/models/WebAuthnVerifyRegistrationResponseData.ts +1 -1
  442. package/src/src/models/Webhook.ts +1 -1
  443. package/src/src/models/WebhookAccountMetricsResponse.ts +1 -1
  444. package/src/src/models/WebhookBulkRetryResponse.ts +1 -1
  445. package/src/src/models/WebhookCircuitState.ts +1 -1
  446. package/src/src/models/WebhookCircuitStateResponse.ts +1 -1
  447. package/src/src/models/WebhookCreateResponse.ts +1 -1
  448. package/src/src/models/WebhookCreateResponseData.ts +1 -1
  449. package/src/src/models/WebhookDeleteResponse.ts +1 -1
  450. package/src/src/models/WebhookDeleteResponseData.ts +1 -1
  451. package/src/src/models/WebhookDelivery.ts +1 -1
  452. package/src/src/models/WebhookDeliveryDetail.ts +1 -1
  453. package/src/src/models/WebhookDeliveryListResponse.ts +1 -1
  454. package/src/src/models/WebhookDeliveryResponse.ts +1 -1
  455. package/src/src/models/WebhookDeliveryRetryResponse.ts +1 -1
  456. package/src/src/models/WebhookDeliveryRetryResponseData.ts +1 -1
  457. package/src/src/models/WebhookEventTypesResponse.ts +1 -1
  458. package/src/src/models/WebhookEventTypesResponseData.ts +1 -1
  459. package/src/src/models/WebhookIpsResponse.ts +1 -1
  460. package/src/src/models/WebhookIpsResponseData.ts +1 -1
  461. package/src/src/models/WebhookJobResponse.ts +1 -1
  462. package/src/src/models/WebhookListResponse.ts +1 -1
  463. package/src/src/models/WebhookMetricsResponse.ts +1 -1
  464. package/src/src/models/WebhookRegion.ts +1 -1
  465. package/src/src/models/WebhookRegionsResponse.ts +1 -1
  466. package/src/src/models/WebhookRegionsResponseData.ts +1 -1
  467. package/src/src/models/WebhookReplayResponse.ts +1 -1
  468. package/src/src/models/WebhookResponse.ts +1 -1
  469. package/src/src/models/WebhookSecretRotateResponse.ts +1 -1
  470. package/src/src/models/WebhookSecretRotateResponseData.ts +1 -1
  471. package/src/src/models/WebhookTestEventResponse.ts +1 -1
  472. package/src/src/models/WebhookTestEventResponseData.ts +1 -1
  473. package/src/src/models/WebhookTransformTestResponse.ts +1 -1
  474. package/src/src/models/WebhookUsageResponse.ts +1 -1
  475. package/src/src/models/WebhookVersion.ts +1 -1
  476. package/src/src/models/WebhookVersionsResponse.ts +1 -1
  477. package/src/src/models/WebhookVersionsResponseData.ts +1 -1
  478. package/src/src/models/WithdrawSubscriberConsentRequest.ts +1 -1
  479. package/src/src/models/WorkflowExecution.ts +1 -1
  480. package/src/src/models/WorkflowExecutionStatus.ts +1 -1
  481. package/src/src/models/WorkflowStepExecution.ts +1 -1
  482. package/src/src/models/WorkflowStepExecutionStatus.ts +1 -1
  483. package/src/src/models/index.ts +6 -0
  484. package/src/src/runtime.ts +1 -1
package/dist/index.js CHANGED
@@ -5092,6 +5092,47 @@ function InboxNotificationResponseToJSONTyped(value, ignoreDiscriminator = false
5092
5092
  };
5093
5093
  }
5094
5094
 
5095
+ // src/src/models/InviteEndUserRequest.ts
5096
+ var InviteEndUserRequestSendLinkEnum = {
5097
+ MAGIC: "magic",
5098
+ PASSWORD_RESET: "password_reset",
5099
+ NONE: "none"
5100
+ };
5101
+ function instanceOfInviteEndUserRequest(value) {
5102
+ if (!("email" in value) || value["email"] === void 0) return false;
5103
+ return true;
5104
+ }
5105
+ function InviteEndUserRequestFromJSON(json) {
5106
+ return InviteEndUserRequestFromJSONTyped(json, false);
5107
+ }
5108
+ function InviteEndUserRequestFromJSONTyped(json, ignoreDiscriminator) {
5109
+ if (json == null) {
5110
+ return json;
5111
+ }
5112
+ return {
5113
+ "email": json["email"],
5114
+ "name": json["name"] == null ? void 0 : json["name"],
5115
+ "metadata": json["metadata"] == null ? void 0 : json["metadata"],
5116
+ "sendLink": json["send_link"] == null ? void 0 : json["send_link"],
5117
+ "redirectUrl": json["redirect_url"] == null ? void 0 : json["redirect_url"]
5118
+ };
5119
+ }
5120
+ function InviteEndUserRequestToJSON(json) {
5121
+ return InviteEndUserRequestToJSONTyped(json, false);
5122
+ }
5123
+ function InviteEndUserRequestToJSONTyped(value, ignoreDiscriminator = false) {
5124
+ if (value == null) {
5125
+ return value;
5126
+ }
5127
+ return {
5128
+ "email": value["email"],
5129
+ "name": value["name"],
5130
+ "metadata": value["metadata"],
5131
+ "send_link": value["sendLink"],
5132
+ "redirect_url": value["redirectUrl"]
5133
+ };
5134
+ }
5135
+
5095
5136
  // src/src/models/ListWaaSApplications200Response.ts
5096
5137
  function instanceOfListWaaSApplications200Response(value) {
5097
5138
  return true;
@@ -6471,6 +6512,37 @@ function OAuthProviderToJSONTyped(value, ignoreDiscriminator = false) {
6471
6512
  };
6472
6513
  }
6473
6514
 
6515
+ // src/src/models/OAuthProviderName.ts
6516
+ var OAuthProviderName = {
6517
+ GOOGLE: "google",
6518
+ APPLE: "apple",
6519
+ FACEBOOK: "facebook",
6520
+ GITHUB: "github",
6521
+ MICROSOFT: "microsoft"
6522
+ };
6523
+ function instanceOfOAuthProviderName(value) {
6524
+ for (const key in OAuthProviderName) {
6525
+ if (Object.prototype.hasOwnProperty.call(OAuthProviderName, key)) {
6526
+ if (OAuthProviderName[key] === value) {
6527
+ return true;
6528
+ }
6529
+ }
6530
+ }
6531
+ return false;
6532
+ }
6533
+ function OAuthProviderNameFromJSON(json) {
6534
+ return OAuthProviderNameFromJSONTyped(json, false);
6535
+ }
6536
+ function OAuthProviderNameFromJSONTyped(json, ignoreDiscriminator) {
6537
+ return json;
6538
+ }
6539
+ function OAuthProviderNameToJSON(value) {
6540
+ return value;
6541
+ }
6542
+ function OAuthProviderNameToJSONTyped(value, ignoreDiscriminator) {
6543
+ return value;
6544
+ }
6545
+
6474
6546
  // src/src/models/OAuthProvidersResponseData.ts
6475
6547
  function instanceOfOAuthProvidersResponseData(value) {
6476
6548
  return true;
@@ -9785,6 +9857,36 @@ function SendSmsResponseToJSONTyped(value, ignoreDiscriminator = false) {
9785
9857
  };
9786
9858
  }
9787
9859
 
9860
+ // src/src/models/SendTemplateTestEmailRequest.ts
9861
+ function instanceOfSendTemplateTestEmailRequest(value) {
9862
+ if (!("to" in value) || value["to"] === void 0) return false;
9863
+ return true;
9864
+ }
9865
+ function SendTemplateTestEmailRequestFromJSON(json) {
9866
+ return SendTemplateTestEmailRequestFromJSONTyped(json, false);
9867
+ }
9868
+ function SendTemplateTestEmailRequestFromJSONTyped(json, ignoreDiscriminator) {
9869
+ if (json == null) {
9870
+ return json;
9871
+ }
9872
+ return {
9873
+ "to": json["to"],
9874
+ "variables": json["variables"] == null ? void 0 : json["variables"]
9875
+ };
9876
+ }
9877
+ function SendTemplateTestEmailRequestToJSON(json) {
9878
+ return SendTemplateTestEmailRequestToJSONTyped(json, false);
9879
+ }
9880
+ function SendTemplateTestEmailRequestToJSONTyped(value, ignoreDiscriminator = false) {
9881
+ if (value == null) {
9882
+ return value;
9883
+ }
9884
+ return {
9885
+ "to": value["to"],
9886
+ "variables": value["variables"]
9887
+ };
9888
+ }
9889
+
9788
9890
  // src/src/models/SendTestSmsData.ts
9789
9891
  function instanceOfSendTestSmsData(value) {
9790
9892
  return true;
@@ -10024,6 +10126,33 @@ function SetDomainInboundRequestToJSONTyped(value, ignoreDiscriminator = false)
10024
10126
  };
10025
10127
  }
10026
10128
 
10129
+ // src/src/models/SetEndUserClaimsRequest.ts
10130
+ function instanceOfSetEndUserClaimsRequest(value) {
10131
+ return true;
10132
+ }
10133
+ function SetEndUserClaimsRequestFromJSON(json) {
10134
+ return SetEndUserClaimsRequestFromJSONTyped(json, false);
10135
+ }
10136
+ function SetEndUserClaimsRequestFromJSONTyped(json, ignoreDiscriminator) {
10137
+ if (json == null) {
10138
+ return json;
10139
+ }
10140
+ return {
10141
+ "claims": json["claims"] == null ? void 0 : json["claims"]
10142
+ };
10143
+ }
10144
+ function SetEndUserClaimsRequestToJSON(json) {
10145
+ return SetEndUserClaimsRequestToJSONTyped(json, false);
10146
+ }
10147
+ function SetEndUserClaimsRequestToJSONTyped(value, ignoreDiscriminator = false) {
10148
+ if (value == null) {
10149
+ return value;
10150
+ }
10151
+ return {
10152
+ "claims": value["claims"]
10153
+ };
10154
+ }
10155
+
10027
10156
  // src/src/models/SetPreferencesRequestPreferencesInner.ts
10028
10157
  function instanceOfSetPreferencesRequestPreferencesInner(value) {
10029
10158
  return true;
@@ -10098,7 +10227,9 @@ function SignInAnonymouslyRequestFromJSONTyped(json, ignoreDiscriminator) {
10098
10227
  return {
10099
10228
  "deviceId": json["device_id"],
10100
10229
  "name": json["name"] == null ? void 0 : json["name"],
10101
- "metadata": json["metadata"] == null ? void 0 : json["metadata"]
10230
+ "metadata": json["metadata"] == null ? void 0 : json["metadata"],
10231
+ "organizationId": json["organization_id"] == null ? void 0 : json["organization_id"],
10232
+ "organizationRole": json["organization_role"] == null ? void 0 : json["organization_role"]
10102
10233
  };
10103
10234
  }
10104
10235
  function SignInAnonymouslyRequestToJSON(json) {
@@ -10111,7 +10242,52 @@ function SignInAnonymouslyRequestToJSONTyped(value, ignoreDiscriminator = false)
10111
10242
  return {
10112
10243
  "device_id": value["deviceId"],
10113
10244
  "name": value["name"],
10114
- "metadata": value["metadata"]
10245
+ "metadata": value["metadata"],
10246
+ "organization_id": value["organizationId"],
10247
+ "organization_role": value["organizationRole"]
10248
+ };
10249
+ }
10250
+
10251
+ // src/src/models/SignInWithGameCenterRequest.ts
10252
+ function instanceOfSignInWithGameCenterRequest(value) {
10253
+ if (!("playerId" in value) || value["playerId"] === void 0) return false;
10254
+ if (!("publicKeyUrl" in value) || value["publicKeyUrl"] === void 0) return false;
10255
+ if (!("signature" in value) || value["signature"] === void 0) return false;
10256
+ if (!("salt" in value) || value["salt"] === void 0) return false;
10257
+ if (!("timestamp" in value) || value["timestamp"] === void 0) return false;
10258
+ if (!("bundleId" in value) || value["bundleId"] === void 0) return false;
10259
+ return true;
10260
+ }
10261
+ function SignInWithGameCenterRequestFromJSON(json) {
10262
+ return SignInWithGameCenterRequestFromJSONTyped(json, false);
10263
+ }
10264
+ function SignInWithGameCenterRequestFromJSONTyped(json, ignoreDiscriminator) {
10265
+ if (json == null) {
10266
+ return json;
10267
+ }
10268
+ return {
10269
+ "playerId": json["playerId"],
10270
+ "publicKeyUrl": json["publicKeyUrl"],
10271
+ "signature": json["signature"],
10272
+ "salt": json["salt"],
10273
+ "timestamp": json["timestamp"],
10274
+ "bundleId": json["bundleId"]
10275
+ };
10276
+ }
10277
+ function SignInWithGameCenterRequestToJSON(json) {
10278
+ return SignInWithGameCenterRequestToJSONTyped(json, false);
10279
+ }
10280
+ function SignInWithGameCenterRequestToJSONTyped(value, ignoreDiscriminator = false) {
10281
+ if (value == null) {
10282
+ return value;
10283
+ }
10284
+ return {
10285
+ "playerId": value["playerId"],
10286
+ "publicKeyUrl": value["publicKeyUrl"],
10287
+ "signature": value["signature"],
10288
+ "salt": value["salt"],
10289
+ "timestamp": value["timestamp"],
10290
+ "bundleId": value["bundleId"]
10115
10291
  };
10116
10292
  }
10117
10293
 
@@ -11770,6 +11946,41 @@ function UpdateCategoryRequestToJSONTyped(value, ignoreDiscriminator = false) {
11770
11946
  };
11771
11947
  }
11772
11948
 
11949
+ // src/src/models/UpdateEndUserByApplicationRequest.ts
11950
+ function instanceOfUpdateEndUserByApplicationRequest(value) {
11951
+ return true;
11952
+ }
11953
+ function UpdateEndUserByApplicationRequestFromJSON(json) {
11954
+ return UpdateEndUserByApplicationRequestFromJSONTyped(json, false);
11955
+ }
11956
+ function UpdateEndUserByApplicationRequestFromJSONTyped(json, ignoreDiscriminator) {
11957
+ if (json == null) {
11958
+ return json;
11959
+ }
11960
+ return {
11961
+ "email": json["email"] == null ? void 0 : json["email"],
11962
+ "name": json["name"] == null ? void 0 : json["name"],
11963
+ "avatarUrl": json["avatar_url"] == null ? void 0 : json["avatar_url"],
11964
+ "metadata": json["metadata"] == null ? void 0 : json["metadata"],
11965
+ "status": json["status"] == null ? void 0 : json["status"]
11966
+ };
11967
+ }
11968
+ function UpdateEndUserByApplicationRequestToJSON(json) {
11969
+ return UpdateEndUserByApplicationRequestToJSONTyped(json, false);
11970
+ }
11971
+ function UpdateEndUserByApplicationRequestToJSONTyped(value, ignoreDiscriminator = false) {
11972
+ if (value == null) {
11973
+ return value;
11974
+ }
11975
+ return {
11976
+ "email": value["email"],
11977
+ "name": value["name"],
11978
+ "avatar_url": value["avatarUrl"],
11979
+ "metadata": value["metadata"],
11980
+ "status": value["status"]
11981
+ };
11982
+ }
11983
+
11773
11984
  // src/src/models/UpdateEndUserRequest.ts
11774
11985
  function instanceOfUpdateEndUserRequest(value) {
11775
11986
  return true;
@@ -16655,7 +16866,7 @@ var AuthRegistrationApi = class extends BaseAPI {
16655
16866
  return await response.value();
16656
16867
  }
16657
16868
  /**
16658
- * Issue an end-user identity to a device without email, password, OAuth, or any other credential. Idempotent per (application, environment, device_id): repeated calls with the same device_id return the same user but a fresh token pair. Prior sessions for the user remain valid until natural expiry. Anonymous users do not count toward MAU quota until their first authenticated request after sign-in (excluding /v1/auth/refresh). Convert an anonymous user to a full account via POST /v1/auth/users/convert.
16869
+ * Issue an end-user identity to a device without email, password, OAuth, or any other credential. Idempotent per (application, environment, device_id): repeated calls with the same device_id return the same user but a fresh token pair. Prior sessions for the user remain valid until natural expiry. Anonymous users do not count toward MAU quota until their first authenticated request after sign-in (excluding /v1/auth/refresh). Convert an anonymous user to a full account via POST /v1/auth/users/convert. Pass an optional `organization_id` to create the anonymous user directly in an organization; the returned access token then carries `org_id` (and `orgs`), matching the org-scoped register/login flow.
16659
16870
  * Sign in anonymously
16660
16871
  */
16661
16872
  async signInAnonymouslyRaw(requestParameters, initOverrides) {
@@ -16681,13 +16892,47 @@ var AuthRegistrationApi = class extends BaseAPI {
16681
16892
  return new JSONApiResponse(response, (jsonValue) => AuthResultResponseFromJSON(jsonValue));
16682
16893
  }
16683
16894
  /**
16684
- * Issue an end-user identity to a device without email, password, OAuth, or any other credential. Idempotent per (application, environment, device_id): repeated calls with the same device_id return the same user but a fresh token pair. Prior sessions for the user remain valid until natural expiry. Anonymous users do not count toward MAU quota until their first authenticated request after sign-in (excluding /v1/auth/refresh). Convert an anonymous user to a full account via POST /v1/auth/users/convert.
16895
+ * Issue an end-user identity to a device without email, password, OAuth, or any other credential. Idempotent per (application, environment, device_id): repeated calls with the same device_id return the same user but a fresh token pair. Prior sessions for the user remain valid until natural expiry. Anonymous users do not count toward MAU quota until their first authenticated request after sign-in (excluding /v1/auth/refresh). Convert an anonymous user to a full account via POST /v1/auth/users/convert. Pass an optional `organization_id` to create the anonymous user directly in an organization; the returned access token then carries `org_id` (and `orgs`), matching the org-scoped register/login flow.
16685
16896
  * Sign in anonymously
16686
16897
  */
16687
16898
  async signInAnonymously(signInAnonymouslyRequest, initOverrides) {
16688
16899
  const response = await this.signInAnonymouslyRaw({ signInAnonymouslyRequest }, initOverrides);
16689
16900
  return await response.value();
16690
16901
  }
16902
+ /**
16903
+ * Exchange an Apple Game Center identity-verification assertion for a Zyphr end-user session. Zyphr independently re-verifies the assertion server-side (Apple certificate chain, RSA-SHA256 signature, timestamp freshness, single-use replay guard, and bundle-id binding) before provisioning-or-looking-up the user and minting tokens. The user is keyed on the modern scoped `playerId` (gamePlayerID). ## Producing the assertion (Integration) The assertion is produced **on-device by the iOS app** — there is no server-side way to mint it. The app calls GameKit\'s `GKLocalPlayer.fetchItems(forIdentityVerificationSignature:)`, which returns `publicKeyURL`, `signature`, `salt`, and `timestamp`; combine those with the local player\'s `gamePlayerID` and the app\'s bundle identifier and submit them here. Two integration shapes are supported: - **client-direct** — the iOS app holds the Zyphr application public key and calls this endpoint itself. - **backend-relayed** — the app forwards the fetched assertion fields to the customer\'s own backend, which relays them to this endpoint; the app never holds Zyphr keys. (This is the common shape for games.) On any verification failure the response is a single opaque `401` `invalid_assertion` — the specific control that failed is never disclosed.
16904
+ * Sign in with Apple Game Center
16905
+ */
16906
+ async signInWithGameCenterRaw(requestParameters, initOverrides) {
16907
+ if (requestParameters["signInWithGameCenterRequest"] == null) {
16908
+ throw new RequiredError(
16909
+ "signInWithGameCenterRequest",
16910
+ 'Required parameter "signInWithGameCenterRequest" was null or undefined when calling signInWithGameCenter().'
16911
+ );
16912
+ }
16913
+ const queryParameters = {};
16914
+ const headerParameters = {};
16915
+ headerParameters["Content-Type"] = "application/json";
16916
+ if (this.configuration && this.configuration.apiKey) {
16917
+ headerParameters["X-Application-Key"] = await this.configuration.apiKey("X-Application-Key");
16918
+ }
16919
+ const response = await this.request({
16920
+ path: `/auth/game-center`,
16921
+ method: "POST",
16922
+ headers: headerParameters,
16923
+ query: queryParameters,
16924
+ body: SignInWithGameCenterRequestToJSON(requestParameters["signInWithGameCenterRequest"])
16925
+ }, initOverrides);
16926
+ return new JSONApiResponse(response, (jsonValue) => AuthResultResponseFromJSON(jsonValue));
16927
+ }
16928
+ /**
16929
+ * Exchange an Apple Game Center identity-verification assertion for a Zyphr end-user session. Zyphr independently re-verifies the assertion server-side (Apple certificate chain, RSA-SHA256 signature, timestamp freshness, single-use replay guard, and bundle-id binding) before provisioning-or-looking-up the user and minting tokens. The user is keyed on the modern scoped `playerId` (gamePlayerID). ## Producing the assertion (Integration) The assertion is produced **on-device by the iOS app** — there is no server-side way to mint it. The app calls GameKit\'s `GKLocalPlayer.fetchItems(forIdentityVerificationSignature:)`, which returns `publicKeyURL`, `signature`, `salt`, and `timestamp`; combine those with the local player\'s `gamePlayerID` and the app\'s bundle identifier and submit them here. Two integration shapes are supported: - **client-direct** — the iOS app holds the Zyphr application public key and calls this endpoint itself. - **backend-relayed** — the app forwards the fetched assertion fields to the customer\'s own backend, which relays them to this endpoint; the app never holds Zyphr keys. (This is the common shape for games.) On any verification failure the response is a single opaque `401` `invalid_assertion` — the specific control that failed is never disclosed.
16930
+ * Sign in with Apple Game Center
16931
+ */
16932
+ async signInWithGameCenter(signInWithGameCenterRequest, initOverrides) {
16933
+ const response = await this.signInWithGameCenterRaw({ signInWithGameCenterRequest }, initOverrides);
16934
+ return await response.value();
16935
+ }
16691
16936
  };
16692
16937
 
16693
16938
  // src/src/apis/AuthSessionsApi.ts
@@ -16837,50 +17082,88 @@ var AuthSessionsApi = class extends BaseAPI {
16837
17082
  }
16838
17083
  };
16839
17084
 
16840
- // src/src/apis/AuthUserProfileApi.ts
16841
- var AuthUserProfileApi = class extends BaseAPI {
17085
+ // src/src/apis/AuthUserDirectoryApi.ts
17086
+ var AuthUserDirectoryApi = class extends BaseAPI {
16842
17087
  /**
16843
- * Delete the current end user account (GDPR right to erasure). This is a soft delete — the account is marked as deleted but data is retained for a period to allow for recovery or legal requirements.
16844
- * Delete current end user account
17088
+ * Secret-key-scoped admin soft-delete for an arbitrary end user in the authenticating application. Works in both test and live environments. Scoped to the application via the application_id filter — a caller can never delete a user belonging to another application. Mirrors the self-service `DELETE /auth/users/me` flow: revokes all sessions, soft-deletes the row (status=\'deleted\'), and emits a `user.deleted` webhook with `method=\'application_admin\'`. The audit log row survives (no FK to end_users), so org-history queries still resolve.
17089
+ * Delete an end user (server-side admin)
16845
17090
  */
16846
- async deleteEndUserRaw(initOverrides) {
17091
+ async deleteEndUserByApplicationRaw(requestParameters, initOverrides) {
17092
+ if (requestParameters["userId"] == null) {
17093
+ throw new RequiredError(
17094
+ "userId",
17095
+ 'Required parameter "userId" was null or undefined when calling deleteEndUserByApplication().'
17096
+ );
17097
+ }
16847
17098
  const queryParameters = {};
16848
17099
  const headerParameters = {};
16849
- if (this.configuration && this.configuration.accessToken) {
16850
- const token = this.configuration.accessToken;
16851
- const tokenString = await token("EndUserToken", []);
16852
- if (tokenString) {
16853
- headerParameters["Authorization"] = `Bearer ${tokenString}`;
16854
- }
17100
+ if (this.configuration && this.configuration.apiKey) {
17101
+ headerParameters["X-Application-Secret"] = await this.configuration.apiKey("X-Application-Secret");
16855
17102
  }
16856
17103
  if (this.configuration && this.configuration.apiKey) {
16857
17104
  headerParameters["X-Application-Key"] = await this.configuration.apiKey("X-Application-Key");
16858
17105
  }
16859
17106
  const response = await this.request({
16860
- path: `/auth/users/me`,
17107
+ path: `/auth/users/{user_id}`.replace(`{${"user_id"}}`, encodeURIComponent(String(requestParameters["userId"]))),
16861
17108
  method: "DELETE",
16862
17109
  headers: headerParameters,
16863
17110
  query: queryParameters
16864
17111
  }, initOverrides);
16865
- return new JSONApiResponse(response, (jsonValue) => EndUserDeleteResponseFromJSON(jsonValue));
17112
+ return new VoidApiResponse(response);
16866
17113
  }
16867
17114
  /**
16868
- * Delete the current end user account (GDPR right to erasure). This is a soft delete — the account is marked as deleted but data is retained for a period to allow for recovery or legal requirements.
16869
- * Delete current end user account
17115
+ * Secret-key-scoped admin soft-delete for an arbitrary end user in the authenticating application. Works in both test and live environments. Scoped to the application via the application_id filter — a caller can never delete a user belonging to another application. Mirrors the self-service `DELETE /auth/users/me` flow: revokes all sessions, soft-deletes the row (status=\'deleted\'), and emits a `user.deleted` webhook with `method=\'application_admin\'`. The audit log row survives (no FK to end_users), so org-history queries still resolve.
17116
+ * Delete an end user (server-side admin)
16870
17117
  */
16871
- async deleteEndUser(initOverrides) {
16872
- const response = await this.deleteEndUserRaw(initOverrides);
16873
- return await response.value();
17118
+ async deleteEndUserByApplication(userId, initOverrides) {
17119
+ await this.deleteEndUserByApplicationRaw({ userId }, initOverrides);
16874
17120
  }
16875
17121
  /**
16876
- * App-credentialed soft-delete for an end user, scoped to the test environment only. Live-mode credentials receive 403 — this is the intentional safety guard against a misconfigured CI runner nuking production users. Mirrors the self-service `DELETE /auth/users/me` flow: revokes all sessions, soft-deletes the row (status=\'deleted\'), and emits a `user.deleted` webhook with `method=\'application_admin\'`. The audit log row survives (no FK to end_users), so org-history queries still resolve. Intended for smoke / test-fixture cleanup. Production deletes should continue to use `DELETE /auth/users/me` from the end-user\'s own session or the dashboard.
16877
- * Delete an end user (test environment only)
17122
+ * Secret-key-scoped lookup of a single end user by email address within the authenticating application. Scoped to the application — never resolves a user from another application. Does not return the password hash.
17123
+ * Look up an end user by email (server-side admin)
16878
17124
  */
16879
- async deleteEndUserByApplicationRaw(requestParameters, initOverrides) {
17125
+ async getEndUserByEmailRaw(requestParameters, initOverrides) {
17126
+ if (requestParameters["email"] == null) {
17127
+ throw new RequiredError(
17128
+ "email",
17129
+ 'Required parameter "email" was null or undefined when calling getEndUserByEmail().'
17130
+ );
17131
+ }
17132
+ const queryParameters = {};
17133
+ if (requestParameters["email"] != null) {
17134
+ queryParameters["email"] = requestParameters["email"];
17135
+ }
17136
+ const headerParameters = {};
17137
+ if (this.configuration && this.configuration.apiKey) {
17138
+ headerParameters["X-Application-Secret"] = await this.configuration.apiKey("X-Application-Secret");
17139
+ }
17140
+ if (this.configuration && this.configuration.apiKey) {
17141
+ headerParameters["X-Application-Key"] = await this.configuration.apiKey("X-Application-Key");
17142
+ }
17143
+ const response = await this.request({
17144
+ path: `/auth/users/by-email`,
17145
+ method: "GET",
17146
+ headers: headerParameters,
17147
+ query: queryParameters
17148
+ }, initOverrides);
17149
+ return new VoidApiResponse(response);
17150
+ }
17151
+ /**
17152
+ * Secret-key-scoped lookup of a single end user by email address within the authenticating application. Scoped to the application — never resolves a user from another application. Does not return the password hash.
17153
+ * Look up an end user by email (server-side admin)
17154
+ */
17155
+ async getEndUserByEmail(email, initOverrides) {
17156
+ await this.getEndUserByEmailRaw({ email }, initOverrides);
17157
+ }
17158
+ /**
17159
+ * Secret-key-scoped fetch of a single end user by id within the authenticating application. Scoped to the application — a caller can never read a user belonging to another application.
17160
+ * Get an end user by id (server-side admin)
17161
+ */
17162
+ async getEndUserByIdRaw(requestParameters, initOverrides) {
16880
17163
  if (requestParameters["userId"] == null) {
16881
17164
  throw new RequiredError(
16882
17165
  "userId",
16883
- 'Required parameter "userId" was null or undefined when calling deleteEndUserByApplication().'
17166
+ 'Required parameter "userId" was null or undefined when calling getEndUserById().'
16884
17167
  );
16885
17168
  }
16886
17169
  const queryParameters = {};
@@ -16893,18 +17176,253 @@ var AuthUserProfileApi = class extends BaseAPI {
16893
17176
  }
16894
17177
  const response = await this.request({
16895
17178
  path: `/auth/users/{user_id}`.replace(`{${"user_id"}}`, encodeURIComponent(String(requestParameters["userId"]))),
16896
- method: "DELETE",
17179
+ method: "GET",
16897
17180
  headers: headerParameters,
16898
17181
  query: queryParameters
16899
17182
  }, initOverrides);
16900
17183
  return new VoidApiResponse(response);
16901
17184
  }
16902
17185
  /**
16903
- * App-credentialed soft-delete for an end user, scoped to the test environment only. Live-mode credentials receive 403 — this is the intentional safety guard against a misconfigured CI runner nuking production users. Mirrors the self-service `DELETE /auth/users/me` flow: revokes all sessions, soft-deletes the row (status=\'deleted\'), and emits a `user.deleted` webhook with `method=\'application_admin\'`. The audit log row survives (no FK to end_users), so org-history queries still resolve. Intended for smoke / test-fixture cleanup. Production deletes should continue to use `DELETE /auth/users/me` from the end-user\'s own session or the dashboard.
16904
- * Delete an end user (test environment only)
17186
+ * Secret-key-scoped fetch of a single end user by id within the authenticating application. Scoped to the application — a caller can never read a user belonging to another application.
17187
+ * Get an end user by id (server-side admin)
16905
17188
  */
16906
- async deleteEndUserByApplication(userId, initOverrides) {
16907
- await this.deleteEndUserByApplicationRaw({ userId }, initOverrides);
17189
+ async getEndUserById(userId, initOverrides) {
17190
+ await this.getEndUserByIdRaw({ userId }, initOverrides);
17191
+ }
17192
+ /**
17193
+ * Secret-key-scoped read of the authoritative custom_claims stored for an end user. These are the TRUSTED claims embedded into the user\'s JWTs on login/refresh — use them (not the client-writable `metadata` field) for authorization decisions. Returns an empty object when none are set.
17194
+ * Get an end user\'s stored custom claims (server-side admin)
17195
+ */
17196
+ async getEndUserClaimsRaw(requestParameters, initOverrides) {
17197
+ if (requestParameters["userId"] == null) {
17198
+ throw new RequiredError(
17199
+ "userId",
17200
+ 'Required parameter "userId" was null or undefined when calling getEndUserClaims().'
17201
+ );
17202
+ }
17203
+ const queryParameters = {};
17204
+ const headerParameters = {};
17205
+ if (this.configuration && this.configuration.apiKey) {
17206
+ headerParameters["X-Application-Secret"] = await this.configuration.apiKey("X-Application-Secret");
17207
+ }
17208
+ if (this.configuration && this.configuration.apiKey) {
17209
+ headerParameters["X-Application-Key"] = await this.configuration.apiKey("X-Application-Key");
17210
+ }
17211
+ const response = await this.request({
17212
+ path: `/auth/users/{user_id}/claims`.replace(`{${"user_id"}}`, encodeURIComponent(String(requestParameters["userId"]))),
17213
+ method: "GET",
17214
+ headers: headerParameters,
17215
+ query: queryParameters
17216
+ }, initOverrides);
17217
+ return new VoidApiResponse(response);
17218
+ }
17219
+ /**
17220
+ * Secret-key-scoped read of the authoritative custom_claims stored for an end user. These are the TRUSTED claims embedded into the user\'s JWTs on login/refresh — use them (not the client-writable `metadata` field) for authorization decisions. Returns an empty object when none are set.
17221
+ * Get an end user\'s stored custom claims (server-side admin)
17222
+ */
17223
+ async getEndUserClaims(userId, initOverrides) {
17224
+ await this.getEndUserClaimsRaw({ userId }, initOverrides);
17225
+ }
17226
+ /**
17227
+ * Secret-key-scoped pre-provisioning for an end user. Creates a passwordless user in the authenticating application (idempotent on email — an existing, non-deleted user is reused, not duplicated) and, when `send_link` is set, sends a first-login link so the user can set up their account without self-registration. - `send_link: \"magic\"` sends a magic-link sign-in email. - `send_link: \"password_reset\"` sends a set-password email. - `send_link: \"none\"` (default) creates the user with no email. A `redirect_url` is required when `send_link` is \"magic\" or \"password_reset\"; it must match the application\'s redirect_uris allowlist (custom schemes such as yourapp://path are permitted).
17228
+ * Pre-provision (invite) an end user (server-side admin)
17229
+ */
17230
+ async inviteEndUserRaw(requestParameters, initOverrides) {
17231
+ if (requestParameters["inviteEndUserRequest"] == null) {
17232
+ throw new RequiredError(
17233
+ "inviteEndUserRequest",
17234
+ 'Required parameter "inviteEndUserRequest" was null or undefined when calling inviteEndUser().'
17235
+ );
17236
+ }
17237
+ const queryParameters = {};
17238
+ const headerParameters = {};
17239
+ headerParameters["Content-Type"] = "application/json";
17240
+ if (this.configuration && this.configuration.apiKey) {
17241
+ headerParameters["X-Application-Secret"] = await this.configuration.apiKey("X-Application-Secret");
17242
+ }
17243
+ if (this.configuration && this.configuration.apiKey) {
17244
+ headerParameters["X-Application-Key"] = await this.configuration.apiKey("X-Application-Key");
17245
+ }
17246
+ const response = await this.request({
17247
+ path: `/auth/users/invite`,
17248
+ method: "POST",
17249
+ headers: headerParameters,
17250
+ query: queryParameters,
17251
+ body: InviteEndUserRequestToJSON(requestParameters["inviteEndUserRequest"])
17252
+ }, initOverrides);
17253
+ return new VoidApiResponse(response);
17254
+ }
17255
+ /**
17256
+ * Secret-key-scoped pre-provisioning for an end user. Creates a passwordless user in the authenticating application (idempotent on email — an existing, non-deleted user is reused, not duplicated) and, when `send_link` is set, sends a first-login link so the user can set up their account without self-registration. - `send_link: \"magic\"` sends a magic-link sign-in email. - `send_link: \"password_reset\"` sends a set-password email. - `send_link: \"none\"` (default) creates the user with no email. A `redirect_url` is required when `send_link` is \"magic\" or \"password_reset\"; it must match the application\'s redirect_uris allowlist (custom schemes such as yourapp://path are permitted).
17257
+ * Pre-provision (invite) an end user (server-side admin)
17258
+ */
17259
+ async inviteEndUser(inviteEndUserRequest, initOverrides) {
17260
+ await this.inviteEndUserRaw({ inviteEndUserRequest }, initOverrides);
17261
+ }
17262
+ /**
17263
+ * Secret-key-scoped directory listing of end users in the authenticating application. Supports substring search over email, name, and phone, an optional environment filter (test/live), and pagination. Scoped to the application — never returns users from another application.
17264
+ * List / search end users (server-side admin)
17265
+ */
17266
+ async listEndUsersRaw(requestParameters, initOverrides) {
17267
+ const queryParameters = {};
17268
+ if (requestParameters["page"] != null) {
17269
+ queryParameters["page"] = requestParameters["page"];
17270
+ }
17271
+ if (requestParameters["perPage"] != null) {
17272
+ queryParameters["per_page"] = requestParameters["perPage"];
17273
+ }
17274
+ if (requestParameters["search"] != null) {
17275
+ queryParameters["search"] = requestParameters["search"];
17276
+ }
17277
+ if (requestParameters["environment"] != null) {
17278
+ queryParameters["environment"] = requestParameters["environment"];
17279
+ }
17280
+ const headerParameters = {};
17281
+ if (this.configuration && this.configuration.apiKey) {
17282
+ headerParameters["X-Application-Secret"] = await this.configuration.apiKey("X-Application-Secret");
17283
+ }
17284
+ if (this.configuration && this.configuration.apiKey) {
17285
+ headerParameters["X-Application-Key"] = await this.configuration.apiKey("X-Application-Key");
17286
+ }
17287
+ const response = await this.request({
17288
+ path: `/auth/users`,
17289
+ method: "GET",
17290
+ headers: headerParameters,
17291
+ query: queryParameters
17292
+ }, initOverrides);
17293
+ return new VoidApiResponse(response);
17294
+ }
17295
+ /**
17296
+ * Secret-key-scoped directory listing of end users in the authenticating application. Supports substring search over email, name, and phone, an optional environment filter (test/live), and pagination. Scoped to the application — never returns users from another application.
17297
+ * List / search end users (server-side admin)
17298
+ */
17299
+ async listEndUsers(page, perPage, search, environment, initOverrides) {
17300
+ await this.listEndUsersRaw({ page, perPage, search, environment }, initOverrides);
17301
+ }
17302
+ /**
17303
+ * Secret-key-scoped upsert of the authoritative custom_claims for an end user. Set server-side only — clients cannot write these, which is what makes them safe for authorization (e.g. an account-type/admin flag). Claims are embedded into the user\'s JWTs on the next login/refresh. Max 4KB; reserved JWT/Zyphr claim names are rejected. To make a change take effect immediately on already-issued tokens (e.g. revoking admin), call POST /auth/sessions/revoke-all for the user after updating claims — that bumps the revocation epoch so outstanding access tokens stop verifying.
17304
+ * Set an end user\'s stored custom claims (server-side admin)
17305
+ */
17306
+ async setEndUserClaimsRaw(requestParameters, initOverrides) {
17307
+ if (requestParameters["userId"] == null) {
17308
+ throw new RequiredError(
17309
+ "userId",
17310
+ 'Required parameter "userId" was null or undefined when calling setEndUserClaims().'
17311
+ );
17312
+ }
17313
+ if (requestParameters["setEndUserClaimsRequest"] == null) {
17314
+ throw new RequiredError(
17315
+ "setEndUserClaimsRequest",
17316
+ 'Required parameter "setEndUserClaimsRequest" was null or undefined when calling setEndUserClaims().'
17317
+ );
17318
+ }
17319
+ const queryParameters = {};
17320
+ const headerParameters = {};
17321
+ headerParameters["Content-Type"] = "application/json";
17322
+ if (this.configuration && this.configuration.apiKey) {
17323
+ headerParameters["X-Application-Secret"] = await this.configuration.apiKey("X-Application-Secret");
17324
+ }
17325
+ if (this.configuration && this.configuration.apiKey) {
17326
+ headerParameters["X-Application-Key"] = await this.configuration.apiKey("X-Application-Key");
17327
+ }
17328
+ const response = await this.request({
17329
+ path: `/auth/users/{user_id}/claims`.replace(`{${"user_id"}}`, encodeURIComponent(String(requestParameters["userId"]))),
17330
+ method: "PUT",
17331
+ headers: headerParameters,
17332
+ query: queryParameters,
17333
+ body: SetEndUserClaimsRequestToJSON(requestParameters["setEndUserClaimsRequest"])
17334
+ }, initOverrides);
17335
+ return new VoidApiResponse(response);
17336
+ }
17337
+ /**
17338
+ * Secret-key-scoped upsert of the authoritative custom_claims for an end user. Set server-side only — clients cannot write these, which is what makes them safe for authorization (e.g. an account-type/admin flag). Claims are embedded into the user\'s JWTs on the next login/refresh. Max 4KB; reserved JWT/Zyphr claim names are rejected. To make a change take effect immediately on already-issued tokens (e.g. revoking admin), call POST /auth/sessions/revoke-all for the user after updating claims — that bumps the revocation epoch so outstanding access tokens stop verifying.
17339
+ * Set an end user\'s stored custom claims (server-side admin)
17340
+ */
17341
+ async setEndUserClaims(userId, setEndUserClaimsRequest, initOverrides) {
17342
+ await this.setEndUserClaimsRaw({ userId, setEndUserClaimsRequest }, initOverrides);
17343
+ }
17344
+ /**
17345
+ * Secret-key-scoped update of an arbitrary end user in the authenticating application. Updatable fields: email, name, avatar_url, metadata, status. Scoped to the application — a caller can never modify a user belonging to another application.
17346
+ * Update an end user (server-side admin)
17347
+ */
17348
+ async updateEndUserByApplicationRaw(requestParameters, initOverrides) {
17349
+ if (requestParameters["userId"] == null) {
17350
+ throw new RequiredError(
17351
+ "userId",
17352
+ 'Required parameter "userId" was null or undefined when calling updateEndUserByApplication().'
17353
+ );
17354
+ }
17355
+ if (requestParameters["updateEndUserByApplicationRequest"] == null) {
17356
+ throw new RequiredError(
17357
+ "updateEndUserByApplicationRequest",
17358
+ 'Required parameter "updateEndUserByApplicationRequest" was null or undefined when calling updateEndUserByApplication().'
17359
+ );
17360
+ }
17361
+ const queryParameters = {};
17362
+ const headerParameters = {};
17363
+ headerParameters["Content-Type"] = "application/json";
17364
+ if (this.configuration && this.configuration.apiKey) {
17365
+ headerParameters["X-Application-Secret"] = await this.configuration.apiKey("X-Application-Secret");
17366
+ }
17367
+ if (this.configuration && this.configuration.apiKey) {
17368
+ headerParameters["X-Application-Key"] = await this.configuration.apiKey("X-Application-Key");
17369
+ }
17370
+ const response = await this.request({
17371
+ path: `/auth/users/{user_id}`.replace(`{${"user_id"}}`, encodeURIComponent(String(requestParameters["userId"]))),
17372
+ method: "PATCH",
17373
+ headers: headerParameters,
17374
+ query: queryParameters,
17375
+ body: UpdateEndUserByApplicationRequestToJSON(requestParameters["updateEndUserByApplicationRequest"])
17376
+ }, initOverrides);
17377
+ return new VoidApiResponse(response);
17378
+ }
17379
+ /**
17380
+ * Secret-key-scoped update of an arbitrary end user in the authenticating application. Updatable fields: email, name, avatar_url, metadata, status. Scoped to the application — a caller can never modify a user belonging to another application.
17381
+ * Update an end user (server-side admin)
17382
+ */
17383
+ async updateEndUserByApplication(userId, updateEndUserByApplicationRequest, initOverrides) {
17384
+ await this.updateEndUserByApplicationRaw({ userId, updateEndUserByApplicationRequest }, initOverrides);
17385
+ }
17386
+ };
17387
+ var ListEndUsersEnvironmentEnum = {
17388
+ TEST: "test",
17389
+ LIVE: "live"
17390
+ };
17391
+
17392
+ // src/src/apis/AuthUserProfileApi.ts
17393
+ var AuthUserProfileApi = class extends BaseAPI {
17394
+ /**
17395
+ * Delete the current end user account (GDPR right to erasure). This is a soft delete — the account is marked as deleted but data is retained for a period to allow for recovery or legal requirements.
17396
+ * Delete current end user account
17397
+ */
17398
+ async deleteEndUserRaw(initOverrides) {
17399
+ const queryParameters = {};
17400
+ const headerParameters = {};
17401
+ if (this.configuration && this.configuration.accessToken) {
17402
+ const token = this.configuration.accessToken;
17403
+ const tokenString = await token("EndUserToken", []);
17404
+ if (tokenString) {
17405
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
17406
+ }
17407
+ }
17408
+ if (this.configuration && this.configuration.apiKey) {
17409
+ headerParameters["X-Application-Key"] = await this.configuration.apiKey("X-Application-Key");
17410
+ }
17411
+ const response = await this.request({
17412
+ path: `/auth/users/me`,
17413
+ method: "DELETE",
17414
+ headers: headerParameters,
17415
+ query: queryParameters
17416
+ }, initOverrides);
17417
+ return new JSONApiResponse(response, (jsonValue) => EndUserDeleteResponseFromJSON(jsonValue));
17418
+ }
17419
+ /**
17420
+ * Delete the current end user account (GDPR right to erasure). This is a soft delete — the account is marked as deleted but data is retained for a period to allow for recovery or legal requirements.
17421
+ * Delete current end user account
17422
+ */
17423
+ async deleteEndUser(initOverrides) {
17424
+ const response = await this.deleteEndUserRaw(initOverrides);
17425
+ return await response.value();
16908
17426
  }
16909
17427
  /**
16910
17428
  * Retrieve the profile of the currently authenticated end user.
@@ -20722,6 +21240,49 @@ var TemplatesApi = class extends BaseAPI {
20722
21240
  const response = await this.renderTemplateRaw({ id, renderTemplateRequest }, initOverrides);
20723
21241
  return await response.value();
20724
21242
  }
21243
+ /**
21244
+ * Render the template and send a one-off test email (dashboard JWT auth). Because this is a send-capable endpoint, a frozen account receives `403 account_frozen` and a throttled account receives `429 account_throttled`.
21245
+ * Send a test email using a template
21246
+ */
21247
+ async sendTemplateTestEmailRaw(requestParameters, initOverrides) {
21248
+ if (requestParameters["id"] == null) {
21249
+ throw new RequiredError(
21250
+ "id",
21251
+ 'Required parameter "id" was null or undefined when calling sendTemplateTestEmail().'
21252
+ );
21253
+ }
21254
+ if (requestParameters["sendTemplateTestEmailRequest"] == null) {
21255
+ throw new RequiredError(
21256
+ "sendTemplateTestEmailRequest",
21257
+ 'Required parameter "sendTemplateTestEmailRequest" was null or undefined when calling sendTemplateTestEmail().'
21258
+ );
21259
+ }
21260
+ const queryParameters = {};
21261
+ const headerParameters = {};
21262
+ headerParameters["Content-Type"] = "application/json";
21263
+ if (this.configuration && this.configuration.accessToken) {
21264
+ const token = this.configuration.accessToken;
21265
+ const tokenString = await token("DashboardAuth", []);
21266
+ if (tokenString) {
21267
+ headerParameters["Authorization"] = `Bearer ${tokenString}`;
21268
+ }
21269
+ }
21270
+ const response = await this.request({
21271
+ path: `/templates/{id}/test`.replace(`{${"id"}}`, encodeURIComponent(String(requestParameters["id"]))),
21272
+ method: "POST",
21273
+ headers: headerParameters,
21274
+ query: queryParameters,
21275
+ body: SendTemplateTestEmailRequestToJSON(requestParameters["sendTemplateTestEmailRequest"])
21276
+ }, initOverrides);
21277
+ return new VoidApiResponse(response);
21278
+ }
21279
+ /**
21280
+ * Render the template and send a one-off test email (dashboard JWT auth). Because this is a send-capable endpoint, a frozen account receives `403 account_frozen` and a throttled account receives `429 account_throttled`.
21281
+ * Send a test email using a template
21282
+ */
21283
+ async sendTemplateTestEmail(id, sendTemplateTestEmailRequest, initOverrides) {
21284
+ await this.sendTemplateTestEmailRaw({ id, sendTemplateTestEmailRequest }, initOverrides);
21285
+ }
20725
21286
  /**
20726
21287
  * Update an existing template. Only provided fields are changed.
20727
21288
  * Update template
@@ -23032,34 +23593,34 @@ var ZyphrError = class extends Error {
23032
23593
  }
23033
23594
  };
23034
23595
  var ZyphrValidationError = class extends ZyphrError {
23035
- constructor(message, details) {
23036
- super({ message, status: 422, code: "validation_error", details });
23596
+ constructor(message, details, code = "validation_error") {
23597
+ super({ message, status: 422, code, details });
23037
23598
  this.name = "ZyphrValidationError";
23038
23599
  }
23039
23600
  };
23040
23601
  var ZyphrAuthenticationError = class extends ZyphrError {
23041
- constructor(message) {
23042
- super({ message, status: 401, code: "authentication_error" });
23602
+ constructor(message, code = "authentication_error") {
23603
+ super({ message, status: 401, code });
23043
23604
  this.name = "ZyphrAuthenticationError";
23044
23605
  }
23045
23606
  };
23046
23607
  var ZyphrRateLimitError = class extends ZyphrError {
23047
23608
  retryAfter;
23048
- constructor(message, retryAfter) {
23049
- super({ message, status: 429, code: "rate_limit_exceeded" });
23609
+ constructor(message, retryAfter, code = "rate_limit_exceeded") {
23610
+ super({ message, status: 429, code });
23050
23611
  this.name = "ZyphrRateLimitError";
23051
23612
  this.retryAfter = retryAfter;
23052
23613
  }
23053
23614
  };
23054
23615
  var ZyphrNotFoundError = class extends ZyphrError {
23055
- constructor(message) {
23056
- super({ message, status: 404, code: "not_found" });
23616
+ constructor(message, code = "not_found") {
23617
+ super({ message, status: 404, code });
23057
23618
  this.name = "ZyphrNotFoundError";
23058
23619
  }
23059
23620
  };
23060
23621
  var ZyphrPayloadTooLargeError = class extends ZyphrError {
23061
- constructor(message, details, requestId) {
23062
- super({ message, status: 413, code: "payload_too_large", details, requestId });
23622
+ constructor(message, details, requestId, code = "payload_too_large") {
23623
+ super({ message, status: 413, code, details, requestId });
23063
23624
  this.name = "ZyphrPayloadTooLargeError";
23064
23625
  }
23065
23626
  /** Maximum allowed request body size in bytes (server-enforced). */
@@ -23089,24 +23650,24 @@ async function parseErrorResponse(response) {
23089
23650
  const error = body.error ?? {};
23090
23651
  const meta = body.meta ?? {};
23091
23652
  const message = error.message ?? response.statusText ?? "Unknown error";
23092
- const code = error.code;
23653
+ const code = error.code || void 0;
23093
23654
  const requestId = meta.request_id;
23094
23655
  const details = error.details;
23095
23656
  switch (response.status) {
23096
23657
  case 400:
23097
23658
  case 422:
23098
- return new ZyphrValidationError(message, details);
23659
+ return new ZyphrValidationError(message, details, code);
23099
23660
  case 401:
23100
23661
  case 403:
23101
- return new ZyphrAuthenticationError(message);
23662
+ return new ZyphrAuthenticationError(message, code);
23102
23663
  case 404:
23103
- return new ZyphrNotFoundError(message);
23664
+ return new ZyphrNotFoundError(message, code);
23104
23665
  case 413:
23105
- return new ZyphrPayloadTooLargeError(message, details, requestId);
23666
+ return new ZyphrPayloadTooLargeError(message, details, requestId, code);
23106
23667
  case 429: {
23107
23668
  const retryAfterHeader = response.headers.get("Retry-After");
23108
23669
  const retryAfter = retryAfterHeader ? parseInt(retryAfterHeader, 10) : void 0;
23109
- return new ZyphrRateLimitError(message, retryAfter);
23670
+ return new ZyphrRateLimitError(message, retryAfter, code);
23110
23671
  }
23111
23672
  default:
23112
23673
  return new ZyphrError({ message, status: response.status, code, requestId, details });
@@ -23217,6 +23778,99 @@ var Zyphr = class {
23217
23778
  }
23218
23779
  };
23219
23780
 
23781
+ // src/clientAuth.ts
23782
+ var errorMiddleware2 = {
23783
+ async post(context) {
23784
+ if (context.response.status >= 200 && context.response.status < 300) {
23785
+ return;
23786
+ }
23787
+ throw await parseErrorResponse(context.response);
23788
+ }
23789
+ };
23790
+ var ZyphrClientCredentialError = class extends Error {
23791
+ constructor(message) {
23792
+ super(message);
23793
+ this.name = "ZyphrClientCredentialError";
23794
+ }
23795
+ };
23796
+ var SECRET_KEY_PREFIXES = ["za_sec_", "zy_live_", "zy_test_"];
23797
+ var ZyphrClient = class {
23798
+ auth;
23799
+ /** Device registration for push (takes an OS-acquired token). */
23800
+ devices;
23801
+ applicationKey;
23802
+ accessToken;
23803
+ constructor(options) {
23804
+ if (!options.applicationKey) {
23805
+ throw new ZyphrClientCredentialError("applicationKey (za_pub_*) is required");
23806
+ }
23807
+ if (SECRET_KEY_PREFIXES.some((p) => options.applicationKey.startsWith(p))) {
23808
+ throw new ZyphrClientCredentialError(
23809
+ "ZyphrClient must be constructed with a publishable application key (za_pub_*), never a secret key. Secret keys must stay server-side."
23810
+ );
23811
+ }
23812
+ if (!options.applicationKey.startsWith("za_pub_")) {
23813
+ throw new ZyphrClientCredentialError(
23814
+ "applicationKey must be a publishable application key (za_pub_*)."
23815
+ );
23816
+ }
23817
+ this.applicationKey = options.applicationKey;
23818
+ this.accessToken = options.accessToken;
23819
+ const config = new Configuration({
23820
+ basePath: options.baseUrl,
23821
+ // The only credential this client sends automatically is the publishable
23822
+ // application key. End-user Bearer tokens are attached per-request via
23823
+ // authedRequest() so token rotation doesn't require rebuilding the client.
23824
+ apiKey: (name) => name === "X-Application-Key" ? this.applicationKey : "",
23825
+ middleware: [errorMiddleware2]
23826
+ });
23827
+ this.auth = {
23828
+ login: new AuthLoginApi(config),
23829
+ registration: new AuthRegistrationApi(config),
23830
+ sessions: new AuthSessionsApi(config),
23831
+ emailVerification: new AuthEmailVerificationApi(config),
23832
+ passwordReset: new AuthPasswordResetApi(config),
23833
+ mfa: new AuthMFAApi(config),
23834
+ magicLinks: new AuthMagicLinksApi(config),
23835
+ oauth: new AuthOAuthApi(config),
23836
+ organizations: new AuthOrganizationsApi(config),
23837
+ phone: new AuthPhoneApi(config),
23838
+ emailOtp: new AuthEmailOTPApi(config),
23839
+ profile: new AuthUserProfileApi(config),
23840
+ webauthn: new AuthWebAuthnApi(config)
23841
+ };
23842
+ this.devices = new DevicesApi(config);
23843
+ }
23844
+ /** Store the end-user access token for subsequent authedRequest() calls. */
23845
+ setAccessToken(accessToken) {
23846
+ this.accessToken = accessToken;
23847
+ }
23848
+ /** True when an end-user access token is currently set. */
23849
+ get isAuthenticated() {
23850
+ return Boolean(this.accessToken);
23851
+ }
23852
+ /**
23853
+ * Build request overrides that authenticate as the current end user: the
23854
+ * stored Bearer token plus the publishable application key required by
23855
+ * user-scoped endpoints. Pass an explicit token to override the stored one.
23856
+ *
23857
+ * @example
23858
+ * ```ts
23859
+ * const me = await zyphr.auth.profile.getEndUser(zyphr.authedRequest());
23860
+ * ```
23861
+ */
23862
+ authedRequest(accessToken) {
23863
+ const token = accessToken ?? this.accessToken;
23864
+ const headers = {
23865
+ "X-Application-Key": this.applicationKey
23866
+ };
23867
+ if (token) {
23868
+ headers.Authorization = `Bearer ${token}`;
23869
+ }
23870
+ return { headers };
23871
+ }
23872
+ };
23873
+
23220
23874
  // src/index.ts
23221
23875
  var SDK_VERSION = "0.1.0";
23222
23876
  export {
@@ -23363,6 +24017,7 @@ export {
23363
24017
  AuthTokensFromJSONTyped,
23364
24018
  AuthTokensToJSON,
23365
24019
  AuthTokensToJSONTyped,
24020
+ AuthUserDirectoryApi,
23366
24021
  AuthUserFromJSON,
23367
24022
  AuthUserFromJSONTyped,
23368
24023
  AuthUserProfileApi,
@@ -23777,10 +24432,16 @@ export {
23777
24432
  InboxNotificationResponseFromJSONTyped,
23778
24433
  InboxNotificationResponseToJSON,
23779
24434
  InboxNotificationResponseToJSONTyped,
24435
+ InviteEndUserRequestFromJSON,
24436
+ InviteEndUserRequestFromJSONTyped,
24437
+ InviteEndUserRequestSendLinkEnum,
24438
+ InviteEndUserRequestToJSON,
24439
+ InviteEndUserRequestToJSONTyped,
23780
24440
  JSONApiResponse,
23781
24441
  ListAllInboxStatusEnum,
23782
24442
  ListDevicesPlatformEnum,
23783
24443
  ListEmailsStatusEnum,
24444
+ ListEndUsersEnvironmentEnum,
23784
24445
  ListInboundEmailsStatusEnum,
23785
24446
  ListPushStatusEnum,
23786
24447
  ListSlackMessagesStatusEnum,
@@ -23967,6 +24628,11 @@ export {
23967
24628
  OAuthProviderInfoFromJSONTyped,
23968
24629
  OAuthProviderInfoToJSON,
23969
24630
  OAuthProviderInfoToJSONTyped,
24631
+ OAuthProviderName,
24632
+ OAuthProviderNameFromJSON,
24633
+ OAuthProviderNameFromJSONTyped,
24634
+ OAuthProviderNameToJSON,
24635
+ OAuthProviderNameToJSONTyped,
23970
24636
  OAuthProviderToJSON,
23971
24637
  OAuthProviderToJSONTyped,
23972
24638
  OAuthProvidersResponseDataFromJSON,
@@ -24360,6 +25026,10 @@ export {
24360
25026
  SendSmsResponseFromJSONTyped,
24361
25027
  SendSmsResponseToJSON,
24362
25028
  SendSmsResponseToJSONTyped,
25029
+ SendTemplateTestEmailRequestFromJSON,
25030
+ SendTemplateTestEmailRequestFromJSONTyped,
25031
+ SendTemplateTestEmailRequestToJSON,
25032
+ SendTemplateTestEmailRequestToJSONTyped,
24363
25033
  SendTestSmsDataFromJSON,
24364
25034
  SendTestSmsDataFromJSONTyped,
24365
25035
  SendTestSmsDataToJSON,
@@ -24392,6 +25062,10 @@ export {
24392
25062
  SetDomainInboundRequestFromJSONTyped,
24393
25063
  SetDomainInboundRequestToJSON,
24394
25064
  SetDomainInboundRequestToJSONTyped,
25065
+ SetEndUserClaimsRequestFromJSON,
25066
+ SetEndUserClaimsRequestFromJSONTyped,
25067
+ SetEndUserClaimsRequestToJSON,
25068
+ SetEndUserClaimsRequestToJSONTyped,
24395
25069
  SetPreferencesRequestFromJSON,
24396
25070
  SetPreferencesRequestFromJSONTyped,
24397
25071
  SetPreferencesRequestPreferencesInnerFromJSON,
@@ -24404,6 +25078,10 @@ export {
24404
25078
  SignInAnonymouslyRequestFromJSONTyped,
24405
25079
  SignInAnonymouslyRequestToJSON,
24406
25080
  SignInAnonymouslyRequestToJSONTyped,
25081
+ SignInWithGameCenterRequestFromJSON,
25082
+ SignInWithGameCenterRequestFromJSONTyped,
25083
+ SignInWithGameCenterRequestToJSON,
25084
+ SignInWithGameCenterRequestToJSONTyped,
24407
25085
  SlackApi,
24408
25086
  SlackMessageFromJSON,
24409
25087
  SlackMessageFromJSONTyped,
@@ -24637,6 +25315,10 @@ export {
24637
25315
  UpdateCategoryRequestFromJSONTyped,
24638
25316
  UpdateCategoryRequestToJSON,
24639
25317
  UpdateCategoryRequestToJSONTyped,
25318
+ UpdateEndUserByApplicationRequestFromJSON,
25319
+ UpdateEndUserByApplicationRequestFromJSONTyped,
25320
+ UpdateEndUserByApplicationRequestToJSON,
25321
+ UpdateEndUserByApplicationRequestToJSONTyped,
24640
25322
  UpdateEndUserRequestFromJSON,
24641
25323
  UpdateEndUserRequestFromJSONTyped,
24642
25324
  UpdateEndUserRequestToJSON,
@@ -25054,6 +25736,8 @@ export {
25054
25736
  WorkflowStepExecutionToJSONTyped,
25055
25737
  Zyphr,
25056
25738
  ZyphrAuthenticationError,
25739
+ ZyphrClient,
25740
+ ZyphrClientCredentialError,
25057
25741
  ZyphrError,
25058
25742
  ZyphrNotFoundError,
25059
25743
  ZyphrPayloadTooLargeError,
@@ -25188,6 +25872,7 @@ export {
25188
25872
  instanceOfInboxListMeta,
25189
25873
  instanceOfInboxListResponse,
25190
25874
  instanceOfInboxNotificationResponse,
25875
+ instanceOfInviteEndUserRequest,
25191
25876
  instanceOfListWaaSApplications200Response,
25192
25877
  instanceOfListWaaSEndpointDeliveries200Response,
25193
25878
  instanceOfListWaaSEndpoints200Response,
@@ -25232,6 +25917,7 @@ export {
25232
25917
  instanceOfOAuthConnectionsResponseData,
25233
25918
  instanceOfOAuthProvider,
25234
25919
  instanceOfOAuthProviderInfo,
25920
+ instanceOfOAuthProviderName,
25235
25921
  instanceOfOAuthProvidersResponse,
25236
25922
  instanceOfOAuthProvidersResponseData,
25237
25923
  instanceOfOAuthTokensRefreshResponse,
@@ -25326,6 +26012,7 @@ export {
25326
26012
  instanceOfSendSmsData,
25327
26013
  instanceOfSendSmsRequest,
25328
26014
  instanceOfSendSmsResponse,
26015
+ instanceOfSendTemplateTestEmailRequest,
25329
26016
  instanceOfSendTestSmsData,
25330
26017
  instanceOfSendTestSmsRequest,
25331
26018
  instanceOfSendTestSmsResponse,
@@ -25334,9 +26021,11 @@ export {
25334
26021
  instanceOfSessionListResponseData,
25335
26022
  instanceOfSessionListResponseDataSessionInfo,
25336
26023
  instanceOfSetDomainInboundRequest,
26024
+ instanceOfSetEndUserClaimsRequest,
25337
26025
  instanceOfSetPreferencesRequest,
25338
26026
  instanceOfSetPreferencesRequestPreferencesInner,
25339
26027
  instanceOfSignInAnonymouslyRequest,
26028
+ instanceOfSignInWithGameCenterRequest,
25340
26029
  instanceOfSlackMessage,
25341
26030
  instanceOfSlackMessageListResponse,
25342
26031
  instanceOfSlackMessageListResponseMeta,
@@ -25392,6 +26081,7 @@ export {
25392
26081
  instanceOfUnsubscribeRequest,
25393
26082
  instanceOfUnsubscribeResponse,
25394
26083
  instanceOfUpdateCategoryRequest,
26084
+ instanceOfUpdateEndUserByApplicationRequest,
25395
26085
  instanceOfUpdateEndUserRequest,
25396
26086
  instanceOfUpdateOrganizationMemberRoleRequest,
25397
26087
  instanceOfUpdateOrganizationRequest,