@nadohq/mobile-client 0.29.0 → 0.30.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.
Files changed (188) hide show
  1. package/dist/{MobileClient-9JSAzblH.cjs → MobileClient-CfDtaEeL.cjs} +21 -1
  2. package/dist/MobileClient-CfDtaEeL.cjs.map +1 -0
  3. package/dist/MobileClient.cjs +1 -1
  4. package/dist/MobileClient.d.cts +21 -9
  5. package/dist/MobileClient.d.cts.map +1 -1
  6. package/dist/MobileClient.d.ts +21 -9
  7. package/dist/MobileClient.d.ts.map +1 -1
  8. package/dist/MobileClient.js +21 -1
  9. package/dist/MobileClient.js.map +1 -1
  10. package/dist/{MobileServerFailureError-ZggEcEda.d.cts → MobileServerFailureError-B11rr9O5.d.cts} +3 -2
  11. package/dist/MobileServerFailureError-B11rr9O5.d.cts.map +1 -0
  12. package/dist/{MobileServerFailureError-f9KhKnJj.d.ts → MobileServerFailureError-DoIvXqYV.d.ts} +3 -2
  13. package/dist/MobileServerFailureError-DoIvXqYV.d.ts.map +1 -0
  14. package/dist/{buildSignedMobileRequest-CDRsRNHm.d.ts → buildSignedMobileRequest-B4KJ6T1y.d.ts} +2 -2
  15. package/dist/{buildSignedMobileRequest-CDRsRNHm.d.ts.map → buildSignedMobileRequest-B4KJ6T1y.d.ts.map} +1 -1
  16. package/dist/{buildSignedMobileRequest-BsbBkU0K.d.cts → buildSignedMobileRequest-EEnDgZF8.d.cts} +2 -2
  17. package/dist/{buildSignedMobileRequest-BsbBkU0K.d.cts.map → buildSignedMobileRequest-EEnDgZF8.d.cts.map} +1 -1
  18. package/dist/{canonicalize-Dm7sXwPg.d.cts → canonicalize-CDdYnhL3.d.cts} +2 -2
  19. package/dist/canonicalize-CDdYnhL3.d.cts.map +1 -0
  20. package/dist/{canonicalize-PX6dTIdF.d.ts → canonicalize-Cc7hdZLJ.d.ts} +2 -2
  21. package/dist/canonicalize-Cc7hdZLJ.d.ts.map +1 -0
  22. package/dist/{clientTypes-DWW2N66c.d.ts → clientTypes-BsOps_pY.d.ts} +67 -3
  23. package/dist/clientTypes-BsOps_pY.d.ts.map +1 -0
  24. package/dist/{clientTypes-Et0PUa2d.d.cts → clientTypes-UFInIAQd.d.cts} +67 -3
  25. package/dist/clientTypes-UFInIAQd.d.cts.map +1 -0
  26. package/dist/dataMappers.cjs +33 -0
  27. package/dist/dataMappers.cjs.map +1 -1
  28. package/dist/dataMappers.d.cts +8 -3
  29. package/dist/dataMappers.d.cts.map +1 -1
  30. package/dist/dataMappers.d.ts +8 -3
  31. package/dist/dataMappers.d.ts.map +1 -1
  32. package/dist/dataMappers.js +33 -1
  33. package/dist/dataMappers.js.map +1 -1
  34. package/dist/{eip712MethodByType-DJgXal9r.d.ts → eip712MethodByType-B67XiwTu.d.ts} +2 -2
  35. package/dist/eip712MethodByType-B67XiwTu.d.ts.map +1 -0
  36. package/dist/{eip712MethodByType-DLh9MRsD.d.cts → eip712MethodByType-DCU415zf.d.cts} +2 -2
  37. package/dist/eip712MethodByType-DCU415zf.d.cts.map +1 -0
  38. package/dist/feed-BF5k6Ryu.d.ts +14 -0
  39. package/dist/feed-BF5k6Ryu.d.ts.map +1 -0
  40. package/dist/feed-CBIwOhTO.d.cts +14 -0
  41. package/dist/feed-CBIwOhTO.d.cts.map +1 -0
  42. package/dist/index.cjs +8 -1
  43. package/dist/index.d.cts +17 -15
  44. package/dist/index.d.ts +17 -15
  45. package/dist/index.js +3 -1
  46. package/dist/{mobileErrorCodes-QG5XbEY6.d.ts → mobileErrorCodes-Cj84nBnT.d.cts} +7 -5
  47. package/dist/mobileErrorCodes-Cj84nBnT.d.cts.map +1 -0
  48. package/dist/{mobileErrorCodes-BeyBKmwh.d.cts → mobileErrorCodes-Czmigq9x.d.ts} +7 -5
  49. package/dist/mobileErrorCodes-Czmigq9x.d.ts.map +1 -0
  50. package/dist/{patterns-BbxH3_VA.d.ts → patterns-B5gi7OfV.d.ts} +1 -1
  51. package/dist/patterns-B5gi7OfV.d.ts.map +1 -0
  52. package/dist/{patterns-B9J2ldpx.d.cts → patterns-Db6fgz8i.d.cts} +1 -1
  53. package/dist/patterns-Db6fgz8i.d.cts.map +1 -0
  54. package/dist/{payloadHash-nj8WuLUP.d.cts → payloadHash-BSoGv3Lz.d.cts} +2 -2
  55. package/dist/payloadHash-BSoGv3Lz.d.cts.map +1 -0
  56. package/dist/{payloadHash-Bmhzs78N.d.ts → payloadHash-BVP2v3p9.d.ts} +2 -2
  57. package/dist/payloadHash-BVP2v3p9.d.ts.map +1 -0
  58. package/dist/serverBaseTypes-A16onlPN.d.cts +25 -0
  59. package/dist/serverBaseTypes-A16onlPN.d.cts.map +1 -0
  60. package/dist/serverBaseTypes-m3zEi0X9.d.ts +25 -0
  61. package/dist/serverBaseTypes-m3zEi0X9.d.ts.map +1 -0
  62. package/dist/{serverExecuteTypes-DKYK1V7C.d.cts → serverExecuteTypes-C-bioiuQ.d.cts} +2 -2
  63. package/dist/serverExecuteTypes-C-bioiuQ.d.cts.map +1 -0
  64. package/dist/{serverExecuteTypes-CXnMjKnt.d.ts → serverExecuteTypes-DfzWOeIx.d.ts} +2 -2
  65. package/dist/serverExecuteTypes-DfzWOeIx.d.ts.map +1 -0
  66. package/dist/serverModelTypes-CPZUvVil.d.cts +143 -0
  67. package/dist/serverModelTypes-CPZUvVil.d.cts.map +1 -0
  68. package/dist/serverModelTypes-CqnqHY5F.d.ts +143 -0
  69. package/dist/serverModelTypes-CqnqHY5F.d.ts.map +1 -0
  70. package/dist/serverQueryTypes-CJLWWZBs.d.ts +91 -0
  71. package/dist/serverQueryTypes-CJLWWZBs.d.ts.map +1 -0
  72. package/dist/serverQueryTypes-C_cCx0Ac.d.cts +91 -0
  73. package/dist/serverQueryTypes-C_cCx0Ac.d.cts.map +1 -0
  74. package/dist/serverRequestTypes-DQDy3K9O.d.ts +62 -0
  75. package/dist/serverRequestTypes-DQDy3K9O.d.ts.map +1 -0
  76. package/dist/serverRequestTypes-DnU_FfMI.d.cts +62 -0
  77. package/dist/serverRequestTypes-DnU_FfMI.d.cts.map +1 -0
  78. package/dist/{serverResponseGuards-DjCNL3CR.d.cts → serverResponseGuards-BlvfJjsa.d.cts} +2 -2
  79. package/dist/{serverResponseGuards-DjCNL3CR.d.cts.map → serverResponseGuards-BlvfJjsa.d.cts.map} +1 -1
  80. package/dist/{serverResponseGuards-C_vZIgGl.d.ts → serverResponseGuards-gpHH8SHk.d.ts} +2 -2
  81. package/dist/{serverResponseGuards-C_vZIgGl.d.ts.map → serverResponseGuards-gpHH8SHk.d.ts.map} +1 -1
  82. package/dist/signing/buildSignedMobileRequest.cjs +1 -1
  83. package/dist/signing/buildSignedMobileRequest.d.cts +1 -1
  84. package/dist/signing/buildSignedMobileRequest.d.ts +1 -1
  85. package/dist/signing/canonicalize.d.cts +1 -1
  86. package/dist/signing/canonicalize.d.ts +1 -1
  87. package/dist/signing/eip712MethodByType.d.cts +1 -1
  88. package/dist/signing/eip712MethodByType.d.ts +1 -1
  89. package/dist/signing/index.d.cts +5 -5
  90. package/dist/signing/index.d.ts +5 -5
  91. package/dist/signing/payloadHash.cjs +1 -1
  92. package/dist/signing/payloadHash.d.cts +1 -1
  93. package/dist/signing/payloadHash.d.ts +1 -1
  94. package/dist/signing/types.d.cts +1 -1
  95. package/dist/signing/types.d.ts +1 -1
  96. package/dist/types/MobileServerFailureError.cjs +1 -1
  97. package/dist/types/MobileServerFailureError.cjs.map +1 -1
  98. package/dist/types/MobileServerFailureError.d.cts +1 -1
  99. package/dist/types/MobileServerFailureError.d.ts +1 -1
  100. package/dist/types/MobileServerFailureError.js.map +1 -1
  101. package/dist/types/clientTypes.d.cts +2 -2
  102. package/dist/types/clientTypes.d.ts +2 -2
  103. package/dist/types/index.cjs +4 -0
  104. package/dist/types/index.d.cts +9 -8
  105. package/dist/types/index.d.ts +9 -8
  106. package/dist/types/index.js +2 -1
  107. package/dist/types/mobileErrorCodes.cjs +9 -5
  108. package/dist/types/mobileErrorCodes.cjs.map +1 -1
  109. package/dist/types/mobileErrorCodes.d.cts +1 -1
  110. package/dist/types/mobileErrorCodes.d.ts +1 -1
  111. package/dist/types/mobileErrorCodes.js +8 -4
  112. package/dist/types/mobileErrorCodes.js.map +1 -1
  113. package/dist/types/serverBaseTypes.d.cts +2 -2
  114. package/dist/types/serverBaseTypes.d.ts +2 -2
  115. package/dist/types/serverExecuteTypes.d.cts +1 -1
  116. package/dist/types/serverExecuteTypes.d.ts +1 -1
  117. package/dist/types/serverModelTypes.cjs +29 -0
  118. package/dist/types/serverModelTypes.cjs.map +1 -0
  119. package/dist/types/serverModelTypes.d.cts +2 -2
  120. package/dist/types/serverModelTypes.d.ts +2 -2
  121. package/dist/types/serverModelTypes.js +26 -1
  122. package/dist/types/serverModelTypes.js.map +1 -0
  123. package/dist/types/serverQueryTypes.d.cts +2 -2
  124. package/dist/types/serverQueryTypes.d.ts +2 -2
  125. package/dist/types/serverRequestTypes.cjs +0 -0
  126. package/dist/types/serverRequestTypes.d.cts +2 -0
  127. package/dist/types/serverRequestTypes.d.ts +2 -0
  128. package/dist/types/serverRequestTypes.js +1 -0
  129. package/dist/{types-uCD4BNZR.d.cts → types-CzOeSYnW.d.cts} +3 -3
  130. package/dist/{types-uCD4BNZR.d.cts.map → types-CzOeSYnW.d.cts.map} +1 -1
  131. package/dist/{types-B76Pn7Sy.d.ts → types-UHjZR-js.d.ts} +3 -3
  132. package/dist/{types-B76Pn7Sy.d.ts.map → types-UHjZR-js.d.ts.map} +1 -1
  133. package/dist/utils/feed.cjs +17 -0
  134. package/dist/utils/feed.cjs.map +1 -0
  135. package/dist/utils/feed.d.cts +2 -0
  136. package/dist/utils/feed.d.ts +2 -0
  137. package/dist/utils/feed.js +15 -0
  138. package/dist/utils/feed.js.map +1 -0
  139. package/dist/utils/index.cjs +3 -0
  140. package/dist/utils/index.d.cts +4 -3
  141. package/dist/utils/index.d.ts +4 -3
  142. package/dist/utils/index.js +2 -1
  143. package/dist/utils/patterns.d.cts +1 -1
  144. package/dist/utils/patterns.d.ts +1 -1
  145. package/dist/utils/serverResponseGuards.d.cts +1 -1
  146. package/dist/utils/serverResponseGuards.d.ts +1 -1
  147. package/package.json +3 -3
  148. package/src/MobileClient.ts +49 -27
  149. package/src/dataMappers.ts +40 -0
  150. package/src/types/MobileServerFailureError.ts +2 -4
  151. package/src/types/clientTypes.ts +70 -0
  152. package/src/types/index.ts +1 -0
  153. package/src/types/mobileErrorCodes.ts +7 -3
  154. package/src/types/serverBaseTypes.ts +7 -28
  155. package/src/types/serverModelTypes.ts +93 -0
  156. package/src/types/serverQueryTypes.ts +83 -39
  157. package/src/types/serverRequestTypes.ts +68 -0
  158. package/src/utils/feed.ts +11 -0
  159. package/src/utils/index.ts +1 -0
  160. package/dist/MobileClient-9JSAzblH.cjs.map +0 -1
  161. package/dist/MobileServerFailureError-ZggEcEda.d.cts.map +0 -1
  162. package/dist/MobileServerFailureError-f9KhKnJj.d.ts.map +0 -1
  163. package/dist/canonicalize-Dm7sXwPg.d.cts.map +0 -1
  164. package/dist/canonicalize-PX6dTIdF.d.ts.map +0 -1
  165. package/dist/clientTypes-DWW2N66c.d.ts.map +0 -1
  166. package/dist/clientTypes-Et0PUa2d.d.cts.map +0 -1
  167. package/dist/eip712MethodByType-DJgXal9r.d.ts.map +0 -1
  168. package/dist/eip712MethodByType-DLh9MRsD.d.cts.map +0 -1
  169. package/dist/mobileErrorCodes-BeyBKmwh.d.cts.map +0 -1
  170. package/dist/mobileErrorCodes-QG5XbEY6.d.ts.map +0 -1
  171. package/dist/patterns-B9J2ldpx.d.cts.map +0 -1
  172. package/dist/patterns-BbxH3_VA.d.ts.map +0 -1
  173. package/dist/payloadHash-Bmhzs78N.d.ts.map +0 -1
  174. package/dist/payloadHash-nj8WuLUP.d.cts.map +0 -1
  175. package/dist/serverBaseTypes-BicXMrZV.d.cts +0 -43
  176. package/dist/serverBaseTypes-BicXMrZV.d.cts.map +0 -1
  177. package/dist/serverBaseTypes-ewbo8l4R.d.ts +0 -43
  178. package/dist/serverBaseTypes-ewbo8l4R.d.ts.map +0 -1
  179. package/dist/serverExecuteTypes-CXnMjKnt.d.ts.map +0 -1
  180. package/dist/serverExecuteTypes-DKYK1V7C.d.cts.map +0 -1
  181. package/dist/serverModelTypes-CQgfqgW3.d.cts +0 -69
  182. package/dist/serverModelTypes-CQgfqgW3.d.cts.map +0 -1
  183. package/dist/serverModelTypes-vEPhHIit.d.ts +0 -69
  184. package/dist/serverModelTypes-vEPhHIit.d.ts.map +0 -1
  185. package/dist/serverQueryTypes-BI-2TD8F.d.ts +0 -53
  186. package/dist/serverQueryTypes-BI-2TD8F.d.ts.map +0 -1
  187. package/dist/serverQueryTypes-D7Yharse.d.cts +0 -53
  188. package/dist/serverQueryTypes-D7Yharse.d.cts.map +0 -1
