squarefi-bff-api-module 1.36.55 → 1.36.56
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.
|
@@ -10760,6 +10760,126 @@ export interface paths {
|
|
|
10760
10760
|
patch?: never;
|
|
10761
10761
|
trace?: never;
|
|
10762
10762
|
};
|
|
10763
|
+
"/frontend/wallets/active": {
|
|
10764
|
+
parameters: {
|
|
10765
|
+
query?: never;
|
|
10766
|
+
header?: never;
|
|
10767
|
+
path?: never;
|
|
10768
|
+
cookie?: never;
|
|
10769
|
+
};
|
|
10770
|
+
/**
|
|
10771
|
+
* Active wallet of the caller
|
|
10772
|
+
* @description The wallet the app should open for the authenticated user.
|
|
10773
|
+
*
|
|
10774
|
+
* Resolution order:
|
|
10775
|
+
* 1. the wallet the user picked in Settings — the membership flagged
|
|
10776
|
+
* `wallets_users.is_selected`, while it is still active and the
|
|
10777
|
+
* wallet is not deleted;
|
|
10778
|
+
* 2. otherwise the default kept for users who never picked one — the
|
|
10779
|
+
* `is_main` wallet, else the oldest one.
|
|
10780
|
+
*
|
|
10781
|
+
* The selection cannot outlive the access it rides on: the flag sits on
|
|
10782
|
+
* the membership row, so revoking membership drops it. A deleted wallet
|
|
10783
|
+
* or a deactivated membership falls back to the default.
|
|
10784
|
+
*
|
|
10785
|
+
* **Authentication**: Bearer token with x-tenant-id header required
|
|
10786
|
+
*
|
|
10787
|
+
*/
|
|
10788
|
+
get: {
|
|
10789
|
+
parameters: {
|
|
10790
|
+
query?: never;
|
|
10791
|
+
header?: never;
|
|
10792
|
+
path?: never;
|
|
10793
|
+
cookie?: never;
|
|
10794
|
+
};
|
|
10795
|
+
requestBody?: never;
|
|
10796
|
+
responses: {
|
|
10797
|
+
/** @description Resolved active wallet id (`null` when the user reaches no wallet). */
|
|
10798
|
+
200: {
|
|
10799
|
+
headers: {
|
|
10800
|
+
[name: string]: unknown;
|
|
10801
|
+
};
|
|
10802
|
+
content: {
|
|
10803
|
+
"application/json": {
|
|
10804
|
+
/** @example true */
|
|
10805
|
+
success?: boolean;
|
|
10806
|
+
data?: {
|
|
10807
|
+
/** Format: uuid */
|
|
10808
|
+
wallet_id?: string | null;
|
|
10809
|
+
};
|
|
10810
|
+
};
|
|
10811
|
+
};
|
|
10812
|
+
};
|
|
10813
|
+
401: components["responses"]["UnauthorizedError"];
|
|
10814
|
+
};
|
|
10815
|
+
};
|
|
10816
|
+
/**
|
|
10817
|
+
* Select the active wallet
|
|
10818
|
+
* @description Stores the caller's active-wallet choice on their own `wallets_users`
|
|
10819
|
+
* row (`is_selected`), so it follows the account instead of the device.
|
|
10820
|
+
* At most one such row exists per user — the DB enforces it.
|
|
10821
|
+
*
|
|
10822
|
+
* The choice is per user, not per wallet: selecting a wallet shared with
|
|
10823
|
+
* the caller changes nothing for its owner or for the other members.
|
|
10824
|
+
* Any wallet the caller is an **active member** of may be selected —
|
|
10825
|
+
* ownership is not required.
|
|
10826
|
+
*
|
|
10827
|
+
* **Authentication**: Bearer token with x-tenant-id header required
|
|
10828
|
+
*
|
|
10829
|
+
*/
|
|
10830
|
+
put: {
|
|
10831
|
+
parameters: {
|
|
10832
|
+
query?: never;
|
|
10833
|
+
header?: never;
|
|
10834
|
+
path?: never;
|
|
10835
|
+
cookie?: never;
|
|
10836
|
+
};
|
|
10837
|
+
requestBody: {
|
|
10838
|
+
content: {
|
|
10839
|
+
"application/json": {
|
|
10840
|
+
/** Format: uuid */
|
|
10841
|
+
wallet_id: string;
|
|
10842
|
+
};
|
|
10843
|
+
};
|
|
10844
|
+
};
|
|
10845
|
+
responses: {
|
|
10846
|
+
/** @description Selection stored. */
|
|
10847
|
+
200: {
|
|
10848
|
+
headers: {
|
|
10849
|
+
[name: string]: unknown;
|
|
10850
|
+
};
|
|
10851
|
+
content: {
|
|
10852
|
+
"application/json": {
|
|
10853
|
+
/** @example true */
|
|
10854
|
+
success?: boolean;
|
|
10855
|
+
/** @example Active wallet updated successfully */
|
|
10856
|
+
message?: string;
|
|
10857
|
+
data?: {
|
|
10858
|
+
/** Format: uuid */
|
|
10859
|
+
wallet_id?: string;
|
|
10860
|
+
};
|
|
10861
|
+
};
|
|
10862
|
+
};
|
|
10863
|
+
};
|
|
10864
|
+
/** @description wallet_id missing or blank */
|
|
10865
|
+
400: {
|
|
10866
|
+
headers: {
|
|
10867
|
+
[name: string]: unknown;
|
|
10868
|
+
};
|
|
10869
|
+
content?: never;
|
|
10870
|
+
};
|
|
10871
|
+
401: components["responses"]["UnauthorizedError"];
|
|
10872
|
+
403: components["responses"]["ForbiddenError"];
|
|
10873
|
+
404: components["responses"]["NotFoundError"];
|
|
10874
|
+
};
|
|
10875
|
+
};
|
|
10876
|
+
post?: never;
|
|
10877
|
+
delete?: never;
|
|
10878
|
+
options?: never;
|
|
10879
|
+
head?: never;
|
|
10880
|
+
patch?: never;
|
|
10881
|
+
trace?: never;
|
|
10882
|
+
};
|
|
10763
10883
|
"/frontend/wallets/accept-invite": {
|
|
10764
10884
|
parameters: {
|
|
10765
10885
|
query?: never;
|
|
@@ -7528,60 +7528,6 @@ export interface components {
|
|
|
7528
7528
|
mon_min_usd?: number;
|
|
7529
7529
|
} | null;
|
|
7530
7530
|
};
|
|
7531
|
-
AuthResponse: {
|
|
7532
|
-
/** @description JWT access token */
|
|
7533
|
-
access_token?: string;
|
|
7534
|
-
/**
|
|
7535
|
-
* @description Token type (bearer)
|
|
7536
|
-
* @enum {string}
|
|
7537
|
-
*/
|
|
7538
|
-
token_type?: "bearer";
|
|
7539
|
-
/** @description Seconds until token expiration */
|
|
7540
|
-
expires_in?: number;
|
|
7541
|
-
/** @description Token expiration timestamp */
|
|
7542
|
-
expires_at?: number;
|
|
7543
|
-
/** @description Refresh token for obtaining new access token */
|
|
7544
|
-
refresh_token?: string;
|
|
7545
|
-
user?: components["schemas"]["User"];
|
|
7546
|
-
};
|
|
7547
|
-
User: {
|
|
7548
|
-
/** @description User's unique identifier */
|
|
7549
|
-
id?: string;
|
|
7550
|
-
/** @description Audience for the token */
|
|
7551
|
-
aud?: string;
|
|
7552
|
-
/** @description User's role */
|
|
7553
|
-
role?: string;
|
|
7554
|
-
/** @description User's email address */
|
|
7555
|
-
email?: string;
|
|
7556
|
-
/**
|
|
7557
|
-
* Format: date-time
|
|
7558
|
-
* @description When email was confirmed
|
|
7559
|
-
*/
|
|
7560
|
-
email_confirmed_at?: string;
|
|
7561
|
-
/** @description User's phone number */
|
|
7562
|
-
phone?: string;
|
|
7563
|
-
/**
|
|
7564
|
-
* Format: date-time
|
|
7565
|
-
* @description When user was confirmed
|
|
7566
|
-
*/
|
|
7567
|
-
confirmed_at?: string;
|
|
7568
|
-
/**
|
|
7569
|
-
* Format: date-time
|
|
7570
|
-
* @description When recovery email was sent
|
|
7571
|
-
*/
|
|
7572
|
-
recovery_sent_at?: string;
|
|
7573
|
-
/**
|
|
7574
|
-
* Format: date-time
|
|
7575
|
-
* @description Last sign in timestamp
|
|
7576
|
-
*/
|
|
7577
|
-
last_sign_in_at?: string;
|
|
7578
|
-
identities?: Record<string, never>[];
|
|
7579
|
-
/** Format: date-time */
|
|
7580
|
-
created_at?: string;
|
|
7581
|
-
/** Format: date-time */
|
|
7582
|
-
updated_at?: string;
|
|
7583
|
-
is_anonymous?: boolean;
|
|
7584
|
-
};
|
|
7585
7531
|
SubAccount: {
|
|
7586
7532
|
/**
|
|
7587
7533
|
* @description Unique identifier for the sub-account
|
|
@@ -8365,6 +8311,7 @@ export interface components {
|
|
|
8365
8311
|
[key: string]: unknown;
|
|
8366
8312
|
};
|
|
8367
8313
|
};
|
|
8314
|
+
User: unknown;
|
|
8368
8315
|
Wallet: unknown;
|
|
8369
8316
|
WalletDetailed: unknown;
|
|
8370
8317
|
CryptoAddress: unknown;
|