@zyphr-dev/node-sdk 0.1.68 → 0.1.69
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.
- package/dist/index.cjs +230 -14
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +274 -21
- package/dist/index.d.ts +274 -21
- package/dist/index.js +204 -14
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
- package/src/.openapi-generator/FILES +5 -0
- package/src/src/apis/AuthMagicLinksApi.ts +12 -12
- package/src/src/apis/AuthPasswordResetApi.ts +12 -12
- package/src/src/apis/AuthUserDirectoryApi.ts +4 -4
- package/src/src/models/ForgotPasswordRequest.ts +11 -0
- package/src/src/models/ForgotPasswordResult.ts +88 -0
- package/src/src/models/ForgotPasswordResultData.ts +100 -0
- package/src/src/models/InviteEndUser200ResponseData.ts +16 -0
- package/src/src/models/InviteEndUserRequest.ts +8 -0
- package/src/src/models/MagicLinkSendRequest.ts +11 -0
- package/src/src/models/MagicLinkSendResult.ts +88 -0
- package/src/src/models/MagicLinkSendResultData.ts +81 -0
- package/src/src/models/ReturnedAuthLink.ts +87 -0
- package/src/src/models/index.ts +5 -0
package/dist/index.js
CHANGED
|
@@ -5036,7 +5036,8 @@ function ForgotPasswordRequestFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
5036
5036
|
}
|
|
5037
5037
|
return {
|
|
5038
5038
|
"email": json["email"],
|
|
5039
|
-
"redirectUrl": json["redirect_url"] == null ? void 0 : json["redirect_url"]
|
|
5039
|
+
"redirectUrl": json["redirect_url"] == null ? void 0 : json["redirect_url"],
|
|
5040
|
+
"returnLink": json["return_link"] == null ? void 0 : json["return_link"]
|
|
5040
5041
|
};
|
|
5041
5042
|
}
|
|
5042
5043
|
function ForgotPasswordRequestToJSON(json) {
|
|
@@ -5048,7 +5049,106 @@ function ForgotPasswordRequestToJSONTyped(value, ignoreDiscriminator = false) {
|
|
|
5048
5049
|
}
|
|
5049
5050
|
return {
|
|
5050
5051
|
"email": value["email"],
|
|
5051
|
-
"redirect_url": value["redirectUrl"]
|
|
5052
|
+
"redirect_url": value["redirectUrl"],
|
|
5053
|
+
"return_link": value["returnLink"]
|
|
5054
|
+
};
|
|
5055
|
+
}
|
|
5056
|
+
|
|
5057
|
+
// src/src/models/ReturnedAuthLink.ts
|
|
5058
|
+
function instanceOfReturnedAuthLink(value) {
|
|
5059
|
+
if (!("url" in value) || value["url"] === void 0) return false;
|
|
5060
|
+
if (!("token" in value) || value["token"] === void 0) return false;
|
|
5061
|
+
if (!("expiresAt" in value) || value["expiresAt"] === void 0) return false;
|
|
5062
|
+
return true;
|
|
5063
|
+
}
|
|
5064
|
+
function ReturnedAuthLinkFromJSON(json) {
|
|
5065
|
+
return ReturnedAuthLinkFromJSONTyped(json, false);
|
|
5066
|
+
}
|
|
5067
|
+
function ReturnedAuthLinkFromJSONTyped(json, ignoreDiscriminator) {
|
|
5068
|
+
if (json == null) {
|
|
5069
|
+
return json;
|
|
5070
|
+
}
|
|
5071
|
+
return {
|
|
5072
|
+
"url": json["url"],
|
|
5073
|
+
"token": json["token"],
|
|
5074
|
+
"expiresAt": new Date(json["expires_at"])
|
|
5075
|
+
};
|
|
5076
|
+
}
|
|
5077
|
+
function ReturnedAuthLinkToJSON(json) {
|
|
5078
|
+
return ReturnedAuthLinkToJSONTyped(json, false);
|
|
5079
|
+
}
|
|
5080
|
+
function ReturnedAuthLinkToJSONTyped(value, ignoreDiscriminator = false) {
|
|
5081
|
+
if (value == null) {
|
|
5082
|
+
return value;
|
|
5083
|
+
}
|
|
5084
|
+
return {
|
|
5085
|
+
"url": value["url"],
|
|
5086
|
+
"token": value["token"],
|
|
5087
|
+
"expires_at": value["expiresAt"].toISOString()
|
|
5088
|
+
};
|
|
5089
|
+
}
|
|
5090
|
+
|
|
5091
|
+
// src/src/models/ForgotPasswordResultData.ts
|
|
5092
|
+
var ForgotPasswordResultDataLinkSuppressedReasonEnum = {
|
|
5093
|
+
USER_NOT_FOUND: "user_not_found",
|
|
5094
|
+
IDENTITY_HAS_OTHER_AUTH_METHODS: "identity_has_other_auth_methods"
|
|
5095
|
+
};
|
|
5096
|
+
function instanceOfForgotPasswordResultData(value) {
|
|
5097
|
+
return true;
|
|
5098
|
+
}
|
|
5099
|
+
function ForgotPasswordResultDataFromJSON(json) {
|
|
5100
|
+
return ForgotPasswordResultDataFromJSONTyped(json, false);
|
|
5101
|
+
}
|
|
5102
|
+
function ForgotPasswordResultDataFromJSONTyped(json, ignoreDiscriminator) {
|
|
5103
|
+
if (json == null) {
|
|
5104
|
+
return json;
|
|
5105
|
+
}
|
|
5106
|
+
return {
|
|
5107
|
+
"success": json["success"] == null ? void 0 : json["success"],
|
|
5108
|
+
"link": json["link"] == null ? void 0 : ReturnedAuthLinkFromJSON(json["link"]),
|
|
5109
|
+
"linkSuppressedReason": json["link_suppressed_reason"] == null ? void 0 : json["link_suppressed_reason"]
|
|
5110
|
+
};
|
|
5111
|
+
}
|
|
5112
|
+
function ForgotPasswordResultDataToJSON(json) {
|
|
5113
|
+
return ForgotPasswordResultDataToJSONTyped(json, false);
|
|
5114
|
+
}
|
|
5115
|
+
function ForgotPasswordResultDataToJSONTyped(value, ignoreDiscriminator = false) {
|
|
5116
|
+
if (value == null) {
|
|
5117
|
+
return value;
|
|
5118
|
+
}
|
|
5119
|
+
return {
|
|
5120
|
+
"success": value["success"],
|
|
5121
|
+
"link": ReturnedAuthLinkToJSON(value["link"]),
|
|
5122
|
+
"link_suppressed_reason": value["linkSuppressedReason"]
|
|
5123
|
+
};
|
|
5124
|
+
}
|
|
5125
|
+
|
|
5126
|
+
// src/src/models/ForgotPasswordResult.ts
|
|
5127
|
+
function instanceOfForgotPasswordResult(value) {
|
|
5128
|
+
return true;
|
|
5129
|
+
}
|
|
5130
|
+
function ForgotPasswordResultFromJSON(json) {
|
|
5131
|
+
return ForgotPasswordResultFromJSONTyped(json, false);
|
|
5132
|
+
}
|
|
5133
|
+
function ForgotPasswordResultFromJSONTyped(json, ignoreDiscriminator) {
|
|
5134
|
+
if (json == null) {
|
|
5135
|
+
return json;
|
|
5136
|
+
}
|
|
5137
|
+
return {
|
|
5138
|
+
"data": json["data"] == null ? void 0 : ForgotPasswordResultDataFromJSON(json["data"]),
|
|
5139
|
+
"meta": json["meta"] == null ? void 0 : GetDomain200ResponseMetaFromJSON(json["meta"])
|
|
5140
|
+
};
|
|
5141
|
+
}
|
|
5142
|
+
function ForgotPasswordResultToJSON(json) {
|
|
5143
|
+
return ForgotPasswordResultToJSONTyped(json, false);
|
|
5144
|
+
}
|
|
5145
|
+
function ForgotPasswordResultToJSONTyped(value, ignoreDiscriminator = false) {
|
|
5146
|
+
if (value == null) {
|
|
5147
|
+
return value;
|
|
5148
|
+
}
|
|
5149
|
+
return {
|
|
5150
|
+
"data": ForgotPasswordResultDataToJSON(value["data"]),
|
|
5151
|
+
"meta": GetDomain200ResponseMetaToJSON(value["meta"])
|
|
5052
5152
|
};
|
|
5053
5153
|
}
|
|
5054
5154
|
|
|
@@ -6513,6 +6613,7 @@ function InviteEndUser200ResponseDataFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
6513
6613
|
"userId": json["user_id"] == null ? void 0 : json["user_id"],
|
|
6514
6614
|
"created": json["created"] == null ? void 0 : json["created"],
|
|
6515
6615
|
"linkSent": json["link_sent"] == null ? void 0 : json["link_sent"],
|
|
6616
|
+
"link": json["link"] == null ? void 0 : ReturnedAuthLinkFromJSON(json["link"]),
|
|
6516
6617
|
"linkSuppressedReason": json["link_suppressed_reason"] == null ? void 0 : json["link_suppressed_reason"]
|
|
6517
6618
|
};
|
|
6518
6619
|
}
|
|
@@ -6527,6 +6628,7 @@ function InviteEndUser200ResponseDataToJSONTyped(value, ignoreDiscriminator = fa
|
|
|
6527
6628
|
"user_id": value["userId"],
|
|
6528
6629
|
"created": value["created"],
|
|
6529
6630
|
"link_sent": value["linkSent"],
|
|
6631
|
+
"link": ReturnedAuthLinkToJSON(value["link"]),
|
|
6530
6632
|
"link_suppressed_reason": value["linkSuppressedReason"]
|
|
6531
6633
|
};
|
|
6532
6634
|
}
|
|
@@ -6583,7 +6685,8 @@ function InviteEndUserRequestFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
6583
6685
|
"name": json["name"] == null ? void 0 : json["name"],
|
|
6584
6686
|
"metadata": json["metadata"] == null ? void 0 : json["metadata"],
|
|
6585
6687
|
"sendLink": json["send_link"] == null ? void 0 : json["send_link"],
|
|
6586
|
-
"redirectUrl": json["redirect_url"] == null ? void 0 : json["redirect_url"]
|
|
6688
|
+
"redirectUrl": json["redirect_url"] == null ? void 0 : json["redirect_url"],
|
|
6689
|
+
"returnLink": json["return_link"] == null ? void 0 : json["return_link"]
|
|
6587
6690
|
};
|
|
6588
6691
|
}
|
|
6589
6692
|
function InviteEndUserRequestToJSON(json) {
|
|
@@ -6598,7 +6701,8 @@ function InviteEndUserRequestToJSONTyped(value, ignoreDiscriminator = false) {
|
|
|
6598
6701
|
"name": value["name"],
|
|
6599
6702
|
"metadata": value["metadata"],
|
|
6600
6703
|
"send_link": value["sendLink"],
|
|
6601
|
-
"redirect_url": value["redirectUrl"]
|
|
6704
|
+
"redirect_url": value["redirectUrl"],
|
|
6705
|
+
"return_link": value["returnLink"]
|
|
6602
6706
|
};
|
|
6603
6707
|
}
|
|
6604
6708
|
|
|
@@ -6922,7 +7026,8 @@ function MagicLinkSendRequestFromJSONTyped(json, ignoreDiscriminator) {
|
|
|
6922
7026
|
}
|
|
6923
7027
|
return {
|
|
6924
7028
|
"email": json["email"],
|
|
6925
|
-
"redirectUrl": json["redirect_url"] == null ? void 0 : json["redirect_url"]
|
|
7029
|
+
"redirectUrl": json["redirect_url"] == null ? void 0 : json["redirect_url"],
|
|
7030
|
+
"returnLink": json["return_link"] == null ? void 0 : json["return_link"]
|
|
6926
7031
|
};
|
|
6927
7032
|
}
|
|
6928
7033
|
function MagicLinkSendRequestToJSON(json) {
|
|
@@ -6934,7 +7039,66 @@ function MagicLinkSendRequestToJSONTyped(value, ignoreDiscriminator = false) {
|
|
|
6934
7039
|
}
|
|
6935
7040
|
return {
|
|
6936
7041
|
"email": value["email"],
|
|
6937
|
-
"redirect_url": value["redirectUrl"]
|
|
7042
|
+
"redirect_url": value["redirectUrl"],
|
|
7043
|
+
"return_link": value["returnLink"]
|
|
7044
|
+
};
|
|
7045
|
+
}
|
|
7046
|
+
|
|
7047
|
+
// src/src/models/MagicLinkSendResultData.ts
|
|
7048
|
+
function instanceOfMagicLinkSendResultData(value) {
|
|
7049
|
+
return true;
|
|
7050
|
+
}
|
|
7051
|
+
function MagicLinkSendResultDataFromJSON(json) {
|
|
7052
|
+
return MagicLinkSendResultDataFromJSONTyped(json, false);
|
|
7053
|
+
}
|
|
7054
|
+
function MagicLinkSendResultDataFromJSONTyped(json, ignoreDiscriminator) {
|
|
7055
|
+
if (json == null) {
|
|
7056
|
+
return json;
|
|
7057
|
+
}
|
|
7058
|
+
return {
|
|
7059
|
+
"success": json["success"] == null ? void 0 : json["success"],
|
|
7060
|
+
"link": json["link"] == null ? void 0 : ReturnedAuthLinkFromJSON(json["link"])
|
|
7061
|
+
};
|
|
7062
|
+
}
|
|
7063
|
+
function MagicLinkSendResultDataToJSON(json) {
|
|
7064
|
+
return MagicLinkSendResultDataToJSONTyped(json, false);
|
|
7065
|
+
}
|
|
7066
|
+
function MagicLinkSendResultDataToJSONTyped(value, ignoreDiscriminator = false) {
|
|
7067
|
+
if (value == null) {
|
|
7068
|
+
return value;
|
|
7069
|
+
}
|
|
7070
|
+
return {
|
|
7071
|
+
"success": value["success"],
|
|
7072
|
+
"link": ReturnedAuthLinkToJSON(value["link"])
|
|
7073
|
+
};
|
|
7074
|
+
}
|
|
7075
|
+
|
|
7076
|
+
// src/src/models/MagicLinkSendResult.ts
|
|
7077
|
+
function instanceOfMagicLinkSendResult(value) {
|
|
7078
|
+
return true;
|
|
7079
|
+
}
|
|
7080
|
+
function MagicLinkSendResultFromJSON(json) {
|
|
7081
|
+
return MagicLinkSendResultFromJSONTyped(json, false);
|
|
7082
|
+
}
|
|
7083
|
+
function MagicLinkSendResultFromJSONTyped(json, ignoreDiscriminator) {
|
|
7084
|
+
if (json == null) {
|
|
7085
|
+
return json;
|
|
7086
|
+
}
|
|
7087
|
+
return {
|
|
7088
|
+
"data": json["data"] == null ? void 0 : MagicLinkSendResultDataFromJSON(json["data"]),
|
|
7089
|
+
"meta": json["meta"] == null ? void 0 : GetDomain200ResponseMetaFromJSON(json["meta"])
|
|
7090
|
+
};
|
|
7091
|
+
}
|
|
7092
|
+
function MagicLinkSendResultToJSON(json) {
|
|
7093
|
+
return MagicLinkSendResultToJSONTyped(json, false);
|
|
7094
|
+
}
|
|
7095
|
+
function MagicLinkSendResultToJSONTyped(value, ignoreDiscriminator = false) {
|
|
7096
|
+
if (value == null) {
|
|
7097
|
+
return value;
|
|
7098
|
+
}
|
|
7099
|
+
return {
|
|
7100
|
+
"data": MagicLinkSendResultDataToJSON(value["data"]),
|
|
7101
|
+
"meta": GetDomain200ResponseMetaToJSON(value["meta"])
|
|
6938
7102
|
};
|
|
6939
7103
|
}
|
|
6940
7104
|
|
|
@@ -18431,7 +18595,7 @@ var AuthMFAApi = class extends BaseAPI {
|
|
|
18431
18595
|
// src/src/apis/AuthMagicLinksApi.ts
|
|
18432
18596
|
var AuthMagicLinksApi = class extends BaseAPI {
|
|
18433
18597
|
/**
|
|
18434
|
-
* Send a magic link email for passwordless authentication.
|
|
18598
|
+
* Send a magic link email for passwordless authentication. **Sending the email yourself:** pass `return_link: true` (with `redirect_url`) and Zyphr mints the link but sends nothing, returning it in `data.link`. Requires your application secret, so call it server-side only.
|
|
18435
18599
|
* Send a magic link
|
|
18436
18600
|
*/
|
|
18437
18601
|
async sendMagicLinkRaw(requestParameters, initOverrides) {
|
|
@@ -18467,10 +18631,10 @@ var AuthMagicLinksApi = class extends BaseAPI {
|
|
|
18467
18631
|
query: queryParameters,
|
|
18468
18632
|
body: MagicLinkSendRequestToJSON(requestParameters["magicLinkSendRequest"])
|
|
18469
18633
|
}, initOverrides);
|
|
18470
|
-
return new JSONApiResponse(response, (jsonValue) =>
|
|
18634
|
+
return new JSONApiResponse(response, (jsonValue) => MagicLinkSendResultFromJSON(jsonValue));
|
|
18471
18635
|
}
|
|
18472
18636
|
/**
|
|
18473
|
-
* Send a magic link email for passwordless authentication.
|
|
18637
|
+
* Send a magic link email for passwordless authentication. **Sending the email yourself:** pass `return_link: true` (with `redirect_url`) and Zyphr mints the link but sends nothing, returning it in `data.link`. Requires your application secret, so call it server-side only.
|
|
18474
18638
|
* Send a magic link
|
|
18475
18639
|
*/
|
|
18476
18640
|
async sendMagicLink(magicLinkSendRequest, initOverrides) {
|
|
@@ -19521,7 +19685,7 @@ var AuthOrganizationsApi = class extends BaseAPI {
|
|
|
19521
19685
|
// src/src/apis/AuthPasswordResetApi.ts
|
|
19522
19686
|
var AuthPasswordResetApi = class extends BaseAPI {
|
|
19523
19687
|
/**
|
|
19524
|
-
* Request a password reset email. Creates a reset token and sends an email to the user. Always returns success to prevent email enumeration — the response is identical whether or not the address is registered. An identity with **no password set** still receives a link, which sets a first password. This covers users migrated from a provider that cannot export password hashes. The one case where no email is sent (beyond an unknown address) is an identity that has no password but *does* have another way in — a linked OAuth provider and/or a passkey. Those users are not locked out, so no set-password link is sent; the attempt is recorded as a suppressed message visible via `GET /emails`.
|
|
19688
|
+
* Request a password reset email. Creates a reset token and sends an email to the user. Always returns success to prevent email enumeration — the response is identical whether or not the address is registered. An identity with **no password set** still receives a link, which sets a first password. This covers users migrated from a provider that cannot export password hashes. The one case where no email is sent (beyond an unknown address) is an identity that has no password but *does* have another way in — a linked OAuth provider and/or a passkey. Those users are not locked out, so no set-password link is sent; the attempt is recorded as a suppressed message visible via `GET /emails`. **Sending the email yourself:** pass `return_link: true` (with `redirect_url`) and Zyphr mints the token but sends nothing, returning the link in `data.link`. When no link is minted, `data.link` is null and `data.link_suppressed_reason` says why. Unlike the default response, this reveals whether the address is registered — acceptable only because the endpoint requires your application secret, so it must only be called server-side.
|
|
19525
19689
|
* Request a password reset
|
|
19526
19690
|
*/
|
|
19527
19691
|
async forgotPasswordRaw(requestParameters, initOverrides) {
|
|
@@ -19557,10 +19721,10 @@ var AuthPasswordResetApi = class extends BaseAPI {
|
|
|
19557
19721
|
query: queryParameters,
|
|
19558
19722
|
body: ForgotPasswordRequestToJSON(requestParameters["forgotPasswordRequest"])
|
|
19559
19723
|
}, initOverrides);
|
|
19560
|
-
return new JSONApiResponse(response, (jsonValue) =>
|
|
19724
|
+
return new JSONApiResponse(response, (jsonValue) => ForgotPasswordResultFromJSON(jsonValue));
|
|
19561
19725
|
}
|
|
19562
19726
|
/**
|
|
19563
|
-
* Request a password reset email. Creates a reset token and sends an email to the user. Always returns success to prevent email enumeration — the response is identical whether or not the address is registered. An identity with **no password set** still receives a link, which sets a first password. This covers users migrated from a provider that cannot export password hashes. The one case where no email is sent (beyond an unknown address) is an identity that has no password but *does* have another way in — a linked OAuth provider and/or a passkey. Those users are not locked out, so no set-password link is sent; the attempt is recorded as a suppressed message visible via `GET /emails`.
|
|
19727
|
+
* Request a password reset email. Creates a reset token and sends an email to the user. Always returns success to prevent email enumeration — the response is identical whether or not the address is registered. An identity with **no password set** still receives a link, which sets a first password. This covers users migrated from a provider that cannot export password hashes. The one case where no email is sent (beyond an unknown address) is an identity that has no password but *does* have another way in — a linked OAuth provider and/or a passkey. Those users are not locked out, so no set-password link is sent; the attempt is recorded as a suppressed message visible via `GET /emails`. **Sending the email yourself:** pass `return_link: true` (with `redirect_url`) and Zyphr mints the token but sends nothing, returning the link in `data.link`. When no link is minted, `data.link` is null and `data.link_suppressed_reason` says why. Unlike the default response, this reveals whether the address is registered — acceptable only because the endpoint requires your application secret, so it must only be called server-side.
|
|
19564
19728
|
* Request a password reset
|
|
19565
19729
|
*/
|
|
19566
19730
|
async forgotPassword(forgotPasswordRequest, initOverrides) {
|
|
@@ -20497,7 +20661,7 @@ var AuthUserDirectoryApi = class extends BaseAPI {
|
|
|
20497
20661
|
return await response.value();
|
|
20498
20662
|
}
|
|
20499
20663
|
/**
|
|
20500
|
-
* 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: \"invitation\"` sends the `invitation` auth email: a set-password link (valid 7 days) redeemed at `POST /auth/reset-password`, so the invitee ends up with a password. It has its own per-application template, separate from password reset\'s. Not sent to an identity that can already sign in. - `send_link: \"password_reset\"` sends a set-password email using the password-reset template. - `send_link: \"magic\"` sends a magic-link sign-in email. The user still has no credential afterwards. - `send_link: \"none\"` (default) creates the user with no email. A `redirect_url` is required whenever `send_link` is not \"none\"; it must match the application\'s redirect_uris allowlist (custom schemes such as yourapp://path are permitted).
|
|
20664
|
+
* 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: \"invitation\"` sends the `invitation` auth email: a set-password link (valid 7 days) redeemed at `POST /auth/reset-password`, so the invitee ends up with a password. It has its own per-application template, separate from password reset\'s. Not sent to an identity that can already sign in. - `send_link: \"password_reset\"` sends a set-password email using the password-reset template. - `send_link: \"magic\"` sends a magic-link sign-in email. The user still has no credential afterwards. - `send_link: \"none\"` (default) creates the user with no email. A `redirect_url` is required whenever `send_link` is not \"none\"; it must match the application\'s redirect_uris allowlist (custom schemes such as yourapp://path are permitted). **Sending the email yourself:** pass `return_link: true` with a `send_link` and Zyphr mints that link but sends nothing, returning it in `data.link` (`link_sent` stays false). The same `link_suppressed_reason` values apply when no link can be minted.
|
|
20501
20665
|
* Pre-provision (invite) an end user (server-side admin)
|
|
20502
20666
|
*/
|
|
20503
20667
|
async inviteEndUserRaw(requestParameters, initOverrides) {
|
|
@@ -20536,7 +20700,7 @@ var AuthUserDirectoryApi = class extends BaseAPI {
|
|
|
20536
20700
|
return new JSONApiResponse(response, (jsonValue) => InviteEndUser200ResponseFromJSON(jsonValue));
|
|
20537
20701
|
}
|
|
20538
20702
|
/**
|
|
20539
|
-
* 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: \"invitation\"` sends the `invitation` auth email: a set-password link (valid 7 days) redeemed at `POST /auth/reset-password`, so the invitee ends up with a password. It has its own per-application template, separate from password reset\'s. Not sent to an identity that can already sign in. - `send_link: \"password_reset\"` sends a set-password email using the password-reset template. - `send_link: \"magic\"` sends a magic-link sign-in email. The user still has no credential afterwards. - `send_link: \"none\"` (default) creates the user with no email. A `redirect_url` is required whenever `send_link` is not \"none\"; it must match the application\'s redirect_uris allowlist (custom schemes such as yourapp://path are permitted).
|
|
20703
|
+
* 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: \"invitation\"` sends the `invitation` auth email: a set-password link (valid 7 days) redeemed at `POST /auth/reset-password`, so the invitee ends up with a password. It has its own per-application template, separate from password reset\'s. Not sent to an identity that can already sign in. - `send_link: \"password_reset\"` sends a set-password email using the password-reset template. - `send_link: \"magic\"` sends a magic-link sign-in email. The user still has no credential afterwards. - `send_link: \"none\"` (default) creates the user with no email. A `redirect_url` is required whenever `send_link` is not \"none\"; it must match the application\'s redirect_uris allowlist (custom schemes such as yourapp://path are permitted). **Sending the email yourself:** pass `return_link: true` with a `send_link` and Zyphr mints that link but sends nothing, returning it in `data.link` (`link_sent` stays false). The same `link_suppressed_reason` values apply when no link can be minted.
|
|
20540
20704
|
* Pre-provision (invite) an end user (server-side admin)
|
|
20541
20705
|
*/
|
|
20542
20706
|
async inviteEndUser(inviteEndUserRequest, initOverrides) {
|
|
@@ -28967,6 +29131,15 @@ export {
|
|
|
28967
29131
|
ForgotPasswordRequestFromJSONTyped,
|
|
28968
29132
|
ForgotPasswordRequestToJSON,
|
|
28969
29133
|
ForgotPasswordRequestToJSONTyped,
|
|
29134
|
+
ForgotPasswordResultDataFromJSON,
|
|
29135
|
+
ForgotPasswordResultDataFromJSONTyped,
|
|
29136
|
+
ForgotPasswordResultDataLinkSuppressedReasonEnum,
|
|
29137
|
+
ForgotPasswordResultDataToJSON,
|
|
29138
|
+
ForgotPasswordResultDataToJSONTyped,
|
|
29139
|
+
ForgotPasswordResultFromJSON,
|
|
29140
|
+
ForgotPasswordResultFromJSONTyped,
|
|
29141
|
+
ForgotPasswordResultToJSON,
|
|
29142
|
+
ForgotPasswordResultToJSONTyped,
|
|
28970
29143
|
GenerateSubscriberToken200ResponseDataFromJSON,
|
|
28971
29144
|
GenerateSubscriberToken200ResponseDataFromJSONTyped,
|
|
28972
29145
|
GenerateSubscriberToken200ResponseDataToJSON,
|
|
@@ -29206,6 +29379,14 @@ export {
|
|
|
29206
29379
|
MagicLinkSendRequestFromJSONTyped,
|
|
29207
29380
|
MagicLinkSendRequestToJSON,
|
|
29208
29381
|
MagicLinkSendRequestToJSONTyped,
|
|
29382
|
+
MagicLinkSendResultDataFromJSON,
|
|
29383
|
+
MagicLinkSendResultDataFromJSONTyped,
|
|
29384
|
+
MagicLinkSendResultDataToJSON,
|
|
29385
|
+
MagicLinkSendResultDataToJSONTyped,
|
|
29386
|
+
MagicLinkSendResultFromJSON,
|
|
29387
|
+
MagicLinkSendResultFromJSONTyped,
|
|
29388
|
+
MagicLinkSendResultToJSON,
|
|
29389
|
+
MagicLinkSendResultToJSONTyped,
|
|
29209
29390
|
MagicLinkVerifyRequestFromJSON,
|
|
29210
29391
|
MagicLinkVerifyRequestFromJSONTyped,
|
|
29211
29392
|
MagicLinkVerifyRequestToJSON,
|
|
@@ -29652,6 +29833,10 @@ export {
|
|
|
29652
29833
|
ResubscribeResponseFromJSONTyped,
|
|
29653
29834
|
ResubscribeResponseToJSON,
|
|
29654
29835
|
ResubscribeResponseToJSONTyped,
|
|
29836
|
+
ReturnedAuthLinkFromJSON,
|
|
29837
|
+
ReturnedAuthLinkFromJSONTyped,
|
|
29838
|
+
ReturnedAuthLinkToJSON,
|
|
29839
|
+
ReturnedAuthLinkToJSONTyped,
|
|
29655
29840
|
RevokeAllSessionsResponseDataFromJSON,
|
|
29656
29841
|
RevokeAllSessionsResponseDataFromJSONTyped,
|
|
29657
29842
|
RevokeAllSessionsResponseDataToJSON,
|
|
@@ -30722,6 +30907,8 @@ export {
|
|
|
30722
30907
|
instanceOfExecutionRetryResponse,
|
|
30723
30908
|
instanceOfExecutionRetryResponseData,
|
|
30724
30909
|
instanceOfForgotPasswordRequest,
|
|
30910
|
+
instanceOfForgotPasswordResult,
|
|
30911
|
+
instanceOfForgotPasswordResultData,
|
|
30725
30912
|
instanceOfGenerateSubscriberToken200Response,
|
|
30726
30913
|
instanceOfGenerateSubscriberToken200ResponseData,
|
|
30727
30914
|
instanceOfGenerateSubscriberTokenRequest,
|
|
@@ -30775,6 +30962,8 @@ export {
|
|
|
30775
30962
|
instanceOfListWorkflows200ResponseMeta,
|
|
30776
30963
|
instanceOfLoginRequest,
|
|
30777
30964
|
instanceOfMagicLinkSendRequest,
|
|
30965
|
+
instanceOfMagicLinkSendResult,
|
|
30966
|
+
instanceOfMagicLinkSendResultData,
|
|
30778
30967
|
instanceOfMagicLinkVerifyRequest,
|
|
30779
30968
|
instanceOfMagicLinkVerifyResponse,
|
|
30780
30969
|
instanceOfMagicLinkVerifyResponseData,
|
|
@@ -30883,6 +31072,7 @@ export {
|
|
|
30883
31072
|
instanceOfResetPasswordResponse,
|
|
30884
31073
|
instanceOfResubscribeRequest,
|
|
30885
31074
|
instanceOfResubscribeResponse,
|
|
31075
|
+
instanceOfReturnedAuthLink,
|
|
30886
31076
|
instanceOfRevokeAllSessionsResponse,
|
|
30887
31077
|
instanceOfRevokeAllSessionsResponseData,
|
|
30888
31078
|
instanceOfRevokeSessionRequest,
|