@@ -0,0 +1 @@
1
+ {"version":3,"file":"patterns-B5gi7OfV.d.ts","names":[],"sources":["../src/utils/src/utils/patterns.ts"],"mappings":";;AAGA;;cAAa,2BAAA,EAA2B,MAA0B"}
@@ -5,4 +5,4 @@
5
5
  declare const MOBILE_DISPLAY_NAME_PATTERN: RegExp;
6
6
  //#endregion
7
7
  export { MOBILE_DISPLAY_NAME_PATTERN as t };
8
- //# sourceMappingURL=patterns-B9J2ldpx.d.cts.map
8
+ //# sourceMappingURL=patterns-Db6fgz8i.d.cts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"patterns-Db6fgz8i.d.cts","names":[],"sources":["../src/utils/src/utils/patterns.ts"],"mappings":";;AAGA;;cAAa,2BAAA,EAA2B,MAA0B"}
@@ -1,4 +1,4 @@
1
- import { n as MobileSignedInner } from "./types-uCD4BNZR.cjs";
1
+ import { n as MobileSignedInner } from "./types-CzOeSYnW.cjs";
2
2
  import { Hex } from "viem";
3
3
 
4
4
  //#region src/signing/payloadHash.d.ts
@@ -10,4 +10,4 @@ import { Hex } from "viem";
10
10
  declare function getMobilePayloadHash(inner: MobileSignedInner): Hex;
