squarefi-bff-api-module 1.36.36 → 1.36.38
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/types/autogen/apiV1External.types.d.ts +110 -14
- package/dist/api/types/autogen/apiV1Frontend.types.d.ts +859 -192
- package/dist/api/types/autogen/apiV1Legacy.types.d.ts +17 -118
- package/dist/api/types/autogen/apiV1Tenant.types.d.ts +56 -74
- package/dist/api/types/autogen/apiV2.types.d.ts +6 -0
- package/package.json +1 -1
|
@@ -406,7 +406,20 @@ export interface paths {
|
|
|
406
406
|
* "transaction_currency": "PLN",
|
|
407
407
|
* "vendor_transaction_id": "A2012189003898834946",
|
|
408
408
|
* "timestamp": "2026-01-16T23:43:37.851",
|
|
409
|
-
* "otp": null
|
|
409
|
+
* "otp": null,
|
|
410
|
+
* "cardholder": {
|
|
411
|
+
* "id": "uuid",
|
|
412
|
+
* "first_name": "Paul",
|
|
413
|
+
* "last_name": "Kashuba",
|
|
414
|
+
* "phone": "+15551234567",
|
|
415
|
+
* "email": "p.kashuba@gmail.com",
|
|
416
|
+
* "kyc_level": "basic"
|
|
417
|
+
* },
|
|
418
|
+
* "sub_account": {
|
|
419
|
+
* "id": "uuid",
|
|
420
|
+
* "balance": 181.25,
|
|
421
|
+
* "currency": "USD"
|
|
422
|
+
* }
|
|
410
423
|
* },
|
|
411
424
|
* "created_at": "2026-01-16T15:43:40.168+00"
|
|
412
425
|
* }
|
|
@@ -4175,11 +4188,12 @@ export interface paths {
|
|
|
4175
4188
|
*/
|
|
4176
4189
|
cardholder_relationship?: "EMPLOYEE" | "CONTRACTOR";
|
|
4177
4190
|
/**
|
|
4178
|
-
* @description Identity document type (KYC vendors)
|
|
4191
|
+
* @description Identity document type (KYC vendors). Which values are accepted depends on the country that issued the document — read cardholder_requirements.country_rules[gov_id_country].gov_id_types instead of hardcoding the list (id_card_cn is the mainland China resident ID, id_card_hk the HKID).
|
|
4192
|
+
*
|
|
4179
4193
|
* @enum {string}
|
|
4180
4194
|
*/
|
|
4181
|
-
gov_id_type?: "passport" | "id_card" | "driving_license";
|
|
4182
|
-
/** @description Identity document number */
|
|
4195
|
+
gov_id_type?: "passport" | "id_card" | "driving_license" | "residence_permit_eu" | "residence_permit_ae" | "id_card_cn" | "id_card_hk";
|
|
4196
|
+
/** @description Identity document number (passport / driving licence / national ID). */
|
|
4183
4197
|
gov_id_number?: string;
|
|
4184
4198
|
/**
|
|
4185
4199
|
* @description Issuing country of the identity document (2-3 letter code)
|
|
@@ -4193,9 +4207,16 @@ export interface paths {
|
|
|
4193
4207
|
gov_id_issuance_date?: string;
|
|
4194
4208
|
/**
|
|
4195
4209
|
* Format: date
|
|
4196
|
-
* @description Identity document expiry date (YYYY-MM-DD)
|
|
4210
|
+
* @description Identity document expiry date (YYYY-MM-DD). Required by the vendor review even for a document issued for life (an Indonesian KTP, "SEUMUR HIDUP"), which has no expiry printed on it — send the issuance date plus 100 years.
|
|
4211
|
+
*
|
|
4197
4212
|
*/
|
|
4198
4213
|
gov_id_expiration_date?: string;
|
|
4214
|
+
/**
|
|
4215
|
+
* @description Tax identifier of the cardholder, separate from the document number. Required by Interlace CONSUMER programs when nationality is USA, where it must be a valid SSN (9 digits or XXX-XX-XXXX).
|
|
4216
|
+
*
|
|
4217
|
+
* @example 123-45-6789
|
|
4218
|
+
*/
|
|
4219
|
+
tax_identification_number?: string;
|
|
4199
4220
|
/** @description Cardholder's address */
|
|
4200
4221
|
address?: {
|
|
4201
4222
|
/**
|
|
@@ -4210,7 +4231,11 @@ export interface paths {
|
|
|
4210
4231
|
line2?: string;
|
|
4211
4232
|
/** @example New York */
|
|
4212
4233
|
city?: string;
|
|
4213
|
-
/**
|
|
4234
|
+
/**
|
|
4235
|
+
* @description Subdivision. Required for a US or Canadian address and must be the two-letter code (AL, ON); optional elsewhere.
|
|
4236
|
+
*
|
|
4237
|
+
* @example NY
|
|
4238
|
+
*/
|
|
4214
4239
|
state?: string;
|
|
4215
4240
|
/** @example 10001 */
|
|
4216
4241
|
postal_code?: string;
|
|
@@ -4404,110 +4429,7 @@ export interface paths {
|
|
|
4404
4429
|
};
|
|
4405
4430
|
options?: never;
|
|
4406
4431
|
head?: never;
|
|
4407
|
-
|
|
4408
|
-
* Update cardholder
|
|
4409
|
-
* @description Updates cardholder information.
|
|
4410
|
-
*
|
|
4411
|
-
* **Authentication**: Bearer token with x-tenant-id header required
|
|
4412
|
-
*
|
|
4413
|
-
* **Access Control**: Cardholder must belong to the user's wallet
|
|
4414
|
-
*
|
|
4415
|
-
*/
|
|
4416
|
-
patch: {
|
|
4417
|
-
parameters: {
|
|
4418
|
-
query?: {
|
|
4419
|
-
/** @description Wallet ID for access validation */
|
|
4420
|
-
wallet_id?: string;
|
|
4421
|
-
};
|
|
4422
|
-
header?: never;
|
|
4423
|
-
path: {
|
|
4424
|
-
/** @description The ID of the cardholder to update */
|
|
4425
|
-
cardholder_id: string;
|
|
4426
|
-
};
|
|
4427
|
-
cookie?: never;
|
|
4428
|
-
};
|
|
4429
|
-
requestBody: {
|
|
4430
|
-
content: {
|
|
4431
|
-
"application/json": {
|
|
4432
|
-
/** @description Cardholder's first name */
|
|
4433
|
-
first_name?: string;
|
|
4434
|
-
/** @description Cardholder's last name */
|
|
4435
|
-
last_name?: string;
|
|
4436
|
-
/**
|
|
4437
|
-
* Format: email
|
|
4438
|
-
* @description Cardholder's email address
|
|
4439
|
-
*/
|
|
4440
|
-
email?: string;
|
|
4441
|
-
/** @description Cardholder's phone number */
|
|
4442
|
-
phone?: string;
|
|
4443
|
-
/**
|
|
4444
|
-
* @description Cardholder's nationality as ISO 3166-1 alpha-3 country code
|
|
4445
|
-
* @example USA
|
|
4446
|
-
*/
|
|
4447
|
-
nationality?: string;
|
|
4448
|
-
/** @enum {string} */
|
|
4449
|
-
gender?: "M" | "F";
|
|
4450
|
-
/** @enum {string} */
|
|
4451
|
-
cardholder_relationship?: "EMPLOYEE" | "CONTRACTOR";
|
|
4452
|
-
/** @enum {string} */
|
|
4453
|
-
gov_id_type?: "passport" | "id_card" | "driving_license";
|
|
4454
|
-
gov_id_number?: string;
|
|
4455
|
-
/** @description 2-3 letter uppercase country code */
|
|
4456
|
-
gov_id_country?: string;
|
|
4457
|
-
/** Format: date */
|
|
4458
|
-
gov_id_issuance_date?: string;
|
|
4459
|
-
/** Format: date */
|
|
4460
|
-
gov_id_expiration_date?: string;
|
|
4461
|
-
address?: {
|
|
4462
|
-
line1?: string;
|
|
4463
|
-
line2?: string;
|
|
4464
|
-
city?: string;
|
|
4465
|
-
state?: string;
|
|
4466
|
-
postal_code?: string;
|
|
4467
|
-
country?: string;
|
|
4468
|
-
};
|
|
4469
|
-
};
|
|
4470
|
-
};
|
|
4471
|
-
};
|
|
4472
|
-
responses: {
|
|
4473
|
-
/** @description Cardholder updated successfully */
|
|
4474
|
-
200: {
|
|
4475
|
-
headers: {
|
|
4476
|
-
[name: string]: unknown;
|
|
4477
|
-
};
|
|
4478
|
-
content: {
|
|
4479
|
-
"application/json": {
|
|
4480
|
-
/** @example true */
|
|
4481
|
-
success?: boolean;
|
|
4482
|
-
data?: components["schemas"]["IssuingCardholder"];
|
|
4483
|
-
/** @example Cardholder updated successfully */
|
|
4484
|
-
message?: string;
|
|
4485
|
-
};
|
|
4486
|
-
};
|
|
4487
|
-
};
|
|
4488
|
-
/** @description Invalid request parameters */
|
|
4489
|
-
400: {
|
|
4490
|
-
headers: {
|
|
4491
|
-
[name: string]: unknown;
|
|
4492
|
-
};
|
|
4493
|
-
content?: never;
|
|
4494
|
-
};
|
|
4495
|
-
/** @description Access denied to this cardholder */
|
|
4496
|
-
403: {
|
|
4497
|
-
headers: {
|
|
4498
|
-
[name: string]: unknown;
|
|
4499
|
-
};
|
|
4500
|
-
content?: never;
|
|
4501
|
-
};
|
|
4502
|
-
/** @description Cardholder not found */
|
|
4503
|
-
404: {
|
|
4504
|
-
headers: {
|
|
4505
|
-
[name: string]: unknown;
|
|
4506
|
-
};
|
|
4507
|
-
content?: never;
|
|
4508
|
-
};
|
|
4509
|
-
};
|
|
4510
|
-
};
|
|
4432
|
+
patch?: never;
|
|
4511
4433
|
trace?: never;
|
|
4512
4434
|
};
|
|
4513
4435
|
"/frontend/issuing/cardholders/{cardholder_id}/submit": {
|
|
@@ -4532,8 +4454,17 @@ export interface paths {
|
|
|
4532
4454
|
* **Retryable**: a failed submit leaves the draft untouched. Nothing is rolled back,
|
|
4533
4455
|
* and the same endpoint can be called again once the dossier is complete.
|
|
4534
4456
|
*
|
|
4535
|
-
* **
|
|
4536
|
-
*
|
|
4457
|
+
* **After a rejection**: a cardholder whose identity review came back
|
|
4458
|
+
* `review_status: REJECTED` or `REQUEST` (read it, with `reject_reason`, from
|
|
4459
|
+
* `GET /frontend/issuing/cardholders/{cardholder_id}`) may be submitted again. Fix what
|
|
4460
|
+
* the vendor named — `PATCH` the field, or upload a better photo and re-attach it via
|
|
4461
|
+
* `POST /cardholders/{cardholder_id}/documents`, which replaces the document of that
|
|
4462
|
+
* type — then call this endpoint once more. The review restarts on the vendor account
|
|
4463
|
+
* the person already has: the same document cannot be registered twice at the vendor, so
|
|
4464
|
+
* a fresh cardholder is NOT the way to retry.
|
|
4465
|
+
*
|
|
4466
|
+
* **Idempotency**: while a review is running, or once the cardholder is live, another
|
|
4467
|
+
* submit returns `409 CARDHOLDER_NOT_DRAFT` rather than spending a second review.
|
|
4537
4468
|
*
|
|
4538
4469
|
* **Authentication**: Bearer token with x-tenant-id header required
|
|
4539
4470
|
*
|
|
@@ -4592,7 +4523,7 @@ export interface paths {
|
|
|
4592
4523
|
};
|
|
4593
4524
|
content?: never;
|
|
4594
4525
|
};
|
|
4595
|
-
/** @description Cardholder is
|
|
4526
|
+
/** @description Cardholder is live at the vendor, or its review is still running */
|
|
4596
4527
|
409: {
|
|
4597
4528
|
headers: {
|
|
4598
4529
|
[name: string]: unknown;
|
|
@@ -4628,8 +4559,8 @@ export interface paths {
|
|
|
4628
4559
|
* @description Uploads KYC files against a wallet via `multipart/form-data`, with no
|
|
4629
4560
|
* cardholder involved — the upload step of the create flow runs before the
|
|
4630
4561
|
* cardholder exists. The form field name is the document type (`selfie`,
|
|
4631
|
-
* `gov_id_front`, `gov_id_back`); one file per type, 5MB max each,
|
|
4632
|
-
* png/jpeg
|
|
4562
|
+
* `gov_id_front`, `gov_id_back`); one file per type, 5MB max each, photos
|
|
4563
|
+
* only (png/jpeg).
|
|
4633
4564
|
*
|
|
4634
4565
|
* Send one file per request so the UI can show progress per file and retry
|
|
4635
4566
|
* a single file. The response returns an `id` per file; pass those ids to
|
|
@@ -4640,6 +4571,14 @@ export interface paths {
|
|
|
4640
4571
|
* boundary itself, and the file has to be appended as a `File`/`Blob`, not
|
|
4641
4572
|
* as a name or a base64 string.
|
|
4642
4573
|
*
|
|
4574
|
+
* **Send the file the camera produced, unchanged.** Do not crop, rotate,
|
|
4575
|
+
* resize or re-encode it on the client: the vendor's identity review runs
|
|
4576
|
+
* a tampering check, and a re-encoded document photo can come back as
|
|
4577
|
+
* `Forgery attempt has been made.` — a verdict far worse than the poor
|
|
4578
|
+
* quality it was meant to fix. When a photo is too small or unreadable,
|
|
4579
|
+
* ask the person to retake it (card filling the frame, straight, no
|
|
4580
|
+
* glare) instead of improving the file.
|
|
4581
|
+
*
|
|
4643
4582
|
* An upload that is never attached is deleted by a cleanup sweep.
|
|
4644
4583
|
*
|
|
4645
4584
|
* **Authentication**: Bearer token with x-tenant-id header required
|
|
@@ -5864,16 +5803,383 @@ export interface paths {
|
|
|
5864
5803
|
parameters: {
|
|
5865
5804
|
query?: never;
|
|
5866
5805
|
header?: never;
|
|
5867
|
-
path: {
|
|
5868
|
-
/** @description Source wallet the batches belong to */
|
|
5869
|
-
wallet_id: components["parameters"]["MassPayoutWalletId"];
|
|
5870
|
-
id: components["parameters"]["MassPayoutId"];
|
|
5871
|
-
};
|
|
5806
|
+
path: {
|
|
5807
|
+
/** @description Source wallet the batches belong to */
|
|
5808
|
+
wallet_id: components["parameters"]["MassPayoutWalletId"];
|
|
5809
|
+
id: components["parameters"]["MassPayoutId"];
|
|
5810
|
+
};
|
|
5811
|
+
cookie?: never;
|
|
5812
|
+
};
|
|
5813
|
+
requestBody?: never;
|
|
5814
|
+
responses: {
|
|
5815
|
+
/** @description Execution started */
|
|
5816
|
+
200: {
|
|
5817
|
+
headers: {
|
|
5818
|
+
[name: string]: unknown;
|
|
5819
|
+
};
|
|
5820
|
+
content: {
|
|
5821
|
+
"application/json": {
|
|
5822
|
+
/** @example true */
|
|
5823
|
+
success?: boolean;
|
|
5824
|
+
data?: components["schemas"]["MassPayout"];
|
|
5825
|
+
};
|
|
5826
|
+
};
|
|
5827
|
+
};
|
|
5828
|
+
/** @description Second-factor verification is stale or the caller lacks permission */
|
|
5829
|
+
403: {
|
|
5830
|
+
headers: {
|
|
5831
|
+
[name: string]: unknown;
|
|
5832
|
+
};
|
|
5833
|
+
content: {
|
|
5834
|
+
"application/json": components["schemas"]["ErrorResponse"];
|
|
5835
|
+
};
|
|
5836
|
+
};
|
|
5837
|
+
/** @description Batch is not awaiting approval */
|
|
5838
|
+
409: {
|
|
5839
|
+
headers: {
|
|
5840
|
+
[name: string]: unknown;
|
|
5841
|
+
};
|
|
5842
|
+
content: {
|
|
5843
|
+
"application/json": components["schemas"]["ErrorResponse"];
|
|
5844
|
+
};
|
|
5845
|
+
};
|
|
5846
|
+
};
|
|
5847
|
+
};
|
|
5848
|
+
delete?: never;
|
|
5849
|
+
options?: never;
|
|
5850
|
+
head?: never;
|
|
5851
|
+
patch?: never;
|
|
5852
|
+
trace?: never;
|
|
5853
|
+
};
|
|
5854
|
+
"/frontend/mass-payouts/{wallet_id}/{id}/cancel": {
|
|
5855
|
+
parameters: {
|
|
5856
|
+
query?: never;
|
|
5857
|
+
header?: never;
|
|
5858
|
+
path?: never;
|
|
5859
|
+
cookie?: never;
|
|
5860
|
+
};
|
|
5861
|
+
get?: never;
|
|
5862
|
+
put?: never;
|
|
5863
|
+
/**
|
|
5864
|
+
* Cancel a mass payout
|
|
5865
|
+
* @description Allowed from DRAFT and PENDING_APPROVAL. A PROCESSING batch cannot be canceled — payouts are already executing.
|
|
5866
|
+
*/
|
|
5867
|
+
post: {
|
|
5868
|
+
parameters: {
|
|
5869
|
+
query?: never;
|
|
5870
|
+
header?: never;
|
|
5871
|
+
path: {
|
|
5872
|
+
/** @description Source wallet the batches belong to */
|
|
5873
|
+
wallet_id: components["parameters"]["MassPayoutWalletId"];
|
|
5874
|
+
id: components["parameters"]["MassPayoutId"];
|
|
5875
|
+
};
|
|
5876
|
+
cookie?: never;
|
|
5877
|
+
};
|
|
5878
|
+
requestBody?: never;
|
|
5879
|
+
responses: {
|
|
5880
|
+
/** @description Batch canceled */
|
|
5881
|
+
200: {
|
|
5882
|
+
headers: {
|
|
5883
|
+
[name: string]: unknown;
|
|
5884
|
+
};
|
|
5885
|
+
content: {
|
|
5886
|
+
"application/json": {
|
|
5887
|
+
/** @example true */
|
|
5888
|
+
success?: boolean;
|
|
5889
|
+
data?: components["schemas"]["MassPayout"];
|
|
5890
|
+
};
|
|
5891
|
+
};
|
|
5892
|
+
};
|
|
5893
|
+
/** @description Batch can no longer be canceled */
|
|
5894
|
+
409: {
|
|
5895
|
+
headers: {
|
|
5896
|
+
[name: string]: unknown;
|
|
5897
|
+
};
|
|
5898
|
+
content: {
|
|
5899
|
+
"application/json": components["schemas"]["ErrorResponse"];
|
|
5900
|
+
};
|
|
5901
|
+
};
|
|
5902
|
+
};
|
|
5903
|
+
};
|
|
5904
|
+
delete?: never;
|
|
5905
|
+
options?: never;
|
|
5906
|
+
head?: never;
|
|
5907
|
+
patch?: never;
|
|
5908
|
+
trace?: never;
|
|
5909
|
+
};
|
|
5910
|
+
"/frontend/mass-payouts/{wallet_id}/{id}/report.csv": {
|
|
5911
|
+
parameters: {
|
|
5912
|
+
query?: never;
|
|
5913
|
+
header?: never;
|
|
5914
|
+
path?: never;
|
|
5915
|
+
cookie?: never;
|
|
5916
|
+
};
|
|
5917
|
+
/**
|
|
5918
|
+
* Download the mass payout report (CSV)
|
|
5919
|
+
* @description Streaming CSV: recipient, amount, item status, the linked order and its
|
|
5920
|
+
* current status, and the failure reason for every unsuccessful payout.
|
|
5921
|
+
*
|
|
5922
|
+
*/
|
|
5923
|
+
get: {
|
|
5924
|
+
parameters: {
|
|
5925
|
+
query?: never;
|
|
5926
|
+
header?: never;
|
|
5927
|
+
path: {
|
|
5928
|
+
/** @description Source wallet the batches belong to */
|
|
5929
|
+
wallet_id: components["parameters"]["MassPayoutWalletId"];
|
|
5930
|
+
id: components["parameters"]["MassPayoutId"];
|
|
5931
|
+
};
|
|
5932
|
+
cookie?: never;
|
|
5933
|
+
};
|
|
5934
|
+
requestBody?: never;
|
|
5935
|
+
responses: {
|
|
5936
|
+
/** @description CSV file */
|
|
5937
|
+
200: {
|
|
5938
|
+
headers: {
|
|
5939
|
+
[name: string]: unknown;
|
|
5940
|
+
};
|
|
5941
|
+
content: {
|
|
5942
|
+
"text/csv": string;
|
|
5943
|
+
};
|
|
5944
|
+
};
|
|
5945
|
+
/** @description Mass payout not found */
|
|
5946
|
+
404: {
|
|
5947
|
+
headers: {
|
|
5948
|
+
[name: string]: unknown;
|
|
5949
|
+
};
|
|
5950
|
+
content: {
|
|
5951
|
+
"application/json": components["schemas"]["ErrorResponse"];
|
|
5952
|
+
};
|
|
5953
|
+
};
|
|
5954
|
+
};
|
|
5955
|
+
};
|
|
5956
|
+
put?: never;
|
|
5957
|
+
post?: never;
|
|
5958
|
+
delete?: never;
|
|
5959
|
+
options?: never;
|
|
5960
|
+
head?: never;
|
|
5961
|
+
patch?: never;
|
|
5962
|
+
trace?: never;
|
|
5963
|
+
};
|
|
5964
|
+
"/frontend/notification-preferences": {
|
|
5965
|
+
parameters: {
|
|
5966
|
+
query?: never;
|
|
5967
|
+
header?: never;
|
|
5968
|
+
path?: never;
|
|
5969
|
+
cookie?: never;
|
|
5970
|
+
};
|
|
5971
|
+
/**
|
|
5972
|
+
* Effective delivery-channel preferences
|
|
5973
|
+
* @description Full channel list with defaults applied. `IN_APP` is always enabled (cannot be disabled).
|
|
5974
|
+
*/
|
|
5975
|
+
get: {
|
|
5976
|
+
parameters: {
|
|
5977
|
+
query?: never;
|
|
5978
|
+
header?: never;
|
|
5979
|
+
path?: never;
|
|
5980
|
+
cookie?: never;
|
|
5981
|
+
};
|
|
5982
|
+
requestBody?: never;
|
|
5983
|
+
responses: {
|
|
5984
|
+
/** @description Effective preference per channel. */
|
|
5985
|
+
200: {
|
|
5986
|
+
headers: {
|
|
5987
|
+
[name: string]: unknown;
|
|
5988
|
+
};
|
|
5989
|
+
content: {
|
|
5990
|
+
"application/json": {
|
|
5991
|
+
/** @example true */
|
|
5992
|
+
success?: boolean;
|
|
5993
|
+
data?: {
|
|
5994
|
+
preferences?: components["schemas"]["NotificationPreference"][];
|
|
5995
|
+
};
|
|
5996
|
+
};
|
|
5997
|
+
};
|
|
5998
|
+
};
|
|
5999
|
+
401: components["responses"]["UnauthorizedError"];
|
|
6000
|
+
};
|
|
6001
|
+
};
|
|
6002
|
+
/**
|
|
6003
|
+
* Update delivery-channel preferences
|
|
6004
|
+
* @description Bulk upsert. Disabling `IN_APP` is rejected with 400 (`INBOX_CHANNEL_LOCKED`). Changes apply from the next delivery.
|
|
6005
|
+
*/
|
|
6006
|
+
put: {
|
|
6007
|
+
parameters: {
|
|
6008
|
+
query?: never;
|
|
6009
|
+
header?: never;
|
|
6010
|
+
path?: never;
|
|
6011
|
+
cookie?: never;
|
|
6012
|
+
};
|
|
6013
|
+
requestBody: {
|
|
6014
|
+
content: {
|
|
6015
|
+
"application/json": {
|
|
6016
|
+
preferences: components["schemas"]["NotificationPreference"][];
|
|
6017
|
+
};
|
|
6018
|
+
};
|
|
6019
|
+
};
|
|
6020
|
+
responses: {
|
|
6021
|
+
/** @description Effective preference list after the update. */
|
|
6022
|
+
200: {
|
|
6023
|
+
headers: {
|
|
6024
|
+
[name: string]: unknown;
|
|
6025
|
+
};
|
|
6026
|
+
content: {
|
|
6027
|
+
"application/json": {
|
|
6028
|
+
/** @example true */
|
|
6029
|
+
success?: boolean;
|
|
6030
|
+
data?: {
|
|
6031
|
+
preferences?: components["schemas"]["NotificationPreference"][];
|
|
6032
|
+
};
|
|
6033
|
+
};
|
|
6034
|
+
};
|
|
6035
|
+
};
|
|
6036
|
+
/** @description Invalid body (`VALIDATION_ERROR`) or an attempt to disable `IN_APP` (`INBOX_CHANNEL_LOCKED`). */
|
|
6037
|
+
400: {
|
|
6038
|
+
headers: {
|
|
6039
|
+
[name: string]: unknown;
|
|
6040
|
+
};
|
|
6041
|
+
content?: never;
|
|
6042
|
+
};
|
|
6043
|
+
401: components["responses"]["UnauthorizedError"];
|
|
6044
|
+
};
|
|
6045
|
+
};
|
|
6046
|
+
post?: never;
|
|
6047
|
+
delete?: never;
|
|
6048
|
+
options?: never;
|
|
6049
|
+
head?: never;
|
|
6050
|
+
patch?: never;
|
|
6051
|
+
trace?: never;
|
|
6052
|
+
};
|
|
6053
|
+
"/frontend/notifications": {
|
|
6054
|
+
parameters: {
|
|
6055
|
+
query?: never;
|
|
6056
|
+
header?: never;
|
|
6057
|
+
path?: never;
|
|
6058
|
+
cookie?: never;
|
|
6059
|
+
};
|
|
6060
|
+
/** List the notification inbox (newest first, cursor pagination) */
|
|
6061
|
+
get: {
|
|
6062
|
+
parameters: {
|
|
6063
|
+
query?: {
|
|
6064
|
+
/** @description Opaque cursor from a previous page (`next_cursor`). Omit for the first page. */
|
|
6065
|
+
cursor?: string;
|
|
6066
|
+
limit?: number;
|
|
6067
|
+
unread_only?: "true" | "false";
|
|
6068
|
+
wallet_id?: string;
|
|
6069
|
+
};
|
|
6070
|
+
header?: never;
|
|
6071
|
+
path?: never;
|
|
6072
|
+
cookie?: never;
|
|
6073
|
+
};
|
|
6074
|
+
requestBody?: never;
|
|
6075
|
+
responses: {
|
|
6076
|
+
/** @description Page of notifications; `next_cursor` is null on the final page. */
|
|
6077
|
+
200: {
|
|
6078
|
+
headers: {
|
|
6079
|
+
[name: string]: unknown;
|
|
6080
|
+
};
|
|
6081
|
+
content: {
|
|
6082
|
+
"application/json": {
|
|
6083
|
+
/** @example true */
|
|
6084
|
+
success?: boolean;
|
|
6085
|
+
data?: {
|
|
6086
|
+
items?: components["schemas"]["NotificationView"][];
|
|
6087
|
+
next_cursor?: string | null;
|
|
6088
|
+
};
|
|
6089
|
+
};
|
|
6090
|
+
};
|
|
6091
|
+
};
|
|
6092
|
+
/** @description Invalid query (`VALIDATION_ERROR`) or a broken cursor (`NOTIFICATION_CURSOR_INVALID`). */
|
|
6093
|
+
400: {
|
|
6094
|
+
headers: {
|
|
6095
|
+
[name: string]: unknown;
|
|
6096
|
+
};
|
|
6097
|
+
content?: never;
|
|
6098
|
+
};
|
|
6099
|
+
401: components["responses"]["UnauthorizedError"];
|
|
6100
|
+
};
|
|
6101
|
+
};
|
|
6102
|
+
put?: never;
|
|
6103
|
+
post?: never;
|
|
6104
|
+
delete?: never;
|
|
6105
|
+
options?: never;
|
|
6106
|
+
head?: never;
|
|
6107
|
+
patch?: never;
|
|
6108
|
+
trace?: never;
|
|
6109
|
+
};
|
|
6110
|
+
"/frontend/notifications/unread-count": {
|
|
6111
|
+
parameters: {
|
|
6112
|
+
query?: never;
|
|
6113
|
+
header?: never;
|
|
6114
|
+
path?: never;
|
|
6115
|
+
cookie?: never;
|
|
6116
|
+
};
|
|
6117
|
+
/** Unread notifications count (badge) */
|
|
6118
|
+
get: {
|
|
6119
|
+
parameters: {
|
|
6120
|
+
query?: never;
|
|
6121
|
+
header?: never;
|
|
6122
|
+
path?: never;
|
|
6123
|
+
cookie?: never;
|
|
6124
|
+
};
|
|
6125
|
+
requestBody?: never;
|
|
6126
|
+
responses: {
|
|
6127
|
+
/** @description Current unread count. */
|
|
6128
|
+
200: {
|
|
6129
|
+
headers: {
|
|
6130
|
+
[name: string]: unknown;
|
|
6131
|
+
};
|
|
6132
|
+
content: {
|
|
6133
|
+
"application/json": {
|
|
6134
|
+
/** @example true */
|
|
6135
|
+
success?: boolean;
|
|
6136
|
+
data?: {
|
|
6137
|
+
/** @example 3 */
|
|
6138
|
+
count?: number;
|
|
6139
|
+
};
|
|
6140
|
+
};
|
|
6141
|
+
};
|
|
6142
|
+
};
|
|
6143
|
+
401: components["responses"]["UnauthorizedError"];
|
|
6144
|
+
};
|
|
6145
|
+
};
|
|
6146
|
+
put?: never;
|
|
6147
|
+
post?: never;
|
|
6148
|
+
delete?: never;
|
|
6149
|
+
options?: never;
|
|
6150
|
+
head?: never;
|
|
6151
|
+
patch?: never;
|
|
6152
|
+
trace?: never;
|
|
6153
|
+
};
|
|
6154
|
+
"/frontend/notifications/mark-read": {
|
|
6155
|
+
parameters: {
|
|
6156
|
+
query?: never;
|
|
6157
|
+
header?: never;
|
|
6158
|
+
path?: never;
|
|
6159
|
+
cookie?: never;
|
|
6160
|
+
};
|
|
6161
|
+
get?: never;
|
|
6162
|
+
put?: never;
|
|
6163
|
+
/**
|
|
6164
|
+
* Mark specific notifications as read
|
|
6165
|
+
* @description Idempotent — already-read ids are not counted. Other tabs/devices sync via the realtime `notifications.read` event.
|
|
6166
|
+
*/
|
|
6167
|
+
post: {
|
|
6168
|
+
parameters: {
|
|
6169
|
+
query?: never;
|
|
6170
|
+
header?: never;
|
|
6171
|
+
path?: never;
|
|
5872
6172
|
cookie?: never;
|
|
5873
6173
|
};
|
|
5874
|
-
requestBody
|
|
6174
|
+
requestBody: {
|
|
6175
|
+
content: {
|
|
6176
|
+
"application/json": {
|
|
6177
|
+
notification_ids: string[];
|
|
6178
|
+
};
|
|
6179
|
+
};
|
|
6180
|
+
};
|
|
5875
6181
|
responses: {
|
|
5876
|
-
/** @description
|
|
6182
|
+
/** @description Number of notifications actually transitioned to read. */
|
|
5877
6183
|
200: {
|
|
5878
6184
|
headers: {
|
|
5879
6185
|
[name: string]: unknown;
|
|
@@ -5882,28 +6188,21 @@ export interface paths {
|
|
|
5882
6188
|
"application/json": {
|
|
5883
6189
|
/** @example true */
|
|
5884
6190
|
success?: boolean;
|
|
5885
|
-
data?:
|
|
6191
|
+
data?: {
|
|
6192
|
+
/** @example 2 */
|
|
6193
|
+
updated?: number;
|
|
6194
|
+
};
|
|
5886
6195
|
};
|
|
5887
6196
|
};
|
|
5888
6197
|
};
|
|
5889
|
-
/** @description
|
|
5890
|
-
|
|
5891
|
-
headers: {
|
|
5892
|
-
[name: string]: unknown;
|
|
5893
|
-
};
|
|
5894
|
-
content: {
|
|
5895
|
-
"application/json": components["schemas"]["ErrorResponse"];
|
|
5896
|
-
};
|
|
5897
|
-
};
|
|
5898
|
-
/** @description Batch is not awaiting approval */
|
|
5899
|
-
409: {
|
|
6198
|
+
/** @description Invalid body (`VALIDATION_ERROR`). */
|
|
6199
|
+
400: {
|
|
5900
6200
|
headers: {
|
|
5901
6201
|
[name: string]: unknown;
|
|
5902
6202
|
};
|
|
5903
|
-
content
|
|
5904
|
-
"application/json": components["schemas"]["ErrorResponse"];
|
|
5905
|
-
};
|
|
6203
|
+
content?: never;
|
|
5906
6204
|
};
|
|
6205
|
+
401: components["responses"]["UnauthorizedError"];
|
|
5907
6206
|
};
|
|
5908
6207
|
};
|
|
5909
6208
|
delete?: never;
|
|
@@ -5912,7 +6211,7 @@ export interface paths {
|
|
|
5912
6211
|
patch?: never;
|
|
5913
6212
|
trace?: never;
|
|
5914
6213
|
};
|
|
5915
|
-
"/frontend/
|
|
6214
|
+
"/frontend/notifications/mark-all-read": {
|
|
5916
6215
|
parameters: {
|
|
5917
6216
|
query?: never;
|
|
5918
6217
|
header?: never;
|
|
@@ -5921,24 +6220,17 @@ export interface paths {
|
|
|
5921
6220
|
};
|
|
5922
6221
|
get?: never;
|
|
5923
6222
|
put?: never;
|
|
5924
|
-
/**
|
|
5925
|
-
* Cancel a mass payout
|
|
5926
|
-
* @description Allowed from DRAFT and PENDING_APPROVAL. A PROCESSING batch cannot be canceled — payouts are already executing.
|
|
5927
|
-
*/
|
|
6223
|
+
/** Mark every unread notification as read */
|
|
5928
6224
|
post: {
|
|
5929
6225
|
parameters: {
|
|
5930
6226
|
query?: never;
|
|
5931
6227
|
header?: never;
|
|
5932
|
-
path
|
|
5933
|
-
/** @description Source wallet the batches belong to */
|
|
5934
|
-
wallet_id: components["parameters"]["MassPayoutWalletId"];
|
|
5935
|
-
id: components["parameters"]["MassPayoutId"];
|
|
5936
|
-
};
|
|
6228
|
+
path?: never;
|
|
5937
6229
|
cookie?: never;
|
|
5938
6230
|
};
|
|
5939
6231
|
requestBody?: never;
|
|
5940
6232
|
responses: {
|
|
5941
|
-
/** @description
|
|
6233
|
+
/** @description Number of notifications actually transitioned to read. */
|
|
5942
6234
|
200: {
|
|
5943
6235
|
headers: {
|
|
5944
6236
|
[name: string]: unknown;
|
|
@@ -5947,19 +6239,14 @@ export interface paths {
|
|
|
5947
6239
|
"application/json": {
|
|
5948
6240
|
/** @example true */
|
|
5949
6241
|
success?: boolean;
|
|
5950
|
-
data?:
|
|
6242
|
+
data?: {
|
|
6243
|
+
/** @example 5 */
|
|
6244
|
+
updated?: number;
|
|
6245
|
+
};
|
|
5951
6246
|
};
|
|
5952
6247
|
};
|
|
5953
6248
|
};
|
|
5954
|
-
|
|
5955
|
-
409: {
|
|
5956
|
-
headers: {
|
|
5957
|
-
[name: string]: unknown;
|
|
5958
|
-
};
|
|
5959
|
-
content: {
|
|
5960
|
-
"application/json": components["schemas"]["ErrorResponse"];
|
|
5961
|
-
};
|
|
5962
|
-
};
|
|
6249
|
+
401: components["responses"]["UnauthorizedError"];
|
|
5963
6250
|
};
|
|
5964
6251
|
};
|
|
5965
6252
|
delete?: never;
|
|
@@ -5968,54 +6255,60 @@ export interface paths {
|
|
|
5968
6255
|
patch?: never;
|
|
5969
6256
|
trace?: never;
|
|
5970
6257
|
};
|
|
5971
|
-
"/frontend/
|
|
6258
|
+
"/frontend/notifications/realtime-token": {
|
|
5972
6259
|
parameters: {
|
|
5973
6260
|
query?: never;
|
|
5974
6261
|
header?: never;
|
|
5975
6262
|
path?: never;
|
|
5976
6263
|
cookie?: never;
|
|
5977
6264
|
};
|
|
6265
|
+
get?: never;
|
|
6266
|
+
put?: never;
|
|
5978
6267
|
/**
|
|
5979
|
-
*
|
|
5980
|
-
* @description
|
|
5981
|
-
*
|
|
6268
|
+
* Issue a realtime subscription token
|
|
6269
|
+
* @description Subscribe-only token for the realtime SDK (`authCallback`). `channels`
|
|
6270
|
+
* lists the exact channel names the token grants — the personal channel
|
|
6271
|
+
* plus one per accessible wallet. Tokens expire after ~1 hour; the SDK
|
|
6272
|
+
* re-requests through the same endpoint.
|
|
5982
6273
|
*
|
|
5983
6274
|
*/
|
|
5984
|
-
|
|
6275
|
+
post: {
|
|
5985
6276
|
parameters: {
|
|
5986
6277
|
query?: never;
|
|
5987
6278
|
header?: never;
|
|
5988
|
-
path
|
|
5989
|
-
/** @description Source wallet the batches belong to */
|
|
5990
|
-
wallet_id: components["parameters"]["MassPayoutWalletId"];
|
|
5991
|
-
id: components["parameters"]["MassPayoutId"];
|
|
5992
|
-
};
|
|
6279
|
+
path?: never;
|
|
5993
6280
|
cookie?: never;
|
|
5994
6281
|
};
|
|
5995
6282
|
requestBody?: never;
|
|
5996
6283
|
responses: {
|
|
5997
|
-
/** @description
|
|
6284
|
+
/** @description Token, expiry and the granted channel names. */
|
|
5998
6285
|
200: {
|
|
5999
6286
|
headers: {
|
|
6000
6287
|
[name: string]: unknown;
|
|
6001
6288
|
};
|
|
6002
6289
|
content: {
|
|
6003
|
-
"
|
|
6290
|
+
"application/json": {
|
|
6291
|
+
/** @example true */
|
|
6292
|
+
success?: boolean;
|
|
6293
|
+
data?: {
|
|
6294
|
+
token?: string;
|
|
6295
|
+
/** Format: date-time */
|
|
6296
|
+
expires_at?: string;
|
|
6297
|
+
channels?: string[];
|
|
6298
|
+
};
|
|
6299
|
+
};
|
|
6004
6300
|
};
|
|
6005
6301
|
};
|
|
6006
|
-
|
|
6007
|
-
|
|
6302
|
+
401: components["responses"]["UnauthorizedError"];
|
|
6303
|
+
/** @description Realtime delivery is disabled for this deployment (`REALTIME_DISABLED`). */
|
|
6304
|
+
503: {
|
|
6008
6305
|
headers: {
|
|
6009
6306
|
[name: string]: unknown;
|
|
6010
6307
|
};
|
|
6011
|
-
content
|
|
6012
|
-
"application/json": components["schemas"]["ErrorResponse"];
|
|
6013
|
-
};
|
|
6308
|
+
content?: never;
|
|
6014
6309
|
};
|
|
6015
6310
|
};
|
|
6016
6311
|
};
|
|
6017
|
-
put?: never;
|
|
6018
|
-
post?: never;
|
|
6019
6312
|
delete?: never;
|
|
6020
6313
|
options?: never;
|
|
6021
6314
|
head?: never;
|
|
@@ -6389,10 +6682,13 @@ export interface paths {
|
|
|
6389
6682
|
* the order is created in `NEW` status without touching the balance;
|
|
6390
6683
|
* `POST /frontend/orders/{id}/approve` (OTP-gated, keyed on the order
|
|
6391
6684
|
* id) checks the balance, debits the funds and dispatches the on-chain
|
|
6392
|
-
* send.
|
|
6393
|
-
*
|
|
6394
|
-
*
|
|
6395
|
-
*
|
|
6685
|
+
* send. This endpoint is external-only: the order always goes on-chain,
|
|
6686
|
+
* even if the destination address belongs to a wallet on this platform
|
|
6687
|
+
* (the receiver is then credited by the regular deposit flow). Internal
|
|
6688
|
+
* (off-chain, fee-free) transfers are created only through the internal
|
|
6689
|
+
* transfer endpoint — use
|
|
6690
|
+
* `GET /frontend/counterparty/destinations/{id}/internal-transfer` to
|
|
6691
|
+
* offer that option when the destination supports it.
|
|
6396
6692
|
*
|
|
6397
6693
|
*/
|
|
6398
6694
|
post: {
|
|
@@ -11330,6 +11626,75 @@ export interface paths {
|
|
|
11330
11626
|
patch?: never;
|
|
11331
11627
|
trace?: never;
|
|
11332
11628
|
};
|
|
11629
|
+
"/frontend/notifications/test": {
|
|
11630
|
+
parameters: {
|
|
11631
|
+
query?: never;
|
|
11632
|
+
header?: never;
|
|
11633
|
+
path?: never;
|
|
11634
|
+
cookie?: never;
|
|
11635
|
+
};
|
|
11636
|
+
get?: never;
|
|
11637
|
+
put?: never;
|
|
11638
|
+
/**
|
|
11639
|
+
* Send mock notification events (development only)
|
|
11640
|
+
* @description Publishes MOCK events straight to the delivery channels so a client can verify its realtime integration: `notification.created` plus a push carrier on the personal channel, and `data.changed` on the wallet channel when `wallet_id` is passed. The mock events are not stored. Additionally, when the wallet has at least one order, a REAL `ORDER_STATUS_CHANGED` notification is produced through the regular pipeline for the wallet's newest order — it lands in the inbox of every wallet member and is delivered over realtime and push (`inbox_outcome` reports the result; `null` means no order was found). Available only on development deployments.
|
|
11641
|
+
*/
|
|
11642
|
+
post: {
|
|
11643
|
+
parameters: {
|
|
11644
|
+
query?: {
|
|
11645
|
+
/** @description Accessible wallet whose channel receives the mock `data.changed` signal */
|
|
11646
|
+
wallet_id?: string;
|
|
11647
|
+
};
|
|
11648
|
+
header?: never;
|
|
11649
|
+
path?: never;
|
|
11650
|
+
cookie?: never;
|
|
11651
|
+
};
|
|
11652
|
+
requestBody?: {
|
|
11653
|
+
content: {
|
|
11654
|
+
"application/json": {
|
|
11655
|
+
/** @description Push notification text */
|
|
11656
|
+
message?: string;
|
|
11657
|
+
};
|
|
11658
|
+
};
|
|
11659
|
+
};
|
|
11660
|
+
responses: {
|
|
11661
|
+
/** @description Mock events published */
|
|
11662
|
+
200: {
|
|
11663
|
+
headers: {
|
|
11664
|
+
[name: string]: unknown;
|
|
11665
|
+
};
|
|
11666
|
+
content: {
|
|
11667
|
+
"application/json": {
|
|
11668
|
+
/** @example true */
|
|
11669
|
+
success?: boolean;
|
|
11670
|
+
data?: {
|
|
11671
|
+
/** Format: uuid */
|
|
11672
|
+
notification_id?: string;
|
|
11673
|
+
/** Format: uuid */
|
|
11674
|
+
signaled_wallet_id?: string | null;
|
|
11675
|
+
/**
|
|
11676
|
+
* @description Result of the real inbox notification; null when no wallet was passed or it has no orders
|
|
11677
|
+
* @enum {string|null}
|
|
11678
|
+
*/
|
|
11679
|
+
inbox_outcome?: "PROCESSED" | "SKIPPED_UNRESOLVED" | "SKIPPED_DUPLICATE" | null;
|
|
11680
|
+
/**
|
|
11681
|
+
* Format: uuid
|
|
11682
|
+
* @description Order the real notification was built from
|
|
11683
|
+
*/
|
|
11684
|
+
inbox_order_uuid?: string | null;
|
|
11685
|
+
};
|
|
11686
|
+
};
|
|
11687
|
+
};
|
|
11688
|
+
};
|
|
11689
|
+
401: components["responses"]["UnauthorizedError"];
|
|
11690
|
+
};
|
|
11691
|
+
};
|
|
11692
|
+
delete?: never;
|
|
11693
|
+
options?: never;
|
|
11694
|
+
head?: never;
|
|
11695
|
+
patch?: never;
|
|
11696
|
+
trace?: never;
|
|
11697
|
+
};
|
|
11333
11698
|
}
|
|
11334
11699
|
export type webhooks = Record<string, never>;
|
|
11335
11700
|
export interface components {
|
|
@@ -11633,6 +11998,25 @@ export interface components {
|
|
|
11633
11998
|
/** @enum {string|null} */
|
|
11634
11999
|
form_factor?: "PHYSICAL" | "VIRTUAL" | null;
|
|
11635
12000
|
tokenizable: boolean;
|
|
12001
|
+
/** @description What a cardholder on this program must carry. Set per program in the vendor config, so it can change without a release — read it instead of hardcoding the form. */
|
|
12002
|
+
cardholder_requirements?: {
|
|
12003
|
+
/** @enum {string} */
|
|
12004
|
+
level?: "minimal" | "basic" | "full";
|
|
12005
|
+
/** @description Required field names; address fields are dotted (address.line1). Interlace CONSUMER also lists gov_id_issuance_date and gov_id_expiration_date (ISO YYYY-MM-DD). */
|
|
12006
|
+
required?: string[];
|
|
12007
|
+
required_documents?: ("gov_id_front" | "gov_id_back" | "selfie")[];
|
|
12008
|
+
/** @description Human-readable constraints the field list cannot express. Interlace CONSUMER: if nationality is USA, tax_identification_number is required and must be a valid SSN. */
|
|
12009
|
+
notes?: string[];
|
|
12010
|
+
/** @description What each country changes, keyed by ISO 3166-1 alpha-3 with a `default` entry; empty when the vendor reviews nothing. These fields stay out of `required` because they only hold once the nationality or address country is known: read the rule for the nationality the user picked (required_by_nationality), the rule for the address country (required_by_address), and the rule for the country that issued the document (gov_id_types). */
|
|
12011
|
+
country_rules?: {
|
|
12012
|
+
[key: string]: {
|
|
12013
|
+
gov_id_types?: string[];
|
|
12014
|
+
required_by_nationality?: string[];
|
|
12015
|
+
required_by_address?: string[];
|
|
12016
|
+
notes?: string[];
|
|
12017
|
+
};
|
|
12018
|
+
};
|
|
12019
|
+
};
|
|
11636
12020
|
/** Format: uuid */
|
|
11637
12021
|
account_currency: string;
|
|
11638
12022
|
card_limit: number;
|
|
@@ -11658,7 +12042,7 @@ export interface components {
|
|
|
11658
12042
|
} & {
|
|
11659
12043
|
[key: string]: unknown;
|
|
11660
12044
|
};
|
|
11661
|
-
/** @description Merchant of a card transaction. */
|
|
12045
|
+
/** @description Merchant of a card transaction. Always present: a row with no merchant (top-up, withdrawal, transfer) carries empty strings, so `merchant.name` is safe to read without a guard. */
|
|
11662
12046
|
TransactionMerchant: {
|
|
11663
12047
|
name?: string;
|
|
11664
12048
|
category_code?: string;
|
|
@@ -11830,7 +12214,7 @@ export interface components {
|
|
|
11830
12214
|
/** Format: date-time */
|
|
11831
12215
|
updated_at?: string;
|
|
11832
12216
|
};
|
|
11833
|
-
/** @description Card / sub-account transaction (GET /cards/{card_id}/transactions and GET /sub-accounts/{sub_account_id}/transactions).
|
|
12217
|
+
/** @description Card / sub-account transaction (GET /cards/{card_id}/transactions and GET /sub-accounts/{sub_account_id}/transactions). */
|
|
11834
12218
|
IssuingTransaction: {
|
|
11835
12219
|
/** @description Transaction id in the issuing vendor */
|
|
11836
12220
|
vendor_transaction_id?: string;
|
|
@@ -11838,7 +12222,7 @@ export interface components {
|
|
|
11838
12222
|
last4?: string;
|
|
11839
12223
|
/** @example APPROVED */
|
|
11840
12224
|
status?: string;
|
|
11841
|
-
/** @example
|
|
12225
|
+
/** @example CLEARING */
|
|
11842
12226
|
transaction_type?: string;
|
|
11843
12227
|
/** @example Purchase */
|
|
11844
12228
|
group?: string;
|
|
@@ -11849,7 +12233,19 @@ export interface components {
|
|
|
11849
12233
|
transaction_amount?: number;
|
|
11850
12234
|
/** @example USD */
|
|
11851
12235
|
transaction_currency?: string;
|
|
12236
|
+
/** @description What actually left the card: `billing_amount` plus `fee` for a debit. Show this one when a fee sits inside the operation. */
|
|
11852
12237
|
total_amount?: number;
|
|
12238
|
+
/** @description Fee charged inside this operation, in billing currency. 0 for vendors that bill fees as their own transactions (those arrive as separate rows with `transaction_type: FEE`). */
|
|
12239
|
+
fee?: number;
|
|
12240
|
+
/** @description Vendor's itemisation of `fee`; empty when it gave none. */
|
|
12241
|
+
fee_details?: {
|
|
12242
|
+
amount?: number;
|
|
12243
|
+
/** @example USD */
|
|
12244
|
+
currency?: string;
|
|
12245
|
+
/** @description Vendor's own fee code — no cross-vendor meaning. */
|
|
12246
|
+
type?: string | null;
|
|
12247
|
+
}[];
|
|
12248
|
+
/** @description Units of billing currency per unit of transaction currency, so `transaction_amount * conversion_rate ≈ billing_amount`. 1 when the currencies match. */
|
|
11853
12249
|
conversion_rate?: number;
|
|
11854
12250
|
failure_reason?: string;
|
|
11855
12251
|
adjustment_type?: string | null;
|
|
@@ -12001,12 +12397,30 @@ export interface components {
|
|
|
12001
12397
|
account_currency?: string;
|
|
12002
12398
|
/** Format: uuid */
|
|
12003
12399
|
destination_currency?: string;
|
|
12400
|
+
/** @description Settlement destination address (when the program settles to crypto) */
|
|
12401
|
+
destination_address?: string | null;
|
|
12402
|
+
/** Format: uuid */
|
|
12403
|
+
integration_vendor_id?: string;
|
|
12004
12404
|
vendor_account_id?: string | null;
|
|
12405
|
+
/** @description Customer name the account is held under */
|
|
12406
|
+
customer_name?: string | null;
|
|
12005
12407
|
/** @description Bank account details for deposits, derived from deposit_instructions. Returned null when deposits are disabled for the account. */
|
|
12006
12408
|
account_details?: Record<string, never> | null;
|
|
12007
12409
|
/** @description Deposit requisites (source of truth). Returned null when deposits are disabled for the account. */
|
|
12008
12410
|
deposit_instructions?: Record<string, never> | null;
|
|
12009
12411
|
meta?: Record<string, never> | null;
|
|
12412
|
+
/** @description Account currency details — present on hydrated reads (e.g. embedded in a single-order response) */
|
|
12413
|
+
account_currency_details?: components["schemas"]["CurrencyDetails"] | null;
|
|
12414
|
+
/** @description Destination currency details — present on hydrated reads (e.g. embedded in a single-order response) */
|
|
12415
|
+
destination_currency_details?: components["schemas"]["CurrencyDetails"] | null;
|
|
12416
|
+
/** @description Integration vendor details — present on hydrated reads (e.g. embedded in a single-order response) */
|
|
12417
|
+
integration_vendor?: {
|
|
12418
|
+
/** Format: uuid */
|
|
12419
|
+
id?: string;
|
|
12420
|
+
name?: string;
|
|
12421
|
+
code?: string;
|
|
12422
|
+
type?: string;
|
|
12423
|
+
} | null;
|
|
12010
12424
|
/** Format: date-time */
|
|
12011
12425
|
created_at?: string;
|
|
12012
12426
|
};
|
|
@@ -12025,12 +12439,111 @@ export interface components {
|
|
|
12025
12439
|
/** Format: uuid */
|
|
12026
12440
|
destination_currency_id?: string;
|
|
12027
12441
|
};
|
|
12028
|
-
/** @description
|
|
12442
|
+
/** @description Currency subset joined onto order and virtual-account reads (from the `crypto` table). */
|
|
12443
|
+
CurrencyDetails: {
|
|
12444
|
+
/** Format: uuid */
|
|
12445
|
+
uuid: string;
|
|
12446
|
+
name: string;
|
|
12447
|
+
symbol: string;
|
|
12448
|
+
icon?: string | null;
|
|
12449
|
+
/** @description Number of minor-unit decimals */
|
|
12450
|
+
decimal: number;
|
|
12451
|
+
};
|
|
12452
|
+
/** @description Public order metadata. The stored `meta` JSONB is reduced server-side to a fixed allowlist of public keys — workflow/provider internals never appear. Every field is optional: presence depends on the order type (crypto transfer, fiat off-ramp, exchange, internal transfer, card top-up, deposit). */
|
|
12029
12453
|
OrderMeta: {
|
|
12030
12454
|
/** @description Legacy idempotency key — null on orders created by the current flow */
|
|
12031
12455
|
request_id?: string | null;
|
|
12032
|
-
|
|
12456
|
+
/** @description Amount sent/received (excluding fees) */
|
|
12457
|
+
transaction_amount?: number | null;
|
|
12458
|
+
/** Format: uuid */
|
|
12459
|
+
transaction_amount_currency?: string | null;
|
|
12460
|
+
/** @description Total amount debited (including fees) */
|
|
12461
|
+
billing_amount?: number | null;
|
|
12462
|
+
/** Format: uuid */
|
|
12463
|
+
billing_amount_currency?: string | null;
|
|
12464
|
+
fee?: number | null;
|
|
12465
|
+
/** Format: uuid */
|
|
12466
|
+
fee_currency?: string | null;
|
|
12467
|
+
network_fee?: number | null;
|
|
12468
|
+
/** Format: uuid */
|
|
12469
|
+
network_fee_currency?: string | null;
|
|
12470
|
+
exchange_rate?: number | null;
|
|
12471
|
+
/** @description Blockchain chain ID (null for fiat orders) */
|
|
12472
|
+
chain_id?: number | null;
|
|
12473
|
+
/** @description Source crypto address */
|
|
12474
|
+
from_address?: string | null;
|
|
12475
|
+
/** @description Destination crypto address */
|
|
12476
|
+
to_address?: string | null;
|
|
12477
|
+
/** @description Destination crypto address (crypto transfers) */
|
|
12478
|
+
to_crypto_address?: string | null;
|
|
12479
|
+
/** @description Blockchain transaction id (when settled on-chain) */
|
|
12480
|
+
txid?: string | null;
|
|
12481
|
+
/** @description Blockchain transaction hash (when settled on-chain) */
|
|
12482
|
+
transaction_hash?: string | null;
|
|
12483
|
+
/** Format: uuid */
|
|
12484
|
+
from_currency_id?: string | null;
|
|
12485
|
+
/** Format: uuid */
|
|
12486
|
+
to_currency_id?: string | null;
|
|
12487
|
+
/**
|
|
12488
|
+
* Format: uuid
|
|
12489
|
+
* @description Sender wallet (internal transfers)
|
|
12490
|
+
*/
|
|
12491
|
+
from_wallet_uuid?: string | null;
|
|
12492
|
+
/**
|
|
12493
|
+
* Format: uuid
|
|
12494
|
+
* @description Receiver wallet (internal transfers)
|
|
12495
|
+
*/
|
|
12496
|
+
to_wallet_uuid?: string | null;
|
|
12497
|
+
/**
|
|
12498
|
+
* Format: uuid
|
|
12499
|
+
* @description Mirror-leg order id (internal transfers)
|
|
12500
|
+
*/
|
|
12501
|
+
linked_order_id?: string | null;
|
|
12502
|
+
/**
|
|
12503
|
+
* Format: uuid
|
|
12504
|
+
* @description Mirror-leg order uuid (internal transfers)
|
|
12505
|
+
*/
|
|
12506
|
+
linked_order_uuid?: string | null;
|
|
12507
|
+
/** @description True when the order settled as an internal (on-platform) transfer */
|
|
12508
|
+
is_internal?: boolean | null;
|
|
12509
|
+
/** Format: uuid */
|
|
12510
|
+
counterparty_account_id?: string | null;
|
|
12511
|
+
counterparty_account_name?: string | null;
|
|
12512
|
+
counterparty_account_nickname?: string | null;
|
|
12513
|
+
/** Format: uuid */
|
|
12514
|
+
counterparty_destination_id?: string | null;
|
|
12515
|
+
/** Format: uuid */
|
|
12516
|
+
virtual_account_id?: string | null;
|
|
12517
|
+
virtual_account_name?: string | null;
|
|
12518
|
+
/**
|
|
12519
|
+
* Format: uuid
|
|
12520
|
+
* @description Card sub-account (card top-up orders)
|
|
12521
|
+
*/
|
|
12522
|
+
sub_account_id?: string | null;
|
|
12523
|
+
/** @description Sender details on inbound (deposit) orders, normalized to one canonical shape across rails. Keys: `profile` (sender identity), `account_information` (bank identifiers: account_number, routing_number, iban, swift_bic, sort_code, currency_code, institution_name, intermediary_institution_name), `wallet_information` (crypto counterpart on internal transfers), `reference`, `memo`. */
|
|
12524
|
+
originator?: {
|
|
12525
|
+
[key: string]: unknown;
|
|
12526
|
+
} | null;
|
|
12527
|
+
/** @description Card authorizations: card id */
|
|
12528
|
+
card_id?: string | null;
|
|
12529
|
+
/** @description Card authorizations: merchant name */
|
|
12530
|
+
merchant_name?: string | null;
|
|
12531
|
+
/** @description Card authorizations: merchant category code */
|
|
12532
|
+
mcc?: string | null;
|
|
12533
|
+
/** @description Card authorizations: amount in merchant currency */
|
|
12534
|
+
merchant_amount?: number | null;
|
|
12535
|
+
merchant_currency?: string | null;
|
|
12536
|
+
is_cross_currency?: boolean | null;
|
|
12537
|
+
fx_fee_percent?: number | null;
|
|
12538
|
+
fee_fiat?: number | null;
|
|
12539
|
+
request_type?: string | null;
|
|
12540
|
+
settlement_kind?: string | null;
|
|
12541
|
+
/** @description User-provided payment reference */
|
|
12033
12542
|
reference?: string | null;
|
|
12543
|
+
/** @description User-provided internal note */
|
|
12544
|
+
note?: string | null;
|
|
12545
|
+
/** Format: date-time */
|
|
12546
|
+
completed_at?: string | null;
|
|
12034
12547
|
};
|
|
12035
12548
|
/** @description Order record */
|
|
12036
12549
|
Order: {
|
|
@@ -12071,6 +12584,36 @@ export interface components {
|
|
|
12071
12584
|
/** Format: uuid */
|
|
12072
12585
|
sub_account_id?: string | null;
|
|
12073
12586
|
info?: string | null;
|
|
12587
|
+
fee?: number | null;
|
|
12588
|
+
/** Format: uuid */
|
|
12589
|
+
fee_currency_id?: string | null;
|
|
12590
|
+
network_fee?: number | null;
|
|
12591
|
+
/** Format: uuid */
|
|
12592
|
+
network_fee_currency_id?: string | null;
|
|
12593
|
+
exchange_rate?: number | null;
|
|
12594
|
+
/** Format: uuid */
|
|
12595
|
+
from_currency_id?: string | null;
|
|
12596
|
+
/** Format: uuid */
|
|
12597
|
+
to_currency_id?: string | null;
|
|
12598
|
+
/** @description Editable free-text comment (see PUT /frontend/orders/{order_id}/comment) */
|
|
12599
|
+
comment?: string | null;
|
|
12600
|
+
/**
|
|
12601
|
+
* Format: uuid
|
|
12602
|
+
* @description user_data uuid of the last comment editor
|
|
12603
|
+
*/
|
|
12604
|
+
comment_updated_by?: string | null;
|
|
12605
|
+
/** Format: date-time */
|
|
12606
|
+
comment_updated_at?: string | null;
|
|
12607
|
+
/** @description Async workflow run id (null for synchronous orders) */
|
|
12608
|
+
workflow_run_id?: string | null;
|
|
12609
|
+
/** @description Ledger integrity: signing nonce */
|
|
12610
|
+
nonce?: string | null;
|
|
12611
|
+
/** @description Ledger integrity: row signature */
|
|
12612
|
+
signature?: string | null;
|
|
12613
|
+
/** @description Ledger integrity: signing key version */
|
|
12614
|
+
sig_key_version?: string | null;
|
|
12615
|
+
/** @description Computed dust flag — amount below the render threshold for either currency. Returned by the list endpoint (GET /frontend/orders/wallet/{wallet_uuid}); absent from single-order reads. */
|
|
12616
|
+
is_threshold_amount?: boolean;
|
|
12074
12617
|
meta?: components["schemas"]["OrderMeta"];
|
|
12075
12618
|
/**
|
|
12076
12619
|
* Format: date-time
|
|
@@ -12084,17 +12627,105 @@ export interface components {
|
|
|
12084
12627
|
};
|
|
12085
12628
|
/** @description Single-order read shape (GET /orders/id/{order_id} and GET /orders/uuid/{order_uuid}) — the base Order plus context objects hydrated from its `meta` references. */
|
|
12086
12629
|
OrderDetail: components["schemas"]["Order"] & {
|
|
12630
|
+
/** @description Owning wallet reference */
|
|
12631
|
+
wallet?: {
|
|
12632
|
+
/** Format: uuid */
|
|
12633
|
+
uuid: string;
|
|
12634
|
+
/** Format: uuid */
|
|
12635
|
+
tenant_id: string;
|
|
12636
|
+
};
|
|
12637
|
+
/** @description Source currency details (resolved from `from_uuid`) */
|
|
12638
|
+
from_currency?: components["schemas"]["CurrencyDetails"];
|
|
12639
|
+
/** @description Destination currency details (resolved from `to_uuid`) */
|
|
12640
|
+
to_currency?: components["schemas"]["CurrencyDetails"];
|
|
12087
12641
|
/** @description Virtual account referenced by the order (fiat off-ramp/on-ramp), hydrated with currency and vendor details. Absent/null when the order has no `meta.virtual_account_id`. */
|
|
12088
12642
|
virtual_account?: components["schemas"]["VirtualAccount"] | null;
|
|
12089
|
-
/** @description
|
|
12090
|
-
counterparty_destination?:
|
|
12091
|
-
|
|
12092
|
-
} | null;
|
|
12093
|
-
/** @description Documents attached to the order; empty array when none (or when document loading failed). */
|
|
12643
|
+
/** @description Receiver of the order. Present when the order has a `meta.counterparty_destination_id`; absent otherwise. */
|
|
12644
|
+
counterparty_destination?: components["schemas"]["OrderCounterpartyDestination"] | null;
|
|
12645
|
+
/** @description Documents attached to the order; empty array when none (or when document loading failed). Returned by GET /frontend/orders/id/{order_id} only; absent from the by-uuid read. */
|
|
12094
12646
|
documents?: {
|
|
12095
12647
|
[key: string]: unknown;
|
|
12096
12648
|
}[];
|
|
12097
12649
|
};
|
|
12650
|
+
/** @description Counterparty destination as embedded in single-order reads — the raw `counterparty_destinations` row with its parent account and payload rows. Distinct from the `CounterpartyDestination` shape served by the /frontend/counterparty endpoints (`external_banking_data`/`external_crypto_data` instead of `banking_data`/`crypto_data`/`internal_data`). */
|
|
12651
|
+
OrderCounterpartyDestination: {
|
|
12652
|
+
/** Format: uuid */
|
|
12653
|
+
id: string;
|
|
12654
|
+
/**
|
|
12655
|
+
* Format: uuid
|
|
12656
|
+
* @description Parent counterparty account id
|
|
12657
|
+
*/
|
|
12658
|
+
counterparty_account_id: string;
|
|
12659
|
+
/** @description User-friendly alias */
|
|
12660
|
+
nickname?: string | null;
|
|
12661
|
+
/**
|
|
12662
|
+
* @description Destination / payment rail type
|
|
12663
|
+
* @enum {string}
|
|
12664
|
+
*/
|
|
12665
|
+
type: "ACH" | "SWIFT" | "SEPA" | "CRYPTO_EXTERNAL" | "CRYPTO_INTERNAL" | "CHAPS" | "FPS" | "FEDWIRE" | "INTERNAL";
|
|
12666
|
+
/** Format: uuid */
|
|
12667
|
+
external_banking_data_id?: string | null;
|
|
12668
|
+
/** Format: uuid */
|
|
12669
|
+
external_crypto_data_id?: string | null;
|
|
12670
|
+
/**
|
|
12671
|
+
* Format: uuid
|
|
12672
|
+
* @description Internal-destination payload id (INTERNAL type)
|
|
12673
|
+
*/
|
|
12674
|
+
internal_wallet_data_id?: string | null;
|
|
12675
|
+
/** @description Soft-delete flag; a deleted destination stays readable on historical orders */
|
|
12676
|
+
is_deleted?: boolean | null;
|
|
12677
|
+
/** Format: date-time */
|
|
12678
|
+
deleted_at?: string | null;
|
|
12679
|
+
/** @description Ledger integrity: signing nonce */
|
|
12680
|
+
nonce?: string | null;
|
|
12681
|
+
/** @description Ledger integrity: row signature */
|
|
12682
|
+
signature?: string | null;
|
|
12683
|
+
/** @description Ledger integrity: signing key version */
|
|
12684
|
+
sig_key_version?: string | null;
|
|
12685
|
+
/** Format: date-time */
|
|
12686
|
+
created_at: string;
|
|
12687
|
+
/** Format: date-time */
|
|
12688
|
+
updated_at: string;
|
|
12689
|
+
/** @description Parent counterparty account */
|
|
12690
|
+
counterparty_account?: {
|
|
12691
|
+
/** Format: uuid */
|
|
12692
|
+
id: string;
|
|
12693
|
+
name: string;
|
|
12694
|
+
type: string;
|
|
12695
|
+
email?: string | null;
|
|
12696
|
+
phone?: string | null;
|
|
12697
|
+
/**
|
|
12698
|
+
* Format: uuid
|
|
12699
|
+
* @description Owning wallet uuid
|
|
12700
|
+
*/
|
|
12701
|
+
wallet_id?: string | null;
|
|
12702
|
+
};
|
|
12703
|
+
/** @description Banking details (bank rails); null for crypto/internal destinations */
|
|
12704
|
+
external_banking_data?: {
|
|
12705
|
+
/** Format: uuid */
|
|
12706
|
+
id?: string;
|
|
12707
|
+
account_number?: string | null;
|
|
12708
|
+
/** @description ABA routing number */
|
|
12709
|
+
routing_number?: string | null;
|
|
12710
|
+
bank_name?: string | null;
|
|
12711
|
+
swift_bic?: string | null;
|
|
12712
|
+
iban?: string | null;
|
|
12713
|
+
note?: string | null;
|
|
12714
|
+
/** Format: uuid */
|
|
12715
|
+
address_id?: string | null;
|
|
12716
|
+
} | null;
|
|
12717
|
+
/** @description Crypto address details (crypto rails); null for bank/internal destinations */
|
|
12718
|
+
external_crypto_data?: {
|
|
12719
|
+
/** Format: uuid */
|
|
12720
|
+
id?: string;
|
|
12721
|
+
/** @description Blockchain address */
|
|
12722
|
+
address?: string;
|
|
12723
|
+
/** Format: uuid */
|
|
12724
|
+
currency_id?: string;
|
|
12725
|
+
/** @description Memo/tag (XRP, XLM, …) */
|
|
12726
|
+
memo?: string | null;
|
|
12727
|
+
} | null;
|
|
12728
|
+
};
|
|
12098
12729
|
/** @description Supporting document attached to an order at creation time (persisted to order_documents). */
|
|
12099
12730
|
OrderDocumentInput: {
|
|
12100
12731
|
/**
|
|
@@ -12110,7 +12741,13 @@ export interface components {
|
|
|
12110
12741
|
* @description Source wallet UUID
|
|
12111
12742
|
*/
|
|
12112
12743
|
wallet_id: string;
|
|
12744
|
+
/** @description Amount to send, in `from_currency_id` units. With `is_reverse: true` — the amount the recipient must receive, in destination-currency units. */
|
|
12113
12745
|
amount: number;
|
|
12746
|
+
/**
|
|
12747
|
+
* @description When true, `amount` is the receive-amount and the debited amount is grossed up with fees.
|
|
12748
|
+
* @default false
|
|
12749
|
+
*/
|
|
12750
|
+
is_reverse: boolean;
|
|
12114
12751
|
/** Format: uuid */
|
|
12115
12752
|
from_currency_id: string;
|
|
12116
12753
|
/** Format: uuid */
|
|
@@ -12135,7 +12772,13 @@ export interface components {
|
|
|
12135
12772
|
* @description Source wallet UUID
|
|
12136
12773
|
*/
|
|
12137
12774
|
wallet_id: string;
|
|
12775
|
+
/** @description Amount to send, in `from_currency_id` units. With `is_reverse: true` — the amount the recipient must receive, in destination-currency units. */
|
|
12138
12776
|
amount: number;
|
|
12777
|
+
/**
|
|
12778
|
+
* @description When true, `amount` is the receive-amount and the debited amount is grossed up with fees.
|
|
12779
|
+
* @default false
|
|
12780
|
+
*/
|
|
12781
|
+
is_reverse: boolean;
|
|
12139
12782
|
/** Format: uuid */
|
|
12140
12783
|
from_currency_id: string;
|
|
12141
12784
|
/** Format: uuid */
|
|
@@ -12157,8 +12800,13 @@ export interface components {
|
|
|
12157
12800
|
FrontendExchangeOrderRequest: {
|
|
12158
12801
|
/** Format: uuid */
|
|
12159
12802
|
wallet_id: string;
|
|
12160
|
-
/** @description Amount to exchange
|
|
12803
|
+
/** @description Amount to exchange, in `from_currency_id` units. With `is_reverse: true` — the amount to receive, in `to_currency_id` units. */
|
|
12161
12804
|
amount: number;
|
|
12805
|
+
/**
|
|
12806
|
+
* @description When true, `amount` is the receive-amount and the debited amount is grossed up with fees.
|
|
12807
|
+
* @default false
|
|
12808
|
+
*/
|
|
12809
|
+
is_reverse: boolean;
|
|
12162
12810
|
/**
|
|
12163
12811
|
* Format: uuid
|
|
12164
12812
|
* @description Source currency UUID
|
|
@@ -12341,6 +12989,25 @@ export interface components {
|
|
|
12341
12989
|
destination_id: string;
|
|
12342
12990
|
amount: number;
|
|
12343
12991
|
};
|
|
12992
|
+
NotificationView: {
|
|
12993
|
+
/** Format: uuid */
|
|
12994
|
+
id: string;
|
|
12995
|
+
/** @enum {string} */
|
|
12996
|
+
type: "DEPOSIT_RECEIVED" | "TRANSFER_RECEIVED" | "ORDER_STATUS_CHANGED" | "KYC_STATUS_CHANGED";
|
|
12997
|
+
/** @description Structured fact snapshot; the client renders the presentation. Shape depends on `type`; evolution is additive-only. */
|
|
12998
|
+
payload: Record<string, never>;
|
|
12999
|
+
/** Format: uuid */
|
|
13000
|
+
wallet_id: string | null;
|
|
13001
|
+
/** Format: date-time */
|
|
13002
|
+
read_at: string | null;
|
|
13003
|
+
/** Format: date-time */
|
|
13004
|
+
created_at: string;
|
|
13005
|
+
};
|
|
13006
|
+
NotificationPreference: {
|
|
13007
|
+
/** @enum {string} */
|
|
13008
|
+
channel: "IN_APP" | "PUSH";
|
|
13009
|
+
enabled: boolean;
|
|
13010
|
+
};
|
|
12344
13011
|
};
|
|
12345
13012
|
responses: {
|
|
12346
13013
|
/** @description Authentication credentials are missing or invalid */
|