@oxy.so/contracts 5.8.0 → 6.0.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/cjs/accountAccess.js +6 -5
- package/dist/cjs/accountEmail.js +13 -5
- package/dist/cjs/accountGraph.js +10 -9
- package/dist/cjs/accountName.js +3 -2
- package/dist/cjs/agency.js +91 -34
- package/dist/cjs/agentKeys.js +21 -17
- package/dist/cjs/appAssertions.js +14 -13
- package/dist/cjs/applicationRoles.js +19 -12
- package/dist/cjs/civic.js +10 -9
- package/dist/cjs/client/check.js +61 -53
- package/dist/cjs/consoleOnboarding.js +9 -4
- package/dist/cjs/contentClaims.js +23 -14
- package/dist/cjs/deviceDirectory.js +11 -9
- package/dist/cjs/deviceSession.js +27 -25
- package/dist/cjs/email/messages.js +20 -18
- package/dist/cjs/emailAgentContext.js +11 -9
- package/dist/cjs/externalIdentity.js +15 -11
- package/dist/cjs/federationInstanceFetch.js +12 -7
- package/dist/cjs/identity.js +19 -17
- package/dist/cjs/identityLink.js +6 -4
- package/dist/cjs/identityProof.js +6 -4
- package/dist/cjs/inboxPush.js +5 -4
- package/dist/cjs/index.js +15 -6
- package/dist/cjs/inference/accountBilling.js +35 -33
- package/dist/cjs/inference/aliaModelRelease.js +9 -7
- package/dist/cjs/inference/attribution.js +14 -12
- package/dist/cjs/inference/catalogue.js +35 -29
- package/dist/cjs/inference/economics.js +24 -19
- package/dist/cjs/inference/embeddings.js +9 -7
- package/dist/cjs/inference/entitlement.js +17 -15
- package/dist/cjs/inference/errors.js +15 -8
- package/dist/cjs/inference/identifiers.js +33 -21
- package/dist/cjs/inference/inbox.js +37 -35
- package/dist/cjs/inference/modelDocumentation.js +16 -14
- package/dist/cjs/inference/money.js +5 -4
- package/dist/cjs/inference/priceVersion.js +10 -5
- package/dist/cjs/inference/providerConnection.js +21 -14
- package/dist/cjs/inference/realtime.js +88 -47
- package/dist/cjs/inference/request.js +27 -25
- package/dist/cjs/inference/routingPolicy.js +12 -10
- package/dist/cjs/inference/streamEvents.js +22 -16
- package/dist/cjs/inference/usage.js +32 -15
- package/dist/cjs/keyRecovery.js +8 -6
- package/dist/cjs/keyRotation.js +5 -4
- package/dist/cjs/linkedAccounts.js +22 -18
- package/dist/cjs/moderationReputation.js +29 -27
- package/dist/cjs/notifications.js +25 -9
- package/dist/cjs/numberChecks.js +45 -0
- package/dist/cjs/oauth.js +14 -12
- package/dist/cjs/organizations.js +23 -21
- package/dist/cjs/products/access.js +10 -8
- package/dist/cjs/products/billing.js +10 -8
- package/dist/cjs/products/checkout.js +22 -10
- package/dist/cjs/products/plans.js +15 -10
- package/dist/cjs/protocol.js +6 -5
- package/dist/cjs/recommendations.js +27 -19
- package/dist/cjs/reputation.js +15 -13
- package/dist/cjs/safety.js +43 -27
- package/dist/cjs/serviceToken.js +81 -2
- package/dist/cjs/sessionRevocation.js +8 -6
- package/dist/cjs/signIn.js +42 -24
- package/dist/cjs/stickers.js +19 -15
- package/dist/cjs/stringChecks.js +70 -0
- package/dist/cjs/transparency.js +14 -12
- package/dist/cjs/updates.js +24 -22
- package/dist/cjs/userInvalidation.js +7 -5
- package/dist/cjs/userResponse.js +8 -7
- package/dist/cjs/username.js +7 -6
- package/dist/esm/accountAccess.js +4 -3
- package/dist/esm/accountEmail.js +13 -5
- package/dist/esm/accountGraph.js +8 -7
- package/dist/esm/accountName.js +3 -2
- package/dist/esm/agency.js +90 -33
- package/dist/esm/agentKeys.js +21 -17
- package/dist/esm/appAssertions.js +11 -10
- package/dist/esm/applicationRoles.js +16 -9
- package/dist/esm/civic.js +8 -7
- package/dist/esm/client/check.js +61 -53
- package/dist/esm/consoleOnboarding.js +7 -2
- package/dist/esm/contentClaims.js +23 -14
- package/dist/esm/deviceDirectory.js +11 -9
- package/dist/esm/deviceSession.js +27 -25
- package/dist/esm/email/messages.js +18 -16
- package/dist/esm/emailAgentContext.js +11 -9
- package/dist/esm/externalIdentity.js +15 -11
- package/dist/esm/federationInstanceFetch.js +10 -5
- package/dist/esm/identity.js +17 -15
- package/dist/esm/identityLink.js +6 -4
- package/dist/esm/identityProof.js +6 -4
- package/dist/esm/inboxPush.js +3 -2
- package/dist/esm/index.js +4 -2
- package/dist/esm/inference/accountBilling.js +33 -31
- package/dist/esm/inference/aliaModelRelease.js +7 -5
- package/dist/esm/inference/attribution.js +14 -12
- package/dist/esm/inference/catalogue.js +33 -27
- package/dist/esm/inference/economics.js +22 -17
- package/dist/esm/inference/embeddings.js +9 -7
- package/dist/esm/inference/entitlement.js +15 -13
- package/dist/esm/inference/errors.js +13 -6
- package/dist/esm/inference/identifiers.js +31 -19
- package/dist/esm/inference/inbox.js +37 -35
- package/dist/esm/inference/modelDocumentation.js +14 -12
- package/dist/esm/inference/money.js +3 -2
- package/dist/esm/inference/priceVersion.js +8 -3
- package/dist/esm/inference/providerConnection.js +19 -12
- package/dist/esm/inference/realtime.js +85 -44
- package/dist/esm/inference/request.js +25 -23
- package/dist/esm/inference/routingPolicy.js +9 -7
- package/dist/esm/inference/streamEvents.js +20 -14
- package/dist/esm/inference/usage.js +30 -13
- package/dist/esm/keyRecovery.js +8 -6
- package/dist/esm/keyRotation.js +5 -4
- package/dist/esm/linkedAccounts.js +20 -16
- package/dist/esm/moderationReputation.js +27 -25
- package/dist/esm/notifications.js +23 -7
- package/dist/esm/numberChecks.js +41 -0
- package/dist/esm/oauth.js +14 -12
- package/dist/esm/organizations.js +23 -21
- package/dist/esm/products/access.js +10 -8
- package/dist/esm/products/billing.js +10 -8
- package/dist/esm/products/checkout.js +22 -10
- package/dist/esm/products/plans.js +15 -10
- package/dist/esm/protocol.js +4 -3
- package/dist/esm/recommendations.js +25 -17
- package/dist/esm/reputation.js +13 -11
- package/dist/esm/safety.js +43 -27
- package/dist/esm/serviceToken.js +80 -1
- package/dist/esm/sessionRevocation.js +6 -4
- package/dist/esm/signIn.js +42 -24
- package/dist/esm/stickers.js +17 -13
- package/dist/esm/stringChecks.js +63 -0
- package/dist/esm/transparency.js +14 -12
- package/dist/esm/updates.js +22 -20
- package/dist/esm/userInvalidation.js +4 -2
- package/dist/esm/userResponse.js +4 -3
- package/dist/esm/username.js +3 -2
- package/dist/types/accountAccess.d.ts +29 -70
- package/dist/types/accountEmail.d.ts +2 -14
- package/dist/types/accountGraph.d.ts +179 -171
- package/dist/types/accountName.d.ts +1 -1
- package/dist/types/accountSubject.d.ts +20 -93
- package/dist/types/agency.d.ts +528 -2924
- package/dist/types/agentKeys.d.ts +48 -421
- package/dist/types/appAssertions.d.ts +56 -210
- package/dist/types/applicationRoles.d.ts +30 -276
- package/dist/types/avatarCharacter.d.ts +1 -1
- package/dist/types/civic.d.ts +1 -13
- package/dist/types/client/agentKeys.d.ts +18 -18
- package/dist/types/client/appAssertions.d.ts +3 -3
- package/dist/types/client/check.d.ts +13 -13
- package/dist/types/client/deviceDirectory.d.ts +51 -51
- package/dist/types/client/deviceSession.d.ts +14 -14
- package/dist/types/client/organizations.d.ts +25 -25
- package/dist/types/client/products.d.ts +33 -33
- package/dist/types/client/recommendations.d.ts +2 -2
- package/dist/types/client/safety.d.ts +45 -45
- package/dist/types/client/sessionStatus.d.ts +4 -4
- package/dist/types/client/signIn.d.ts +1 -1
- package/dist/types/commonsSignIn.d.ts +4 -1
- package/dist/types/consoleOnboarding.d.ts +24 -44
- package/dist/types/contentClaims.d.ts +24 -180
- package/dist/types/deviceDirectory.d.ts +109 -1040
- package/dist/types/deviceSession.d.ts +36 -298
- package/dist/types/email/messages.d.ts +212 -1793
- package/dist/types/emailAgentContext.d.ts +10 -194
- package/dist/types/externalIdentity.d.ts +121 -615
- package/dist/types/federationInstanceFetch.d.ts +3 -32
- package/dist/types/identity.d.ts +15 -92
- package/dist/types/identityLink.d.ts +6 -84
- package/dist/types/identityProof.d.ts +5 -17
- package/dist/types/inboxPush.d.ts +1 -9
- package/dist/types/index.d.ts +5 -3
- package/dist/types/inference/accountBilling.d.ts +151 -488
- package/dist/types/inference/aliaModelRelease.d.ts +42 -439
- package/dist/types/inference/attribution.d.ts +75 -104
- package/dist/types/inference/catalogue.d.ts +417 -1599
- package/dist/types/inference/economics.d.ts +69 -276
- package/dist/types/inference/embeddings.d.ts +110 -406
- package/dist/types/inference/entitlement.d.ts +80 -335
- package/dist/types/inference/errors.d.ts +90 -102
- package/dist/types/inference/identifiers.d.ts +12 -4
- package/dist/types/inference/inbox.d.ts +105 -420
- package/dist/types/inference/modelDocumentation.d.ts +201 -1390
- package/dist/types/inference/money.d.ts +65 -32
- package/dist/types/inference/priceVersion.d.ts +53 -120
- package/dist/types/inference/providerConnection.d.ts +253 -710
- package/dist/types/inference/realtime.d.ts +954 -6825
- package/dist/types/inference/request.d.ts +300 -2572
- package/dist/types/inference/routingPolicy.d.ts +95 -503
- package/dist/types/inference/streamEvents.d.ts +253 -721
- package/dist/types/inference/usage.d.ts +317 -950
- package/dist/types/keyRecovery.d.ts +3 -51
- package/dist/types/keyRotation.d.ts +3 -38
- package/dist/types/linkedAccounts.d.ts +50 -236
- package/dist/types/moderationReputation.d.ts +81 -14
- package/dist/types/notifications.d.ts +19 -51
- package/dist/types/numberChecks.d.ts +9 -0
- package/dist/types/oauth.d.ts +101 -809
- package/dist/types/organizations.d.ts +268 -921
- package/dist/types/oxyRecordTypes.d.ts +11 -1
- package/dist/types/products/access.d.ts +125 -775
- package/dist/types/products/billing.d.ts +67 -503
- package/dist/types/products/checkout.d.ts +16 -69
- package/dist/types/products/plans.d.ts +33 -366
- package/dist/types/recommendations.d.ts +76 -389
- package/dist/types/reputation.d.ts +37 -5
- package/dist/types/safety.d.ts +408 -2048
- package/dist/types/serviceToken.d.ts +247 -7
- package/dist/types/sessionRevocation.d.ts +2 -17
- package/dist/types/sessionStatus.d.ts +27 -115
- package/dist/types/signIn.d.ts +53 -553
- package/dist/types/stickers.d.ts +67 -819
- package/dist/types/stringChecks.d.ts +16 -0
- package/dist/types/transparency.d.ts +14 -302
- package/dist/types/updates.d.ts +60 -316
- package/dist/types/userInvalidation.d.ts +4 -13
- package/dist/types/userResponse.d.ts +302 -2400
- package/dist/types/username.d.ts +3 -3
- package/package.json +2 -2
|
@@ -111,7 +111,7 @@ export declare const themePreferenceSchema: z.ZodType<ThemePreference>;
|
|
|
111
111
|
* a date with no timezone of its own is evaluated in UTC rather than any
|
|
112
112
|
* particular caller's local zone.
|
|
113
113
|
*/
|
|
114
|
-
export declare const dateOfBirthSchema: z.
|
|
114
|
+
export declare const dateOfBirthSchema: z.ZodString;
|
|
115
115
|
/**
|
|
116
116
|
* The canonical user object emitted by `formatUserResponse`.
|
|
117
117
|
*
|
|
@@ -130,9 +130,7 @@ export declare const dateOfBirthSchema: z.ZodEffects<z.ZodEffects<z.ZodEffects<z
|
|
|
130
130
|
* identity/display fields are the ones we pin precisely.
|
|
131
131
|
*/
|
|
132
132
|
export declare const userResponseSchema: z.ZodObject<{
|
|
133
|
-
/** The user id as a string. Present on `formatUserResponse` output. */
|
|
134
133
|
id: z.ZodOptional<z.ZodString>;
|
|
135
|
-
/** Raw-document id (e.g. `GET /users/me`). Present when `id` is not. */
|
|
136
134
|
_id: z.ZodOptional<z.ZodString>;
|
|
137
135
|
publicKey: z.ZodOptional<z.ZodString>;
|
|
138
136
|
username: z.ZodOptional<z.ZodString>;
|
|
@@ -140,578 +138,95 @@ export declare const userResponseSchema: z.ZodObject<{
|
|
|
140
138
|
phone: z.ZodOptional<z.ZodString>;
|
|
141
139
|
address: z.ZodOptional<z.ZodString>;
|
|
142
140
|
birthday: z.ZodOptional<z.ZodString>;
|
|
143
|
-
|
|
144
|
-
* Structured date of birth, `YYYY-MM-DD`. Present only on the
|
|
145
|
-
* account's OWN profile response (`GET /users/me`, `PUT /users/me`
|
|
146
|
-
* with `includePrivateFields`) — never on another account's profile,
|
|
147
|
-
* the same visibility `phone`/`address`/`birthday` already have. See
|
|
148
|
-
* {@link dateOfBirthSchema}.
|
|
149
|
-
*/
|
|
150
|
-
dateOfBirth: z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>, string, string>>;
|
|
151
|
-
/**
|
|
152
|
-
* Derived, non-PII signal: whether the account holder is at least 18
|
|
153
|
-
* (see `computeIsAdult` in `user.service.ts` for the exact threshold
|
|
154
|
-
* and the UTC-"today" choice). Computed fresh on every read — age
|
|
155
|
-
* changes daily, so this is never stored. `undefined` when
|
|
156
|
-
* `dateOfBirth` is unset ("unknown"), distinct from `false` ("known,
|
|
157
|
-
* not yet 18"). Rides the same owner-only visibility as
|
|
158
|
-
* `dateOfBirth`; a future pass may widen this specific field to
|
|
159
|
-
* other viewers without exposing the birthdate itself, but that is
|
|
160
|
-
* not decided here.
|
|
161
|
-
*/
|
|
141
|
+
dateOfBirth: z.ZodOptional<z.ZodString>;
|
|
162
142
|
isAdult: z.ZodOptional<z.ZodBoolean>;
|
|
163
|
-
/** Avatar file id (string) or null. */
|
|
164
143
|
avatar: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
165
|
-
/** Named Bloom color preset (e.g. `"blue"`) or null. */
|
|
166
144
|
color: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
167
|
-
name: z.ZodType<UserNameResponse, z.
|
|
145
|
+
name: z.ZodType<UserNameResponse, unknown, z.core.$ZodTypeInternals<UserNameResponse, unknown>>;
|
|
168
146
|
verified: z.ZodOptional<z.ZodBoolean>;
|
|
169
|
-
|
|
170
|
-
* The account's languages as full BCP-47 locales (`language-REGION`,
|
|
171
|
-
* e.g. `es-ES`, `en-US`, `pt-BR`), ordered with the PRIMARY (UI) locale
|
|
172
|
-
* first. `languages[0]` is the primary locale — there is no singular
|
|
173
|
-
* `language` field.
|
|
174
|
-
*/
|
|
175
|
-
languages: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
176
|
-
/**
|
|
177
|
-
* The account's self-sovereign identifier
|
|
178
|
-
* (`did:web:<FEDERATION_DOMAIN>:u:<userId>`). Surfaced as a `User`
|
|
179
|
-
* virtual; present on formatted DTOs once the identity layer is live.
|
|
180
|
-
*/
|
|
147
|
+
languages: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
181
148
|
did: z.ZodOptional<z.ZodString>;
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
* ORTHOGONAL to `type` (`local` / `federated` / `agent` / `automated`),
|
|
191
|
-
* which says where the account lives and how it is driven; the two
|
|
192
|
-
* coexist and neither substitutes for the other. A `channel` is a
|
|
193
|
-
* publishing identity nobody can act as, so a consumer that renders
|
|
194
|
-
* authored content reads THIS to tell a channel's post from a person's.
|
|
195
|
-
*
|
|
196
|
-
* Optional because a DTO produced from a source that never carried the
|
|
197
|
-
* column omits it; absent should be read as `personal`, the column's
|
|
198
|
-
* default, not as unknown.
|
|
199
|
-
*/
|
|
200
|
-
kind: z.ZodOptional<z.ZodEnum<["personal", "organization", "project", "bot", "channel", "community"]>>;
|
|
201
|
-
/**
|
|
202
|
-
* What this account is about — the field a profile screen RENDERS.
|
|
203
|
-
*
|
|
204
|
-
* **Ordered, primary first.** `accountCategories[0]` is the primary
|
|
205
|
-
* category; there is deliberately no sibling `primaryCategory` field,
|
|
206
|
-
* because two representations of one fact can disagree (see rule 2 in
|
|
207
|
-
* `accountGraph.ts`). Nothing downstream may sort, de-duplicate or
|
|
208
|
-
* otherwise reorder this array.
|
|
209
|
-
*
|
|
210
|
-
* **Ids, never labels.** Each element is a stable slug; the visible text
|
|
211
|
-
* comes from the reader's own translation catalogue, keyed
|
|
212
|
-
* `accounts.accountCategory.<id>`. A label on the wire would paint every
|
|
213
|
-
* profile in the language of whoever picked it.
|
|
214
|
-
*
|
|
215
|
-
* Absent when the account has none — which is every `personal` account,
|
|
216
|
-
* and any non-personal one that has not chosen. A renderer reads
|
|
217
|
-
* `user.accountCategories ?? []`.
|
|
218
|
-
*/
|
|
219
|
-
accountCategories: z.ZodOptional<z.ZodEffects<z.ZodArray<z.ZodEnum<["news", "politics", "business", "startup", "finance", "crypto", "marketplace", "retail", "real_estate", "agency", "landlord", "cooperative", "architecture", "technology", "software", "ai", "security", "automation", "science", "education", "books", "health", "fitness", "sports", "gaming", "music", "film", "podcast", "art", "photography", "comedy", "food", "travel", "fashion", "home_garden", "diy", "automotive", "animals", "family", "nonprofit", "government", "community", "activism", "environment", "religion", "other"]>, "many">, ("community" | "news" | "politics" | "business" | "startup" | "finance" | "crypto" | "marketplace" | "retail" | "real_estate" | "agency" | "landlord" | "cooperative" | "architecture" | "technology" | "software" | "ai" | "security" | "automation" | "science" | "education" | "books" | "health" | "fitness" | "sports" | "gaming" | "music" | "film" | "podcast" | "art" | "photography" | "comedy" | "food" | "travel" | "fashion" | "home_garden" | "diy" | "automotive" | "animals" | "family" | "nonprofit" | "government" | "activism" | "environment" | "religion" | "other")[], ("community" | "news" | "politics" | "business" | "startup" | "finance" | "crypto" | "marketplace" | "retail" | "real_estate" | "agency" | "landlord" | "cooperative" | "architecture" | "technology" | "software" | "ai" | "security" | "automation" | "science" | "education" | "books" | "health" | "fitness" | "sports" | "gaming" | "music" | "film" | "podcast" | "art" | "photography" | "comedy" | "food" | "travel" | "fashion" | "home_garden" | "diy" | "automotive" | "animals" | "family" | "nonprofit" | "government" | "activism" | "environment" | "religion" | "other")[]>>;
|
|
220
|
-
/**
|
|
221
|
-
* The 3D avatar character of a `kind: 'bot'` account — what Bloom's
|
|
222
|
-
* `Avatar` draws instead of a picture. Present ONLY on a bot's payload,
|
|
223
|
-
* never on a person's or an organization's, so those DTOs do not grow.
|
|
224
|
-
*/
|
|
225
|
-
character: z.ZodOptional<z.ZodType<import("./avatarCharacter").AvatarCharacter, z.ZodTypeDef, unknown>>;
|
|
226
|
-
/**
|
|
227
|
-
* The authenticated viewer's relationship to this profile. Present ONLY
|
|
228
|
-
* on single-profile fetches (`GET /profiles/username/:username`,
|
|
229
|
-
* `GET /users/:userId`) when the request is authenticated; OMITTED for
|
|
230
|
-
* anonymous requests and for the bulk `POST /users/by-ids` fan-out.
|
|
231
|
-
*/
|
|
232
|
-
relationship: z.ZodOptional<z.ZodType<UserRelationship, z.ZodTypeDef, UserRelationship>>;
|
|
233
|
-
/**
|
|
234
|
-
* Portable theme preference. Rides the self/session payload (cold boot),
|
|
235
|
-
* so it is present on the current-user DTO (`GET /users/me`,
|
|
236
|
-
* `GET /session/user/:sessionId`) and absent until the user sets it.
|
|
237
|
-
*/
|
|
238
|
-
userPreferences: z.ZodOptional<z.ZodObject<{
|
|
239
|
-
displayCurrency: z.ZodOptional<z.ZodEnum<["USD", "EUR", "FAIR"]>>;
|
|
240
|
-
}, "strip", z.ZodUnknown, z.objectOutputType<{
|
|
241
|
-
displayCurrency: z.ZodOptional<z.ZodEnum<["USD", "EUR", "FAIR"]>>;
|
|
242
|
-
}, z.ZodUnknown, "strip">, z.objectInputType<{
|
|
243
|
-
displayCurrency: z.ZodOptional<z.ZodEnum<["USD", "EUR", "FAIR"]>>;
|
|
244
|
-
}, z.ZodUnknown, "strip">>>;
|
|
245
|
-
themePreference: z.ZodOptional<z.ZodType<ThemePreference, z.ZodTypeDef, ThemePreference>>;
|
|
246
|
-
personalization: z.ZodOptional<z.ZodObject<{
|
|
247
|
-
mentionMono: z.ZodObject<{
|
|
248
|
-
allowed: z.ZodBoolean;
|
|
249
|
-
expiresAt: z.ZodNullable<z.ZodString>;
|
|
250
|
-
}, "strict", z.ZodTypeAny, {
|
|
251
|
-
expiresAt: string | null;
|
|
252
|
-
allowed: boolean;
|
|
253
|
-
}, {
|
|
254
|
-
expiresAt: string | null;
|
|
255
|
-
allowed: boolean;
|
|
256
|
-
}>;
|
|
257
|
-
}, "strict", z.ZodTypeAny, {
|
|
258
|
-
mentionMono: {
|
|
259
|
-
expiresAt: string | null;
|
|
260
|
-
allowed: boolean;
|
|
261
|
-
};
|
|
262
|
-
}, {
|
|
263
|
-
mentionMono: {
|
|
264
|
-
expiresAt: string | null;
|
|
265
|
-
allowed: boolean;
|
|
266
|
-
};
|
|
149
|
+
verifiedDomains: z.ZodOptional<z.ZodArray<z.ZodType<import("./identity").VerifiedDomain, unknown, z.core.$ZodTypeInternals<import("./identity").VerifiedDomain, unknown>>>>;
|
|
150
|
+
kind: z.ZodOptional<z.ZodEnum<{
|
|
151
|
+
personal: "personal";
|
|
152
|
+
organization: "organization";
|
|
153
|
+
project: "project";
|
|
154
|
+
bot: "bot";
|
|
155
|
+
channel: "channel";
|
|
156
|
+
community: "community";
|
|
267
157
|
}>>;
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
|
|
285
|
-
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
296
|
-
|
|
297
|
-
|
|
298
|
-
|
|
299
|
-
|
|
300
|
-
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
312
|
-
|
|
313
|
-
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
/**
|
|
319
|
-
* Proven domain-ownership badges. Each is a {@link verifiedDomainSchema}
|
|
320
|
-
* entry; present only when the account has verified at least one domain.
|
|
321
|
-
*/
|
|
322
|
-
verifiedDomains: z.ZodOptional<z.ZodArray<z.ZodType<import("./identity").VerifiedDomain, z.ZodTypeDef, import("./identity").VerifiedDomain>, "many">>;
|
|
323
|
-
/**
|
|
324
|
-
* Account-graph classification — what KIND of account this is.
|
|
325
|
-
*
|
|
326
|
-
* ORTHOGONAL to `type` (`local` / `federated` / `agent` / `automated`),
|
|
327
|
-
* which says where the account lives and how it is driven; the two
|
|
328
|
-
* coexist and neither substitutes for the other. A `channel` is a
|
|
329
|
-
* publishing identity nobody can act as, so a consumer that renders
|
|
330
|
-
* authored content reads THIS to tell a channel's post from a person's.
|
|
331
|
-
*
|
|
332
|
-
* Optional because a DTO produced from a source that never carried the
|
|
333
|
-
* column omits it; absent should be read as `personal`, the column's
|
|
334
|
-
* default, not as unknown.
|
|
335
|
-
*/
|
|
336
|
-
kind: z.ZodOptional<z.ZodEnum<["personal", "organization", "project", "bot", "channel", "community"]>>;
|
|
337
|
-
/**
|
|
338
|
-
* What this account is about — the field a profile screen RENDERS.
|
|
339
|
-
*
|
|
340
|
-
* **Ordered, primary first.** `accountCategories[0]` is the primary
|
|
341
|
-
* category; there is deliberately no sibling `primaryCategory` field,
|
|
342
|
-
* because two representations of one fact can disagree (see rule 2 in
|
|
343
|
-
* `accountGraph.ts`). Nothing downstream may sort, de-duplicate or
|
|
344
|
-
* otherwise reorder this array.
|
|
345
|
-
*
|
|
346
|
-
* **Ids, never labels.** Each element is a stable slug; the visible text
|
|
347
|
-
* comes from the reader's own translation catalogue, keyed
|
|
348
|
-
* `accounts.accountCategory.<id>`. A label on the wire would paint every
|
|
349
|
-
* profile in the language of whoever picked it.
|
|
350
|
-
*
|
|
351
|
-
* Absent when the account has none — which is every `personal` account,
|
|
352
|
-
* and any non-personal one that has not chosen. A renderer reads
|
|
353
|
-
* `user.accountCategories ?? []`.
|
|
354
|
-
*/
|
|
355
|
-
accountCategories: z.ZodOptional<z.ZodEffects<z.ZodArray<z.ZodEnum<["news", "politics", "business", "startup", "finance", "crypto", "marketplace", "retail", "real_estate", "agency", "landlord", "cooperative", "architecture", "technology", "software", "ai", "security", "automation", "science", "education", "books", "health", "fitness", "sports", "gaming", "music", "film", "podcast", "art", "photography", "comedy", "food", "travel", "fashion", "home_garden", "diy", "automotive", "animals", "family", "nonprofit", "government", "community", "activism", "environment", "religion", "other"]>, "many">, ("community" | "news" | "politics" | "business" | "startup" | "finance" | "crypto" | "marketplace" | "retail" | "real_estate" | "agency" | "landlord" | "cooperative" | "architecture" | "technology" | "software" | "ai" | "security" | "automation" | "science" | "education" | "books" | "health" | "fitness" | "sports" | "gaming" | "music" | "film" | "podcast" | "art" | "photography" | "comedy" | "food" | "travel" | "fashion" | "home_garden" | "diy" | "automotive" | "animals" | "family" | "nonprofit" | "government" | "activism" | "environment" | "religion" | "other")[], ("community" | "news" | "politics" | "business" | "startup" | "finance" | "crypto" | "marketplace" | "retail" | "real_estate" | "agency" | "landlord" | "cooperative" | "architecture" | "technology" | "software" | "ai" | "security" | "automation" | "science" | "education" | "books" | "health" | "fitness" | "sports" | "gaming" | "music" | "film" | "podcast" | "art" | "photography" | "comedy" | "food" | "travel" | "fashion" | "home_garden" | "diy" | "automotive" | "animals" | "family" | "nonprofit" | "government" | "activism" | "environment" | "religion" | "other")[]>>;
|
|
356
|
-
/**
|
|
357
|
-
* The 3D avatar character of a `kind: 'bot'` account — what Bloom's
|
|
358
|
-
* `Avatar` draws instead of a picture. Present ONLY on a bot's payload,
|
|
359
|
-
* never on a person's or an organization's, so those DTOs do not grow.
|
|
360
|
-
*/
|
|
361
|
-
character: z.ZodOptional<z.ZodType<import("./avatarCharacter").AvatarCharacter, z.ZodTypeDef, unknown>>;
|
|
362
|
-
/**
|
|
363
|
-
* The authenticated viewer's relationship to this profile. Present ONLY
|
|
364
|
-
* on single-profile fetches (`GET /profiles/username/:username`,
|
|
365
|
-
* `GET /users/:userId`) when the request is authenticated; OMITTED for
|
|
366
|
-
* anonymous requests and for the bulk `POST /users/by-ids` fan-out.
|
|
367
|
-
*/
|
|
368
|
-
relationship: z.ZodOptional<z.ZodType<UserRelationship, z.ZodTypeDef, UserRelationship>>;
|
|
369
|
-
/**
|
|
370
|
-
* Portable theme preference. Rides the self/session payload (cold boot),
|
|
371
|
-
* so it is present on the current-user DTO (`GET /users/me`,
|
|
372
|
-
* `GET /session/user/:sessionId`) and absent until the user sets it.
|
|
373
|
-
*/
|
|
374
|
-
userPreferences: z.ZodOptional<z.ZodObject<{
|
|
375
|
-
displayCurrency: z.ZodOptional<z.ZodEnum<["USD", "EUR", "FAIR"]>>;
|
|
376
|
-
}, "strip", z.ZodUnknown, z.objectOutputType<{
|
|
377
|
-
displayCurrency: z.ZodOptional<z.ZodEnum<["USD", "EUR", "FAIR"]>>;
|
|
378
|
-
}, z.ZodUnknown, "strip">, z.objectInputType<{
|
|
379
|
-
displayCurrency: z.ZodOptional<z.ZodEnum<["USD", "EUR", "FAIR"]>>;
|
|
380
|
-
}, z.ZodUnknown, "strip">>>;
|
|
381
|
-
themePreference: z.ZodOptional<z.ZodType<ThemePreference, z.ZodTypeDef, ThemePreference>>;
|
|
382
|
-
personalization: z.ZodOptional<z.ZodObject<{
|
|
383
|
-
mentionMono: z.ZodObject<{
|
|
384
|
-
allowed: z.ZodBoolean;
|
|
385
|
-
expiresAt: z.ZodNullable<z.ZodString>;
|
|
386
|
-
}, "strict", z.ZodTypeAny, {
|
|
387
|
-
expiresAt: string | null;
|
|
388
|
-
allowed: boolean;
|
|
389
|
-
}, {
|
|
390
|
-
expiresAt: string | null;
|
|
391
|
-
allowed: boolean;
|
|
392
|
-
}>;
|
|
393
|
-
}, "strict", z.ZodTypeAny, {
|
|
394
|
-
mentionMono: {
|
|
395
|
-
expiresAt: string | null;
|
|
396
|
-
allowed: boolean;
|
|
397
|
-
};
|
|
398
|
-
}, {
|
|
399
|
-
mentionMono: {
|
|
400
|
-
expiresAt: string | null;
|
|
401
|
-
allowed: boolean;
|
|
402
|
-
};
|
|
403
|
-
}>>;
|
|
404
|
-
}, z.ZodTypeAny, "passthrough">, z.objectInputType<{
|
|
405
|
-
/** The user id as a string. Present on `formatUserResponse` output. */
|
|
406
|
-
id: z.ZodOptional<z.ZodString>;
|
|
407
|
-
/** Raw-document id (e.g. `GET /users/me`). Present when `id` is not. */
|
|
408
|
-
_id: z.ZodOptional<z.ZodString>;
|
|
409
|
-
publicKey: z.ZodOptional<z.ZodString>;
|
|
410
|
-
username: z.ZodOptional<z.ZodString>;
|
|
411
|
-
email: z.ZodOptional<z.ZodString>;
|
|
412
|
-
phone: z.ZodOptional<z.ZodString>;
|
|
413
|
-
address: z.ZodOptional<z.ZodString>;
|
|
414
|
-
birthday: z.ZodOptional<z.ZodString>;
|
|
415
|
-
/**
|
|
416
|
-
* Structured date of birth, `YYYY-MM-DD`. Present only on the
|
|
417
|
-
* account's OWN profile response (`GET /users/me`, `PUT /users/me`
|
|
418
|
-
* with `includePrivateFields`) — never on another account's profile,
|
|
419
|
-
* the same visibility `phone`/`address`/`birthday` already have. See
|
|
420
|
-
* {@link dateOfBirthSchema}.
|
|
421
|
-
*/
|
|
422
|
-
dateOfBirth: z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>, string, string>>;
|
|
423
|
-
/**
|
|
424
|
-
* Derived, non-PII signal: whether the account holder is at least 18
|
|
425
|
-
* (see `computeIsAdult` in `user.service.ts` for the exact threshold
|
|
426
|
-
* and the UTC-"today" choice). Computed fresh on every read — age
|
|
427
|
-
* changes daily, so this is never stored. `undefined` when
|
|
428
|
-
* `dateOfBirth` is unset ("unknown"), distinct from `false` ("known,
|
|
429
|
-
* not yet 18"). Rides the same owner-only visibility as
|
|
430
|
-
* `dateOfBirth`; a future pass may widen this specific field to
|
|
431
|
-
* other viewers without exposing the birthdate itself, but that is
|
|
432
|
-
* not decided here.
|
|
433
|
-
*/
|
|
434
|
-
isAdult: z.ZodOptional<z.ZodBoolean>;
|
|
435
|
-
/** Avatar file id (string) or null. */
|
|
436
|
-
avatar: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
437
|
-
/** Named Bloom color preset (e.g. `"blue"`) or null. */
|
|
438
|
-
color: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
439
|
-
name: z.ZodType<UserNameResponse, z.ZodTypeDef, UserNameResponse>;
|
|
440
|
-
verified: z.ZodOptional<z.ZodBoolean>;
|
|
441
|
-
/**
|
|
442
|
-
* The account's languages as full BCP-47 locales (`language-REGION`,
|
|
443
|
-
* e.g. `es-ES`, `en-US`, `pt-BR`), ordered with the PRIMARY (UI) locale
|
|
444
|
-
* first. `languages[0]` is the primary locale — there is no singular
|
|
445
|
-
* `language` field.
|
|
446
|
-
*/
|
|
447
|
-
languages: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
448
|
-
/**
|
|
449
|
-
* The account's self-sovereign identifier
|
|
450
|
-
* (`did:web:<FEDERATION_DOMAIN>:u:<userId>`). Surfaced as a `User`
|
|
451
|
-
* virtual; present on formatted DTOs once the identity layer is live.
|
|
452
|
-
*/
|
|
453
|
-
did: z.ZodOptional<z.ZodString>;
|
|
454
|
-
/**
|
|
455
|
-
* Proven domain-ownership badges. Each is a {@link verifiedDomainSchema}
|
|
456
|
-
* entry; present only when the account has verified at least one domain.
|
|
457
|
-
*/
|
|
458
|
-
verifiedDomains: z.ZodOptional<z.ZodArray<z.ZodType<import("./identity").VerifiedDomain, z.ZodTypeDef, import("./identity").VerifiedDomain>, "many">>;
|
|
459
|
-
/**
|
|
460
|
-
* Account-graph classification — what KIND of account this is.
|
|
461
|
-
*
|
|
462
|
-
* ORTHOGONAL to `type` (`local` / `federated` / `agent` / `automated`),
|
|
463
|
-
* which says where the account lives and how it is driven; the two
|
|
464
|
-
* coexist and neither substitutes for the other. A `channel` is a
|
|
465
|
-
* publishing identity nobody can act as, so a consumer that renders
|
|
466
|
-
* authored content reads THIS to tell a channel's post from a person's.
|
|
467
|
-
*
|
|
468
|
-
* Optional because a DTO produced from a source that never carried the
|
|
469
|
-
* column omits it; absent should be read as `personal`, the column's
|
|
470
|
-
* default, not as unknown.
|
|
471
|
-
*/
|
|
472
|
-
kind: z.ZodOptional<z.ZodEnum<["personal", "organization", "project", "bot", "channel", "community"]>>;
|
|
473
|
-
/**
|
|
474
|
-
* What this account is about — the field a profile screen RENDERS.
|
|
475
|
-
*
|
|
476
|
-
* **Ordered, primary first.** `accountCategories[0]` is the primary
|
|
477
|
-
* category; there is deliberately no sibling `primaryCategory` field,
|
|
478
|
-
* because two representations of one fact can disagree (see rule 2 in
|
|
479
|
-
* `accountGraph.ts`). Nothing downstream may sort, de-duplicate or
|
|
480
|
-
* otherwise reorder this array.
|
|
481
|
-
*
|
|
482
|
-
* **Ids, never labels.** Each element is a stable slug; the visible text
|
|
483
|
-
* comes from the reader's own translation catalogue, keyed
|
|
484
|
-
* `accounts.accountCategory.<id>`. A label on the wire would paint every
|
|
485
|
-
* profile in the language of whoever picked it.
|
|
486
|
-
*
|
|
487
|
-
* Absent when the account has none — which is every `personal` account,
|
|
488
|
-
* and any non-personal one that has not chosen. A renderer reads
|
|
489
|
-
* `user.accountCategories ?? []`.
|
|
490
|
-
*/
|
|
491
|
-
accountCategories: z.ZodOptional<z.ZodEffects<z.ZodArray<z.ZodEnum<["news", "politics", "business", "startup", "finance", "crypto", "marketplace", "retail", "real_estate", "agency", "landlord", "cooperative", "architecture", "technology", "software", "ai", "security", "automation", "science", "education", "books", "health", "fitness", "sports", "gaming", "music", "film", "podcast", "art", "photography", "comedy", "food", "travel", "fashion", "home_garden", "diy", "automotive", "animals", "family", "nonprofit", "government", "community", "activism", "environment", "religion", "other"]>, "many">, ("community" | "news" | "politics" | "business" | "startup" | "finance" | "crypto" | "marketplace" | "retail" | "real_estate" | "agency" | "landlord" | "cooperative" | "architecture" | "technology" | "software" | "ai" | "security" | "automation" | "science" | "education" | "books" | "health" | "fitness" | "sports" | "gaming" | "music" | "film" | "podcast" | "art" | "photography" | "comedy" | "food" | "travel" | "fashion" | "home_garden" | "diy" | "automotive" | "animals" | "family" | "nonprofit" | "government" | "activism" | "environment" | "religion" | "other")[], ("community" | "news" | "politics" | "business" | "startup" | "finance" | "crypto" | "marketplace" | "retail" | "real_estate" | "agency" | "landlord" | "cooperative" | "architecture" | "technology" | "software" | "ai" | "security" | "automation" | "science" | "education" | "books" | "health" | "fitness" | "sports" | "gaming" | "music" | "film" | "podcast" | "art" | "photography" | "comedy" | "food" | "travel" | "fashion" | "home_garden" | "diy" | "automotive" | "animals" | "family" | "nonprofit" | "government" | "activism" | "environment" | "religion" | "other")[]>>;
|
|
492
|
-
/**
|
|
493
|
-
* The 3D avatar character of a `kind: 'bot'` account — what Bloom's
|
|
494
|
-
* `Avatar` draws instead of a picture. Present ONLY on a bot's payload,
|
|
495
|
-
* never on a person's or an organization's, so those DTOs do not grow.
|
|
496
|
-
*/
|
|
497
|
-
character: z.ZodOptional<z.ZodType<import("./avatarCharacter").AvatarCharacter, z.ZodTypeDef, unknown>>;
|
|
498
|
-
/**
|
|
499
|
-
* The authenticated viewer's relationship to this profile. Present ONLY
|
|
500
|
-
* on single-profile fetches (`GET /profiles/username/:username`,
|
|
501
|
-
* `GET /users/:userId`) when the request is authenticated; OMITTED for
|
|
502
|
-
* anonymous requests and for the bulk `POST /users/by-ids` fan-out.
|
|
503
|
-
*/
|
|
504
|
-
relationship: z.ZodOptional<z.ZodType<UserRelationship, z.ZodTypeDef, UserRelationship>>;
|
|
505
|
-
/**
|
|
506
|
-
* Portable theme preference. Rides the self/session payload (cold boot),
|
|
507
|
-
* so it is present on the current-user DTO (`GET /users/me`,
|
|
508
|
-
* `GET /session/user/:sessionId`) and absent until the user sets it.
|
|
509
|
-
*/
|
|
158
|
+
accountCategories: z.ZodOptional<z.ZodArray<z.ZodEnum<{
|
|
159
|
+
community: "community";
|
|
160
|
+
news: "news";
|
|
161
|
+
politics: "politics";
|
|
162
|
+
business: "business";
|
|
163
|
+
startup: "startup";
|
|
164
|
+
finance: "finance";
|
|
165
|
+
crypto: "crypto";
|
|
166
|
+
marketplace: "marketplace";
|
|
167
|
+
retail: "retail";
|
|
168
|
+
real_estate: "real_estate";
|
|
169
|
+
agency: "agency";
|
|
170
|
+
landlord: "landlord";
|
|
171
|
+
cooperative: "cooperative";
|
|
172
|
+
architecture: "architecture";
|
|
173
|
+
technology: "technology";
|
|
174
|
+
software: "software";
|
|
175
|
+
ai: "ai";
|
|
176
|
+
security: "security";
|
|
177
|
+
automation: "automation";
|
|
178
|
+
science: "science";
|
|
179
|
+
education: "education";
|
|
180
|
+
books: "books";
|
|
181
|
+
health: "health";
|
|
182
|
+
fitness: "fitness";
|
|
183
|
+
sports: "sports";
|
|
184
|
+
gaming: "gaming";
|
|
185
|
+
music: "music";
|
|
186
|
+
film: "film";
|
|
187
|
+
podcast: "podcast";
|
|
188
|
+
art: "art";
|
|
189
|
+
photography: "photography";
|
|
190
|
+
comedy: "comedy";
|
|
191
|
+
food: "food";
|
|
192
|
+
travel: "travel";
|
|
193
|
+
fashion: "fashion";
|
|
194
|
+
home_garden: "home_garden";
|
|
195
|
+
diy: "diy";
|
|
196
|
+
automotive: "automotive";
|
|
197
|
+
animals: "animals";
|
|
198
|
+
family: "family";
|
|
199
|
+
nonprofit: "nonprofit";
|
|
200
|
+
government: "government";
|
|
201
|
+
activism: "activism";
|
|
202
|
+
environment: "environment";
|
|
203
|
+
religion: "religion";
|
|
204
|
+
other: "other";
|
|
205
|
+
}>>>;
|
|
206
|
+
character: z.ZodOptional<z.ZodType<import("./avatarCharacter").AvatarCharacter, unknown, z.core.$ZodTypeInternals<import("./avatarCharacter").AvatarCharacter, unknown>>>;
|
|
207
|
+
relationship: z.ZodOptional<z.ZodType<UserRelationship, unknown, z.core.$ZodTypeInternals<UserRelationship, unknown>>>;
|
|
510
208
|
userPreferences: z.ZodOptional<z.ZodObject<{
|
|
511
|
-
displayCurrency: z.ZodOptional<z.ZodEnum<
|
|
512
|
-
|
|
513
|
-
|
|
514
|
-
|
|
515
|
-
|
|
516
|
-
}, z.ZodUnknown
|
|
517
|
-
themePreference: z.ZodOptional<z.ZodType<ThemePreference, z.
|
|
209
|
+
displayCurrency: z.ZodOptional<z.ZodEnum<{
|
|
210
|
+
USD: "USD";
|
|
211
|
+
EUR: "EUR";
|
|
212
|
+
FAIR: "FAIR";
|
|
213
|
+
}>>;
|
|
214
|
+
}, z.core.$catchall<z.ZodUnknown>>>;
|
|
215
|
+
themePreference: z.ZodOptional<z.ZodType<ThemePreference, unknown, z.core.$ZodTypeInternals<ThemePreference, unknown>>>;
|
|
518
216
|
personalization: z.ZodOptional<z.ZodObject<{
|
|
519
217
|
mentionMono: z.ZodObject<{
|
|
520
218
|
allowed: z.ZodBoolean;
|
|
521
219
|
expiresAt: z.ZodNullable<z.ZodString>;
|
|
522
|
-
},
|
|
523
|
-
|
|
524
|
-
|
|
525
|
-
}, {
|
|
526
|
-
expiresAt: string | null;
|
|
527
|
-
allowed: boolean;
|
|
528
|
-
}>;
|
|
529
|
-
}, "strict", z.ZodTypeAny, {
|
|
530
|
-
mentionMono: {
|
|
531
|
-
expiresAt: string | null;
|
|
532
|
-
allowed: boolean;
|
|
533
|
-
};
|
|
534
|
-
}, {
|
|
535
|
-
mentionMono: {
|
|
536
|
-
expiresAt: string | null;
|
|
537
|
-
allowed: boolean;
|
|
538
|
-
};
|
|
539
|
-
}>>;
|
|
540
|
-
}, z.ZodTypeAny, "passthrough">>;
|
|
220
|
+
}, z.core.$strict>;
|
|
221
|
+
}, z.core.$strict>>;
|
|
222
|
+
}, z.core.$loose>;
|
|
541
223
|
export type UserResponse = z.infer<typeof userResponseSchema>;
|
|
542
224
|
export declare const userProfileUpdateSchema: z.ZodObject<{
|
|
543
225
|
name: z.ZodOptional<z.ZodObject<{
|
|
544
226
|
first: z.ZodOptional<z.ZodString>;
|
|
545
227
|
last: z.ZodOptional<z.ZodString>;
|
|
546
|
-
/**
|
|
547
|
-
* Explicit display name, stored rather than composed. Wins over
|
|
548
|
-
* `first`/`last` when set; send `''` to clear it and fall back
|
|
549
|
-
* to the composed pair.
|
|
550
|
-
*/
|
|
551
|
-
displayName: z.ZodOptional<z.ZodString>;
|
|
552
|
-
}, "strip", z.ZodTypeAny, {
|
|
553
|
-
first?: string | undefined;
|
|
554
|
-
last?: string | undefined;
|
|
555
|
-
displayName?: string | undefined;
|
|
556
|
-
}, {
|
|
557
|
-
first?: string | undefined;
|
|
558
|
-
last?: string | undefined;
|
|
559
|
-
displayName?: string | undefined;
|
|
560
|
-
}>>;
|
|
561
|
-
username: z.ZodOptional<z.ZodString>;
|
|
562
|
-
email: z.ZodOptional<z.ZodString>;
|
|
563
|
-
avatar: z.ZodOptional<z.ZodString>;
|
|
564
|
-
color: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
565
|
-
bio: z.ZodOptional<z.ZodString>;
|
|
566
|
-
description: z.ZodOptional<z.ZodString>;
|
|
567
|
-
phone: z.ZodOptional<z.ZodString>;
|
|
568
|
-
address: z.ZodOptional<z.ZodString>;
|
|
569
|
-
birthday: z.ZodOptional<z.ZodString>;
|
|
570
|
-
/**
|
|
571
|
-
* Structured date of birth. `null` (or `''`, at the service layer)
|
|
572
|
-
* clears it. Independently settable from `birthday` — see
|
|
573
|
-
* `user.service.ts`'s `updateUserProfile` for why the two legacy and
|
|
574
|
-
* structured fields are not kept in sync with each other.
|
|
575
|
-
*/
|
|
576
|
-
dateOfBirth: z.ZodOptional<z.ZodNullable<z.ZodEffects<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>, string, string>>>;
|
|
577
|
-
locations: z.ZodOptional<z.ZodArray<z.ZodUnknown, "many">>;
|
|
578
|
-
links: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
579
|
-
linksMetadata: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
580
|
-
url: z.ZodString;
|
|
581
|
-
title: z.ZodOptional<z.ZodString>;
|
|
582
|
-
description: z.ZodOptional<z.ZodString>;
|
|
583
|
-
image: z.ZodOptional<z.ZodString>;
|
|
584
|
-
id: z.ZodOptional<z.ZodString>;
|
|
585
|
-
}, "strip", z.ZodTypeAny, {
|
|
586
|
-
url: string;
|
|
587
|
-
title?: string | undefined;
|
|
588
|
-
id?: string | undefined;
|
|
589
|
-
description?: string | undefined;
|
|
590
|
-
image?: string | undefined;
|
|
591
|
-
}, {
|
|
592
|
-
url: string;
|
|
593
|
-
title?: string | undefined;
|
|
594
|
-
id?: string | undefined;
|
|
595
|
-
description?: string | undefined;
|
|
596
|
-
image?: string | undefined;
|
|
597
|
-
}>, "many">>;
|
|
598
|
-
/**
|
|
599
|
-
* Ordered account locales (`language-REGION`), primary first. Replaces
|
|
600
|
-
* the eliminated singular `language`; `languages[0]` is the primary UI
|
|
601
|
-
* locale.
|
|
602
|
-
*/
|
|
603
|
-
languages: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
604
|
-
accountExpiresAfterInactivityDays: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
605
|
-
notificationPreferences: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
606
|
-
userPreferences: z.ZodOptional<z.ZodObject<{
|
|
607
|
-
displayCurrency: z.ZodOptional<z.ZodEnum<["USD", "EUR", "FAIR"]>>;
|
|
608
|
-
}, "strip", z.ZodUnknown, z.objectOutputType<{
|
|
609
|
-
displayCurrency: z.ZodOptional<z.ZodEnum<["USD", "EUR", "FAIR"]>>;
|
|
610
|
-
}, z.ZodUnknown, "strip">, z.objectInputType<{
|
|
611
|
-
displayCurrency: z.ZodOptional<z.ZodEnum<["USD", "EUR", "FAIR"]>>;
|
|
612
|
-
}, z.ZodUnknown, "strip">>>;
|
|
613
|
-
privacySettings: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
614
|
-
/**
|
|
615
|
-
* Portable theme preference. Written through the same `PUT /users/me`
|
|
616
|
-
* settings-update path as `languages`/`userPreferences`.
|
|
617
|
-
*/
|
|
618
|
-
themePreference: z.ZodOptional<z.ZodType<ThemePreference, z.ZodTypeDef, ThemePreference>>;
|
|
619
|
-
}, "passthrough", z.ZodTypeAny, z.objectOutputType<{
|
|
620
|
-
name: z.ZodOptional<z.ZodObject<{
|
|
621
|
-
first: z.ZodOptional<z.ZodString>;
|
|
622
|
-
last: z.ZodOptional<z.ZodString>;
|
|
623
|
-
/**
|
|
624
|
-
* Explicit display name, stored rather than composed. Wins over
|
|
625
|
-
* `first`/`last` when set; send `''` to clear it and fall back
|
|
626
|
-
* to the composed pair.
|
|
627
|
-
*/
|
|
628
|
-
displayName: z.ZodOptional<z.ZodString>;
|
|
629
|
-
}, "strip", z.ZodTypeAny, {
|
|
630
|
-
first?: string | undefined;
|
|
631
|
-
last?: string | undefined;
|
|
632
|
-
displayName?: string | undefined;
|
|
633
|
-
}, {
|
|
634
|
-
first?: string | undefined;
|
|
635
|
-
last?: string | undefined;
|
|
636
|
-
displayName?: string | undefined;
|
|
637
|
-
}>>;
|
|
638
|
-
username: z.ZodOptional<z.ZodString>;
|
|
639
|
-
email: z.ZodOptional<z.ZodString>;
|
|
640
|
-
avatar: z.ZodOptional<z.ZodString>;
|
|
641
|
-
color: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
642
|
-
bio: z.ZodOptional<z.ZodString>;
|
|
643
|
-
description: z.ZodOptional<z.ZodString>;
|
|
644
|
-
phone: z.ZodOptional<z.ZodString>;
|
|
645
|
-
address: z.ZodOptional<z.ZodString>;
|
|
646
|
-
birthday: z.ZodOptional<z.ZodString>;
|
|
647
|
-
/**
|
|
648
|
-
* Structured date of birth. `null` (or `''`, at the service layer)
|
|
649
|
-
* clears it. Independently settable from `birthday` — see
|
|
650
|
-
* `user.service.ts`'s `updateUserProfile` for why the two legacy and
|
|
651
|
-
* structured fields are not kept in sync with each other.
|
|
652
|
-
*/
|
|
653
|
-
dateOfBirth: z.ZodOptional<z.ZodNullable<z.ZodEffects<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>, string, string>>>;
|
|
654
|
-
locations: z.ZodOptional<z.ZodArray<z.ZodUnknown, "many">>;
|
|
655
|
-
links: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
656
|
-
linksMetadata: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
657
|
-
url: z.ZodString;
|
|
658
|
-
title: z.ZodOptional<z.ZodString>;
|
|
659
|
-
description: z.ZodOptional<z.ZodString>;
|
|
660
|
-
image: z.ZodOptional<z.ZodString>;
|
|
661
|
-
id: z.ZodOptional<z.ZodString>;
|
|
662
|
-
}, "strip", z.ZodTypeAny, {
|
|
663
|
-
url: string;
|
|
664
|
-
title?: string | undefined;
|
|
665
|
-
id?: string | undefined;
|
|
666
|
-
description?: string | undefined;
|
|
667
|
-
image?: string | undefined;
|
|
668
|
-
}, {
|
|
669
|
-
url: string;
|
|
670
|
-
title?: string | undefined;
|
|
671
|
-
id?: string | undefined;
|
|
672
|
-
description?: string | undefined;
|
|
673
|
-
image?: string | undefined;
|
|
674
|
-
}>, "many">>;
|
|
675
|
-
/**
|
|
676
|
-
* Ordered account locales (`language-REGION`), primary first. Replaces
|
|
677
|
-
* the eliminated singular `language`; `languages[0]` is the primary UI
|
|
678
|
-
* locale.
|
|
679
|
-
*/
|
|
680
|
-
languages: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
681
|
-
accountExpiresAfterInactivityDays: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
682
|
-
notificationPreferences: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
683
|
-
userPreferences: z.ZodOptional<z.ZodObject<{
|
|
684
|
-
displayCurrency: z.ZodOptional<z.ZodEnum<["USD", "EUR", "FAIR"]>>;
|
|
685
|
-
}, "strip", z.ZodUnknown, z.objectOutputType<{
|
|
686
|
-
displayCurrency: z.ZodOptional<z.ZodEnum<["USD", "EUR", "FAIR"]>>;
|
|
687
|
-
}, z.ZodUnknown, "strip">, z.objectInputType<{
|
|
688
|
-
displayCurrency: z.ZodOptional<z.ZodEnum<["USD", "EUR", "FAIR"]>>;
|
|
689
|
-
}, z.ZodUnknown, "strip">>>;
|
|
690
|
-
privacySettings: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
691
|
-
/**
|
|
692
|
-
* Portable theme preference. Written through the same `PUT /users/me`
|
|
693
|
-
* settings-update path as `languages`/`userPreferences`.
|
|
694
|
-
*/
|
|
695
|
-
themePreference: z.ZodOptional<z.ZodType<ThemePreference, z.ZodTypeDef, ThemePreference>>;
|
|
696
|
-
}, z.ZodTypeAny, "passthrough">, z.objectInputType<{
|
|
697
|
-
name: z.ZodOptional<z.ZodObject<{
|
|
698
|
-
first: z.ZodOptional<z.ZodString>;
|
|
699
|
-
last: z.ZodOptional<z.ZodString>;
|
|
700
|
-
/**
|
|
701
|
-
* Explicit display name, stored rather than composed. Wins over
|
|
702
|
-
* `first`/`last` when set; send `''` to clear it and fall back
|
|
703
|
-
* to the composed pair.
|
|
704
|
-
*/
|
|
705
228
|
displayName: z.ZodOptional<z.ZodString>;
|
|
706
|
-
},
|
|
707
|
-
first?: string | undefined;
|
|
708
|
-
last?: string | undefined;
|
|
709
|
-
displayName?: string | undefined;
|
|
710
|
-
}, {
|
|
711
|
-
first?: string | undefined;
|
|
712
|
-
last?: string | undefined;
|
|
713
|
-
displayName?: string | undefined;
|
|
714
|
-
}>>;
|
|
229
|
+
}, z.core.$strip>>;
|
|
715
230
|
username: z.ZodOptional<z.ZodString>;
|
|
716
231
|
email: z.ZodOptional<z.ZodString>;
|
|
717
232
|
avatar: z.ZodOptional<z.ZodString>;
|
|
@@ -721,56 +236,29 @@ export declare const userProfileUpdateSchema: z.ZodObject<{
|
|
|
721
236
|
phone: z.ZodOptional<z.ZodString>;
|
|
722
237
|
address: z.ZodOptional<z.ZodString>;
|
|
723
238
|
birthday: z.ZodOptional<z.ZodString>;
|
|
724
|
-
|
|
725
|
-
|
|
726
|
-
|
|
727
|
-
* `user.service.ts`'s `updateUserProfile` for why the two legacy and
|
|
728
|
-
* structured fields are not kept in sync with each other.
|
|
729
|
-
*/
|
|
730
|
-
dateOfBirth: z.ZodOptional<z.ZodNullable<z.ZodEffects<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>, string, string>>>;
|
|
731
|
-
locations: z.ZodOptional<z.ZodArray<z.ZodUnknown, "many">>;
|
|
732
|
-
links: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
239
|
+
dateOfBirth: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
240
|
+
locations: z.ZodOptional<z.ZodArray<z.ZodUnknown>>;
|
|
241
|
+
links: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
733
242
|
linksMetadata: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
734
243
|
url: z.ZodString;
|
|
735
244
|
title: z.ZodOptional<z.ZodString>;
|
|
736
245
|
description: z.ZodOptional<z.ZodString>;
|
|
737
246
|
image: z.ZodOptional<z.ZodString>;
|
|
738
247
|
id: z.ZodOptional<z.ZodString>;
|
|
739
|
-
},
|
|
740
|
-
|
|
741
|
-
title?: string | undefined;
|
|
742
|
-
id?: string | undefined;
|
|
743
|
-
description?: string | undefined;
|
|
744
|
-
image?: string | undefined;
|
|
745
|
-
}, {
|
|
746
|
-
url: string;
|
|
747
|
-
title?: string | undefined;
|
|
748
|
-
id?: string | undefined;
|
|
749
|
-
description?: string | undefined;
|
|
750
|
-
image?: string | undefined;
|
|
751
|
-
}>, "many">>;
|
|
752
|
-
/**
|
|
753
|
-
* Ordered account locales (`language-REGION`), primary first. Replaces
|
|
754
|
-
* the eliminated singular `language`; `languages[0]` is the primary UI
|
|
755
|
-
* locale.
|
|
756
|
-
*/
|
|
757
|
-
languages: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
248
|
+
}, z.core.$strip>>>;
|
|
249
|
+
languages: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
758
250
|
accountExpiresAfterInactivityDays: z.ZodOptional<z.ZodNullable<z.ZodNumber>>;
|
|
759
251
|
notificationPreferences: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
760
252
|
userPreferences: z.ZodOptional<z.ZodObject<{
|
|
761
|
-
displayCurrency: z.ZodOptional<z.ZodEnum<
|
|
762
|
-
|
|
763
|
-
|
|
764
|
-
|
|
765
|
-
|
|
766
|
-
}, z.ZodUnknown
|
|
253
|
+
displayCurrency: z.ZodOptional<z.ZodEnum<{
|
|
254
|
+
USD: "USD";
|
|
255
|
+
EUR: "EUR";
|
|
256
|
+
FAIR: "FAIR";
|
|
257
|
+
}>>;
|
|
258
|
+
}, z.core.$catchall<z.ZodUnknown>>>;
|
|
767
259
|
privacySettings: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
768
|
-
|
|
769
|
-
|
|
770
|
-
* settings-update path as `languages`/`userPreferences`.
|
|
771
|
-
*/
|
|
772
|
-
themePreference: z.ZodOptional<z.ZodType<ThemePreference, z.ZodTypeDef, ThemePreference>>;
|
|
773
|
-
}, z.ZodTypeAny, "passthrough">>;
|
|
260
|
+
themePreference: z.ZodOptional<z.ZodType<ThemePreference, unknown, z.core.$ZodTypeInternals<ThemePreference, unknown>>>;
|
|
261
|
+
}, z.core.$loose>;
|
|
774
262
|
export type UserProfileUpdate = z.infer<typeof userProfileUpdateSchema>;
|
|
775
263
|
/**
|
|
776
264
|
* Resolve the canonical user id from a {@link UserResponse}, accepting either
|
|
@@ -785,145 +273,7 @@ export declare function resolveUserId(user: UserResponse): string | undefined;
|
|
|
785
273
|
*/
|
|
786
274
|
export declare const currentUserResponseSchema: z.ZodObject<{
|
|
787
275
|
data: z.ZodObject<{
|
|
788
|
-
/** The user id as a string. Present on `formatUserResponse` output. */
|
|
789
|
-
id: z.ZodOptional<z.ZodString>;
|
|
790
|
-
/** Raw-document id (e.g. `GET /users/me`). Present when `id` is not. */
|
|
791
|
-
_id: z.ZodOptional<z.ZodString>;
|
|
792
|
-
publicKey: z.ZodOptional<z.ZodString>;
|
|
793
|
-
username: z.ZodOptional<z.ZodString>;
|
|
794
|
-
email: z.ZodOptional<z.ZodString>;
|
|
795
|
-
phone: z.ZodOptional<z.ZodString>;
|
|
796
|
-
address: z.ZodOptional<z.ZodString>;
|
|
797
|
-
birthday: z.ZodOptional<z.ZodString>;
|
|
798
|
-
/**
|
|
799
|
-
* Structured date of birth, `YYYY-MM-DD`. Present only on the
|
|
800
|
-
* account's OWN profile response (`GET /users/me`, `PUT /users/me`
|
|
801
|
-
* with `includePrivateFields`) — never on another account's profile,
|
|
802
|
-
* the same visibility `phone`/`address`/`birthday` already have. See
|
|
803
|
-
* {@link dateOfBirthSchema}.
|
|
804
|
-
*/
|
|
805
|
-
dateOfBirth: z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>, string, string>>;
|
|
806
|
-
/**
|
|
807
|
-
* Derived, non-PII signal: whether the account holder is at least 18
|
|
808
|
-
* (see `computeIsAdult` in `user.service.ts` for the exact threshold
|
|
809
|
-
* and the UTC-"today" choice). Computed fresh on every read — age
|
|
810
|
-
* changes daily, so this is never stored. `undefined` when
|
|
811
|
-
* `dateOfBirth` is unset ("unknown"), distinct from `false` ("known,
|
|
812
|
-
* not yet 18"). Rides the same owner-only visibility as
|
|
813
|
-
* `dateOfBirth`; a future pass may widen this specific field to
|
|
814
|
-
* other viewers without exposing the birthdate itself, but that is
|
|
815
|
-
* not decided here.
|
|
816
|
-
*/
|
|
817
|
-
isAdult: z.ZodOptional<z.ZodBoolean>;
|
|
818
|
-
/** Avatar file id (string) or null. */
|
|
819
|
-
avatar: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
820
|
-
/** Named Bloom color preset (e.g. `"blue"`) or null. */
|
|
821
|
-
color: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
822
|
-
name: z.ZodType<UserNameResponse, z.ZodTypeDef, UserNameResponse>;
|
|
823
|
-
verified: z.ZodOptional<z.ZodBoolean>;
|
|
824
|
-
/**
|
|
825
|
-
* The account's languages as full BCP-47 locales (`language-REGION`,
|
|
826
|
-
* e.g. `es-ES`, `en-US`, `pt-BR`), ordered with the PRIMARY (UI) locale
|
|
827
|
-
* first. `languages[0]` is the primary locale — there is no singular
|
|
828
|
-
* `language` field.
|
|
829
|
-
*/
|
|
830
|
-
languages: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
831
|
-
/**
|
|
832
|
-
* The account's self-sovereign identifier
|
|
833
|
-
* (`did:web:<FEDERATION_DOMAIN>:u:<userId>`). Surfaced as a `User`
|
|
834
|
-
* virtual; present on formatted DTOs once the identity layer is live.
|
|
835
|
-
*/
|
|
836
|
-
did: z.ZodOptional<z.ZodString>;
|
|
837
|
-
/**
|
|
838
|
-
* Proven domain-ownership badges. Each is a {@link verifiedDomainSchema}
|
|
839
|
-
* entry; present only when the account has verified at least one domain.
|
|
840
|
-
*/
|
|
841
|
-
verifiedDomains: z.ZodOptional<z.ZodArray<z.ZodType<import("./identity").VerifiedDomain, z.ZodTypeDef, import("./identity").VerifiedDomain>, "many">>;
|
|
842
|
-
/**
|
|
843
|
-
* Account-graph classification — what KIND of account this is.
|
|
844
|
-
*
|
|
845
|
-
* ORTHOGONAL to `type` (`local` / `federated` / `agent` / `automated`),
|
|
846
|
-
* which says where the account lives and how it is driven; the two
|
|
847
|
-
* coexist and neither substitutes for the other. A `channel` is a
|
|
848
|
-
* publishing identity nobody can act as, so a consumer that renders
|
|
849
|
-
* authored content reads THIS to tell a channel's post from a person's.
|
|
850
|
-
*
|
|
851
|
-
* Optional because a DTO produced from a source that never carried the
|
|
852
|
-
* column omits it; absent should be read as `personal`, the column's
|
|
853
|
-
* default, not as unknown.
|
|
854
|
-
*/
|
|
855
|
-
kind: z.ZodOptional<z.ZodEnum<["personal", "organization", "project", "bot", "channel", "community"]>>;
|
|
856
|
-
/**
|
|
857
|
-
* What this account is about — the field a profile screen RENDERS.
|
|
858
|
-
*
|
|
859
|
-
* **Ordered, primary first.** `accountCategories[0]` is the primary
|
|
860
|
-
* category; there is deliberately no sibling `primaryCategory` field,
|
|
861
|
-
* because two representations of one fact can disagree (see rule 2 in
|
|
862
|
-
* `accountGraph.ts`). Nothing downstream may sort, de-duplicate or
|
|
863
|
-
* otherwise reorder this array.
|
|
864
|
-
*
|
|
865
|
-
* **Ids, never labels.** Each element is a stable slug; the visible text
|
|
866
|
-
* comes from the reader's own translation catalogue, keyed
|
|
867
|
-
* `accounts.accountCategory.<id>`. A label on the wire would paint every
|
|
868
|
-
* profile in the language of whoever picked it.
|
|
869
|
-
*
|
|
870
|
-
* Absent when the account has none — which is every `personal` account,
|
|
871
|
-
* and any non-personal one that has not chosen. A renderer reads
|
|
872
|
-
* `user.accountCategories ?? []`.
|
|
873
|
-
*/
|
|
874
|
-
accountCategories: z.ZodOptional<z.ZodEffects<z.ZodArray<z.ZodEnum<["news", "politics", "business", "startup", "finance", "crypto", "marketplace", "retail", "real_estate", "agency", "landlord", "cooperative", "architecture", "technology", "software", "ai", "security", "automation", "science", "education", "books", "health", "fitness", "sports", "gaming", "music", "film", "podcast", "art", "photography", "comedy", "food", "travel", "fashion", "home_garden", "diy", "automotive", "animals", "family", "nonprofit", "government", "community", "activism", "environment", "religion", "other"]>, "many">, ("community" | "news" | "politics" | "business" | "startup" | "finance" | "crypto" | "marketplace" | "retail" | "real_estate" | "agency" | "landlord" | "cooperative" | "architecture" | "technology" | "software" | "ai" | "security" | "automation" | "science" | "education" | "books" | "health" | "fitness" | "sports" | "gaming" | "music" | "film" | "podcast" | "art" | "photography" | "comedy" | "food" | "travel" | "fashion" | "home_garden" | "diy" | "automotive" | "animals" | "family" | "nonprofit" | "government" | "activism" | "environment" | "religion" | "other")[], ("community" | "news" | "politics" | "business" | "startup" | "finance" | "crypto" | "marketplace" | "retail" | "real_estate" | "agency" | "landlord" | "cooperative" | "architecture" | "technology" | "software" | "ai" | "security" | "automation" | "science" | "education" | "books" | "health" | "fitness" | "sports" | "gaming" | "music" | "film" | "podcast" | "art" | "photography" | "comedy" | "food" | "travel" | "fashion" | "home_garden" | "diy" | "automotive" | "animals" | "family" | "nonprofit" | "government" | "activism" | "environment" | "religion" | "other")[]>>;
|
|
875
|
-
/**
|
|
876
|
-
* The 3D avatar character of a `kind: 'bot'` account — what Bloom's
|
|
877
|
-
* `Avatar` draws instead of a picture. Present ONLY on a bot's payload,
|
|
878
|
-
* never on a person's or an organization's, so those DTOs do not grow.
|
|
879
|
-
*/
|
|
880
|
-
character: z.ZodOptional<z.ZodType<import("./avatarCharacter").AvatarCharacter, z.ZodTypeDef, unknown>>;
|
|
881
|
-
/**
|
|
882
|
-
* The authenticated viewer's relationship to this profile. Present ONLY
|
|
883
|
-
* on single-profile fetches (`GET /profiles/username/:username`,
|
|
884
|
-
* `GET /users/:userId`) when the request is authenticated; OMITTED for
|
|
885
|
-
* anonymous requests and for the bulk `POST /users/by-ids` fan-out.
|
|
886
|
-
*/
|
|
887
|
-
relationship: z.ZodOptional<z.ZodType<UserRelationship, z.ZodTypeDef, UserRelationship>>;
|
|
888
|
-
/**
|
|
889
|
-
* Portable theme preference. Rides the self/session payload (cold boot),
|
|
890
|
-
* so it is present on the current-user DTO (`GET /users/me`,
|
|
891
|
-
* `GET /session/user/:sessionId`) and absent until the user sets it.
|
|
892
|
-
*/
|
|
893
|
-
userPreferences: z.ZodOptional<z.ZodObject<{
|
|
894
|
-
displayCurrency: z.ZodOptional<z.ZodEnum<["USD", "EUR", "FAIR"]>>;
|
|
895
|
-
}, "strip", z.ZodUnknown, z.objectOutputType<{
|
|
896
|
-
displayCurrency: z.ZodOptional<z.ZodEnum<["USD", "EUR", "FAIR"]>>;
|
|
897
|
-
}, z.ZodUnknown, "strip">, z.objectInputType<{
|
|
898
|
-
displayCurrency: z.ZodOptional<z.ZodEnum<["USD", "EUR", "FAIR"]>>;
|
|
899
|
-
}, z.ZodUnknown, "strip">>>;
|
|
900
|
-
themePreference: z.ZodOptional<z.ZodType<ThemePreference, z.ZodTypeDef, ThemePreference>>;
|
|
901
|
-
personalization: z.ZodOptional<z.ZodObject<{
|
|
902
|
-
mentionMono: z.ZodObject<{
|
|
903
|
-
allowed: z.ZodBoolean;
|
|
904
|
-
expiresAt: z.ZodNullable<z.ZodString>;
|
|
905
|
-
}, "strict", z.ZodTypeAny, {
|
|
906
|
-
expiresAt: string | null;
|
|
907
|
-
allowed: boolean;
|
|
908
|
-
}, {
|
|
909
|
-
expiresAt: string | null;
|
|
910
|
-
allowed: boolean;
|
|
911
|
-
}>;
|
|
912
|
-
}, "strict", z.ZodTypeAny, {
|
|
913
|
-
mentionMono: {
|
|
914
|
-
expiresAt: string | null;
|
|
915
|
-
allowed: boolean;
|
|
916
|
-
};
|
|
917
|
-
}, {
|
|
918
|
-
mentionMono: {
|
|
919
|
-
expiresAt: string | null;
|
|
920
|
-
allowed: boolean;
|
|
921
|
-
};
|
|
922
|
-
}>>;
|
|
923
|
-
}, "passthrough", z.ZodTypeAny, z.objectOutputType<{
|
|
924
|
-
/** The user id as a string. Present on `formatUserResponse` output. */
|
|
925
276
|
id: z.ZodOptional<z.ZodString>;
|
|
926
|
-
/** Raw-document id (e.g. `GET /users/me`). Present when `id` is not. */
|
|
927
277
|
_id: z.ZodOptional<z.ZodString>;
|
|
928
278
|
publicKey: z.ZodOptional<z.ZodString>;
|
|
929
279
|
username: z.ZodOptional<z.ZodString>;
|
|
@@ -931,341 +281,89 @@ export declare const currentUserResponseSchema: z.ZodObject<{
|
|
|
931
281
|
phone: z.ZodOptional<z.ZodString>;
|
|
932
282
|
address: z.ZodOptional<z.ZodString>;
|
|
933
283
|
birthday: z.ZodOptional<z.ZodString>;
|
|
934
|
-
|
|
935
|
-
* Structured date of birth, `YYYY-MM-DD`. Present only on the
|
|
936
|
-
* account's OWN profile response (`GET /users/me`, `PUT /users/me`
|
|
937
|
-
* with `includePrivateFields`) — never on another account's profile,
|
|
938
|
-
* the same visibility `phone`/`address`/`birthday` already have. See
|
|
939
|
-
* {@link dateOfBirthSchema}.
|
|
940
|
-
*/
|
|
941
|
-
dateOfBirth: z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>, string, string>>;
|
|
942
|
-
/**
|
|
943
|
-
* Derived, non-PII signal: whether the account holder is at least 18
|
|
944
|
-
* (see `computeIsAdult` in `user.service.ts` for the exact threshold
|
|
945
|
-
* and the UTC-"today" choice). Computed fresh on every read — age
|
|
946
|
-
* changes daily, so this is never stored. `undefined` when
|
|
947
|
-
* `dateOfBirth` is unset ("unknown"), distinct from `false` ("known,
|
|
948
|
-
* not yet 18"). Rides the same owner-only visibility as
|
|
949
|
-
* `dateOfBirth`; a future pass may widen this specific field to
|
|
950
|
-
* other viewers without exposing the birthdate itself, but that is
|
|
951
|
-
* not decided here.
|
|
952
|
-
*/
|
|
284
|
+
dateOfBirth: z.ZodOptional<z.ZodString>;
|
|
953
285
|
isAdult: z.ZodOptional<z.ZodBoolean>;
|
|
954
|
-
/** Avatar file id (string) or null. */
|
|
955
286
|
avatar: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
956
|
-
/** Named Bloom color preset (e.g. `"blue"`) or null. */
|
|
957
287
|
color: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
958
|
-
name: z.ZodType<UserNameResponse, z.
|
|
288
|
+
name: z.ZodType<UserNameResponse, unknown, z.core.$ZodTypeInternals<UserNameResponse, unknown>>;
|
|
959
289
|
verified: z.ZodOptional<z.ZodBoolean>;
|
|
960
|
-
|
|
961
|
-
* The account's languages as full BCP-47 locales (`language-REGION`,
|
|
962
|
-
* e.g. `es-ES`, `en-US`, `pt-BR`), ordered with the PRIMARY (UI) locale
|
|
963
|
-
* first. `languages[0]` is the primary locale — there is no singular
|
|
964
|
-
* `language` field.
|
|
965
|
-
*/
|
|
966
|
-
languages: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
967
|
-
/**
|
|
968
|
-
* The account's self-sovereign identifier
|
|
969
|
-
* (`did:web:<FEDERATION_DOMAIN>:u:<userId>`). Surfaced as a `User`
|
|
970
|
-
* virtual; present on formatted DTOs once the identity layer is live.
|
|
971
|
-
*/
|
|
290
|
+
languages: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
972
291
|
did: z.ZodOptional<z.ZodString>;
|
|
973
|
-
|
|
974
|
-
|
|
975
|
-
|
|
976
|
-
|
|
977
|
-
|
|
978
|
-
|
|
979
|
-
|
|
980
|
-
|
|
981
|
-
* ORTHOGONAL to `type` (`local` / `federated` / `agent` / `automated`),
|
|
982
|
-
* which says where the account lives and how it is driven; the two
|
|
983
|
-
* coexist and neither substitutes for the other. A `channel` is a
|
|
984
|
-
* publishing identity nobody can act as, so a consumer that renders
|
|
985
|
-
* authored content reads THIS to tell a channel's post from a person's.
|
|
986
|
-
*
|
|
987
|
-
* Optional because a DTO produced from a source that never carried the
|
|
988
|
-
* column omits it; absent should be read as `personal`, the column's
|
|
989
|
-
* default, not as unknown.
|
|
990
|
-
*/
|
|
991
|
-
kind: z.ZodOptional<z.ZodEnum<["personal", "organization", "project", "bot", "channel", "community"]>>;
|
|
992
|
-
/**
|
|
993
|
-
* What this account is about — the field a profile screen RENDERS.
|
|
994
|
-
*
|
|
995
|
-
* **Ordered, primary first.** `accountCategories[0]` is the primary
|
|
996
|
-
* category; there is deliberately no sibling `primaryCategory` field,
|
|
997
|
-
* because two representations of one fact can disagree (see rule 2 in
|
|
998
|
-
* `accountGraph.ts`). Nothing downstream may sort, de-duplicate or
|
|
999
|
-
* otherwise reorder this array.
|
|
1000
|
-
*
|
|
1001
|
-
* **Ids, never labels.** Each element is a stable slug; the visible text
|
|
1002
|
-
* comes from the reader's own translation catalogue, keyed
|
|
1003
|
-
* `accounts.accountCategory.<id>`. A label on the wire would paint every
|
|
1004
|
-
* profile in the language of whoever picked it.
|
|
1005
|
-
*
|
|
1006
|
-
* Absent when the account has none — which is every `personal` account,
|
|
1007
|
-
* and any non-personal one that has not chosen. A renderer reads
|
|
1008
|
-
* `user.accountCategories ?? []`.
|
|
1009
|
-
*/
|
|
1010
|
-
accountCategories: z.ZodOptional<z.ZodEffects<z.ZodArray<z.ZodEnum<["news", "politics", "business", "startup", "finance", "crypto", "marketplace", "retail", "real_estate", "agency", "landlord", "cooperative", "architecture", "technology", "software", "ai", "security", "automation", "science", "education", "books", "health", "fitness", "sports", "gaming", "music", "film", "podcast", "art", "photography", "comedy", "food", "travel", "fashion", "home_garden", "diy", "automotive", "animals", "family", "nonprofit", "government", "community", "activism", "environment", "religion", "other"]>, "many">, ("community" | "news" | "politics" | "business" | "startup" | "finance" | "crypto" | "marketplace" | "retail" | "real_estate" | "agency" | "landlord" | "cooperative" | "architecture" | "technology" | "software" | "ai" | "security" | "automation" | "science" | "education" | "books" | "health" | "fitness" | "sports" | "gaming" | "music" | "film" | "podcast" | "art" | "photography" | "comedy" | "food" | "travel" | "fashion" | "home_garden" | "diy" | "automotive" | "animals" | "family" | "nonprofit" | "government" | "activism" | "environment" | "religion" | "other")[], ("community" | "news" | "politics" | "business" | "startup" | "finance" | "crypto" | "marketplace" | "retail" | "real_estate" | "agency" | "landlord" | "cooperative" | "architecture" | "technology" | "software" | "ai" | "security" | "automation" | "science" | "education" | "books" | "health" | "fitness" | "sports" | "gaming" | "music" | "film" | "podcast" | "art" | "photography" | "comedy" | "food" | "travel" | "fashion" | "home_garden" | "diy" | "automotive" | "animals" | "family" | "nonprofit" | "government" | "activism" | "environment" | "religion" | "other")[]>>;
|
|
1011
|
-
/**
|
|
1012
|
-
* The 3D avatar character of a `kind: 'bot'` account — what Bloom's
|
|
1013
|
-
* `Avatar` draws instead of a picture. Present ONLY on a bot's payload,
|
|
1014
|
-
* never on a person's or an organization's, so those DTOs do not grow.
|
|
1015
|
-
*/
|
|
1016
|
-
character: z.ZodOptional<z.ZodType<import("./avatarCharacter").AvatarCharacter, z.ZodTypeDef, unknown>>;
|
|
1017
|
-
/**
|
|
1018
|
-
* The authenticated viewer's relationship to this profile. Present ONLY
|
|
1019
|
-
* on single-profile fetches (`GET /profiles/username/:username`,
|
|
1020
|
-
* `GET /users/:userId`) when the request is authenticated; OMITTED for
|
|
1021
|
-
* anonymous requests and for the bulk `POST /users/by-ids` fan-out.
|
|
1022
|
-
*/
|
|
1023
|
-
relationship: z.ZodOptional<z.ZodType<UserRelationship, z.ZodTypeDef, UserRelationship>>;
|
|
1024
|
-
/**
|
|
1025
|
-
* Portable theme preference. Rides the self/session payload (cold boot),
|
|
1026
|
-
* so it is present on the current-user DTO (`GET /users/me`,
|
|
1027
|
-
* `GET /session/user/:sessionId`) and absent until the user sets it.
|
|
1028
|
-
*/
|
|
1029
|
-
userPreferences: z.ZodOptional<z.ZodObject<{
|
|
1030
|
-
displayCurrency: z.ZodOptional<z.ZodEnum<["USD", "EUR", "FAIR"]>>;
|
|
1031
|
-
}, "strip", z.ZodUnknown, z.objectOutputType<{
|
|
1032
|
-
displayCurrency: z.ZodOptional<z.ZodEnum<["USD", "EUR", "FAIR"]>>;
|
|
1033
|
-
}, z.ZodUnknown, "strip">, z.objectInputType<{
|
|
1034
|
-
displayCurrency: z.ZodOptional<z.ZodEnum<["USD", "EUR", "FAIR"]>>;
|
|
1035
|
-
}, z.ZodUnknown, "strip">>>;
|
|
1036
|
-
themePreference: z.ZodOptional<z.ZodType<ThemePreference, z.ZodTypeDef, ThemePreference>>;
|
|
1037
|
-
personalization: z.ZodOptional<z.ZodObject<{
|
|
1038
|
-
mentionMono: z.ZodObject<{
|
|
1039
|
-
allowed: z.ZodBoolean;
|
|
1040
|
-
expiresAt: z.ZodNullable<z.ZodString>;
|
|
1041
|
-
}, "strict", z.ZodTypeAny, {
|
|
1042
|
-
expiresAt: string | null;
|
|
1043
|
-
allowed: boolean;
|
|
1044
|
-
}, {
|
|
1045
|
-
expiresAt: string | null;
|
|
1046
|
-
allowed: boolean;
|
|
1047
|
-
}>;
|
|
1048
|
-
}, "strict", z.ZodTypeAny, {
|
|
1049
|
-
mentionMono: {
|
|
1050
|
-
expiresAt: string | null;
|
|
1051
|
-
allowed: boolean;
|
|
1052
|
-
};
|
|
1053
|
-
}, {
|
|
1054
|
-
mentionMono: {
|
|
1055
|
-
expiresAt: string | null;
|
|
1056
|
-
allowed: boolean;
|
|
1057
|
-
};
|
|
292
|
+
verifiedDomains: z.ZodOptional<z.ZodArray<z.ZodType<import("./identity").VerifiedDomain, unknown, z.core.$ZodTypeInternals<import("./identity").VerifiedDomain, unknown>>>>;
|
|
293
|
+
kind: z.ZodOptional<z.ZodEnum<{
|
|
294
|
+
personal: "personal";
|
|
295
|
+
organization: "organization";
|
|
296
|
+
project: "project";
|
|
297
|
+
bot: "bot";
|
|
298
|
+
channel: "channel";
|
|
299
|
+
community: "community";
|
|
1058
300
|
}>>;
|
|
1059
|
-
|
|
1060
|
-
|
|
1061
|
-
|
|
1062
|
-
|
|
1063
|
-
|
|
1064
|
-
|
|
1065
|
-
|
|
1066
|
-
|
|
1067
|
-
|
|
1068
|
-
|
|
1069
|
-
|
|
1070
|
-
|
|
1071
|
-
|
|
1072
|
-
|
|
1073
|
-
|
|
1074
|
-
|
|
1075
|
-
|
|
1076
|
-
|
|
1077
|
-
|
|
1078
|
-
|
|
1079
|
-
|
|
1080
|
-
|
|
1081
|
-
|
|
1082
|
-
|
|
1083
|
-
|
|
1084
|
-
|
|
1085
|
-
|
|
1086
|
-
|
|
1087
|
-
|
|
1088
|
-
|
|
1089
|
-
|
|
1090
|
-
|
|
1091
|
-
|
|
1092
|
-
|
|
1093
|
-
|
|
1094
|
-
|
|
1095
|
-
|
|
1096
|
-
|
|
1097
|
-
|
|
1098
|
-
|
|
1099
|
-
|
|
1100
|
-
|
|
1101
|
-
|
|
1102
|
-
|
|
1103
|
-
|
|
1104
|
-
|
|
1105
|
-
|
|
1106
|
-
|
|
1107
|
-
|
|
1108
|
-
|
|
1109
|
-
/**
|
|
1110
|
-
* Proven domain-ownership badges. Each is a {@link verifiedDomainSchema}
|
|
1111
|
-
* entry; present only when the account has verified at least one domain.
|
|
1112
|
-
*/
|
|
1113
|
-
verifiedDomains: z.ZodOptional<z.ZodArray<z.ZodType<import("./identity").VerifiedDomain, z.ZodTypeDef, import("./identity").VerifiedDomain>, "many">>;
|
|
1114
|
-
/**
|
|
1115
|
-
* Account-graph classification — what KIND of account this is.
|
|
1116
|
-
*
|
|
1117
|
-
* ORTHOGONAL to `type` (`local` / `federated` / `agent` / `automated`),
|
|
1118
|
-
* which says where the account lives and how it is driven; the two
|
|
1119
|
-
* coexist and neither substitutes for the other. A `channel` is a
|
|
1120
|
-
* publishing identity nobody can act as, so a consumer that renders
|
|
1121
|
-
* authored content reads THIS to tell a channel's post from a person's.
|
|
1122
|
-
*
|
|
1123
|
-
* Optional because a DTO produced from a source that never carried the
|
|
1124
|
-
* column omits it; absent should be read as `personal`, the column's
|
|
1125
|
-
* default, not as unknown.
|
|
1126
|
-
*/
|
|
1127
|
-
kind: z.ZodOptional<z.ZodEnum<["personal", "organization", "project", "bot", "channel", "community"]>>;
|
|
1128
|
-
/**
|
|
1129
|
-
* What this account is about — the field a profile screen RENDERS.
|
|
1130
|
-
*
|
|
1131
|
-
* **Ordered, primary first.** `accountCategories[0]` is the primary
|
|
1132
|
-
* category; there is deliberately no sibling `primaryCategory` field,
|
|
1133
|
-
* because two representations of one fact can disagree (see rule 2 in
|
|
1134
|
-
* `accountGraph.ts`). Nothing downstream may sort, de-duplicate or
|
|
1135
|
-
* otherwise reorder this array.
|
|
1136
|
-
*
|
|
1137
|
-
* **Ids, never labels.** Each element is a stable slug; the visible text
|
|
1138
|
-
* comes from the reader's own translation catalogue, keyed
|
|
1139
|
-
* `accounts.accountCategory.<id>`. A label on the wire would paint every
|
|
1140
|
-
* profile in the language of whoever picked it.
|
|
1141
|
-
*
|
|
1142
|
-
* Absent when the account has none — which is every `personal` account,
|
|
1143
|
-
* and any non-personal one that has not chosen. A renderer reads
|
|
1144
|
-
* `user.accountCategories ?? []`.
|
|
1145
|
-
*/
|
|
1146
|
-
accountCategories: z.ZodOptional<z.ZodEffects<z.ZodArray<z.ZodEnum<["news", "politics", "business", "startup", "finance", "crypto", "marketplace", "retail", "real_estate", "agency", "landlord", "cooperative", "architecture", "technology", "software", "ai", "security", "automation", "science", "education", "books", "health", "fitness", "sports", "gaming", "music", "film", "podcast", "art", "photography", "comedy", "food", "travel", "fashion", "home_garden", "diy", "automotive", "animals", "family", "nonprofit", "government", "community", "activism", "environment", "religion", "other"]>, "many">, ("community" | "news" | "politics" | "business" | "startup" | "finance" | "crypto" | "marketplace" | "retail" | "real_estate" | "agency" | "landlord" | "cooperative" | "architecture" | "technology" | "software" | "ai" | "security" | "automation" | "science" | "education" | "books" | "health" | "fitness" | "sports" | "gaming" | "music" | "film" | "podcast" | "art" | "photography" | "comedy" | "food" | "travel" | "fashion" | "home_garden" | "diy" | "automotive" | "animals" | "family" | "nonprofit" | "government" | "activism" | "environment" | "religion" | "other")[], ("community" | "news" | "politics" | "business" | "startup" | "finance" | "crypto" | "marketplace" | "retail" | "real_estate" | "agency" | "landlord" | "cooperative" | "architecture" | "technology" | "software" | "ai" | "security" | "automation" | "science" | "education" | "books" | "health" | "fitness" | "sports" | "gaming" | "music" | "film" | "podcast" | "art" | "photography" | "comedy" | "food" | "travel" | "fashion" | "home_garden" | "diy" | "automotive" | "animals" | "family" | "nonprofit" | "government" | "activism" | "environment" | "religion" | "other")[]>>;
|
|
1147
|
-
/**
|
|
1148
|
-
* The 3D avatar character of a `kind: 'bot'` account — what Bloom's
|
|
1149
|
-
* `Avatar` draws instead of a picture. Present ONLY on a bot's payload,
|
|
1150
|
-
* never on a person's or an organization's, so those DTOs do not grow.
|
|
1151
|
-
*/
|
|
1152
|
-
character: z.ZodOptional<z.ZodType<import("./avatarCharacter").AvatarCharacter, z.ZodTypeDef, unknown>>;
|
|
1153
|
-
/**
|
|
1154
|
-
* The authenticated viewer's relationship to this profile. Present ONLY
|
|
1155
|
-
* on single-profile fetches (`GET /profiles/username/:username`,
|
|
1156
|
-
* `GET /users/:userId`) when the request is authenticated; OMITTED for
|
|
1157
|
-
* anonymous requests and for the bulk `POST /users/by-ids` fan-out.
|
|
1158
|
-
*/
|
|
1159
|
-
relationship: z.ZodOptional<z.ZodType<UserRelationship, z.ZodTypeDef, UserRelationship>>;
|
|
1160
|
-
/**
|
|
1161
|
-
* Portable theme preference. Rides the self/session payload (cold boot),
|
|
1162
|
-
* so it is present on the current-user DTO (`GET /users/me`,
|
|
1163
|
-
* `GET /session/user/:sessionId`) and absent until the user sets it.
|
|
1164
|
-
*/
|
|
301
|
+
accountCategories: z.ZodOptional<z.ZodArray<z.ZodEnum<{
|
|
302
|
+
community: "community";
|
|
303
|
+
news: "news";
|
|
304
|
+
politics: "politics";
|
|
305
|
+
business: "business";
|
|
306
|
+
startup: "startup";
|
|
307
|
+
finance: "finance";
|
|
308
|
+
crypto: "crypto";
|
|
309
|
+
marketplace: "marketplace";
|
|
310
|
+
retail: "retail";
|
|
311
|
+
real_estate: "real_estate";
|
|
312
|
+
agency: "agency";
|
|
313
|
+
landlord: "landlord";
|
|
314
|
+
cooperative: "cooperative";
|
|
315
|
+
architecture: "architecture";
|
|
316
|
+
technology: "technology";
|
|
317
|
+
software: "software";
|
|
318
|
+
ai: "ai";
|
|
319
|
+
security: "security";
|
|
320
|
+
automation: "automation";
|
|
321
|
+
science: "science";
|
|
322
|
+
education: "education";
|
|
323
|
+
books: "books";
|
|
324
|
+
health: "health";
|
|
325
|
+
fitness: "fitness";
|
|
326
|
+
sports: "sports";
|
|
327
|
+
gaming: "gaming";
|
|
328
|
+
music: "music";
|
|
329
|
+
film: "film";
|
|
330
|
+
podcast: "podcast";
|
|
331
|
+
art: "art";
|
|
332
|
+
photography: "photography";
|
|
333
|
+
comedy: "comedy";
|
|
334
|
+
food: "food";
|
|
335
|
+
travel: "travel";
|
|
336
|
+
fashion: "fashion";
|
|
337
|
+
home_garden: "home_garden";
|
|
338
|
+
diy: "diy";
|
|
339
|
+
automotive: "automotive";
|
|
340
|
+
animals: "animals";
|
|
341
|
+
family: "family";
|
|
342
|
+
nonprofit: "nonprofit";
|
|
343
|
+
government: "government";
|
|
344
|
+
activism: "activism";
|
|
345
|
+
environment: "environment";
|
|
346
|
+
religion: "religion";
|
|
347
|
+
other: "other";
|
|
348
|
+
}>>>;
|
|
349
|
+
character: z.ZodOptional<z.ZodType<import("./avatarCharacter").AvatarCharacter, unknown, z.core.$ZodTypeInternals<import("./avatarCharacter").AvatarCharacter, unknown>>>;
|
|
350
|
+
relationship: z.ZodOptional<z.ZodType<UserRelationship, unknown, z.core.$ZodTypeInternals<UserRelationship, unknown>>>;
|
|
1165
351
|
userPreferences: z.ZodOptional<z.ZodObject<{
|
|
1166
|
-
displayCurrency: z.ZodOptional<z.ZodEnum<
|
|
1167
|
-
|
|
1168
|
-
|
|
1169
|
-
|
|
1170
|
-
|
|
1171
|
-
}, z.ZodUnknown
|
|
1172
|
-
themePreference: z.ZodOptional<z.ZodType<ThemePreference, z.
|
|
352
|
+
displayCurrency: z.ZodOptional<z.ZodEnum<{
|
|
353
|
+
USD: "USD";
|
|
354
|
+
EUR: "EUR";
|
|
355
|
+
FAIR: "FAIR";
|
|
356
|
+
}>>;
|
|
357
|
+
}, z.core.$catchall<z.ZodUnknown>>>;
|
|
358
|
+
themePreference: z.ZodOptional<z.ZodType<ThemePreference, unknown, z.core.$ZodTypeInternals<ThemePreference, unknown>>>;
|
|
1173
359
|
personalization: z.ZodOptional<z.ZodObject<{
|
|
1174
360
|
mentionMono: z.ZodObject<{
|
|
1175
361
|
allowed: z.ZodBoolean;
|
|
1176
362
|
expiresAt: z.ZodNullable<z.ZodString>;
|
|
1177
|
-
},
|
|
1178
|
-
|
|
1179
|
-
|
|
1180
|
-
|
|
1181
|
-
expiresAt: string | null;
|
|
1182
|
-
allowed: boolean;
|
|
1183
|
-
}>;
|
|
1184
|
-
}, "strict", z.ZodTypeAny, {
|
|
1185
|
-
mentionMono: {
|
|
1186
|
-
expiresAt: string | null;
|
|
1187
|
-
allowed: boolean;
|
|
1188
|
-
};
|
|
1189
|
-
}, {
|
|
1190
|
-
mentionMono: {
|
|
1191
|
-
expiresAt: string | null;
|
|
1192
|
-
allowed: boolean;
|
|
1193
|
-
};
|
|
1194
|
-
}>>;
|
|
1195
|
-
}, z.ZodTypeAny, "passthrough">>;
|
|
1196
|
-
}, "strip", z.ZodTypeAny, {
|
|
1197
|
-
data: {
|
|
1198
|
-
name: UserNameResponse;
|
|
1199
|
-
color?: string | null | undefined;
|
|
1200
|
-
kind?: "personal" | "organization" | "project" | "bot" | "channel" | "community" | undefined;
|
|
1201
|
-
username?: string | undefined;
|
|
1202
|
-
avatar?: string | null | undefined;
|
|
1203
|
-
verifiedDomains?: import("./identity").VerifiedDomain[] | undefined;
|
|
1204
|
-
id?: string | undefined;
|
|
1205
|
-
accountCategories?: ("community" | "news" | "politics" | "business" | "startup" | "finance" | "crypto" | "marketplace" | "retail" | "real_estate" | "agency" | "landlord" | "cooperative" | "architecture" | "technology" | "software" | "ai" | "security" | "automation" | "science" | "education" | "books" | "health" | "fitness" | "sports" | "gaming" | "music" | "film" | "podcast" | "art" | "photography" | "comedy" | "food" | "travel" | "fashion" | "home_garden" | "diy" | "automotive" | "animals" | "family" | "nonprofit" | "government" | "activism" | "environment" | "religion" | "other")[] | undefined;
|
|
1206
|
-
character?: import("./avatarCharacter").AvatarCharacter | undefined;
|
|
1207
|
-
email?: string | undefined;
|
|
1208
|
-
publicKey?: string | undefined;
|
|
1209
|
-
verified?: boolean | undefined;
|
|
1210
|
-
did?: string | undefined;
|
|
1211
|
-
relationship?: UserRelationship | undefined;
|
|
1212
|
-
address?: string | undefined;
|
|
1213
|
-
phone?: string | undefined;
|
|
1214
|
-
_id?: string | undefined;
|
|
1215
|
-
birthday?: string | undefined;
|
|
1216
|
-
dateOfBirth?: string | undefined;
|
|
1217
|
-
isAdult?: boolean | undefined;
|
|
1218
|
-
languages?: string[] | undefined;
|
|
1219
|
-
userPreferences?: z.objectOutputType<{
|
|
1220
|
-
displayCurrency: z.ZodOptional<z.ZodEnum<["USD", "EUR", "FAIR"]>>;
|
|
1221
|
-
}, z.ZodUnknown, "strip"> | undefined;
|
|
1222
|
-
themePreference?: ThemePreference | undefined;
|
|
1223
|
-
personalization?: {
|
|
1224
|
-
mentionMono: {
|
|
1225
|
-
expiresAt: string | null;
|
|
1226
|
-
allowed: boolean;
|
|
1227
|
-
};
|
|
1228
|
-
} | undefined;
|
|
1229
|
-
} & {
|
|
1230
|
-
[k: string]: unknown;
|
|
1231
|
-
};
|
|
1232
|
-
}, {
|
|
1233
|
-
data: {
|
|
1234
|
-
name: UserNameResponse;
|
|
1235
|
-
color?: string | null | undefined;
|
|
1236
|
-
kind?: "personal" | "organization" | "project" | "bot" | "channel" | "community" | undefined;
|
|
1237
|
-
username?: string | undefined;
|
|
1238
|
-
avatar?: string | null | undefined;
|
|
1239
|
-
verifiedDomains?: import("./identity").VerifiedDomain[] | undefined;
|
|
1240
|
-
id?: string | undefined;
|
|
1241
|
-
accountCategories?: ("community" | "news" | "politics" | "business" | "startup" | "finance" | "crypto" | "marketplace" | "retail" | "real_estate" | "agency" | "landlord" | "cooperative" | "architecture" | "technology" | "software" | "ai" | "security" | "automation" | "science" | "education" | "books" | "health" | "fitness" | "sports" | "gaming" | "music" | "film" | "podcast" | "art" | "photography" | "comedy" | "food" | "travel" | "fashion" | "home_garden" | "diy" | "automotive" | "animals" | "family" | "nonprofit" | "government" | "activism" | "environment" | "religion" | "other")[] | undefined;
|
|
1242
|
-
character?: unknown;
|
|
1243
|
-
email?: string | undefined;
|
|
1244
|
-
publicKey?: string | undefined;
|
|
1245
|
-
verified?: boolean | undefined;
|
|
1246
|
-
did?: string | undefined;
|
|
1247
|
-
relationship?: UserRelationship | undefined;
|
|
1248
|
-
address?: string | undefined;
|
|
1249
|
-
phone?: string | undefined;
|
|
1250
|
-
_id?: string | undefined;
|
|
1251
|
-
birthday?: string | undefined;
|
|
1252
|
-
dateOfBirth?: string | undefined;
|
|
1253
|
-
isAdult?: boolean | undefined;
|
|
1254
|
-
languages?: string[] | undefined;
|
|
1255
|
-
userPreferences?: z.objectInputType<{
|
|
1256
|
-
displayCurrency: z.ZodOptional<z.ZodEnum<["USD", "EUR", "FAIR"]>>;
|
|
1257
|
-
}, z.ZodUnknown, "strip"> | undefined;
|
|
1258
|
-
themePreference?: ThemePreference | undefined;
|
|
1259
|
-
personalization?: {
|
|
1260
|
-
mentionMono: {
|
|
1261
|
-
expiresAt: string | null;
|
|
1262
|
-
allowed: boolean;
|
|
1263
|
-
};
|
|
1264
|
-
} | undefined;
|
|
1265
|
-
} & {
|
|
1266
|
-
[k: string]: unknown;
|
|
1267
|
-
};
|
|
1268
|
-
}>;
|
|
363
|
+
}, z.core.$strict>;
|
|
364
|
+
}, z.core.$strict>>;
|
|
365
|
+
}, z.core.$loose>;
|
|
366
|
+
}, z.core.$strip>;
|
|
1269
367
|
export type CurrentUserResponseContract = z.infer<typeof currentUserResponseSchema>;
|
|
1270
368
|
/**
|
|
1271
369
|
* One entry of `GET /session/device/sessions/:sessionId` — the deduplicated
|
|
@@ -1277,9 +375,7 @@ export declare const deviceLinkedSessionSchema: z.ZodObject<{
|
|
|
1277
375
|
sessionId: z.ZodString;
|
|
1278
376
|
isCurrent: z.ZodOptional<z.ZodBoolean>;
|
|
1279
377
|
user: z.ZodOptional<z.ZodNullable<z.ZodObject<{
|
|
1280
|
-
/** The user id as a string. Present on `formatUserResponse` output. */
|
|
1281
378
|
id: z.ZodOptional<z.ZodString>;
|
|
1282
|
-
/** Raw-document id (e.g. `GET /users/me`). Present when `id` is not. */
|
|
1283
379
|
_id: z.ZodOptional<z.ZodString>;
|
|
1284
380
|
publicKey: z.ZodOptional<z.ZodString>;
|
|
1285
381
|
username: z.ZodOptional<z.ZodString>;
|
|
@@ -1287,694 +383,96 @@ export declare const deviceLinkedSessionSchema: z.ZodObject<{
|
|
|
1287
383
|
phone: z.ZodOptional<z.ZodString>;
|
|
1288
384
|
address: z.ZodOptional<z.ZodString>;
|
|
1289
385
|
birthday: z.ZodOptional<z.ZodString>;
|
|
1290
|
-
|
|
1291
|
-
* Structured date of birth, `YYYY-MM-DD`. Present only on the
|
|
1292
|
-
* account's OWN profile response (`GET /users/me`, `PUT /users/me`
|
|
1293
|
-
* with `includePrivateFields`) — never on another account's profile,
|
|
1294
|
-
* the same visibility `phone`/`address`/`birthday` already have. See
|
|
1295
|
-
* {@link dateOfBirthSchema}.
|
|
1296
|
-
*/
|
|
1297
|
-
dateOfBirth: z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>, string, string>>;
|
|
1298
|
-
/**
|
|
1299
|
-
* Derived, non-PII signal: whether the account holder is at least 18
|
|
1300
|
-
* (see `computeIsAdult` in `user.service.ts` for the exact threshold
|
|
1301
|
-
* and the UTC-"today" choice). Computed fresh on every read — age
|
|
1302
|
-
* changes daily, so this is never stored. `undefined` when
|
|
1303
|
-
* `dateOfBirth` is unset ("unknown"), distinct from `false` ("known,
|
|
1304
|
-
* not yet 18"). Rides the same owner-only visibility as
|
|
1305
|
-
* `dateOfBirth`; a future pass may widen this specific field to
|
|
1306
|
-
* other viewers without exposing the birthdate itself, but that is
|
|
1307
|
-
* not decided here.
|
|
1308
|
-
*/
|
|
386
|
+
dateOfBirth: z.ZodOptional<z.ZodString>;
|
|
1309
387
|
isAdult: z.ZodOptional<z.ZodBoolean>;
|
|
1310
|
-
/** Avatar file id (string) or null. */
|
|
1311
388
|
avatar: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
1312
|
-
/** Named Bloom color preset (e.g. `"blue"`) or null. */
|
|
1313
389
|
color: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
1314
|
-
name: z.ZodType<UserNameResponse, z.
|
|
390
|
+
name: z.ZodType<UserNameResponse, unknown, z.core.$ZodTypeInternals<UserNameResponse, unknown>>;
|
|
1315
391
|
verified: z.ZodOptional<z.ZodBoolean>;
|
|
1316
|
-
|
|
1317
|
-
* The account's languages as full BCP-47 locales (`language-REGION`,
|
|
1318
|
-
* e.g. `es-ES`, `en-US`, `pt-BR`), ordered with the PRIMARY (UI) locale
|
|
1319
|
-
* first. `languages[0]` is the primary locale — there is no singular
|
|
1320
|
-
* `language` field.
|
|
1321
|
-
*/
|
|
1322
|
-
languages: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
1323
|
-
/**
|
|
1324
|
-
* The account's self-sovereign identifier
|
|
1325
|
-
* (`did:web:<FEDERATION_DOMAIN>:u:<userId>`). Surfaced as a `User`
|
|
1326
|
-
* virtual; present on formatted DTOs once the identity layer is live.
|
|
1327
|
-
*/
|
|
392
|
+
languages: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
1328
393
|
did: z.ZodOptional<z.ZodString>;
|
|
1329
|
-
|
|
1330
|
-
|
|
1331
|
-
|
|
1332
|
-
|
|
1333
|
-
|
|
1334
|
-
|
|
1335
|
-
|
|
1336
|
-
|
|
1337
|
-
* ORTHOGONAL to `type` (`local` / `federated` / `agent` / `automated`),
|
|
1338
|
-
* which says where the account lives and how it is driven; the two
|
|
1339
|
-
* coexist and neither substitutes for the other. A `channel` is a
|
|
1340
|
-
* publishing identity nobody can act as, so a consumer that renders
|
|
1341
|
-
* authored content reads THIS to tell a channel's post from a person's.
|
|
1342
|
-
*
|
|
1343
|
-
* Optional because a DTO produced from a source that never carried the
|
|
1344
|
-
* column omits it; absent should be read as `personal`, the column's
|
|
1345
|
-
* default, not as unknown.
|
|
1346
|
-
*/
|
|
1347
|
-
kind: z.ZodOptional<z.ZodEnum<["personal", "organization", "project", "bot", "channel", "community"]>>;
|
|
1348
|
-
/**
|
|
1349
|
-
* What this account is about — the field a profile screen RENDERS.
|
|
1350
|
-
*
|
|
1351
|
-
* **Ordered, primary first.** `accountCategories[0]` is the primary
|
|
1352
|
-
* category; there is deliberately no sibling `primaryCategory` field,
|
|
1353
|
-
* because two representations of one fact can disagree (see rule 2 in
|
|
1354
|
-
* `accountGraph.ts`). Nothing downstream may sort, de-duplicate or
|
|
1355
|
-
* otherwise reorder this array.
|
|
1356
|
-
*
|
|
1357
|
-
* **Ids, never labels.** Each element is a stable slug; the visible text
|
|
1358
|
-
* comes from the reader's own translation catalogue, keyed
|
|
1359
|
-
* `accounts.accountCategory.<id>`. A label on the wire would paint every
|
|
1360
|
-
* profile in the language of whoever picked it.
|
|
1361
|
-
*
|
|
1362
|
-
* Absent when the account has none — which is every `personal` account,
|
|
1363
|
-
* and any non-personal one that has not chosen. A renderer reads
|
|
1364
|
-
* `user.accountCategories ?? []`.
|
|
1365
|
-
*/
|
|
1366
|
-
accountCategories: z.ZodOptional<z.ZodEffects<z.ZodArray<z.ZodEnum<["news", "politics", "business", "startup", "finance", "crypto", "marketplace", "retail", "real_estate", "agency", "landlord", "cooperative", "architecture", "technology", "software", "ai", "security", "automation", "science", "education", "books", "health", "fitness", "sports", "gaming", "music", "film", "podcast", "art", "photography", "comedy", "food", "travel", "fashion", "home_garden", "diy", "automotive", "animals", "family", "nonprofit", "government", "community", "activism", "environment", "religion", "other"]>, "many">, ("community" | "news" | "politics" | "business" | "startup" | "finance" | "crypto" | "marketplace" | "retail" | "real_estate" | "agency" | "landlord" | "cooperative" | "architecture" | "technology" | "software" | "ai" | "security" | "automation" | "science" | "education" | "books" | "health" | "fitness" | "sports" | "gaming" | "music" | "film" | "podcast" | "art" | "photography" | "comedy" | "food" | "travel" | "fashion" | "home_garden" | "diy" | "automotive" | "animals" | "family" | "nonprofit" | "government" | "activism" | "environment" | "religion" | "other")[], ("community" | "news" | "politics" | "business" | "startup" | "finance" | "crypto" | "marketplace" | "retail" | "real_estate" | "agency" | "landlord" | "cooperative" | "architecture" | "technology" | "software" | "ai" | "security" | "automation" | "science" | "education" | "books" | "health" | "fitness" | "sports" | "gaming" | "music" | "film" | "podcast" | "art" | "photography" | "comedy" | "food" | "travel" | "fashion" | "home_garden" | "diy" | "automotive" | "animals" | "family" | "nonprofit" | "government" | "activism" | "environment" | "religion" | "other")[]>>;
|
|
1367
|
-
/**
|
|
1368
|
-
* The 3D avatar character of a `kind: 'bot'` account — what Bloom's
|
|
1369
|
-
* `Avatar` draws instead of a picture. Present ONLY on a bot's payload,
|
|
1370
|
-
* never on a person's or an organization's, so those DTOs do not grow.
|
|
1371
|
-
*/
|
|
1372
|
-
character: z.ZodOptional<z.ZodType<import("./avatarCharacter").AvatarCharacter, z.ZodTypeDef, unknown>>;
|
|
1373
|
-
/**
|
|
1374
|
-
* The authenticated viewer's relationship to this profile. Present ONLY
|
|
1375
|
-
* on single-profile fetches (`GET /profiles/username/:username`,
|
|
1376
|
-
* `GET /users/:userId`) when the request is authenticated; OMITTED for
|
|
1377
|
-
* anonymous requests and for the bulk `POST /users/by-ids` fan-out.
|
|
1378
|
-
*/
|
|
1379
|
-
relationship: z.ZodOptional<z.ZodType<UserRelationship, z.ZodTypeDef, UserRelationship>>;
|
|
1380
|
-
/**
|
|
1381
|
-
* Portable theme preference. Rides the self/session payload (cold boot),
|
|
1382
|
-
* so it is present on the current-user DTO (`GET /users/me`,
|
|
1383
|
-
* `GET /session/user/:sessionId`) and absent until the user sets it.
|
|
1384
|
-
*/
|
|
1385
|
-
userPreferences: z.ZodOptional<z.ZodObject<{
|
|
1386
|
-
displayCurrency: z.ZodOptional<z.ZodEnum<["USD", "EUR", "FAIR"]>>;
|
|
1387
|
-
}, "strip", z.ZodUnknown, z.objectOutputType<{
|
|
1388
|
-
displayCurrency: z.ZodOptional<z.ZodEnum<["USD", "EUR", "FAIR"]>>;
|
|
1389
|
-
}, z.ZodUnknown, "strip">, z.objectInputType<{
|
|
1390
|
-
displayCurrency: z.ZodOptional<z.ZodEnum<["USD", "EUR", "FAIR"]>>;
|
|
1391
|
-
}, z.ZodUnknown, "strip">>>;
|
|
1392
|
-
themePreference: z.ZodOptional<z.ZodType<ThemePreference, z.ZodTypeDef, ThemePreference>>;
|
|
1393
|
-
personalization: z.ZodOptional<z.ZodObject<{
|
|
1394
|
-
mentionMono: z.ZodObject<{
|
|
1395
|
-
allowed: z.ZodBoolean;
|
|
1396
|
-
expiresAt: z.ZodNullable<z.ZodString>;
|
|
1397
|
-
}, "strict", z.ZodTypeAny, {
|
|
1398
|
-
expiresAt: string | null;
|
|
1399
|
-
allowed: boolean;
|
|
1400
|
-
}, {
|
|
1401
|
-
expiresAt: string | null;
|
|
1402
|
-
allowed: boolean;
|
|
1403
|
-
}>;
|
|
1404
|
-
}, "strict", z.ZodTypeAny, {
|
|
1405
|
-
mentionMono: {
|
|
1406
|
-
expiresAt: string | null;
|
|
1407
|
-
allowed: boolean;
|
|
1408
|
-
};
|
|
1409
|
-
}, {
|
|
1410
|
-
mentionMono: {
|
|
1411
|
-
expiresAt: string | null;
|
|
1412
|
-
allowed: boolean;
|
|
1413
|
-
};
|
|
394
|
+
verifiedDomains: z.ZodOptional<z.ZodArray<z.ZodType<import("./identity").VerifiedDomain, unknown, z.core.$ZodTypeInternals<import("./identity").VerifiedDomain, unknown>>>>;
|
|
395
|
+
kind: z.ZodOptional<z.ZodEnum<{
|
|
396
|
+
personal: "personal";
|
|
397
|
+
organization: "organization";
|
|
398
|
+
project: "project";
|
|
399
|
+
bot: "bot";
|
|
400
|
+
channel: "channel";
|
|
401
|
+
community: "community";
|
|
1414
402
|
}>>;
|
|
1415
|
-
|
|
1416
|
-
|
|
1417
|
-
|
|
1418
|
-
|
|
1419
|
-
|
|
1420
|
-
|
|
1421
|
-
|
|
1422
|
-
|
|
1423
|
-
|
|
1424
|
-
|
|
1425
|
-
|
|
1426
|
-
|
|
1427
|
-
|
|
1428
|
-
|
|
1429
|
-
|
|
1430
|
-
|
|
1431
|
-
|
|
1432
|
-
|
|
1433
|
-
|
|
1434
|
-
|
|
1435
|
-
|
|
1436
|
-
|
|
1437
|
-
|
|
1438
|
-
|
|
1439
|
-
|
|
1440
|
-
|
|
1441
|
-
|
|
1442
|
-
|
|
1443
|
-
|
|
1444
|
-
|
|
1445
|
-
|
|
1446
|
-
|
|
1447
|
-
|
|
1448
|
-
|
|
1449
|
-
|
|
1450
|
-
|
|
1451
|
-
|
|
1452
|
-
|
|
1453
|
-
|
|
1454
|
-
|
|
1455
|
-
|
|
1456
|
-
|
|
1457
|
-
|
|
1458
|
-
|
|
1459
|
-
|
|
1460
|
-
|
|
1461
|
-
|
|
1462
|
-
|
|
1463
|
-
|
|
1464
|
-
|
|
1465
|
-
/**
|
|
1466
|
-
* Proven domain-ownership badges. Each is a {@link verifiedDomainSchema}
|
|
1467
|
-
* entry; present only when the account has verified at least one domain.
|
|
1468
|
-
*/
|
|
1469
|
-
verifiedDomains: z.ZodOptional<z.ZodArray<z.ZodType<import("./identity").VerifiedDomain, z.ZodTypeDef, import("./identity").VerifiedDomain>, "many">>;
|
|
1470
|
-
/**
|
|
1471
|
-
* Account-graph classification — what KIND of account this is.
|
|
1472
|
-
*
|
|
1473
|
-
* ORTHOGONAL to `type` (`local` / `federated` / `agent` / `automated`),
|
|
1474
|
-
* which says where the account lives and how it is driven; the two
|
|
1475
|
-
* coexist and neither substitutes for the other. A `channel` is a
|
|
1476
|
-
* publishing identity nobody can act as, so a consumer that renders
|
|
1477
|
-
* authored content reads THIS to tell a channel's post from a person's.
|
|
1478
|
-
*
|
|
1479
|
-
* Optional because a DTO produced from a source that never carried the
|
|
1480
|
-
* column omits it; absent should be read as `personal`, the column's
|
|
1481
|
-
* default, not as unknown.
|
|
1482
|
-
*/
|
|
1483
|
-
kind: z.ZodOptional<z.ZodEnum<["personal", "organization", "project", "bot", "channel", "community"]>>;
|
|
1484
|
-
/**
|
|
1485
|
-
* What this account is about — the field a profile screen RENDERS.
|
|
1486
|
-
*
|
|
1487
|
-
* **Ordered, primary first.** `accountCategories[0]` is the primary
|
|
1488
|
-
* category; there is deliberately no sibling `primaryCategory` field,
|
|
1489
|
-
* because two representations of one fact can disagree (see rule 2 in
|
|
1490
|
-
* `accountGraph.ts`). Nothing downstream may sort, de-duplicate or
|
|
1491
|
-
* otherwise reorder this array.
|
|
1492
|
-
*
|
|
1493
|
-
* **Ids, never labels.** Each element is a stable slug; the visible text
|
|
1494
|
-
* comes from the reader's own translation catalogue, keyed
|
|
1495
|
-
* `accounts.accountCategory.<id>`. A label on the wire would paint every
|
|
1496
|
-
* profile in the language of whoever picked it.
|
|
1497
|
-
*
|
|
1498
|
-
* Absent when the account has none — which is every `personal` account,
|
|
1499
|
-
* and any non-personal one that has not chosen. A renderer reads
|
|
1500
|
-
* `user.accountCategories ?? []`.
|
|
1501
|
-
*/
|
|
1502
|
-
accountCategories: z.ZodOptional<z.ZodEffects<z.ZodArray<z.ZodEnum<["news", "politics", "business", "startup", "finance", "crypto", "marketplace", "retail", "real_estate", "agency", "landlord", "cooperative", "architecture", "technology", "software", "ai", "security", "automation", "science", "education", "books", "health", "fitness", "sports", "gaming", "music", "film", "podcast", "art", "photography", "comedy", "food", "travel", "fashion", "home_garden", "diy", "automotive", "animals", "family", "nonprofit", "government", "community", "activism", "environment", "religion", "other"]>, "many">, ("community" | "news" | "politics" | "business" | "startup" | "finance" | "crypto" | "marketplace" | "retail" | "real_estate" | "agency" | "landlord" | "cooperative" | "architecture" | "technology" | "software" | "ai" | "security" | "automation" | "science" | "education" | "books" | "health" | "fitness" | "sports" | "gaming" | "music" | "film" | "podcast" | "art" | "photography" | "comedy" | "food" | "travel" | "fashion" | "home_garden" | "diy" | "automotive" | "animals" | "family" | "nonprofit" | "government" | "activism" | "environment" | "religion" | "other")[], ("community" | "news" | "politics" | "business" | "startup" | "finance" | "crypto" | "marketplace" | "retail" | "real_estate" | "agency" | "landlord" | "cooperative" | "architecture" | "technology" | "software" | "ai" | "security" | "automation" | "science" | "education" | "books" | "health" | "fitness" | "sports" | "gaming" | "music" | "film" | "podcast" | "art" | "photography" | "comedy" | "food" | "travel" | "fashion" | "home_garden" | "diy" | "automotive" | "animals" | "family" | "nonprofit" | "government" | "activism" | "environment" | "religion" | "other")[]>>;
|
|
1503
|
-
/**
|
|
1504
|
-
* The 3D avatar character of a `kind: 'bot'` account — what Bloom's
|
|
1505
|
-
* `Avatar` draws instead of a picture. Present ONLY on a bot's payload,
|
|
1506
|
-
* never on a person's or an organization's, so those DTOs do not grow.
|
|
1507
|
-
*/
|
|
1508
|
-
character: z.ZodOptional<z.ZodType<import("./avatarCharacter").AvatarCharacter, z.ZodTypeDef, unknown>>;
|
|
1509
|
-
/**
|
|
1510
|
-
* The authenticated viewer's relationship to this profile. Present ONLY
|
|
1511
|
-
* on single-profile fetches (`GET /profiles/username/:username`,
|
|
1512
|
-
* `GET /users/:userId`) when the request is authenticated; OMITTED for
|
|
1513
|
-
* anonymous requests and for the bulk `POST /users/by-ids` fan-out.
|
|
1514
|
-
*/
|
|
1515
|
-
relationship: z.ZodOptional<z.ZodType<UserRelationship, z.ZodTypeDef, UserRelationship>>;
|
|
1516
|
-
/**
|
|
1517
|
-
* Portable theme preference. Rides the self/session payload (cold boot),
|
|
1518
|
-
* so it is present on the current-user DTO (`GET /users/me`,
|
|
1519
|
-
* `GET /session/user/:sessionId`) and absent until the user sets it.
|
|
1520
|
-
*/
|
|
1521
|
-
userPreferences: z.ZodOptional<z.ZodObject<{
|
|
1522
|
-
displayCurrency: z.ZodOptional<z.ZodEnum<["USD", "EUR", "FAIR"]>>;
|
|
1523
|
-
}, "strip", z.ZodUnknown, z.objectOutputType<{
|
|
1524
|
-
displayCurrency: z.ZodOptional<z.ZodEnum<["USD", "EUR", "FAIR"]>>;
|
|
1525
|
-
}, z.ZodUnknown, "strip">, z.objectInputType<{
|
|
1526
|
-
displayCurrency: z.ZodOptional<z.ZodEnum<["USD", "EUR", "FAIR"]>>;
|
|
1527
|
-
}, z.ZodUnknown, "strip">>>;
|
|
1528
|
-
themePreference: z.ZodOptional<z.ZodType<ThemePreference, z.ZodTypeDef, ThemePreference>>;
|
|
1529
|
-
personalization: z.ZodOptional<z.ZodObject<{
|
|
1530
|
-
mentionMono: z.ZodObject<{
|
|
1531
|
-
allowed: z.ZodBoolean;
|
|
1532
|
-
expiresAt: z.ZodNullable<z.ZodString>;
|
|
1533
|
-
}, "strict", z.ZodTypeAny, {
|
|
1534
|
-
expiresAt: string | null;
|
|
1535
|
-
allowed: boolean;
|
|
1536
|
-
}, {
|
|
1537
|
-
expiresAt: string | null;
|
|
1538
|
-
allowed: boolean;
|
|
1539
|
-
}>;
|
|
1540
|
-
}, "strict", z.ZodTypeAny, {
|
|
1541
|
-
mentionMono: {
|
|
1542
|
-
expiresAt: string | null;
|
|
1543
|
-
allowed: boolean;
|
|
1544
|
-
};
|
|
1545
|
-
}, {
|
|
1546
|
-
mentionMono: {
|
|
1547
|
-
expiresAt: string | null;
|
|
1548
|
-
allowed: boolean;
|
|
1549
|
-
};
|
|
1550
|
-
}>>;
|
|
1551
|
-
}, z.ZodTypeAny, "passthrough">, z.objectInputType<{
|
|
1552
|
-
/** The user id as a string. Present on `formatUserResponse` output. */
|
|
1553
|
-
id: z.ZodOptional<z.ZodString>;
|
|
1554
|
-
/** Raw-document id (e.g. `GET /users/me`). Present when `id` is not. */
|
|
1555
|
-
_id: z.ZodOptional<z.ZodString>;
|
|
1556
|
-
publicKey: z.ZodOptional<z.ZodString>;
|
|
1557
|
-
username: z.ZodOptional<z.ZodString>;
|
|
1558
|
-
email: z.ZodOptional<z.ZodString>;
|
|
1559
|
-
phone: z.ZodOptional<z.ZodString>;
|
|
1560
|
-
address: z.ZodOptional<z.ZodString>;
|
|
1561
|
-
birthday: z.ZodOptional<z.ZodString>;
|
|
1562
|
-
/**
|
|
1563
|
-
* Structured date of birth, `YYYY-MM-DD`. Present only on the
|
|
1564
|
-
* account's OWN profile response (`GET /users/me`, `PUT /users/me`
|
|
1565
|
-
* with `includePrivateFields`) — never on another account's profile,
|
|
1566
|
-
* the same visibility `phone`/`address`/`birthday` already have. See
|
|
1567
|
-
* {@link dateOfBirthSchema}.
|
|
1568
|
-
*/
|
|
1569
|
-
dateOfBirth: z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>, string, string>>;
|
|
1570
|
-
/**
|
|
1571
|
-
* Derived, non-PII signal: whether the account holder is at least 18
|
|
1572
|
-
* (see `computeIsAdult` in `user.service.ts` for the exact threshold
|
|
1573
|
-
* and the UTC-"today" choice). Computed fresh on every read — age
|
|
1574
|
-
* changes daily, so this is never stored. `undefined` when
|
|
1575
|
-
* `dateOfBirth` is unset ("unknown"), distinct from `false` ("known,
|
|
1576
|
-
* not yet 18"). Rides the same owner-only visibility as
|
|
1577
|
-
* `dateOfBirth`; a future pass may widen this specific field to
|
|
1578
|
-
* other viewers without exposing the birthdate itself, but that is
|
|
1579
|
-
* not decided here.
|
|
1580
|
-
*/
|
|
1581
|
-
isAdult: z.ZodOptional<z.ZodBoolean>;
|
|
1582
|
-
/** Avatar file id (string) or null. */
|
|
1583
|
-
avatar: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
1584
|
-
/** Named Bloom color preset (e.g. `"blue"`) or null. */
|
|
1585
|
-
color: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
1586
|
-
name: z.ZodType<UserNameResponse, z.ZodTypeDef, UserNameResponse>;
|
|
1587
|
-
verified: z.ZodOptional<z.ZodBoolean>;
|
|
1588
|
-
/**
|
|
1589
|
-
* The account's languages as full BCP-47 locales (`language-REGION`,
|
|
1590
|
-
* e.g. `es-ES`, `en-US`, `pt-BR`), ordered with the PRIMARY (UI) locale
|
|
1591
|
-
* first. `languages[0]` is the primary locale — there is no singular
|
|
1592
|
-
* `language` field.
|
|
1593
|
-
*/
|
|
1594
|
-
languages: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
1595
|
-
/**
|
|
1596
|
-
* The account's self-sovereign identifier
|
|
1597
|
-
* (`did:web:<FEDERATION_DOMAIN>:u:<userId>`). Surfaced as a `User`
|
|
1598
|
-
* virtual; present on formatted DTOs once the identity layer is live.
|
|
1599
|
-
*/
|
|
1600
|
-
did: z.ZodOptional<z.ZodString>;
|
|
1601
|
-
/**
|
|
1602
|
-
* Proven domain-ownership badges. Each is a {@link verifiedDomainSchema}
|
|
1603
|
-
* entry; present only when the account has verified at least one domain.
|
|
1604
|
-
*/
|
|
1605
|
-
verifiedDomains: z.ZodOptional<z.ZodArray<z.ZodType<import("./identity").VerifiedDomain, z.ZodTypeDef, import("./identity").VerifiedDomain>, "many">>;
|
|
1606
|
-
/**
|
|
1607
|
-
* Account-graph classification — what KIND of account this is.
|
|
1608
|
-
*
|
|
1609
|
-
* ORTHOGONAL to `type` (`local` / `federated` / `agent` / `automated`),
|
|
1610
|
-
* which says where the account lives and how it is driven; the two
|
|
1611
|
-
* coexist and neither substitutes for the other. A `channel` is a
|
|
1612
|
-
* publishing identity nobody can act as, so a consumer that renders
|
|
1613
|
-
* authored content reads THIS to tell a channel's post from a person's.
|
|
1614
|
-
*
|
|
1615
|
-
* Optional because a DTO produced from a source that never carried the
|
|
1616
|
-
* column omits it; absent should be read as `personal`, the column's
|
|
1617
|
-
* default, not as unknown.
|
|
1618
|
-
*/
|
|
1619
|
-
kind: z.ZodOptional<z.ZodEnum<["personal", "organization", "project", "bot", "channel", "community"]>>;
|
|
1620
|
-
/**
|
|
1621
|
-
* What this account is about — the field a profile screen RENDERS.
|
|
1622
|
-
*
|
|
1623
|
-
* **Ordered, primary first.** `accountCategories[0]` is the primary
|
|
1624
|
-
* category; there is deliberately no sibling `primaryCategory` field,
|
|
1625
|
-
* because two representations of one fact can disagree (see rule 2 in
|
|
1626
|
-
* `accountGraph.ts`). Nothing downstream may sort, de-duplicate or
|
|
1627
|
-
* otherwise reorder this array.
|
|
1628
|
-
*
|
|
1629
|
-
* **Ids, never labels.** Each element is a stable slug; the visible text
|
|
1630
|
-
* comes from the reader's own translation catalogue, keyed
|
|
1631
|
-
* `accounts.accountCategory.<id>`. A label on the wire would paint every
|
|
1632
|
-
* profile in the language of whoever picked it.
|
|
1633
|
-
*
|
|
1634
|
-
* Absent when the account has none — which is every `personal` account,
|
|
1635
|
-
* and any non-personal one that has not chosen. A renderer reads
|
|
1636
|
-
* `user.accountCategories ?? []`.
|
|
1637
|
-
*/
|
|
1638
|
-
accountCategories: z.ZodOptional<z.ZodEffects<z.ZodArray<z.ZodEnum<["news", "politics", "business", "startup", "finance", "crypto", "marketplace", "retail", "real_estate", "agency", "landlord", "cooperative", "architecture", "technology", "software", "ai", "security", "automation", "science", "education", "books", "health", "fitness", "sports", "gaming", "music", "film", "podcast", "art", "photography", "comedy", "food", "travel", "fashion", "home_garden", "diy", "automotive", "animals", "family", "nonprofit", "government", "community", "activism", "environment", "religion", "other"]>, "many">, ("community" | "news" | "politics" | "business" | "startup" | "finance" | "crypto" | "marketplace" | "retail" | "real_estate" | "agency" | "landlord" | "cooperative" | "architecture" | "technology" | "software" | "ai" | "security" | "automation" | "science" | "education" | "books" | "health" | "fitness" | "sports" | "gaming" | "music" | "film" | "podcast" | "art" | "photography" | "comedy" | "food" | "travel" | "fashion" | "home_garden" | "diy" | "automotive" | "animals" | "family" | "nonprofit" | "government" | "activism" | "environment" | "religion" | "other")[], ("community" | "news" | "politics" | "business" | "startup" | "finance" | "crypto" | "marketplace" | "retail" | "real_estate" | "agency" | "landlord" | "cooperative" | "architecture" | "technology" | "software" | "ai" | "security" | "automation" | "science" | "education" | "books" | "health" | "fitness" | "sports" | "gaming" | "music" | "film" | "podcast" | "art" | "photography" | "comedy" | "food" | "travel" | "fashion" | "home_garden" | "diy" | "automotive" | "animals" | "family" | "nonprofit" | "government" | "activism" | "environment" | "religion" | "other")[]>>;
|
|
1639
|
-
/**
|
|
1640
|
-
* The 3D avatar character of a `kind: 'bot'` account — what Bloom's
|
|
1641
|
-
* `Avatar` draws instead of a picture. Present ONLY on a bot's payload,
|
|
1642
|
-
* never on a person's or an organization's, so those DTOs do not grow.
|
|
1643
|
-
*/
|
|
1644
|
-
character: z.ZodOptional<z.ZodType<import("./avatarCharacter").AvatarCharacter, z.ZodTypeDef, unknown>>;
|
|
1645
|
-
/**
|
|
1646
|
-
* The authenticated viewer's relationship to this profile. Present ONLY
|
|
1647
|
-
* on single-profile fetches (`GET /profiles/username/:username`,
|
|
1648
|
-
* `GET /users/:userId`) when the request is authenticated; OMITTED for
|
|
1649
|
-
* anonymous requests and for the bulk `POST /users/by-ids` fan-out.
|
|
1650
|
-
*/
|
|
1651
|
-
relationship: z.ZodOptional<z.ZodType<UserRelationship, z.ZodTypeDef, UserRelationship>>;
|
|
1652
|
-
/**
|
|
1653
|
-
* Portable theme preference. Rides the self/session payload (cold boot),
|
|
1654
|
-
* so it is present on the current-user DTO (`GET /users/me`,
|
|
1655
|
-
* `GET /session/user/:sessionId`) and absent until the user sets it.
|
|
1656
|
-
*/
|
|
1657
|
-
userPreferences: z.ZodOptional<z.ZodObject<{
|
|
1658
|
-
displayCurrency: z.ZodOptional<z.ZodEnum<["USD", "EUR", "FAIR"]>>;
|
|
1659
|
-
}, "strip", z.ZodUnknown, z.objectOutputType<{
|
|
1660
|
-
displayCurrency: z.ZodOptional<z.ZodEnum<["USD", "EUR", "FAIR"]>>;
|
|
1661
|
-
}, z.ZodUnknown, "strip">, z.objectInputType<{
|
|
1662
|
-
displayCurrency: z.ZodOptional<z.ZodEnum<["USD", "EUR", "FAIR"]>>;
|
|
1663
|
-
}, z.ZodUnknown, "strip">>>;
|
|
1664
|
-
themePreference: z.ZodOptional<z.ZodType<ThemePreference, z.ZodTypeDef, ThemePreference>>;
|
|
1665
|
-
personalization: z.ZodOptional<z.ZodObject<{
|
|
1666
|
-
mentionMono: z.ZodObject<{
|
|
1667
|
-
allowed: z.ZodBoolean;
|
|
1668
|
-
expiresAt: z.ZodNullable<z.ZodString>;
|
|
1669
|
-
}, "strict", z.ZodTypeAny, {
|
|
1670
|
-
expiresAt: string | null;
|
|
1671
|
-
allowed: boolean;
|
|
1672
|
-
}, {
|
|
1673
|
-
expiresAt: string | null;
|
|
1674
|
-
allowed: boolean;
|
|
1675
|
-
}>;
|
|
1676
|
-
}, "strict", z.ZodTypeAny, {
|
|
1677
|
-
mentionMono: {
|
|
1678
|
-
expiresAt: string | null;
|
|
1679
|
-
allowed: boolean;
|
|
1680
|
-
};
|
|
1681
|
-
}, {
|
|
1682
|
-
mentionMono: {
|
|
1683
|
-
expiresAt: string | null;
|
|
1684
|
-
allowed: boolean;
|
|
1685
|
-
};
|
|
1686
|
-
}>>;
|
|
1687
|
-
}, z.ZodTypeAny, "passthrough">>>>;
|
|
1688
|
-
}, "strip", z.ZodTypeAny, {
|
|
1689
|
-
sessionId: string;
|
|
1690
|
-
user?: z.objectOutputType<{
|
|
1691
|
-
/** The user id as a string. Present on `formatUserResponse` output. */
|
|
1692
|
-
id: z.ZodOptional<z.ZodString>;
|
|
1693
|
-
/** Raw-document id (e.g. `GET /users/me`). Present when `id` is not. */
|
|
1694
|
-
_id: z.ZodOptional<z.ZodString>;
|
|
1695
|
-
publicKey: z.ZodOptional<z.ZodString>;
|
|
1696
|
-
username: z.ZodOptional<z.ZodString>;
|
|
1697
|
-
email: z.ZodOptional<z.ZodString>;
|
|
1698
|
-
phone: z.ZodOptional<z.ZodString>;
|
|
1699
|
-
address: z.ZodOptional<z.ZodString>;
|
|
1700
|
-
birthday: z.ZodOptional<z.ZodString>;
|
|
1701
|
-
/**
|
|
1702
|
-
* Structured date of birth, `YYYY-MM-DD`. Present only on the
|
|
1703
|
-
* account's OWN profile response (`GET /users/me`, `PUT /users/me`
|
|
1704
|
-
* with `includePrivateFields`) — never on another account's profile,
|
|
1705
|
-
* the same visibility `phone`/`address`/`birthday` already have. See
|
|
1706
|
-
* {@link dateOfBirthSchema}.
|
|
1707
|
-
*/
|
|
1708
|
-
dateOfBirth: z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>, string, string>>;
|
|
1709
|
-
/**
|
|
1710
|
-
* Derived, non-PII signal: whether the account holder is at least 18
|
|
1711
|
-
* (see `computeIsAdult` in `user.service.ts` for the exact threshold
|
|
1712
|
-
* and the UTC-"today" choice). Computed fresh on every read — age
|
|
1713
|
-
* changes daily, so this is never stored. `undefined` when
|
|
1714
|
-
* `dateOfBirth` is unset ("unknown"), distinct from `false` ("known,
|
|
1715
|
-
* not yet 18"). Rides the same owner-only visibility as
|
|
1716
|
-
* `dateOfBirth`; a future pass may widen this specific field to
|
|
1717
|
-
* other viewers without exposing the birthdate itself, but that is
|
|
1718
|
-
* not decided here.
|
|
1719
|
-
*/
|
|
1720
|
-
isAdult: z.ZodOptional<z.ZodBoolean>;
|
|
1721
|
-
/** Avatar file id (string) or null. */
|
|
1722
|
-
avatar: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
1723
|
-
/** Named Bloom color preset (e.g. `"blue"`) or null. */
|
|
1724
|
-
color: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
1725
|
-
name: z.ZodType<UserNameResponse, z.ZodTypeDef, UserNameResponse>;
|
|
1726
|
-
verified: z.ZodOptional<z.ZodBoolean>;
|
|
1727
|
-
/**
|
|
1728
|
-
* The account's languages as full BCP-47 locales (`language-REGION`,
|
|
1729
|
-
* e.g. `es-ES`, `en-US`, `pt-BR`), ordered with the PRIMARY (UI) locale
|
|
1730
|
-
* first. `languages[0]` is the primary locale — there is no singular
|
|
1731
|
-
* `language` field.
|
|
1732
|
-
*/
|
|
1733
|
-
languages: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
1734
|
-
/**
|
|
1735
|
-
* The account's self-sovereign identifier
|
|
1736
|
-
* (`did:web:<FEDERATION_DOMAIN>:u:<userId>`). Surfaced as a `User`
|
|
1737
|
-
* virtual; present on formatted DTOs once the identity layer is live.
|
|
1738
|
-
*/
|
|
1739
|
-
did: z.ZodOptional<z.ZodString>;
|
|
1740
|
-
/**
|
|
1741
|
-
* Proven domain-ownership badges. Each is a {@link verifiedDomainSchema}
|
|
1742
|
-
* entry; present only when the account has verified at least one domain.
|
|
1743
|
-
*/
|
|
1744
|
-
verifiedDomains: z.ZodOptional<z.ZodArray<z.ZodType<import("./identity").VerifiedDomain, z.ZodTypeDef, import("./identity").VerifiedDomain>, "many">>;
|
|
1745
|
-
/**
|
|
1746
|
-
* Account-graph classification — what KIND of account this is.
|
|
1747
|
-
*
|
|
1748
|
-
* ORTHOGONAL to `type` (`local` / `federated` / `agent` / `automated`),
|
|
1749
|
-
* which says where the account lives and how it is driven; the two
|
|
1750
|
-
* coexist and neither substitutes for the other. A `channel` is a
|
|
1751
|
-
* publishing identity nobody can act as, so a consumer that renders
|
|
1752
|
-
* authored content reads THIS to tell a channel's post from a person's.
|
|
1753
|
-
*
|
|
1754
|
-
* Optional because a DTO produced from a source that never carried the
|
|
1755
|
-
* column omits it; absent should be read as `personal`, the column's
|
|
1756
|
-
* default, not as unknown.
|
|
1757
|
-
*/
|
|
1758
|
-
kind: z.ZodOptional<z.ZodEnum<["personal", "organization", "project", "bot", "channel", "community"]>>;
|
|
1759
|
-
/**
|
|
1760
|
-
* What this account is about — the field a profile screen RENDERS.
|
|
1761
|
-
*
|
|
1762
|
-
* **Ordered, primary first.** `accountCategories[0]` is the primary
|
|
1763
|
-
* category; there is deliberately no sibling `primaryCategory` field,
|
|
1764
|
-
* because two representations of one fact can disagree (see rule 2 in
|
|
1765
|
-
* `accountGraph.ts`). Nothing downstream may sort, de-duplicate or
|
|
1766
|
-
* otherwise reorder this array.
|
|
1767
|
-
*
|
|
1768
|
-
* **Ids, never labels.** Each element is a stable slug; the visible text
|
|
1769
|
-
* comes from the reader's own translation catalogue, keyed
|
|
1770
|
-
* `accounts.accountCategory.<id>`. A label on the wire would paint every
|
|
1771
|
-
* profile in the language of whoever picked it.
|
|
1772
|
-
*
|
|
1773
|
-
* Absent when the account has none — which is every `personal` account,
|
|
1774
|
-
* and any non-personal one that has not chosen. A renderer reads
|
|
1775
|
-
* `user.accountCategories ?? []`.
|
|
1776
|
-
*/
|
|
1777
|
-
accountCategories: z.ZodOptional<z.ZodEffects<z.ZodArray<z.ZodEnum<["news", "politics", "business", "startup", "finance", "crypto", "marketplace", "retail", "real_estate", "agency", "landlord", "cooperative", "architecture", "technology", "software", "ai", "security", "automation", "science", "education", "books", "health", "fitness", "sports", "gaming", "music", "film", "podcast", "art", "photography", "comedy", "food", "travel", "fashion", "home_garden", "diy", "automotive", "animals", "family", "nonprofit", "government", "community", "activism", "environment", "religion", "other"]>, "many">, ("community" | "news" | "politics" | "business" | "startup" | "finance" | "crypto" | "marketplace" | "retail" | "real_estate" | "agency" | "landlord" | "cooperative" | "architecture" | "technology" | "software" | "ai" | "security" | "automation" | "science" | "education" | "books" | "health" | "fitness" | "sports" | "gaming" | "music" | "film" | "podcast" | "art" | "photography" | "comedy" | "food" | "travel" | "fashion" | "home_garden" | "diy" | "automotive" | "animals" | "family" | "nonprofit" | "government" | "activism" | "environment" | "religion" | "other")[], ("community" | "news" | "politics" | "business" | "startup" | "finance" | "crypto" | "marketplace" | "retail" | "real_estate" | "agency" | "landlord" | "cooperative" | "architecture" | "technology" | "software" | "ai" | "security" | "automation" | "science" | "education" | "books" | "health" | "fitness" | "sports" | "gaming" | "music" | "film" | "podcast" | "art" | "photography" | "comedy" | "food" | "travel" | "fashion" | "home_garden" | "diy" | "automotive" | "animals" | "family" | "nonprofit" | "government" | "activism" | "environment" | "religion" | "other")[]>>;
|
|
1778
|
-
/**
|
|
1779
|
-
* The 3D avatar character of a `kind: 'bot'` account — what Bloom's
|
|
1780
|
-
* `Avatar` draws instead of a picture. Present ONLY on a bot's payload,
|
|
1781
|
-
* never on a person's or an organization's, so those DTOs do not grow.
|
|
1782
|
-
*/
|
|
1783
|
-
character: z.ZodOptional<z.ZodType<import("./avatarCharacter").AvatarCharacter, z.ZodTypeDef, unknown>>;
|
|
1784
|
-
/**
|
|
1785
|
-
* The authenticated viewer's relationship to this profile. Present ONLY
|
|
1786
|
-
* on single-profile fetches (`GET /profiles/username/:username`,
|
|
1787
|
-
* `GET /users/:userId`) when the request is authenticated; OMITTED for
|
|
1788
|
-
* anonymous requests and for the bulk `POST /users/by-ids` fan-out.
|
|
1789
|
-
*/
|
|
1790
|
-
relationship: z.ZodOptional<z.ZodType<UserRelationship, z.ZodTypeDef, UserRelationship>>;
|
|
1791
|
-
/**
|
|
1792
|
-
* Portable theme preference. Rides the self/session payload (cold boot),
|
|
1793
|
-
* so it is present on the current-user DTO (`GET /users/me`,
|
|
1794
|
-
* `GET /session/user/:sessionId`) and absent until the user sets it.
|
|
1795
|
-
*/
|
|
403
|
+
accountCategories: z.ZodOptional<z.ZodArray<z.ZodEnum<{
|
|
404
|
+
community: "community";
|
|
405
|
+
news: "news";
|
|
406
|
+
politics: "politics";
|
|
407
|
+
business: "business";
|
|
408
|
+
startup: "startup";
|
|
409
|
+
finance: "finance";
|
|
410
|
+
crypto: "crypto";
|
|
411
|
+
marketplace: "marketplace";
|
|
412
|
+
retail: "retail";
|
|
413
|
+
real_estate: "real_estate";
|
|
414
|
+
agency: "agency";
|
|
415
|
+
landlord: "landlord";
|
|
416
|
+
cooperative: "cooperative";
|
|
417
|
+
architecture: "architecture";
|
|
418
|
+
technology: "technology";
|
|
419
|
+
software: "software";
|
|
420
|
+
ai: "ai";
|
|
421
|
+
security: "security";
|
|
422
|
+
automation: "automation";
|
|
423
|
+
science: "science";
|
|
424
|
+
education: "education";
|
|
425
|
+
books: "books";
|
|
426
|
+
health: "health";
|
|
427
|
+
fitness: "fitness";
|
|
428
|
+
sports: "sports";
|
|
429
|
+
gaming: "gaming";
|
|
430
|
+
music: "music";
|
|
431
|
+
film: "film";
|
|
432
|
+
podcast: "podcast";
|
|
433
|
+
art: "art";
|
|
434
|
+
photography: "photography";
|
|
435
|
+
comedy: "comedy";
|
|
436
|
+
food: "food";
|
|
437
|
+
travel: "travel";
|
|
438
|
+
fashion: "fashion";
|
|
439
|
+
home_garden: "home_garden";
|
|
440
|
+
diy: "diy";
|
|
441
|
+
automotive: "automotive";
|
|
442
|
+
animals: "animals";
|
|
443
|
+
family: "family";
|
|
444
|
+
nonprofit: "nonprofit";
|
|
445
|
+
government: "government";
|
|
446
|
+
activism: "activism";
|
|
447
|
+
environment: "environment";
|
|
448
|
+
religion: "religion";
|
|
449
|
+
other: "other";
|
|
450
|
+
}>>>;
|
|
451
|
+
character: z.ZodOptional<z.ZodType<import("./avatarCharacter").AvatarCharacter, unknown, z.core.$ZodTypeInternals<import("./avatarCharacter").AvatarCharacter, unknown>>>;
|
|
452
|
+
relationship: z.ZodOptional<z.ZodType<UserRelationship, unknown, z.core.$ZodTypeInternals<UserRelationship, unknown>>>;
|
|
1796
453
|
userPreferences: z.ZodOptional<z.ZodObject<{
|
|
1797
|
-
displayCurrency: z.ZodOptional<z.ZodEnum<
|
|
1798
|
-
|
|
1799
|
-
|
|
1800
|
-
|
|
1801
|
-
|
|
1802
|
-
}, z.ZodUnknown
|
|
1803
|
-
themePreference: z.ZodOptional<z.ZodType<ThemePreference, z.
|
|
454
|
+
displayCurrency: z.ZodOptional<z.ZodEnum<{
|
|
455
|
+
USD: "USD";
|
|
456
|
+
EUR: "EUR";
|
|
457
|
+
FAIR: "FAIR";
|
|
458
|
+
}>>;
|
|
459
|
+
}, z.core.$catchall<z.ZodUnknown>>>;
|
|
460
|
+
themePreference: z.ZodOptional<z.ZodType<ThemePreference, unknown, z.core.$ZodTypeInternals<ThemePreference, unknown>>>;
|
|
1804
461
|
personalization: z.ZodOptional<z.ZodObject<{
|
|
1805
462
|
mentionMono: z.ZodObject<{
|
|
1806
463
|
allowed: z.ZodBoolean;
|
|
1807
464
|
expiresAt: z.ZodNullable<z.ZodString>;
|
|
1808
|
-
},
|
|
1809
|
-
|
|
1810
|
-
|
|
1811
|
-
|
|
1812
|
-
expiresAt: string | null;
|
|
1813
|
-
allowed: boolean;
|
|
1814
|
-
}>;
|
|
1815
|
-
}, "strict", z.ZodTypeAny, {
|
|
1816
|
-
mentionMono: {
|
|
1817
|
-
expiresAt: string | null;
|
|
1818
|
-
allowed: boolean;
|
|
1819
|
-
};
|
|
1820
|
-
}, {
|
|
1821
|
-
mentionMono: {
|
|
1822
|
-
expiresAt: string | null;
|
|
1823
|
-
allowed: boolean;
|
|
1824
|
-
};
|
|
1825
|
-
}>>;
|
|
1826
|
-
}, z.ZodTypeAny, "passthrough"> | null | undefined;
|
|
1827
|
-
isCurrent?: boolean | undefined;
|
|
1828
|
-
}, {
|
|
1829
|
-
sessionId: string;
|
|
1830
|
-
user?: z.objectInputType<{
|
|
1831
|
-
/** The user id as a string. Present on `formatUserResponse` output. */
|
|
1832
|
-
id: z.ZodOptional<z.ZodString>;
|
|
1833
|
-
/** Raw-document id (e.g. `GET /users/me`). Present when `id` is not. */
|
|
1834
|
-
_id: z.ZodOptional<z.ZodString>;
|
|
1835
|
-
publicKey: z.ZodOptional<z.ZodString>;
|
|
1836
|
-
username: z.ZodOptional<z.ZodString>;
|
|
1837
|
-
email: z.ZodOptional<z.ZodString>;
|
|
1838
|
-
phone: z.ZodOptional<z.ZodString>;
|
|
1839
|
-
address: z.ZodOptional<z.ZodString>;
|
|
1840
|
-
birthday: z.ZodOptional<z.ZodString>;
|
|
1841
|
-
/**
|
|
1842
|
-
* Structured date of birth, `YYYY-MM-DD`. Present only on the
|
|
1843
|
-
* account's OWN profile response (`GET /users/me`, `PUT /users/me`
|
|
1844
|
-
* with `includePrivateFields`) — never on another account's profile,
|
|
1845
|
-
* the same visibility `phone`/`address`/`birthday` already have. See
|
|
1846
|
-
* {@link dateOfBirthSchema}.
|
|
1847
|
-
*/
|
|
1848
|
-
dateOfBirth: z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>, string, string>>;
|
|
1849
|
-
/**
|
|
1850
|
-
* Derived, non-PII signal: whether the account holder is at least 18
|
|
1851
|
-
* (see `computeIsAdult` in `user.service.ts` for the exact threshold
|
|
1852
|
-
* and the UTC-"today" choice). Computed fresh on every read — age
|
|
1853
|
-
* changes daily, so this is never stored. `undefined` when
|
|
1854
|
-
* `dateOfBirth` is unset ("unknown"), distinct from `false` ("known,
|
|
1855
|
-
* not yet 18"). Rides the same owner-only visibility as
|
|
1856
|
-
* `dateOfBirth`; a future pass may widen this specific field to
|
|
1857
|
-
* other viewers without exposing the birthdate itself, but that is
|
|
1858
|
-
* not decided here.
|
|
1859
|
-
*/
|
|
1860
|
-
isAdult: z.ZodOptional<z.ZodBoolean>;
|
|
1861
|
-
/** Avatar file id (string) or null. */
|
|
1862
|
-
avatar: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
1863
|
-
/** Named Bloom color preset (e.g. `"blue"`) or null. */
|
|
1864
|
-
color: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
1865
|
-
name: z.ZodType<UserNameResponse, z.ZodTypeDef, UserNameResponse>;
|
|
1866
|
-
verified: z.ZodOptional<z.ZodBoolean>;
|
|
1867
|
-
/**
|
|
1868
|
-
* The account's languages as full BCP-47 locales (`language-REGION`,
|
|
1869
|
-
* e.g. `es-ES`, `en-US`, `pt-BR`), ordered with the PRIMARY (UI) locale
|
|
1870
|
-
* first. `languages[0]` is the primary locale — there is no singular
|
|
1871
|
-
* `language` field.
|
|
1872
|
-
*/
|
|
1873
|
-
languages: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
1874
|
-
/**
|
|
1875
|
-
* The account's self-sovereign identifier
|
|
1876
|
-
* (`did:web:<FEDERATION_DOMAIN>:u:<userId>`). Surfaced as a `User`
|
|
1877
|
-
* virtual; present on formatted DTOs once the identity layer is live.
|
|
1878
|
-
*/
|
|
1879
|
-
did: z.ZodOptional<z.ZodString>;
|
|
1880
|
-
/**
|
|
1881
|
-
* Proven domain-ownership badges. Each is a {@link verifiedDomainSchema}
|
|
1882
|
-
* entry; present only when the account has verified at least one domain.
|
|
1883
|
-
*/
|
|
1884
|
-
verifiedDomains: z.ZodOptional<z.ZodArray<z.ZodType<import("./identity").VerifiedDomain, z.ZodTypeDef, import("./identity").VerifiedDomain>, "many">>;
|
|
1885
|
-
/**
|
|
1886
|
-
* Account-graph classification — what KIND of account this is.
|
|
1887
|
-
*
|
|
1888
|
-
* ORTHOGONAL to `type` (`local` / `federated` / `agent` / `automated`),
|
|
1889
|
-
* which says where the account lives and how it is driven; the two
|
|
1890
|
-
* coexist and neither substitutes for the other. A `channel` is a
|
|
1891
|
-
* publishing identity nobody can act as, so a consumer that renders
|
|
1892
|
-
* authored content reads THIS to tell a channel's post from a person's.
|
|
1893
|
-
*
|
|
1894
|
-
* Optional because a DTO produced from a source that never carried the
|
|
1895
|
-
* column omits it; absent should be read as `personal`, the column's
|
|
1896
|
-
* default, not as unknown.
|
|
1897
|
-
*/
|
|
1898
|
-
kind: z.ZodOptional<z.ZodEnum<["personal", "organization", "project", "bot", "channel", "community"]>>;
|
|
1899
|
-
/**
|
|
1900
|
-
* What this account is about — the field a profile screen RENDERS.
|
|
1901
|
-
*
|
|
1902
|
-
* **Ordered, primary first.** `accountCategories[0]` is the primary
|
|
1903
|
-
* category; there is deliberately no sibling `primaryCategory` field,
|
|
1904
|
-
* because two representations of one fact can disagree (see rule 2 in
|
|
1905
|
-
* `accountGraph.ts`). Nothing downstream may sort, de-duplicate or
|
|
1906
|
-
* otherwise reorder this array.
|
|
1907
|
-
*
|
|
1908
|
-
* **Ids, never labels.** Each element is a stable slug; the visible text
|
|
1909
|
-
* comes from the reader's own translation catalogue, keyed
|
|
1910
|
-
* `accounts.accountCategory.<id>`. A label on the wire would paint every
|
|
1911
|
-
* profile in the language of whoever picked it.
|
|
1912
|
-
*
|
|
1913
|
-
* Absent when the account has none — which is every `personal` account,
|
|
1914
|
-
* and any non-personal one that has not chosen. A renderer reads
|
|
1915
|
-
* `user.accountCategories ?? []`.
|
|
1916
|
-
*/
|
|
1917
|
-
accountCategories: z.ZodOptional<z.ZodEffects<z.ZodArray<z.ZodEnum<["news", "politics", "business", "startup", "finance", "crypto", "marketplace", "retail", "real_estate", "agency", "landlord", "cooperative", "architecture", "technology", "software", "ai", "security", "automation", "science", "education", "books", "health", "fitness", "sports", "gaming", "music", "film", "podcast", "art", "photography", "comedy", "food", "travel", "fashion", "home_garden", "diy", "automotive", "animals", "family", "nonprofit", "government", "community", "activism", "environment", "religion", "other"]>, "many">, ("community" | "news" | "politics" | "business" | "startup" | "finance" | "crypto" | "marketplace" | "retail" | "real_estate" | "agency" | "landlord" | "cooperative" | "architecture" | "technology" | "software" | "ai" | "security" | "automation" | "science" | "education" | "books" | "health" | "fitness" | "sports" | "gaming" | "music" | "film" | "podcast" | "art" | "photography" | "comedy" | "food" | "travel" | "fashion" | "home_garden" | "diy" | "automotive" | "animals" | "family" | "nonprofit" | "government" | "activism" | "environment" | "religion" | "other")[], ("community" | "news" | "politics" | "business" | "startup" | "finance" | "crypto" | "marketplace" | "retail" | "real_estate" | "agency" | "landlord" | "cooperative" | "architecture" | "technology" | "software" | "ai" | "security" | "automation" | "science" | "education" | "books" | "health" | "fitness" | "sports" | "gaming" | "music" | "film" | "podcast" | "art" | "photography" | "comedy" | "food" | "travel" | "fashion" | "home_garden" | "diy" | "automotive" | "animals" | "family" | "nonprofit" | "government" | "activism" | "environment" | "religion" | "other")[]>>;
|
|
1918
|
-
/**
|
|
1919
|
-
* The 3D avatar character of a `kind: 'bot'` account — what Bloom's
|
|
1920
|
-
* `Avatar` draws instead of a picture. Present ONLY on a bot's payload,
|
|
1921
|
-
* never on a person's or an organization's, so those DTOs do not grow.
|
|
1922
|
-
*/
|
|
1923
|
-
character: z.ZodOptional<z.ZodType<import("./avatarCharacter").AvatarCharacter, z.ZodTypeDef, unknown>>;
|
|
1924
|
-
/**
|
|
1925
|
-
* The authenticated viewer's relationship to this profile. Present ONLY
|
|
1926
|
-
* on single-profile fetches (`GET /profiles/username/:username`,
|
|
1927
|
-
* `GET /users/:userId`) when the request is authenticated; OMITTED for
|
|
1928
|
-
* anonymous requests and for the bulk `POST /users/by-ids` fan-out.
|
|
1929
|
-
*/
|
|
1930
|
-
relationship: z.ZodOptional<z.ZodType<UserRelationship, z.ZodTypeDef, UserRelationship>>;
|
|
1931
|
-
/**
|
|
1932
|
-
* Portable theme preference. Rides the self/session payload (cold boot),
|
|
1933
|
-
* so it is present on the current-user DTO (`GET /users/me`,
|
|
1934
|
-
* `GET /session/user/:sessionId`) and absent until the user sets it.
|
|
1935
|
-
*/
|
|
1936
|
-
userPreferences: z.ZodOptional<z.ZodObject<{
|
|
1937
|
-
displayCurrency: z.ZodOptional<z.ZodEnum<["USD", "EUR", "FAIR"]>>;
|
|
1938
|
-
}, "strip", z.ZodUnknown, z.objectOutputType<{
|
|
1939
|
-
displayCurrency: z.ZodOptional<z.ZodEnum<["USD", "EUR", "FAIR"]>>;
|
|
1940
|
-
}, z.ZodUnknown, "strip">, z.objectInputType<{
|
|
1941
|
-
displayCurrency: z.ZodOptional<z.ZodEnum<["USD", "EUR", "FAIR"]>>;
|
|
1942
|
-
}, z.ZodUnknown, "strip">>>;
|
|
1943
|
-
themePreference: z.ZodOptional<z.ZodType<ThemePreference, z.ZodTypeDef, ThemePreference>>;
|
|
1944
|
-
personalization: z.ZodOptional<z.ZodObject<{
|
|
1945
|
-
mentionMono: z.ZodObject<{
|
|
1946
|
-
allowed: z.ZodBoolean;
|
|
1947
|
-
expiresAt: z.ZodNullable<z.ZodString>;
|
|
1948
|
-
}, "strict", z.ZodTypeAny, {
|
|
1949
|
-
expiresAt: string | null;
|
|
1950
|
-
allowed: boolean;
|
|
1951
|
-
}, {
|
|
1952
|
-
expiresAt: string | null;
|
|
1953
|
-
allowed: boolean;
|
|
1954
|
-
}>;
|
|
1955
|
-
}, "strict", z.ZodTypeAny, {
|
|
1956
|
-
mentionMono: {
|
|
1957
|
-
expiresAt: string | null;
|
|
1958
|
-
allowed: boolean;
|
|
1959
|
-
};
|
|
1960
|
-
}, {
|
|
1961
|
-
mentionMono: {
|
|
1962
|
-
expiresAt: string | null;
|
|
1963
|
-
allowed: boolean;
|
|
1964
|
-
};
|
|
1965
|
-
}>>;
|
|
1966
|
-
}, z.ZodTypeAny, "passthrough"> | null | undefined;
|
|
1967
|
-
isCurrent?: boolean | undefined;
|
|
1968
|
-
}>;
|
|
465
|
+
}, z.core.$strict>;
|
|
466
|
+
}, z.core.$strict>>;
|
|
467
|
+
}, z.core.$loose>>>;
|
|
468
|
+
}, z.core.$strip>;
|
|
1969
469
|
export type DeviceLinkedSessionResponse = z.infer<typeof deviceLinkedSessionSchema>;
|
|
1970
470
|
/** Wire shape of `GET /session/device/sessions/:sessionId` (an array). */
|
|
1971
471
|
export declare const deviceLinkedSessionsResponseSchema: z.ZodArray<z.ZodObject<{
|
|
1972
472
|
sessionId: z.ZodString;
|
|
1973
473
|
isCurrent: z.ZodOptional<z.ZodBoolean>;
|
|
1974
474
|
user: z.ZodOptional<z.ZodNullable<z.ZodObject<{
|
|
1975
|
-
/** The user id as a string. Present on `formatUserResponse` output. */
|
|
1976
475
|
id: z.ZodOptional<z.ZodString>;
|
|
1977
|
-
/** Raw-document id (e.g. `GET /users/me`). Present when `id` is not. */
|
|
1978
476
|
_id: z.ZodOptional<z.ZodString>;
|
|
1979
477
|
publicKey: z.ZodOptional<z.ZodString>;
|
|
1980
478
|
username: z.ZodOptional<z.ZodString>;
|
|
@@ -1982,685 +480,89 @@ export declare const deviceLinkedSessionsResponseSchema: z.ZodArray<z.ZodObject<
|
|
|
1982
480
|
phone: z.ZodOptional<z.ZodString>;
|
|
1983
481
|
address: z.ZodOptional<z.ZodString>;
|
|
1984
482
|
birthday: z.ZodOptional<z.ZodString>;
|
|
1985
|
-
|
|
1986
|
-
* Structured date of birth, `YYYY-MM-DD`. Present only on the
|
|
1987
|
-
* account's OWN profile response (`GET /users/me`, `PUT /users/me`
|
|
1988
|
-
* with `includePrivateFields`) — never on another account's profile,
|
|
1989
|
-
* the same visibility `phone`/`address`/`birthday` already have. See
|
|
1990
|
-
* {@link dateOfBirthSchema}.
|
|
1991
|
-
*/
|
|
1992
|
-
dateOfBirth: z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>, string, string>>;
|
|
1993
|
-
/**
|
|
1994
|
-
* Derived, non-PII signal: whether the account holder is at least 18
|
|
1995
|
-
* (see `computeIsAdult` in `user.service.ts` for the exact threshold
|
|
1996
|
-
* and the UTC-"today" choice). Computed fresh on every read — age
|
|
1997
|
-
* changes daily, so this is never stored. `undefined` when
|
|
1998
|
-
* `dateOfBirth` is unset ("unknown"), distinct from `false` ("known,
|
|
1999
|
-
* not yet 18"). Rides the same owner-only visibility as
|
|
2000
|
-
* `dateOfBirth`; a future pass may widen this specific field to
|
|
2001
|
-
* other viewers without exposing the birthdate itself, but that is
|
|
2002
|
-
* not decided here.
|
|
2003
|
-
*/
|
|
483
|
+
dateOfBirth: z.ZodOptional<z.ZodString>;
|
|
2004
484
|
isAdult: z.ZodOptional<z.ZodBoolean>;
|
|
2005
|
-
/** Avatar file id (string) or null. */
|
|
2006
485
|
avatar: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
2007
|
-
/** Named Bloom color preset (e.g. `"blue"`) or null. */
|
|
2008
486
|
color: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
2009
|
-
name: z.ZodType<UserNameResponse, z.
|
|
487
|
+
name: z.ZodType<UserNameResponse, unknown, z.core.$ZodTypeInternals<UserNameResponse, unknown>>;
|
|
2010
488
|
verified: z.ZodOptional<z.ZodBoolean>;
|
|
2011
|
-
|
|
2012
|
-
* The account's languages as full BCP-47 locales (`language-REGION`,
|
|
2013
|
-
* e.g. `es-ES`, `en-US`, `pt-BR`), ordered with the PRIMARY (UI) locale
|
|
2014
|
-
* first. `languages[0]` is the primary locale — there is no singular
|
|
2015
|
-
* `language` field.
|
|
2016
|
-
*/
|
|
2017
|
-
languages: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
2018
|
-
/**
|
|
2019
|
-
* The account's self-sovereign identifier
|
|
2020
|
-
* (`did:web:<FEDERATION_DOMAIN>:u:<userId>`). Surfaced as a `User`
|
|
2021
|
-
* virtual; present on formatted DTOs once the identity layer is live.
|
|
2022
|
-
*/
|
|
489
|
+
languages: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
2023
490
|
did: z.ZodOptional<z.ZodString>;
|
|
2024
|
-
|
|
2025
|
-
|
|
2026
|
-
|
|
2027
|
-
|
|
2028
|
-
|
|
2029
|
-
|
|
2030
|
-
|
|
2031
|
-
|
|
2032
|
-
* ORTHOGONAL to `type` (`local` / `federated` / `agent` / `automated`),
|
|
2033
|
-
* which says where the account lives and how it is driven; the two
|
|
2034
|
-
* coexist and neither substitutes for the other. A `channel` is a
|
|
2035
|
-
* publishing identity nobody can act as, so a consumer that renders
|
|
2036
|
-
* authored content reads THIS to tell a channel's post from a person's.
|
|
2037
|
-
*
|
|
2038
|
-
* Optional because a DTO produced from a source that never carried the
|
|
2039
|
-
* column omits it; absent should be read as `personal`, the column's
|
|
2040
|
-
* default, not as unknown.
|
|
2041
|
-
*/
|
|
2042
|
-
kind: z.ZodOptional<z.ZodEnum<["personal", "organization", "project", "bot", "channel", "community"]>>;
|
|
2043
|
-
/**
|
|
2044
|
-
* What this account is about — the field a profile screen RENDERS.
|
|
2045
|
-
*
|
|
2046
|
-
* **Ordered, primary first.** `accountCategories[0]` is the primary
|
|
2047
|
-
* category; there is deliberately no sibling `primaryCategory` field,
|
|
2048
|
-
* because two representations of one fact can disagree (see rule 2 in
|
|
2049
|
-
* `accountGraph.ts`). Nothing downstream may sort, de-duplicate or
|
|
2050
|
-
* otherwise reorder this array.
|
|
2051
|
-
*
|
|
2052
|
-
* **Ids, never labels.** Each element is a stable slug; the visible text
|
|
2053
|
-
* comes from the reader's own translation catalogue, keyed
|
|
2054
|
-
* `accounts.accountCategory.<id>`. A label on the wire would paint every
|
|
2055
|
-
* profile in the language of whoever picked it.
|
|
2056
|
-
*
|
|
2057
|
-
* Absent when the account has none — which is every `personal` account,
|
|
2058
|
-
* and any non-personal one that has not chosen. A renderer reads
|
|
2059
|
-
* `user.accountCategories ?? []`.
|
|
2060
|
-
*/
|
|
2061
|
-
accountCategories: z.ZodOptional<z.ZodEffects<z.ZodArray<z.ZodEnum<["news", "politics", "business", "startup", "finance", "crypto", "marketplace", "retail", "real_estate", "agency", "landlord", "cooperative", "architecture", "technology", "software", "ai", "security", "automation", "science", "education", "books", "health", "fitness", "sports", "gaming", "music", "film", "podcast", "art", "photography", "comedy", "food", "travel", "fashion", "home_garden", "diy", "automotive", "animals", "family", "nonprofit", "government", "community", "activism", "environment", "religion", "other"]>, "many">, ("community" | "news" | "politics" | "business" | "startup" | "finance" | "crypto" | "marketplace" | "retail" | "real_estate" | "agency" | "landlord" | "cooperative" | "architecture" | "technology" | "software" | "ai" | "security" | "automation" | "science" | "education" | "books" | "health" | "fitness" | "sports" | "gaming" | "music" | "film" | "podcast" | "art" | "photography" | "comedy" | "food" | "travel" | "fashion" | "home_garden" | "diy" | "automotive" | "animals" | "family" | "nonprofit" | "government" | "activism" | "environment" | "religion" | "other")[], ("community" | "news" | "politics" | "business" | "startup" | "finance" | "crypto" | "marketplace" | "retail" | "real_estate" | "agency" | "landlord" | "cooperative" | "architecture" | "technology" | "software" | "ai" | "security" | "automation" | "science" | "education" | "books" | "health" | "fitness" | "sports" | "gaming" | "music" | "film" | "podcast" | "art" | "photography" | "comedy" | "food" | "travel" | "fashion" | "home_garden" | "diy" | "automotive" | "animals" | "family" | "nonprofit" | "government" | "activism" | "environment" | "religion" | "other")[]>>;
|
|
2062
|
-
/**
|
|
2063
|
-
* The 3D avatar character of a `kind: 'bot'` account — what Bloom's
|
|
2064
|
-
* `Avatar` draws instead of a picture. Present ONLY on a bot's payload,
|
|
2065
|
-
* never on a person's or an organization's, so those DTOs do not grow.
|
|
2066
|
-
*/
|
|
2067
|
-
character: z.ZodOptional<z.ZodType<import("./avatarCharacter").AvatarCharacter, z.ZodTypeDef, unknown>>;
|
|
2068
|
-
/**
|
|
2069
|
-
* The authenticated viewer's relationship to this profile. Present ONLY
|
|
2070
|
-
* on single-profile fetches (`GET /profiles/username/:username`,
|
|
2071
|
-
* `GET /users/:userId`) when the request is authenticated; OMITTED for
|
|
2072
|
-
* anonymous requests and for the bulk `POST /users/by-ids` fan-out.
|
|
2073
|
-
*/
|
|
2074
|
-
relationship: z.ZodOptional<z.ZodType<UserRelationship, z.ZodTypeDef, UserRelationship>>;
|
|
2075
|
-
/**
|
|
2076
|
-
* Portable theme preference. Rides the self/session payload (cold boot),
|
|
2077
|
-
* so it is present on the current-user DTO (`GET /users/me`,
|
|
2078
|
-
* `GET /session/user/:sessionId`) and absent until the user sets it.
|
|
2079
|
-
*/
|
|
2080
|
-
userPreferences: z.ZodOptional<z.ZodObject<{
|
|
2081
|
-
displayCurrency: z.ZodOptional<z.ZodEnum<["USD", "EUR", "FAIR"]>>;
|
|
2082
|
-
}, "strip", z.ZodUnknown, z.objectOutputType<{
|
|
2083
|
-
displayCurrency: z.ZodOptional<z.ZodEnum<["USD", "EUR", "FAIR"]>>;
|
|
2084
|
-
}, z.ZodUnknown, "strip">, z.objectInputType<{
|
|
2085
|
-
displayCurrency: z.ZodOptional<z.ZodEnum<["USD", "EUR", "FAIR"]>>;
|
|
2086
|
-
}, z.ZodUnknown, "strip">>>;
|
|
2087
|
-
themePreference: z.ZodOptional<z.ZodType<ThemePreference, z.ZodTypeDef, ThemePreference>>;
|
|
2088
|
-
personalization: z.ZodOptional<z.ZodObject<{
|
|
2089
|
-
mentionMono: z.ZodObject<{
|
|
2090
|
-
allowed: z.ZodBoolean;
|
|
2091
|
-
expiresAt: z.ZodNullable<z.ZodString>;
|
|
2092
|
-
}, "strict", z.ZodTypeAny, {
|
|
2093
|
-
expiresAt: string | null;
|
|
2094
|
-
allowed: boolean;
|
|
2095
|
-
}, {
|
|
2096
|
-
expiresAt: string | null;
|
|
2097
|
-
allowed: boolean;
|
|
2098
|
-
}>;
|
|
2099
|
-
}, "strict", z.ZodTypeAny, {
|
|
2100
|
-
mentionMono: {
|
|
2101
|
-
expiresAt: string | null;
|
|
2102
|
-
allowed: boolean;
|
|
2103
|
-
};
|
|
2104
|
-
}, {
|
|
2105
|
-
mentionMono: {
|
|
2106
|
-
expiresAt: string | null;
|
|
2107
|
-
allowed: boolean;
|
|
2108
|
-
};
|
|
491
|
+
verifiedDomains: z.ZodOptional<z.ZodArray<z.ZodType<import("./identity").VerifiedDomain, unknown, z.core.$ZodTypeInternals<import("./identity").VerifiedDomain, unknown>>>>;
|
|
492
|
+
kind: z.ZodOptional<z.ZodEnum<{
|
|
493
|
+
personal: "personal";
|
|
494
|
+
organization: "organization";
|
|
495
|
+
project: "project";
|
|
496
|
+
bot: "bot";
|
|
497
|
+
channel: "channel";
|
|
498
|
+
community: "community";
|
|
2109
499
|
}>>;
|
|
2110
|
-
|
|
2111
|
-
|
|
2112
|
-
|
|
2113
|
-
|
|
2114
|
-
|
|
2115
|
-
|
|
2116
|
-
|
|
2117
|
-
|
|
2118
|
-
|
|
2119
|
-
|
|
2120
|
-
|
|
2121
|
-
|
|
2122
|
-
|
|
2123
|
-
|
|
2124
|
-
|
|
2125
|
-
|
|
2126
|
-
|
|
2127
|
-
|
|
2128
|
-
|
|
2129
|
-
|
|
2130
|
-
|
|
2131
|
-
|
|
2132
|
-
|
|
2133
|
-
|
|
2134
|
-
|
|
2135
|
-
|
|
2136
|
-
|
|
2137
|
-
|
|
2138
|
-
|
|
2139
|
-
|
|
2140
|
-
|
|
2141
|
-
|
|
2142
|
-
|
|
2143
|
-
|
|
2144
|
-
|
|
2145
|
-
|
|
2146
|
-
|
|
2147
|
-
|
|
2148
|
-
|
|
2149
|
-
|
|
2150
|
-
|
|
2151
|
-
|
|
2152
|
-
|
|
2153
|
-
|
|
2154
|
-
|
|
2155
|
-
|
|
2156
|
-
|
|
2157
|
-
|
|
2158
|
-
|
|
2159
|
-
|
|
2160
|
-
/**
|
|
2161
|
-
* Proven domain-ownership badges. Each is a {@link verifiedDomainSchema}
|
|
2162
|
-
* entry; present only when the account has verified at least one domain.
|
|
2163
|
-
*/
|
|
2164
|
-
verifiedDomains: z.ZodOptional<z.ZodArray<z.ZodType<import("./identity").VerifiedDomain, z.ZodTypeDef, import("./identity").VerifiedDomain>, "many">>;
|
|
2165
|
-
/**
|
|
2166
|
-
* Account-graph classification — what KIND of account this is.
|
|
2167
|
-
*
|
|
2168
|
-
* ORTHOGONAL to `type` (`local` / `federated` / `agent` / `automated`),
|
|
2169
|
-
* which says where the account lives and how it is driven; the two
|
|
2170
|
-
* coexist and neither substitutes for the other. A `channel` is a
|
|
2171
|
-
* publishing identity nobody can act as, so a consumer that renders
|
|
2172
|
-
* authored content reads THIS to tell a channel's post from a person's.
|
|
2173
|
-
*
|
|
2174
|
-
* Optional because a DTO produced from a source that never carried the
|
|
2175
|
-
* column omits it; absent should be read as `personal`, the column's
|
|
2176
|
-
* default, not as unknown.
|
|
2177
|
-
*/
|
|
2178
|
-
kind: z.ZodOptional<z.ZodEnum<["personal", "organization", "project", "bot", "channel", "community"]>>;
|
|
2179
|
-
/**
|
|
2180
|
-
* What this account is about — the field a profile screen RENDERS.
|
|
2181
|
-
*
|
|
2182
|
-
* **Ordered, primary first.** `accountCategories[0]` is the primary
|
|
2183
|
-
* category; there is deliberately no sibling `primaryCategory` field,
|
|
2184
|
-
* because two representations of one fact can disagree (see rule 2 in
|
|
2185
|
-
* `accountGraph.ts`). Nothing downstream may sort, de-duplicate or
|
|
2186
|
-
* otherwise reorder this array.
|
|
2187
|
-
*
|
|
2188
|
-
* **Ids, never labels.** Each element is a stable slug; the visible text
|
|
2189
|
-
* comes from the reader's own translation catalogue, keyed
|
|
2190
|
-
* `accounts.accountCategory.<id>`. A label on the wire would paint every
|
|
2191
|
-
* profile in the language of whoever picked it.
|
|
2192
|
-
*
|
|
2193
|
-
* Absent when the account has none — which is every `personal` account,
|
|
2194
|
-
* and any non-personal one that has not chosen. A renderer reads
|
|
2195
|
-
* `user.accountCategories ?? []`.
|
|
2196
|
-
*/
|
|
2197
|
-
accountCategories: z.ZodOptional<z.ZodEffects<z.ZodArray<z.ZodEnum<["news", "politics", "business", "startup", "finance", "crypto", "marketplace", "retail", "real_estate", "agency", "landlord", "cooperative", "architecture", "technology", "software", "ai", "security", "automation", "science", "education", "books", "health", "fitness", "sports", "gaming", "music", "film", "podcast", "art", "photography", "comedy", "food", "travel", "fashion", "home_garden", "diy", "automotive", "animals", "family", "nonprofit", "government", "community", "activism", "environment", "religion", "other"]>, "many">, ("community" | "news" | "politics" | "business" | "startup" | "finance" | "crypto" | "marketplace" | "retail" | "real_estate" | "agency" | "landlord" | "cooperative" | "architecture" | "technology" | "software" | "ai" | "security" | "automation" | "science" | "education" | "books" | "health" | "fitness" | "sports" | "gaming" | "music" | "film" | "podcast" | "art" | "photography" | "comedy" | "food" | "travel" | "fashion" | "home_garden" | "diy" | "automotive" | "animals" | "family" | "nonprofit" | "government" | "activism" | "environment" | "religion" | "other")[], ("community" | "news" | "politics" | "business" | "startup" | "finance" | "crypto" | "marketplace" | "retail" | "real_estate" | "agency" | "landlord" | "cooperative" | "architecture" | "technology" | "software" | "ai" | "security" | "automation" | "science" | "education" | "books" | "health" | "fitness" | "sports" | "gaming" | "music" | "film" | "podcast" | "art" | "photography" | "comedy" | "food" | "travel" | "fashion" | "home_garden" | "diy" | "automotive" | "animals" | "family" | "nonprofit" | "government" | "activism" | "environment" | "religion" | "other")[]>>;
|
|
2198
|
-
/**
|
|
2199
|
-
* The 3D avatar character of a `kind: 'bot'` account — what Bloom's
|
|
2200
|
-
* `Avatar` draws instead of a picture. Present ONLY on a bot's payload,
|
|
2201
|
-
* never on a person's or an organization's, so those DTOs do not grow.
|
|
2202
|
-
*/
|
|
2203
|
-
character: z.ZodOptional<z.ZodType<import("./avatarCharacter").AvatarCharacter, z.ZodTypeDef, unknown>>;
|
|
2204
|
-
/**
|
|
2205
|
-
* The authenticated viewer's relationship to this profile. Present ONLY
|
|
2206
|
-
* on single-profile fetches (`GET /profiles/username/:username`,
|
|
2207
|
-
* `GET /users/:userId`) when the request is authenticated; OMITTED for
|
|
2208
|
-
* anonymous requests and for the bulk `POST /users/by-ids` fan-out.
|
|
2209
|
-
*/
|
|
2210
|
-
relationship: z.ZodOptional<z.ZodType<UserRelationship, z.ZodTypeDef, UserRelationship>>;
|
|
2211
|
-
/**
|
|
2212
|
-
* Portable theme preference. Rides the self/session payload (cold boot),
|
|
2213
|
-
* so it is present on the current-user DTO (`GET /users/me`,
|
|
2214
|
-
* `GET /session/user/:sessionId`) and absent until the user sets it.
|
|
2215
|
-
*/
|
|
500
|
+
accountCategories: z.ZodOptional<z.ZodArray<z.ZodEnum<{
|
|
501
|
+
community: "community";
|
|
502
|
+
news: "news";
|
|
503
|
+
politics: "politics";
|
|
504
|
+
business: "business";
|
|
505
|
+
startup: "startup";
|
|
506
|
+
finance: "finance";
|
|
507
|
+
crypto: "crypto";
|
|
508
|
+
marketplace: "marketplace";
|
|
509
|
+
retail: "retail";
|
|
510
|
+
real_estate: "real_estate";
|
|
511
|
+
agency: "agency";
|
|
512
|
+
landlord: "landlord";
|
|
513
|
+
cooperative: "cooperative";
|
|
514
|
+
architecture: "architecture";
|
|
515
|
+
technology: "technology";
|
|
516
|
+
software: "software";
|
|
517
|
+
ai: "ai";
|
|
518
|
+
security: "security";
|
|
519
|
+
automation: "automation";
|
|
520
|
+
science: "science";
|
|
521
|
+
education: "education";
|
|
522
|
+
books: "books";
|
|
523
|
+
health: "health";
|
|
524
|
+
fitness: "fitness";
|
|
525
|
+
sports: "sports";
|
|
526
|
+
gaming: "gaming";
|
|
527
|
+
music: "music";
|
|
528
|
+
film: "film";
|
|
529
|
+
podcast: "podcast";
|
|
530
|
+
art: "art";
|
|
531
|
+
photography: "photography";
|
|
532
|
+
comedy: "comedy";
|
|
533
|
+
food: "food";
|
|
534
|
+
travel: "travel";
|
|
535
|
+
fashion: "fashion";
|
|
536
|
+
home_garden: "home_garden";
|
|
537
|
+
diy: "diy";
|
|
538
|
+
automotive: "automotive";
|
|
539
|
+
animals: "animals";
|
|
540
|
+
family: "family";
|
|
541
|
+
nonprofit: "nonprofit";
|
|
542
|
+
government: "government";
|
|
543
|
+
activism: "activism";
|
|
544
|
+
environment: "environment";
|
|
545
|
+
religion: "religion";
|
|
546
|
+
other: "other";
|
|
547
|
+
}>>>;
|
|
548
|
+
character: z.ZodOptional<z.ZodType<import("./avatarCharacter").AvatarCharacter, unknown, z.core.$ZodTypeInternals<import("./avatarCharacter").AvatarCharacter, unknown>>>;
|
|
549
|
+
relationship: z.ZodOptional<z.ZodType<UserRelationship, unknown, z.core.$ZodTypeInternals<UserRelationship, unknown>>>;
|
|
2216
550
|
userPreferences: z.ZodOptional<z.ZodObject<{
|
|
2217
|
-
displayCurrency: z.ZodOptional<z.ZodEnum<
|
|
2218
|
-
|
|
2219
|
-
|
|
2220
|
-
|
|
2221
|
-
|
|
2222
|
-
}, z.ZodUnknown
|
|
2223
|
-
themePreference: z.ZodOptional<z.ZodType<ThemePreference, z.
|
|
551
|
+
displayCurrency: z.ZodOptional<z.ZodEnum<{
|
|
552
|
+
USD: "USD";
|
|
553
|
+
EUR: "EUR";
|
|
554
|
+
FAIR: "FAIR";
|
|
555
|
+
}>>;
|
|
556
|
+
}, z.core.$catchall<z.ZodUnknown>>>;
|
|
557
|
+
themePreference: z.ZodOptional<z.ZodType<ThemePreference, unknown, z.core.$ZodTypeInternals<ThemePreference, unknown>>>;
|
|
2224
558
|
personalization: z.ZodOptional<z.ZodObject<{
|
|
2225
559
|
mentionMono: z.ZodObject<{
|
|
2226
560
|
allowed: z.ZodBoolean;
|
|
2227
561
|
expiresAt: z.ZodNullable<z.ZodString>;
|
|
2228
|
-
},
|
|
2229
|
-
|
|
2230
|
-
|
|
2231
|
-
|
|
2232
|
-
expiresAt: string | null;
|
|
2233
|
-
allowed: boolean;
|
|
2234
|
-
}>;
|
|
2235
|
-
}, "strict", z.ZodTypeAny, {
|
|
2236
|
-
mentionMono: {
|
|
2237
|
-
expiresAt: string | null;
|
|
2238
|
-
allowed: boolean;
|
|
2239
|
-
};
|
|
2240
|
-
}, {
|
|
2241
|
-
mentionMono: {
|
|
2242
|
-
expiresAt: string | null;
|
|
2243
|
-
allowed: boolean;
|
|
2244
|
-
};
|
|
2245
|
-
}>>;
|
|
2246
|
-
}, z.ZodTypeAny, "passthrough">, z.objectInputType<{
|
|
2247
|
-
/** The user id as a string. Present on `formatUserResponse` output. */
|
|
2248
|
-
id: z.ZodOptional<z.ZodString>;
|
|
2249
|
-
/** Raw-document id (e.g. `GET /users/me`). Present when `id` is not. */
|
|
2250
|
-
_id: z.ZodOptional<z.ZodString>;
|
|
2251
|
-
publicKey: z.ZodOptional<z.ZodString>;
|
|
2252
|
-
username: z.ZodOptional<z.ZodString>;
|
|
2253
|
-
email: z.ZodOptional<z.ZodString>;
|
|
2254
|
-
phone: z.ZodOptional<z.ZodString>;
|
|
2255
|
-
address: z.ZodOptional<z.ZodString>;
|
|
2256
|
-
birthday: z.ZodOptional<z.ZodString>;
|
|
2257
|
-
/**
|
|
2258
|
-
* Structured date of birth, `YYYY-MM-DD`. Present only on the
|
|
2259
|
-
* account's OWN profile response (`GET /users/me`, `PUT /users/me`
|
|
2260
|
-
* with `includePrivateFields`) — never on another account's profile,
|
|
2261
|
-
* the same visibility `phone`/`address`/`birthday` already have. See
|
|
2262
|
-
* {@link dateOfBirthSchema}.
|
|
2263
|
-
*/
|
|
2264
|
-
dateOfBirth: z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>, string, string>>;
|
|
2265
|
-
/**
|
|
2266
|
-
* Derived, non-PII signal: whether the account holder is at least 18
|
|
2267
|
-
* (see `computeIsAdult` in `user.service.ts` for the exact threshold
|
|
2268
|
-
* and the UTC-"today" choice). Computed fresh on every read — age
|
|
2269
|
-
* changes daily, so this is never stored. `undefined` when
|
|
2270
|
-
* `dateOfBirth` is unset ("unknown"), distinct from `false` ("known,
|
|
2271
|
-
* not yet 18"). Rides the same owner-only visibility as
|
|
2272
|
-
* `dateOfBirth`; a future pass may widen this specific field to
|
|
2273
|
-
* other viewers without exposing the birthdate itself, but that is
|
|
2274
|
-
* not decided here.
|
|
2275
|
-
*/
|
|
2276
|
-
isAdult: z.ZodOptional<z.ZodBoolean>;
|
|
2277
|
-
/** Avatar file id (string) or null. */
|
|
2278
|
-
avatar: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
2279
|
-
/** Named Bloom color preset (e.g. `"blue"`) or null. */
|
|
2280
|
-
color: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
2281
|
-
name: z.ZodType<UserNameResponse, z.ZodTypeDef, UserNameResponse>;
|
|
2282
|
-
verified: z.ZodOptional<z.ZodBoolean>;
|
|
2283
|
-
/**
|
|
2284
|
-
* The account's languages as full BCP-47 locales (`language-REGION`,
|
|
2285
|
-
* e.g. `es-ES`, `en-US`, `pt-BR`), ordered with the PRIMARY (UI) locale
|
|
2286
|
-
* first. `languages[0]` is the primary locale — there is no singular
|
|
2287
|
-
* `language` field.
|
|
2288
|
-
*/
|
|
2289
|
-
languages: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
2290
|
-
/**
|
|
2291
|
-
* The account's self-sovereign identifier
|
|
2292
|
-
* (`did:web:<FEDERATION_DOMAIN>:u:<userId>`). Surfaced as a `User`
|
|
2293
|
-
* virtual; present on formatted DTOs once the identity layer is live.
|
|
2294
|
-
*/
|
|
2295
|
-
did: z.ZodOptional<z.ZodString>;
|
|
2296
|
-
/**
|
|
2297
|
-
* Proven domain-ownership badges. Each is a {@link verifiedDomainSchema}
|
|
2298
|
-
* entry; present only when the account has verified at least one domain.
|
|
2299
|
-
*/
|
|
2300
|
-
verifiedDomains: z.ZodOptional<z.ZodArray<z.ZodType<import("./identity").VerifiedDomain, z.ZodTypeDef, import("./identity").VerifiedDomain>, "many">>;
|
|
2301
|
-
/**
|
|
2302
|
-
* Account-graph classification — what KIND of account this is.
|
|
2303
|
-
*
|
|
2304
|
-
* ORTHOGONAL to `type` (`local` / `federated` / `agent` / `automated`),
|
|
2305
|
-
* which says where the account lives and how it is driven; the two
|
|
2306
|
-
* coexist and neither substitutes for the other. A `channel` is a
|
|
2307
|
-
* publishing identity nobody can act as, so a consumer that renders
|
|
2308
|
-
* authored content reads THIS to tell a channel's post from a person's.
|
|
2309
|
-
*
|
|
2310
|
-
* Optional because a DTO produced from a source that never carried the
|
|
2311
|
-
* column omits it; absent should be read as `personal`, the column's
|
|
2312
|
-
* default, not as unknown.
|
|
2313
|
-
*/
|
|
2314
|
-
kind: z.ZodOptional<z.ZodEnum<["personal", "organization", "project", "bot", "channel", "community"]>>;
|
|
2315
|
-
/**
|
|
2316
|
-
* What this account is about — the field a profile screen RENDERS.
|
|
2317
|
-
*
|
|
2318
|
-
* **Ordered, primary first.** `accountCategories[0]` is the primary
|
|
2319
|
-
* category; there is deliberately no sibling `primaryCategory` field,
|
|
2320
|
-
* because two representations of one fact can disagree (see rule 2 in
|
|
2321
|
-
* `accountGraph.ts`). Nothing downstream may sort, de-duplicate or
|
|
2322
|
-
* otherwise reorder this array.
|
|
2323
|
-
*
|
|
2324
|
-
* **Ids, never labels.** Each element is a stable slug; the visible text
|
|
2325
|
-
* comes from the reader's own translation catalogue, keyed
|
|
2326
|
-
* `accounts.accountCategory.<id>`. A label on the wire would paint every
|
|
2327
|
-
* profile in the language of whoever picked it.
|
|
2328
|
-
*
|
|
2329
|
-
* Absent when the account has none — which is every `personal` account,
|
|
2330
|
-
* and any non-personal one that has not chosen. A renderer reads
|
|
2331
|
-
* `user.accountCategories ?? []`.
|
|
2332
|
-
*/
|
|
2333
|
-
accountCategories: z.ZodOptional<z.ZodEffects<z.ZodArray<z.ZodEnum<["news", "politics", "business", "startup", "finance", "crypto", "marketplace", "retail", "real_estate", "agency", "landlord", "cooperative", "architecture", "technology", "software", "ai", "security", "automation", "science", "education", "books", "health", "fitness", "sports", "gaming", "music", "film", "podcast", "art", "photography", "comedy", "food", "travel", "fashion", "home_garden", "diy", "automotive", "animals", "family", "nonprofit", "government", "community", "activism", "environment", "religion", "other"]>, "many">, ("community" | "news" | "politics" | "business" | "startup" | "finance" | "crypto" | "marketplace" | "retail" | "real_estate" | "agency" | "landlord" | "cooperative" | "architecture" | "technology" | "software" | "ai" | "security" | "automation" | "science" | "education" | "books" | "health" | "fitness" | "sports" | "gaming" | "music" | "film" | "podcast" | "art" | "photography" | "comedy" | "food" | "travel" | "fashion" | "home_garden" | "diy" | "automotive" | "animals" | "family" | "nonprofit" | "government" | "activism" | "environment" | "religion" | "other")[], ("community" | "news" | "politics" | "business" | "startup" | "finance" | "crypto" | "marketplace" | "retail" | "real_estate" | "agency" | "landlord" | "cooperative" | "architecture" | "technology" | "software" | "ai" | "security" | "automation" | "science" | "education" | "books" | "health" | "fitness" | "sports" | "gaming" | "music" | "film" | "podcast" | "art" | "photography" | "comedy" | "food" | "travel" | "fashion" | "home_garden" | "diy" | "automotive" | "animals" | "family" | "nonprofit" | "government" | "activism" | "environment" | "religion" | "other")[]>>;
|
|
2334
|
-
/**
|
|
2335
|
-
* The 3D avatar character of a `kind: 'bot'` account — what Bloom's
|
|
2336
|
-
* `Avatar` draws instead of a picture. Present ONLY on a bot's payload,
|
|
2337
|
-
* never on a person's or an organization's, so those DTOs do not grow.
|
|
2338
|
-
*/
|
|
2339
|
-
character: z.ZodOptional<z.ZodType<import("./avatarCharacter").AvatarCharacter, z.ZodTypeDef, unknown>>;
|
|
2340
|
-
/**
|
|
2341
|
-
* The authenticated viewer's relationship to this profile. Present ONLY
|
|
2342
|
-
* on single-profile fetches (`GET /profiles/username/:username`,
|
|
2343
|
-
* `GET /users/:userId`) when the request is authenticated; OMITTED for
|
|
2344
|
-
* anonymous requests and for the bulk `POST /users/by-ids` fan-out.
|
|
2345
|
-
*/
|
|
2346
|
-
relationship: z.ZodOptional<z.ZodType<UserRelationship, z.ZodTypeDef, UserRelationship>>;
|
|
2347
|
-
/**
|
|
2348
|
-
* Portable theme preference. Rides the self/session payload (cold boot),
|
|
2349
|
-
* so it is present on the current-user DTO (`GET /users/me`,
|
|
2350
|
-
* `GET /session/user/:sessionId`) and absent until the user sets it.
|
|
2351
|
-
*/
|
|
2352
|
-
userPreferences: z.ZodOptional<z.ZodObject<{
|
|
2353
|
-
displayCurrency: z.ZodOptional<z.ZodEnum<["USD", "EUR", "FAIR"]>>;
|
|
2354
|
-
}, "strip", z.ZodUnknown, z.objectOutputType<{
|
|
2355
|
-
displayCurrency: z.ZodOptional<z.ZodEnum<["USD", "EUR", "FAIR"]>>;
|
|
2356
|
-
}, z.ZodUnknown, "strip">, z.objectInputType<{
|
|
2357
|
-
displayCurrency: z.ZodOptional<z.ZodEnum<["USD", "EUR", "FAIR"]>>;
|
|
2358
|
-
}, z.ZodUnknown, "strip">>>;
|
|
2359
|
-
themePreference: z.ZodOptional<z.ZodType<ThemePreference, z.ZodTypeDef, ThemePreference>>;
|
|
2360
|
-
personalization: z.ZodOptional<z.ZodObject<{
|
|
2361
|
-
mentionMono: z.ZodObject<{
|
|
2362
|
-
allowed: z.ZodBoolean;
|
|
2363
|
-
expiresAt: z.ZodNullable<z.ZodString>;
|
|
2364
|
-
}, "strict", z.ZodTypeAny, {
|
|
2365
|
-
expiresAt: string | null;
|
|
2366
|
-
allowed: boolean;
|
|
2367
|
-
}, {
|
|
2368
|
-
expiresAt: string | null;
|
|
2369
|
-
allowed: boolean;
|
|
2370
|
-
}>;
|
|
2371
|
-
}, "strict", z.ZodTypeAny, {
|
|
2372
|
-
mentionMono: {
|
|
2373
|
-
expiresAt: string | null;
|
|
2374
|
-
allowed: boolean;
|
|
2375
|
-
};
|
|
2376
|
-
}, {
|
|
2377
|
-
mentionMono: {
|
|
2378
|
-
expiresAt: string | null;
|
|
2379
|
-
allowed: boolean;
|
|
2380
|
-
};
|
|
2381
|
-
}>>;
|
|
2382
|
-
}, z.ZodTypeAny, "passthrough">>>>;
|
|
2383
|
-
}, "strip", z.ZodTypeAny, {
|
|
2384
|
-
sessionId: string;
|
|
2385
|
-
user?: z.objectOutputType<{
|
|
2386
|
-
/** The user id as a string. Present on `formatUserResponse` output. */
|
|
2387
|
-
id: z.ZodOptional<z.ZodString>;
|
|
2388
|
-
/** Raw-document id (e.g. `GET /users/me`). Present when `id` is not. */
|
|
2389
|
-
_id: z.ZodOptional<z.ZodString>;
|
|
2390
|
-
publicKey: z.ZodOptional<z.ZodString>;
|
|
2391
|
-
username: z.ZodOptional<z.ZodString>;
|
|
2392
|
-
email: z.ZodOptional<z.ZodString>;
|
|
2393
|
-
phone: z.ZodOptional<z.ZodString>;
|
|
2394
|
-
address: z.ZodOptional<z.ZodString>;
|
|
2395
|
-
birthday: z.ZodOptional<z.ZodString>;
|
|
2396
|
-
/**
|
|
2397
|
-
* Structured date of birth, `YYYY-MM-DD`. Present only on the
|
|
2398
|
-
* account's OWN profile response (`GET /users/me`, `PUT /users/me`
|
|
2399
|
-
* with `includePrivateFields`) — never on another account's profile,
|
|
2400
|
-
* the same visibility `phone`/`address`/`birthday` already have. See
|
|
2401
|
-
* {@link dateOfBirthSchema}.
|
|
2402
|
-
*/
|
|
2403
|
-
dateOfBirth: z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>, string, string>>;
|
|
2404
|
-
/**
|
|
2405
|
-
* Derived, non-PII signal: whether the account holder is at least 18
|
|
2406
|
-
* (see `computeIsAdult` in `user.service.ts` for the exact threshold
|
|
2407
|
-
* and the UTC-"today" choice). Computed fresh on every read — age
|
|
2408
|
-
* changes daily, so this is never stored. `undefined` when
|
|
2409
|
-
* `dateOfBirth` is unset ("unknown"), distinct from `false` ("known,
|
|
2410
|
-
* not yet 18"). Rides the same owner-only visibility as
|
|
2411
|
-
* `dateOfBirth`; a future pass may widen this specific field to
|
|
2412
|
-
* other viewers without exposing the birthdate itself, but that is
|
|
2413
|
-
* not decided here.
|
|
2414
|
-
*/
|
|
2415
|
-
isAdult: z.ZodOptional<z.ZodBoolean>;
|
|
2416
|
-
/** Avatar file id (string) or null. */
|
|
2417
|
-
avatar: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
2418
|
-
/** Named Bloom color preset (e.g. `"blue"`) or null. */
|
|
2419
|
-
color: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
2420
|
-
name: z.ZodType<UserNameResponse, z.ZodTypeDef, UserNameResponse>;
|
|
2421
|
-
verified: z.ZodOptional<z.ZodBoolean>;
|
|
2422
|
-
/**
|
|
2423
|
-
* The account's languages as full BCP-47 locales (`language-REGION`,
|
|
2424
|
-
* e.g. `es-ES`, `en-US`, `pt-BR`), ordered with the PRIMARY (UI) locale
|
|
2425
|
-
* first. `languages[0]` is the primary locale — there is no singular
|
|
2426
|
-
* `language` field.
|
|
2427
|
-
*/
|
|
2428
|
-
languages: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
2429
|
-
/**
|
|
2430
|
-
* The account's self-sovereign identifier
|
|
2431
|
-
* (`did:web:<FEDERATION_DOMAIN>:u:<userId>`). Surfaced as a `User`
|
|
2432
|
-
* virtual; present on formatted DTOs once the identity layer is live.
|
|
2433
|
-
*/
|
|
2434
|
-
did: z.ZodOptional<z.ZodString>;
|
|
2435
|
-
/**
|
|
2436
|
-
* Proven domain-ownership badges. Each is a {@link verifiedDomainSchema}
|
|
2437
|
-
* entry; present only when the account has verified at least one domain.
|
|
2438
|
-
*/
|
|
2439
|
-
verifiedDomains: z.ZodOptional<z.ZodArray<z.ZodType<import("./identity").VerifiedDomain, z.ZodTypeDef, import("./identity").VerifiedDomain>, "many">>;
|
|
2440
|
-
/**
|
|
2441
|
-
* Account-graph classification — what KIND of account this is.
|
|
2442
|
-
*
|
|
2443
|
-
* ORTHOGONAL to `type` (`local` / `federated` / `agent` / `automated`),
|
|
2444
|
-
* which says where the account lives and how it is driven; the two
|
|
2445
|
-
* coexist and neither substitutes for the other. A `channel` is a
|
|
2446
|
-
* publishing identity nobody can act as, so a consumer that renders
|
|
2447
|
-
* authored content reads THIS to tell a channel's post from a person's.
|
|
2448
|
-
*
|
|
2449
|
-
* Optional because a DTO produced from a source that never carried the
|
|
2450
|
-
* column omits it; absent should be read as `personal`, the column's
|
|
2451
|
-
* default, not as unknown.
|
|
2452
|
-
*/
|
|
2453
|
-
kind: z.ZodOptional<z.ZodEnum<["personal", "organization", "project", "bot", "channel", "community"]>>;
|
|
2454
|
-
/**
|
|
2455
|
-
* What this account is about — the field a profile screen RENDERS.
|
|
2456
|
-
*
|
|
2457
|
-
* **Ordered, primary first.** `accountCategories[0]` is the primary
|
|
2458
|
-
* category; there is deliberately no sibling `primaryCategory` field,
|
|
2459
|
-
* because two representations of one fact can disagree (see rule 2 in
|
|
2460
|
-
* `accountGraph.ts`). Nothing downstream may sort, de-duplicate or
|
|
2461
|
-
* otherwise reorder this array.
|
|
2462
|
-
*
|
|
2463
|
-
* **Ids, never labels.** Each element is a stable slug; the visible text
|
|
2464
|
-
* comes from the reader's own translation catalogue, keyed
|
|
2465
|
-
* `accounts.accountCategory.<id>`. A label on the wire would paint every
|
|
2466
|
-
* profile in the language of whoever picked it.
|
|
2467
|
-
*
|
|
2468
|
-
* Absent when the account has none — which is every `personal` account,
|
|
2469
|
-
* and any non-personal one that has not chosen. A renderer reads
|
|
2470
|
-
* `user.accountCategories ?? []`.
|
|
2471
|
-
*/
|
|
2472
|
-
accountCategories: z.ZodOptional<z.ZodEffects<z.ZodArray<z.ZodEnum<["news", "politics", "business", "startup", "finance", "crypto", "marketplace", "retail", "real_estate", "agency", "landlord", "cooperative", "architecture", "technology", "software", "ai", "security", "automation", "science", "education", "books", "health", "fitness", "sports", "gaming", "music", "film", "podcast", "art", "photography", "comedy", "food", "travel", "fashion", "home_garden", "diy", "automotive", "animals", "family", "nonprofit", "government", "community", "activism", "environment", "religion", "other"]>, "many">, ("community" | "news" | "politics" | "business" | "startup" | "finance" | "crypto" | "marketplace" | "retail" | "real_estate" | "agency" | "landlord" | "cooperative" | "architecture" | "technology" | "software" | "ai" | "security" | "automation" | "science" | "education" | "books" | "health" | "fitness" | "sports" | "gaming" | "music" | "film" | "podcast" | "art" | "photography" | "comedy" | "food" | "travel" | "fashion" | "home_garden" | "diy" | "automotive" | "animals" | "family" | "nonprofit" | "government" | "activism" | "environment" | "religion" | "other")[], ("community" | "news" | "politics" | "business" | "startup" | "finance" | "crypto" | "marketplace" | "retail" | "real_estate" | "agency" | "landlord" | "cooperative" | "architecture" | "technology" | "software" | "ai" | "security" | "automation" | "science" | "education" | "books" | "health" | "fitness" | "sports" | "gaming" | "music" | "film" | "podcast" | "art" | "photography" | "comedy" | "food" | "travel" | "fashion" | "home_garden" | "diy" | "automotive" | "animals" | "family" | "nonprofit" | "government" | "activism" | "environment" | "religion" | "other")[]>>;
|
|
2473
|
-
/**
|
|
2474
|
-
* The 3D avatar character of a `kind: 'bot'` account — what Bloom's
|
|
2475
|
-
* `Avatar` draws instead of a picture. Present ONLY on a bot's payload,
|
|
2476
|
-
* never on a person's or an organization's, so those DTOs do not grow.
|
|
2477
|
-
*/
|
|
2478
|
-
character: z.ZodOptional<z.ZodType<import("./avatarCharacter").AvatarCharacter, z.ZodTypeDef, unknown>>;
|
|
2479
|
-
/**
|
|
2480
|
-
* The authenticated viewer's relationship to this profile. Present ONLY
|
|
2481
|
-
* on single-profile fetches (`GET /profiles/username/:username`,
|
|
2482
|
-
* `GET /users/:userId`) when the request is authenticated; OMITTED for
|
|
2483
|
-
* anonymous requests and for the bulk `POST /users/by-ids` fan-out.
|
|
2484
|
-
*/
|
|
2485
|
-
relationship: z.ZodOptional<z.ZodType<UserRelationship, z.ZodTypeDef, UserRelationship>>;
|
|
2486
|
-
/**
|
|
2487
|
-
* Portable theme preference. Rides the self/session payload (cold boot),
|
|
2488
|
-
* so it is present on the current-user DTO (`GET /users/me`,
|
|
2489
|
-
* `GET /session/user/:sessionId`) and absent until the user sets it.
|
|
2490
|
-
*/
|
|
2491
|
-
userPreferences: z.ZodOptional<z.ZodObject<{
|
|
2492
|
-
displayCurrency: z.ZodOptional<z.ZodEnum<["USD", "EUR", "FAIR"]>>;
|
|
2493
|
-
}, "strip", z.ZodUnknown, z.objectOutputType<{
|
|
2494
|
-
displayCurrency: z.ZodOptional<z.ZodEnum<["USD", "EUR", "FAIR"]>>;
|
|
2495
|
-
}, z.ZodUnknown, "strip">, z.objectInputType<{
|
|
2496
|
-
displayCurrency: z.ZodOptional<z.ZodEnum<["USD", "EUR", "FAIR"]>>;
|
|
2497
|
-
}, z.ZodUnknown, "strip">>>;
|
|
2498
|
-
themePreference: z.ZodOptional<z.ZodType<ThemePreference, z.ZodTypeDef, ThemePreference>>;
|
|
2499
|
-
personalization: z.ZodOptional<z.ZodObject<{
|
|
2500
|
-
mentionMono: z.ZodObject<{
|
|
2501
|
-
allowed: z.ZodBoolean;
|
|
2502
|
-
expiresAt: z.ZodNullable<z.ZodString>;
|
|
2503
|
-
}, "strict", z.ZodTypeAny, {
|
|
2504
|
-
expiresAt: string | null;
|
|
2505
|
-
allowed: boolean;
|
|
2506
|
-
}, {
|
|
2507
|
-
expiresAt: string | null;
|
|
2508
|
-
allowed: boolean;
|
|
2509
|
-
}>;
|
|
2510
|
-
}, "strict", z.ZodTypeAny, {
|
|
2511
|
-
mentionMono: {
|
|
2512
|
-
expiresAt: string | null;
|
|
2513
|
-
allowed: boolean;
|
|
2514
|
-
};
|
|
2515
|
-
}, {
|
|
2516
|
-
mentionMono: {
|
|
2517
|
-
expiresAt: string | null;
|
|
2518
|
-
allowed: boolean;
|
|
2519
|
-
};
|
|
2520
|
-
}>>;
|
|
2521
|
-
}, z.ZodTypeAny, "passthrough"> | null | undefined;
|
|
2522
|
-
isCurrent?: boolean | undefined;
|
|
2523
|
-
}, {
|
|
2524
|
-
sessionId: string;
|
|
2525
|
-
user?: z.objectInputType<{
|
|
2526
|
-
/** The user id as a string. Present on `formatUserResponse` output. */
|
|
2527
|
-
id: z.ZodOptional<z.ZodString>;
|
|
2528
|
-
/** Raw-document id (e.g. `GET /users/me`). Present when `id` is not. */
|
|
2529
|
-
_id: z.ZodOptional<z.ZodString>;
|
|
2530
|
-
publicKey: z.ZodOptional<z.ZodString>;
|
|
2531
|
-
username: z.ZodOptional<z.ZodString>;
|
|
2532
|
-
email: z.ZodOptional<z.ZodString>;
|
|
2533
|
-
phone: z.ZodOptional<z.ZodString>;
|
|
2534
|
-
address: z.ZodOptional<z.ZodString>;
|
|
2535
|
-
birthday: z.ZodOptional<z.ZodString>;
|
|
2536
|
-
/**
|
|
2537
|
-
* Structured date of birth, `YYYY-MM-DD`. Present only on the
|
|
2538
|
-
* account's OWN profile response (`GET /users/me`, `PUT /users/me`
|
|
2539
|
-
* with `includePrivateFields`) — never on another account's profile,
|
|
2540
|
-
* the same visibility `phone`/`address`/`birthday` already have. See
|
|
2541
|
-
* {@link dateOfBirthSchema}.
|
|
2542
|
-
*/
|
|
2543
|
-
dateOfBirth: z.ZodOptional<z.ZodEffects<z.ZodEffects<z.ZodEffects<z.ZodString, string, string>, string, string>, string, string>>;
|
|
2544
|
-
/**
|
|
2545
|
-
* Derived, non-PII signal: whether the account holder is at least 18
|
|
2546
|
-
* (see `computeIsAdult` in `user.service.ts` for the exact threshold
|
|
2547
|
-
* and the UTC-"today" choice). Computed fresh on every read — age
|
|
2548
|
-
* changes daily, so this is never stored. `undefined` when
|
|
2549
|
-
* `dateOfBirth` is unset ("unknown"), distinct from `false` ("known,
|
|
2550
|
-
* not yet 18"). Rides the same owner-only visibility as
|
|
2551
|
-
* `dateOfBirth`; a future pass may widen this specific field to
|
|
2552
|
-
* other viewers without exposing the birthdate itself, but that is
|
|
2553
|
-
* not decided here.
|
|
2554
|
-
*/
|
|
2555
|
-
isAdult: z.ZodOptional<z.ZodBoolean>;
|
|
2556
|
-
/** Avatar file id (string) or null. */
|
|
2557
|
-
avatar: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
2558
|
-
/** Named Bloom color preset (e.g. `"blue"`) or null. */
|
|
2559
|
-
color: z.ZodOptional<z.ZodNullable<z.ZodString>>;
|
|
2560
|
-
name: z.ZodType<UserNameResponse, z.ZodTypeDef, UserNameResponse>;
|
|
2561
|
-
verified: z.ZodOptional<z.ZodBoolean>;
|
|
2562
|
-
/**
|
|
2563
|
-
* The account's languages as full BCP-47 locales (`language-REGION`,
|
|
2564
|
-
* e.g. `es-ES`, `en-US`, `pt-BR`), ordered with the PRIMARY (UI) locale
|
|
2565
|
-
* first. `languages[0]` is the primary locale — there is no singular
|
|
2566
|
-
* `language` field.
|
|
2567
|
-
*/
|
|
2568
|
-
languages: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
|
|
2569
|
-
/**
|
|
2570
|
-
* The account's self-sovereign identifier
|
|
2571
|
-
* (`did:web:<FEDERATION_DOMAIN>:u:<userId>`). Surfaced as a `User`
|
|
2572
|
-
* virtual; present on formatted DTOs once the identity layer is live.
|
|
2573
|
-
*/
|
|
2574
|
-
did: z.ZodOptional<z.ZodString>;
|
|
2575
|
-
/**
|
|
2576
|
-
* Proven domain-ownership badges. Each is a {@link verifiedDomainSchema}
|
|
2577
|
-
* entry; present only when the account has verified at least one domain.
|
|
2578
|
-
*/
|
|
2579
|
-
verifiedDomains: z.ZodOptional<z.ZodArray<z.ZodType<import("./identity").VerifiedDomain, z.ZodTypeDef, import("./identity").VerifiedDomain>, "many">>;
|
|
2580
|
-
/**
|
|
2581
|
-
* Account-graph classification — what KIND of account this is.
|
|
2582
|
-
*
|
|
2583
|
-
* ORTHOGONAL to `type` (`local` / `federated` / `agent` / `automated`),
|
|
2584
|
-
* which says where the account lives and how it is driven; the two
|
|
2585
|
-
* coexist and neither substitutes for the other. A `channel` is a
|
|
2586
|
-
* publishing identity nobody can act as, so a consumer that renders
|
|
2587
|
-
* authored content reads THIS to tell a channel's post from a person's.
|
|
2588
|
-
*
|
|
2589
|
-
* Optional because a DTO produced from a source that never carried the
|
|
2590
|
-
* column omits it; absent should be read as `personal`, the column's
|
|
2591
|
-
* default, not as unknown.
|
|
2592
|
-
*/
|
|
2593
|
-
kind: z.ZodOptional<z.ZodEnum<["personal", "organization", "project", "bot", "channel", "community"]>>;
|
|
2594
|
-
/**
|
|
2595
|
-
* What this account is about — the field a profile screen RENDERS.
|
|
2596
|
-
*
|
|
2597
|
-
* **Ordered, primary first.** `accountCategories[0]` is the primary
|
|
2598
|
-
* category; there is deliberately no sibling `primaryCategory` field,
|
|
2599
|
-
* because two representations of one fact can disagree (see rule 2 in
|
|
2600
|
-
* `accountGraph.ts`). Nothing downstream may sort, de-duplicate or
|
|
2601
|
-
* otherwise reorder this array.
|
|
2602
|
-
*
|
|
2603
|
-
* **Ids, never labels.** Each element is a stable slug; the visible text
|
|
2604
|
-
* comes from the reader's own translation catalogue, keyed
|
|
2605
|
-
* `accounts.accountCategory.<id>`. A label on the wire would paint every
|
|
2606
|
-
* profile in the language of whoever picked it.
|
|
2607
|
-
*
|
|
2608
|
-
* Absent when the account has none — which is every `personal` account,
|
|
2609
|
-
* and any non-personal one that has not chosen. A renderer reads
|
|
2610
|
-
* `user.accountCategories ?? []`.
|
|
2611
|
-
*/
|
|
2612
|
-
accountCategories: z.ZodOptional<z.ZodEffects<z.ZodArray<z.ZodEnum<["news", "politics", "business", "startup", "finance", "crypto", "marketplace", "retail", "real_estate", "agency", "landlord", "cooperative", "architecture", "technology", "software", "ai", "security", "automation", "science", "education", "books", "health", "fitness", "sports", "gaming", "music", "film", "podcast", "art", "photography", "comedy", "food", "travel", "fashion", "home_garden", "diy", "automotive", "animals", "family", "nonprofit", "government", "community", "activism", "environment", "religion", "other"]>, "many">, ("community" | "news" | "politics" | "business" | "startup" | "finance" | "crypto" | "marketplace" | "retail" | "real_estate" | "agency" | "landlord" | "cooperative" | "architecture" | "technology" | "software" | "ai" | "security" | "automation" | "science" | "education" | "books" | "health" | "fitness" | "sports" | "gaming" | "music" | "film" | "podcast" | "art" | "photography" | "comedy" | "food" | "travel" | "fashion" | "home_garden" | "diy" | "automotive" | "animals" | "family" | "nonprofit" | "government" | "activism" | "environment" | "religion" | "other")[], ("community" | "news" | "politics" | "business" | "startup" | "finance" | "crypto" | "marketplace" | "retail" | "real_estate" | "agency" | "landlord" | "cooperative" | "architecture" | "technology" | "software" | "ai" | "security" | "automation" | "science" | "education" | "books" | "health" | "fitness" | "sports" | "gaming" | "music" | "film" | "podcast" | "art" | "photography" | "comedy" | "food" | "travel" | "fashion" | "home_garden" | "diy" | "automotive" | "animals" | "family" | "nonprofit" | "government" | "activism" | "environment" | "religion" | "other")[]>>;
|
|
2613
|
-
/**
|
|
2614
|
-
* The 3D avatar character of a `kind: 'bot'` account — what Bloom's
|
|
2615
|
-
* `Avatar` draws instead of a picture. Present ONLY on a bot's payload,
|
|
2616
|
-
* never on a person's or an organization's, so those DTOs do not grow.
|
|
2617
|
-
*/
|
|
2618
|
-
character: z.ZodOptional<z.ZodType<import("./avatarCharacter").AvatarCharacter, z.ZodTypeDef, unknown>>;
|
|
2619
|
-
/**
|
|
2620
|
-
* The authenticated viewer's relationship to this profile. Present ONLY
|
|
2621
|
-
* on single-profile fetches (`GET /profiles/username/:username`,
|
|
2622
|
-
* `GET /users/:userId`) when the request is authenticated; OMITTED for
|
|
2623
|
-
* anonymous requests and for the bulk `POST /users/by-ids` fan-out.
|
|
2624
|
-
*/
|
|
2625
|
-
relationship: z.ZodOptional<z.ZodType<UserRelationship, z.ZodTypeDef, UserRelationship>>;
|
|
2626
|
-
/**
|
|
2627
|
-
* Portable theme preference. Rides the self/session payload (cold boot),
|
|
2628
|
-
* so it is present on the current-user DTO (`GET /users/me`,
|
|
2629
|
-
* `GET /session/user/:sessionId`) and absent until the user sets it.
|
|
2630
|
-
*/
|
|
2631
|
-
userPreferences: z.ZodOptional<z.ZodObject<{
|
|
2632
|
-
displayCurrency: z.ZodOptional<z.ZodEnum<["USD", "EUR", "FAIR"]>>;
|
|
2633
|
-
}, "strip", z.ZodUnknown, z.objectOutputType<{
|
|
2634
|
-
displayCurrency: z.ZodOptional<z.ZodEnum<["USD", "EUR", "FAIR"]>>;
|
|
2635
|
-
}, z.ZodUnknown, "strip">, z.objectInputType<{
|
|
2636
|
-
displayCurrency: z.ZodOptional<z.ZodEnum<["USD", "EUR", "FAIR"]>>;
|
|
2637
|
-
}, z.ZodUnknown, "strip">>>;
|
|
2638
|
-
themePreference: z.ZodOptional<z.ZodType<ThemePreference, z.ZodTypeDef, ThemePreference>>;
|
|
2639
|
-
personalization: z.ZodOptional<z.ZodObject<{
|
|
2640
|
-
mentionMono: z.ZodObject<{
|
|
2641
|
-
allowed: z.ZodBoolean;
|
|
2642
|
-
expiresAt: z.ZodNullable<z.ZodString>;
|
|
2643
|
-
}, "strict", z.ZodTypeAny, {
|
|
2644
|
-
expiresAt: string | null;
|
|
2645
|
-
allowed: boolean;
|
|
2646
|
-
}, {
|
|
2647
|
-
expiresAt: string | null;
|
|
2648
|
-
allowed: boolean;
|
|
2649
|
-
}>;
|
|
2650
|
-
}, "strict", z.ZodTypeAny, {
|
|
2651
|
-
mentionMono: {
|
|
2652
|
-
expiresAt: string | null;
|
|
2653
|
-
allowed: boolean;
|
|
2654
|
-
};
|
|
2655
|
-
}, {
|
|
2656
|
-
mentionMono: {
|
|
2657
|
-
expiresAt: string | null;
|
|
2658
|
-
allowed: boolean;
|
|
2659
|
-
};
|
|
2660
|
-
}>>;
|
|
2661
|
-
}, z.ZodTypeAny, "passthrough"> | null | undefined;
|
|
2662
|
-
isCurrent?: boolean | undefined;
|
|
2663
|
-
}>, "many">;
|
|
562
|
+
}, z.core.$strict>;
|
|
563
|
+
}, z.core.$strict>>;
|
|
564
|
+
}, z.core.$loose>>>;
|
|
565
|
+
}, z.core.$strip>>;
|
|
2664
566
|
export type DeviceLinkedSessionsResponseContract = z.infer<typeof deviceLinkedSessionsResponseSchema>;
|
|
2665
567
|
/**
|
|
2666
568
|
* Safely parse a value against a contract schema. Returns the parsed (typed)
|