11
11
  //#endregion
12
12
  export { getMobilePayloadHash as t };
13
- //# sourceMappingURL=payloadHash-nj8WuLUP.d.cts.map
13
+ //# sourceMappingURL=payloadHash-BSoGv3Lz.d.cts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"payloadHash-BSoGv3Lz.d.cts","names":[],"sources":["../src/signing/src/signing/payloadHash.ts"],"mappings":";;;;;;AASA;;;iBAAgB,oBAAA,CAAqB,KAAA,EAAO,iBAAA,GAAoB,GAAG"}
@@ -1,4 +1,4 @@
1
- import { n as MobileSignedInner } from "./types-B76Pn7Sy.js";
1
+ import { n as MobileSignedInner } from "./types-UHjZR-js.js";
2
2
  import { Hex } from "viem";
3
3
 
4
4
  //#region src/signing/payloadHash.d.ts
@@ -10,4 +10,4 @@ import { Hex } from "viem";
10
10
  declare function getMobilePayloadHash(inner: MobileSignedInner): Hex;
11
11
  //#endregion
12
12
  export { getMobilePayloadHash as t };
13
- //# sourceMappingURL=payloadHash-Bmhzs78N.d.ts.map
13
+ //# sourceMappingURL=payloadHash-BVP2v3p9.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"payloadHash-BVP2v3p9.d.ts","names":[],"sources":["../src/signing/src/signing/payloadHash.ts"],"mappings":";;;;;;AASA;;;iBAAgB,oBAAA,CAAqB,KAAA,EAAO,iBAAA,GAAoB,GAAG"}
@@ -0,0 +1,25 @@
1
+ import { i as MobileServerRequestType } from "./serverRequestTypes-DnU_FfMI.cjs";
2
+
3
+ //#region src/types/serverBaseTypes.d.ts
4
+ /**
5
+ * Base success envelope shared by every mobile service API route: just the `status` discriminant. Query
6
+ * routes intersect this with their payload (see {@link MobileServerPublicQuerySuccessResponse}), inlining the
7
+ * payload fields alongside `status` rather than nesting them under a `data` key like the engine does; execute
8
+ * routes return it as-is because they carry no payload.
9
+ */
10
+ interface MobileServerSuccessResponse {
11
+ status: 'success';
12
+ }
13
+ /**
14
+ * Failure envelope returned by any mobile service API route. A response missing this envelope shape
15
+ * (e.g. a malformed body, or a non-JSON response) is a transport-level error, not a domain error.
16
+ */
17
+ interface MobileServerFailureResponse {
18
+ status: 'failure';
19
+ error: string;
20
+ error_code: number;
21
+ request_type: MobileServerRequestType;
22
+ }
23
+ //#endregion
24
+ export { MobileServerSuccessResponse as n, MobileServerFailureResponse as t };
25
+ //# sourceMappingURL=serverBaseTypes-A16onlPN.d.cts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"serverBaseTypes-A16onlPN.d.cts","names":[],"sources":["../src/types/src/types/serverBaseTypes.ts"],"mappings":";;;;;AAQA;;;;UAAiB,2BAAA;EACf,MAAM;AAAA;;;;;UAOS,2BAAA;EACf,MAAA;EACA,KAAA;EACA,UAAA;EACA,YAAA,EAAc,uBAAuB;AAAA"}
@@ -0,0 +1,25 @@
1
+ import { i as MobileServerRequestType } from "./serverRequestTypes-DQDy3K9O.js";
2
+
3
+ //#region src/types/serverBaseTypes.d.ts
4
+ /**
5
+ * Base success envelope shared by every mobile service API route: just the `status` discriminant. Query
6
+ * routes intersect this with their payload (see {@link MobileServerPublicQuerySuccessResponse}), inlining the
7
+ * payload fields alongside `status` rather than nesting them under a `data` key like the engine does; execute
8
+ * routes return it as-is because they carry no payload.
9
+ */
10
+ interface MobileServerSuccessResponse {
11
+ status: 'success';
12
+ }
13
+ /**
14
+ * Failure envelope returned by any mobile service API route. A response missing this envelope shape
15
+ * (e.g. a malformed body, or a non-JSON response) is a transport-level error, not a domain error.
16
+ */
17
+ interface MobileServerFailureResponse {
18
+ status: 'failure';
19
+ error: string;
20
+ error_code: number;
21
+ request_type: MobileServerRequestType;
22
+ }
23
+ //#endregion
24
+ export { MobileServerSuccessResponse as n, MobileServerFailureResponse as t };
25
+ //# sourceMappingURL=serverBaseTypes-m3zEi0X9.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"serverBaseTypes-m3zEi0X9.d.ts","names":[],"sources":["../src/types/src/types/serverBaseTypes.ts"],"mappings":";;;;;AAQA;;;;UAAiB,2BAAA;EACf,MAAM;AAAA;;;;;UAOS,2BAAA;EACf,MAAA;EACA,KAAA;EACA,UAAA;EACA,YAAA,EAAc,uBAAuB;AAAA"}
@@ -1,4 +1,4 @@
1
- import { a as MobileServerSuccessResponse, t as MobileServerFailureResponse } from "./serverBaseTypes-BicXMrZV.cjs";
1
+ import { n as MobileServerSuccessResponse, t as MobileServerFailureResponse } from "./serverBaseTypes-A16onlPN.cjs";
2
2
 
