@feelflow/ffid-sdk 5.27.0 → 5.29.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/{chunk-JZB2IM7Y.js → chunk-4QQJMLL7.js} +40 -5
- package/dist/{chunk-R4KUHR4S.cjs → chunk-MESRDT7H.cjs} +41 -4
- package/dist/components/index.cjs +8 -8
- package/dist/components/index.d.cts +1 -1
- package/dist/components/index.d.ts +1 -1
- package/dist/components/index.js +1 -1
- package/dist/{ffid-client-BqnzUmG7.d.ts → ffid-client-DCS-MoxK.d.ts} +53 -1
- package/dist/{ffid-client-BlVuH6ja.d.cts → ffid-client-hv2PuUr7.d.cts} +53 -1
- package/dist/{index-D3S_Pkkv.d.cts → index-_-MqJCN3.d.cts} +56 -2
- package/dist/{index-D3S_Pkkv.d.ts → index-_-MqJCN3.d.ts} +56 -2
- package/dist/index.cjs +64 -56
- package/dist/index.d.cts +28 -2
- package/dist/index.d.ts +28 -2
- package/dist/index.js +2 -2
- package/dist/server/index.cjs +189 -6
- package/dist/server/index.d.cts +180 -3
- package/dist/server/index.d.ts +180 -3
- package/dist/server/index.js +176 -7
- package/dist/server/test/index.d.cts +1 -1
- package/dist/server/test/index.d.ts +1 -1
- package/package.json +1 -1
|
@@ -1036,6 +1036,26 @@ type FFIDInquiryCategorySite2026 = (typeof FFID_INQUIRY_CATEGORIES_SITE_2026)[nu
|
|
|
1036
1036
|
* parameter) to the canonical union.
|
|
1037
1037
|
*/
|
|
1038
1038
|
declare const isFFIDInquiryCategorySite2026: (value: string) => value is FFIDInquiryCategorySite2026;
|
|
1039
|
+
/**
|
|
1040
|
+
* Acquisition-source ("how did you first hear about us") survey slugs
|
|
1041
|
+
* accepted by `/api/v1/ext/inquiry` (feelflow-id-platform#4377). Mirrors
|
|
1042
|
+
* feelflow-website-2026 `ACQUISITION_SOURCE_OPTIONS`
|
|
1043
|
+
* (`feelflow-site/src/lib/acquisition-source.ts`); FFID
|
|
1044
|
+
* `src/lib/inquiry/acquisition-sources.ts` is the persistence-side
|
|
1045
|
+
* source of truth.
|
|
1046
|
+
*
|
|
1047
|
+
* Unlike `category`, the server validates this field strictly: a value
|
|
1048
|
+
* outside this list is rejected with `INQUIRY_VALIDATION_ERROR` rather than
|
|
1049
|
+
* stored as-is. Ship a new slug to FFID first, then start sending it.
|
|
1050
|
+
*/
|
|
1051
|
+
declare const FFID_INQUIRY_ACQUISITION_SOURCES: readonly ["referral", "generative-ai", "social-media", "networking-event", "web-search", "company-blog", "sales-outreach", "press-release", "web-advertising", "other"];
|
|
1052
|
+
type FFIDInquiryAcquisitionSource = (typeof FFID_INQUIRY_ACQUISITION_SOURCES)[number];
|
|
1053
|
+
/**
|
|
1054
|
+
* Runtime type guard for the acquisition-source allowlist. Use when
|
|
1055
|
+
* narrowing an unknown string (e.g., a URL query parameter or analytics
|
|
1056
|
+
* value) before passing it to `client.inquiry.create()`.
|
|
1057
|
+
*/
|
|
1058
|
+
declare const isFFIDInquiryAcquisitionSource: (value: string) => value is FFIDInquiryAcquisitionSource;
|
|
1039
1059
|
/**
|
|
1040
1060
|
* Parameters for `client.inquiry.create()`. When submitting from a
|
|
1041
1061
|
* server-side SDK (Service API Key), set `source` to a stable
|
|
@@ -1055,6 +1075,18 @@ interface FFIDInquiryCreateParams {
|
|
|
1055
1075
|
name: string;
|
|
1056
1076
|
message: string;
|
|
1057
1077
|
category?: FFIDInquiryCategorySite2026 | FFIDInquiryCategory | (string & {});
|
|
1078
|
+
/**
|
|
1079
|
+
* "How did you first hear about us" survey answer (#4377). Optional and
|
|
1080
|
+
* backward compatible — `undefined` and `null` are both normalized to
|
|
1081
|
+
* an omitted key on the wire (`null` is accepted so
|
|
1082
|
+
* `FFIDInquiryFormSubmitData.acquisitionSource` can be forwarded
|
|
1083
|
+
* verbatim) and the row is stored with NULL.
|
|
1084
|
+
* Server-side validation is a strict allowlist (unlike `category`):
|
|
1085
|
+
* values outside {@link FFID_INQUIRY_ACQUISITION_SOURCES} fail with
|
|
1086
|
+
* `INQUIRY_VALIDATION_ERROR`. Narrow untrusted strings with
|
|
1087
|
+
* {@link isFFIDInquiryAcquisitionSource} before submitting.
|
|
1088
|
+
*/
|
|
1089
|
+
acquisitionSource?: FFIDInquiryAcquisitionSource | null;
|
|
1058
1090
|
company?: string;
|
|
1059
1091
|
phone?: string;
|
|
1060
1092
|
locale?: 'ja' | 'en';
|
|
@@ -1420,6 +1452,15 @@ interface FFIDInquiryFormSubmitData {
|
|
|
1420
1452
|
company: string | null;
|
|
1421
1453
|
phone: string | null;
|
|
1422
1454
|
category: string;
|
|
1455
|
+
/**
|
|
1456
|
+
* Acquisition-source slug forwarded verbatim from the
|
|
1457
|
+
* `acquisitionSource` prop (#4377). `null` when the consumer does not
|
|
1458
|
+
* collect the survey — existing `onSubmit` handlers that ignore the
|
|
1459
|
+
* field keep working unchanged. Typed as the closed allowlist union so
|
|
1460
|
+
* the payload can be handed to `client.inquiry.create()` without a
|
|
1461
|
+
* re-narrowing cast.
|
|
1462
|
+
*/
|
|
1463
|
+
acquisitionSource: FFIDInquiryAcquisitionSource | null;
|
|
1423
1464
|
message: string;
|
|
1424
1465
|
organizationId: string | null;
|
|
1425
1466
|
inquiryFollowupOptIn: boolean;
|
|
@@ -1449,6 +1490,19 @@ interface FFIDInquiryFormProps {
|
|
|
1449
1490
|
privacyHref?: string;
|
|
1450
1491
|
/** Must be refreshed by the consumer when the Turnstile widget reissues a token. */
|
|
1451
1492
|
turnstileToken?: string | null;
|
|
1493
|
+
/**
|
|
1494
|
+
* Acquisition-source survey answer collected by the consumer's own UI
|
|
1495
|
+
* (#4377). The form renders no input for it — like `turnstileToken`,
|
|
1496
|
+
* it is a consumer-controlled value passed through into
|
|
1497
|
+
* `FFIDInquiryFormSubmitData.acquisitionSource` on every submit /
|
|
1498
|
+
* `onChange` broadcast. Typed as the closed
|
|
1499
|
+
* `FFID_INQUIRY_ACQUISITION_SOURCES` union so an invalid slug (e.g. a
|
|
1500
|
+
* display label, or a new value not yet deployed to FFID) fails at the
|
|
1501
|
+
* consumer's compile step instead of rejecting every end-user
|
|
1502
|
+
* submission with `INQUIRY_VALIDATION_ERROR` at runtime. Narrow
|
|
1503
|
+
* untrusted strings with `isFFIDInquiryAcquisitionSource` first.
|
|
1504
|
+
*/
|
|
1505
|
+
acquisitionSource?: FFIDInquiryAcquisitionSource | null;
|
|
1452
1506
|
/** Slot for the consumer's Turnstile widget (anonymous mode only). */
|
|
1453
1507
|
turnstileSlot?: ReactNode;
|
|
1454
1508
|
onSubmit: (data: FFIDInquiryFormSubmitData) => Promise<FFIDInquiryFormSubmitResult>;
|
|
@@ -1534,6 +1588,6 @@ interface FFIDInquiryFormProps {
|
|
|
1534
1588
|
interface FFIDInquiryFormPlaceholderContext {
|
|
1535
1589
|
category: string | null;
|
|
1536
1590
|
}
|
|
1537
|
-
declare function FFIDInquiryForm({ mode, prefill, organizations, preselectedOrganizationId, categories, termsVersion, privacyVersion, termsHref, privacyHref, turnstileToken, turnstileSlot, onSubmit, onChange, legalLayout, messagePlaceholder, requireCategorySelection, unstyled, classNames, locale, className, }: FFIDInquiryFormProps): react_jsx_runtime.JSX.Element;
|
|
1591
|
+
declare function FFIDInquiryForm({ mode, prefill, organizations, preselectedOrganizationId, categories, termsVersion, privacyVersion, termsHref, privacyHref, turnstileToken, acquisitionSource, turnstileSlot, onSubmit, onChange, legalLayout, messagePlaceholder, requireCategorySelection, unstyled, classNames, locale, className, }: FFIDInquiryFormProps): react_jsx_runtime.JSX.Element;
|
|
1538
1592
|
|
|
1539
|
-
export { type
|
|
1593
|
+
export { type FFIDInquiryFormSubmitData as $, type AnnouncementListResponse as A, type AnnouncementStatus as B, type AnnouncementType as C, EFFECTIVE_SUBSCRIPTION_STATUSES as D, type EffectiveSubscriptionStatus as E, type FFIDSubscriptionStatus as F, FFIDAnnouncementBadge as G, FFIDAnnouncementList as H, type FFIDAnnouncementsError as I, type FFIDAnnouncementsErrorCode as J, type FFIDAnnouncementsServerResponse as K, type ListAnnouncementsOptions as L, type FFIDApiResponseMeta as M, type FFIDCacheConfig as N, type FFIDContextValue as O, type FFIDInquiryAcquisitionSource as P, type FFIDInquiryCategory as Q, type FFIDInquiryCategorySite2026 as R, FFIDInquiryForm as S, type TokenStore as T, type FFIDInquiryFormCategoryItem as U, type FFIDInquiryFormClassNames as V, type FFIDInquiryFormLegalLayout as W, type FFIDInquiryFormOrganization as X, type FFIDInquiryFormPlaceholderContext as Y, type FFIDInquiryFormPrefill as Z, type FFIDInquiryFormProps as _, type FFIDOAuthUserInfoSubscription as a, type FFIDInquiryFormSubmitResult as a0, type FFIDJwtClaims as a1, FFIDLoginButton as a2, type FFIDOAuthUserInfoMemberRole as a3, FFIDOrganizationSwitcher as a4, type FFIDSeatAssignmentClaim as a5, type FFIDSeatAssignmentStatus as a6, type FFIDSeatModel as a7, type FFIDServiceAccessDenialReason as a8, type FFIDServiceAccessFailPolicy as a9, FFIDSubscriptionBadge as aa, FFIDUserMenu as ab, FFID_INQUIRY_ACQUISITION_SOURCES as ac, FFID_INQUIRY_CATEGORIES as ad, FFID_INQUIRY_CATEGORIES_SITE_2026 as ae, type TokenData as af, type UseFFIDAnnouncementsOptions as ag, type UseFFIDAnnouncementsReturn as ah, createTokenStore as ai, isFFIDInquiryAcquisitionSource as aj, isFFIDInquiryCategorySite2026 as ak, useFFIDAnnouncements as al, type FFIDAnnouncementBadgeClassNames as am, type FFIDAnnouncementBadgeProps as an, type FFIDAnnouncementListClassNames as ao, type FFIDAnnouncementListProps as ap, type FFIDLoginButtonProps as aq, type FFIDOrganizationSwitcherClassNames as ar, type FFIDOrganizationSwitcherProps as as, type FFIDSubscriptionBadgeClassNames as at, type FFIDSubscriptionBadgeProps as au, type FFIDUserMenuClassNames as av, type FFIDUserMenuProps as aw, type FFIDPrompt as b, type FFIDConfig as c, type FFIDApiResponse as d, type FFIDSessionResponse as e, type FFIDSignOutResult as f, type FFIDError as g, type FFIDSubscriptionCheckResponse as h, type FFIDCheckServiceAccessParams as i, type FFIDServiceAccessDecision as j, type FFIDAnalyticsConfig as k, type FFIDVerifyAccessTokenOptions as l, type FFIDOAuthUserInfo as m, type FFIDInquiryCreateParams as n, type FFIDInquiryCreateResponse as o, type FFIDAuthMode as p, type FFIDLogger as q, type FFIDCacheAdapter as r, type FFIDUser as s, type FFIDOrganization as t, type FFIDSubscription as u, type FFIDSubscriptionContextValue as v, type FFIDAnnouncementsClientConfig as w, type FFIDAnnouncementsApiResponse as x, type FFIDAnnouncementsLogger as y, type Announcement as z };
|
package/dist/index.cjs
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var chunkMESRDT7H_cjs = require('./chunk-MESRDT7H.cjs');
|
|
4
4
|
var chunkH5O2CCAY_cjs = require('./chunk-H5O2CCAY.cjs');
|
|
5
5
|
var react = require('react');
|
|
6
6
|
var jsxRuntime = require('react/jsx-runtime');
|
|
@@ -54,8 +54,8 @@ function defaultRedirect(url) {
|
|
|
54
54
|
}
|
|
55
55
|
function useRequireActiveSubscription(options) {
|
|
56
56
|
const { redirectTo, allowGrace = true, onRedirect } = options;
|
|
57
|
-
const { isLoading, error } =
|
|
58
|
-
const { effectiveStatus, isBlocked, isGrace } =
|
|
57
|
+
const { isLoading, error } = chunkMESRDT7H_cjs.useFFIDContext();
|
|
58
|
+
const { effectiveStatus, isBlocked, isGrace } = chunkMESRDT7H_cjs.useSubscription();
|
|
59
59
|
const hasFetchError = error !== null && effectiveStatus === null;
|
|
60
60
|
const shouldRedirect = !isLoading && !hasFetchError && (isBlocked || !allowGrace && isGrace || effectiveStatus === null);
|
|
61
61
|
react.useEffect(() => {
|
|
@@ -76,7 +76,7 @@ function useRequireActiveSubscription(options) {
|
|
|
76
76
|
}
|
|
77
77
|
function withFFIDAuth(Component, options = {}) {
|
|
78
78
|
const WrappedComponent = (props) => {
|
|
79
|
-
const { isLoading, isAuthenticated, login } =
|
|
79
|
+
const { isLoading, isAuthenticated, login } = chunkMESRDT7H_cjs.useFFIDContext();
|
|
80
80
|
const hasRedirected = react.useRef(false);
|
|
81
81
|
react.useEffect(() => {
|
|
82
82
|
if (!isLoading && !isAuthenticated && options.redirectToLogin && !hasRedirected.current) {
|
|
@@ -105,211 +105,219 @@ var FFID_NEWSLETTER_DISPATCH_MAX_RECIPIENTS = 1e3;
|
|
|
105
105
|
|
|
106
106
|
Object.defineProperty(exports, "ACCESS_GRANTING_EFFECTIVE_STATUSES", {
|
|
107
107
|
enumerable: true,
|
|
108
|
-
get: function () { return
|
|
108
|
+
get: function () { return chunkMESRDT7H_cjs.ACCESS_GRANTING_EFFECTIVE_STATUSES; }
|
|
109
109
|
});
|
|
110
110
|
Object.defineProperty(exports, "BLOCKING_EFFECTIVE_STATUSES", {
|
|
111
111
|
enumerable: true,
|
|
112
|
-
get: function () { return
|
|
112
|
+
get: function () { return chunkMESRDT7H_cjs.BLOCKING_EFFECTIVE_STATUSES; }
|
|
113
113
|
});
|
|
114
114
|
Object.defineProperty(exports, "CATALOG_HASH_PATTERN", {
|
|
115
115
|
enumerable: true,
|
|
116
|
-
get: function () { return
|
|
116
|
+
get: function () { return chunkMESRDT7H_cjs.CATALOG_HASH_PATTERN; }
|
|
117
117
|
});
|
|
118
118
|
Object.defineProperty(exports, "DEFAULT_API_BASE_URL", {
|
|
119
119
|
enumerable: true,
|
|
120
|
-
get: function () { return
|
|
120
|
+
get: function () { return chunkMESRDT7H_cjs.DEFAULT_API_BASE_URL; }
|
|
121
121
|
});
|
|
122
122
|
Object.defineProperty(exports, "DEFAULT_OAUTH_SCOPES", {
|
|
123
123
|
enumerable: true,
|
|
124
|
-
get: function () { return
|
|
124
|
+
get: function () { return chunkMESRDT7H_cjs.DEFAULT_OAUTH_SCOPES; }
|
|
125
125
|
});
|
|
126
126
|
Object.defineProperty(exports, "EFFECTIVE_SUBSCRIPTION_STATUSES", {
|
|
127
127
|
enumerable: true,
|
|
128
|
-
get: function () { return
|
|
128
|
+
get: function () { return chunkMESRDT7H_cjs.EFFECTIVE_SUBSCRIPTION_STATUSES; }
|
|
129
129
|
});
|
|
130
130
|
Object.defineProperty(exports, "FFIDAnnouncementBadge", {
|
|
131
131
|
enumerable: true,
|
|
132
|
-
get: function () { return
|
|
132
|
+
get: function () { return chunkMESRDT7H_cjs.FFIDAnnouncementBadge; }
|
|
133
133
|
});
|
|
134
134
|
Object.defineProperty(exports, "FFIDAnnouncementList", {
|
|
135
135
|
enumerable: true,
|
|
136
|
-
get: function () { return
|
|
136
|
+
get: function () { return chunkMESRDT7H_cjs.FFIDAnnouncementList; }
|
|
137
137
|
});
|
|
138
138
|
Object.defineProperty(exports, "FFIDCatalogHashError", {
|
|
139
139
|
enumerable: true,
|
|
140
|
-
get: function () { return
|
|
140
|
+
get: function () { return chunkMESRDT7H_cjs.FFIDCatalogHashError; }
|
|
141
141
|
});
|
|
142
142
|
Object.defineProperty(exports, "FFIDInquiryForm", {
|
|
143
143
|
enumerable: true,
|
|
144
|
-
get: function () { return
|
|
144
|
+
get: function () { return chunkMESRDT7H_cjs.FFIDInquiryForm; }
|
|
145
145
|
});
|
|
146
146
|
Object.defineProperty(exports, "FFIDLoginButton", {
|
|
147
147
|
enumerable: true,
|
|
148
|
-
get: function () { return
|
|
148
|
+
get: function () { return chunkMESRDT7H_cjs.FFIDLoginButton; }
|
|
149
149
|
});
|
|
150
150
|
Object.defineProperty(exports, "FFIDOrganizationSwitcher", {
|
|
151
151
|
enumerable: true,
|
|
152
|
-
get: function () { return
|
|
152
|
+
get: function () { return chunkMESRDT7H_cjs.FFIDOrganizationSwitcher; }
|
|
153
153
|
});
|
|
154
154
|
Object.defineProperty(exports, "FFIDProvider", {
|
|
155
155
|
enumerable: true,
|
|
156
|
-
get: function () { return
|
|
156
|
+
get: function () { return chunkMESRDT7H_cjs.FFIDProvider; }
|
|
157
157
|
});
|
|
158
158
|
Object.defineProperty(exports, "FFIDSDKError", {
|
|
159
159
|
enumerable: true,
|
|
160
|
-
get: function () { return
|
|
160
|
+
get: function () { return chunkMESRDT7H_cjs.FFIDSDKError; }
|
|
161
161
|
});
|
|
162
162
|
Object.defineProperty(exports, "FFIDSubscriptionBadge", {
|
|
163
163
|
enumerable: true,
|
|
164
|
-
get: function () { return
|
|
164
|
+
get: function () { return chunkMESRDT7H_cjs.FFIDSubscriptionBadge; }
|
|
165
165
|
});
|
|
166
166
|
Object.defineProperty(exports, "FFIDUserMenu", {
|
|
167
167
|
enumerable: true,
|
|
168
|
-
get: function () { return
|
|
168
|
+
get: function () { return chunkMESRDT7H_cjs.FFIDUserMenu; }
|
|
169
169
|
});
|
|
170
170
|
Object.defineProperty(exports, "FFID_ANNOUNCEMENTS_ERROR_CODES", {
|
|
171
171
|
enumerable: true,
|
|
172
|
-
get: function () { return
|
|
172
|
+
get: function () { return chunkMESRDT7H_cjs.FFID_ANNOUNCEMENTS_ERROR_CODES; }
|
|
173
173
|
});
|
|
174
174
|
Object.defineProperty(exports, "FFID_CATALOG_ENVIRONMENTS", {
|
|
175
175
|
enumerable: true,
|
|
176
|
-
get: function () { return
|
|
176
|
+
get: function () { return chunkMESRDT7H_cjs.FFID_CATALOG_ENVIRONMENTS; }
|
|
177
177
|
});
|
|
178
178
|
Object.defineProperty(exports, "FFID_CATALOG_PUBLICATION_STATUSES", {
|
|
179
179
|
enumerable: true,
|
|
180
|
-
get: function () { return
|
|
180
|
+
get: function () { return chunkMESRDT7H_cjs.FFID_CATALOG_PUBLICATION_STATUSES; }
|
|
181
181
|
});
|
|
182
182
|
Object.defineProperty(exports, "FFID_ERROR_CODES", {
|
|
183
183
|
enumerable: true,
|
|
184
|
-
get: function () { return
|
|
184
|
+
get: function () { return chunkMESRDT7H_cjs.FFID_ERROR_CODES; }
|
|
185
|
+
});
|
|
186
|
+
Object.defineProperty(exports, "FFID_INQUIRY_ACQUISITION_SOURCES", {
|
|
187
|
+
enumerable: true,
|
|
188
|
+
get: function () { return chunkMESRDT7H_cjs.FFID_INQUIRY_ACQUISITION_SOURCES; }
|
|
185
189
|
});
|
|
186
190
|
Object.defineProperty(exports, "FFID_INQUIRY_CATEGORIES", {
|
|
187
191
|
enumerable: true,
|
|
188
|
-
get: function () { return
|
|
192
|
+
get: function () { return chunkMESRDT7H_cjs.FFID_INQUIRY_CATEGORIES; }
|
|
189
193
|
});
|
|
190
194
|
Object.defineProperty(exports, "FFID_INQUIRY_CATEGORIES_SITE_2026", {
|
|
191
195
|
enumerable: true,
|
|
192
|
-
get: function () { return
|
|
196
|
+
get: function () { return chunkMESRDT7H_cjs.FFID_INQUIRY_CATEGORIES_SITE_2026; }
|
|
193
197
|
});
|
|
194
198
|
Object.defineProperty(exports, "canonicalizeCatalogValue", {
|
|
195
199
|
enumerable: true,
|
|
196
|
-
get: function () { return
|
|
200
|
+
get: function () { return chunkMESRDT7H_cjs.canonicalizeCatalogValue; }
|
|
197
201
|
});
|
|
198
202
|
Object.defineProperty(exports, "clearState", {
|
|
199
203
|
enumerable: true,
|
|
200
|
-
get: function () { return
|
|
204
|
+
get: function () { return chunkMESRDT7H_cjs.cleanupStateStorage; }
|
|
201
205
|
});
|
|
202
206
|
Object.defineProperty(exports, "computeEffectiveStatusFromSession", {
|
|
203
207
|
enumerable: true,
|
|
204
|
-
get: function () { return
|
|
208
|
+
get: function () { return chunkMESRDT7H_cjs.computeEffectiveStatusFromSession; }
|
|
205
209
|
});
|
|
206
210
|
Object.defineProperty(exports, "computeFFIDCheckoutCopyHash", {
|
|
207
211
|
enumerable: true,
|
|
208
|
-
get: function () { return
|
|
212
|
+
get: function () { return chunkMESRDT7H_cjs.computeFFIDCheckoutCopyHash; }
|
|
209
213
|
});
|
|
210
214
|
Object.defineProperty(exports, "computeLegalDisclosureHash", {
|
|
211
215
|
enumerable: true,
|
|
212
|
-
get: function () { return
|
|
216
|
+
get: function () { return chunkMESRDT7H_cjs.computeLegalDisclosureHash; }
|
|
213
217
|
});
|
|
214
218
|
Object.defineProperty(exports, "computePaymentConfigurationHash", {
|
|
215
219
|
enumerable: true,
|
|
216
|
-
get: function () { return
|
|
220
|
+
get: function () { return chunkMESRDT7H_cjs.computePaymentConfigurationHash; }
|
|
217
221
|
});
|
|
218
222
|
Object.defineProperty(exports, "computePraxisCopyHash", {
|
|
219
223
|
enumerable: true,
|
|
220
|
-
get: function () { return
|
|
224
|
+
get: function () { return chunkMESRDT7H_cjs.computePraxisCopyHash; }
|
|
221
225
|
});
|
|
222
226
|
Object.defineProperty(exports, "computeScopeHash", {
|
|
223
227
|
enumerable: true,
|
|
224
|
-
get: function () { return
|
|
228
|
+
get: function () { return chunkMESRDT7H_cjs.computeScopeHash; }
|
|
225
229
|
});
|
|
226
230
|
Object.defineProperty(exports, "computeTaxConfigurationHash", {
|
|
227
231
|
enumerable: true,
|
|
228
|
-
get: function () { return
|
|
232
|
+
get: function () { return chunkMESRDT7H_cjs.computeTaxConfigurationHash; }
|
|
229
233
|
});
|
|
230
234
|
Object.defineProperty(exports, "createFFIDAnnouncementsClient", {
|
|
231
235
|
enumerable: true,
|
|
232
|
-
get: function () { return
|
|
236
|
+
get: function () { return chunkMESRDT7H_cjs.createFFIDAnnouncementsClient; }
|
|
233
237
|
});
|
|
234
238
|
Object.defineProperty(exports, "createFFIDClient", {
|
|
235
239
|
enumerable: true,
|
|
236
|
-
get: function () { return
|
|
240
|
+
get: function () { return chunkMESRDT7H_cjs.createFFIDClient; }
|
|
237
241
|
});
|
|
238
242
|
Object.defineProperty(exports, "createTokenStore", {
|
|
239
243
|
enumerable: true,
|
|
240
|
-
get: function () { return
|
|
244
|
+
get: function () { return chunkMESRDT7H_cjs.createTokenStore; }
|
|
241
245
|
});
|
|
242
246
|
Object.defineProperty(exports, "generateCodeChallenge", {
|
|
243
247
|
enumerable: true,
|
|
244
|
-
get: function () { return
|
|
248
|
+
get: function () { return chunkMESRDT7H_cjs.generateCodeChallenge; }
|
|
245
249
|
});
|
|
246
250
|
Object.defineProperty(exports, "generateCodeVerifier", {
|
|
247
251
|
enumerable: true,
|
|
248
|
-
get: function () { return
|
|
252
|
+
get: function () { return chunkMESRDT7H_cjs.generateCodeVerifier; }
|
|
249
253
|
});
|
|
250
254
|
Object.defineProperty(exports, "handleRedirectCallback", {
|
|
251
255
|
enumerable: true,
|
|
252
|
-
get: function () { return
|
|
256
|
+
get: function () { return chunkMESRDT7H_cjs.handleRedirectCallback; }
|
|
253
257
|
});
|
|
254
258
|
Object.defineProperty(exports, "hasAccessFromUserinfo", {
|
|
255
259
|
enumerable: true,
|
|
256
|
-
get: function () { return
|
|
260
|
+
get: function () { return chunkMESRDT7H_cjs.hasAccessFromUserinfo; }
|
|
257
261
|
});
|
|
258
262
|
Object.defineProperty(exports, "hashCanonicalJson", {
|
|
259
263
|
enumerable: true,
|
|
260
|
-
get: function () { return
|
|
264
|
+
get: function () { return chunkMESRDT7H_cjs.hashCanonicalJson; }
|
|
261
265
|
});
|
|
262
266
|
Object.defineProperty(exports, "isBlockedFromUserinfo", {
|
|
263
267
|
enumerable: true,
|
|
264
|
-
get: function () { return
|
|
268
|
+
get: function () { return chunkMESRDT7H_cjs.isBlockedFromUserinfo; }
|
|
269
|
+
});
|
|
270
|
+
Object.defineProperty(exports, "isFFIDInquiryAcquisitionSource", {
|
|
271
|
+
enumerable: true,
|
|
272
|
+
get: function () { return chunkMESRDT7H_cjs.isFFIDInquiryAcquisitionSource; }
|
|
265
273
|
});
|
|
266
274
|
Object.defineProperty(exports, "isFFIDInquiryCategorySite2026", {
|
|
267
275
|
enumerable: true,
|
|
268
|
-
get: function () { return
|
|
276
|
+
get: function () { return chunkMESRDT7H_cjs.isFFIDInquiryCategorySite2026; }
|
|
269
277
|
});
|
|
270
278
|
Object.defineProperty(exports, "normalizeRedirectUri", {
|
|
271
279
|
enumerable: true,
|
|
272
|
-
get: function () { return
|
|
280
|
+
get: function () { return chunkMESRDT7H_cjs.normalizeRedirectUri; }
|
|
273
281
|
});
|
|
274
282
|
Object.defineProperty(exports, "retrieveCodeVerifier", {
|
|
275
283
|
enumerable: true,
|
|
276
|
-
get: function () { return
|
|
284
|
+
get: function () { return chunkMESRDT7H_cjs.retrieveCodeVerifier; }
|
|
277
285
|
});
|
|
278
286
|
Object.defineProperty(exports, "retrieveState", {
|
|
279
287
|
enumerable: true,
|
|
280
|
-
get: function () { return
|
|
288
|
+
get: function () { return chunkMESRDT7H_cjs.retrieveState; }
|
|
281
289
|
});
|
|
282
290
|
Object.defineProperty(exports, "sha256Hex", {
|
|
283
291
|
enumerable: true,
|
|
284
|
-
get: function () { return
|
|
292
|
+
get: function () { return chunkMESRDT7H_cjs.sha256Hex; }
|
|
285
293
|
});
|
|
286
294
|
Object.defineProperty(exports, "storeCodeVerifier", {
|
|
287
295
|
enumerable: true,
|
|
288
|
-
get: function () { return
|
|
296
|
+
get: function () { return chunkMESRDT7H_cjs.storeCodeVerifier; }
|
|
289
297
|
});
|
|
290
298
|
Object.defineProperty(exports, "storeState", {
|
|
291
299
|
enumerable: true,
|
|
292
|
-
get: function () { return
|
|
300
|
+
get: function () { return chunkMESRDT7H_cjs.storeState; }
|
|
293
301
|
});
|
|
294
302
|
Object.defineProperty(exports, "useFFID", {
|
|
295
303
|
enumerable: true,
|
|
296
|
-
get: function () { return
|
|
304
|
+
get: function () { return chunkMESRDT7H_cjs.useFFID; }
|
|
297
305
|
});
|
|
298
306
|
Object.defineProperty(exports, "useFFIDAnnouncements", {
|
|
299
307
|
enumerable: true,
|
|
300
|
-
get: function () { return
|
|
308
|
+
get: function () { return chunkMESRDT7H_cjs.useFFIDAnnouncements; }
|
|
301
309
|
});
|
|
302
310
|
Object.defineProperty(exports, "useSubscription", {
|
|
303
311
|
enumerable: true,
|
|
304
|
-
get: function () { return
|
|
312
|
+
get: function () { return chunkMESRDT7H_cjs.useSubscription; }
|
|
305
313
|
});
|
|
306
314
|
Object.defineProperty(exports, "validatePublishedCatalog", {
|
|
307
315
|
enumerable: true,
|
|
308
|
-
get: function () { return
|
|
316
|
+
get: function () { return chunkMESRDT7H_cjs.validatePublishedCatalog; }
|
|
309
317
|
});
|
|
310
318
|
Object.defineProperty(exports, "withSubscription", {
|
|
311
319
|
enumerable: true,
|
|
312
|
-
get: function () { return
|
|
320
|
+
get: function () { return chunkMESRDT7H_cjs.withSubscription; }
|
|
313
321
|
});
|
|
314
322
|
Object.defineProperty(exports, "ALL_DENIED_EXCEPT_NECESSARY", {
|
|
315
323
|
enumerable: true,
|
package/dist/index.d.cts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { F as FFIDSubscriptionStatus, a as FFIDOAuthUserInfoSubscription, b as FFIDPrompt, c as FFIDConfig, d as FFIDApiResponse, e as FFIDSessionResponse, f as FFIDSignOutResult, g as FFIDError, h as FFIDSubscriptionCheckResponse, i as FFIDCheckServiceAccessParams, j as FFIDServiceAccessDecision, k as FFIDAnalyticsConfig, l as FFIDVerifyAccessTokenOptions, m as FFIDOAuthUserInfo, n as FFIDInquiryCreateParams, o as FFIDInquiryCreateResponse, T as TokenStore, p as FFIDAuthMode, q as FFIDLogger, r as FFIDCacheAdapter, s as FFIDUser, t as FFIDOrganization, u as FFIDSubscription, v as FFIDSubscriptionContextValue, E as EffectiveSubscriptionStatus, w as FFIDAnnouncementsClientConfig, L as ListAnnouncementsOptions, x as FFIDAnnouncementsApiResponse, A as AnnouncementListResponse, y as FFIDAnnouncementsLogger } from './index-
|
|
2
|
-
export { z as Announcement, B as AnnouncementStatus, C as AnnouncementType, D as EFFECTIVE_SUBSCRIPTION_STATUSES, G as FFIDAnnouncementBadge, H as FFIDAnnouncementList, I as FFIDAnnouncementsError, J as FFIDAnnouncementsErrorCode, K as FFIDAnnouncementsServerResponse, M as FFIDApiResponseMeta, N as FFIDCacheConfig, O as FFIDContextValue, P as
|
|
1
|
+
import { F as FFIDSubscriptionStatus, a as FFIDOAuthUserInfoSubscription, b as FFIDPrompt, c as FFIDConfig, d as FFIDApiResponse, e as FFIDSessionResponse, f as FFIDSignOutResult, g as FFIDError, h as FFIDSubscriptionCheckResponse, i as FFIDCheckServiceAccessParams, j as FFIDServiceAccessDecision, k as FFIDAnalyticsConfig, l as FFIDVerifyAccessTokenOptions, m as FFIDOAuthUserInfo, n as FFIDInquiryCreateParams, o as FFIDInquiryCreateResponse, T as TokenStore, p as FFIDAuthMode, q as FFIDLogger, r as FFIDCacheAdapter, s as FFIDUser, t as FFIDOrganization, u as FFIDSubscription, v as FFIDSubscriptionContextValue, E as EffectiveSubscriptionStatus, w as FFIDAnnouncementsClientConfig, L as ListAnnouncementsOptions, x as FFIDAnnouncementsApiResponse, A as AnnouncementListResponse, y as FFIDAnnouncementsLogger } from './index-_-MqJCN3.cjs';
|
|
2
|
+
export { z as Announcement, B as AnnouncementStatus, C as AnnouncementType, D as EFFECTIVE_SUBSCRIPTION_STATUSES, G as FFIDAnnouncementBadge, H as FFIDAnnouncementList, I as FFIDAnnouncementsError, J as FFIDAnnouncementsErrorCode, K as FFIDAnnouncementsServerResponse, M as FFIDApiResponseMeta, N as FFIDCacheConfig, O as FFIDContextValue, P as FFIDInquiryAcquisitionSource, Q as FFIDInquiryCategory, R as FFIDInquiryCategorySite2026, S as FFIDInquiryForm, U as FFIDInquiryFormCategoryItem, V as FFIDInquiryFormClassNames, W as FFIDInquiryFormLegalLayout, X as FFIDInquiryFormOrganization, Y as FFIDInquiryFormPlaceholderContext, Z as FFIDInquiryFormPrefill, _ as FFIDInquiryFormProps, $ as FFIDInquiryFormSubmitData, a0 as FFIDInquiryFormSubmitResult, a1 as FFIDJwtClaims, a2 as FFIDLoginButton, a3 as FFIDOAuthUserInfoMemberRole, a4 as FFIDOrganizationSwitcher, a5 as FFIDSeatAssignmentClaim, a6 as FFIDSeatAssignmentStatus, a7 as FFIDSeatModel, a8 as FFIDServiceAccessDenialReason, a9 as FFIDServiceAccessFailPolicy, aa as FFIDSubscriptionBadge, ab as FFIDUserMenu, ac as FFID_INQUIRY_ACQUISITION_SOURCES, ad as FFID_INQUIRY_CATEGORIES, ae as FFID_INQUIRY_CATEGORIES_SITE_2026, af as TokenData, ag as UseFFIDAnnouncementsOptions, ah as UseFFIDAnnouncementsReturn, ai as createTokenStore, aj as isFFIDInquiryAcquisitionSource, ak as isFFIDInquiryCategorySite2026, al as useFFIDAnnouncements } from './index-_-MqJCN3.cjs';
|
|
3
3
|
export { A as ALL_DENIED_EXCEPT_NECESSARY, i as CONSENT_COOKIE_NAME, j as CONSENT_DISMISSAL_TIMESTAMP_KEY, l as COOKIE_VERSION, D as DEFAULT_CONSENT_ERROR_MESSAGES, o as FFIDAnalyticsProvider, p as FFIDAnalyticsProviderProps, c as FFIDConsentCategories, r as FFIDConsentCategoryCode, e as FFIDConsentCategoryMetadata, w as FFIDConsentError, x as FFIDConsentErrorCode, y as FFIDConsentMergeStrategy, B as FFIDConsentMergeWarning, E as FFIDConsentMergeWarningEvent, F as FFIDConsentResult, I as FFIDConsentSource, a as FFIDConsentState, d as FFIDConsentSyncResult, M as FFIDCookieBanner, N as FFIDCookieBannerClassNames, O as FFIDCookieBannerProps, Q as FFIDCookieLink, R as FFIDCookieLinkProps, f as FFIDCookiePolicy, T as FFIDCookieSettings, U as FFIDCookieSettingsClassNames, V as FFIDCookieSettingsProps, _ as FFID_CONSENT_ERROR_CODES, ae as UseFFIDConsentPreferencesReturn, af as UseFFIDConsentReturn, ag as clearConsentDismissalTimestamp, aj as decodeConsentCookie, al as encodeConsentCookie, an as readConsentCookie, ao as readConsentDismissalTimestamp, aq as useFFIDConsent, ar as useFFIDConsentPreferences, as as writeConsentCookie, at as writeConsentDismissalTimestamp } from './FFIDCookieLink-BJgVcJyw.cjs';
|
|
4
4
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
5
5
|
import { ReactNode, ComponentType, FC } from 'react';
|
|
@@ -625,6 +625,31 @@ interface FFIDProvisionUserDryRun {
|
|
|
625
625
|
* response. This mirrors how `FFIDApiResponse` is narrowed on `data` / `error`.
|
|
626
626
|
*/
|
|
627
627
|
type FFIDProvisionUserResponse = FFIDProvisionUserOutcome | FFIDProvisionUserDryRun;
|
|
628
|
+
/** Parameters for `sendProvisionWelcomeEmail` (#4449). */
|
|
629
|
+
interface FFIDProvisionWelcomeEmailParams {
|
|
630
|
+
/** Email of the provisioned FFID user to notify (must already exist). */
|
|
631
|
+
email: string;
|
|
632
|
+
}
|
|
633
|
+
/**
|
|
634
|
+
* Response from `sendProvisionWelcomeEmail` (#4449).
|
|
635
|
+
*
|
|
636
|
+
* `status` is always `'sent'` on the data branch. Non-success outcomes arrive
|
|
637
|
+
* on the error branch instead:
|
|
638
|
+
* - `USER_NOT_FOUND` (404) — provision the user first.
|
|
639
|
+
* - `RATE_LIMITED` (429) — per-recipient cooldown; `details.retryAfterSeconds`
|
|
640
|
+
* says when a resend will be accepted. The cooldown is claimed only after a
|
|
641
|
+
* successful send, so a 429 always means an email really was just sent.
|
|
642
|
+
* - `RECOVERY_LINK_GENERATION_FAILED` (502) — the password-setup link could
|
|
643
|
+
* not be generated; nothing was sent.
|
|
644
|
+
* - `EMAIL_SEND_FAILED` / `EMAIL_SEND_FAILED_PERMANENT` (502),
|
|
645
|
+
* `EMAIL_SERVICE_UNAVAILABLE` (503) — delivery-side failures; the caller
|
|
646
|
+
* should surface "not delivered" and offer a resend (failed attempts do not
|
|
647
|
+
* consume the cooldown, so an immediate retry is accepted).
|
|
648
|
+
*/
|
|
649
|
+
interface FFIDProvisionWelcomeEmailResponse {
|
|
650
|
+
status: 'sent';
|
|
651
|
+
user: FFIDProvisionedUser;
|
|
652
|
+
}
|
|
628
653
|
/** A member to add to the provisioned organization. */
|
|
629
654
|
interface FFIDProvisionOrganizationMemberInput {
|
|
630
655
|
email: string;
|
|
@@ -1577,6 +1602,7 @@ declare function createFFIDClient(config: FFIDConfig): {
|
|
|
1577
1602
|
userId: string;
|
|
1578
1603
|
}) => Promise<FFIDApiResponse<FFIDRemoveMemberResponse>>;
|
|
1579
1604
|
provisionUser: (params: FFIDProvisionUserParams) => Promise<FFIDApiResponse<FFIDProvisionUserResponse>>;
|
|
1605
|
+
sendProvisionWelcomeEmail: (params: FFIDProvisionWelcomeEmailParams) => Promise<FFIDApiResponse<FFIDProvisionWelcomeEmailResponse>>;
|
|
1580
1606
|
provisionOrganization: (params: FFIDProvisionOrganizationParams) => Promise<FFIDApiResponse<FFIDProvisionOrganizationResponse>>;
|
|
1581
1607
|
getProfile: (options?: FFIDProfileCallOptions) => Promise<FFIDApiResponse<FFIDUserProfile>>;
|
|
1582
1608
|
updateProfile: (data: FFIDUpdateUserProfileRequest, options?: FFIDProfileCallOptions) => Promise<FFIDApiResponse<FFIDUserProfile>>;
|
package/dist/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { F as FFIDSubscriptionStatus, a as FFIDOAuthUserInfoSubscription, b as FFIDPrompt, c as FFIDConfig, d as FFIDApiResponse, e as FFIDSessionResponse, f as FFIDSignOutResult, g as FFIDError, h as FFIDSubscriptionCheckResponse, i as FFIDCheckServiceAccessParams, j as FFIDServiceAccessDecision, k as FFIDAnalyticsConfig, l as FFIDVerifyAccessTokenOptions, m as FFIDOAuthUserInfo, n as FFIDInquiryCreateParams, o as FFIDInquiryCreateResponse, T as TokenStore, p as FFIDAuthMode, q as FFIDLogger, r as FFIDCacheAdapter, s as FFIDUser, t as FFIDOrganization, u as FFIDSubscription, v as FFIDSubscriptionContextValue, E as EffectiveSubscriptionStatus, w as FFIDAnnouncementsClientConfig, L as ListAnnouncementsOptions, x as FFIDAnnouncementsApiResponse, A as AnnouncementListResponse, y as FFIDAnnouncementsLogger } from './index-
|
|
2
|
-
export { z as Announcement, B as AnnouncementStatus, C as AnnouncementType, D as EFFECTIVE_SUBSCRIPTION_STATUSES, G as FFIDAnnouncementBadge, H as FFIDAnnouncementList, I as FFIDAnnouncementsError, J as FFIDAnnouncementsErrorCode, K as FFIDAnnouncementsServerResponse, M as FFIDApiResponseMeta, N as FFIDCacheConfig, O as FFIDContextValue, P as
|
|
1
|
+
import { F as FFIDSubscriptionStatus, a as FFIDOAuthUserInfoSubscription, b as FFIDPrompt, c as FFIDConfig, d as FFIDApiResponse, e as FFIDSessionResponse, f as FFIDSignOutResult, g as FFIDError, h as FFIDSubscriptionCheckResponse, i as FFIDCheckServiceAccessParams, j as FFIDServiceAccessDecision, k as FFIDAnalyticsConfig, l as FFIDVerifyAccessTokenOptions, m as FFIDOAuthUserInfo, n as FFIDInquiryCreateParams, o as FFIDInquiryCreateResponse, T as TokenStore, p as FFIDAuthMode, q as FFIDLogger, r as FFIDCacheAdapter, s as FFIDUser, t as FFIDOrganization, u as FFIDSubscription, v as FFIDSubscriptionContextValue, E as EffectiveSubscriptionStatus, w as FFIDAnnouncementsClientConfig, L as ListAnnouncementsOptions, x as FFIDAnnouncementsApiResponse, A as AnnouncementListResponse, y as FFIDAnnouncementsLogger } from './index-_-MqJCN3.js';
|
|
2
|
+
export { z as Announcement, B as AnnouncementStatus, C as AnnouncementType, D as EFFECTIVE_SUBSCRIPTION_STATUSES, G as FFIDAnnouncementBadge, H as FFIDAnnouncementList, I as FFIDAnnouncementsError, J as FFIDAnnouncementsErrorCode, K as FFIDAnnouncementsServerResponse, M as FFIDApiResponseMeta, N as FFIDCacheConfig, O as FFIDContextValue, P as FFIDInquiryAcquisitionSource, Q as FFIDInquiryCategory, R as FFIDInquiryCategorySite2026, S as FFIDInquiryForm, U as FFIDInquiryFormCategoryItem, V as FFIDInquiryFormClassNames, W as FFIDInquiryFormLegalLayout, X as FFIDInquiryFormOrganization, Y as FFIDInquiryFormPlaceholderContext, Z as FFIDInquiryFormPrefill, _ as FFIDInquiryFormProps, $ as FFIDInquiryFormSubmitData, a0 as FFIDInquiryFormSubmitResult, a1 as FFIDJwtClaims, a2 as FFIDLoginButton, a3 as FFIDOAuthUserInfoMemberRole, a4 as FFIDOrganizationSwitcher, a5 as FFIDSeatAssignmentClaim, a6 as FFIDSeatAssignmentStatus, a7 as FFIDSeatModel, a8 as FFIDServiceAccessDenialReason, a9 as FFIDServiceAccessFailPolicy, aa as FFIDSubscriptionBadge, ab as FFIDUserMenu, ac as FFID_INQUIRY_ACQUISITION_SOURCES, ad as FFID_INQUIRY_CATEGORIES, ae as FFID_INQUIRY_CATEGORIES_SITE_2026, af as TokenData, ag as UseFFIDAnnouncementsOptions, ah as UseFFIDAnnouncementsReturn, ai as createTokenStore, aj as isFFIDInquiryAcquisitionSource, ak as isFFIDInquiryCategorySite2026, al as useFFIDAnnouncements } from './index-_-MqJCN3.js';
|
|
3
3
|
export { A as ALL_DENIED_EXCEPT_NECESSARY, i as CONSENT_COOKIE_NAME, j as CONSENT_DISMISSAL_TIMESTAMP_KEY, l as COOKIE_VERSION, D as DEFAULT_CONSENT_ERROR_MESSAGES, o as FFIDAnalyticsProvider, p as FFIDAnalyticsProviderProps, c as FFIDConsentCategories, r as FFIDConsentCategoryCode, e as FFIDConsentCategoryMetadata, w as FFIDConsentError, x as FFIDConsentErrorCode, y as FFIDConsentMergeStrategy, B as FFIDConsentMergeWarning, E as FFIDConsentMergeWarningEvent, F as FFIDConsentResult, I as FFIDConsentSource, a as FFIDConsentState, d as FFIDConsentSyncResult, M as FFIDCookieBanner, N as FFIDCookieBannerClassNames, O as FFIDCookieBannerProps, Q as FFIDCookieLink, R as FFIDCookieLinkProps, f as FFIDCookiePolicy, T as FFIDCookieSettings, U as FFIDCookieSettingsClassNames, V as FFIDCookieSettingsProps, _ as FFID_CONSENT_ERROR_CODES, ae as UseFFIDConsentPreferencesReturn, af as UseFFIDConsentReturn, ag as clearConsentDismissalTimestamp, aj as decodeConsentCookie, al as encodeConsentCookie, an as readConsentCookie, ao as readConsentDismissalTimestamp, aq as useFFIDConsent, ar as useFFIDConsentPreferences, as as writeConsentCookie, at as writeConsentDismissalTimestamp } from './FFIDCookieLink-BJgVcJyw.js';
|
|
4
4
|
import * as react_jsx_runtime from 'react/jsx-runtime';
|
|
5
5
|
import { ReactNode, ComponentType, FC } from 'react';
|
|
@@ -625,6 +625,31 @@ interface FFIDProvisionUserDryRun {
|
|
|
625
625
|
* response. This mirrors how `FFIDApiResponse` is narrowed on `data` / `error`.
|
|
626
626
|
*/
|
|
627
627
|
type FFIDProvisionUserResponse = FFIDProvisionUserOutcome | FFIDProvisionUserDryRun;
|
|
628
|
+
/** Parameters for `sendProvisionWelcomeEmail` (#4449). */
|
|
629
|
+
interface FFIDProvisionWelcomeEmailParams {
|
|
630
|
+
/** Email of the provisioned FFID user to notify (must already exist). */
|
|
631
|
+
email: string;
|
|
632
|
+
}
|
|
633
|
+
/**
|
|
634
|
+
* Response from `sendProvisionWelcomeEmail` (#4449).
|
|
635
|
+
*
|
|
636
|
+
* `status` is always `'sent'` on the data branch. Non-success outcomes arrive
|
|
637
|
+
* on the error branch instead:
|
|
638
|
+
* - `USER_NOT_FOUND` (404) — provision the user first.
|
|
639
|
+
* - `RATE_LIMITED` (429) — per-recipient cooldown; `details.retryAfterSeconds`
|
|
640
|
+
* says when a resend will be accepted. The cooldown is claimed only after a
|
|
641
|
+
* successful send, so a 429 always means an email really was just sent.
|
|
642
|
+
* - `RECOVERY_LINK_GENERATION_FAILED` (502) — the password-setup link could
|
|
643
|
+
* not be generated; nothing was sent.
|
|
644
|
+
* - `EMAIL_SEND_FAILED` / `EMAIL_SEND_FAILED_PERMANENT` (502),
|
|
645
|
+
* `EMAIL_SERVICE_UNAVAILABLE` (503) — delivery-side failures; the caller
|
|
646
|
+
* should surface "not delivered" and offer a resend (failed attempts do not
|
|
647
|
+
* consume the cooldown, so an immediate retry is accepted).
|
|
648
|
+
*/
|
|
649
|
+
interface FFIDProvisionWelcomeEmailResponse {
|
|
650
|
+
status: 'sent';
|
|
651
|
+
user: FFIDProvisionedUser;
|
|
652
|
+
}
|
|
628
653
|
/** A member to add to the provisioned organization. */
|
|
629
654
|
interface FFIDProvisionOrganizationMemberInput {
|
|
630
655
|
email: string;
|
|
@@ -1577,6 +1602,7 @@ declare function createFFIDClient(config: FFIDConfig): {
|
|
|
1577
1602
|
userId: string;
|
|
1578
1603
|
}) => Promise<FFIDApiResponse<FFIDRemoveMemberResponse>>;
|
|
1579
1604
|
provisionUser: (params: FFIDProvisionUserParams) => Promise<FFIDApiResponse<FFIDProvisionUserResponse>>;
|
|
1605
|
+
sendProvisionWelcomeEmail: (params: FFIDProvisionWelcomeEmailParams) => Promise<FFIDApiResponse<FFIDProvisionWelcomeEmailResponse>>;
|
|
1580
1606
|
provisionOrganization: (params: FFIDProvisionOrganizationParams) => Promise<FFIDApiResponse<FFIDProvisionOrganizationResponse>>;
|
|
1581
1607
|
getProfile: (options?: FFIDProfileCallOptions) => Promise<FFIDApiResponse<FFIDUserProfile>>;
|
|
1582
1608
|
updateProfile: (data: FFIDUpdateUserProfileRequest, options?: FFIDProfileCallOptions) => Promise<FFIDApiResponse<FFIDUserProfile>>;
|
package/dist/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { useFFIDContext, useSubscription } from './chunk-
|
|
2
|
-
export { ACCESS_GRANTING_EFFECTIVE_STATUSES, BLOCKING_EFFECTIVE_STATUSES, CATALOG_HASH_PATTERN, DEFAULT_API_BASE_URL, DEFAULT_OAUTH_SCOPES, EFFECTIVE_SUBSCRIPTION_STATUSES, FFIDAnnouncementBadge, FFIDAnnouncementList, FFIDCatalogHashError, FFIDInquiryForm, FFIDLoginButton, FFIDOrganizationSwitcher, FFIDProvider, FFIDSDKError, FFIDSubscriptionBadge, FFIDUserMenu, FFID_ANNOUNCEMENTS_ERROR_CODES, FFID_CATALOG_ENVIRONMENTS, FFID_CATALOG_PUBLICATION_STATUSES, FFID_ERROR_CODES, FFID_INQUIRY_CATEGORIES, FFID_INQUIRY_CATEGORIES_SITE_2026, canonicalizeCatalogValue, cleanupStateStorage as clearState, computeEffectiveStatusFromSession, computeFFIDCheckoutCopyHash, computeLegalDisclosureHash, computePaymentConfigurationHash, computePraxisCopyHash, computeScopeHash, computeTaxConfigurationHash, createFFIDAnnouncementsClient, createFFIDClient, createTokenStore, generateCodeChallenge, generateCodeVerifier, handleRedirectCallback, hasAccessFromUserinfo, hashCanonicalJson, isBlockedFromUserinfo, isFFIDInquiryCategorySite2026, normalizeRedirectUri, retrieveCodeVerifier, retrieveState, sha256Hex, storeCodeVerifier, storeState, useFFID, useFFIDAnnouncements, useSubscription, validatePublishedCatalog, withSubscription } from './chunk-
|
|
1
|
+
import { useFFIDContext, useSubscription } from './chunk-4QQJMLL7.js';
|
|
2
|
+
export { ACCESS_GRANTING_EFFECTIVE_STATUSES, BLOCKING_EFFECTIVE_STATUSES, CATALOG_HASH_PATTERN, DEFAULT_API_BASE_URL, DEFAULT_OAUTH_SCOPES, EFFECTIVE_SUBSCRIPTION_STATUSES, FFIDAnnouncementBadge, FFIDAnnouncementList, FFIDCatalogHashError, FFIDInquiryForm, FFIDLoginButton, FFIDOrganizationSwitcher, FFIDProvider, FFIDSDKError, FFIDSubscriptionBadge, FFIDUserMenu, FFID_ANNOUNCEMENTS_ERROR_CODES, FFID_CATALOG_ENVIRONMENTS, FFID_CATALOG_PUBLICATION_STATUSES, FFID_ERROR_CODES, FFID_INQUIRY_ACQUISITION_SOURCES, FFID_INQUIRY_CATEGORIES, FFID_INQUIRY_CATEGORIES_SITE_2026, canonicalizeCatalogValue, cleanupStateStorage as clearState, computeEffectiveStatusFromSession, computeFFIDCheckoutCopyHash, computeLegalDisclosureHash, computePaymentConfigurationHash, computePraxisCopyHash, computeScopeHash, computeTaxConfigurationHash, createFFIDAnnouncementsClient, createFFIDClient, createTokenStore, generateCodeChallenge, generateCodeVerifier, handleRedirectCallback, hasAccessFromUserinfo, hashCanonicalJson, isBlockedFromUserinfo, isFFIDInquiryAcquisitionSource, isFFIDInquiryCategorySite2026, normalizeRedirectUri, retrieveCodeVerifier, retrieveState, sha256Hex, storeCodeVerifier, storeState, useFFID, useFFIDAnnouncements, useSubscription, validatePublishedCatalog, withSubscription } from './chunk-4QQJMLL7.js';
|
|
3
3
|
export { ALL_DENIED_EXCEPT_NECESSARY, CONSENT_COOKIE_NAME, CONSENT_DISMISSAL_TIMESTAMP_KEY, COOKIE_VERSION, DEFAULT_CONSENT_ERROR_MESSAGES, FFIDAnalyticsProvider, FFIDConsentError, FFIDCookieBanner, FFIDCookieLink, FFIDCookieSettings, FFID_CONSENT_ERROR_CODES, clearConsentDismissalTimestamp, decodeConsentCookie, encodeConsentCookie, readConsentCookie, readConsentDismissalTimestamp, useFFIDConsent, useFFIDConsentPreferences, writeConsentCookie, writeConsentDismissalTimestamp } from './chunk-G7VOX64X.js';
|
|
4
4
|
import { useEffect, useRef } from 'react';
|
|
5
5
|
import { jsx, Fragment } from 'react/jsx-runtime';
|