squarefi-bff-api-module 1.36.6 → 1.36.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/api/counterparties.d.ts +9 -8
- package/dist/api/counterparties.js +72 -13
- package/dist/api/types/autogen/apiV1External.types.d.ts +45 -13
- package/dist/api/types/autogen/apiV1Frontend.types.d.ts +608 -32
- package/dist/api/types/autogen/apiV1Legacy.types.d.ts +1 -1
- package/dist/api/types/autogen/apiV1Tenant.types.d.ts +44 -8
- package/dist/api/types/types.d.ts +72 -67
- package/dist/constants.d.ts +2 -1
- package/dist/constants.js +2 -0
- package/package.json +1 -1
|
@@ -8668,7 +8668,7 @@ export interface components {
|
|
|
8668
8668
|
* @description Payment method associated with this order type
|
|
8669
8669
|
* @enum {string|null}
|
|
8670
8670
|
*/
|
|
8671
|
-
payment_method?: "
|
|
8671
|
+
payment_method?: "FEDWIRE" | "ACH" | "RTP" | "SWIFT" | "SEPA" | "CHAPS" | "FPS" | "CRYPTO_EXTERNAL" | "CRYPTO_INTERNAL" | null;
|
|
8672
8672
|
/**
|
|
8673
8673
|
* Format: uuid
|
|
8674
8674
|
* @description Associated KYC rail configuration ID
|
|
@@ -581,6 +581,9 @@ export interface paths {
|
|
|
581
581
|
* **Crypto types** (CRYPTO_EXTERNAL, CRYPTO_INTERNAL):
|
|
582
582
|
* crypto_data: { address, currency_id, memo }
|
|
583
583
|
*
|
|
584
|
+
* **Internal type** (INTERNAL):
|
|
585
|
+
* internal_data: { wallet_id, description? } — receiver wallet on the same platform
|
|
586
|
+
*
|
|
584
587
|
*/
|
|
585
588
|
post: {
|
|
586
589
|
parameters: {
|
|
@@ -600,7 +603,7 @@ export interface paths {
|
|
|
600
603
|
/** Format: uuid */
|
|
601
604
|
counterparty_account_id: string;
|
|
602
605
|
/** @enum {string} */
|
|
603
|
-
type: "ACH" | "SWIFT" | "SEPA" | "CRYPTO_EXTERNAL" | "CRYPTO_INTERNAL" | "CHAPS" | "FPS" | "FEDWIRE";
|
|
606
|
+
type: "ACH" | "SWIFT" | "SEPA" | "CRYPTO_EXTERNAL" | "CRYPTO_INTERNAL" | "CHAPS" | "FPS" | "FEDWIRE" | "INTERNAL";
|
|
604
607
|
nickname?: string;
|
|
605
608
|
banking_data?: {
|
|
606
609
|
account_number?: string;
|
|
@@ -626,6 +629,16 @@ export interface paths {
|
|
|
626
629
|
currency_id?: string;
|
|
627
630
|
memo?: string;
|
|
628
631
|
};
|
|
632
|
+
/** @description Required for type INTERNAL — points at the receiver wallet on the same platform. */
|
|
633
|
+
internal_data?: {
|
|
634
|
+
/**
|
|
635
|
+
* Format: uuid
|
|
636
|
+
* @description Target (receiver) wallet uuid on the same platform.
|
|
637
|
+
*/
|
|
638
|
+
wallet_id: string;
|
|
639
|
+
/** @description Optional, reserved for future use. */
|
|
640
|
+
description?: string;
|
|
641
|
+
};
|
|
629
642
|
};
|
|
630
643
|
};
|
|
631
644
|
};
|
|
@@ -2354,8 +2367,11 @@ export interface paths {
|
|
|
2354
2367
|
"application/json": {
|
|
2355
2368
|
/** Format: uuid */
|
|
2356
2369
|
from_currency_id: string;
|
|
2357
|
-
/**
|
|
2358
|
-
|
|
2370
|
+
/**
|
|
2371
|
+
* Format: uuid
|
|
2372
|
+
* @description Counterparty destination of type INTERNAL (points at the receiver wallet).
|
|
2373
|
+
*/
|
|
2374
|
+
counterparty_destination_id: string;
|
|
2359
2375
|
amount: number;
|
|
2360
2376
|
request_id: string;
|
|
2361
2377
|
documents?: Record<string, never>[];
|
|
@@ -5905,7 +5921,10 @@ export interface paths {
|
|
|
5905
5921
|
query: {
|
|
5906
5922
|
wallet_id: string;
|
|
5907
5923
|
program_id?: string;
|
|
5908
|
-
|
|
5924
|
+
/** @description Filter cards by status.
|
|
5925
|
+
* Accepts a single value or a comma-separated list, e.g. `status=ACTIVE,CANCELED`.
|
|
5926
|
+
* */
|
|
5927
|
+
status?: ("ACTIVE" | "INACTIVE" | "SUSPENDED" | "CANCELED")[];
|
|
5909
5928
|
sub_account_type?: "balance" | "prepaid";
|
|
5910
5929
|
offset?: number;
|
|
5911
5930
|
limit?: number;
|
|
@@ -7523,7 +7542,7 @@ export interface components {
|
|
|
7523
7542
|
id?: string;
|
|
7524
7543
|
account_number?: string | null;
|
|
7525
7544
|
routing_number?: string | null;
|
|
7526
|
-
bank_name
|
|
7545
|
+
bank_name: string | null;
|
|
7527
7546
|
swift_bic?: string | null;
|
|
7528
7547
|
iban?: string | null;
|
|
7529
7548
|
/** @description Sort code (6 digits, UK banking) */
|
|
@@ -7539,15 +7558,31 @@ export interface components {
|
|
|
7539
7558
|
street2?: string | null;
|
|
7540
7559
|
state_id?: number | null;
|
|
7541
7560
|
} | null;
|
|
7561
|
+
/** Format: date-time */
|
|
7562
|
+
created_at: string;
|
|
7542
7563
|
} | null;
|
|
7543
7564
|
CryptoData: {
|
|
7544
7565
|
/** Format: uuid */
|
|
7545
7566
|
id?: string;
|
|
7546
|
-
address
|
|
7567
|
+
address: string;
|
|
7547
7568
|
/** Format: uuid */
|
|
7548
7569
|
currency_id?: string;
|
|
7549
7570
|
memo?: string | null;
|
|
7550
|
-
currency
|
|
7571
|
+
currency: components["schemas"]["CurrencyRef"];
|
|
7572
|
+
/** Format: date-time */
|
|
7573
|
+
created_at: string;
|
|
7574
|
+
} | null;
|
|
7575
|
+
/** @description Internal destination payload — the receiver wallet on the same platform. Populated when type is INTERNAL; null otherwise. */
|
|
7576
|
+
CounterpartyInternalData: {
|
|
7577
|
+
/**
|
|
7578
|
+
* Format: uuid
|
|
7579
|
+
* @description Target (receiver) wallet uuid
|
|
7580
|
+
*/
|
|
7581
|
+
wallet_id: string;
|
|
7582
|
+
/** @description Optional, reserved for future use */
|
|
7583
|
+
description?: string | null;
|
|
7584
|
+
/** Format: date-time */
|
|
7585
|
+
created_at: string;
|
|
7551
7586
|
} | null;
|
|
7552
7587
|
CounterpartyDestination: {
|
|
7553
7588
|
/** Format: uuid */
|
|
@@ -7555,7 +7590,7 @@ export interface components {
|
|
|
7555
7590
|
/** Format: uuid */
|
|
7556
7591
|
counterparty_account_id?: string;
|
|
7557
7592
|
/** @enum {string} */
|
|
7558
|
-
type?: "ACH" | "SWIFT" | "SEPA" | "CRYPTO_EXTERNAL" | "CRYPTO_INTERNAL" | "CHAPS" | "FPS" | "FEDWIRE";
|
|
7593
|
+
type?: "ACH" | "SWIFT" | "SEPA" | "CRYPTO_EXTERNAL" | "CRYPTO_INTERNAL" | "CHAPS" | "FPS" | "FEDWIRE" | "INTERNAL";
|
|
7559
7594
|
nickname?: string | null;
|
|
7560
7595
|
/** Format: date-time */
|
|
7561
7596
|
created_at?: string;
|
|
@@ -7563,6 +7598,7 @@ export interface components {
|
|
|
7563
7598
|
updated_at?: string;
|
|
7564
7599
|
banking_data?: components["schemas"]["BankingData"];
|
|
7565
7600
|
crypto_data?: components["schemas"]["CryptoData"];
|
|
7601
|
+
internal_data?: components["schemas"]["CounterpartyInternalData"];
|
|
7566
7602
|
};
|
|
7567
7603
|
AdminApiKey: {
|
|
7568
7604
|
/** Format: uuid */
|
|
@@ -368,84 +368,65 @@ export declare namespace API {
|
|
|
368
368
|
}
|
|
369
369
|
}
|
|
370
370
|
namespace Counterparties {
|
|
371
|
-
type CounterpartyType =
|
|
372
|
-
type Counterparty =
|
|
371
|
+
type CounterpartyType = componentsV1Frontend['schemas']['CounterpartyAccount']['type'];
|
|
372
|
+
type Counterparty = componentsV1Frontend['schemas']['CounterpartyAccount'];
|
|
373
|
+
type CounterpartyWithDestinations = Counterparty & {
|
|
374
|
+
destinations: Destination.List.CounterpartyDestinationListItem[];
|
|
375
|
+
};
|
|
373
376
|
namespace Destination {
|
|
374
|
-
type CounterpartyDestinationType =
|
|
377
|
+
type CounterpartyDestinationType = componentsV1Frontend['schemas']['CounterpartyDestination']['type'];
|
|
375
378
|
type BankingDestinationType = Extract<CounterpartyDestinationType, 'FEDWIRE'> | Extract<CounterpartyDestinationType, 'ACH'> | Extract<CounterpartyDestinationType, 'SWIFT'> | Extract<CounterpartyDestinationType, 'SEPA'> | Extract<CounterpartyDestinationType, 'CHAPS'> | Extract<CounterpartyDestinationType, 'FPS'>;
|
|
376
379
|
type CryptoDestinationType = Extract<CounterpartyDestinationType, 'CRYPTO_EXTERNAL'> | Extract<CounterpartyDestinationType, 'CRYPTO_INTERNAL'>;
|
|
377
|
-
type
|
|
380
|
+
type InternalDestinationType = Extract<CounterpartyDestinationType, 'INTERNAL'>;
|
|
381
|
+
type DestinationType = BankingDestinationType | CryptoDestinationType | InternalDestinationType;
|
|
378
382
|
namespace List {
|
|
379
383
|
interface DestinationListItemCommonFields {
|
|
380
384
|
id: string;
|
|
381
|
-
nickname: string;
|
|
385
|
+
nickname: string | null;
|
|
382
386
|
type: CounterpartyDestinationType;
|
|
383
387
|
created_at: string;
|
|
384
388
|
}
|
|
385
|
-
|
|
386
|
-
|
|
387
|
-
|
|
388
|
-
bank_name: string;
|
|
389
|
-
note: string;
|
|
390
|
-
swift_bic?: string;
|
|
391
|
-
sort_code?: string;
|
|
392
|
-
iban?: string;
|
|
393
|
-
address: {
|
|
394
|
-
city: string;
|
|
395
|
-
country_id: number;
|
|
396
|
-
state_id: number;
|
|
397
|
-
postcode: string;
|
|
398
|
-
street1: string;
|
|
399
|
-
street2?: string;
|
|
400
|
-
};
|
|
401
|
-
}
|
|
402
|
-
interface DestinationListItemExternalCryptoData {
|
|
403
|
-
address: string;
|
|
404
|
-
currency_id: string;
|
|
405
|
-
memo?: string;
|
|
406
|
-
}
|
|
389
|
+
type DestinationListItemExternalBankingData = NonNullable<componentsV1Frontend['schemas']['CounterpartyBankingData']>;
|
|
390
|
+
type DestinationListItemExternalCryptoData = NonNullable<componentsV1Frontend['schemas']['CounterpartyCryptoData']>;
|
|
391
|
+
type DestinationInternalData = NonNullable<componentsV1Frontend['schemas']['CounterpartyInternalData']>;
|
|
407
392
|
interface DestinationListItemWithExternalBankingData extends DestinationListItemCommonFields {
|
|
408
393
|
type: BankingDestinationType;
|
|
409
394
|
external_banking_data: DestinationListItemExternalBankingData;
|
|
410
395
|
external_crypto_data?: never;
|
|
396
|
+
internal_data?: never;
|
|
411
397
|
}
|
|
412
398
|
interface DestinationListItemWithExternalCryptoData extends DestinationListItemCommonFields {
|
|
413
399
|
type: CryptoDestinationType;
|
|
414
400
|
external_banking_data?: never;
|
|
415
401
|
external_crypto_data: DestinationListItemExternalCryptoData;
|
|
402
|
+
internal_data?: never;
|
|
416
403
|
}
|
|
417
|
-
|
|
418
|
-
|
|
404
|
+
interface DestinationListItemWithInternalData extends DestinationListItemCommonFields {
|
|
405
|
+
type: InternalDestinationType;
|
|
406
|
+
external_banking_data?: never;
|
|
407
|
+
external_crypto_data?: never;
|
|
408
|
+
internal_data: DestinationInternalData;
|
|
409
|
+
}
|
|
410
|
+
type CounterpartyDestinationListItem = DestinationListItemWithExternalBankingData | DestinationListItemWithExternalCryptoData | DestinationListItemWithInternalData;
|
|
411
|
+
type Request = pathsV1Frontend['/frontend/counterparty/destinations/wallet/{wallet_id}']['get']['parameters']['path'] & NonNullable<pathsV1Frontend['/frontend/counterparty/destinations/wallet/{wallet_id}']['get']['parameters']['query']>;
|
|
419
412
|
type Response = {
|
|
420
413
|
total: number;
|
|
421
414
|
data: CounterpartyDestinationListItem[];
|
|
422
415
|
};
|
|
423
416
|
}
|
|
424
417
|
namespace Detail {
|
|
425
|
-
type DestinationDetailItemCommonFields =
|
|
426
|
-
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
|
|
430
|
-
|
|
431
|
-
|
|
432
|
-
interface
|
|
433
|
-
|
|
434
|
-
|
|
435
|
-
|
|
436
|
-
type: BankingDestinationType;
|
|
437
|
-
external_banking_data: DestinationDetailItemExternalBankingData;
|
|
438
|
-
external_crypto_data?: never;
|
|
439
|
-
}
|
|
440
|
-
interface DestinationDetailItemWithExternalCryptoData extends DestinationDetailItemCommonFields {
|
|
441
|
-
type: CryptoDestinationType;
|
|
442
|
-
external_banking_data?: never;
|
|
443
|
-
external_crypto_data: DestinationDetailItemExternalCryptoData;
|
|
418
|
+
type DestinationDetailItemCommonFields = List.DestinationListItemCommonFields;
|
|
419
|
+
type DestinationDetailItemExternalBankingData = List.DestinationListItemExternalBankingData;
|
|
420
|
+
type DestinationDetailItemExternalCryptoData = List.DestinationListItemExternalCryptoData;
|
|
421
|
+
type DestinationDetailItemWithExternalBankingData = List.DestinationListItemWithExternalBankingData;
|
|
422
|
+
type DestinationDetailItemWithExternalCryptoData = List.DestinationListItemWithExternalCryptoData;
|
|
423
|
+
type DestinationDetailItemWithInternalData = List.DestinationListItemWithInternalData;
|
|
424
|
+
type DestinationDetailItem = List.CounterpartyDestinationListItem;
|
|
425
|
+
interface Request {
|
|
426
|
+
counterparty_destination_id: string;
|
|
427
|
+
wallet_id?: string;
|
|
428
|
+
counterparty_account_id?: string;
|
|
444
429
|
}
|
|
445
|
-
type DestinationDetailItem = DestinationDetailItemWithExternalBankingData | DestinationDetailItemWithExternalCryptoData;
|
|
446
|
-
type Request = operations['CounterpartyDestinationsController_findOne']['parameters']['path'] & {
|
|
447
|
-
wallet_id: string;
|
|
448
|
-
};
|
|
449
430
|
type Response = DestinationDetailItem;
|
|
450
431
|
}
|
|
451
432
|
namespace Create {
|
|
@@ -457,48 +438,72 @@ export declare namespace API {
|
|
|
457
438
|
swift_bic: string;
|
|
458
439
|
}
|
|
459
440
|
interface Request {
|
|
460
|
-
wallet_id
|
|
441
|
+
wallet_id?: string;
|
|
461
442
|
counterparty_account_id: string;
|
|
462
443
|
type: CounterpartyDestinationType;
|
|
463
|
-
nickname
|
|
464
|
-
external_banking_data?:
|
|
465
|
-
external_crypto_data?: Pick<
|
|
444
|
+
nickname?: string;
|
|
445
|
+
external_banking_data?: List.DestinationListItemExternalBankingData;
|
|
446
|
+
external_crypto_data?: Pick<List.DestinationListItemExternalCryptoData, 'currency_id' | 'address' | 'memo'>;
|
|
447
|
+
internal_data?: List.DestinationInternalData;
|
|
466
448
|
}
|
|
467
|
-
type Response =
|
|
449
|
+
type Response = Detail.DestinationDetailItem;
|
|
468
450
|
}
|
|
469
451
|
namespace Delete {
|
|
470
|
-
type Request =
|
|
452
|
+
type Request = NonNullable<pathsV1Frontend['/frontend/counterparty/destinations/{id}']['delete']['parameters']['query']> & {
|
|
453
|
+
counterparty_destination_id: string;
|
|
454
|
+
wallet_id?: string;
|
|
455
|
+
counterparty_account_id?: string;
|
|
456
|
+
};
|
|
457
|
+
type Response = void;
|
|
471
458
|
}
|
|
472
459
|
namespace Update {
|
|
473
|
-
type Request =
|
|
474
|
-
|
|
460
|
+
type Request = pathsV1Frontend['/frontend/counterparty/destinations/{id}']['patch']['requestBody']['content']['application/json'] & {
|
|
461
|
+
counterparty_destination_id: string;
|
|
462
|
+
wallet_id?: string;
|
|
463
|
+
counterparty_account_id?: string;
|
|
464
|
+
};
|
|
465
|
+
type Response = Detail.DestinationDetailItem;
|
|
466
|
+
}
|
|
467
|
+
namespace InternalTransfer {
|
|
468
|
+
interface Request {
|
|
469
|
+
counterparty_destination_id: string;
|
|
470
|
+
}
|
|
471
|
+
type Response = componentsV1Frontend['schemas']['InternalTransferAvailability'];
|
|
475
472
|
}
|
|
476
473
|
}
|
|
477
474
|
namespace GetById {
|
|
478
475
|
interface Request {
|
|
479
|
-
wallet_id: string;
|
|
480
476
|
counterparty_account_id: string;
|
|
477
|
+
wallet_id?: string;
|
|
481
478
|
}
|
|
482
|
-
type Response =
|
|
479
|
+
type Response = CounterpartyWithDestinations;
|
|
483
480
|
}
|
|
484
481
|
namespace List {
|
|
485
|
-
type Request =
|
|
482
|
+
type Request = pathsV1Frontend['/frontend/counterparty/accounts/wallet/{wallet_id}']['get']['parameters']['path'] & NonNullable<pathsV1Frontend['/frontend/counterparty/accounts/wallet/{wallet_id}']['get']['parameters']['query']>;
|
|
486
483
|
type Response = {
|
|
487
484
|
total: number;
|
|
488
485
|
data: Counterparty[];
|
|
489
486
|
};
|
|
490
487
|
}
|
|
491
488
|
namespace Create {
|
|
492
|
-
type Request =
|
|
489
|
+
type Request = pathsV1Frontend['/frontend/counterparty/accounts/wallet/{wallet_id}']['post']['parameters']['path'] & pathsV1Frontend['/frontend/counterparty/accounts/wallet/{wallet_id}']['post']['requestBody']['content']['application/json'];
|
|
493
490
|
type Response = Counterparty;
|
|
494
491
|
}
|
|
495
492
|
namespace Update {
|
|
496
|
-
type Request =
|
|
493
|
+
type Request = pathsV1Frontend['/frontend/counterparty/accounts/{id}']['patch']['requestBody']['content']['application/json'] & {
|
|
494
|
+
counterparty_account_id: string;
|
|
495
|
+
wallet_id?: string;
|
|
496
|
+
};
|
|
497
497
|
type Response = Counterparty;
|
|
498
498
|
}
|
|
499
499
|
namespace Delete {
|
|
500
|
-
|
|
501
|
-
|
|
500
|
+
interface Request {
|
|
501
|
+
counterparty_account_id: string;
|
|
502
|
+
wallet_id?: string;
|
|
503
|
+
}
|
|
504
|
+
type Response = {
|
|
505
|
+
message: string;
|
|
506
|
+
};
|
|
502
507
|
}
|
|
503
508
|
}
|
|
504
509
|
namespace Currencies {
|
package/dist/constants.d.ts
CHANGED
|
@@ -354,7 +354,8 @@ export declare enum CounterpartyDestinationType {
|
|
|
354
354
|
CRYPTO_EXTERNAL = "CRYPTO_EXTERNAL",
|
|
355
355
|
CRYPTO_INTERNAL = "CRYPTO_INTERNAL",
|
|
356
356
|
CHAPS = "CHAPS",
|
|
357
|
-
FPS = "FPS"
|
|
357
|
+
FPS = "FPS",
|
|
358
|
+
INTERNAL = "INTERNAL"
|
|
358
359
|
}
|
|
359
360
|
export declare const counterpartyBankingDestinationTypes: Record<API.Counterparties.Destination.BankingDestinationType, CounterpartyDestinationType>;
|
|
360
361
|
export declare const counterpartyCryptoDestinationTypes: Record<API.Counterparties.Destination.CryptoDestinationType, CounterpartyDestinationType>;
|
package/dist/constants.js
CHANGED
|
@@ -378,6 +378,8 @@ export var CounterpartyDestinationType;
|
|
|
378
378
|
CounterpartyDestinationType["CRYPTO_INTERNAL"] = "CRYPTO_INTERNAL";
|
|
379
379
|
CounterpartyDestinationType["CHAPS"] = "CHAPS";
|
|
380
380
|
CounterpartyDestinationType["FPS"] = "FPS";
|
|
381
|
+
// Перевод на кошелёк внутри платформы (фронт-модуль контрагентов).
|
|
382
|
+
CounterpartyDestinationType["INTERNAL"] = "INTERNAL";
|
|
381
383
|
})(CounterpartyDestinationType || (CounterpartyDestinationType = {}));
|
|
382
384
|
export const counterpartyBankingDestinationTypes = {
|
|
383
385
|
FEDWIRE: CounterpartyDestinationType.FEDWIRE,
|