3
3
  //#region src/types/serverExecuteTypes.d.ts
4
4
  /**
@@ -8,4 +8,4 @@ import { a as MobileServerSuccessResponse, t as MobileServerFailureResponse } fr
8
8
  type MobileServerExecuteResult = MobileServerSuccessResponse | MobileServerFailureResponse;
9
9
  //#endregion
10
10
  export { MobileServerExecuteResult as t };
11
- //# sourceMappingURL=serverExecuteTypes-DKYK1V7C.d.cts.map
11
+ //# sourceMappingURL=serverExecuteTypes-C-bioiuQ.d.cts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"serverExecuteTypes-C-bioiuQ.d.cts","names":[],"sources":["../src/types/src/types/serverExecuteTypes.ts"],"mappings":";;;;;AASA;;KAAY,yBAAA,GACR,2BAAA,GACA,2BAA2B"}
@@ -1,4 +1,4 @@
1
- import { a as MobileServerSuccessResponse, t as MobileServerFailureResponse } from "./serverBaseTypes-ewbo8l4R.js";
1
+ import { n as MobileServerSuccessResponse, t as MobileServerFailureResponse } from "./serverBaseTypes-m3zEi0X9.js";
2
2
 
3
3
  //#region src/types/serverExecuteTypes.d.ts
4
4
  /**
@@ -8,4 +8,4 @@ import { a as MobileServerSuccessResponse, t as MobileServerFailureResponse } fr
8
8
  type MobileServerExecuteResult = MobileServerSuccessResponse | MobileServerFailureResponse;
9
9
  //#endregion
10
10
  export { MobileServerExecuteResult as t };
11
- //# sourceMappingURL=serverExecuteTypes-CXnMjKnt.d.ts.map
11
+ //# sourceMappingURL=serverExecuteTypes-DfzWOeIx.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"serverExecuteTypes-DfzWOeIx.d.ts","names":[],"sources":["../src/types/src/types/serverExecuteTypes.ts"],"mappings":";;;;;AASA;;KAAY,yBAAA,GACR,2BAAA,GACA,2BAA2B"}
@@ -0,0 +1,143 @@
1
+ import { BalanceSide } from "@nadohq/shared";
2
+ import { Hex } from "viem";
3
+
4
+ //#region src/types/serverModelTypes.d.ts
5
+ /**
6
+ * Platform of a device registered for push notifications.
7
+ */
8
+ type MobileNotificationPlatform = 'ios' | 'android';
9
+ /**
10
+ * Category of push notification.
11
+ */
12
+ type MobileNotificationCategory = 'order_fill' | 'order_update' | 'liquidation' | 'funding' | 'product_listing' | 'announcement';
13
+ /**
14
+ * Server-side public profile shape (snake_case).
15
+ */
16
+ interface MobileServerProfile {
17
+ subaccount: Hex;
18
+ username: string;
19
+ display_name: string;
20
+ }
21
+ /**
22
+ * Server-side identity shape (snake_case) returned by the signed `self_identity` query.
23
+ */
24
+ interface MobileServerIdentity {
25
+ subaccount: Hex;
26
+ username: string;
27
+ display_name: string;
28
+ private_mode: boolean;
29
+ }
30
+ /**
31
+ * Direction of the position a feed trade resulted in — for `closed`, the direction that was closed. This is
32
+ * NOT the execution buy/sell side, which the feed does not expose. Aliases {@link BalanceSide} so the feed's
33
+ * direction values stay in lockstep with the rest of the SDK.
34
+ */
35
+ type MobileFeedTradePositionDirection = BalanceSide;
36
+ /**
37
+ * Every {@link MobileFeedTradePositionDirection} the feed can report, for callers that need the values at
38
+ * runtime (validation, filters, UI enumeration).
39
+ */
40
+ declare const MOBILE_FEED_TRADE_POSITION_DIRECTIONS: readonly ["long", "short"];
41
+ /**
42
+ * Every {@link MobileFeedTradePositionEffect} the feed can report, for callers that need the values at
43
+ * runtime (validation, filters, UI enumeration).
44
+ */
45
+ declare const MOBILE_FEED_TRADE_POSITION_EFFECTS: readonly ["opened", "increased", "reduced", "closed", "flipped"];
46
+ /**
47
+ * How a feed trade changed the trader's position in the product.
48
+ */
49
+ type MobileFeedTradePositionEffect = (typeof MOBILE_FEED_TRADE_POSITION_EFFECTS)[number];
50
+ /**
51
+ * Position change of a feed trade. Both keys are single words, so the wire and client shapes are identical
52
+ * and this type is shared by {@link MobileServerFeedTrade} and the client-side `MobileFeedTrade`.
53
+ */
54
+ interface MobileFeedTradePosition {
55
+ direction: MobileFeedTradePositionDirection;
56
+ effect: MobileFeedTradePositionEffect;
57
+ }
58
+ /**
59
+ * Every {@link MobileFeedMarginMode} the feed can report, for callers that need the values at runtime
60
+ * (validation, filters, UI enumeration).
61
+ */
62
+ declare const MOBILE_FEED_MARGIN_MODES: readonly ["cross", "isolated"];
63
+ /**
64
+ * Margin mode a feed trade was executed under. Shared by the wire and client margin shapes.
65
+ */
66
+ type MobileFeedMarginMode = (typeof MOBILE_FEED_MARGIN_MODES)[number];
67
+ /**
68
+ * Server-side margin of a feed trade. Branch on `mode` — do not infer isolated state from leverage presence:
69
+ * `estimated_leverage` (a rounded whole-number estimate, not exact submitted leverage) is omitted on `cross`,
70
+ * and also omitted inside `isolated` when no estimate is available.
71
+ */
72
+ interface MobileServerFeedMargin {
73
+ mode: MobileFeedMarginMode;
74
+ estimated_leverage?: number;
75
+ }
76
+ /**
77
+ * Server-side feed trade shape (snake_case): one row per order digest, enriched at read time with the
78
+ * trader's current identity. Amounts are display-oriented human-unit JSON numbers — do not use them for
79
+ * accounting, order construction, or exact threshold decisions.
80
+ */
81
+ interface MobileServerFeedTrade {
82
+ /** Order digest this row is keyed by; the stable id clients use to reconcile live pagination. */
83
+ order_digest: Hex;
84
+ subaccount: Hex;
85
+ username: string;
86
+ display_name: string;
87
+ /** Reserved for a future avatar source; `null` until one is implemented. */
88
+ avatar_url: string | null;
89
+ product_id: number;
90
+ /** Executed quantity in human units. */
91
+ quantity: number;
92
+ /** Trade notional in whole-dollar human units. */
93
+ notional: number;
94
+ /** Average execution price in human units. */
95
+ average_price: number;
96
+ margin: MobileServerFeedMargin;
97
+ position: MobileFeedTradePosition;
98
+ /** Realized PnL of the trade in human units; can be negative. */
99
+ realized_pnl: number;
100
+ /** Fill time as JavaScript-safe integer Unix milliseconds. */
101
+ filled_at_ms: number;
102
+ }
103
+ /**
104
+ * Server-side scope limiting a notification category preference. Scopes are rejected by the backend for the
105
+ * MVP (`scopes` must be empty) but are part of the wire format.
106
+ */
107
+ type MobileServerNotificationPreferenceScope = {
108
+ type: 'subaccount';
109
+ subaccount: Hex;
110
+ } | {
111
+ type: 'product';
112
+ product_id: number;
113
+ };
114
+ /**
115
+ * Server-side per-category notification preference (snake_case).
116
+ */
117
+ interface MobileServerNotificationCategoryPreference {
118
+ category: MobileNotificationCategory;
119
+ enabled: boolean;
120
+ scopes: MobileServerNotificationPreferenceScope[];
121
+ }
122
+ /**
123
+ * Server-side notification preferences shape (snake_case), used in both the `update_preferences` execute and
124
+ * the `notification_preferences` query response.
125
+ */
126
+ interface MobileServerNotificationPreferences {
127
+ /** Only `1` is accepted by the backend for the MVP. */
128
+ schema_version: 1;
129
+ categories: MobileServerNotificationCategoryPreference[];
130
+ }
131
+ /**
132
+ * Server-side registered push device shape (snake_case).
133
+ */
134
+ interface MobileServerRegisteredDevice {
135
+ platform: MobileNotificationPlatform;
136
+ locale: string | null;
137
+ app_version: string | null;
138
+ token_fingerprint_prefix: string;
139
+ last_seen_at: number;
140
+ }
141
+ //#endregion
142
+ export { MobileServerRegisteredDevice as _, MobileFeedTradePosition as a, MobileNotificationCategory as c, MobileServerFeedTrade as d, MobileServerIdentity as f, MobileServerProfile as g, MobileServerNotificationPreferences as h, MobileFeedMarginMode as i, MobileNotificationPlatform as l, MobileServerNotificationPreferenceScope as m, MOBILE_FEED_TRADE_POSITION_DIRECTIONS as n, MobileFeedTradePositionDirection as o, MobileServerNotificationCategoryPreference as p, MOBILE_FEED_TRADE_POSITION_EFFECTS as r, MobileFeedTradePositionEffect as s, MOBILE_FEED_MARGIN_MODES as t, MobileServerFeedMargin as u };
143
+ //# sourceMappingURL=serverModelTypes-CPZUvVil.d.cts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"serverModelTypes-CPZUvVil.d.cts","names":[],"sources":["../src/types/src/types/serverModelTypes.ts"],"mappings":";;;;;;AAMA;KAAY,0BAAA;;;AAA0B;KAK1B,0BAAA;;;;UAWK,mBAAA;EACf,UAAA,EAAY,GAAG;EACf,QAAA;EACA,YAAA;AAAA;;;;UAMe,oBAAA;EACf,UAAA,EAAY,GAAG;EACf,QAAA;EACA,YAAA;EACA,YAAA;AAAA;;;;;;KAQU,gCAAA,GAAmC,WAAW;;AAR5C;AAQd;;cAMa,qCAAA;;AAN6C;AAM1D;;cASa,kCAAA;;AANmD;AAMhE;KAWY,6BAAA,WACF,kCAAkC;;;AANlC;AAKV;UAOiB,uBAAA;EACf,SAAA,EAAW,gCAAA;EACX,MAAA,EAAQ,6BAA6B;AAAA;AAFvC;;;;AAAA,cASa,wBAAA;;;;KAKD,oBAAA,WAA+B,wBAAwB;AAZ5B;AAOvC;;;;AAPuC,UAmBtB,sBAAA;EACf,IAAA,EAAM,oBAAoB;EAC1B,kBAAA;AAAA;;AATiE;AAOnE;;;UAUiB,qBAAA;EATf;EAWA,YAAA,EAAc,GAAA;EACd,UAAA,EAAY,GAAA;EACZ,QAAA;EACA,YAAA;EALe;EAOf,UAAA;EACA,UAAA;EANc;EAQd,QAAA;EAKQ;EAHR,QAAA;EAIiC;EAFjC,aAAA;EACA,MAAA,EAAQ,sBAAA;EACR,QAAA,EAAU,uBAAA;EAbV;EAeA,YAAA;EAdA;EAgBA,YAAA;AAAA;;;;;KAOU,uCAAA;EACN,IAAA;EAAoB,UAAA,EAAY,GAAG;AAAA;EACnC,IAAA;EAAiB,UAAA;AAAA;AATT;AAOd;;AAPc,UAcG,0CAAA;EACf,QAAA,EAAU,0BAAA;EACV,OAAA;EACA,MAAA,EAAQ,uCAAuC;AAAA;;;;AARhB;UAehB,mCAAA;EAV0C;EAYzD,cAAA;EACA,UAAA,EAAY,0CAA0C;AAAA;;;;UAMvC,4BAAA;EACf,QAAA,EAAU,0BAA0B;EACpC,MAAA;EACA,WAAA;EACA,wBAAA;EACA,YAAA;AAAA"}
@@ -0,0 +1,143 @@
1
+ import { BalanceSide } from "@nadohq/shared";
2
+ import { Hex } from "viem";
3
+
4
+ //#region src/types/serverModelTypes.d.ts
5
+ /**
6
+ * Platform of a device registered for push notifications.
7
+ */
8
+ type MobileNotificationPlatform = 'ios' | 'android';
9
+ /**
10
+ * Category of push notification.
11
+ */
12
+ type MobileNotificationCategory = 'order_fill' | 'order_update' | 'liquidation' | 'funding' | 'product_listing' | 'announcement';
13
+ /**
14
+ * Server-side public profile shape (snake_case).
15
+ */
16
+ interface MobileServerProfile {
17
+ subaccount: Hex;
18
+ username: string;
19
+ display_name: string;
20
+ }
21
+ /**
22
+ * Server-side identity shape (snake_case) returned by the signed `self_identity` query.
23
+ */
24
+ interface MobileServerIdentity {
25
+ subaccount: Hex;
26
+ username: string;
27
+ display_name: string;
28
+ private_mode: boolean;
29
+ }
30
+ /**
31
+ * Direction of the position a feed trade resulted in — for `closed`, the direction that was closed. This is
32
+ * NOT the execution buy/sell side, which the feed does not expose. Aliases {@link BalanceSide} so the feed's
33
+ * direction values stay in lockstep with the rest of the SDK.
34
+ */
35
+ type MobileFeedTradePositionDirection = BalanceSide;
36
+ /**
37
+ * Every {@link MobileFeedTradePositionDirection} the feed can report, for callers that need the values at
38
+ * runtime (validation, filters, UI enumeration).
39
+ */
40
+ declare const MOBILE_FEED_TRADE_POSITION_DIRECTIONS: readonly ["long", "short"];
41
+ /**
42
+ * Every {@link MobileFeedTradePositionEffect} the feed can report, for callers that need the values at
43
+ * runtime (validation, filters, UI enumeration).
44
+ */
45
+ declare const MOBILE_FEED_TRADE_POSITION_EFFECTS: readonly ["opened", "increased", "reduced", "closed", "flipped"];
46
+ /**
47
+ * How a feed trade changed the trader's position in the product.
48
+ */
49
+ type MobileFeedTradePositionEffect = (typeof MOBILE_FEED_TRADE_POSITION_EFFECTS)[number];
50
+ /**
51
+ * Position change of a feed trade. Both keys are single words, so the wire and client shapes are identical
52
+ * and this type is shared by {@link MobileServerFeedTrade} and the client-side `MobileFeedTrade`.
53
+ */
54
+ interface MobileFeedTradePosition {
55
+ direction: MobileFeedTradePositionDirection;
56
+ effect: MobileFeedTradePositionEffect;
57
+ }
58
+ /**
59
+ * Every {@link MobileFeedMarginMode} the feed can report, for callers that need the values at runtime
60
+ * (validation, filters, UI enumeration).
61
+ */
62
+ declare const MOBILE_FEED_MARGIN_MODES: readonly ["cross", "isolated"];
63
+ /**
64
+ * Margin mode a feed trade was executed under. Shared by the wire and client margin shapes.
65
+ */
66
+ type MobileFeedMarginMode = (typeof MOBILE_FEED_MARGIN_MODES)[number];
67
+ /**
68
+ * Server-side margin of a feed trade. Branch on `mode` — do not infer isolated state from leverage presence:
69
+ * `estimated_leverage` (a rounded whole-number estimate, not exact submitted leverage) is omitted on `cross`,
70
+ * and also omitted inside `isolated` when no estimate is available.
71
+ */
72
+ interface MobileServerFeedMargin {
73
+ mode: MobileFeedMarginMode;
74
+ estimated_leverage?: number;
75
+ }
76
+ /**
77
+ * Server-side feed trade shape (snake_case): one row per order digest, enriched at read time with the
78
+ * trader's current identity. Amounts are display-oriented human-unit JSON numbers — do not use them for
79
+ * accounting, order construction, or exact threshold decisions.
80
+ */
81
+ interface MobileServerFeedTrade {
82
+ /** Order digest this row is keyed by; the stable id clients use to reconcile live pagination. */
83
+ order_digest: Hex;
84
+ subaccount: Hex;
85
+ username: string;
86
+ display_name: string;
87
+ /** Reserved for a future avatar source; `null` until one is implemented. */
88
+ avatar_url: string | null;
89
+ product_id: number;
90
+ /** Executed quantity in human units. */
91
+ quantity: number;
92
+ /** Trade notional in whole-dollar human units. */
93
+ notional: number;
94
+ /** Average execution price in human units. */
95
+ average_price: number;
96
+ margin: MobileServerFeedMargin;
97
+ position: MobileFeedTradePosition;
98
+ /** Realized PnL of the trade in human units; can be negative. */
99
+ realized_pnl: number;
100
+ /** Fill time as JavaScript-safe integer Unix milliseconds. */
101
+ filled_at_ms: number;
102
+ }
103
+ /**
104
+ * Server-side scope limiting a notification category preference. Scopes are rejected by the backend for the
105
+ * MVP (`scopes` must be empty) but are part of the wire format.
106
+ */
107
+ type MobileServerNotificationPreferenceScope = {
108
+ type: 'subaccount';
109
+ subaccount: Hex;
110
+ } | {
111
+ type: 'product';
112
+ product_id: number;
113
+ };
114
+ /**
115
+ * Server-side per-category notification preference (snake_case).
116
+ */
117
+ interface MobileServerNotificationCategoryPreference {
118
+ category: MobileNotificationCategory;
119
+ enabled: boolean;
120
+ scopes: MobileServerNotificationPreferenceScope[];
121
+ }
122
+ /**
123
+ * Server-side notification preferences shape (snake_case), used in both the `update_preferences` execute and
124
+ * the `notification_preferences` query response.
125
+ */
126
+ interface MobileServerNotificationPreferences {
127
+ /** Only `1` is accepted by the backend for the MVP. */
128
+ schema_version: 1;
129
+ categories: MobileServerNotificationCategoryPreference[];
130
+ }
131
+ /**
132
+ * Server-side registered push device shape (snake_case).
133
+ */
134
+ interface MobileServerRegisteredDevice {
135
+ platform: MobileNotificationPlatform;
136
+ locale: string | null;
137
+ app_version: string | null;
138
+ token_fingerprint_prefix: string;
139
+ last_seen_at: number;
140
+ }
141
+ //#endregion
142
+ export { MobileServerRegisteredDevice as _, MobileFeedTradePosition as a, MobileNotificationCategory as c, MobileServerFeedTrade as d, MobileServerIdentity as f, MobileServerProfile as g, MobileServerNotificationPreferences as h, MobileFeedMarginMode as i, MobileNotificationPlatform as l, MobileServerNotificationPreferenceScope as m, MOBILE_FEED_TRADE_POSITION_DIRECTIONS as n, MobileFeedTradePositionDirection as o, MobileServerNotificationCategoryPreference as p, MOBILE_FEED_TRADE_POSITION_EFFECTS as r, MobileFeedTradePositionEffect as s, MOBILE_FEED_MARGIN_MODES as t, MobileServerFeedMargin as u };
143
+ //# sourceMappingURL=serverModelTypes-CqnqHY5F.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"serverModelTypes-CqnqHY5F.d.ts","names":[],"sources":["../src/types/src/types/serverModelTypes.ts"],"mappings":";;;;;;AAMA;KAAY,0BAAA;;;AAA0B;KAK1B,0BAAA;;;;UAWK,mBAAA;EACf,UAAA,EAAY,GAAG;EACf,QAAA;EACA,YAAA;AAAA;;;;UAMe,oBAAA;EACf,UAAA,EAAY,GAAG;EACf,QAAA;EACA,YAAA;EACA,YAAA;AAAA;;;;;;KAQU,gCAAA,GAAmC,WAAW;;AAR5C;AAQd;;cAMa,qCAAA;;AAN6C;AAM1D;;cASa,kCAAA;;AANmD;AAMhE;KAWY,6BAAA,WACF,kCAAkC;;;AANlC;AAKV;UAOiB,uBAAA;EACf,SAAA,EAAW,gCAAA;EACX,MAAA,EAAQ,6BAA6B;AAAA;AAFvC;;;;AAAA,cASa,wBAAA;;;;KAKD,oBAAA,WAA+B,wBAAwB;AAZ5B;AAOvC;;;;AAPuC,UAmBtB,sBAAA;EACf,IAAA,EAAM,oBAAoB;EAC1B,kBAAA;AAAA;;AATiE;AAOnE;;;UAUiB,qBAAA;EATf;EAWA,YAAA,EAAc,GAAA;EACd,UAAA,EAAY,GAAA;EACZ,QAAA;EACA,YAAA;EALe;EAOf,UAAA;EACA,UAAA;EANc;EAQd,QAAA;EAKQ;EAHR,QAAA;EAIiC;EAFjC,aAAA;EACA,MAAA,EAAQ,sBAAA;EACR,QAAA,EAAU,uBAAA;EAbV;EAeA,YAAA;EAdA;EAgBA,YAAA;AAAA;;;;;KAOU,uCAAA;EACN,IAAA;EAAoB,UAAA,EAAY,GAAG;AAAA;EACnC,IAAA;EAAiB,UAAA;AAAA;AATT;AAOd;;AAPc,UAcG,0CAAA;EACf,QAAA,EAAU,0BAAA;EACV,OAAA;EACA,MAAA,EAAQ,uCAAuC;AAAA;;;;AARhB;UAehB,mCAAA;EAV0C;EAYzD,cAAA;EACA,UAAA,EAAY,0CAA0C;AAAA;;;;UAMvC,4BAAA;EACf,QAAA,EAAU,0BAA0B;EACpC,MAAA;EACA,WAAA;EACA,wBAAA;EACA,YAAA;AAAA"}
@@ -0,0 +1,91 @@
1
+ import { _ as MobileServerRegisteredDevice, d as MobileServerFeedTrade, f as MobileServerIdentity, g as MobileServerProfile, h as MobileServerNotificationPreferences } from "./serverModelTypes-CqnqHY5F.js";
2
+ import { n as MobileServerPublicQueryRequestByType, o as MobileServerSignedQueryRequestType, r as MobileServerPublicQueryRequestType } from "./serverRequestTypes-DQDy3K9O.js";
3
+ import { n as MobileServerSuccessResponse } from "./serverBaseTypes-m3zEi0X9.js";
4
+
5
+ //#region src/types/serverQueryTypes.d.ts
6
+ /**
7
+ * Unsigned `public_query` request body: a `type` discriminant flattened with its params.
8
+ */
9
+ type MobileServerPublicQueryRequest<T extends MobileServerPublicQueryRequestType = MobileServerPublicQueryRequestType> = { [K in MobileServerPublicQueryRequestType]: {
10
+ type: K;
11
+ } & MobileServerPublicQueryRequestByType[K] }[T];
12
+ /**
13
+ * Payload of the `username_availability` public query success response.
14
+ */
15
+ interface MobileServerUsernameAvailabilityResponse {
16
+ username: string;
17
+ available: boolean;
18
+ }
19
+ /**
20
+ * Payload of the `profile` public query success response.
21
+ */
22
+ interface MobileServerProfileResponse {
23
+ profile: MobileServerProfile;
24
+ }
25
+ /**
26
+ * Payload of the `feed` public query success response.
27
+ */
28
+ interface MobileServerFeedResponse {
29
+ trades: MobileServerFeedTrade[];
30
+ /**
31
+ * `null` when there was no additional candidate at query time; a page may contain fewer than `limit` trades
32
+ * (or none) with a non-null cursor because invalid enrichment rows are omitted and pagination is live
33
+ * rather than snapshot.
34
+ */
35
+ next_cursor: string | null;
36
+ }
37
+ /**
38
+ * Payload of the signed `self_identity` query success response. A `null` identity means the subaccount has
39
+ * not claimed a username yet — this is normal data, not an error.
40
+ */
41
+ interface MobileServerSelfIdentityResponse {
42
+ identity: MobileServerIdentity | null;
43
+ }
44
+ /**
45
+ * Payload of the signed `notification_preferences` query success response.
46
+ */
47
+ interface MobileServerNotificationPreferencesResponse {
48
+ preferences: MobileServerNotificationPreferences;
49
+ }
50
+ /**
51
+ * Payload of the signed `registered_devices` query success response.
52
+ */
53
+ interface MobileServerRegisteredDevicesResponse {
54
+ devices: MobileServerRegisteredDevice[];
55
+ }
56
+ /**
57
+ * Success payloads for each unsigned `public_query`, keyed by request `type`. Counterpart to
58
+ * {@link MobileServerPublicQueryRequestByType} so a query's request params and response share one lookup,
59
+ * matching engine's `EngineServerQueryResponseByType`. Holds the unwrapped payload; the envelope is applied
60
+ * by {@link MobileServerPublicQuerySuccessResponse}.
61
+ */
62
+ interface MobileServerPublicQueryResponseByType {
63
+ username_availability: MobileServerUsernameAvailabilityResponse;
64
+ profile: MobileServerProfileResponse;
65
+ feed: MobileServerFeedResponse;
66
+ }
67
+ /**
68
+ * Success payloads for each signed `query`, keyed by request `type`. Counterpart to
69
+ * {@link MobileServerSignedQueryRequestByType} so a signed query's request params and response share one
70
+ * lookup, matching the public route. Holds the unwrapped payload; the envelope is applied by
71
+ * {@link MobileServerSignedQuerySuccessResponse}.
72
+ */
73
+ interface MobileServerSignedQueryResponseByType {
74
+ self_identity: MobileServerSelfIdentityResponse;
75
+ notification_preferences: MobileServerNotificationPreferencesResponse;
76
+ registered_devices: MobileServerRegisteredDevicesResponse;
77
+ }
78
+ /**
79
+ * Full success response for an unsigned `public_query`: the {@link MobileServerSuccessResponse} envelope with
80
+ * the query's payload inlined alongside `status`. Derived from {@link MobileServerPublicQueryResponseByType},
81
+ * mirroring engine's `EngineServerQuerySuccessResponse` (inlined here instead of nested under `data`).
82
+ */
83
+ type MobileServerPublicQuerySuccessResponse<T extends MobileServerPublicQueryRequestType = MobileServerPublicQueryRequestType> = MobileServerSuccessResponse & MobileServerPublicQueryResponseByType[T];
84
+ /**
85
+ * Full success response for a signed `query`: the {@link MobileServerSuccessResponse} envelope with the
86
+ * query's payload inlined alongside `status`. Derived from {@link MobileServerSignedQueryResponseByType}.
87
+ */
88
+ type MobileServerSignedQuerySuccessResponse<T extends MobileServerSignedQueryRequestType = MobileServerSignedQueryRequestType> = MobileServerSuccessResponse & MobileServerSignedQueryResponseByType[T];
89
+ //#endregion
90
+ export { MobileServerPublicQueryResponseByType as a, MobileServerSelfIdentityResponse as c, MobileServerUsernameAvailabilityResponse as d, MobileServerPublicQueryRequest as i, MobileServerSignedQueryResponseByType as l, MobileServerNotificationPreferencesResponse as n, MobileServerPublicQuerySuccessResponse as o, MobileServerProfileResponse as r, MobileServerRegisteredDevicesResponse as s, MobileServerFeedResponse as t, MobileServerSignedQuerySuccessResponse as u };
91
+ //# sourceMappingURL=serverQueryTypes-CJLWWZBs.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"serverQueryTypes-CJLWWZBs.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,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;UAciB,gCAAA;EACf,QAAA,EAAU,oBAAoB;AAAA;;;;UAMf,2CAAA;EACf,WAAA,EAAa,mCAAmC;AAAA;;;;UAMjC,qCAAA;EACf,OAAA,EAAS,4BAA4B;AAAA;;;AAPW;AAMlD;;;UAUiB,qCAAA;EACf,qBAAA,EAAuB,wCAAA;EACvB,OAAA,EAAS,2BAAA;EACT,IAAA,EAAM,wBAAA;AAAA;;;;;;;UASS,qCAAA;EACf,aAAA,EAAe,gCAAA;EACf,wBAAA,EAA0B,2CAAA;EAC1B,kBAAA,EAAoB,qCAAA;AAAA;;AAZU;AAShC;;;KAWY,sCAAA,WACA,kCAAA,GACR,kCAAA,IACA,2BAAA,GAA8B,qCAAA,CAAsC,CAAA;;;;;KAM5D,sCAAA,WACA,kCAAA,GACR,kCAAA,IACA,2BAAA,GAA8B,qCAAA,CAAsC,CAAA"}
@@ -0,0 +1,91 @@
1
+ import { _ as MobileServerRegisteredDevice, d as MobileServerFeedTrade, f as MobileServerIdentity, g as MobileServerProfile, h as MobileServerNotificationPreferences } from "./serverModelTypes-CPZUvVil.cjs";
2
+ import { n as MobileServerPublicQueryRequestByType, o as MobileServerSignedQueryRequestType, r as MobileServerPublicQueryRequestType } from "./serverRequestTypes-DnU_FfMI.cjs";
3
+ import { n as MobileServerSuccessResponse } from "./serverBaseTypes-A16onlPN.cjs";
4
+
5
+ //#region src/types/serverQueryTypes.d.ts
6
+ /**
7
+ * Unsigned `public_query` request body: a `type` discriminant flattened with its params.
8
+ */
9
+ type MobileServerPublicQueryRequest<T extends MobileServerPublicQueryRequestType = MobileServerPublicQueryRequestType> = { [K in MobileServerPublicQueryRequestType]: {
10
+ type: K;
11
+ } & MobileServerPublicQueryRequestByType[K] }[T];
12
+ /**
13
+ * Payload of the `username_availability` public query success response.
14
+ */
15
+ interface MobileServerUsernameAvailabilityResponse {
16
+ username: string;
17
+ available: boolean;
18
+ }
19
+ /**
20
+ * Payload of the `profile` public query success response.
21
+ */
22
+ interface MobileServerProfileResponse {
23
+ profile: MobileServerProfile;
24
+ }
25
+ /**
26
+ * Payload of the `feed` public query success response.
27
+ */
28
+ interface MobileServerFeedResponse {
29
+ trades: MobileServerFeedTrade[];
30
+ /**
31
+ * `null` when there was no additional candidate at query time; a page may contain fewer than `limit` trades
32
+ * (or none) with a non-null cursor because invalid enrichment rows are omitted and pagination is live
33
+ * rather than snapshot.
34
+ */
35
+ next_cursor: string | null;
36
+ }
37
+ /**
38
+ * Payload of the signed `self_identity` query success response. A `null` identity means the subaccount has
39
+ * not claimed a username yet — this is normal data, not an error.
40
+ */
41
+ interface MobileServerSelfIdentityResponse {
42
+ identity: MobileServerIdentity | null;
43
+ }
44
+ /**
45
+ * Payload of the signed `notification_preferences` query success response.
46
+ */
47
+ interface MobileServerNotificationPreferencesResponse {
48
+ preferences: MobileServerNotificationPreferences;
49
+ }
50
+ /**
51
+ * Payload of the signed `registered_devices` query success response.
52
+ */
53
+ interface MobileServerRegisteredDevicesResponse {
54
+ devices: MobileServerRegisteredDevice[];
55
+ }
56
+ /**
57
+ * Success payloads for each unsigned `public_query`, keyed by request `type`. Counterpart to
58
+ * {@link MobileServerPublicQueryRequestByType} so a query's request params and response share one lookup,
59
+ * matching engine's `EngineServerQueryResponseByType`. Holds the unwrapped payload; the envelope is applied
60
+ * by {@link MobileServerPublicQuerySuccessResponse}.
61
+ */
62
+ interface MobileServerPublicQueryResponseByType {
63
+ username_availability: MobileServerUsernameAvailabilityResponse;
64
+ profile: MobileServerProfileResponse;
65
+ feed: MobileServerFeedResponse;
66
+ }
67
+ /**
68
+ * Success payloads for each signed `query`, keyed by request `type`. Counterpart to
69
+ * {@link MobileServerSignedQueryRequestByType} so a signed query's request params and response share one
70
+ * lookup, matching the public route. Holds the unwrapped payload; the envelope is applied by
71
+ * {@link MobileServerSignedQuerySuccessResponse}.
72
+ */
73
+ interface MobileServerSignedQueryResponseByType {
74
+ self_identity: MobileServerSelfIdentityResponse;
75
+ notification_preferences: MobileServerNotificationPreferencesResponse;
76
+ registered_devices: MobileServerRegisteredDevicesResponse;
77
+ }
78
+ /**
79
+ * Full success response for an unsigned `public_query`: the {@link MobileServerSuccessResponse} envelope with
80
+ * the query's payload inlined alongside `status`. Derived from {@link MobileServerPublicQueryResponseByType},
81
+ * mirroring engine's `EngineServerQuerySuccessResponse` (inlined here instead of nested under `data`).
82
+ */
83
+ type MobileServerPublicQuerySuccessResponse<T extends MobileServerPublicQueryRequestType = MobileServerPublicQueryRequestType> = MobileServerSuccessResponse & MobileServerPublicQueryResponseByType[T];
84
+ /**
85
+ * Full success response for a signed `query`: the {@link MobileServerSuccessResponse} envelope with the
86
+ * query's payload inlined alongside `status`. Derived from {@link MobileServerSignedQueryResponseByType}.
87
+ */
88
+ type MobileServerSignedQuerySuccessResponse<T extends MobileServerSignedQueryRequestType = MobileServerSignedQueryRequestType> = MobileServerSuccessResponse & MobileServerSignedQueryResponseByType[T];
89
+ //#endregion
90
+ export { MobileServerPublicQueryResponseByType as a, MobileServerSelfIdentityResponse as c, MobileServerUsernameAvailabilityResponse as d, MobileServerPublicQueryRequest as i, MobileServerSignedQueryResponseByType as l, MobileServerNotificationPreferencesResponse as n, MobileServerPublicQuerySuccessResponse as o, MobileServerProfileResponse as r, MobileServerRegisteredDevicesResponse as s, MobileServerFeedResponse as t, MobileServerSignedQuerySuccessResponse as u };
91
+ //# sourceMappingURL=serverQueryTypes-C_cCx0Ac.d.cts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"serverQueryTypes-C_cCx0Ac.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;UAciB,gCAAA;EACf,QAAA,EAAU,oBAAoB;AAAA;;;;UAMf,2CAAA;EACf,WAAA,EAAa,mCAAmC;AAAA;;;;UAMjC,qCAAA;EACf,OAAA,EAAS,4BAA4B;AAAA;;;AAPW;AAMlD;;;UAUiB,qCAAA;EACf,qBAAA,EAAuB,wCAAA;EACvB,OAAA,EAAS,2BAAA;EACT,IAAA,EAAM,wBAAA;AAAA;;;;;;;UASS,qCAAA;EACf,aAAA,EAAe,gCAAA;EACf,wBAAA,EAA0B,2CAAA;EAC1B,kBAAA,EAAoB,qCAAA;AAAA;;AAZU;AAShC;;;KAWY,sCAAA,WACA,kCAAA,GACR,kCAAA,IACA,2BAAA,GAA8B,qCAAA,CAAsC,CAAA;;;;;KAM5D,sCAAA,WACA,kCAAA,GACR,kCAAA,IACA,2BAAA,GAA8B,qCAAA,CAAsC,CAAA"}