@nadohq/mobile-client 0.66.0 → 0.67.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/README.md +110 -17
- package/dist/{MobileClient-M4oC4lrX.cjs → MobileClient-vuI5wlB_.cjs} +69 -29
- package/dist/MobileClient-vuI5wlB_.cjs.map +1 -0
- package/dist/MobileClient.cjs +1 -1
- package/dist/MobileClient.d.cts +50 -25
- package/dist/MobileClient.d.cts.map +1 -1
- package/dist/MobileClient.d.ts +50 -25
- package/dist/MobileClient.d.ts.map +1 -1
- package/dist/MobileClient.js +69 -29
- package/dist/MobileClient.js.map +1 -1
- package/dist/{MobileServerFailureError-MtS2reel.d.cts → MobileServerFailureError-BeCCNShj.d.cts} +2 -2
- package/dist/{MobileServerFailureError-MtS2reel.d.cts.map → MobileServerFailureError-BeCCNShj.d.cts.map} +1 -1
- package/dist/{MobileServerFailureError-C9iqNsxI.d.ts → MobileServerFailureError-hHv28weI.d.ts} +2 -2
- package/dist/{MobileServerFailureError-C9iqNsxI.d.ts.map → MobileServerFailureError-hHv28weI.d.ts.map} +1 -1
- package/dist/{buildSignedMobileRequest-DyKCK34Y.d.cts → buildSignedMobileRequest-DcEMKU_4.d.cts} +2 -2
- package/dist/{buildSignedMobileRequest-DyKCK34Y.d.cts.map → buildSignedMobileRequest-DcEMKU_4.d.cts.map} +1 -1
- package/dist/{buildSignedMobileRequest-BR-KJhIF.d.ts → buildSignedMobileRequest-DlTMvoXR.d.ts} +2 -2
- package/dist/{buildSignedMobileRequest-BR-KJhIF.d.ts.map → buildSignedMobileRequest-DlTMvoXR.d.ts.map} +1 -1
- package/dist/{canonicalize-Bv6UIAbR.d.ts → canonicalize-BOZlflI3.d.ts} +2 -2
- package/dist/canonicalize-BOZlflI3.d.ts.map +1 -0
- package/dist/{canonicalize-CWh3XZzj.d.cts → canonicalize-BvCozzvJ.d.cts} +2 -2
- package/dist/canonicalize-BvCozzvJ.d.cts.map +1 -0
- package/dist/{clientTypes-DOpUcu80.d.cts → clientTypes-KpHlCDGZ.d.cts} +75 -49
- package/dist/clientTypes-KpHlCDGZ.d.cts.map +1 -0
- package/dist/{clientTypes-BUn5_OzK.d.ts → clientTypes-XRI41VdC.d.ts} +75 -49
- package/dist/clientTypes-XRI41VdC.d.ts.map +1 -0
- package/dist/dataMappers.cjs +56 -17
- package/dist/dataMappers.cjs.map +1 -1
- package/dist/dataMappers.d.cts +33 -13
- package/dist/dataMappers.d.cts.map +1 -1
- package/dist/dataMappers.d.ts +33 -13
- package/dist/dataMappers.d.ts.map +1 -1
- package/dist/dataMappers.js +53 -17
- package/dist/dataMappers.js.map +1 -1
- package/dist/{eip712MethodByType-CJ6BoayT.d.cts → eip712MethodByType-DyAmzH7b.d.cts} +2 -2
- package/dist/eip712MethodByType-DyAmzH7b.d.cts.map +1 -0
- package/dist/{eip712MethodByType-Dx4mvgni.d.ts → eip712MethodByType-qSSAF6i2.d.ts} +2 -2
- package/dist/eip712MethodByType-qSSAF6i2.d.ts.map +1 -0
- package/dist/feed-BrgkFqP3.d.cts +23 -0
- package/dist/feed-BrgkFqP3.d.cts.map +1 -0
- package/dist/feed-DcbhLoo1.d.ts +23 -0
- package/dist/feed-DcbhLoo1.d.ts.map +1 -0
- package/dist/index-BVVgDSdq.d.cts +1 -0
- package/dist/index-BVVgDSdq.d.ts +1 -0
- package/dist/index.cjs +2 -1
- package/dist/index.d.cts +13 -13
- package/dist/index.d.ts +13 -13
- package/dist/index.js +2 -2
- package/dist/{mobileErrorCodes-vD6rbFuF.d.ts → mobileErrorCodes-CdwX6QTO.d.cts} +3 -3
- package/dist/{mobileErrorCodes-vD6rbFuF.d.cts.map → mobileErrorCodes-CdwX6QTO.d.cts.map} +1 -1
- package/dist/{mobileErrorCodes-vD6rbFuF.d.cts → mobileErrorCodes-CdwX6QTO.d.ts} +3 -3
- package/dist/{mobileErrorCodes-vD6rbFuF.d.ts.map → mobileErrorCodes-CdwX6QTO.d.ts.map} +1 -1
- package/dist/{payloadHash-CdkF2Ocr.d.cts → payloadHash-BgGSZock.d.cts} +2 -2
- package/dist/payloadHash-BgGSZock.d.cts.map +1 -0
- package/dist/{payloadHash-HD29K77M.d.ts → payloadHash-Bi6upCLQ.d.ts} +2 -2
- package/dist/payloadHash-Bi6upCLQ.d.ts.map +1 -0
- package/dist/{serverExecuteTypes-5JyyIXRK.d.ts → serverExecuteTypes-DuCWe_H_.d.cts} +7 -14
- package/dist/{serverExecuteTypes-CHrQ9Rtq.d.cts.map → serverExecuteTypes-DuCWe_H_.d.cts.map} +1 -1
- package/dist/{serverExecuteTypes-CHrQ9Rtq.d.cts → serverExecuteTypes-usJ6HMJv.d.ts} +7 -14
- package/dist/{serverExecuteTypes-5JyyIXRK.d.ts.map → serverExecuteTypes-usJ6HMJv.d.ts.map} +1 -1
- package/dist/{serverModelTypes-CGUZCi0y.d.ts → serverModelTypes-CTHMNIQS.d.cts} +16 -14
- package/dist/serverModelTypes-CTHMNIQS.d.cts.map +1 -0
- package/dist/{serverModelTypes-CGUZCi0y.d.cts → serverModelTypes-CTHMNIQS.d.ts} +16 -14
- package/dist/serverModelTypes-CTHMNIQS.d.ts.map +1 -0
- package/dist/{serverResponseGuards-i1njcYKN.d.cts → serverResponseGuards-CzmldAad.d.cts} +2 -2
- package/dist/{serverResponseGuards-i1njcYKN.d.cts.map → serverResponseGuards-CzmldAad.d.cts.map} +1 -1
- package/dist/{serverResponseGuards-Bvw8ltYJ.d.ts → serverResponseGuards-Dvkbjp2_.d.ts} +2 -2
- package/dist/{serverResponseGuards-Bvw8ltYJ.d.ts.map → serverResponseGuards-Dvkbjp2_.d.ts.map} +1 -1
- package/dist/signing/buildSignedMobileRequest.d.cts +1 -1
- package/dist/signing/buildSignedMobileRequest.d.ts +1 -1
- package/dist/signing/canonicalize.cjs +4 -2
- package/dist/signing/canonicalize.cjs.map +1 -1
- package/dist/signing/canonicalize.d.cts +1 -1
- package/dist/signing/canonicalize.d.ts +1 -1
- package/dist/signing/canonicalize.js +4 -2
- package/dist/signing/canonicalize.js.map +1 -1
- package/dist/signing/eip712MethodByType.d.cts +1 -1
- package/dist/signing/eip712MethodByType.d.ts +1 -1
- package/dist/signing/index.d.cts +5 -5
- package/dist/signing/index.d.ts +5 -5
- package/dist/signing/payloadHash.d.cts +1 -1
- package/dist/signing/payloadHash.d.ts +1 -1
- package/dist/signing/types.d.cts +1 -1
- package/dist/signing/types.d.ts +1 -1
- package/dist/types/MobileServerFailureError.d.cts +1 -1
- package/dist/types/MobileServerFailureError.d.ts +1 -1
- package/dist/types/clientTypes.d.cts +2 -2
- package/dist/types/clientTypes.d.ts +2 -2
- package/dist/types/index.d.cts +7 -7
- package/dist/types/index.d.ts +7 -7
- package/dist/types/mobileErrorCodes.cjs +2 -2
- package/dist/types/mobileErrorCodes.cjs.map +1 -1
- package/dist/types/mobileErrorCodes.d.cts +1 -1
- package/dist/types/mobileErrorCodes.d.ts +1 -1
- package/dist/types/mobileErrorCodes.js +2 -2
- package/dist/types/mobileErrorCodes.js.map +1 -1
- package/dist/types/serverBaseTypes.d.cts +1 -1
- package/dist/types/serverBaseTypes.d.ts +1 -1
- package/dist/types/serverExecuteTypes.d.cts +2 -2
- package/dist/types/serverExecuteTypes.d.ts +2 -2
- package/dist/types/serverModelTypes.cjs.map +1 -1
- package/dist/types/serverModelTypes.d.cts +2 -2
- package/dist/types/serverModelTypes.d.ts +2 -2
- package/dist/types/serverModelTypes.js.map +1 -1
- package/dist/types/serverQueryTypes.d.cts +2 -2
- package/dist/types/serverQueryTypes.d.ts +2 -2
- package/dist/types/serverRequestTypes.d.cts +1 -1
- package/dist/types/serverRequestTypes.d.ts +1 -1
- package/dist/{types-C9YE4EIt.d.cts → types-CByl_NyJ.d.ts} +49 -18
- package/dist/types-CByl_NyJ.d.ts.map +1 -0
- package/dist/{types-Cwy1y_9x.d.ts → types-CR5iaKR4.d.cts} +49 -18
- package/dist/types-CR5iaKR4.d.cts.map +1 -0
- package/dist/utils/feed.cjs +9 -0
- package/dist/utils/feed.cjs.map +1 -1
- package/dist/utils/feed.d.cts +2 -2
- package/dist/utils/feed.d.ts +2 -2
- package/dist/utils/feed.js +9 -1
- package/dist/utils/feed.js.map +1 -1
- package/dist/utils/index.cjs +1 -0
- package/dist/utils/index.d.cts +3 -3
- package/dist/utils/index.d.ts +3 -3
- package/dist/utils/index.js +2 -2
- package/dist/utils/serverResponseGuards.d.cts +1 -1
- package/dist/utils/serverResponseGuards.d.ts +1 -1
- package/package.json +3 -3
- package/src/MobileClient.ts +82 -34
- package/src/dataMappers.test.ts +408 -9
- package/src/dataMappers.ts +76 -23
- package/src/signing/canonicalize.ts +6 -0
- package/src/signing/signing.test.ts +51 -0
- package/src/signing/types.ts +4 -0
- package/src/socialFeed.test.ts +53 -28
- package/src/types/clientTypes.ts +82 -47
- package/src/types/mobileErrorCodes.ts +2 -2
- package/src/types/serverExecuteTypes.ts +4 -12
- package/src/types/serverModelTypes.ts +19 -13
- package/src/types/serverQueryTypes.ts +32 -4
- package/src/types/serverRequestTypes.ts +20 -12
- package/src/utils/feed.ts +13 -0
- package/dist/MobileClient-M4oC4lrX.cjs.map +0 -1
- package/dist/canonicalize-Bv6UIAbR.d.ts.map +0 -1
- package/dist/canonicalize-CWh3XZzj.d.cts.map +0 -1
- package/dist/clientTypes-BUn5_OzK.d.ts.map +0 -1
- package/dist/clientTypes-DOpUcu80.d.cts.map +0 -1
- package/dist/eip712MethodByType-CJ6BoayT.d.cts.map +0 -1
- package/dist/eip712MethodByType-Dx4mvgni.d.ts.map +0 -1
- package/dist/feed-DErOLaoY.d.cts +0 -16
- package/dist/feed-DErOLaoY.d.cts.map +0 -1
- package/dist/feed-DErOLaoY.d.ts +0 -16
- package/dist/feed-DErOLaoY.d.ts.map +0 -1
- package/dist/payloadHash-CdkF2Ocr.d.cts.map +0 -1
- package/dist/payloadHash-HD29K77M.d.ts.map +0 -1
- package/dist/serverModelTypes-CGUZCi0y.d.cts.map +0 -1
- package/dist/serverModelTypes-CGUZCi0y.d.ts.map +0 -1
- package/dist/types-C9YE4EIt.d.cts.map +0 -1
- package/dist/types-Cwy1y_9x.d.ts.map +0 -1
package/dist/MobileClient.d.cts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { $
|
|
2
|
-
import { P as MobileServerPublicQuerySuccessResponse, R as MobileServerSignedQuerySuccessResponse, a as MobileSignedRequest, d as MobileServerPublicExecuteRequestType,
|
|
3
|
-
import { a as MobileServerExecuteSuccessResponse, d as MobileServerPublicExecuteSuccessResponse } from "./serverExecuteTypes-
|
|
1
|
+
import { $t as MobileSocialFeedItem, A as GetMobileUsernameAvailabilityParams, Bn as MobileUpdateNotificationSubscriptionsParams, C as GetMobilePositionThoughtsParams, Ct as MobileSetPrivateModeParams, D as GetMobileRegisteredWalletParams, Dn as MobileSocialFeedTopTradersPage, E as GetMobileProfilesParams, F as MobileCreateFeedCommentParams, Fn as MobileSocialFeedUploadedImage, G as MobileFollowListPage, Gn as SearchMobileProfilesParams, I as MobileCreateFeedImageUploadParams, In as MobileSocialFeedWatchers, K as MobileFollowMutationResult, L as MobileCreateFeedPostParams, Ln as MobileUnregisterExpoTokenParams, N as MobileAvatarUpload, O as GetMobileSelfFeedPositionsParams, Ot as MobileSocialFeedActionResolutionResult, P as MobileCreateAvatarUploadParams, Pn as MobileSocialFeedUpdates, Q as MobileNotificationInboxV2, R as MobileFeedChartDrawingParams, Rn as MobileUpdateNotificationPreferencesParams, Rt as MobileSocialFeedCommentResult, S as GetMobilePositionHistoryParams, Sn as MobileSocialFeedRankedPage, St as MobileSetFollowParams, T as GetMobileProfileFeedParams, Tt as MobileSignedRequestParams, U as MobileFollowBatchResultItem, Un as ResolveMobileFeedActionParams, Ut as MobileSocialFeedDrawingMutationResult, V as MobileFeedPage, Vn as MobileUsernameAvailability, Wn as ResolveMobileFeedPositionParams, Wt as MobileSocialFeedDrawingResult, _ as GetMobileNotificationSettingsV2Params, _n as MobileSocialFeedPositionThoughtsPage, _t as MobileRegisteredWallet, a as GetMobileFeedItemParams, at as MobileNotificationSettingsV2, b as GetMobilePositionFeedParams, bn as MobileSocialFeedPresence, bt as MobileSetFeedLikeParams, ct as MobilePositionPresenceParams, d as GetMobileForYouFeedParams, dn as MobileSocialFeedPositionChart, f as GetMobileFriendsFeedParams, fn as MobileSocialFeedPositionHistory, ft as MobilePublicProfile, g as GetMobileNotificationRegistrationV2Params, gt as MobileRegisterExpoTokenV2Params, h as GetMobileNotificationPreferencesParams, hn as MobileSocialFeedPositionResolutionResult, ht as MobileRegisterExpoTokenParams, i as GetMobileFeedImageRequestParams, j as MobileAvatarPreset, k as GetMobileTopTradersFeedParams, l as GetMobileFollowersParams, m as GetMobileNotificationInboxV2Params, mt as MobileRecordProductEventsParams, n as GetMobileFeedCommentsParams, nn as MobileSocialFeedItemResponse, nt as MobileNotificationRegistrationV2, o as GetMobileFeedParams, ot as MobileNotificationSubscriptions, p as GetMobileMarketFeedParams, pt as MobileRecordFeedViewsParams, r as GetMobileFeedImageBytesParams, rn as MobileSocialFeedLikeResult, s as GetMobileFeedUpdatesParams, sn as MobileSocialFeedPage, t as GetMobileFeedChartDrawingParams, tt as MobileNotificationPreferences, u as GetMobileFollowingParams, ut as MobileProfileSearchPage, v as GetMobileNotificationSubscriptionsParams, vn as MobileSocialFeedPositionsPage, vt as MobileSetAvatarParams, w as GetMobilePositionWatchersParams, wt as MobileSetUsernameParams, x as GetMobilePositionHistoryAllParams, xt as MobileSetFollowBatchParams, y as GetMobilePositionChartParams, yt as MobileSetBioParams, z as MobileFeedImageRequest, zn as MobileUpdateNotificationSettingsV2Params, zt as MobileSocialFeedCommentsPage } from "./clientTypes-KpHlCDGZ.cjs";
|
|
2
|
+
import { P as MobileServerPublicQuerySuccessResponse, R as MobileServerSignedQuerySuccessResponse, a as MobileSignedRequest, d as MobileServerPublicExecuteRequestType, f as MobileServerPublicQueryRequestByType, i as MobileSignedInnerParams, n as MobileSignedInner, nt as MobileServerSuccessResponse, o as MobileServerExecuteRequestType, p as MobileServerPublicQueryRequestType, r as MobileSignedInnerByType, u as MobileServerPublicExecuteRequestByType, v as MobileServerSignedQueryRequestType } from "./types-CR5iaKR4.cjs";
|
|
3
|
+
import { a as MobileServerExecuteSuccessResponse, d as MobileServerPublicExecuteSuccessResponse } from "./serverExecuteTypes-DuCWe_H_.cjs";
|
|
4
4
|
import { WalletClientWithAccount } from "@nadohq/shared";
|
|
5
5
|
import { AxiosInstance } from "axios";
|
|
6
6
|
|
|
@@ -173,9 +173,8 @@ declare class MobileClient {
|
|
|
173
173
|
/**
|
|
174
174
|
* Reads one item visible to viewAs, including that account's own hidden content.
|
|
175
175
|
* Creates an item session directly when sessionId is omitted.
|
|
176
|
-
*
|
|
177
|
-
*
|
|
178
|
-
* @param params - Item UUID, optional detail-visit event, preview limit, and optional existing session/read identity.
|
|
176
|
+
* Reading does not increment views; use {@link recordFeedViews} independently when reporting views.
|
|
177
|
+
* @param params - Item UUID, preview limit, and optional existing session/read identity.
|
|
179
178
|
* @returns The complete item and authorized reading session.
|
|
180
179
|
* @throws {MobileServerFailureError} On inaccessible content or session mismatch/expiry.
|
|
181
180
|
* @throws {MobileUnsupportedFeedItemError} If the service returns an unsupported item kind.
|
|
@@ -256,25 +255,28 @@ declare class MobileClient {
|
|
|
256
255
|
resolveFeedImageUrl(path: string): string;
|
|
257
256
|
/**
|
|
258
257
|
* Prepares a protected image request for native image components without downloading or encoding bytes.
|
|
259
|
-
* Does not
|
|
258
|
+
* Does not increment view counts.
|
|
260
259
|
* @param params - Image path from metadata plus the original session credentials.
|
|
261
260
|
* @returns Absolute URL and headers; pass them as the image source's URI and headers.
|
|
262
261
|
*/
|
|
263
262
|
getFeedImageRequest(params: GetMobileFeedImageRequestParams): MobileFeedImageRequest;
|
|
264
263
|
/**
|
|
265
264
|
* Fetches protected feed image bytes using the reading session that fully delivered the parent item.
|
|
266
|
-
* Does not
|
|
265
|
+
* Does not increment view counts.
|
|
267
266
|
* @param params - Image path from metadata plus the original session credentials.
|
|
268
267
|
* @returns Raw image bytes.
|
|
269
268
|
* @throws {MobileServerFailureError} On session, permission, or availability errors.
|
|
270
269
|
*/
|
|
271
270
|
getFeedImageBytes(params: GetMobileFeedImageBytesParams): Promise<Uint8Array>;
|
|
272
271
|
/**
|
|
273
|
-
* Reads
|
|
272
|
+
* Reads top-level comment groups with all readable descendants and bidirectional pagination.
|
|
273
|
+
* The limit counts groups, not descendants. Groups are newest first; their flat replies are oldest first,
|
|
274
|
+
* with depth then UUID breaking timestamp ties. An anchor at any depth selects its top-level group.
|
|
275
|
+
* Preview cursors open the first complete group page in the same snapshot; do not prepend preview items.
|
|
274
276
|
* Independent reads create a public-only session; reused sessions retain their original scope.
|
|
275
|
-
* @param params - Root item, optional anchor or cursor (mutually exclusive),
|
|
277
|
+
* @param params - Root item, optional anchor or cursor (mutually exclusive), group limit, and read perspective.
|
|
276
278
|
* Paging requires the original session and viewer token.
|
|
277
|
-
* @returns
|
|
279
|
+
* @returns Complete comment groups, whole-thread reply and top-level counts, cursors, anchor, and session.
|
|
278
280
|
* @throws {MobileServerFailureError} On invalid parameters, session mismatch or expiry, inaccessible content,
|
|
279
281
|
* or unavailable data. Restart pagination with a new session after expiry; do not reuse the old cursor.
|
|
280
282
|
*/
|
|
@@ -286,10 +288,35 @@ declare class MobileClient {
|
|
|
286
288
|
* the original position session and viewer token, not a feed session.
|
|
287
289
|
* @returns Position metrics, ordered action/take history, summary, trading hints, cursor, and reading session.
|
|
288
290
|
* @throws {MobileServerFailureError} On invalid parameters, session mismatch or expiry, inaccessible content,
|
|
289
|
-
*
|
|
291
|
+
* unavailable source data, or SOCIAL_FEED_HISTORY_TOO_LARGE when the initial directory exceeds capacity.
|
|
292
|
+
* Restart with a new position session after expiry.
|
|
290
293
|
* @throws {MobileUnsupportedFeedItemError} If a timeline entry or take has an unsupported kind.
|
|
291
294
|
*/
|
|
292
295
|
getPositionHistory(params: GetMobilePositionHistoryParams): Promise<MobileSocialFeedPositionHistory>;
|
|
296
|
+
/**
|
|
297
|
+
* Reads the most recent 500 lifecycle actions, without authored text, drawings, or images.
|
|
298
|
+
* Creates a new position session on every call. A null nextCursor means no pagination, not complete
|
|
299
|
+
* history; use getPositionHistory with a fresh session for the full lifecycle. takeCount is always zero.
|
|
300
|
+
* @param params - Position and read perspective; an existing viewer token may be reused.
|
|
301
|
+
* @returns Position metrics, owner, recent actions, response-scope counts, trading hints, and a new session.
|
|
302
|
+
* @throws {MobileServerFailureError} On invalid parameters, inaccessible content, unavailable data,
|
|
303
|
+
* or SOCIAL_FEED_HISTORY_TOO_LARGE when the initial directory exceeds capacity.
|
|
304
|
+
* @throws {MobileUnsupportedFeedItemError} If a timeline entry or take has an unsupported kind.
|
|
305
|
+
*/
|
|
306
|
+
getPositionHistoryAll(params: GetMobilePositionHistoryAllParams): Promise<MobileSocialFeedPositionHistory>;
|
|
307
|
+
/**
|
|
308
|
+
* Reads published position thoughts with both nonblank text and a saved drawing, without signing.
|
|
309
|
+
* Keeps descending drawing creation time / item UUID order; editing a drawing does not move the item.
|
|
310
|
+
* Continue until nextCursor is null, even after an empty page. There is no 500-item total cap.
|
|
311
|
+
* Keep positionId, limit, sessionId, and viewerToken unchanged when paging; omitted viewAs inherits
|
|
312
|
+
* the session. History/feed sessions cannot be substituted. Refresh to include newly eligible content.
|
|
313
|
+
* @param params - Position, page size, read perspective, and original thoughts-session credentials for paging.
|
|
314
|
+
* @returns Complete thoughts and drawings in server order, a continuation cursor, and the reading session.
|
|
315
|
+
* @throws {MobileServerFailureError} On invalid parameters, session mismatch/expiry, inaccessible content,
|
|
316
|
+
* unavailable source data, or SOCIAL_FEED_HISTORY_TOO_LARGE when the initial directory exceeds capacity.
|
|
317
|
+
* @throws {MobileUnsupportedFeedItemError} If an item is not a post or trade card.
|
|
318
|
+
*/
|
|
319
|
+
getPositionThoughts(params: GetMobilePositionThoughtsParams): Promise<MobileSocialFeedPositionThoughtsPage>;
|
|
293
320
|
/**
|
|
294
321
|
* Reads candles and action markers without creating a reading session.
|
|
295
322
|
* Preserve the original range, interval, and read perspective when paging with nextBeforeMs.
|
|
@@ -373,18 +400,16 @@ declare class MobileClient {
|
|
|
373
400
|
*/
|
|
374
401
|
updateNotificationSettingsV2(params: MobileUpdateNotificationSettingsV2Params): Promise<MobileNotificationSettingsV2>;
|
|
375
402
|
/**
|
|
376
|
-
* Reports
|
|
377
|
-
*
|
|
378
|
-
*
|
|
379
|
-
*
|
|
380
|
-
*
|
|
381
|
-
*
|
|
382
|
-
* @returns
|
|
383
|
-
* @throws {MobileServerFailureError} On invalid parameters,
|
|
384
|
-
* (`SOCIAL_FEED_VIEW_EVENT_REBOUND`), session mismatch or expiry, or an ineligible item.
|
|
385
|
-
* Acquire a new session after expiry, re-register the same event via getFeedItem, then retry.
|
|
403
|
+
* Reports views for posts, trade cards, comments, and replies without signing or a reading session.
|
|
404
|
+
* Duplicate IDs count once within a request; another request increments them again. Only supplied IDs
|
|
405
|
+
* count, not their parents. Missing, deleted, unpublished, excluded, or unsupported targets are skipped.
|
|
406
|
+
* A successful response does not identify skipped items. Read interaction.viewCount for current counts.
|
|
407
|
+
* This operation is not idempotent: retrying an uncertain result may count twice. No automatic retry is made.
|
|
408
|
+
* @param params - itemIds: 1–50 canonical lowercase item UUIDs, including any same-request duplicates.
|
|
409
|
+
* @returns Only the success status, even when every target was skipped.
|
|
410
|
+
* @throws {MobileServerFailureError} On invalid parameters, disabled writes, rate limiting, or unavailable data.
|
|
386
411
|
*/
|
|
387
|
-
recordFeedViews(params: MobileRecordFeedViewsParams): Promise<
|
|
412
|
+
recordFeedViews(params: MobileRecordFeedViewsParams): Promise<MobileServerSuccessResponse>;
|
|
388
413
|
/**
|
|
389
414
|
* Registers, renews, or leaves a page lease without signing or authenticating the displayed account.
|
|
390
415
|
* Omitting watcherSubaccount preserves its value; null clears it. This operation does not record item views.
|
|
@@ -540,7 +565,7 @@ declare class MobileClient {
|
|
|
540
565
|
* or when publishing is disabled (`SERVICE_UNAVAILABLE`), or image storage is unavailable
|
|
541
566
|
* (`SOCIAL_FEED_DATA_UNAVAILABLE`, 6320, HTTP 503).
|
|
542
567
|
*/
|
|
543
|
-
createFeedPostImageUpload(params: MobileCreateFeedImageUploadParams): Promise<
|
|
568
|
+
createFeedPostImageUpload(params: MobileCreateFeedImageUploadParams): Promise<MobileSocialFeedUploadedImage>;
|
|
544
569
|
/**
|
|
545
570
|
* Uploads one static JPEG/PNG for a later {@link createFeedComment} via multipart execute.
|
|
546
571
|
* Same size and readiness rules as {@link createFeedPostImageUpload}; comment text remains required.
|
|
@@ -552,7 +577,7 @@ declare class MobileClient {
|
|
|
552
577
|
* or when comments are disabled (`SERVICE_UNAVAILABLE`), or image storage is unavailable
|
|
553
578
|
* (`SOCIAL_FEED_DATA_UNAVAILABLE`, 6320, HTTP 503).
|
|
554
579
|
*/
|
|
555
|
-
createFeedCommentImageUpload(params: MobileCreateFeedImageUploadParams): Promise<
|
|
580
|
+
createFeedCommentImageUpload(params: MobileCreateFeedImageUploadParams): Promise<MobileSocialFeedUploadedImage>;
|
|
556
581
|
/**
|
|
557
582
|
* First attaches a drawing to an owned post or trade card while the author still holds its position.
|
|
558
583
|
* The original JSON is signed unchanged; false and zero are valid drawing documents.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"MobileClient.d.cts","names":[],"sources":["../src/src/MobileClient.ts"],"mappings":";;;;;;;
|
|
1
|
+
{"version":3,"file":"MobileClient.d.cts","names":[],"sources":["../src/src/MobileClient.ts"],"mappings":";;;;;;;AA2LA;;;AAAA,UAAiB,gBAAA;EAIf;;;EAAA,GAAA;EAQ2B;;;EAJ3B,YAAA,GAAe,uBAAA;EAgBJ;;;EAZX,wBAAA,GAA2B,uBAAuB;EAc1B;;;EAVxB,UAAA;AAAA;;;;;;cAQW,YAAA;EAAA,SACF,IAAA,EAAM,gBAAA;EAAA,SACN,aAAA,EAAe,aAAA;cAEZ,IAAA,EAAM,gBAAA;EA2HR;;;;;EA5GH,eAAA,CACL,wBA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CAAA,CACpC,IAAA;IAAQ,IAAA,EAAM,CAAA;EAAA,IAAM,oCAAA,CAAqC,CAAA,IACxD,OAAA,CAAQ,sCAAA,CAAuC,CAAA;EAAA,UAalC,cAAA,CACd,GAAA,UACA,OAAA,EAAS,MAAA,mBACR,OAAA,CAAQ,UAAA;EAAA,UAkBK,aAAA,WAAwB,oCAAA,CAAA,CACtC,IAAA;IAAQ,IAAA,EAAM,CAAA;EAAA,IAAM,sCAAA,CAAuC,CAAA,IAC1D,OAAA,CAAQ,wCAAA,CAAyC,CAAA;;;;;;;YAmBpC,KAAA,WAAgB,kCAAA,CAAA,CAC9B,IAAA,EAAM,mBAAA;IAAwB,IAAA,EAAM,CAAA;EAAA,IACnC,OAAA,CAAQ,sCAAA,CAAuC,CAAA;EAAA,UAYlC,OAAA,WAAkB,8BAAA,CAAA,CAChC,IAAA,EAAM,mBAAA;IAAwB,IAAA,EAAM,CAAA;EAAA,GACpC,SAAA,GAAY,UAAA,GACX,OAAA,CAAQ,kCAAA,CAAmC,CAAA;EAAA,QAuBhC,qBAAA;EAAA,QAgCN,yBAAA;;;;;;UAaA,mBAAA;EAAA,QAYA,iBAAA;AAAA"}
|
package/dist/MobileClient.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { $
|
|
2
|
-
import { P as MobileServerPublicQuerySuccessResponse, R as MobileServerSignedQuerySuccessResponse, a as MobileSignedRequest, d as MobileServerPublicExecuteRequestType,
|
|
3
|
-
import { a as MobileServerExecuteSuccessResponse, d as MobileServerPublicExecuteSuccessResponse } from "./serverExecuteTypes-
|
|
1
|
+
import { $t as MobileSocialFeedItem, A as GetMobileUsernameAvailabilityParams, Bn as MobileUpdateNotificationSubscriptionsParams, C as GetMobilePositionThoughtsParams, Ct as MobileSetPrivateModeParams, D as GetMobileRegisteredWalletParams, Dn as MobileSocialFeedTopTradersPage, E as GetMobileProfilesParams, F as MobileCreateFeedCommentParams, Fn as MobileSocialFeedUploadedImage, G as MobileFollowListPage, Gn as SearchMobileProfilesParams, I as MobileCreateFeedImageUploadParams, In as MobileSocialFeedWatchers, K as MobileFollowMutationResult, L as MobileCreateFeedPostParams, Ln as MobileUnregisterExpoTokenParams, N as MobileAvatarUpload, O as GetMobileSelfFeedPositionsParams, Ot as MobileSocialFeedActionResolutionResult, P as MobileCreateAvatarUploadParams, Pn as MobileSocialFeedUpdates, Q as MobileNotificationInboxV2, R as MobileFeedChartDrawingParams, Rn as MobileUpdateNotificationPreferencesParams, Rt as MobileSocialFeedCommentResult, S as GetMobilePositionHistoryParams, Sn as MobileSocialFeedRankedPage, St as MobileSetFollowParams, T as GetMobileProfileFeedParams, Tt as MobileSignedRequestParams, U as MobileFollowBatchResultItem, Un as ResolveMobileFeedActionParams, Ut as MobileSocialFeedDrawingMutationResult, V as MobileFeedPage, Vn as MobileUsernameAvailability, Wn as ResolveMobileFeedPositionParams, Wt as MobileSocialFeedDrawingResult, _ as GetMobileNotificationSettingsV2Params, _n as MobileSocialFeedPositionThoughtsPage, _t as MobileRegisteredWallet, a as GetMobileFeedItemParams, at as MobileNotificationSettingsV2, b as GetMobilePositionFeedParams, bn as MobileSocialFeedPresence, bt as MobileSetFeedLikeParams, ct as MobilePositionPresenceParams, d as GetMobileForYouFeedParams, dn as MobileSocialFeedPositionChart, f as GetMobileFriendsFeedParams, fn as MobileSocialFeedPositionHistory, ft as MobilePublicProfile, g as GetMobileNotificationRegistrationV2Params, gt as MobileRegisterExpoTokenV2Params, h as GetMobileNotificationPreferencesParams, hn as MobileSocialFeedPositionResolutionResult, ht as MobileRegisterExpoTokenParams, i as GetMobileFeedImageRequestParams, j as MobileAvatarPreset, k as GetMobileTopTradersFeedParams, l as GetMobileFollowersParams, m as GetMobileNotificationInboxV2Params, mt as MobileRecordProductEventsParams, n as GetMobileFeedCommentsParams, nn as MobileSocialFeedItemResponse, nt as MobileNotificationRegistrationV2, o as GetMobileFeedParams, ot as MobileNotificationSubscriptions, p as GetMobileMarketFeedParams, pt as MobileRecordFeedViewsParams, r as GetMobileFeedImageBytesParams, rn as MobileSocialFeedLikeResult, s as GetMobileFeedUpdatesParams, sn as MobileSocialFeedPage, t as GetMobileFeedChartDrawingParams, tt as MobileNotificationPreferences, u as GetMobileFollowingParams, ut as MobileProfileSearchPage, v as GetMobileNotificationSubscriptionsParams, vn as MobileSocialFeedPositionsPage, vt as MobileSetAvatarParams, w as GetMobilePositionWatchersParams, wt as MobileSetUsernameParams, x as GetMobilePositionHistoryAllParams, xt as MobileSetFollowBatchParams, y as GetMobilePositionChartParams, yt as MobileSetBioParams, z as MobileFeedImageRequest, zn as MobileUpdateNotificationSettingsV2Params, zt as MobileSocialFeedCommentsPage } from "./clientTypes-XRI41VdC.js";
|
|
2
|
+
import { P as MobileServerPublicQuerySuccessResponse, R as MobileServerSignedQuerySuccessResponse, a as MobileSignedRequest, d as MobileServerPublicExecuteRequestType, f as MobileServerPublicQueryRequestByType, i as MobileSignedInnerParams, n as MobileSignedInner, nt as MobileServerSuccessResponse, o as MobileServerExecuteRequestType, p as MobileServerPublicQueryRequestType, r as MobileSignedInnerByType, u as MobileServerPublicExecuteRequestByType, v as MobileServerSignedQueryRequestType } from "./types-CByl_NyJ.js";
|
|
3
|
+
import { a as MobileServerExecuteSuccessResponse, d as MobileServerPublicExecuteSuccessResponse } from "./serverExecuteTypes-usJ6HMJv.js";
|
|
4
4
|
import { WalletClientWithAccount } from "@nadohq/shared";
|
|
5
5
|
import { AxiosInstance } from "axios";
|
|
6
6
|
|
|
@@ -173,9 +173,8 @@ declare class MobileClient {
|
|
|
173
173
|
/**
|
|
174
174
|
* Reads one item visible to viewAs, including that account's own hidden content.
|
|
175
175
|
* Creates an item session directly when sessionId is omitted.
|
|
176
|
-
*
|
|
177
|
-
*
|
|
178
|
-
* @param params - Item UUID, optional detail-visit event, preview limit, and optional existing session/read identity.
|
|
176
|
+
* Reading does not increment views; use {@link recordFeedViews} independently when reporting views.
|
|
177
|
+
* @param params - Item UUID, preview limit, and optional existing session/read identity.
|
|
179
178
|
* @returns The complete item and authorized reading session.
|
|
180
179
|
* @throws {MobileServerFailureError} On inaccessible content or session mismatch/expiry.
|
|
181
180
|
* @throws {MobileUnsupportedFeedItemError} If the service returns an unsupported item kind.
|
|
@@ -256,25 +255,28 @@ declare class MobileClient {
|
|
|
256
255
|
resolveFeedImageUrl(path: string): string;
|
|
257
256
|
/**
|
|
258
257
|
* Prepares a protected image request for native image components without downloading or encoding bytes.
|
|
259
|
-
* Does not
|
|
258
|
+
* Does not increment view counts.
|
|
260
259
|
* @param params - Image path from metadata plus the original session credentials.
|
|
261
260
|
* @returns Absolute URL and headers; pass them as the image source's URI and headers.
|
|
262
261
|
*/
|
|
263
262
|
getFeedImageRequest(params: GetMobileFeedImageRequestParams): MobileFeedImageRequest;
|
|
264
263
|
/**
|
|
265
264
|
* Fetches protected feed image bytes using the reading session that fully delivered the parent item.
|
|
266
|
-
* Does not
|
|
265
|
+
* Does not increment view counts.
|
|
267
266
|
* @param params - Image path from metadata plus the original session credentials.
|
|
268
267
|
* @returns Raw image bytes.
|
|
269
268
|
* @throws {MobileServerFailureError} On session, permission, or availability errors.
|
|
270
269
|
*/
|
|
271
270
|
getFeedImageBytes(params: GetMobileFeedImageBytesParams): Promise<Uint8Array>;
|
|
272
271
|
/**
|
|
273
|
-
* Reads
|
|
272
|
+
* Reads top-level comment groups with all readable descendants and bidirectional pagination.
|
|
273
|
+
* The limit counts groups, not descendants. Groups are newest first; their flat replies are oldest first,
|
|
274
|
+
* with depth then UUID breaking timestamp ties. An anchor at any depth selects its top-level group.
|
|
275
|
+
* Preview cursors open the first complete group page in the same snapshot; do not prepend preview items.
|
|
274
276
|
* Independent reads create a public-only session; reused sessions retain their original scope.
|
|
275
|
-
* @param params - Root item, optional anchor or cursor (mutually exclusive),
|
|
277
|
+
* @param params - Root item, optional anchor or cursor (mutually exclusive), group limit, and read perspective.
|
|
276
278
|
* Paging requires the original session and viewer token.
|
|
277
|
-
* @returns
|
|
279
|
+
* @returns Complete comment groups, whole-thread reply and top-level counts, cursors, anchor, and session.
|
|
278
280
|
* @throws {MobileServerFailureError} On invalid parameters, session mismatch or expiry, inaccessible content,
|
|
279
281
|
* or unavailable data. Restart pagination with a new session after expiry; do not reuse the old cursor.
|
|
280
282
|
*/
|
|
@@ -286,10 +288,35 @@ declare class MobileClient {
|
|
|
286
288
|
* the original position session and viewer token, not a feed session.
|
|
287
289
|
* @returns Position metrics, ordered action/take history, summary, trading hints, cursor, and reading session.
|
|
288
290
|
* @throws {MobileServerFailureError} On invalid parameters, session mismatch or expiry, inaccessible content,
|
|
289
|
-
*
|
|
291
|
+
* unavailable source data, or SOCIAL_FEED_HISTORY_TOO_LARGE when the initial directory exceeds capacity.
|
|
292
|
+
* Restart with a new position session after expiry.
|
|
290
293
|
* @throws {MobileUnsupportedFeedItemError} If a timeline entry or take has an unsupported kind.
|
|
291
294
|
*/
|
|
292
295
|
getPositionHistory(params: GetMobilePositionHistoryParams): Promise<MobileSocialFeedPositionHistory>;
|
|
296
|
+
/**
|
|
297
|
+
* Reads the most recent 500 lifecycle actions, without authored text, drawings, or images.
|
|
298
|
+
* Creates a new position session on every call. A null nextCursor means no pagination, not complete
|
|
299
|
+
* history; use getPositionHistory with a fresh session for the full lifecycle. takeCount is always zero.
|
|
300
|
+
* @param params - Position and read perspective; an existing viewer token may be reused.
|
|
301
|
+
* @returns Position metrics, owner, recent actions, response-scope counts, trading hints, and a new session.
|
|
302
|
+
* @throws {MobileServerFailureError} On invalid parameters, inaccessible content, unavailable data,
|
|
303
|
+
* or SOCIAL_FEED_HISTORY_TOO_LARGE when the initial directory exceeds capacity.
|
|
304
|
+
* @throws {MobileUnsupportedFeedItemError} If a timeline entry or take has an unsupported kind.
|
|
305
|
+
*/
|
|
306
|
+
getPositionHistoryAll(params: GetMobilePositionHistoryAllParams): Promise<MobileSocialFeedPositionHistory>;
|
|
307
|
+
/**
|
|
308
|
+
* Reads published position thoughts with both nonblank text and a saved drawing, without signing.
|
|
309
|
+
* Keeps descending drawing creation time / item UUID order; editing a drawing does not move the item.
|
|
310
|
+
* Continue until nextCursor is null, even after an empty page. There is no 500-item total cap.
|
|
311
|
+
* Keep positionId, limit, sessionId, and viewerToken unchanged when paging; omitted viewAs inherits
|
|
312
|
+
* the session. History/feed sessions cannot be substituted. Refresh to include newly eligible content.
|
|
313
|
+
* @param params - Position, page size, read perspective, and original thoughts-session credentials for paging.
|
|
314
|
+
* @returns Complete thoughts and drawings in server order, a continuation cursor, and the reading session.
|
|
315
|
+
* @throws {MobileServerFailureError} On invalid parameters, session mismatch/expiry, inaccessible content,
|
|
316
|
+
* unavailable source data, or SOCIAL_FEED_HISTORY_TOO_LARGE when the initial directory exceeds capacity.
|
|
317
|
+
* @throws {MobileUnsupportedFeedItemError} If an item is not a post or trade card.
|
|
318
|
+
*/
|
|
319
|
+
getPositionThoughts(params: GetMobilePositionThoughtsParams): Promise<MobileSocialFeedPositionThoughtsPage>;
|
|
293
320
|
/**
|
|
294
321
|
* Reads candles and action markers without creating a reading session.
|
|
295
322
|
* Preserve the original range, interval, and read perspective when paging with nextBeforeMs.
|
|
@@ -373,18 +400,16 @@ declare class MobileClient {
|
|
|
373
400
|
*/
|
|
374
401
|
updateNotificationSettingsV2(params: MobileUpdateNotificationSettingsV2Params): Promise<MobileNotificationSettingsV2>;
|
|
375
402
|
/**
|
|
376
|
-
* Reports
|
|
377
|
-
*
|
|
378
|
-
*
|
|
379
|
-
*
|
|
380
|
-
*
|
|
381
|
-
*
|
|
382
|
-
* @returns
|
|
383
|
-
* @throws {MobileServerFailureError} On invalid parameters,
|
|
384
|
-
* (`SOCIAL_FEED_VIEW_EVENT_REBOUND`), session mismatch or expiry, or an ineligible item.
|
|
385
|
-
* Acquire a new session after expiry, re-register the same event via getFeedItem, then retry.
|
|
403
|
+
* Reports views for posts, trade cards, comments, and replies without signing or a reading session.
|
|
404
|
+
* Duplicate IDs count once within a request; another request increments them again. Only supplied IDs
|
|
405
|
+
* count, not their parents. Missing, deleted, unpublished, excluded, or unsupported targets are skipped.
|
|
406
|
+
* A successful response does not identify skipped items. Read interaction.viewCount for current counts.
|
|
407
|
+
* This operation is not idempotent: retrying an uncertain result may count twice. No automatic retry is made.
|
|
408
|
+
* @param params - itemIds: 1–50 canonical lowercase item UUIDs, including any same-request duplicates.
|
|
409
|
+
* @returns Only the success status, even when every target was skipped.
|
|
410
|
+
* @throws {MobileServerFailureError} On invalid parameters, disabled writes, rate limiting, or unavailable data.
|
|
386
411
|
*/
|
|
387
|
-
recordFeedViews(params: MobileRecordFeedViewsParams): Promise<
|
|
412
|
+
recordFeedViews(params: MobileRecordFeedViewsParams): Promise<MobileServerSuccessResponse>;
|
|
388
413
|
/**
|
|
389
414
|
* Registers, renews, or leaves a page lease without signing or authenticating the displayed account.
|
|
390
415
|
* Omitting watcherSubaccount preserves its value; null clears it. This operation does not record item views.
|
|
@@ -540,7 +565,7 @@ declare class MobileClient {
|
|
|
540
565
|
* or when publishing is disabled (`SERVICE_UNAVAILABLE`), or image storage is unavailable
|
|
541
566
|
* (`SOCIAL_FEED_DATA_UNAVAILABLE`, 6320, HTTP 503).
|
|
542
567
|
*/
|
|
543
|
-
createFeedPostImageUpload(params: MobileCreateFeedImageUploadParams): Promise<
|
|
568
|
+
createFeedPostImageUpload(params: MobileCreateFeedImageUploadParams): Promise<MobileSocialFeedUploadedImage>;
|
|
544
569
|
/**
|
|
545
570
|
* Uploads one static JPEG/PNG for a later {@link createFeedComment} via multipart execute.
|
|
546
571
|
* Same size and readiness rules as {@link createFeedPostImageUpload}; comment text remains required.
|
|
@@ -552,7 +577,7 @@ declare class MobileClient {
|
|
|
552
577
|
* or when comments are disabled (`SERVICE_UNAVAILABLE`), or image storage is unavailable
|
|
553
578
|
* (`SOCIAL_FEED_DATA_UNAVAILABLE`, 6320, HTTP 503).
|
|
554
579
|
*/
|
|
555
|
-
createFeedCommentImageUpload(params: MobileCreateFeedImageUploadParams): Promise<
|
|
580
|
+
createFeedCommentImageUpload(params: MobileCreateFeedImageUploadParams): Promise<MobileSocialFeedUploadedImage>;
|
|
556
581
|
/**
|
|
557
582
|
* First attaches a drawing to an owned post or trade card while the author still holds its position.
|
|
558
583
|
* The original JSON is signed unchanged; false and zero are valid drawing documents.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"MobileClient.d.ts","names":[],"sources":["../src/src/MobileClient.ts"],"mappings":";;;;;;;
|
|
1
|
+
{"version":3,"file":"MobileClient.d.ts","names":[],"sources":["../src/src/MobileClient.ts"],"mappings":";;;;;;;AA2LA;;;AAAA,UAAiB,gBAAA;EAIf;;;EAAA,GAAA;EAQ2B;;;EAJ3B,YAAA,GAAe,uBAAA;EAgBJ;;;EAZX,wBAAA,GAA2B,uBAAuB;EAc1B;;;EAVxB,UAAA;AAAA;;;;;;cAQW,YAAA;EAAA,SACF,IAAA,EAAM,gBAAA;EAAA,SACN,aAAA,EAAe,aAAA;cAEZ,IAAA,EAAM,gBAAA;EA2HR;;;;;EA5GH,eAAA,CACL,wBAAA,EAA0B,uBAAA;EAiJN;;;;;EAnIhB,gBAAA,CAAA,GAAoB,OAAA,CAAQ,kBAAA;EA6KxB;;;EAlKJ,uBAAA,CACJ,MAAA,EAAQ,mCAAA,GACP,OAAA,CAAQ,0BAAA;EAqLA;;;;;;;;;;;;;;EA9JL,WAAA,CACJ,MAAA,EAAQ,uBAAA,GACP,OAAA,CAAQ,mBAAA;EA0QA;;;;;;;;;;;;;;;;EA9OL,cAAA,CACJ,MAAA,EAAQ,0BAAA,GACP,OAAA,CAAQ,uBAAA;EA2WD;;;;;;;;;;;;;;;EAnVJ,YAAA,CACJ,MAAA,EAAQ,wBAAA,GACP,OAAA,CAAQ,oBAAA;EAscR;;;;;EAxbG,YAAA,CACJ,MAAA,EAAQ,wBAAA,GACP,OAAA,CAAQ,oBAAA;EAoeR;;;;;;;;;;;;EA/cG,OAAA,CAAQ,MAAA,GAAQ,mBAAA,GAA2B,OAAA,CAAQ,cAAA;EAmjB/C;;;;;;;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,OAAA,CAAQ,kCAAA,CAAmC,CAAA;EAAA,QAuBhC,qBAAA;EAAA,QAgCN,yBAAA;;;;;;UAaA,mBAAA;EAAA,QAYA,iBAAA;AAAA"}
|
package/dist/MobileClient.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { mapMobileAvatarPreset, mapMobileAvatarSelectionToServer, mapMobileAvatarUpload, mapMobileFeedPage, mapMobileFollowBatchResult, mapMobileFollowListPage, mapMobileFollowListParamsToServer, mapMobileFollowMutationResult, mapMobileNotificationCapabilitiesToServer, mapMobileNotificationInboxV2, mapMobileNotificationPreferences, mapMobileNotificationPreferencesToServer, mapMobileNotificationRegistrationV2, mapMobileNotificationSettingsToServer, mapMobileNotificationSettingsV2, mapMobileNotificationSubscriptions, mapMobileNotificationSubscriptionsUpdateToServer, mapMobileProductEventToServer, mapMobileProfileSearchPage, mapMobileProfileSearchParamsToServer, mapMobileProfilesIncludeToServer, mapMobilePublicProfile, mapMobileRegisteredWallet, mapMobileSocialFeedActionResolutionResult, mapMobileSocialFeedCommentResult, mapMobileSocialFeedCommentsPage, mapMobileSocialFeedDrawingMutationResult, mapMobileSocialFeedDrawingResult,
|
|
1
|
+
import { mapMobileAvatarPreset, mapMobileAvatarSelectionToServer, mapMobileAvatarUpload, mapMobileFeedPage, mapMobileFollowBatchResult, mapMobileFollowListPage, mapMobileFollowListParamsToServer, mapMobileFollowMutationResult, mapMobileNotificationCapabilitiesToServer, mapMobileNotificationInboxV2, mapMobileNotificationPreferences, mapMobileNotificationPreferencesToServer, mapMobileNotificationRegistrationV2, mapMobileNotificationSettingsToServer, mapMobileNotificationSettingsV2, mapMobileNotificationSubscriptions, mapMobileNotificationSubscriptionsUpdateToServer, mapMobileProductEventToServer, mapMobileProfileSearchPage, mapMobileProfileSearchParamsToServer, mapMobileProfilesIncludeToServer, mapMobilePublicProfile, mapMobileRegisteredWallet, mapMobileSocialFeedActionResolutionResult, mapMobileSocialFeedCommentResult, mapMobileSocialFeedCommentsPage, mapMobileSocialFeedDrawingMutationResult, mapMobileSocialFeedDrawingResult, mapMobileSocialFeedItem, mapMobileSocialFeedItemResponse, mapMobileSocialFeedLikeResult, mapMobileSocialFeedListParamsToServer, mapMobileSocialFeedMentionToServer, mapMobileSocialFeedPage, mapMobileSocialFeedPositionChart, mapMobileSocialFeedPositionHistory, mapMobileSocialFeedPositionResolutionResult, mapMobileSocialFeedPositionThoughts, mapMobileSocialFeedPositionsPage, mapMobileSocialFeedPresence, mapMobileSocialFeedRankedPage, mapMobileSocialFeedReadParamsToServer, mapMobileSocialFeedTopTradersPage, mapMobileSocialFeedUpdates, mapMobileSocialFeedUploadedImage, mapMobileSocialFeedWatchers } from "./dataMappers.js";
|
|
2
2
|
import { getMobileNonce } from "./signing/nonce.js";
|
|
3
3
|
import { buildSignedMobileRequest } from "./signing/buildSignedMobileRequest.js";
|
|
4
4
|
import "./signing/index.js";
|
|
@@ -259,9 +259,8 @@ var MobileClient = class {
|
|
|
259
259
|
/**
|
|
260
260
|
* Reads one item visible to viewAs, including that account's own hidden content.
|
|
261
261
|
* Creates an item session directly when sessionId is omitted.
|
|
262
|
-
*
|
|
263
|
-
*
|
|
264
|
-
* @param params - Item UUID, optional detail-visit event, preview limit, and optional existing session/read identity.
|
|
262
|
+
* Reading does not increment views; use {@link recordFeedViews} independently when reporting views.
|
|
263
|
+
* @param params - Item UUID, preview limit, and optional existing session/read identity.
|
|
265
264
|
* @returns The complete item and authorized reading session.
|
|
266
265
|
* @throws {MobileServerFailureError} On inaccessible content or session mismatch/expiry.
|
|
267
266
|
* @throws {MobileUnsupportedFeedItemError} If the service returns an unsupported item kind.
|
|
@@ -270,7 +269,6 @@ var MobileClient = class {
|
|
|
270
269
|
const body = {
|
|
271
270
|
type: "feed_item",
|
|
272
271
|
item_id: params.itemId,
|
|
273
|
-
view_event_id: params.viewEventId,
|
|
274
272
|
comment_preview_limit: params.commentPreviewLimit,
|
|
275
273
|
session_id: params.sessionId,
|
|
276
274
|
...mapMobileSocialFeedReadParamsToServer(params)
|
|
@@ -410,7 +408,7 @@ var MobileClient = class {
|
|
|
410
408
|
}
|
|
411
409
|
/**
|
|
412
410
|
* Prepares a protected image request for native image components without downloading or encoding bytes.
|
|
413
|
-
* Does not
|
|
411
|
+
* Does not increment view counts.
|
|
414
412
|
* @param params - Image path from metadata plus the original session credentials.
|
|
415
413
|
* @returns Absolute URL and headers; pass them as the image source's URI and headers.
|
|
416
414
|
*/
|
|
@@ -425,7 +423,7 @@ var MobileClient = class {
|
|
|
425
423
|
}
|
|
426
424
|
/**
|
|
427
425
|
* Fetches protected feed image bytes using the reading session that fully delivered the parent item.
|
|
428
|
-
* Does not
|
|
426
|
+
* Does not increment view counts.
|
|
429
427
|
* @param params - Image path from metadata plus the original session credentials.
|
|
430
428
|
* @returns Raw image bytes.
|
|
431
429
|
* @throws {MobileServerFailureError} On session, permission, or availability errors.
|
|
@@ -435,11 +433,14 @@ var MobileClient = class {
|
|
|
435
433
|
return this.publicGetBytes(url, headers);
|
|
436
434
|
}
|
|
437
435
|
/**
|
|
438
|
-
* Reads
|
|
436
|
+
* Reads top-level comment groups with all readable descendants and bidirectional pagination.
|
|
437
|
+
* The limit counts groups, not descendants. Groups are newest first; their flat replies are oldest first,
|
|
438
|
+
* with depth then UUID breaking timestamp ties. An anchor at any depth selects its top-level group.
|
|
439
|
+
* Preview cursors open the first complete group page in the same snapshot; do not prepend preview items.
|
|
439
440
|
* Independent reads create a public-only session; reused sessions retain their original scope.
|
|
440
|
-
* @param params - Root item, optional anchor or cursor (mutually exclusive),
|
|
441
|
+
* @param params - Root item, optional anchor or cursor (mutually exclusive), group limit, and read perspective.
|
|
441
442
|
* Paging requires the original session and viewer token.
|
|
442
|
-
* @returns
|
|
443
|
+
* @returns Complete comment groups, whole-thread reply and top-level counts, cursors, anchor, and session.
|
|
443
444
|
* @throws {MobileServerFailureError} On invalid parameters, session mismatch or expiry, inaccessible content,
|
|
444
445
|
* or unavailable data. Restart pagination with a new session after expiry; do not reuse the old cursor.
|
|
445
446
|
*/
|
|
@@ -462,7 +463,8 @@ var MobileClient = class {
|
|
|
462
463
|
* the original position session and viewer token, not a feed session.
|
|
463
464
|
* @returns Position metrics, ordered action/take history, summary, trading hints, cursor, and reading session.
|
|
464
465
|
* @throws {MobileServerFailureError} On invalid parameters, session mismatch or expiry, inaccessible content,
|
|
465
|
-
*
|
|
466
|
+
* unavailable source data, or SOCIAL_FEED_HISTORY_TOO_LARGE when the initial directory exceeds capacity.
|
|
467
|
+
* Restart with a new position session after expiry.
|
|
466
468
|
* @throws {MobileUnsupportedFeedItemError} If a timeline entry or take has an unsupported kind.
|
|
467
469
|
*/
|
|
468
470
|
async getPositionHistory(params) {
|
|
@@ -478,6 +480,47 @@ var MobileClient = class {
|
|
|
478
480
|
return mapMobileSocialFeedPositionHistory(await this.publicQuery(body));
|
|
479
481
|
}
|
|
480
482
|
/**
|
|
483
|
+
* Reads the most recent 500 lifecycle actions, without authored text, drawings, or images.
|
|
484
|
+
* Creates a new position session on every call. A null nextCursor means no pagination, not complete
|
|
485
|
+
* history; use getPositionHistory with a fresh session for the full lifecycle. takeCount is always zero.
|
|
486
|
+
* @param params - Position and read perspective; an existing viewer token may be reused.
|
|
487
|
+
* @returns Position metrics, owner, recent actions, response-scope counts, trading hints, and a new session.
|
|
488
|
+
* @throws {MobileServerFailureError} On invalid parameters, inaccessible content, unavailable data,
|
|
489
|
+
* or SOCIAL_FEED_HISTORY_TOO_LARGE when the initial directory exceeds capacity.
|
|
490
|
+
* @throws {MobileUnsupportedFeedItemError} If a timeline entry or take has an unsupported kind.
|
|
491
|
+
*/
|
|
492
|
+
async getPositionHistoryAll(params) {
|
|
493
|
+
const body = {
|
|
494
|
+
type: "position_history_all",
|
|
495
|
+
position_id: params.positionId,
|
|
496
|
+
...mapMobileSocialFeedReadParamsToServer(params)
|
|
497
|
+
};
|
|
498
|
+
return mapMobileSocialFeedPositionHistory(await this.publicQuery(body));
|
|
499
|
+
}
|
|
500
|
+
/**
|
|
501
|
+
* Reads published position thoughts with both nonblank text and a saved drawing, without signing.
|
|
502
|
+
* Keeps descending drawing creation time / item UUID order; editing a drawing does not move the item.
|
|
503
|
+
* Continue until nextCursor is null, even after an empty page. There is no 500-item total cap.
|
|
504
|
+
* Keep positionId, limit, sessionId, and viewerToken unchanged when paging; omitted viewAs inherits
|
|
505
|
+
* the session. History/feed sessions cannot be substituted. Refresh to include newly eligible content.
|
|
506
|
+
* @param params - Position, page size, read perspective, and original thoughts-session credentials for paging.
|
|
507
|
+
* @returns Complete thoughts and drawings in server order, a continuation cursor, and the reading session.
|
|
508
|
+
* @throws {MobileServerFailureError} On invalid parameters, session mismatch/expiry, inaccessible content,
|
|
509
|
+
* unavailable source data, or SOCIAL_FEED_HISTORY_TOO_LARGE when the initial directory exceeds capacity.
|
|
510
|
+
* @throws {MobileUnsupportedFeedItemError} If an item is not a post or trade card.
|
|
511
|
+
*/
|
|
512
|
+
async getPositionThoughts(params) {
|
|
513
|
+
const body = {
|
|
514
|
+
type: "position_thoughts",
|
|
515
|
+
position_id: params.positionId,
|
|
516
|
+
limit: params.limit,
|
|
517
|
+
session_id: params.sessionId,
|
|
518
|
+
cursor: params.cursor,
|
|
519
|
+
...mapMobileSocialFeedReadParamsToServer(params)
|
|
520
|
+
};
|
|
521
|
+
return mapMobileSocialFeedPositionThoughts(await this.publicQuery(body));
|
|
522
|
+
}
|
|
523
|
+
/**
|
|
481
524
|
* Reads candles and action markers without creating a reading session.
|
|
482
525
|
* Preserve the original range, interval, and read perspective when paging with nextBeforeMs.
|
|
483
526
|
* @param params - Position, candle interval, half-open time range, pagination, and optional original session
|
|
@@ -621,26 +664,21 @@ var MobileClient = class {
|
|
|
621
664
|
}));
|
|
622
665
|
}
|
|
623
666
|
/**
|
|
624
|
-
* Reports
|
|
625
|
-
*
|
|
626
|
-
*
|
|
627
|
-
*
|
|
628
|
-
*
|
|
629
|
-
*
|
|
630
|
-
* @returns
|
|
631
|
-
* @throws {MobileServerFailureError} On invalid parameters,
|
|
632
|
-
* (`SOCIAL_FEED_VIEW_EVENT_REBOUND`), session mismatch or expiry, or an ineligible item.
|
|
633
|
-
* Acquire a new session after expiry, re-register the same event via getFeedItem, then retry.
|
|
667
|
+
* Reports views for posts, trade cards, comments, and replies without signing or a reading session.
|
|
668
|
+
* Duplicate IDs count once within a request; another request increments them again. Only supplied IDs
|
|
669
|
+
* count, not their parents. Missing, deleted, unpublished, excluded, or unsupported targets are skipped.
|
|
670
|
+
* A successful response does not identify skipped items. Read interaction.viewCount for current counts.
|
|
671
|
+
* This operation is not idempotent: retrying an uncertain result may count twice. No automatic retry is made.
|
|
672
|
+
* @param params - itemIds: 1–50 canonical lowercase item UUIDs, including any same-request duplicates.
|
|
673
|
+
* @returns Only the success status, even when every target was skipped.
|
|
674
|
+
* @throws {MobileServerFailureError} On invalid parameters, disabled writes, rate limiting, or unavailable data.
|
|
634
675
|
*/
|
|
635
676
|
async recordFeedViews(params) {
|
|
636
677
|
const body = {
|
|
637
678
|
type: "record_feed_views",
|
|
638
|
-
|
|
639
|
-
viewer_token: params.viewerToken,
|
|
640
|
-
view_event_id: params.viewEventId,
|
|
641
|
-
item_ids: [params.itemId]
|
|
679
|
+
item_ids: params.itemIds
|
|
642
680
|
};
|
|
643
|
-
return
|
|
681
|
+
return this.publicExecute(body);
|
|
644
682
|
}
|
|
645
683
|
/**
|
|
646
684
|
* Registers, renews, or leaves a page lease without signing or authenticating the displayed account.
|
|
@@ -853,7 +891,8 @@ var MobileClient = class {
|
|
|
853
891
|
text: params.text,
|
|
854
892
|
mentions: params.mentions.map(mapMobileSocialFeedMentionToServer),
|
|
855
893
|
drawing_data_json: params.drawingDataJson,
|
|
856
|
-
image_ids: params.imageIds
|
|
894
|
+
image_ids: params.imageIds,
|
|
895
|
+
image_urls: params.imageUrls
|
|
857
896
|
});
|
|
858
897
|
return mapMobileSocialFeedItem((await this.execute(request)).item);
|
|
859
898
|
}
|
|
@@ -943,7 +982,8 @@ var MobileClient = class {
|
|
|
943
982
|
text: params.text,
|
|
944
983
|
mentions: params.mentions.map(mapMobileSocialFeedMentionToServer),
|
|
945
984
|
attached_position_id: params.attachedPositionId,
|
|
946
|
-
image_ids: params.imageIds
|
|
985
|
+
image_ids: params.imageIds,
|
|
986
|
+
image_urls: params.imageUrls
|
|
947
987
|
});
|
|
948
988
|
return mapMobileSocialFeedCommentResult(await this.execute(request));
|
|
949
989
|
}
|
|
@@ -1047,7 +1087,7 @@ var MobileClient = class {
|
|
|
1047
1087
|
...params,
|
|
1048
1088
|
nonce
|
|
1049
1089
|
}, { content_hash: contentHash });
|
|
1050
|
-
return
|
|
1090
|
+
return mapMobileSocialFeedUploadedImage((await this.execute(request, params.fileBytes)).image);
|
|
1051
1091
|
}
|
|
1052
1092
|
checkFeedImageRequestSize(byteLength) {
|
|
1053
1093
|
if (byteLength > 2097152) throw new RangeError(`Feed image upload request exceeds ${MOBILE_FEED_IMAGE_MAX_REQUEST_BYTES} bytes (2 MiB).`);
|