@nadohq/mobile-client 0.32.0 → 0.34.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 +2 -2
- package/dist/{MobileClient-_i0ZV6Dq.cjs → MobileClient-SQ7byUxo.cjs} +18 -8
- package/dist/MobileClient-SQ7byUxo.cjs.map +1 -0
- package/dist/MobileClient.cjs +1 -1
- package/dist/MobileClient.d.cts +17 -10
- package/dist/MobileClient.d.cts.map +1 -1
- package/dist/MobileClient.d.ts +17 -10
- package/dist/MobileClient.d.ts.map +1 -1
- package/dist/MobileClient.js +18 -8
- package/dist/MobileClient.js.map +1 -1
- package/dist/{MobileServerFailureError-MgYVBh5p.d.ts → MobileServerFailureError-A2EcYe6Y.d.ts} +3 -3
- package/dist/{MobileServerFailureError-MgYVBh5p.d.ts.map → MobileServerFailureError-A2EcYe6Y.d.ts.map} +1 -1
- package/dist/{MobileServerFailureError-BoyAfEZA.d.cts → MobileServerFailureError-N3nGgdmg.d.cts} +3 -3
- package/dist/{MobileServerFailureError-BoyAfEZA.d.cts.map → MobileServerFailureError-N3nGgdmg.d.cts.map} +1 -1
- package/dist/{buildSignedMobileRequest-qEC4gWaI.d.ts → buildSignedMobileRequest-B8iVGxQc.d.ts} +2 -2
- package/dist/{buildSignedMobileRequest-qEC4gWaI.d.ts.map → buildSignedMobileRequest-B8iVGxQc.d.ts.map} +1 -1
- package/dist/{buildSignedMobileRequest-CBMt97aY.d.cts → buildSignedMobileRequest-CtRX4zl4.d.cts} +2 -2
- package/dist/{buildSignedMobileRequest-CBMt97aY.d.cts.map → buildSignedMobileRequest-CtRX4zl4.d.cts.map} +1 -1
- package/dist/{canonicalize-wVdGejB1.d.ts → canonicalize-Cz1rz_ER.d.ts} +2 -2
- package/dist/canonicalize-Cz1rz_ER.d.ts.map +1 -0
- package/dist/{canonicalize-QNARV_Xc.d.cts → canonicalize-afPLlUjE.d.cts} +2 -2
- package/dist/canonicalize-afPLlUjE.d.cts.map +1 -0
- package/dist/{clientTypes-D9qgtNlE.d.cts → clientTypes-DIipTg9D.d.cts} +10 -7
- package/dist/clientTypes-DIipTg9D.d.cts.map +1 -0
- package/dist/{clientTypes-6utzUU-b.d.ts → clientTypes-DqDZEcBu.d.ts} +10 -7
- package/dist/clientTypes-DqDZEcBu.d.ts.map +1 -0
- package/dist/dataMappers.cjs +4 -3
- package/dist/dataMappers.cjs.map +1 -1
- package/dist/dataMappers.d.cts +6 -6
- package/dist/dataMappers.d.cts.map +1 -1
- package/dist/dataMappers.d.ts +6 -6
- package/dist/dataMappers.d.ts.map +1 -1
- package/dist/dataMappers.js +4 -3
- package/dist/dataMappers.js.map +1 -1
- package/dist/{eip712MethodByType-DBUy4AdI.d.ts → eip712MethodByType-BzfeoDTF.d.ts} +2 -2
- package/dist/eip712MethodByType-BzfeoDTF.d.ts.map +1 -0
- package/dist/{eip712MethodByType-CroIPqsJ.d.cts → eip712MethodByType-CUAcWwX0.d.cts} +2 -2
- package/dist/eip712MethodByType-CUAcWwX0.d.cts.map +1 -0
- package/dist/index.cjs +1 -1
- package/dist/index.d.cts +14 -14
- package/dist/index.d.ts +14 -14
- package/dist/{payloadHash-B0tlFOK8.d.cts → payloadHash-CgKXMvZU.d.cts} +2 -2
- package/dist/payloadHash-CgKXMvZU.d.cts.map +1 -0
- package/dist/{payloadHash-D1yTQSF4.d.ts → payloadHash-yIWBW4Iq.d.ts} +2 -2
- package/dist/payloadHash-yIWBW4Iq.d.ts.map +1 -0
- package/dist/{serverBaseTypes-CzRgwUvA.d.ts → serverBaseTypes-ClQZqTAK.d.ts} +2 -2
- package/dist/{serverBaseTypes-CzRgwUvA.d.ts.map → serverBaseTypes-ClQZqTAK.d.ts.map} +1 -1
- package/dist/{serverBaseTypes-DSRgU2Fb.d.cts → serverBaseTypes-_a1pE464.d.cts} +2 -2
- package/dist/{serverBaseTypes-DSRgU2Fb.d.cts.map → serverBaseTypes-_a1pE464.d.cts.map} +1 -1
- package/dist/{serverExecuteTypes-CI3NBW2Z.d.ts → serverExecuteTypes-BD8Awy8Q.d.ts} +3 -3
- package/dist/{serverExecuteTypes-CI3NBW2Z.d.ts.map → serverExecuteTypes-BD8Awy8Q.d.ts.map} +1 -1
- package/dist/{serverExecuteTypes-BCb6bUMP.d.cts → serverExecuteTypes-CUla9jFj.d.cts} +3 -3
- package/dist/{serverExecuteTypes-BCb6bUMP.d.cts.map → serverExecuteTypes-CUla9jFj.d.cts.map} +1 -1
- package/dist/{serverModelTypes-DvPs5qs3.d.ts → serverModelTypes-BIGPd52y.d.ts} +2 -12
- package/dist/{serverModelTypes-DvPs5qs3.d.ts.map → serverModelTypes-BIGPd52y.d.ts.map} +1 -1
- package/dist/{serverModelTypes-BYQcsRrx.d.cts → serverModelTypes-DGYc_3XP.d.cts} +2 -12
- package/dist/{serverModelTypes-BYQcsRrx.d.cts.map → serverModelTypes-DGYc_3XP.d.cts.map} +1 -1
- package/dist/{serverQueryTypes-9H6P1vJ5.d.cts → serverQueryTypes-4J8qNQld.d.ts} +16 -9
- package/dist/serverQueryTypes-4J8qNQld.d.ts.map +1 -0
- package/dist/{serverQueryTypes-Cbjx0bIj.d.ts → serverQueryTypes-C_rvZnol.d.cts} +16 -9
- package/dist/serverQueryTypes-C_rvZnol.d.cts.map +1 -0
- package/dist/{serverRequestTypes-DYTLrCpz.d.ts → serverRequestTypes-Cw661qjM.d.cts} +6 -4
- package/dist/serverRequestTypes-Cw661qjM.d.cts.map +1 -0
- package/dist/{serverRequestTypes-CHDk6JwE.d.cts → serverRequestTypes-w1r41ff7.d.ts} +6 -4
- package/dist/serverRequestTypes-w1r41ff7.d.ts.map +1 -0
- package/dist/{serverResponseGuards-DRMHmfXh.d.cts → serverResponseGuards-DEyNjgwq.d.cts} +2 -2
- package/dist/{serverResponseGuards-DRMHmfXh.d.cts.map → serverResponseGuards-DEyNjgwq.d.cts.map} +1 -1
- package/dist/{serverResponseGuards-DpbZvJfL.d.ts → serverResponseGuards-DNJZw8yq.d.ts} +2 -2
- package/dist/{serverResponseGuards-DpbZvJfL.d.ts.map → serverResponseGuards-DNJZw8yq.d.ts.map} +1 -1
- package/dist/signing/buildSignedMobileRequest.cjs +1 -1
- package/dist/signing/buildSignedMobileRequest.d.cts +1 -1
- package/dist/signing/buildSignedMobileRequest.d.ts +1 -1
- package/dist/signing/canonicalize.cjs +0 -1
- 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 +0 -1
- package/dist/signing/canonicalize.js.map +1 -1
- package/dist/signing/eip712MethodByType.cjs +1 -2
- package/dist/signing/eip712MethodByType.cjs.map +1 -1
- package/dist/signing/eip712MethodByType.d.cts +1 -1
- package/dist/signing/eip712MethodByType.d.ts +1 -1
- package/dist/signing/eip712MethodByType.js +1 -2
- package/dist/signing/eip712MethodByType.js.map +1 -1
- package/dist/signing/index.d.cts +5 -5
- package/dist/signing/index.d.ts +5 -5
- package/dist/signing/payloadHash.cjs +1 -1
- 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.cjs +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 +8 -8
- package/dist/types/index.d.ts +8 -8
- package/dist/types/mobileErrorCodes.cjs +1 -1
- package/dist/types/serverBaseTypes.d.cts +1 -1
- package/dist/types/serverBaseTypes.d.ts +1 -1
- package/dist/types/serverExecuteTypes.d.cts +1 -1
- package/dist/types/serverExecuteTypes.d.ts +1 -1
- 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-CQE3HD2V.d.ts → types-BycRkqAj.d.cts} +3 -5
- package/dist/types-BycRkqAj.d.cts.map +1 -0
- package/dist/{types-bNB98pYk.d.cts → types-DNd9S0Rz.d.ts} +3 -5
- package/dist/types-DNd9S0Rz.d.ts.map +1 -0
- package/dist/utils/index.d.cts +1 -1
- package/dist/utils/index.d.ts +1 -1
- 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 +24 -18
- package/src/dataMappers.ts +10 -7
- package/src/signing/canonicalize.ts +0 -2
- package/src/signing/eip712MethodByType.ts +0 -1
- package/src/signing/signing.test.ts +0 -8
- package/src/signing/types.ts +1 -2
- package/src/types/clientTypes.ts +7 -4
- package/src/types/serverModelTypes.ts +0 -11
- package/src/types/serverQueryTypes.ts +12 -5
- package/src/types/serverRequestTypes.ts +1 -1
- package/dist/MobileClient-_i0ZV6Dq.cjs.map +0 -1
- package/dist/canonicalize-QNARV_Xc.d.cts.map +0 -1
- package/dist/canonicalize-wVdGejB1.d.ts.map +0 -1
- package/dist/clientTypes-6utzUU-b.d.ts.map +0 -1
- package/dist/clientTypes-D9qgtNlE.d.cts.map +0 -1
- package/dist/eip712MethodByType-CroIPqsJ.d.cts.map +0 -1
- package/dist/eip712MethodByType-DBUy4AdI.d.ts.map +0 -1
- package/dist/payloadHash-B0tlFOK8.d.cts.map +0 -1
- package/dist/payloadHash-D1yTQSF4.d.ts.map +0 -1
- package/dist/serverQueryTypes-9H6P1vJ5.d.cts.map +0 -1
- package/dist/serverQueryTypes-Cbjx0bIj.d.ts.map +0 -1
- package/dist/serverRequestTypes-CHDk6JwE.d.cts.map +0 -1
- package/dist/serverRequestTypes-DYTLrCpz.d.ts.map +0 -1
- package/dist/types-CQE3HD2V.d.ts.map +0 -1
- package/dist/types-bNB98pYk.d.cts.map +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"serverModelTypes.js","names":[],"sources":["../../src/types/serverModelTypes.ts"],"sourcesContent":["import { BalanceSide } from '@nadohq/shared';\nimport { Hex } from 'viem';\n\n/**\n * Platform of a device registered for push notifications.\n */\nexport type MobileNotificationPlatform = 'ios' | 'android';\n\n/**\n * Category of push notification.\n */\nexport type MobileNotificationCategory =\n | 'order_fill'\n | 'order_update'\n | 'liquidation'\n | 'funding'\n | 'product_listing'\n | 'announcement';\n\n/**\n * Server-side public profile shape (snake_case). Name fields are `null` until the subaccount claims a\n * username.\n */\nexport interface MobileServerProfile {\n subaccount: Hex;\n username: string | null;\n display_name: string | null;\n private_mode: boolean;\n}\n\n/**\n * Server-side identity shape (snake_case) returned by the signed `self_identity` query. Name fields are\n * `null` until the subaccount claims a username.\n */\nexport interface MobileServerIdentity {\n subaccount: Hex;\n username: string | null;\n display_name: string | null;\n private_mode: boolean;\n}\n\n/**\n * Direction of the position a feed trade resulted in — for `closed`, the direction that was closed. This is\n * NOT the execution buy/sell side, which the feed does not expose. Aliases {@link BalanceSide} so the feed's\n * direction values stay in lockstep with the rest of the SDK.\n */\nexport type MobileFeedTradePositionDirection = BalanceSide;\n\n/**\n * Every {@link MobileFeedTradePositionDirection} the feed can report, for callers that need the values at\n * runtime (validation, filters, UI enumeration).\n */\nexport const MOBILE_FEED_TRADE_POSITION_DIRECTIONS = [\n 'long',\n 'short',\n] as const satisfies readonly MobileFeedTradePositionDirection[];\n\n/**\n * Every {@link MobileFeedTradePositionEffect} the feed can report, for callers that need the values at\n * runtime (validation, filters, UI enumeration).\n */\nexport const MOBILE_FEED_TRADE_POSITION_EFFECTS = [\n 'opened',\n 'increased',\n 'reduced',\n 'closed',\n 'flipped',\n] as const;\n\n/**\n * How a feed trade changed the trader's position in the product.\n */\nexport type MobileFeedTradePositionEffect =\n (typeof MOBILE_FEED_TRADE_POSITION_EFFECTS)[number];\n\n/**\n * Position change of a feed trade. Both keys are single words, so the wire and client shapes are identical\n * and this type is shared by {@link MobileServerFeedTrade} and the client-side `MobileFeedTrade`.\n */\nexport interface MobileFeedTradePosition {\n direction: MobileFeedTradePositionDirection;\n effect: MobileFeedTradePositionEffect;\n}\n\n/**\n * Every {@link MobileFeedMarginMode} the feed can report, for callers that need the values at runtime\n * (validation, filters, UI enumeration).\n */\nexport const MOBILE_FEED_MARGIN_MODES = ['cross', 'isolated'] as const;\n\n/**\n * Margin mode a feed trade was executed under. Shared by the wire and client margin shapes.\n */\nexport type MobileFeedMarginMode = (typeof MOBILE_FEED_MARGIN_MODES)[number];\n\n/**\n * Server-side margin of a feed trade. Branch on `mode` — do not infer isolated state from leverage presence:\n * `estimated_leverage` (a rounded whole-number estimate, not exact submitted leverage) is omitted on `cross`,\n * and also omitted inside `isolated` when no estimate is available.\n */\nexport interface MobileServerFeedMargin {\n mode: MobileFeedMarginMode;\n estimated_leverage?: number;\n}\n\n/**\n * Server-side feed trade shape (snake_case): one row per order digest, enriched at read time with the\n * trader's current identity. Amounts are display-oriented human-unit JSON numbers — do not use them for\n * accounting, order construction, or exact threshold decisions.\n */\nexport interface MobileServerFeedTrade {\n /** Order digest this row is keyed by; the stable id clients use to reconcile live pagination. */\n order_digest: Hex;\n subaccount: Hex;\n username: string | null;\n display_name: string | null;\n /** Reserved for a future avatar source; `null` until one is implemented. */\n avatar_url: string | null;\n product_id: number;\n /** Executed quantity in human units. */\n quantity: number;\n /** Trade notional in whole-dollar human units. */\n notional: number;\n /** Average execution price in human units. */\n average_price: number;\n margin: MobileServerFeedMargin;\n position: MobileFeedTradePosition;\n /** Realized PnL of the trade in human units; can be negative. */\n realized_pnl: number;\n /** Fill time as JavaScript-safe integer Unix milliseconds. */\n filled_at_ms: number;\n}\n\n/**\n * Server-side scope limiting a notification category preference. Scopes are rejected by the backend for the\n * MVP (`scopes` must be empty) but are part of the wire format.\n */\nexport type MobileServerNotificationPreferenceScope =\n | { type: 'subaccount'; subaccount: Hex }\n | { type: 'product'; product_id: number };\n\n/**\n * Server-side per-category notification preference (snake_case).\n */\nexport interface MobileServerNotificationCategoryPreference {\n category: MobileNotificationCategory;\n enabled: boolean;\n scopes: MobileServerNotificationPreferenceScope[];\n}\n\n/**\n * Server-side notification preferences shape (snake_case), used in both the `update_preferences` public\n * execute and the `notification_preferences` public query response.\n */\nexport interface MobileServerNotificationPreferences {\n /** Only `1` is accepted by the backend for the MVP. */\n schema_version: 1;\n categories: MobileServerNotificationCategoryPreference[];\n}\n
|
|
1
|
+
{"version":3,"file":"serverModelTypes.js","names":[],"sources":["../../src/types/serverModelTypes.ts"],"sourcesContent":["import { BalanceSide } from '@nadohq/shared';\nimport { Hex } from 'viem';\n\n/**\n * Platform of a device registered for push notifications.\n */\nexport type MobileNotificationPlatform = 'ios' | 'android';\n\n/**\n * Category of push notification.\n */\nexport type MobileNotificationCategory =\n | 'order_fill'\n | 'order_update'\n | 'liquidation'\n | 'funding'\n | 'product_listing'\n | 'announcement';\n\n/**\n * Server-side public profile shape (snake_case). Name fields are `null` until the subaccount claims a\n * username.\n */\nexport interface MobileServerProfile {\n subaccount: Hex;\n username: string | null;\n display_name: string | null;\n private_mode: boolean;\n}\n\n/**\n * Server-side identity shape (snake_case) returned by the signed `self_identity` query. Name fields are\n * `null` until the subaccount claims a username.\n */\nexport interface MobileServerIdentity {\n subaccount: Hex;\n username: string | null;\n display_name: string | null;\n private_mode: boolean;\n}\n\n/**\n * Direction of the position a feed trade resulted in — for `closed`, the direction that was closed. This is\n * NOT the execution buy/sell side, which the feed does not expose. Aliases {@link BalanceSide} so the feed's\n * direction values stay in lockstep with the rest of the SDK.\n */\nexport type MobileFeedTradePositionDirection = BalanceSide;\n\n/**\n * Every {@link MobileFeedTradePositionDirection} the feed can report, for callers that need the values at\n * runtime (validation, filters, UI enumeration).\n */\nexport const MOBILE_FEED_TRADE_POSITION_DIRECTIONS = [\n 'long',\n 'short',\n] as const satisfies readonly MobileFeedTradePositionDirection[];\n\n/**\n * Every {@link MobileFeedTradePositionEffect} the feed can report, for callers that need the values at\n * runtime (validation, filters, UI enumeration).\n */\nexport const MOBILE_FEED_TRADE_POSITION_EFFECTS = [\n 'opened',\n 'increased',\n 'reduced',\n 'closed',\n 'flipped',\n] as const;\n\n/**\n * How a feed trade changed the trader's position in the product.\n */\nexport type MobileFeedTradePositionEffect =\n (typeof MOBILE_FEED_TRADE_POSITION_EFFECTS)[number];\n\n/**\n * Position change of a feed trade. Both keys are single words, so the wire and client shapes are identical\n * and this type is shared by {@link MobileServerFeedTrade} and the client-side `MobileFeedTrade`.\n */\nexport interface MobileFeedTradePosition {\n direction: MobileFeedTradePositionDirection;\n effect: MobileFeedTradePositionEffect;\n}\n\n/**\n * Every {@link MobileFeedMarginMode} the feed can report, for callers that need the values at runtime\n * (validation, filters, UI enumeration).\n */\nexport const MOBILE_FEED_MARGIN_MODES = ['cross', 'isolated'] as const;\n\n/**\n * Margin mode a feed trade was executed under. Shared by the wire and client margin shapes.\n */\nexport type MobileFeedMarginMode = (typeof MOBILE_FEED_MARGIN_MODES)[number];\n\n/**\n * Server-side margin of a feed trade. Branch on `mode` — do not infer isolated state from leverage presence:\n * `estimated_leverage` (a rounded whole-number estimate, not exact submitted leverage) is omitted on `cross`,\n * and also omitted inside `isolated` when no estimate is available.\n */\nexport interface MobileServerFeedMargin {\n mode: MobileFeedMarginMode;\n estimated_leverage?: number;\n}\n\n/**\n * Server-side feed trade shape (snake_case): one row per order digest, enriched at read time with the\n * trader's current identity. Amounts are display-oriented human-unit JSON numbers — do not use them for\n * accounting, order construction, or exact threshold decisions.\n */\nexport interface MobileServerFeedTrade {\n /** Order digest this row is keyed by; the stable id clients use to reconcile live pagination. */\n order_digest: Hex;\n subaccount: Hex;\n username: string | null;\n display_name: string | null;\n /** Reserved for a future avatar source; `null` until one is implemented. */\n avatar_url: string | null;\n product_id: number;\n /** Executed quantity in human units. */\n quantity: number;\n /** Trade notional in whole-dollar human units. */\n notional: number;\n /** Average execution price in human units. */\n average_price: number;\n margin: MobileServerFeedMargin;\n position: MobileFeedTradePosition;\n /** Realized PnL of the trade in human units; can be negative. */\n realized_pnl: number;\n /** Fill time as JavaScript-safe integer Unix milliseconds. */\n filled_at_ms: number;\n}\n\n/**\n * Server-side scope limiting a notification category preference. Scopes are rejected by the backend for the\n * MVP (`scopes` must be empty) but are part of the wire format.\n */\nexport type MobileServerNotificationPreferenceScope =\n | { type: 'subaccount'; subaccount: Hex }\n | { type: 'product'; product_id: number };\n\n/**\n * Server-side per-category notification preference (snake_case).\n */\nexport interface MobileServerNotificationCategoryPreference {\n category: MobileNotificationCategory;\n enabled: boolean;\n scopes: MobileServerNotificationPreferenceScope[];\n}\n\n/**\n * Server-side notification preferences shape (snake_case), used in both the `update_preferences` public\n * execute and the `notification_preferences` public query response.\n */\nexport interface MobileServerNotificationPreferences {\n /** Only `1` is accepted by the backend for the MVP. */\n schema_version: 1;\n categories: MobileServerNotificationCategoryPreference[];\n}\n"],"mappings":";;;;;AAoDA,MAAa,wCAAwC,CACnD,QACA,OACF;;;;;AAMA,MAAa,qCAAqC;CAChD;CACA;CACA;CACA;CACA;AACF;;;;;AAqBA,MAAa,2BAA2B,CAAC,SAAS,UAAU"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { a as MobileServerPublicQueryResponseByType, c as MobileServerSelfIdentityResponse, d as MobileServerUsernameAvailabilityResponse, i as MobileServerPublicQueryRequest, l as MobileServerSignedQueryResponseByType, n as MobileServerNotificationPreferencesResponse, o as MobileServerPublicQuerySuccessResponse, r as MobileServerProfileResponse, s as
|
|
2
|
-
export { MobileServerFeedResponse, MobileServerNotificationPreferencesResponse, MobileServerProfileResponse, MobileServerPublicQueryRequest, MobileServerPublicQueryResponseByType, MobileServerPublicQuerySuccessResponse,
|
|
1
|
+
import { a as MobileServerPublicQueryResponseByType, c as MobileServerSelfIdentityResponse, d as MobileServerUsernameAvailabilityResponse, i as MobileServerPublicQueryRequest, l as MobileServerSignedQueryResponseByType, n as MobileServerNotificationPreferencesResponse, o as MobileServerPublicQuerySuccessResponse, r as MobileServerProfileResponse, s as MobileServerRegisteredWalletResponse, t as MobileServerFeedResponse, u as MobileServerSignedQuerySuccessResponse } from "../serverQueryTypes-C_rvZnol.cjs";
|
|
2
|
+
export { MobileServerFeedResponse, MobileServerNotificationPreferencesResponse, MobileServerProfileResponse, MobileServerPublicQueryRequest, MobileServerPublicQueryResponseByType, MobileServerPublicQuerySuccessResponse, MobileServerRegisteredWalletResponse, MobileServerSelfIdentityResponse, MobileServerSignedQueryResponseByType, MobileServerSignedQuerySuccessResponse, MobileServerUsernameAvailabilityResponse };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { a as MobileServerPublicQueryResponseByType, c as MobileServerSelfIdentityResponse, d as MobileServerUsernameAvailabilityResponse, i as MobileServerPublicQueryRequest, l as MobileServerSignedQueryResponseByType, n as MobileServerNotificationPreferencesResponse, o as MobileServerPublicQuerySuccessResponse, r as MobileServerProfileResponse, s as
|
|
2
|
-
export { MobileServerFeedResponse, MobileServerNotificationPreferencesResponse, MobileServerProfileResponse, MobileServerPublicQueryRequest, MobileServerPublicQueryResponseByType, MobileServerPublicQuerySuccessResponse,
|
|
1
|
+
import { a as MobileServerPublicQueryResponseByType, c as MobileServerSelfIdentityResponse, d as MobileServerUsernameAvailabilityResponse, i as MobileServerPublicQueryRequest, l as MobileServerSignedQueryResponseByType, n as MobileServerNotificationPreferencesResponse, o as MobileServerPublicQuerySuccessResponse, r as MobileServerProfileResponse, s as MobileServerRegisteredWalletResponse, t as MobileServerFeedResponse, u as MobileServerSignedQuerySuccessResponse } from "../serverQueryTypes-4J8qNQld.js";
|
|
2
|
+
export { MobileServerFeedResponse, MobileServerNotificationPreferencesResponse, MobileServerProfileResponse, MobileServerPublicQueryRequest, MobileServerPublicQueryResponseByType, MobileServerPublicQuerySuccessResponse, MobileServerRegisteredWalletResponse, MobileServerSelfIdentityResponse, MobileServerSignedQueryResponseByType, MobileServerSignedQuerySuccessResponse, MobileServerUsernameAvailabilityResponse };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { a as MobileServerPublicQueryRequestType, c as MobileServerSignedQueryRequestType, i as MobileServerPublicQueryRequestByType, n as MobileServerPublicExecuteRequestByType, o as MobileServerRequestType, r as MobileServerPublicExecuteRequestType, s as MobileServerSignedQueryRequestByType, t as MobileServerExecuteRequestType } from "../serverRequestTypes-
|
|
1
|
+
import { a as MobileServerPublicQueryRequestType, c as MobileServerSignedQueryRequestType, i as MobileServerPublicQueryRequestByType, n as MobileServerPublicExecuteRequestByType, o as MobileServerRequestType, r as MobileServerPublicExecuteRequestType, s as MobileServerSignedQueryRequestByType, t as MobileServerExecuteRequestType } from "../serverRequestTypes-Cw661qjM.cjs";
|
|
2
2
|
export { MobileServerExecuteRequestType, MobileServerPublicExecuteRequestByType, MobileServerPublicExecuteRequestType, MobileServerPublicQueryRequestByType, MobileServerPublicQueryRequestType, MobileServerRequestType, MobileServerSignedQueryRequestByType, MobileServerSignedQueryRequestType };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { a as MobileServerPublicQueryRequestType, c as MobileServerSignedQueryRequestType, i as MobileServerPublicQueryRequestByType, n as MobileServerPublicExecuteRequestByType, o as MobileServerRequestType, r as MobileServerPublicExecuteRequestType, s as MobileServerSignedQueryRequestByType, t as MobileServerExecuteRequestType } from "../serverRequestTypes-
|
|
1
|
+
import { a as MobileServerPublicQueryRequestType, c as MobileServerSignedQueryRequestType, i as MobileServerPublicQueryRequestByType, n as MobileServerPublicExecuteRequestByType, o as MobileServerRequestType, r as MobileServerPublicExecuteRequestType, s as MobileServerSignedQueryRequestByType, t as MobileServerExecuteRequestType } from "../serverRequestTypes-w1r41ff7.js";
|
|
2
2
|
export { MobileServerExecuteRequestType, MobileServerPublicExecuteRequestByType, MobileServerPublicExecuteRequestType, MobileServerPublicQueryRequestByType, MobileServerPublicQueryRequestType, MobileServerRequestType, MobileServerSignedQueryRequestByType, MobileServerSignedQueryRequestType };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { l as MobileNotificationPlatform } from "./serverModelTypes-
|
|
2
|
-
import { y as MobileSignedRequestParams } from "./clientTypes-
|
|
1
|
+
import { l as MobileNotificationPlatform } from "./serverModelTypes-DGYc_3XP.cjs";
|
|
2
|
+
import { y as MobileSignedRequestParams } from "./clientTypes-DIipTg9D.cjs";
|
|
3
3
|
import { WalletClientWithAccount } from "@nadohq/shared";
|
|
4
4
|
import { Hex } from "viem";
|
|
5
5
|
|
|
@@ -27,8 +27,6 @@ type MobileSignedInner = {
|
|
|
27
27
|
platform: MobileNotificationPlatform;
|
|
28
28
|
locale: string | null;
|
|
29
29
|
app_version: string | null;
|
|
30
|
-
} | {
|
|
31
|
-
type: 'registered_devices';
|
|
32
30
|
};
|
|
33
31
|
/**
|
|
34
32
|
* Type-specific payload fields for a signed inner request of a given `type` (the inner payload without its
|
|
@@ -59,4 +57,4 @@ interface BuildSignedMobileRequestParams extends MobileSignedRequestParams {
|
|
|
59
57
|
}
|
|
60
58
|
//#endregion
|
|
61
59
|
export { MobileSignedRequest as i, MobileSignedInner as n, MobileSignedInnerParams as r, BuildSignedMobileRequestParams as t };
|
|
62
|
-
//# sourceMappingURL=types-
|
|
60
|
+
//# sourceMappingURL=types-BycRkqAj.d.cts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types-BycRkqAj.d.cts","names":[],"sources":["../src/signing/src/signing/types.ts"],"mappings":";;;;;;;;AAcA;;;;;;;KAAY,iBAAA;EACN,IAAA;EAAsB,YAAA;AAAA;EACtB,IAAA;EAA0B,YAAA;AAAA;EAC1B,IAAA;AAAA;EAEA,IAAA;EACA,UAAA;EACA,QAAA,EAAU,0BAA0B;EAGpC,MAAA;EACA,WAAA;AAAA;;;;;KAOM,uBAAA,WAAkC,iBAAA,YAA6B,IAAA,CACzE,OAAA,CAAQ,iBAAA;EAAqB,IAAA,EAAM,CAAA;AAAA;;;;;KAQzB,mBAAA,WACA,iBAAA,GAAoB,iBAAA,IAC5B,CAAA;EACF,SAAA,EAAW,GAAA;EACX,MAAA,EAAQ,GAAA;EACR,KAAA;AAAA;;;;UAMe,8BAAA,SAAuC,yBAAA;EACtD,YAAA,EAAc,uBAAA;EACd,KAAA,EAAO,iBAAA;EATI;;;EAaX,KAAA;AAAA"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { l as MobileNotificationPlatform } from "./serverModelTypes-
|
|
2
|
-
import { y as MobileSignedRequestParams } from "./clientTypes-
|
|
1
|
+
import { l as MobileNotificationPlatform } from "./serverModelTypes-BIGPd52y.js";
|
|
2
|
+
import { y as MobileSignedRequestParams } from "./clientTypes-DqDZEcBu.js";
|
|
3
3
|
import { WalletClientWithAccount } from "@nadohq/shared";
|
|
4
4
|
import { Hex } from "viem";
|
|
5
5
|
|
|
@@ -27,8 +27,6 @@ type MobileSignedInner = {
|
|
|
27
27
|
platform: MobileNotificationPlatform;
|
|
28
28
|
locale: string | null;
|
|
29
29
|
app_version: string | null;
|
|
30
|
-
} | {
|
|
31
|
-
type: 'registered_devices';
|
|
32
30
|
};
|
|
33
31
|
/**
|
|
34
32
|
* Type-specific payload fields for a signed inner request of a given `type` (the inner payload without its
|
|
@@ -59,4 +57,4 @@ interface BuildSignedMobileRequestParams extends MobileSignedRequestParams {
|
|
|
59
57
|
}
|
|
60
58
|
//#endregion
|
|
61
59
|
export { MobileSignedRequest as i, MobileSignedInner as n, MobileSignedInnerParams as r, BuildSignedMobileRequestParams as t };
|
|
62
|
-
//# sourceMappingURL=types-
|
|
60
|
+
//# sourceMappingURL=types-DNd9S0Rz.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types-DNd9S0Rz.d.ts","names":[],"sources":["../src/signing/src/signing/types.ts"],"mappings":";;;;;;;;AAcA;;;;;;;KAAY,iBAAA;EACN,IAAA;EAAsB,YAAA;AAAA;EACtB,IAAA;EAA0B,YAAA;AAAA;EAC1B,IAAA;AAAA;EAEA,IAAA;EACA,UAAA;EACA,QAAA,EAAU,0BAA0B;EAGpC,MAAA;EACA,WAAA;AAAA;;;;;KAOM,uBAAA,WAAkC,iBAAA,YAA6B,IAAA,CACzE,OAAA,CAAQ,iBAAA;EAAqB,IAAA,EAAM,CAAA;AAAA;;;;;KAQzB,mBAAA,WACA,iBAAA,GAAoB,iBAAA,IAC5B,CAAA;EACF,SAAA,EAAW,GAAA;EACX,MAAA,EAAQ,GAAA;EACR,KAAA;AAAA;;;;UAMe,8BAAA,SAAuC,yBAAA;EACtD,YAAA,EAAc,uBAAA;EACd,KAAA,EAAO,iBAAA;EATI;;;EAaX,KAAA;AAAA"}
|
package/dist/utils/index.d.cts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import { n as MOBILE_FEED_MIN_NOTIONAL_FLOOR, t as MOBILE_FEED_MAX_PAGE_SIZE } from "../feed-CBIwOhTO.cjs";
|
|
2
2
|
import { t as MOBILE_DISPLAY_NAME_PATTERN } from "../patterns-Db6fgz8i.cjs";
|
|
3
|
-
import { n as isMobileServerSuccessResponse, t as isMobileServerFailureResponse } from "../serverResponseGuards-
|
|
3
|
+
import { n as isMobileServerSuccessResponse, t as isMobileServerFailureResponse } from "../serverResponseGuards-DEyNjgwq.cjs";
|
|
4
4
|
export { MOBILE_DISPLAY_NAME_PATTERN, MOBILE_FEED_MAX_PAGE_SIZE, MOBILE_FEED_MIN_NOTIONAL_FLOOR, isMobileServerFailureResponse, isMobileServerSuccessResponse };
|
package/dist/utils/index.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
import { n as MOBILE_FEED_MIN_NOTIONAL_FLOOR, t as MOBILE_FEED_MAX_PAGE_SIZE } from "../feed-BF5k6Ryu.js";
|
|
2
2
|
import { t as MOBILE_DISPLAY_NAME_PATTERN } from "../patterns-B5gi7OfV.js";
|
|
3
|
-
import { n as isMobileServerSuccessResponse, t as isMobileServerFailureResponse } from "../serverResponseGuards-
|
|
3
|
+
import { n as isMobileServerSuccessResponse, t as isMobileServerFailureResponse } from "../serverResponseGuards-DNJZw8yq.js";
|
|
4
4
|
export { MOBILE_DISPLAY_NAME_PATTERN, MOBILE_FEED_MAX_PAGE_SIZE, MOBILE_FEED_MIN_NOTIONAL_FLOOR, isMobileServerFailureResponse, isMobileServerSuccessResponse };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { n as isMobileServerSuccessResponse, t as isMobileServerFailureResponse } from "../serverResponseGuards-
|
|
1
|
+
import { n as isMobileServerSuccessResponse, t as isMobileServerFailureResponse } from "../serverResponseGuards-DEyNjgwq.cjs";
|
|
2
2
|
export { isMobileServerFailureResponse, isMobileServerSuccessResponse };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { n as isMobileServerSuccessResponse, t as isMobileServerFailureResponse } from "../serverResponseGuards-
|
|
1
|
+
import { n as isMobileServerSuccessResponse, t as isMobileServerFailureResponse } from "../serverResponseGuards-DNJZw8yq.js";
|
|
2
2
|
export { isMobileServerFailureResponse, isMobileServerSuccessResponse };
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@nadohq/mobile-client",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.34.0",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"sideEffects": false,
|
|
6
6
|
"description": "HTTP client for the Nado mobile service API — username claims, profiles, privacy settings, and push notification devices & preferences",
|
|
@@ -42,7 +42,7 @@
|
|
|
42
42
|
"types": "./dist/index.d.ts",
|
|
43
43
|
"dependencies": {
|
|
44
44
|
"@msgpack/msgpack": "3.1.3",
|
|
45
|
-
"@nadohq/shared": "^0.
|
|
45
|
+
"@nadohq/shared": "^0.34.0",
|
|
46
46
|
"axios": "1.16.1"
|
|
47
47
|
},
|
|
48
48
|
"peerDependencies": {
|
|
@@ -54,5 +54,5 @@
|
|
|
54
54
|
"bignumber.js": "11.1.1",
|
|
55
55
|
"viem": "2.52.0"
|
|
56
56
|
},
|
|
57
|
-
"gitHead": "
|
|
57
|
+
"gitHead": "a8dd2f31219463c5a4565ee535064ec2e2bdfb6b"
|
|
58
58
|
}
|
package/src/MobileClient.ts
CHANGED
|
@@ -10,7 +10,7 @@ import {
|
|
|
10
10
|
mapMobileNotificationPreferences,
|
|
11
11
|
mapMobileNotificationPreferencesToServer,
|
|
12
12
|
mapMobilePublicProfile,
|
|
13
|
-
|
|
13
|
+
mapMobileRegisteredWallet,
|
|
14
14
|
} from './dataMappers';
|
|
15
15
|
import {
|
|
16
16
|
buildSignedMobileRequest,
|
|
@@ -22,14 +22,14 @@ import {
|
|
|
22
22
|
GetMobileFeedParams,
|
|
23
23
|
GetMobileNotificationPreferencesParams,
|
|
24
24
|
GetMobilePublicProfileParams,
|
|
25
|
-
|
|
25
|
+
GetMobileRegisteredWalletParams,
|
|
26
26
|
GetMobileSelfIdentityParams,
|
|
27
27
|
GetMobileUsernameAvailabilityParams,
|
|
28
28
|
MobileFeedPage,
|
|
29
29
|
MobileIdentity,
|
|
30
30
|
MobileNotificationPreferences,
|
|
31
31
|
MobilePublicProfile,
|
|
32
|
-
|
|
32
|
+
MobileRegisteredWallet,
|
|
33
33
|
MobileRegisterExpoTokenParams,
|
|
34
34
|
MobileSetPrivateModeParams,
|
|
35
35
|
MobileSetUsernameParams,
|
|
@@ -184,6 +184,27 @@ export class MobileClient {
|
|
|
184
184
|
return mapMobileNotificationPreferences(data.preferences);
|
|
185
185
|
}
|
|
186
186
|
|
|
187
|
+
/**
|
|
188
|
+
* Resolves the wallet that an Expo push token is currently registered to, along with the redacted metadata
|
|
189
|
+
* of the device that registered it. Unsigned — the token identifies the wallet on its own. Use it to check
|
|
190
|
+
* whether a locally held token is still active and which wallet currently owns it, since registering the
|
|
191
|
+
* same token under another wallet transfers ownership.
|
|
192
|
+
*
|
|
193
|
+
* @throws {MobileServerFailureError} With error code `INVALID_EXPO_TOKEN` if the token is malformed, or is
|
|
194
|
+
* not currently registered to a wallet — including a token that was unregistered. The backend does not
|
|
195
|
+
* distinguish those cases.
|
|
196
|
+
*/
|
|
197
|
+
async getRegisteredWallet(
|
|
198
|
+
params: GetMobileRegisteredWalletParams,
|
|
199
|
+
): Promise<MobileRegisteredWallet> {
|
|
200
|
+
const body: MobileServerPublicQueryRequest<'registered_wallet'> = {
|
|
201
|
+
type: 'registered_wallet',
|
|
202
|
+
expo_token: params.expoToken,
|
|
203
|
+
};
|
|
204
|
+
const data = await this.publicQuery(body);
|
|
205
|
+
return mapMobileRegisteredWallet(data);
|
|
206
|
+
}
|
|
207
|
+
|
|
187
208
|
/*
|
|
188
209
|
Public executes
|
|
189
210
|
*/
|
|
@@ -255,21 +276,6 @@ export class MobileClient {
|
|
|
255
276
|
return data.identity ? mapMobileIdentity(data.identity) : null;
|
|
256
277
|
}
|
|
257
278
|
|
|
258
|
-
/**
|
|
259
|
-
* Fetches the devices registered for push notifications for a wallet.
|
|
260
|
-
*/
|
|
261
|
-
async getRegisteredDevices(
|
|
262
|
-
params: GetMobileRegisteredDevicesParams,
|
|
263
|
-
): Promise<MobileRegisteredDevice[]> {
|
|
264
|
-
const signedRequest = await this.getSignedRequest(
|
|
265
|
-
'registered_devices',
|
|
266
|
-
params,
|
|
267
|
-
{},
|
|
268
|
-
);
|
|
269
|
-
const data = await this.query<'registered_devices'>(signedRequest);
|
|
270
|
-
return data.devices.map(mapMobileRegisteredDevice);
|
|
271
|
-
}
|
|
272
|
-
|
|
273
279
|
/*
|
|
274
280
|
Signed executes
|
|
275
281
|
*/
|
package/src/dataMappers.ts
CHANGED
|
@@ -5,7 +5,7 @@ import {
|
|
|
5
5
|
MobileNotificationPreferenceScope,
|
|
6
6
|
MobileNotificationPreferences,
|
|
7
7
|
MobilePublicProfile,
|
|
8
|
-
|
|
8
|
+
MobileRegisteredWallet,
|
|
9
9
|
} from './types/clientTypes';
|
|
10
10
|
import {
|
|
11
11
|
MobileServerFeedTrade,
|
|
@@ -13,9 +13,11 @@ import {
|
|
|
13
13
|
MobileServerNotificationPreferenceScope,
|
|
14
14
|
MobileServerNotificationPreferences,
|
|
15
15
|
MobileServerProfile,
|
|
16
|
-
MobileServerRegisteredDevice,
|
|
17
16
|
} from './types/serverModelTypes';
|
|
18
|
-
import {
|
|
17
|
+
import {
|
|
18
|
+
MobileServerFeedResponse,
|
|
19
|
+
MobileServerRegisteredWalletResponse,
|
|
20
|
+
} from './types/serverQueryTypes';
|
|
19
21
|
|
|
20
22
|
/**
|
|
21
23
|
* Maps a server-side identity (snake_case) to its client-side (camelCase) representation.
|
|
@@ -132,12 +134,13 @@ export function mapMobileFeedPage(
|
|
|
132
134
|
}
|
|
133
135
|
|
|
134
136
|
/**
|
|
135
|
-
* Maps a server-side registered
|
|
137
|
+
* Maps a server-side registered wallet (snake_case) to its client-side (camelCase) representation.
|
|
136
138
|
*/
|
|
137
|
-
export function
|
|
138
|
-
server:
|
|
139
|
-
):
|
|
139
|
+
export function mapMobileRegisteredWallet(
|
|
140
|
+
server: MobileServerRegisteredWalletResponse,
|
|
141
|
+
): MobileRegisteredWallet {
|
|
140
142
|
return {
|
|
143
|
+
wallet: server.wallet,
|
|
141
144
|
platform: server.platform,
|
|
142
145
|
locale: server.locale,
|
|
143
146
|
appVersion: server.app_version,
|
|
@@ -25,8 +25,6 @@ export function canonicalizeMobileInner(
|
|
|
25
25
|
locale: inner.locale,
|
|
26
26
|
app_version: inner.app_version,
|
|
27
27
|
};
|
|
28
|
-
case 'registered_devices':
|
|
29
|
-
return { type: 'registered_devices' };
|
|
30
28
|
default: {
|
|
31
29
|
throw new Error(
|
|
32
30
|
`canonicalizeMobileInner: unhandled inner payload type: ${JSON.stringify(inner)}`,
|
|
@@ -11,5 +11,4 @@ export const MOBILE_EIP712_METHOD_BY_TYPE: Record<
|
|
|
11
11
|
set_private_mode: 'mobile:execute_set_private_mode',
|
|
12
12
|
self_identity: 'mobile:query_self_identity',
|
|
13
13
|
register_expo_token: 'mobile:execute_register_expo_token',
|
|
14
|
-
registered_devices: 'mobile:query_registered_devices',
|
|
15
14
|
};
|
|
@@ -30,8 +30,6 @@ const PINNED_HASHES = {
|
|
|
30
30
|
'0x10e94c4502cade0a0b4d7469717bcc1d266fc6a3b7635236fa1d3600b58c9954',
|
|
31
31
|
register_expo_token:
|
|
32
32
|
'0x1b9471afc9bde66f9bffd576d3326420e1bade4e16afa3a73ddc65f27155611c',
|
|
33
|
-
registered_devices:
|
|
34
|
-
'0xe77b42e32d27f054f86d5ed52c9aac7b3eed857eb6209ee883c92f01b84d3334',
|
|
35
33
|
} as const;
|
|
36
34
|
|
|
37
35
|
describe('[mobile-client]: signing (offline)', () => {
|
|
@@ -71,12 +69,6 @@ describe('[mobile-client]: signing (offline)', () => {
|
|
|
71
69
|
const hash = getMobilePayloadHash(canonicalizeMobileInner(inner));
|
|
72
70
|
expect(hash).toBe(PINNED_HASHES.register_expo_token);
|
|
73
71
|
});
|
|
74
|
-
|
|
75
|
-
it('registered_devices', () => {
|
|
76
|
-
const inner: MobileSignedInner = { type: 'registered_devices' };
|
|
77
|
-
const hash = getMobilePayloadHash(canonicalizeMobileInner(inner));
|
|
78
|
-
expect(hash).toBe(PINNED_HASHES.registered_devices);
|
|
79
|
-
});
|
|
80
72
|
});
|
|
81
73
|
|
|
82
74
|
it('canonicalizes msgpack key order regardless of input key order', () => {
|
package/src/signing/types.ts
CHANGED
|
@@ -24,8 +24,7 @@ export type MobileSignedInner =
|
|
|
24
24
|
// backend, which serializes `Option::None` as nil under the same key.
|
|
25
25
|
locale: string | null;
|
|
26
26
|
app_version: string | null;
|
|
27
|
-
}
|
|
28
|
-
| { type: 'registered_devices' };
|
|
27
|
+
};
|
|
29
28
|
|
|
30
29
|
/**
|
|
31
30
|
* Type-specific payload fields for a signed inner request of a given `type` (the inner payload without its
|
package/src/types/clientTypes.ts
CHANGED
|
@@ -132,9 +132,12 @@ export interface MobileNotificationPreferences {
|
|
|
132
132
|
}
|
|
133
133
|
|
|
134
134
|
/**
|
|
135
|
-
*
|
|
135
|
+
* The wallet an Expo push token is currently registered to, alongside the redacted metadata of the device
|
|
136
|
+
* that registered it.
|
|
136
137
|
*/
|
|
137
|
-
export interface
|
|
138
|
+
export interface MobileRegisteredWallet {
|
|
139
|
+
/** Address of the wallet that owns the token's active registration. */
|
|
140
|
+
wallet: Hex;
|
|
138
141
|
/** Push platform the device registered under. */
|
|
139
142
|
platform: MobileNotificationPlatform;
|
|
140
143
|
/** BCP-47 locale tag reported at registration, or `null` if none was provided. */
|
|
@@ -255,6 +258,6 @@ export interface MobileUpdateNotificationPreferencesParams extends MobileWithExp
|
|
|
255
258
|
export type GetMobileNotificationPreferencesParams = MobileWithExpoTokenParams;
|
|
256
259
|
|
|
257
260
|
/**
|
|
258
|
-
* Params for {@link MobileClient.
|
|
261
|
+
* Params for {@link MobileClient.getRegisteredWallet}.
|
|
259
262
|
*/
|
|
260
|
-
export type
|
|
263
|
+
export type GetMobileRegisteredWalletParams = MobileWithExpoTokenParams;
|
|
@@ -157,14 +157,3 @@ export interface MobileServerNotificationPreferences {
|
|
|
157
157
|
schema_version: 1;
|
|
158
158
|
categories: MobileServerNotificationCategoryPreference[];
|
|
159
159
|
}
|
|
160
|
-
|
|
161
|
-
/**
|
|
162
|
-
* Server-side registered push device shape (snake_case).
|
|
163
|
-
*/
|
|
164
|
-
export interface MobileServerRegisteredDevice {
|
|
165
|
-
platform: MobileNotificationPlatform;
|
|
166
|
-
locale: string | null;
|
|
167
|
-
app_version: string | null;
|
|
168
|
-
token_fingerprint_prefix: string;
|
|
169
|
-
last_seen_at: number;
|
|
170
|
-
}
|
|
@@ -1,10 +1,11 @@
|
|
|
1
|
+
import { Hex } from 'viem';
|
|
1
2
|
import { MobileServerSuccessResponse } from './serverBaseTypes';
|
|
2
3
|
import {
|
|
4
|
+
MobileNotificationPlatform,
|
|
3
5
|
MobileServerFeedTrade,
|
|
4
6
|
MobileServerIdentity,
|
|
5
7
|
MobileServerNotificationPreferences,
|
|
6
8
|
MobileServerProfile,
|
|
7
|
-
MobileServerRegisteredDevice,
|
|
8
9
|
} from './serverModelTypes';
|
|
9
10
|
import {
|
|
10
11
|
MobileServerPublicQueryRequestByType,
|
|
@@ -69,10 +70,16 @@ export interface MobileServerNotificationPreferencesResponse {
|
|
|
69
70
|
}
|
|
70
71
|
|
|
71
72
|
/**
|
|
72
|
-
* Payload of the
|
|
73
|
+
* Payload of the `registered_wallet` public query success response. Inlined into the envelope rather than
|
|
74
|
+
* nested under a key, matching the backend's `RegisteredWalletResponse`.
|
|
73
75
|
*/
|
|
74
|
-
export interface
|
|
75
|
-
|
|
76
|
+
export interface MobileServerRegisteredWalletResponse {
|
|
77
|
+
wallet: Hex;
|
|
78
|
+
platform: MobileNotificationPlatform;
|
|
79
|
+
locale: string | null;
|
|
80
|
+
app_version: string | null;
|
|
81
|
+
token_fingerprint_prefix: string;
|
|
82
|
+
last_seen_at: number;
|
|
76
83
|
}
|
|
77
84
|
|
|
78
85
|
/**
|
|
@@ -86,6 +93,7 @@ export interface MobileServerPublicQueryResponseByType {
|
|
|
86
93
|
profile: MobileServerProfileResponse;
|
|
87
94
|
feed: MobileServerFeedResponse;
|
|
88
95
|
notification_preferences: MobileServerNotificationPreferencesResponse;
|
|
96
|
+
registered_wallet: MobileServerRegisteredWalletResponse;
|
|
89
97
|
}
|
|
90
98
|
|
|
91
99
|
/**
|
|
@@ -96,7 +104,6 @@ export interface MobileServerPublicQueryResponseByType {
|
|
|
96
104
|
*/
|
|
97
105
|
export interface MobileServerSignedQueryResponseByType {
|
|
98
106
|
self_identity: MobileServerSelfIdentityResponse;
|
|
99
|
-
registered_devices: MobileServerRegisteredDevicesResponse;
|
|
100
107
|
}
|
|
101
108
|
|
|
102
109
|
/**
|
|
@@ -23,6 +23,7 @@ export interface MobileServerPublicQueryRequestByType {
|
|
|
23
23
|
cursor?: string;
|
|
24
24
|
};
|
|
25
25
|
notification_preferences: { expo_token: string };
|
|
26
|
+
registered_wallet: { expo_token: string };
|
|
26
27
|
}
|
|
27
28
|
|
|
28
29
|
/**
|
|
@@ -60,7 +61,6 @@ export type MobileServerPublicExecuteRequestType =
|
|
|
60
61
|
*/
|
|
61
62
|
export interface MobileServerSignedQueryRequestByType {
|
|
62
63
|
self_identity: Record<string, never>;
|
|
63
|
-
registered_devices: Record<string, never>;
|
|
64
64
|
}
|
|
65
65
|
|
|
66
66
|
/**
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"MobileClient-_i0ZV6Dq.cjs","names":["mapMobilePublicProfile","mapMobileFeedPage","mapMobileNotificationPreferences","mapMobileNotificationPreferencesToServer","mapMobileIdentity","mapMobileRegisteredDevice","WalletNotProvidedError","buildSignedMobileRequest","isMobileServerFailureResponse","MobileServerFailureError","isMobileServerSuccessResponse"],"sources":["../src/MobileClient.ts"],"sourcesContent":["import {\n subaccountToHex,\n WalletClientWithAccount,\n WalletNotProvidedError,\n} from '@nadohq/shared';\nimport axios, { AxiosInstance, AxiosResponse } from 'axios';\nimport {\n mapMobileFeedPage,\n mapMobileIdentity,\n mapMobileNotificationPreferences,\n mapMobileNotificationPreferencesToServer,\n mapMobilePublicProfile,\n mapMobileRegisteredDevice,\n} from './dataMappers';\nimport {\n buildSignedMobileRequest,\n MobileSignedInner,\n MobileSignedInnerParams,\n MobileSignedRequest,\n} from './signing';\nimport {\n GetMobileFeedParams,\n GetMobileNotificationPreferencesParams,\n GetMobilePublicProfileParams,\n GetMobileRegisteredDevicesParams,\n GetMobileSelfIdentityParams,\n GetMobileUsernameAvailabilityParams,\n MobileFeedPage,\n MobileIdentity,\n MobileNotificationPreferences,\n MobilePublicProfile,\n MobileRegisteredDevice,\n MobileRegisterExpoTokenParams,\n MobileSetPrivateModeParams,\n MobileSetUsernameParams,\n MobileSignedRequestParams,\n MobileUnregisterExpoTokenParams,\n MobileUpdateNotificationPreferencesParams,\n MobileUsernameAvailability,\n} from './types/clientTypes';\nimport { MobileServerFailureError } from './types/MobileServerFailureError';\nimport { MobileServerSuccessResponse } from './types/serverBaseTypes';\nimport {\n MobileServerExecuteResult,\n MobileServerPublicExecuteRequest,\n} from './types/serverExecuteTypes';\nimport {\n MobileServerPublicQueryRequest,\n MobileServerPublicQuerySuccessResponse,\n MobileServerSignedQuerySuccessResponse,\n} from './types/serverQueryTypes';\nimport {\n MobileServerPublicQueryRequestByType,\n MobileServerPublicQueryRequestType,\n MobileServerSignedQueryRequestType,\n} from './types/serverRequestTypes';\nimport {\n isMobileServerFailureResponse,\n isMobileServerSuccessResponse,\n} from './utils/serverResponseGuards';\n\n/**\n * Options for constructing a {@link MobileClient}.\n */\nexport interface MobileClientOpts {\n /**\n * Base URL of the mobile service API, e.g. {@link MOBILE_CLIENT_ENDPOINTS}.\n */\n url: string;\n /**\n * Wallet client used to sign requests.\n */\n walletClient?: WalletClientWithAccount;\n /**\n * If provided, this signer is used instead of `walletClient` for all signed requests.\n */\n linkedSignerWalletClient?: WalletClientWithAccount;\n}\n\n/**\n * Client for the Nado mobile service API: usernames, public profile lookups, the global trade feed, privacy\n * settings, and push notification device/preference management.\n */\nexport class MobileClient {\n readonly opts: MobileClientOpts;\n readonly axiosInstance: AxiosInstance;\n\n constructor(opts: MobileClientOpts) {\n this.opts = opts;\n this.axiosInstance = axios.create({\n withCredentials: true,\n // We have custom logic to validate response status and create an appropriate error\n validateStatus: () => true,\n });\n }\n\n /**\n * Sets the linked signer for requests\n *\n * @param linkedSignerWalletClient The linkedSigner to use for all signatures. Set to null to revert to the chain signer\n */\n public setLinkedSigner(\n linkedSignerWalletClient: WalletClientWithAccount | null,\n ) {\n this.opts.linkedSignerWalletClient = linkedSignerWalletClient ?? undefined;\n }\n\n /*\n Public queries\n */\n\n /**\n * Checks whether a username derived from the given display name is available to claim.\n */\n async getUsernameAvailability(\n params: GetMobileUsernameAvailabilityParams,\n ): Promise<MobileUsernameAvailability> {\n const body: MobileServerPublicQueryRequest<'username_availability'> = {\n type: 'username_availability',\n display_name: params.displayName,\n };\n const data = await this.publicQuery(body);\n return { username: data.username, available: data.available };\n }\n\n /**\n * Looks up a subaccount's public profile. Every non-isolated subaccount resolves, with `username` and\n * `displayName` `null` until a username is claimed. Private Mode does not hide the profile itself, only the\n * account's activity.\n *\n * @throws {MobileServerFailureError} With error code `PROFILE_NOT_FOUND` if the subaccount is in the\n * engine-created isolated namespace, which cannot own a profile.\n */\n async getPublicProfile(\n params: GetMobilePublicProfileParams,\n ): Promise<MobilePublicProfile> {\n const body: MobileServerPublicQueryRequest<'profile'> = {\n type: 'profile',\n subaccount: subaccountToHex(params),\n };\n const data = await this.publicQuery(body);\n return mapMobilePublicProfile(data.profile);\n }\n\n /**\n * Fetches a page of the global trade feed: public perpetual trades, newest first, optionally filtered by a\n * whole-dollar minimum notional (omitted means unfiltered). Trades by subaccounts that have not claimed a\n * username are included with `null` name fields; only private accounts are filtered out. The feed is\n * best-effort rather than authoritative history, and pagination is live (not snapshot), so deduplicate pages\n * by {@link MobileFeedTrade.orderDigest}.\n *\n * @throws {MobileServerFailureError} With error code `INVALID_FEED_FILTER` if `minimumNotional` or\n * `limit` is outside its allowed domain (fix the request; do not retry unchanged), or\n * `INVALID_FEED_CURSOR` if the cursor is malformed or was issued for a different `minimumNotional`\n * (discard the cursor and restart from the first page).\n */\n async getFeed(params: GetMobileFeedParams = {}): Promise<MobileFeedPage> {\n const body: MobileServerPublicQueryRequest<'feed'> = {\n type: 'feed',\n minimum_notional: params.minimumNotional,\n limit: params.limit,\n cursor: params.cursor,\n };\n const data = await this.publicQuery(body);\n return mapMobileFeedPage(data);\n }\n\n /**\n * Fetches the push notification preferences of the wallet that owns the given Expo push token. Unsigned —\n * the token identifies the wallet on its own. Falls back to the backend's defaults if the wallet has never\n * updated its preferences.\n *\n * @throws {MobileServerFailureError} With error code `INVALID_EXPO_TOKEN` if the token is malformed, or is\n * not currently registered to a wallet.\n */\n async getNotificationPreferences(\n params: GetMobileNotificationPreferencesParams,\n ): Promise<MobileNotificationPreferences> {\n const body: MobileServerPublicQueryRequest<'notification_preferences'> = {\n type: 'notification_preferences',\n expo_token: params.expoToken,\n };\n const data = await this.publicQuery(body);\n return mapMobileNotificationPreferences(data.preferences);\n }\n\n /*\n Public executes\n */\n\n /**\n * Unregisters an Expo push token, stopping delivery to that device. Unsigned, so it still works at logout\n * when a wallet signature may no longer be obtainable. Idempotent: unregistering an inactive or unknown\n * well-formed token succeeds.\n *\n * A registration that commits after this call re-activates the token, so stop or await any in-flight\n * {@link MobileClient.registerExpoToken} before unregistering.\n *\n * @throws {MobileServerFailureError} With error code `INVALID_EXPO_TOKEN` if the token is malformed.\n */\n async unregisterExpoToken(\n params: MobileUnregisterExpoTokenParams,\n ): Promise<MobileServerSuccessResponse> {\n const body: MobileServerPublicExecuteRequest<'unregister_expo_token'> = {\n type: 'unregister_expo_token',\n expo_token: params.expoToken,\n };\n return this.publicExecute(body);\n }\n\n /**\n * Replaces the push notification preferences of the wallet that owns the given Expo push token. Possession\n * of an active token is the credential rather than a signature, so anyone holding the token can overwrite\n * that wallet's preferences. The backend requires `schemaVersion` of 1, exactly one entry per known\n * category, and empty `scopes` on every entry.\n *\n * Writes are last-write-wins on commit order rather than ordered by a client nonce, so callers must\n * serialize their own preference writes.\n *\n * @throws {MobileServerFailureError} With error code `INVALID_PREFERENCES` if those rules are violated, or\n * `INVALID_EXPO_TOKEN` if the token is malformed or is not currently registered to a wallet.\n */\n async updateNotificationPreferences(\n params: MobileUpdateNotificationPreferencesParams,\n ): Promise<MobileServerSuccessResponse> {\n const body: MobileServerPublicExecuteRequest<'update_preferences'> = {\n type: 'update_preferences',\n expo_token: params.expoToken,\n preferences: mapMobileNotificationPreferencesToServer(params.preferences),\n };\n return this.publicExecute(body);\n }\n\n /*\n Signed queries\n */\n\n /**\n * Fetches the caller's own identity for a subaccount. Every non-isolated subaccount has an implicit\n * identity, so this resolves for any valid sender with `username` and `displayName` `null` until a username\n * is claimed.\n *\n * @throws {MobileServerFailureError} With error code `INVALID_IDENTITY_TARGET` if the sender is in the\n * engine-created isolated namespace, which cannot own an identity.\n */\n async getSelfIdentity(\n params: GetMobileSelfIdentityParams,\n ): Promise<MobileIdentity | null> {\n const signedRequest = await this.getSignedRequest(\n 'self_identity',\n params,\n {},\n );\n const data = await this.query<'self_identity'>(signedRequest);\n return data.identity ? mapMobileIdentity(data.identity) : null;\n }\n\n /**\n * Fetches the devices registered for push notifications for a wallet.\n */\n async getRegisteredDevices(\n params: GetMobileRegisteredDevicesParams,\n ): Promise<MobileRegisteredDevice[]> {\n const signedRequest = await this.getSignedRequest(\n 'registered_devices',\n params,\n {},\n );\n const data = await this.query<'registered_devices'>(signedRequest);\n return data.devices.map(mapMobileRegisteredDevice);\n }\n\n /*\n Signed executes\n */\n\n /**\n * Sets a subaccount's username, derived from the given display name. Upserts: the same call claims a first\n * username and renames an existing one, so callers never need to read the current identity first.\n *\n * @throws {MobileServerFailureError} With error code `INVALID_DISPLAY_NAME` if the display name violates\n * `MOBILE_DISPLAY_NAME_PATTERN`, `USERNAME_UNAVAILABLE` if the derived username is reserved or already\n * taken by another subaccount, `INVALID_IDENTITY_TARGET` if the sender is in the engine-created isolated\n * namespace, or `STALE_IDENTITY_UPDATE` if another identity write for this subaccount committed with a\n * later nonce (re-read the identity before retrying).\n */\n async setUsername(\n params: MobileSetUsernameParams,\n ): Promise<MobileServerSuccessResponse> {\n const signedRequest = await this.getSignedRequest('set_username', params, {\n display_name: params.displayName,\n });\n return this.execute(signedRequest);\n }\n\n /**\n * Sets whether a subaccount's profile is private.\n */\n async setPrivateMode(\n params: MobileSetPrivateModeParams,\n ): Promise<MobileServerSuccessResponse> {\n const signedRequest = await this.getSignedRequest(\n 'set_private_mode',\n params,\n { private_mode: params.privateMode },\n );\n return this.execute(signedRequest);\n }\n\n /**\n * Registers an Expo push token for the wallet, transferring active ownership of the token if another\n * wallet had registered it. Idempotent per `(wallet, token)`.\n *\n * @throws {MobileServerFailureError} With error code `INVALID_EXPO_TOKEN` if the token is not a valid Expo\n * push token, or `INVALID_DEVICE_METADATA` if `locale` (max 35 chars) or `appVersion` (max 64 chars) is\n * too long.\n */\n async registerExpoToken(\n params: MobileRegisterExpoTokenParams,\n ): Promise<MobileServerSuccessResponse> {\n const signedRequest = await this.getSignedRequest(\n 'register_expo_token',\n params,\n {\n expo_token: params.expoToken,\n platform: params.platform,\n locale: params.locale ?? null,\n app_version: params.appVersion ?? null,\n },\n );\n return this.execute(signedRequest);\n }\n\n /*\n Base Fns\n */\n\n protected async getSignedRequest<T extends MobileSignedInner['type']>(\n type: T,\n params: MobileSignedRequestParams,\n innerParams: MobileSignedInnerParams<T>,\n ): Promise<MobileSignedRequest> {\n // Use the linked signer if provided, otherwise use the default signer provided to the client\n const walletClient =\n this.opts.linkedSignerWalletClient ?? this.opts.walletClient;\n\n if (walletClient == null) {\n throw new WalletNotProvidedError();\n }\n\n const inner = { type, ...innerParams } as MobileSignedInner;\n return buildSignedMobileRequest({ ...params, walletClient, inner });\n }\n\n // Spelled out as an intersection rather than `MobileServerPublicQueryRequest<T>`: the latter is an indexed\n // access on a mapped type, which is not an inference site, so `T` would always widen to the full union.\n protected async publicQuery<T extends MobileServerPublicQueryRequestType>(\n body: { type: T } & MobileServerPublicQueryRequestByType[T],\n ): Promise<MobileServerPublicQuerySuccessResponse<T>> {\n const response = await this.axiosInstance.post<unknown>(\n `${this.opts.url}/mobile/public_query`,\n body,\n );\n\n this.checkResponseStatus(response);\n this.checkServerStatus(response);\n\n // checkServerStatus throws on failure responses so the cast to the success response is acceptable here\n return response.data as MobileServerPublicQuerySuccessResponse<T>;\n }\n\n protected async publicExecute(\n body: MobileServerPublicExecuteRequest,\n ): Promise<MobileServerSuccessResponse> {\n const response = await this.axiosInstance.post<MobileServerExecuteResult>(\n `${this.opts.url}/mobile/public_execute`,\n body,\n );\n\n this.checkResponseStatus(response);\n this.checkServerStatus(response);\n\n // checkServerStatus catches the failure result and throws the error, so the cast to the success response is acceptable here\n return response.data as MobileServerSuccessResponse;\n }\n\n protected async query<T extends MobileServerSignedQueryRequestType>(\n body: MobileSignedRequest,\n ): Promise<MobileServerSignedQuerySuccessResponse<T>> {\n const response = await this.axiosInstance.post<unknown>(\n `${this.opts.url}/mobile/query`,\n body,\n );\n\n this.checkResponseStatus(response);\n this.checkServerStatus(response);\n\n // checkServerStatus throws on failure responses so the cast to the success response is acceptable here\n return response.data as MobileServerSignedQuerySuccessResponse<T>;\n }\n\n protected async execute(\n body: MobileSignedRequest,\n ): Promise<MobileServerSuccessResponse> {\n const response = await this.axiosInstance.post<MobileServerExecuteResult>(\n `${this.opts.url}/mobile/execute`,\n body,\n );\n\n this.checkResponseStatus(response);\n this.checkServerStatus(response);\n\n // checkServerStatus catches the failure result and throws the error, so the cast to the success response is acceptable here\n return response.data as MobileServerSuccessResponse;\n }\n\n /**\n * Validates the HTTP status before interpreting the body. Unlike the engine, the mobile backend returns\n * failure envelopes with non-2xx statuses (e.g. 404 for `PROFILE_NOT_FOUND`), so a non-2xx response with a\n * failure envelope still throws the typed error; anything else is a transport-level error.\n */\n private checkResponseStatus(response: AxiosResponse<unknown>) {\n if (response.status >= 200 && response.status < 300) {\n return;\n }\n if (isMobileServerFailureResponse(response.data)) {\n throw new MobileServerFailureError(response.data, response.status);\n }\n throw new Error(\n `Unexpected response from mobile service: ${response.status} ${response.statusText}. Data: ${JSON.stringify(response.data)}`,\n );\n }\n\n private checkServerStatus(response: AxiosResponse<unknown>) {\n const { data } = response;\n\n if (isMobileServerFailureResponse(data)) {\n throw new MobileServerFailureError(data, response.status);\n }\n if (!isMobileServerSuccessResponse(data)) {\n throw new Error(\n `Unexpected response from mobile service: missing success envelope. Data: ${JSON.stringify(data)}`,\n );\n }\n }\n}\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAmFA,IAAa,eAAb,MAA0B;CAIxB,YAAY,MAAwB;EAClC,KAAK,OAAO;EACZ,KAAK,gBAAgB,M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/signing/canonicalize.ts"],"mappings":";;;;;AASA;;;;;iBAAgB,uBAAA,CACd,KAAA,EAAO,iBAAA,GACN,iBAAiB"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"canonicalize-wVdGejB1.d.ts","names":[],"sources":["../src/signing/src/signing/canonicalize.ts"],"mappings":";;;;;AASA;;;;;iBAAgB,uBAAA,CACd,KAAA,EAAO,iBAAA,GACN,iBAAiB"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"clientTypes-6utzUU-b.d.ts","names":[],"sources":["../src/types/src/types/clientTypes.ts"],"mappings":";;;;;;;AAkBA;;;;;;;UAAiB,cAAA;EACf,UAAA,EAAY,GAAG;EAWJ;AAAA;AAOb;;EAbE,QAAA;EAce;;;;EATf,WAAA;EACA,WAAA;AAAA;AAaW;AAMb;;;AANa,UANI,mBAAA;EACf,UAAA,EAAY,GAAG;EAqBA;EAnBf,QAAA;;EAEA,WAAA;EACA,WAAA;AAAA;;;AAkBiB;UAZF,0BAAA;EACf,QAAA;EACA,SAAS;AAAA;;;;;;UAQM,gBAAA;EACf,IAAA,EAAM,oBAAoB;EAC1B,iBAAA;AAAA;;;;;;UAQe,eAAA;EAgBf;EAdA,WAAA,EAAa,GAAA;EACb,UAAA,EAAY,GAAA;EAgBZ;EAdA,QAAA;EAgBA;EAdA,WAAA;EAgBQ;EAdR,SAAA;EACA,SAAA;EAsB6B;EApB7B,QAAA;EAqBuB;EAnBvB,QAAA;EAmBQ;EAjBR,YAAA;EACA,MAAA,EAAQ,gBAAA;EAiBE;EAfV,QAAA,EAAU,uBAAA;EAsBiC;EApB3C,WAAA;EAqBuC;EAnBvC,QAAA;AAAA;;;;;AAoB8B;AAKhC;UAhBiB,cAAA;EACf,MAAA,EAAQ,eAAe;EACvB,UAAA;AAAA;;;;;KAOU,iCAAA;EACN,IAAA;EAAoB,UAAA,EAAY,GAAG;AAAA;EACnC,IAAA;EAAiB,SAAA;AAAA;;;;UAKN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f;;;;EArCA,eAAA;EA8CU;EA5CV,KAAA;EAkDU;;;;EA7CV,MAAA;AAAA;;;;KAMU,2BAAA,GAA8B,yBAAyB;;;;UAKlD,uBAAA,SAAgC,yBAAyB;EA8C9D;EA5CV,WAAW;AAAA;;AA4CiE;AAK9E;UA3CiB,0BAAA,SAAmC,yBAAyB;EAC3E,WAAW;AAAA;AA0C2D;;;AAAA,UApCvD,6BAAA,SAAsC,yBAAyB;;;;EAI9E,SAAA;EACA,QAAA,EAAU,0BAAA;;;;EAIV,MAAA;;;;EAIA,UAAA;AAAA;;;;KAMU,+BAAA,GAAkC,yBAAyB;;;;UAKtD,yCAAA,SAAkD,yBAAyB;EAC1F,WAAA,EAAa,6BAAA;AAAA;;;;KAMH,sCAAA,GAAyC,yBAAyB;;;;KAKlE,gCAAA,GAAmC,yBAAyB"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"eip712MethodByType-CroIPqsJ.d.cts","names":[],"sources":["../src/signing/src/signing/eip712MethodByType.ts"],"mappings":";;;;;AAKA;cAAa,4BAAA,EAA8B,MAAM,CAC/C,iBAAA"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"eip712MethodByType-DBUy4AdI.d.ts","names":[],"sources":["../src/signing/src/signing/eip712MethodByType.ts"],"mappings":";;;;;AAKA;cAAa,4BAAA,EAA8B,MAAM,CAC/C,iBAAA"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"payloadHash-B0tlFOK8.d.cts","names":[],"sources":["../src/signing/src/signing/payloadHash.ts"],"mappings":";;;;;;AASA;;;iBAAgB,oBAAA,CAAqB,KAAA,EAAO,iBAAA,GAAoB,GAAG"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"payloadHash-D1yTQSF4.d.ts","names":[],"sources":["../src/signing/src/signing/payloadHash.ts"],"mappings":";;;;;;AASA;;;iBAAgB,oBAAA,CAAqB,KAAA,EAAO,iBAAA,GAAoB,GAAG"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"serverQueryTypes-9H6P1vJ5.d.cts","names":[],"sources":["../src/types/src/types/serverQueryTypes.ts"],"mappings":";;;;;;;AAiBA;KAAY,8BAAA,WACA,kCAAA,GACR,kCAAA,YAEI,kCAAA;EACJ,IAAA,EAAM,CAAA;AAAA,IACJ,oCAAA,CAAqC,CAAA,IACzC,CAAA;;;;UAKe,wCAAA;EACf,QAAA;EACA,SAAS;AAAA;;;;UAMM,2BAAA;EACf,OAAA,EAAS,mBAAmB;AAAA;;;;UAMb,wBAAA;EACf,MAAA,EAAQ,qBAAqB;EAhBd;;;;AAEN;EAoBT,WAAA;AAAA;;;AAb4B;AAM9B;;UAeiB,gCAAA;EACf,QAAA,EAAU,oBAAoB;AAAA;;;;UAMf,2CAAA;EACf,WAAA,EAAa,mCAAmC;AAAA;;;AAPlB;UAaf,qCAAA;EACf,OAAA,EAAS,4BAA4B;AAAA;;AAPW;AAMlD;;;;UAUiB,qCAAA;EACf,qBAAA,EAAuB,wCAAA;EACvB,OAAA,EAAS,2BAAA;EACT,IAAA,EAAM,wBAAA;EACN,wBAAA,EAA0B,2CAAA;AAAA;;;;;;;UASX,qCAAA;EACf,aAAA,EAAe,gCAAA;EACf,kBAAA,EAAoB,qCAAqC;AAAA;;;;AAXY;AASvE;KAUY,sCAAA,WACA,kCAAA,GACR,kCAAA,IACA,2BAAA,GAA8B,qCAAA,CAAsC,CAAA;;;;;KAM5D,sCAAA,WACA,kCAAA,GACR,kCAAA,IACA,2BAAA,GAA8B,qCAAA,CAAsC,CAAA"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"serverQueryTypes-Cbjx0bIj.d.ts","names":[],"sources":["../src/types/src/types/serverQueryTypes.ts"],"mappings":";;;;;;;AAiBA;KAAY,8BAAA,WACA,kCAAA,GACR,kCAAA,YAEI,kCAAA;EACJ,IAAA,EAAM,CAAA;AAAA,IACJ,oCA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A;IACA,WAAA,EAAa,mCAAmC;EAAA;AAAA;;;;KAOxC,oCAAA,SACJ,sCAAsC;AAkB9C;;;;AAC4C;AAM5C;;AAPA,UATiB,oCAAA;EACf,aAAA,EAAe,MAAA;EACf,kBAAA,EAAoB,MAAM;AAAA;;;;;KAOhB,kCAAA,SACJ,oCAAoC;;AAQR;AAQpC;;KAVY,8BAAA,GAAiC,OAAA,CAC3C,iBAAA,UACA,kCAAA;;;;;;KAQU,uBAAA,mBACQ,kCAAA,uBACE,oCAAA,cACT,kCAAA,gBACE,8BAAA"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"serverRequestTypes-DYTLrCpz.d.ts","names":[],"sources":["../src/types/src/types/serverRequestTypes.ts"],"mappings":";;;;;;;AAOA;UAAiB,oCAAA;EACf,qBAAA;IAAyB,YAAA;EAAA;EACzB,OAAA;IAAW,UAAA,EAAY,GAAG;EAAA;EAC1B,IAAA;IAAA;;;;IAKE,gBAAA,WAS0B;IAP1B,KAAA;IAOoC;AAMxC;;;IARI,MAAA;EAAA;EAEF,wBAAA;IAA4B,UAAA;EAAA;AAAA;;;;KAMlB,kCAAA,SACJ,oCAAoC;;;;AAYQ;AAOpD;;UAXiB,sCAAA;EACf,qBAAA;IAAyB,UAAA;EAAA;EACzB,kBAAA;IACE,UAAA;IACA,WAAA,EAAa,mCAAmC;EAAA;AAAA;;;;KAOxC,oCAAA,SACJ,sCAAsC;AAkB9C;;;;AAC4C;AAM5C;;AAPA,UATiB,oCAAA;EACf,aAAA,EAAe,MAAA;EACf,kBAAA,EAAoB,MAAM;AAAA;;;;;KAOhB,kCAAA,SACJ,oCAAoC;;AAQR;AAQpC;;KAVY,8BAAA,GAAiC,OAAA,CAC3C,iBAAA,UACA,kCAAA;;;;;;KAQU,uBAAA,mBACQ,kCAAA,uBACE,oCAAA,cACT,kCAAA,gBACE,8BAAA"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"types-CQE3HD2V.d.ts","names":[],"sources":["../src/signing/src/signing/types.ts"],"mappings":";;;;;;;;AAcA;;;;;;;KAAY,iBAAA;EACN,IAAA;EAAsB,YAAA;AAAA;EACtB,IAAA;EAA0B,YAAA;AAAA;EAC1B,IAAA;AAAA;EAEA,IAAA;EACA,UAAA;EACA,QAAA,EAAU,0BAA0B;EAGpC,MAAA;EACA,WAAA;AAAA;EAEA,IAAA;AAAA;;;;;KAMM,uBAAA,WAAkC,iBAAA,YAA6B,IAAA,CACzE,OAAA,CAAQ,iBAAA;EAAqB,IAAA,EAAM,CAAA;AAAA;;;;;KAQzB,mBAAA,WACA,iBAAA,GAAoB,iBAAA,IAC5B,CAAA;EACF,SAAA,EAAW,GAAA;EACX,MAAA,EAAQ,GAAA;EACR,KAAA;AAAA;;;;UAMe,8BAAA,SAAuC,yBAAA;EACtD,YAAA,EAAc,uBAAA;EACd,KAAA,EAAO,iBAAA;EATI;;;EAaX,KAAA;AAAA"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"types-bNB98pYk.d.cts","names":[],"sources":["../src/signing/src/signing/types.ts"],"mappings":";;;;;;;;AAcA;;;;;;;KAAY,iBAAA;EACN,IAAA;EAAsB,YAAA;AAAA;EACtB,IAAA;EAA0B,YAAA;AAAA;EAC1B,IAAA;AAAA;EAEA,IAAA;EACA,UAAA;EACA,QAAA,EAAU,0BAA0B;EAGpC,MAAA;EACA,WAAA;AAAA;EAEA,IAAA;AAAA;;;;;KAMM,uBAAA,WAAkC,iBAAA,YAA6B,IAAA,CACzE,OAAA,CAAQ,iBAAA;EAAqB,IAAA,EAAM,CAAA;AAAA;;;;;KAQzB,mBAAA,WACA,iBAAA,GAAoB,iBAAA,IAC5B,CAAA;EACF,SAAA,EAAW,GAAA;EACX,MAAA,EAAQ,GAAA;EACR,KAAA;AAAA;;;;UAMe,8BAAA,SAAuC,yBAAA;EACtD,YAAA,EAAc,uBAAA;EACd,KAAA,EAAO,iBAAA;EATI;;;EAaX,KAAA;AAAA"}
|