@singi-labs/sifa-sdk 0.19.67 → 0.19.68
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 +1 -1
- package/dist/index.js +1 -1
- package/dist/{org--5MN6Ev4.d.ts → org-BmKMu2h9.d.ts} +5 -0
- package/dist/{org-B_0EMNuF.d.cts → org-DZZNwznR.d.cts} +5 -0
- package/dist/query/fetchers/index.cjs +5 -0
- package/dist/query/fetchers/index.cjs.map +1 -1
- package/dist/query/fetchers/index.d.cts +1 -1
- package/dist/query/fetchers/index.d.ts +1 -1
- package/dist/query/fetchers/verification.js +49 -0
- package/dist/query/fetchers/verification.js.map +1 -0
- package/dist/query/hooks/index.cjs +44 -0
- package/dist/query/hooks/index.cjs.map +1 -1
- package/dist/query/hooks/index.d.cts +2 -2
- package/dist/query/hooks/index.d.ts +2 -2
- package/dist/query/hooks/index.js +2 -0
- package/dist/query/hooks/index.js.map +1 -1
- package/dist/query/hooks/use-verification.js +19 -0
- package/dist/query/hooks/use-verification.js.map +1 -0
- package/dist/query/index.cjs +57 -0
- package/dist/query/index.cjs.map +1 -1
- package/dist/query/index.d.cts +3 -3
- package/dist/query/index.d.ts +3 -3
- package/dist/query/index.js +12 -0
- package/dist/query/index.js.map +1 -1
- package/dist/query/keys.js +5 -0
- package/dist/query/keys.js.map +1 -1
- package/dist/{use-org-notification-emails-DZ0oVtiX.d.ts → use-org-notification-emails-BKXLY0Nx.d.ts} +79 -3
- package/dist/{use-org-notification-emails-B4INNGOe.d.cts → use-org-notification-emails-jVBPNbUy.d.cts} +79 -3
- package/package.json +1 -1
|
@@ -1,10 +1,11 @@
|
|
|
1
1
|
import * as react from 'react';
|
|
2
2
|
import { ReactNode } from 'react';
|
|
3
|
-
import { K as SifaApiConfig, n as ProfileView, W as WriteResult, N as CreateResult, Q as FilterOptions, S as SearchFilters, X as SearchResponse, Y as SkillSearchResult, a5 as CompanySearchFilters, a6 as CompanySearchResponse, t as RepoDeleteResult, w as RepoInventory } from './types-BV-qBo9i.cjs';
|
|
3
|
+
import { K as SifaApiConfig, M as ApiFetchOptions, n as ProfileView, W as WriteResult, N as CreateResult, Q as FilterOptions, S as SearchFilters, X as SearchResponse, Y as SkillSearchResult, a5 as CompanySearchFilters, a6 as CompanySearchResponse, t as RepoDeleteResult, w as RepoInventory } from './types-BV-qBo9i.cjs';
|
|
4
4
|
import * as _tanstack_react_query from '@tanstack/react-query';
|
|
5
5
|
import { UseQueryOptions, UseMutationOptions, UseInfiniteQueryOptions, InfiniteData } from '@tanstack/react-query';
|
|
6
6
|
import { c as Profile, d as ProfilePosition, U as SkillRef, p as ExternalAccount, V as SkillSuggestion, s as OrgFloorVerdict } from './index-syVBnrbI.cjs';
|
|
7
|
-
import { s as sifaQueryKeys, aD as RefreshPdsResult, aU as UpdateProfileOverrideInput, aV as UpdateProfileSelfInput, aW as UploadAvatarResult, aX as UploadPronunciationAudioResult, an as PrimarySection, aO as SubCategoryBulkResult, as as ProfileLocationInput, o as ExternalAccountInput, m as CreateExternalAccountResult, aY as VerifyExternalAccountResult, E as EndorsementInput, k as ConfirmationInput, l as ConfirmationSubjectInput, Z as GivenConfirmation, am as PendingConfirmationsPage, a8 as InboxCounts, n as DismissUnlinkedPositionInput, aT as UnlinkedPositionsResult, ao as ProfileCompleteness, aC as RefreshOrcidPublicationsResult, B as BulkHideProfileItemInput, a7 as HideProfileItemInput, a2 as HiddenActivityItem, a6 as HideActivityItemInput, aR as UnhideActivityItemInput, aN as StatsResponse, h as AppRegistryEntry, a3 as HiddenApp, b as AccountSummary, p as FeaturedProfile, aM as SimilarProfile, L as FetchSuggestionsOptions, aQ as SuggestionsResponse, Q as FollowUserResult, v as FetchFollowListOptions, N as FollowListPage, W as FollowingResponse, x as FetchFollowingFeedOptions, U as FollowingFeedResponse, V as FollowingFeedVersion, w as FetchFollowProfilePageOptions, P as FollowProfilePageResponse, F as FeatureAllowlistResponse, g as AdminReviewQueues, r as FetchActivityFeedOptions, c as ActivityFeedResponse, f as ActivityTeaserResponse, a1 as HeatmapResponse, aa as MyGithubPullRequestsResponse, A as AccountCheckResult, aB as ReactionStatus, aA as ReactionResult, az as ReactionError, aK as RoadmapVotesResponse, i as CastRoadmapVoteResult, D as DeleteAccountResult, aF as ResetProfileResult, aZ as WipePreview, aE as RepoDeleteInput, ac as OrgClaimResult, ai as OrgProfileUpdateResult, ad as OrgDomainChallengeResult, ae as OrgDomainVerifyResult, af as OrgNotificationEmailAddResult, ag as OrgNotificationEmailRemoveResult } from './org-
|
|
7
|
+
import { s as sifaQueryKeys, aD as RefreshPdsResult, aU as UpdateProfileOverrideInput, aV as UpdateProfileSelfInput, aW as UploadAvatarResult, aX as UploadPronunciationAudioResult, an as PrimarySection, aO as SubCategoryBulkResult, as as ProfileLocationInput, o as ExternalAccountInput, m as CreateExternalAccountResult, aY as VerifyExternalAccountResult, E as EndorsementInput, k as ConfirmationInput, l as ConfirmationSubjectInput, Z as GivenConfirmation, am as PendingConfirmationsPage, a8 as InboxCounts, n as DismissUnlinkedPositionInput, aT as UnlinkedPositionsResult, ao as ProfileCompleteness, aC as RefreshOrcidPublicationsResult, B as BulkHideProfileItemInput, a7 as HideProfileItemInput, a2 as HiddenActivityItem, a6 as HideActivityItemInput, aR as UnhideActivityItemInput, aN as StatsResponse, h as AppRegistryEntry, a3 as HiddenApp, b as AccountSummary, p as FeaturedProfile, aM as SimilarProfile, L as FetchSuggestionsOptions, aQ as SuggestionsResponse, Q as FollowUserResult, v as FetchFollowListOptions, N as FollowListPage, W as FollowingResponse, x as FetchFollowingFeedOptions, U as FollowingFeedResponse, V as FollowingFeedVersion, w as FetchFollowProfilePageOptions, P as FollowProfilePageResponse, F as FeatureAllowlistResponse, g as AdminReviewQueues, r as FetchActivityFeedOptions, c as ActivityFeedResponse, f as ActivityTeaserResponse, a1 as HeatmapResponse, aa as MyGithubPullRequestsResponse, A as AccountCheckResult, aB as ReactionStatus, aA as ReactionResult, az as ReactionError, aK as RoadmapVotesResponse, i as CastRoadmapVoteResult, D as DeleteAccountResult, aF as ResetProfileResult, aZ as WipePreview, aE as RepoDeleteInput, ac as OrgClaimResult, ai as OrgProfileUpdateResult, ad as OrgDomainChallengeResult, ae as OrgDomainVerifyResult, af as OrgNotificationEmailAddResult, ag as OrgNotificationEmailRemoveResult } from './org-DZZNwznR.cjs';
|
|
8
|
+
import { z } from 'zod';
|
|
8
9
|
import { i as EntitySearchResponse, E as EntitySearchResult, c as EntityMintDomainResponse, g as EntityResolveDomainResponse, n as EntitySelectResponse, l as EntitySelectRequest, r as FeatureFlag } from './follow-profile-CQ3DTTak.cjs';
|
|
9
10
|
import { O as OrgClaimRequestInput, a as OrgProfileUpdateRequestInput, b as OrgDomainChallengeRequestInput, c as OrgDomainVerifyRequestInput, d as OrgNotificationEmailRequestInput } from './org-settings-C73Sin5E.cjs';
|
|
10
11
|
|
|
@@ -32,6 +33,64 @@ declare function SifaProvider({ config, children }: SifaProviderProps): react.JS
|
|
|
32
33
|
*/
|
|
33
34
|
declare function useSifaConfig(): SifaApiConfig;
|
|
34
35
|
|
|
36
|
+
/**
|
|
37
|
+
* Every kind of fact the employment-verification log can hold. Mirrors
|
|
38
|
+
* `VERIFICATION_EVENT_KINDS` in sifa-api. Kept open (`z.string()`) on the
|
|
39
|
+
* wire so a kind the AppView adds later does not break older clients; the
|
|
40
|
+
* union is the set a client can render specific copy for today.
|
|
41
|
+
*/
|
|
42
|
+
declare const VERIFICATION_EVENT_KINDS: readonly ["mailbox_verified", "domain_recognized", "reverified", "reverification_failed", "org_confirmed", "org_status_changed", "org_revoked", "peer_vouched", "peer_withdrawn"];
|
|
43
|
+
type VerificationEventKind = (typeof VERIFICATION_EVENT_KINDS)[number];
|
|
44
|
+
/**
|
|
45
|
+
* One entry of a position's verification log, newest first, as the AppView
|
|
46
|
+
* returns it. `emailAddress` is present only when the signed-in viewer owns
|
|
47
|
+
* the profile; everyone else gets the domain at most. An AppView READ shape,
|
|
48
|
+
* not a PDS record: the log lives in Sifa's database. Unknown extra fields
|
|
49
|
+
* pass through so the shape stays additive.
|
|
50
|
+
*/
|
|
51
|
+
declare const VerificationLogEntrySchema: z.ZodObject<{
|
|
52
|
+
id: z.ZodNumber;
|
|
53
|
+
kind: z.ZodString;
|
|
54
|
+
occurredAt: z.ZodString;
|
|
55
|
+
entityId: z.ZodDefault<z.ZodNullable<z.ZodNumber>>;
|
|
56
|
+
emailDomain: z.ZodDefault<z.ZodNullable<z.ZodString>>;
|
|
57
|
+
emailAddress: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
58
|
+
meta: z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
59
|
+
}, z.core.$loose>;
|
|
60
|
+
declare const VerificationLogSchema: z.ZodObject<{
|
|
61
|
+
events: z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
62
|
+
id: z.ZodNumber;
|
|
63
|
+
kind: z.ZodString;
|
|
64
|
+
occurredAt: z.ZodString;
|
|
65
|
+
entityId: z.ZodDefault<z.ZodNullable<z.ZodNumber>>;
|
|
66
|
+
emailDomain: z.ZodDefault<z.ZodNullable<z.ZodString>>;
|
|
67
|
+
emailAddress: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
68
|
+
meta: z.ZodDefault<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
69
|
+
}, z.core.$loose>>>;
|
|
70
|
+
}, z.core.$strip>;
|
|
71
|
+
type VerificationLogEntry = z.infer<typeof VerificationLogEntrySchema>;
|
|
72
|
+
type VerificationLog = z.infer<typeof VerificationLogSchema>;
|
|
73
|
+
/** Options for {@link fetchVerificationLog}, adding the RSC cookie-forwarding escape hatch. */
|
|
74
|
+
interface FetchVerificationLogOptions extends ApiFetchOptions {
|
|
75
|
+
/**
|
|
76
|
+
* Pass the caller's `Cookie` header on Next.js RSC server-side calls, so
|
|
77
|
+
* the owner sees full addresses. `credentials: 'include'` does not propagate
|
|
78
|
+
* browser cookies in RSC.
|
|
79
|
+
*/
|
|
80
|
+
cookieHeader?: string;
|
|
81
|
+
}
|
|
82
|
+
/**
|
|
83
|
+
* The verification log of one position, newest first. Public: anyone can read
|
|
84
|
+
* it, the AppView strips the addresses for everyone but the owner.
|
|
85
|
+
*
|
|
86
|
+
* Resolves to an empty log on any failure (network, non-2xx, malformed body)
|
|
87
|
+
* by design, the same contract as the confirmation fetchers: the log is a
|
|
88
|
+
* detail panel on a profile, and a broken panel must never take the profile
|
|
89
|
+
* down with it. Callers that need to distinguish "empty" from "failed" use
|
|
90
|
+
* `apiFetch` directly.
|
|
91
|
+
*/
|
|
92
|
+
declare function fetchVerificationLog(config: SifaApiConfig, did: string, positionRkey: string, options?: FetchVerificationLogOptions): Promise<VerificationLog>;
|
|
93
|
+
|
|
35
94
|
/**
|
|
36
95
|
* React hook that reads an aggregated profile by handle or DID via
|
|
37
96
|
* TanStack Query. Returns `null` data when the profile does not exist.
|
|
@@ -273,6 +332,23 @@ declare function useRevokeConfirmation(claimerHandleOrDid: string | null, option
|
|
|
273
332
|
*/
|
|
274
333
|
declare function useInboxCounts(options?: Omit<UseQueryOptions<InboxCounts, Error, InboxCounts, ReturnType<typeof sifaQueryKeys.inbox.counts>>, 'queryKey' | 'queryFn'>): _tanstack_react_query.UseQueryResult<InboxCounts, Error>;
|
|
275
334
|
|
|
335
|
+
/**
|
|
336
|
+
* The verification log of one position. Returns an empty log on error, so a
|
|
337
|
+
* panel can render "no verification yet" without special-casing failure.
|
|
338
|
+
*/
|
|
339
|
+
declare function useVerificationLog(did: string, positionRkey: string, options?: Omit<UseQueryOptions<VerificationLog, Error, VerificationLog, ReturnType<typeof sifaQueryKeys.verification.log>>, 'queryKey' | 'queryFn'>): _tanstack_react_query.UseQueryResult<{
|
|
340
|
+
events: {
|
|
341
|
+
[x: string]: unknown;
|
|
342
|
+
id: number;
|
|
343
|
+
kind: string;
|
|
344
|
+
occurredAt: string;
|
|
345
|
+
entityId: number | null;
|
|
346
|
+
emailDomain: string | null;
|
|
347
|
+
meta: Record<string, unknown>;
|
|
348
|
+
emailAddress?: string | null | undefined;
|
|
349
|
+
}[];
|
|
350
|
+
}, Error>;
|
|
351
|
+
|
|
276
352
|
/**
|
|
277
353
|
* Positions on the signed-in user's profile whose company is not yet linked to a
|
|
278
354
|
* canonical entity, for the unified Inbox. Returns an empty list when signed out
|
|
@@ -902,4 +978,4 @@ declare function useRemoveOrgNotificationEmail(options?: Omit<UseMutationOptions
|
|
|
902
978
|
email: string;
|
|
903
979
|
}, unknown>;
|
|
904
980
|
|
|
905
|
-
export {
|
|
981
|
+
export { useDebouncedValue as $, type AddFeatureAllowlistVariables as A, useAppsRegistry as B, type CreateReactionVariables as C, type DeleteReactionVariables as D, useAtFundLink as E, type FetchVerificationLogOptions as F, useBlueskySuggestions as G, useBulkHideProfileItems as H, useBulkHideStandardPublications as I, useBulkUnhideProfileItems as J, useBulkUnhideStandardPublications as K, useCanonicalSkillSearch as L, useCastRoadmapVote as M, useCreateConfirmation as N, useCreateEducation as O, type PositionSkillLinkVariables as P, useCreateEndorsement as Q, type RemoveFeatureAllowlistVariables as R, SifaProvider as S, useCreateExternalAccount as T, type UnfollowVariables as U, VERIFICATION_EVENT_KINDS as V, useCreatePosition as W, useCreateProfileLocation as X, useCreateReaction as Y, useCreateRecord as Z, useCreateSkill as _, type CreateRecordVariables as a, useSearchProfiles as a$, useDeleteAccount as a0, useDeleteAvatarOverride as a1, useDeleteEducation as a2, useDeleteExternalAccount as a3, useDeleteNamePronunciationAudio as a4, useDeletePosition as a5, useDeleteProfileLocation as a6, useDeleteReaction as a7, useDeleteRecord as a8, useDeleteRepoRecords as a9, useInboxCounts as aA, useLinkSkillToPosition as aB, useMintEntityDomain as aC, useMutuals as aD, useMyGithubPullRequests as aE, useMyRoadmapVotes as aF, useNetworkStreamCount as aG, useOrgClaim as aH, useOrgDomainChallenge as aI, useOrgDomainVerify as aJ, useOrgProfile as aK, usePendingConfirmations as aL, useProfile as aM, useProfileCompleteness as aN, useReactionStatus as aO, useRefreshOrcidPublications as aP, useRefreshPds as aQ, useRemoveFeatureAllowlist as aR, useRemoveOrgNotificationEmail as aS, useRepoInventory as aT, useResetProfile as aU, useResolveEntityDomain as aV, useRetractRoadmapVote as aW, useRevealMarqueDomain as aX, useRevokeConfirmation as aY, useRoadmapVotes as aZ, useSearchFilters as a_, useDeleteSkill as aa, useDismissConfirmation as ab, useDismissUnlinkedPosition as ac, useEndorsementCount as ad, useEntitySearch as ae, useExternalAccounts as af, useFeatureAllowlist as ag, useFeaturedProfile as ah, useFollow as ai, useFollowers as aj, useFollowing as ak, useFollowingFeed as al, useFollowingFeedVersion as am, useFollowingList as an, useGetProfileView as ao, useGivenConfirmations as ap, useHeatmapData as aq, useHiddenActivityItems as ar, useHiddenApps as as, useHideActivityItem as at, useHideKeytraceClaim as au, useHideOrcidPublication as av, useHideProfileItem as aw, useHideSifaPublication as ax, useHideStandardPublication as ay, useImportSearchEntities as az, type DeleteRecordVariables as b, useSelectEntity as b0, useSetExternalAccountPrimary as b1, useSetPositionPrimary as b2, useSetSectionPrimary as b3, useSifaConfig as b4, useSimilarProfiles as b5, useSkillSuggestions as b6, useStats as b7, useSuggestionCount as b8, useSuggestions as b9, useVerifyExternalAccount as bA, useWipePreview as bB, useSearchCompanies as bC, useUnfollow as ba, useUnhideActivityItem as bb, useUnhideKeytraceClaim as bc, useUnhideOrcidPublication as bd, useUnhideProfileItem as be, useUnhideSifaPublication as bf, useUnhideStandardPublication as bg, useUnlinkSkillFromPosition as bh, useUnlinkedPositions as bi, useUnrevealMarqueDomain as bj, useUnsetExternalAccountPrimary as bk, useUnsetPositionPrimary as bl, useUnsetSectionPrimary as bm, useUpdateEducation as bn, useUpdateExternalAccount as bo, useUpdateOrgProfile as bp, useUpdatePosition as bq, useUpdateProfileLocation as br, useUpdateProfileOverride as bs, useUpdateProfileSelf as bt, useUpdateRecord as bu, useUpdateSkill as bv, useUpdateSkillSubCategories as bw, useUploadAvatar as bx, useUploadNamePronunciationAudio as by, useVerificationLog as bz, type FollowVariables as c, type SifaProviderProps as d, type UpdateEducationVariables as e, type UpdateExternalAccountVariables as f, type UpdatePositionVariables as g, type UpdateProfileLocationVariables as h, type UpdateRecordVariables as i, type UpdateSkillSubCategoriesVariables as j, type UpdateSkillVariables as k, type UseEntitySearchOptions as l, type UseMyGithubPullRequestsParams as m, type VerificationEventKind as n, type VerificationLog as o, type VerificationLogEntry as p, VerificationLogEntrySchema as q, VerificationLogSchema as r, fetchVerificationLog as s, useActivityFeed as t, useAccounts as u, useActivityTeaser as v, useAddFeatureAllowlist as w, useAddOrgNotificationEmail as x, useAdminReviewQueues as y, useAppAccountCheck as z };
|
package/package.json
CHANGED