@dakota-xyz/ts-sdk 1.0.17 → 1.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.d.mts CHANGED
@@ -429,6 +429,85 @@ type components = {
429
429
  */
430
430
  readonly decimals: number;
431
431
  };
432
+ readonly SelfServeCreditsBalanceResponse: {
433
+ /**
434
+ * Format: int64
435
+ * @example 45000
436
+ */
437
+ readonly balance_cents: number;
438
+ /**
439
+ * Format: int64
440
+ * @example 9000000
441
+ */
442
+ readonly transfer_capacity_cents: number;
443
+ };
444
+ readonly SelfServeCreditsLedgerEntry: {
445
+ /** @example 34o8dS2h9c7n1V8qLpY2Zx6TwUa */
446
+ readonly id: string;
447
+ /** @enum {string} */
448
+ readonly entry_type: "purchase" | "deduction" | "refund";
449
+ /**
450
+ * @description Sub-category that distinguishes transaction fees from compliance
451
+ * fees and similar for refunds. `unknown` indicates a legacy row
452
+ * written before this column existed.
453
+ * @enum {string}
454
+ */
455
+ readonly category: "transaction_fee" | "compliance_fee" | "transaction_refund" | "compliance_refund" | "purchase" | "adjustment" | "unknown";
456
+ /**
457
+ * Format: int64
458
+ * @example -5000
459
+ */
460
+ readonly amount_cents: number;
461
+ /**
462
+ * Format: int64
463
+ * @example 45000
464
+ */
465
+ readonly balance_after_cents: number;
466
+ readonly transaction_id?: string | null;
467
+ /**
468
+ * @description Stripe PaymentIntent ID (pi_...) for purchase entries — paste into the Stripe dashboard search to look up the underlying payment.
469
+ * @example pi_3M5xY42eZvKYlo2C0xRm6WVe
470
+ */
471
+ readonly stripe_payment_intent_id?: string | null;
472
+ /** @example Transfer fee for transaction txn_123 */
473
+ readonly description: string;
474
+ /** Format: date-time */
475
+ readonly created_at: string;
476
+ };
477
+ readonly SelfServeCreditsLedgerResponse: {
478
+ readonly entries: readonly components["schemas"]["SelfServeCreditsLedgerEntry"][];
479
+ /** @example false */
480
+ readonly has_more: boolean;
481
+ };
482
+ readonly SelfServeCreditTier: {
483
+ /**
484
+ * Format: int64
485
+ * @example 10000
486
+ */
487
+ readonly price_cents: number;
488
+ /**
489
+ * Format: int64
490
+ * @example 2000000
491
+ */
492
+ readonly transfer_capacity_cents: number;
493
+ };
494
+ readonly SelfServeCreditTiersResponse: {
495
+ readonly tiers: readonly components["schemas"]["SelfServeCreditTier"][];
496
+ };
497
+ readonly SelfServeCreditsPurchaseRequest: {
498
+ /**
499
+ * Format: int64
500
+ * @example 10000
501
+ */
502
+ readonly tier_price_cents: number;
503
+ };
504
+ readonly SelfServeCreditsPurchaseResponse: {
505
+ /**
506
+ * Format: uri
507
+ * @example https://checkout.stripe.com/c/pay/cs_test_123
508
+ */
509
+ readonly checkout_url: string;
510
+ };
432
511
  /** @description User object representing a user in the system, including all clients they can access. */
433
512
  readonly ClientUser: {
434
513
  readonly id: components["schemas"]["KSUID"];
@@ -450,6 +529,12 @@ type components = {
450
529
  readonly role: components["schemas"]["ClientUserRole"];
451
530
  /** @description Whether the client has SWIFT payments enabled. */
452
531
  readonly swift_enabled?: boolean;
532
+ readonly client_id?: components["schemas"]["KSUID"];
533
+ /**
534
+ * @description Display name of the active client for this request.
535
+ * @example Acme Corp
536
+ */
537
+ readonly client_name?: string;
453
538
  /**
454
539
  * @description Timestamp of when the user was created.
455
540
  * @example 1234567890
@@ -457,11 +542,71 @@ type components = {
457
542
  readonly created_at: number;
458
543
  };
459
544
  /**
460
- * @description Role that can be assigned to a client user
545
+ * @description Role that can be assigned to a client user. Available roles: `admin` (full access except issuances) and `viewer` (read-only access).
461
546
  * @example admin
462
547
  * @enum {string}
463
548
  */
464
549
  readonly ClientUserRole: "admin" | "viewer";
550
+ readonly ClientPricingConfig: {
551
+ /**
552
+ * @description Monthly minimum fee in cents
553
+ * @example 10000
554
+ */
555
+ readonly monthlyMinimumCents: number;
556
+ /**
557
+ * @description Transfer fee in basis points (0-10000, representing 0% to 100%)
558
+ * @example 25
559
+ */
560
+ readonly transferFeeBps: number;
561
+ /**
562
+ * @description Per-ACH transaction fee in cents
563
+ * @example 100
564
+ */
565
+ readonly achFeeCents: number;
566
+ /**
567
+ * @description Per-wire transaction fee in cents
568
+ * @example 2500
569
+ */
570
+ readonly wireFeeCents: number;
571
+ /**
572
+ * @description Per-SWIFT transaction fee in cents
573
+ * @example 150
574
+ */
575
+ readonly sepaFeeCents: number;
576
+ /**
577
+ * @description Per-Swift-transfer banking fee in USD cents.
578
+ * @example 4000
579
+ */
580
+ readonly swiftFeeCents: number;
581
+ /**
582
+ * @description Per-individual-application-submission compliance fee in USD cents.
583
+ * @example 500
584
+ */
585
+ readonly kycFeeCents: number;
586
+ /**
587
+ * @description Per-business-application-submission compliance fee in USD cents.
588
+ * @example 2500
589
+ */
590
+ readonly kybFeeCents: number;
591
+ /**
592
+ * Format: date-time
593
+ * @description When this pricing takes effect
594
+ * @example 2024-01-01T00:00:00Z
595
+ */
596
+ readonly effectiveFrom: string;
597
+ /**
598
+ * Format: date-time
599
+ * @description When this pricing configuration was created
600
+ * @example 2024-01-01T00:00:00Z
601
+ */
602
+ readonly createdAt: string;
603
+ /**
604
+ * Format: date-time
605
+ * @description When this pricing configuration was last updated
606
+ * @example 2024-01-01T00:00:00Z
607
+ */
608
+ readonly updatedAt: string;
609
+ };
465
610
  /** @description Request body for creating a new client user */
466
611
  readonly CreateClientUserRequest: {
467
612
  /**
@@ -583,7 +728,7 @@ type components = {
583
728
  * @example transaction.auto.updated
584
729
  * @enum {string}
585
730
  */
586
- readonly EventType: "user.created" | "user.updated" | "user.deleted" | "api_key.created" | "api_key.deleted" | "customer.created" | "customer.updated" | "customer.kyb_link.created" | "customer.kyb_link.updated" | "customer.kyb_status.created" | "customer.kyb_status.updated" | "auto_account.created" | "auto_account.updated" | "auto_account.deleted" | "transaction.auto.created" | "transaction.auto.updated" | "transaction.one_off.created" | "transaction.one_off.updated" | "recipient.created" | "recipient.updated" | "recipient.deleted" | "destination.created" | "destination.deleted" | "target.created" | "target.updated" | "target.deleted" | "exception.created" | "exception.cleared" | "bvnk.onboarding.created" | "bvnk.onboarding.updated" | "wallet.created" | "wallet.updated" | "wallet.signer_group.created" | "wallet.signer_group.updated" | "wallet.policy.created" | "wallet.policy.updated" | "wallet.transaction.created" | "wallet.transaction.updated" | "wallet.deposit";
731
+ readonly EventType: "user.created" | "user.updated" | "user.deleted" | "api_key.created" | "api_key.deleted" | "customer.created" | "customer.updated" | "customer.kyb_link.created" | "customer.kyb_link.updated" | "customer.kyb_status.created" | "customer.kyb_status.updated" | "customer.kyb_application.submitted" | "auto_account.created" | "auto_account.updated" | "auto_account.deleted" | "transaction.auto.created" | "transaction.auto.updated" | "transaction.one_off.created" | "transaction.one_off.updated" | "recipient.created" | "recipient.updated" | "recipient.deleted" | "destination.created" | "destination.deleted" | "target.created" | "target.updated" | "target.deleted" | "exception.created" | "exception.cleared" | "bvnk.onboarding.created" | "bvnk.onboarding.updated" | "wallet.created" | "wallet.updated" | "wallet.signer_group.created" | "wallet.signer_group.updated" | "wallet.policy.created" | "wallet.policy.updated" | "wallet.transaction.created" | "wallet.transaction.updated" | "wallet.deposit";
587
732
  /** @description Request metadata for the original operation that emitted the event, when available. */
588
733
  readonly EventRequest: {
589
734
  /**
@@ -637,6 +782,10 @@ type components = {
637
782
  * @enum {string}
638
783
  */
639
784
  readonly NetworkId: "ethereum-mainnet" | "ethereum-sepolia" | "ethereum-goerli" | "ethereum-holesky" | "solana-mainnet" | "solana-devnet" | "solana-testnet" | "base-mainnet" | "base-sepolia" | "arbitrum-mainnet" | "arbitrum-sepolia" | "optimism-mainnet" | "optimism-sepolia" | "polygon-mainnet" | "polygon-amoy";
785
+ readonly CreateApiKeyForClientRequest: {
786
+ /** @description Client ID to create the API key for */
787
+ readonly client_id: components["schemas"]["KSUID"];
788
+ };
640
789
  readonly ApiKeyResponse: {
641
790
  readonly id: components["schemas"]["KSUID"];
642
791
  /**
@@ -724,6 +873,15 @@ type components = {
724
873
  */
725
874
  readonly country: string;
726
875
  };
876
+ /**
877
+ * Destination Address
878
+ * @description Address format for fiat destinations with Lead Bank wire transfer character limits (max 35 characters per address line).
879
+ */
880
+ readonly FiatUSDestinationAddress: components["schemas"]["Address"] & {
881
+ readonly street1?: string;
882
+ readonly street2?: string;
883
+ readonly street3?: string;
884
+ };
727
885
  readonly Country: {
728
886
  /** @example CA */
729
887
  readonly code: string;
@@ -748,6 +906,8 @@ type components = {
748
906
  * @example external_customer_123
749
907
  */
750
908
  readonly external_id?: string;
909
+ /** @description ID of an existing customer to associate this new customer with as a sub-client. The referenced customer must belong to the same client. */
910
+ readonly sub_client_id?: components["schemas"]["KSUID"];
751
911
  };
752
912
  /** @description Response returned when a customer creation process is successfully initiated. */
753
913
  readonly CustomerCreateResponse: {
@@ -789,6 +949,31 @@ type components = {
789
949
  */
790
950
  readonly customer_type: "individual" | "business";
791
951
  readonly kyb_status: components["schemas"]["KybStatus"];
952
+ /**
953
+ * @description Provider-agnostic effective KYC/B status for this customer,
954
+ * derived server-side for display convenience. Returns the same
955
+ * answer for both Sumsub-verified and Persona-verified customers
956
+ * without the client having to know which provider did the work.
957
+ *
958
+ * **Derivation order (most authoritative first):**
959
+ * 1. The customer's onboarding application `decision`, if set
960
+ * (`approved` → `approved`; `declined`/`auto_declined` →
961
+ * `rejected`; `withdrawn` → `expired`).
962
+ * 2. The most-recently-updated non-deleted persona `kyb_link`'s
963
+ * status (legacy customers from before the orchestration
964
+ * layer — Persona's `created` maps to `not_started`,
965
+ * `completed` to `approved`, `needs_review` to `in_review`).
966
+ * 3. `pending` if the customer has an open onboarding
967
+ * application but no decision yet (Sumsub in-flight).
968
+ * 4. `not_started` otherwise.
969
+ *
970
+ * **Advisory, not authoritative.** This field is provided for
971
+ * badge rendering and operator UIs. The derivation rules may
972
+ * evolve as new verification providers are added. For
973
+ * compliance-critical decisions, consult `decision`,
974
+ * `kyb_links`, and `provider_statuses` directly.
975
+ */
976
+ readonly kyc_status: components["schemas"]["KybLinkStatus"];
792
977
  /** @description KYB Links for different providers used in the KYB process. */
793
978
  readonly kyb_links?: readonly components["schemas"]["KybLink"][];
794
979
  /** @description Detailed status information from different verification providers used in the KYB process. */
@@ -821,13 +1006,47 @@ type components = {
821
1006
  * @example 1234567890
822
1007
  */
823
1008
  readonly deleted_at?: number;
1009
+ /** @description ID of the sub-client this customer is associated with, if any. */
1010
+ readonly sub_client_id?: components["schemas"]["KSUID"];
1011
+ /**
1012
+ * @description Name of the sub-client this customer is associated with, if any.
1013
+ * @example Partner Corp
1014
+ */
1015
+ readonly sub_client_name?: string;
1016
+ /**
1017
+ * @description Whether this customer is acting as a sub-client (has other customers associated with it).
1018
+ * @default false
1019
+ */
1020
+ readonly is_sub_client: boolean;
824
1021
  };
825
1022
  /**
826
1023
  * @description Overall status of the KYB verification process (e.g., pending, active, restricted).
827
1024
  * @example pending
828
1025
  * @enum {string}
829
1026
  */
830
- readonly KybStatus: "active" | "pending" | "partner_review" | "rejected" | "frozen";
1027
+ readonly KybStatus: "active" | "pending" | "partner_review" | "rejected" | "frozen" | "auto_declined";
1028
+ /** @description Request to update the sub-client association for a customer. Set sub_client_id to associate with a sub-client, or null to disassociate. */
1029
+ readonly UpdateCustomerSubClientRequest: {
1030
+ /**
1031
+ * @description ID of the sub-client to associate with, or null to disassociate.
1032
+ * @example 1NFHrqBHb3cTfLVkFSGmHZqdDPi
1033
+ */
1034
+ readonly sub_client_id?: string | null;
1035
+ };
1036
+ /** @description Summary of a sub-client including the count of customers associated with it. */
1037
+ readonly SubClientSummary: {
1038
+ readonly sub_client_id: components["schemas"]["KSUID"];
1039
+ /**
1040
+ * @description Name of the customer acting as a sub-client.
1041
+ * @example Partner Corp
1042
+ */
1043
+ readonly sub_client_name: string;
1044
+ /**
1045
+ * @description Number of customers associated with this sub-client.
1046
+ * @example 15
1047
+ */
1048
+ readonly customer_count: number;
1049
+ };
831
1050
  readonly ProviderKybStatus: {
832
1051
  /**
833
1052
  * @description ID of the verification provider or service used for a specific check.
@@ -839,7 +1058,7 @@ type components = {
839
1058
  * @example approved
840
1059
  * @enum {string}
841
1060
  */
842
- readonly status: "not_started" | "in_review" | "approved" | "rejected" | "requires_info" | "frozen";
1061
+ readonly status: "not_started" | "in_review" | "approved" | "rejected" | "requires_info" | "auto_declined" | "frozen";
843
1062
  /** @description Array of endorsements associated with this provider status. */
844
1063
  readonly endorsements?: readonly string[];
845
1064
  };
@@ -881,6 +1100,13 @@ type components = {
881
1100
  /**
882
1101
  * KYB Link Type
883
1102
  * @description Type of link provided by a verification provider for KYB verification.
1103
+ *
1104
+ * **Deprecated values:**
1105
+ * - `tos` — the Bridge TOS flow has been deprecated. The dashboard no
1106
+ * longer surfaces TOS state, but legacy customer records may still
1107
+ * carry `link_type: 'tos'` entries on the wire. New integrations
1108
+ * should ignore these entries; the value is retained in the enum
1109
+ * to keep responses for legacy data schema-valid.
884
1110
  * @example persona
885
1111
  * @enum {string}
886
1112
  */
@@ -918,17 +1144,17 @@ type components = {
918
1144
  readonly Family: "evm" | "solana";
919
1145
  /**
920
1146
  * Payment Capability
921
- * @description Type of payment rail capability supported.
1147
+ * @description Type of payment rail capability supported. For onramp accounts, `us_bank_account` indicates the account accepts both ACH and Wire (Fedwire) deposits interchangeably.
922
1148
  * @example ach
923
1149
  * @enum {string}
924
1150
  */
925
- readonly PaymentCapability: "ach" | "fedwire" | "swift" | "sepa";
1151
+ readonly PaymentCapability: "ach" | "fedwire" | "swift" | "us_bank_account";
926
1152
  /**
927
1153
  * Transaction Status
928
1154
  * @description Current status of a transaction.
929
1155
  * @enum {string}
930
1156
  */
931
- readonly TransactionStatus: "timed_out" | "not_started" | "in_progress" | "awaiting_confirmation" | "pending" | "processing" | "completed" | "invalid" | "failed" | "canceled" | "reversed" | "rejected" | "broadcasted" | "pending_return" | "returned";
1157
+ readonly TransactionStatus: "timed_out" | "not_started" | "in_progress" | "awaiting_confirmation" | "pending" | "processing" | "completed" | "invalid" | "failed" | "canceled" | "reversed" | "rejected" | "broadcasted" | "pending_return" | "returned" | "pending_reversal";
932
1158
  /**
933
1159
  * Transaction Type
934
1160
  * @description Type of transaction.
@@ -1179,13 +1405,13 @@ type components = {
1179
1405
  readonly account_type: "checking" | "savings";
1180
1406
  /** @example John Doe */
1181
1407
  readonly account_holder_name: string;
1182
- readonly account_holder_address?: components["schemas"]["Address"];
1408
+ readonly account_holder_address?: components["schemas"]["FiatUSDestinationAddress"];
1183
1409
  /** @example 1234567890 */
1184
1410
  readonly account_holder_phone?: string;
1185
1411
  /** @example Bank of America */
1186
1412
  readonly bank_name: string;
1187
1413
  /** @description Address of the bank. Optional for US domestic transfers. */
1188
- readonly bank_address?: components["schemas"]["Address"];
1414
+ readonly bank_address?: components["schemas"]["FiatUSDestinationAddress"];
1189
1415
  /** @example 1234567890 */
1190
1416
  readonly bank_phone?: string;
1191
1417
  } & {
@@ -1203,7 +1429,7 @@ type components = {
1203
1429
  };
1204
1430
  /**
1205
1431
  * IBAN Fiat Destination Request
1206
- * @description Request for creating or updating an IBAN bank account destination (for SWIFT and SEPA transfers).
1432
+ * @description Request for creating or updating an IBAN bank account destination (for SWIFT and SWIFT transfers).
1207
1433
  */
1208
1434
  readonly FiatIBANDestinationRequest: Omit<components["schemas"]["DestinationRequest"], "destination_type"> & {
1209
1435
  /**
@@ -1224,7 +1450,7 @@ type components = {
1224
1450
  */
1225
1451
  readonly iban: string;
1226
1452
  /**
1227
- * @description BIC/SWIFT code for the international bank account (optional for SEPA, required for SWIFT).
1453
+ * @description BIC/SWIFT code for the international bank account (optional for required for SWIFT).
1228
1454
  * @example DEUTDEFFXXX
1229
1455
  */
1230
1456
  readonly bic?: string;
@@ -1429,7 +1655,7 @@ type components = {
1429
1655
  };
1430
1656
  /**
1431
1657
  * IBAN Fiat Destination Response
1432
- * @description Response for an IBAN bank account destination (for SWIFT and SEPA transfers).
1658
+ * @description Response for an IBAN bank account destination (for SWIFT and SWIFT transfers).
1433
1659
  */
1434
1660
  readonly FiatIBANDestinationResponse: Omit<components["schemas"]["DestinationResponse"], "destination_type"> & {
1435
1661
  /**
@@ -1448,7 +1674,7 @@ type components = {
1448
1674
  */
1449
1675
  readonly iban: string;
1450
1676
  /**
1451
- * @description BIC/SWIFT code for the international bank account (optional for SEPA, required for SWIFT).
1677
+ * @description BIC/SWIFT code for the international bank account (optional for required for SWIFT).
1452
1678
  * @example DEUTDEFFXXX
1453
1679
  */
1454
1680
  readonly bic?: string;
@@ -1483,9 +1709,14 @@ type components = {
1483
1709
  */
1484
1710
  readonly destination_type: "fiat_iban";
1485
1711
  };
1486
- /** @description A unified transaction object representing money movements in the Dakota platform. */
1712
+ /** @description A unified transaction object representing money movements in the Dakota platform. Used for auto-account transactions. */
1487
1713
  readonly Transaction: {
1488
1714
  readonly id: components["schemas"]["KSUID"];
1715
+ /**
1716
+ * @description Discriminator field. Always "auto_account" for auto-account transactions. (enum property replaced by openapi-typescript)
1717
+ * @enum {string}
1718
+ */
1719
+ readonly resource_type: "auto_account";
1489
1720
  readonly type: components["schemas"]["TransactionType"];
1490
1721
  readonly status: components["schemas"]["TransactionStatus"];
1491
1722
  /**
@@ -1519,6 +1750,7 @@ type components = {
1519
1750
  * @example 1234567890
1520
1751
  */
1521
1752
  readonly completedAt?: number | null;
1753
+ readonly sender_details?: components["schemas"]["SenderDetails"];
1522
1754
  };
1523
1755
  readonly TransactionResource: components["schemas"]["OneOffTransaction"] | components["schemas"]["WalletTransaction"] | components["schemas"]["Transaction"];
1524
1756
  readonly PaginatedCustomerTransactionResponse: components["schemas"]["PaginatedListResponse"] & {
@@ -1682,6 +1914,64 @@ type components = {
1682
1914
  /** @description List of event types this target cares about (ignored if global is true) */
1683
1915
  readonly event_types?: readonly components["schemas"]["EventType"][];
1684
1916
  };
1917
+ /** @description Originating sender details for onramp/offramp/swap transactions. Populated when source-side metadata is available (e.g., from inbound wire/ACH source data). */
1918
+ readonly SenderDetails: {
1919
+ /**
1920
+ * @description Type of the originating sender (e.g., "fiat_account", "crypto_wallet").
1921
+ * @example fiat_account
1922
+ */
1923
+ readonly sender_type?: string;
1924
+ /**
1925
+ * @description Name on the originating account.
1926
+ * @example John Doe
1927
+ */
1928
+ readonly sender_account_holder_name?: string;
1929
+ /**
1930
+ * @description Bank name of the originating account.
1931
+ * @example Chase Bank
1932
+ */
1933
+ readonly sender_bank_name?: string;
1934
+ /**
1935
+ * @description ACH routing number of the originating bank account.
1936
+ * @example 021000021
1937
+ */
1938
+ readonly sender_routing_number?: string;
1939
+ /**
1940
+ * @description Account number of the originating bank account.
1941
+ * @example 1234567890
1942
+ */
1943
+ readonly sender_account_number?: string;
1944
+ /**
1945
+ * @description Wire routing number of the originating bank account.
1946
+ * @example 021000021
1947
+ */
1948
+ readonly sender_wire_routing_number?: string;
1949
+ /**
1950
+ * @description Type of the originating bank account (e.g., "checking", "savings").
1951
+ * @example checking
1952
+ */
1953
+ readonly sender_account_type?: string;
1954
+ /**
1955
+ * @description IBAN of the originating account.
1956
+ * @example GB82WEST12345698765432
1957
+ */
1958
+ readonly sender_iban?: string;
1959
+ /**
1960
+ * @description BIC/SWIFT code of the originating bank.
1961
+ * @example BARCGB22XXX
1962
+ */
1963
+ readonly sender_bic?: string;
1964
+ /**
1965
+ * @description Blockchain wallet address of the originating sender (offramp/swap).
1966
+ * @example 0x1234567890abcdef1234567890abcdef12345678
1967
+ */
1968
+ readonly sender_wallet_address?: string;
1969
+ /**
1970
+ * @description Network identifier of the originating wallet (e.g., "ethereum-mainnet").
1971
+ * @example ethereum-mainnet
1972
+ */
1973
+ readonly sender_network?: string;
1974
+ };
1685
1975
  /** @description A transaction relating to an auto account */
1686
1976
  readonly AutoAccountTransaction: {
1687
1977
  readonly id: components["schemas"]["KSUID"];
@@ -1709,6 +1999,7 @@ type components = {
1709
1999
  readonly completed_at?: number;
1710
2000
  readonly receipt?: components["schemas"]["TransactionReceipt"];
1711
2001
  readonly crypto_details?: components["schemas"]["TransactionCryptoDetails"];
2002
+ readonly sender_details?: components["schemas"]["SenderDetails"];
1712
2003
  /**
1713
2004
  * @description Provider identifier
1714
2005
  * @example dakota
@@ -1724,6 +2015,36 @@ type components = {
1724
2015
  * @example processing
1725
2016
  */
1726
2017
  readonly provider_status: string;
2018
+ /**
2019
+ * @description NACHA/Fedwire return code (e.g., R01) when the transaction was returned by the receiving bank.
2020
+ * @example R01
2021
+ */
2022
+ readonly return_code?: string;
2023
+ /**
2024
+ * @description Human-readable return reason provided by the receiving bank.
2025
+ * @example Insufficient Funds
2026
+ */
2027
+ readonly return_reason?: string;
2028
+ /**
2029
+ * @description Unix timestamp when the return was initiated.
2030
+ * @example 1234567890
2031
+ */
2032
+ readonly return_initiated_at?: number;
2033
+ /**
2034
+ * @description Unix timestamp deadline for return processing.
2035
+ * @example 1234567890
2036
+ */
2037
+ readonly return_deadline?: number;
2038
+ /**
2039
+ * @description Lead Bank ACH reversal reason when the originator reverses the transaction (e.g., duplicate, receiver_incorrect).
2040
+ * @example duplicate
2041
+ */
2042
+ readonly reversal_reason?: string;
2043
+ /**
2044
+ * @description Unix timestamp when the reversal was initiated.
2045
+ * @example 1234567890
2046
+ */
2047
+ readonly reversal_initiated_at?: number;
1727
2048
  };
1728
2049
  /** @description Detailed representation of an amount with its asset and optional metadata */
1729
2050
  readonly AmountDetails: {
@@ -1811,14 +2132,25 @@ type components = {
1811
2132
  /** @description Optional preferred payment rail for bank transfers. If not specified, the system will automatically select the most appropriate rail based on the destination's supported methods. */
1812
2133
  readonly destination_payment_rail?: components["schemas"]["PaymentCapability"];
1813
2134
  /**
1814
- * @description Optional payment reference message for bank transfers. Length limits: ACH (1-10 chars), Wire (1-140 chars), SEPA (6-140 chars), SWIFT (1-140 chars, max 4 lines of 35 chars each)
2135
+ * @description Optional payment reference message for bank transfers. Length limits: ACH (1-10 chars), Wire (1-140 chars) (6-140 chars), SWIFT (1-140 chars, max 4 lines of 35 chars each)
1815
2136
  * @example Invoice payment for services
1816
2137
  */
1817
2138
  readonly payment_reference?: string;
2139
+ /**
2140
+ * Format: int32
2141
+ * @description Developer fee in basis points (1 bp = 0.01%). Overrides the default client fee for this transaction.
2142
+ * @example 50
2143
+ */
2144
+ readonly developer_fee_bps?: number;
1818
2145
  };
1819
- /** @description A one-off transaction response */
2146
+ /** @description A one-off transaction response. Used for single on/off-ramp transactions. */
1820
2147
  readonly OneOffTransaction: {
1821
2148
  readonly id: components["schemas"]["KSUID"];
2149
+ /**
2150
+ * @description Discriminator field. Always "one_off" for one-off transactions. (enum property replaced by openapi-typescript)
2151
+ * @enum {string}
2152
+ */
2153
+ readonly resource_type: "one_off";
1822
2154
  readonly customer_id: components["schemas"]["KSUID"];
1823
2155
  /**
1824
2156
  * @description Temporary address where funds should be sent
@@ -1865,7 +2197,7 @@ type components = {
1865
2197
  readonly completed_at?: number;
1866
2198
  /** @description The payment rail that was selected for this transaction */
1867
2199
  readonly destination_payment_rail?: components["schemas"]["PaymentCapability"];
1868
- /** @description Payment reference message for bank transfers (e.g. wire message, SWIFT or SEPA reference) */
2200
+ /** @description Payment reference message for bank transfers (e.g. wire message, SWIFT reference) */
1869
2201
  readonly payment_reference?: string | null;
1870
2202
  /**
1871
2203
  * @description Name of the destination bank
@@ -1897,13 +2229,48 @@ type components = {
1897
2229
  * @example BARCGB22XXX
1898
2230
  */
1899
2231
  readonly destination_bic?: string;
2232
+ /**
2233
+ * @description NACHA/Fedwire return code (e.g., R01) when the transaction was returned by the receiving bank.
2234
+ * @example R01
2235
+ */
2236
+ readonly return_code?: string;
2237
+ /**
2238
+ * @description Human-readable return reason provided by the receiving bank.
2239
+ * @example Insufficient Funds
2240
+ */
2241
+ readonly return_reason?: string;
2242
+ /**
2243
+ * @description Unix timestamp when the return was initiated.
2244
+ * @example 1234567890
2245
+ */
2246
+ readonly return_initiated_at?: number;
2247
+ /**
2248
+ * @description Unix timestamp deadline for return processing.
2249
+ * @example 1234567890
2250
+ */
2251
+ readonly return_deadline?: number;
2252
+ /**
2253
+ * @description Lead Bank ACH reversal reason when the originator reverses the transaction (e.g., duplicate, receiver_incorrect).
2254
+ * @example duplicate
2255
+ */
2256
+ readonly reversal_reason?: string;
2257
+ /**
2258
+ * @description Unix timestamp when the reversal was initiated.
2259
+ * @example 1234567890
2260
+ */
2261
+ readonly reversal_initiated_at?: number;
2262
+ /**
2263
+ * @description Display name of the customer associated with this transaction.
2264
+ * @example Acme Corp
2265
+ */
2266
+ readonly customer_name?: string;
1900
2267
  };
1901
2268
  /**
1902
2269
  * @description Status of a one-off transaction
1903
2270
  * @example pending
1904
2271
  * @enum {string}
1905
2272
  */
1906
- readonly OneOffTransactionStatus: "pending" | "processing" | "completed" | "failed" | "cancelled" | "reversed" | "pending_return" | "returned";
2273
+ readonly OneOffTransactionStatus: "pending" | "processing" | "completed" | "failed" | "cancelled" | "reversed" | "pending_return" | "returned" | "pending_reversal";
1907
2274
  readonly PaginatedOneOffTransactionResponse: components["schemas"]["PaginatedListResponse"] & {
1908
2275
  readonly data?: readonly components["schemas"]["OneOffTransaction"][];
1909
2276
  };
@@ -1963,6 +2330,11 @@ type components = {
1963
2330
  /** @description Transaction details representing a transfer of funds from a crypto wallet. */
1964
2331
  readonly WalletTransaction: {
1965
2332
  readonly id: components["schemas"]["KSUID"];
2333
+ /**
2334
+ * @description Discriminator field. Always "wallet" for wallet transactions. (enum property replaced by openapi-typescript)
2335
+ * @enum {string}
2336
+ */
2337
+ readonly resource_type: "wallet";
1966
2338
  readonly wallet_id: components["schemas"]["KSUID"];
1967
2339
  readonly network_id?: components["schemas"]["NetworkId"];
1968
2340
  /** @description The source address */
@@ -2009,7 +2381,13 @@ type components = {
2009
2381
  * @example Marc
2010
2382
  */
2011
2383
  readonly name: string;
2012
- /** @description The signer public key */
2384
+ /**
2385
+ * @description The signer public key. For KEY_TYPE_ES256 this must be a
2386
+ * base64-encoded X.509 SubjectPublicKeyInfo (PKIX) for an ECDSA
2387
+ * P-256 key. Both PEM-wrapped (with BEGIN/END PUBLIC KEY headers)
2388
+ * and raw DER encodings are accepted. For KEY_TYPE_WEBAUTHN this
2389
+ * must be a base64-encoded COSE public key.
2390
+ */
2013
2391
  readonly public_key: string;
2014
2392
  /**
2015
2393
  * @description Type of the key
@@ -2024,7 +2402,13 @@ type components = {
2024
2402
  * @example Marc
2025
2403
  */
2026
2404
  readonly name: string;
2027
- /** @description The signer public key */
2405
+ /**
2406
+ * @description The signer public key. For KEY_TYPE_ES256 this must be a
2407
+ * base64-encoded X.509 SubjectPublicKeyInfo (PKIX) for an ECDSA
2408
+ * P-256 key. Both PEM-wrapped (with BEGIN/END PUBLIC KEY headers)
2409
+ * and raw DER encodings are accepted. For KEY_TYPE_WEBAUTHN this
2410
+ * must be a base64-encoded COSE public key.
2411
+ */
2028
2412
  readonly public_key: string;
2029
2413
  /**
2030
2414
  * @description Type of the key
@@ -2046,6 +2430,11 @@ type components = {
2046
2430
  */
2047
2431
  readonly id: string;
2048
2432
  readonly client_id?: components["schemas"]["KSUID"];
2433
+ /**
2434
+ * @description ID of the signer group that governs mutations of this policy. Members of this group must endorse any add_policy_rule, update_policy_rule, remove_policy_rule, or delete_policy intent.
2435
+ * @example grp_2N4YkKpKu7M3mKpGYmF8kcJ8oZT
2436
+ */
2437
+ readonly signer_group_id?: string | null;
2049
2438
  /**
2050
2439
  * Format: int32
2051
2440
  * @description Version number of the policy (incremented on rule changes)
@@ -3186,6 +3575,11 @@ type components = {
3186
3575
  * ]
3187
3576
  */
3188
3577
  readonly source_of_wealth?: readonly ("investments" | "employment" | "court_settlement" | "lottery_winnings" | "retirement_income" | "savings" | "sale_of_assets" | "family_funds" | "gambling_winnings" | "gift" | "inheritance" | "insurance_claim" | "loan" | "redundancy_severance" | "benefits")[];
3578
+ /**
3579
+ * @description Social Security Number (only present for US persons, format XXX-XX-XXXX)
3580
+ * @example 123-45-6789
3581
+ */
3582
+ readonly ssn?: string;
3189
3583
  /**
3190
3584
  * @description Decision on this individual entity (if made)
3191
3585
  * @example approved
@@ -3548,14 +3942,25 @@ type components = {
3548
3942
  * @enum {string|null}
3549
3943
  */
3550
3944
  readonly application_decision?: "approved" | "declined" | "withdrawn" | null;
3945
+ /**
3946
+ * @description How the decision was reached: 'manual' for operator-driven decisions, 'auto' for automated approvals, 'override' reserved for future escalation. Null if no decision has been made.
3947
+ * @example manual
3948
+ * @enum {string|null}
3949
+ */
3950
+ readonly decision_method?: "manual" | "auto" | "override" | null;
3951
+ /**
3952
+ * @description Version identifier of the rule set that produced an automated decision. Null for manual decisions or when no decision has been made.
3953
+ * @example v1.2
3954
+ */
3955
+ readonly decision_rule_version?: string | null;
3551
3956
  /** @description The people/businesses being onboarded */
3552
- readonly entities: components["schemas"]["ApplicationEntities"];
3957
+ readonly entities?: components["schemas"]["ApplicationEntities"];
3553
3958
  /** @description Enhanced Due Diligence data (if provided) */
3554
3959
  readonly edd?: components["schemas"]["EDDResponse"];
3555
3960
  /** @description Attestations submitted for this application */
3556
3961
  readonly attestations?: components["schemas"]["AttestationData"];
3557
3962
  /** @description Validation state computed at retrieval time */
3558
- readonly validation: components["schemas"]["ApplicationValidation"];
3963
+ readonly validation?: components["schemas"]["ApplicationValidation"];
3559
3964
  /** @description Risk rating (only present for superadmin users) */
3560
3965
  readonly risk_rating?: components["schemas"]["RiskRating"];
3561
3966
  };
@@ -3664,11 +4069,6 @@ type components = {
3664
4069
  * ]
3665
4070
  */
3666
4071
  readonly top_customer_countries?: readonly string[];
3667
- /**
3668
- * @description Whether the business screens customers against sanctions lists
3669
- * @example true
3670
- */
3671
- readonly screens_customers_for_sanctions?: boolean;
3672
4072
  /**
3673
4073
  * @description Whether the business issues tokens
3674
4074
  * @example false
@@ -3779,6 +4179,32 @@ type components = {
3779
4179
  */
3780
4180
  readonly applicant_id: string;
3781
4181
  };
4182
+ /** @description Error response when a self-serve client lacks the credits required to perform an action. */
4183
+ readonly InsufficientCreditsError: {
4184
+ /**
4185
+ * @description Stable machine-readable error code.
4186
+ * @example insufficient_credits
4187
+ * @enum {string}
4188
+ */
4189
+ readonly error: "insufficient_credits";
4190
+ /**
4191
+ * @description Human-readable explanation including the required and current amounts.
4192
+ * @example Insufficient credits to submit this application. Required 2500 cents, balance 500 cents.
4193
+ */
4194
+ readonly message: string;
4195
+ /**
4196
+ * Format: int64
4197
+ * @description Amount of credits required to perform this action, in USD cents.
4198
+ * @example 2500
4199
+ */
4200
+ readonly required_cents: number;
4201
+ /**
4202
+ * Format: int64
4203
+ * @description Caller's current credit balance, in USD cents.
4204
+ * @example 500
4205
+ */
4206
+ readonly balance_cents: number;
4207
+ };
3782
4208
  /** @description Error response when application cannot be submitted because applicants are not ready */
3783
4209
  readonly ApplicationNotReadyError: {
3784
4210
  /**
@@ -3977,6 +4403,36 @@ type components = {
3977
4403
  readonly EndingBeforeParam: components["schemas"]["KSUID"];
3978
4404
  /** @description A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 20. */
3979
4405
  readonly LimitParam: number;
4406
+ /**
4407
+ * @description Sandbox-only. Sets the HTTP status code returned when the sandbox injects an error at the configured step (see `X-Sandbox-Error-Step`). Must be a valid HTTP status code in the range 100-599; values outside that range are ignored. Status codes >= 400 cause the request to short-circuit immediately with a structured error response.
4408
+ * Effective only on `https://api.platform.sandbox.dakota.xyz`. Ignored in production.
4409
+ */
4410
+ readonly SandboxErrorStatusHeader: number;
4411
+ /**
4412
+ * @description Sandbox-only. Sets the human-readable `message` field of the injected sandbox error response. Truncated values longer than 500 characters are ignored.
4413
+ * Effective only on `https://api.platform.sandbox.dakota.xyz`. Ignored in production.
4414
+ */
4415
+ readonly SandboxErrorMessageHeader: string;
4416
+ /**
4417
+ * @description Sandbox-only. Names the pipeline step at which the injected error fires. Pair with `X-Sandbox-Error-Status` and (optionally) `X-Sandbox-Error-Message` to drive a deterministic failure mode at a known point in the request lifecycle. Values longer than 100 characters are ignored.
4418
+ * Effective only on `https://api.platform.sandbox.dakota.xyz`. Ignored in production.
4419
+ */
4420
+ readonly SandboxErrorStepHeader: "transaction_processing" | "compliance_check" | "account_validation" | "provider_call" | "kyb_submission" | "kyb_approval" | "network_call";
4421
+ /**
4422
+ * @description Sandbox-only. Applies a preset failure or behavior mode for the request, selecting a coherent combination of error step, status, and message. The full set of scenarios is also exposed dynamically via `GET /sandbox/scenarios` along with descriptions and per-rail applicability.
4423
+ * Effective only on `https://api.platform.sandbox.dakota.xyz`. Ignored in production.
4424
+ */
4425
+ readonly SandboxScenarioHeader: "happy_path" | "delayed_settlement" | "insufficient_funds" | "compliance_block" | "invalid_account" | "provider_maintenance" | "network_congestion" | "kyb_manual_review" | "kyb_rejected" | "kyb_expired" | "network_timeout" | "intermittent_errors" | "account_frozen" | "document_expired" | "invalid_swift";
4426
+ /**
4427
+ * @description Sandbox-only. When `true`, asynchronous simulation flows complete immediately rather than progressing through their normal timed states. Useful for fast end-to-end test runs that do not need to exercise intermediate webhook events. Accepts `true`/`false` (also `1`/`0`, `yes`/`no`); other values are treated as `false`.
4428
+ * Effective only on `https://api.platform.sandbox.dakota.xyz`. Ignored in production.
4429
+ */
4430
+ readonly SandboxInstantCompletionHeader: boolean;
4431
+ /**
4432
+ * @description Sandbox-only. When `true`, prevents the default 5-second KYB auto-approval that the sandbox applies to newly created customers. Use this header (typically with `X-Sandbox-Scenario: kyb_manual_review` or `kyb_rejected`) to keep an application in `pending` so integrators can exercise manual-review and rejection flows. Accepts `true`/`false` (also `1`/`0`, `yes`/`no`); other values are treated as `false`.
4433
+ * Effective only on `https://api.platform.sandbox.dakota.xyz`. Ignored in production.
4434
+ */
4435
+ readonly SandboxSkipAutoApprovalHeader: boolean;
3980
4436
  };
3981
4437
  requestBodies: never;
3982
4438
  headers: never;
@@ -4014,6 +4470,30 @@ type CustomerCreateRequest = components['schemas']['CustomerCreateRequest'];
4014
4470
  type CustomerCreateResponse = components['schemas']['CustomerCreateResponse'];
4015
4471
  /** KYB status */
4016
4472
  type KybStatus = Customer['kyb_status'];
4473
+ /** Request to update the sub-client association for a customer */
4474
+ type UpdateCustomerSubClientRequest = components['schemas']['UpdateCustomerSubClientRequest'];
4475
+ /** Summary of a sub-client including the count of associated customers */
4476
+ type SubClientSummary = components['schemas']['SubClientSummary'];
4477
+ /** Request body for bulk-importing customers from Sumsub share tokens */
4478
+ interface BulkImportSumsubTokensRequest {
4479
+ /** List of Sumsub share tokens to import */
4480
+ tokens: string[];
4481
+ }
4482
+ /** Per-token outcome for a bulk Sumsub import */
4483
+ interface BulkImportSumsubTokensResult {
4484
+ name?: string;
4485
+ success?: boolean;
4486
+ customer_id?: string;
4487
+ application_id?: string;
4488
+ error?: string;
4489
+ }
4490
+ /** Response from bulk-importing customers from Sumsub share tokens */
4491
+ interface BulkImportSumsubTokensResponse {
4492
+ total?: number;
4493
+ succeeded?: number;
4494
+ failed?: number;
4495
+ results?: BulkImportSumsubTokensResult[];
4496
+ }
4017
4497
  /** Recipient response */
4018
4498
  type Recipient = components['schemas']['RecipientResponse'];
4019
4499
  /** Recipient creation request */
@@ -4123,6 +4603,36 @@ type AssociatedIndividualRequest = components['schemas']['IndividualRequest'];
4123
4603
  * This type is kept for forward compatibility if fields are added in the future.
4124
4604
  */
4125
4605
  type ApplicationSubmissionRequest = Record<string, unknown>;
4606
+ /** Response after updating business details */
4607
+ type BusinessDetailsResponse = components['schemas']['BusinessDetailsResponse'];
4608
+ /** Response after updating individual details */
4609
+ type IndividualDetailsResponse = components['schemas']['IndividualDetailsResponse'];
4610
+ /** Attestation submission request */
4611
+ type AttestationSubmitRequest = components['schemas']['AttestationSubmitRequest'];
4612
+ /** Attestation type */
4613
+ type AttestationType = components['schemas']['AttestationType'];
4614
+ /** EDD (Enhanced Due Diligence) request */
4615
+ type EDDRequest = components['schemas']['EDDRequest'];
4616
+ /** EDD response with application context */
4617
+ type EDDWithApplicationID = components['schemas']['EDDWithApplicationID'];
4618
+ /** Application document upload request (base64-encoded content) */
4619
+ type ApplicationDocumentUploadRequest = components['schemas']['ApplicationDocumentUploadRequest'];
4620
+ /** Application document upload URL request (presigned URL) */
4621
+ type ApplicationDocumentUploadUrlRequest = components['schemas']['ApplicationDocumentUploadUrlRequest'];
4622
+ /** Document upload response (contains document_id) */
4623
+ type DocumentUploadResponse = components['schemas']['DocumentUploadResponse'];
4624
+ /** Document upload URL response (contains upload_url and upload_id) */
4625
+ type DocumentUploadUrlResponse = components['schemas']['DocumentUploadUrlResponse'];
4626
+ /** Uploaded document metadata (used in list responses) */
4627
+ type UploadedDocumentMetadata = components['schemas']['UploadedDocumentMetadata'];
4628
+ /** Individual document upload request (base64-encoded content) */
4629
+ type IndividualDocumentUploadRequest = components['schemas']['IndividualDocumentUploadRequest'];
4630
+ /** Individual document upload URL request (presigned URL) */
4631
+ type IndividualDocumentUploadUrlRequest = components['schemas']['IndividualDocumentUploadUrlRequest'];
4632
+ /** Application document type */
4633
+ type ApplicationDocumentType = components['schemas']['ApplicationDocumentType'];
4634
+ /** Individual document type */
4635
+ type IndividualDocumentType = components['schemas']['IndividualDocumentType'];
4126
4636
  /** Policy */
4127
4637
  type Policy = components['schemas']['Policy'];
4128
4638
  /** Policy creation request */
@@ -4159,6 +4669,44 @@ type WebhookTargetCreateRequest = components['schemas']['WebhookTargetCreateRequ
4159
4669
  type WebhookTargetUpdateRequest = components['schemas']['WebhookTargetUpdateRequest'];
4160
4670
  /** Webhook event */
4161
4671
  type WebhookEvent = components['schemas']['WebhookDelivery'];
4672
+ /** Webhook history list response (cursor-based pagination) */
4673
+ type WebhookHistoryList = components['schemas']['WebhookHistoryList'];
4674
+ /** Webhook replay response */
4675
+ type WebhookReplayResponse = components['schemas']['WebhookReplayResponse'];
4676
+ /** API key creation request for a specific client (admin only) */
4677
+ type CreateApiKeyForClientRequest = components['schemas']['CreateApiKeyForClientRequest'];
4678
+ /**
4679
+ * Webhook history list parameters.
4680
+ *
4681
+ * Uses cursor-based pagination (not starting_after/has_more_after).
4682
+ */
4683
+ interface WebhookHistoryListParams {
4684
+ /** Filter by delivery status */
4685
+ status?: 'delivered' | 'failed' | 'pending';
4686
+ /** Filter by event type (e.g. `transaction.completed`) */
4687
+ event_type?: string;
4688
+ /** Filter to deliveries that originated from a sandbox simulation */
4689
+ simulation_id?: string;
4690
+ /** Return only records created at or after this timestamp (ISO 8601) */
4691
+ from?: string;
4692
+ /** Return only records created at or before this timestamp (ISO 8601) */
4693
+ to?: string;
4694
+ /** Maximum number of records to return per page (1-100, default 20) */
4695
+ limit?: number;
4696
+ /** Pagination cursor (event_id of the last item from the previous page) */
4697
+ cursor?: string;
4698
+ }
4699
+ /**
4700
+ * Webhook history response.
4701
+ *
4702
+ * Uses cursor-based pagination with `has_more` and `cursor` instead of the
4703
+ * standard `meta.has_more_after` format.
4704
+ */
4705
+ interface WebhookHistoryResponse {
4706
+ data: WebhookEvent[];
4707
+ has_more: boolean;
4708
+ cursor?: string | null;
4709
+ }
4162
4710
  /** Country info */
4163
4711
  type Country = components['schemas']['Country'];
4164
4712
  /** Network info - generic structure for network responses */
@@ -4282,10 +4830,11 @@ interface SimulateOnboardingResponse {
4282
4830
  /**
4283
4831
  * Onboarding simulation types.
4284
4832
  *
4285
- * - `kyb_approve` - Approve a KYB application
4833
+ * - `kyb_approve` - Fully approve any customer (individual or business). Triggers the complete
4834
+ * onboarding flow including endorsement and recipient creation.
4286
4835
  * - `kyb_reject` - Reject a KYB application
4287
4836
  * - `kyb_info_request` - Request additional information for KYB
4288
- * - `kyc_approve` - Approve a KYC check
4837
+ * - `kyc_approve` - Approve an individual applicant's KYC application status only (no endorsement/recipient)
4289
4838
  * - `kyc_reject` - Reject a KYC check
4290
4839
  * - `kyc_info_request` - Request additional information for KYC
4291
4840
  * - `applicant_activate` - Activate an applicant (triggers provisioning)
@@ -4413,6 +4962,40 @@ interface SimulationInspection {
4413
4962
  }
4414
4963
  /** Sandbox scenario */
4415
4964
  type SandboxScenario = components['schemas']['SandboxScenario'];
4965
+ /** Self-serve credits purchase request */
4966
+ type SelfServeCreditsPurchaseRequest = components['schemas']['SelfServeCreditsPurchaseRequest'];
4967
+ /** Self-serve credits purchase response (contains checkout URL) */
4968
+ type SelfServeCreditsPurchaseResponse = components['schemas']['SelfServeCreditsPurchaseResponse'];
4969
+ /** Self-serve credits balance response */
4970
+ type SelfServeCreditsBalanceResponse = components['schemas']['SelfServeCreditsBalanceResponse'];
4971
+ /** Self-serve credits ledger entry */
4972
+ type SelfServeCreditsLedgerEntry = components['schemas']['SelfServeCreditsLedgerEntry'];
4973
+ /** Self-serve credits ledger response */
4974
+ type SelfServeCreditsLedgerResponse = components['schemas']['SelfServeCreditsLedgerResponse'];
4975
+ /** Self-serve credit tier */
4976
+ type SelfServeCreditTier = components['schemas']['SelfServeCreditTier'];
4977
+ /** Self-serve credit tiers response */
4978
+ type SelfServeCreditTiersResponse = components['schemas']['SelfServeCreditTiersResponse'];
4979
+ /** Self-serve client pricing configuration (fee schedule) */
4980
+ type ClientPricingConfig = components['schemas']['ClientPricingConfig'];
4981
+ /**
4982
+ * Self-serve credits pricing response.
4983
+ *
4984
+ * Returned by `GET /self-serve/credits/pricing` — the caller's current
4985
+ * `ClientPricingConfig` (transfer/ACH/wire/SEPA/SWIFT/KYC/KYB fees + monthly minimum).
4986
+ */
4987
+ type SelfServeCreditsPricingResponse = ClientPricingConfig;
4988
+ /** Ledger entry type filter */
4989
+ type SelfServeCreditsLedgerEntryType = SelfServeCreditsLedgerEntry['entry_type'];
4990
+ /** Parameters for listing self-serve credits ledger entries */
4991
+ interface SelfServeCreditsLedgerParams {
4992
+ /** Cursor for pagination (ISO 8601 datetime) */
4993
+ cursor?: string;
4994
+ /** Number of entries to return (1-100, default 20) */
4995
+ limit?: number;
4996
+ /** Filter by entry type */
4997
+ type?: SelfServeCreditsLedgerEntryType;
4998
+ }
4416
4999
  /**
4417
5000
  * Options for API requests.
4418
5001
  *
@@ -4455,12 +5038,19 @@ interface CustomerListParams extends ListParams {
4455
5038
  external_id?: string;
4456
5039
  search?: string;
4457
5040
  kyb_status?: KybStatus;
5041
+ sub_client_id?: string;
5042
+ is_sub_client?: boolean;
4458
5043
  }
4459
5044
  /** Transaction list parameters */
4460
5045
  interface TransactionListParams extends ListParams {
5046
+ /** Filter by resource family: one_off, wallet, auto_account */
5047
+ transaction_type?: 'one_off' | 'wallet' | 'auto_account';
4461
5048
  customer_id?: string;
4462
- account_id?: string;
5049
+ destination_id?: string;
4463
5050
  status?: TransactionStatus;
5051
+ source_network_id?: string;
5052
+ source_asset?: string;
5053
+ destination_asset?: string;
4464
5054
  }
4465
5055
  /** Event list parameters */
4466
5056
  interface EventListParams extends ListParams {
@@ -4538,6 +5128,68 @@ declare class CustomersResource extends BaseResource {
4538
5128
  * ```
4539
5129
  */
4540
5130
  get(customerId: string): Promise<Customer>;
5131
+ /**
5132
+ * Update the sub-client association for a customer.
5133
+ *
5134
+ * Associates or disassociates a customer with a sub-client.
5135
+ * Set `sub_client_id` to associate, or set it to `null` to disassociate.
5136
+ *
5137
+ * @param customerId - Customer ID (KSUID)
5138
+ * @param data - Sub-client association data
5139
+ * @param options - Request options (e.g., custom idempotency key)
5140
+ * @returns Updated customer record
5141
+ *
5142
+ * @example
5143
+ * ```typescript
5144
+ * // Associate customer with a sub-client
5145
+ * const customer = await client.customers.updateSubClient('cust_abc123', {
5146
+ * sub_client_id: 'cust_sub456',
5147
+ * });
5148
+ *
5149
+ * // Disassociate customer from sub-client
5150
+ * const customer = await client.customers.updateSubClient('cust_abc123', {
5151
+ * sub_client_id: null,
5152
+ * });
5153
+ * ```
5154
+ */
5155
+ updateSubClient(customerId: string, data: UpdateCustomerSubClientRequest, options?: RequestOptions): Promise<Customer>;
5156
+ /**
5157
+ * Get a summary of all sub-clients and their associated customer counts.
5158
+ *
5159
+ * @returns Array of sub-client summaries
5160
+ *
5161
+ * @example
5162
+ * ```typescript
5163
+ * const summaries = await client.customers.getSubClientSummary();
5164
+ * for (const summary of summaries) {
5165
+ * console.log(`${summary.sub_client_name}: ${summary.customer_count} customers`);
5166
+ * }
5167
+ * ```
5168
+ */
5169
+ getSubClientSummary(): Promise<SubClientSummary[]>;
5170
+ /**
5171
+ * Bulk-import customers from Sumsub share tokens.
5172
+ *
5173
+ * Exchanges one or more Sumsub share tokens for Dakota customers + applications.
5174
+ * The response surfaces per-token results — individual tokens can fail while
5175
+ * others succeed.
5176
+ *
5177
+ * @param data - Bulk-import request containing the share tokens to redeem
5178
+ * @param options - Request options (e.g., custom idempotency key)
5179
+ * @returns Bulk-import summary with per-token results
5180
+ *
5181
+ * @example
5182
+ * ```typescript
5183
+ * const result = await client.customers.bulkImportFromSumsubTokens({
5184
+ * tokens: ['_act-sbx-jwt-...', '_act-sbx-jwt-...'],
5185
+ * });
5186
+ * console.log(`Imported ${result.succeeded}/${result.total}`);
5187
+ * for (const r of result.results ?? []) {
5188
+ * if (!r.success) console.error(r.name, r.error);
5189
+ * }
5190
+ * ```
5191
+ */
5192
+ bulkImportFromSumsubTokens(data: BulkImportSumsubTokensRequest, options?: RequestOptions): Promise<BulkImportSumsubTokensResponse>;
4541
5193
  }
4542
5194
 
4543
5195
  /**
@@ -4607,6 +5259,17 @@ declare class RecipientsResource extends BaseResource {
4607
5259
  * ```
4608
5260
  */
4609
5261
  update(recipientId: string, data: RecipientUpdateRequest, options?: RequestOptions): Promise<Recipient>;
5262
+ /**
5263
+ * Delete a recipient.
5264
+ *
5265
+ * @param recipientId - Recipient ID
5266
+ *
5267
+ * @example
5268
+ * ```typescript
5269
+ * await client.recipients.delete(recipientId);
5270
+ * ```
5271
+ */
5272
+ delete(recipientId: string): Promise<void>;
4610
5273
  }
4611
5274
 
4612
5275
  /**
@@ -4662,6 +5325,18 @@ declare class DestinationsResource extends BaseResource {
4662
5325
  * ```
4663
5326
  */
4664
5327
  list(recipientId: string, params?: ListParams): PaginatedIterator<Destination>;
5328
+ /**
5329
+ * Delete a destination.
5330
+ *
5331
+ * @param recipientId - Recipient ID
5332
+ * @param destinationId - Destination ID
5333
+ *
5334
+ * @example
5335
+ * ```typescript
5336
+ * await client.destinations.delete(recipientId, destinationId);
5337
+ * ```
5338
+ */
5339
+ delete(recipientId: string, destinationId: string): Promise<void>;
4665
5340
  }
4666
5341
 
4667
5342
  /**
@@ -4670,8 +5345,14 @@ declare class DestinationsResource extends BaseResource {
4670
5345
 
4671
5346
  /** Account list parameters */
4672
5347
  interface AccountListParams extends ListParams {
5348
+ /** Account type filter. Required by the API. */
5349
+ account_type: 'onramp' | 'offramp' | 'swap';
4673
5350
  customer_id?: string;
4674
- account_type?: 'onramp' | 'offramp' | 'swap';
5351
+ source_network_id?: string;
5352
+ destination_network_id?: string;
5353
+ destination_asset?: string;
5354
+ crypto_destination_id?: string;
5355
+ fiat_destination_id?: string;
4675
5356
  }
4676
5357
  /**
4677
5358
  * Accounts API resource.
@@ -4761,6 +5442,17 @@ declare class AccountsResource extends BaseResource {
4761
5442
  * ```
4762
5443
  */
4763
5444
  update(accountId: string, data: AccountUpdateRequest, options?: RequestOptions): Promise<Account>;
5445
+ /**
5446
+ * Delete an account.
5447
+ *
5448
+ * @param accountId - Account ID
5449
+ *
5450
+ * @example
5451
+ * ```typescript
5452
+ * await client.accounts.delete(accountId);
5453
+ * ```
5454
+ */
5455
+ delete(accountId: string): Promise<void>;
4764
5456
  }
4765
5457
 
4766
5458
  /**
@@ -4966,24 +5658,17 @@ declare class EventsResource extends BaseResource {
4966
5658
  * ```
4967
5659
  */
4968
5660
  list(params?: EventListParams): PaginatedIterator<Event>;
4969
- /**
4970
- * Get an event by ID.
4971
- *
4972
- * @param eventId - Event ID
4973
- * @returns Event record
4974
- *
4975
- * @example
4976
- * ```typescript
4977
- * const event = await client.events.get(eventId);
4978
- * ```
4979
- */
4980
- get(eventId: string): Promise<Event>;
4981
5661
  }
4982
5662
 
4983
5663
  /**
4984
5664
  * Applications resource (Onboarding/KYB).
4985
5665
  */
4986
5666
 
5667
+ /** Parameters for listing application documents */
5668
+ interface DocumentListParams extends ListParams {
5669
+ category?: 'business' | 'identity' | 'edd';
5670
+ document_type?: string;
5671
+ }
4987
5672
  /**
4988
5673
  * Applications API resource for KYB onboarding.
4989
5674
  */
@@ -5011,38 +5696,45 @@ declare class ApplicationsResource extends BaseResource {
5011
5696
  */
5012
5697
  submit(applicationId: string, data?: ApplicationSubmissionRequest, options?: RequestOptions): Promise<Application>;
5013
5698
  /**
5014
- * List associated individuals for an application.
5699
+ * Update business details for an application.
5700
+ *
5701
+ * Uses PUT (full replace) per the OpenAPI spec.
5015
5702
  *
5016
5703
  * @param applicationId - Application ID
5017
- * @param params - Pagination parameters
5018
- * @returns Async iterator of individuals
5704
+ * @param data - Business details (full BusinessApplicationCreateRequest)
5705
+ * @returns Updated business details with application context
5019
5706
  */
5020
- listIndividuals(applicationId: string, params?: ListParams): PaginatedIterator<AssociatedIndividual>;
5707
+ updateBusinessDetails(applicationId: string, data: BusinessApplicationCreateRequest, options?: RequestOptions): Promise<BusinessDetailsResponse>;
5021
5708
  /**
5022
- * Add an associated individual to an application.
5709
+ * Update individual details for a non-business application.
5710
+ *
5711
+ * Uses PUT (full replace) per the OpenAPI spec. Only callable when the
5712
+ * application status is 'pending'.
5023
5713
  *
5024
5714
  * @param applicationId - Application ID
5025
- * @param data - Individual data
5026
- * @returns Created individual
5715
+ * @param data - Individual details (full IndividualRequest)
5716
+ * @returns Updated individual details with application context
5027
5717
  */
5028
- addIndividual(applicationId: string, data: AssociatedIndividualRequest, options?: RequestOptions): Promise<AssociatedIndividual>;
5718
+ updateIndividualDetails(applicationId: string, data: IndividualRequest, options?: RequestOptions): Promise<IndividualDetailsResponse>;
5029
5719
  /**
5030
- * Get an associated individual.
5720
+ * Add an associated individual to an application.
5031
5721
  *
5032
5722
  * @param applicationId - Application ID
5033
- * @param individualId - Individual ID
5034
- * @returns Individual record
5723
+ * @param data - Individual data
5724
+ * @returns Created individual
5035
5725
  */
5036
- getIndividual(applicationId: string, individualId: string): Promise<AssociatedIndividual>;
5726
+ addIndividual(applicationId: string, data: AssociatedIndividualRequest, options?: RequestOptions): Promise<AssociatedIndividual>;
5037
5727
  /**
5038
5728
  * Update an associated individual.
5039
5729
  *
5730
+ * Uses PUT (full replace) per the OpenAPI spec.
5731
+ *
5040
5732
  * @param applicationId - Application ID
5041
5733
  * @param individualId - Individual ID
5042
- * @param data - Update data
5734
+ * @param data - Full individual data (replaces existing)
5043
5735
  * @returns Updated individual
5044
5736
  */
5045
- updateIndividual(applicationId: string, individualId: string, data: Partial<AssociatedIndividualRequest>, options?: RequestOptions): Promise<AssociatedIndividual>;
5737
+ updateIndividual(applicationId: string, individualId: string, data: AssociatedIndividualRequest, options?: RequestOptions): Promise<AssociatedIndividual>;
5046
5738
  /**
5047
5739
  * Delete an associated individual.
5048
5740
  *
@@ -5051,27 +5743,114 @@ declare class ApplicationsResource extends BaseResource {
5051
5743
  */
5052
5744
  deleteIndividual(applicationId: string, individualId: string): Promise<void>;
5053
5745
  /**
5054
- * Update business details for an application.
5746
+ * Submit an attestation for an application.
5747
+ *
5748
+ * @param applicationId - Application ID
5749
+ * @param data - Attestation data (type, timestamp, applicant_id)
5750
+ */
5751
+ submitAttestation(applicationId: string, data: AttestationSubmitRequest, options?: RequestOptions): Promise<void>;
5752
+ /**
5753
+ * Get the EDD record for an application.
5055
5754
  *
5056
5755
  * @param applicationId - Application ID
5057
- * @param data - Business details
5058
- * @returns Updated application
5756
+ * @returns EDD record with application context
5059
5757
  */
5060
- updateBusinessDetails(applicationId: string, data: Record<string, unknown>, options?: RequestOptions): Promise<Application>;
5758
+ getEDD(applicationId: string): Promise<EDDWithApplicationID>;
5061
5759
  /**
5062
- * Get document upload URL for an application.
5760
+ * Create or update the EDD record for an application.
5761
+ *
5762
+ * This endpoint is idempotent (uses PUT).
5763
+ *
5764
+ * @param applicationId - Application ID
5765
+ * @param data - EDD data
5766
+ * @returns Updated EDD record with application context
5767
+ */
5768
+ createOrUpdateEDD(applicationId: string, data: EDDRequest, options?: RequestOptions): Promise<EDDWithApplicationID>;
5769
+ /**
5770
+ * Upload an application document using base64-encoded content.
5771
+ *
5772
+ * For files larger than 20MB, use {@link getDocumentUploadUrl} and upload
5773
+ * directly to cloud storage, then call {@link verifyDocument}.
5774
+ *
5775
+ * @param applicationId - Application ID
5776
+ * @param data - Document data including base64 content
5777
+ * @returns Document upload response with document_id
5778
+ */
5779
+ createDocument(applicationId: string, data: ApplicationDocumentUploadRequest, options?: RequestOptions): Promise<DocumentUploadResponse>;
5780
+ /**
5781
+ * List documents for an application.
5782
+ *
5783
+ * Supports filtering by category and document type.
5063
5784
  *
5064
5785
  * @param applicationId - Application ID
5786
+ * @param params - Pagination and filter parameters
5787
+ * @returns Paginated iterator of document metadata
5788
+ */
5789
+ listDocuments(applicationId: string, params?: DocumentListParams): PaginatedIterator<UploadedDocumentMetadata>;
5790
+ /**
5791
+ * Download/get a document by ID.
5792
+ *
5793
+ * @param applicationId - Application ID
5794
+ * @param documentId - Document ID
5795
+ * @returns Document content (binary)
5796
+ */
5797
+ getDocument(applicationId: string, documentId: string): Promise<unknown>;
5798
+ /**
5799
+ * Delete a document from a pending application.
5800
+ *
5801
+ * Only documents from applications in 'pending' status can be deleted.
5802
+ *
5803
+ * @param applicationId - Application ID
5804
+ * @param documentId - Document ID
5805
+ */
5806
+ deleteDocument(applicationId: string, documentId: string): Promise<void>;
5807
+ /**
5808
+ * Verify a document uploaded via presigned URL.
5809
+ *
5810
+ * After uploading a file to the presigned URL from {@link getDocumentUploadUrl},
5811
+ * call this endpoint to register and verify the upload.
5812
+ *
5813
+ * @param applicationId - Application ID
5814
+ * @param documentId - The upload_id from the presigned URL response
5815
+ * @returns Document upload response with document_id
5816
+ */
5817
+ verifyDocument(applicationId: string, documentId: string, _data?: Record<string, unknown>, options?: RequestOptions): Promise<DocumentUploadResponse>;
5818
+ /**
5819
+ * Get a presigned upload URL for an application document.
5820
+ *
5821
+ * Use this for files larger than 20MB. Upload the file directly to the
5822
+ * returned URL, then call {@link verifyDocument} to register it.
5823
+ *
5824
+ * @param applicationId - Application ID
5825
+ * @param data - Document metadata
5826
+ * @returns Upload URL and upload ID
5827
+ */
5828
+ getDocumentUploadUrl(applicationId: string, data: ApplicationDocumentUploadUrlRequest, options?: RequestOptions): Promise<DocumentUploadUrlResponse>;
5829
+ /**
5830
+ * Upload a document for an associated individual using base64-encoded content.
5831
+ *
5832
+ * Supports identity documents (passport, driver's license, residence permit)
5833
+ * and EDD documents (bank statement, etc.). For files larger than 10MB, use
5834
+ * {@link getIndividualDocumentUploadUrl} instead.
5835
+ *
5836
+ * @param applicationId - Application ID
5837
+ * @param individualId - Individual ID
5838
+ * @param data - Document data including base64 content
5839
+ * @returns Document upload response with document_id
5840
+ */
5841
+ uploadIndividualDocument(applicationId: string, individualId: string, data: IndividualDocumentUploadRequest, options?: RequestOptions): Promise<DocumentUploadResponse>;
5842
+ /**
5843
+ * Get a presigned upload URL for an individual document.
5844
+ *
5845
+ * Use this for files larger than 10MB. Upload the file directly to the
5846
+ * returned URL.
5847
+ *
5848
+ * @param applicationId - Application ID
5849
+ * @param individualId - Individual ID
5065
5850
  * @param data - Document metadata
5066
- * @returns Upload URL and document ID
5851
+ * @returns Upload URL and upload ID
5067
5852
  */
5068
- getDocumentUploadUrl(applicationId: string, data: {
5069
- document_type: string;
5070
- file_name: string;
5071
- }, options?: RequestOptions): Promise<{
5072
- upload_url: string;
5073
- document_id: string;
5074
- }>;
5853
+ getIndividualDocumentUploadUrl(applicationId: string, individualId: string, data: IndividualDocumentUploadUrlRequest, options?: RequestOptions): Promise<DocumentUploadUrlResponse>;
5075
5854
  }
5076
5855
 
5077
5856
  /**
@@ -5207,25 +5986,27 @@ declare class SignerGroupsResource extends BaseResource {
5207
5986
  * @param signerGroupId - Signer group ID
5208
5987
  */
5209
5988
  detachFromWallet(walletId: string, signerGroupId: string): Promise<void>;
5989
+ /**
5990
+ * List signer groups attached to a wallet.
5991
+ *
5992
+ * @param walletId - Wallet ID
5993
+ * @param params - Pagination parameters
5994
+ * @returns Async iterator of signer groups
5995
+ */
5996
+ listForWallet(walletId: string, params?: ListParams): PaginatedIterator<SignerGroup>;
5210
5997
  }
5211
5998
  /**
5212
5999
  * Signers API resource.
5213
6000
  */
5214
6001
  declare class SignersResource extends BaseResource {
5215
6002
  /**
5216
- * List all signers.
6003
+ * Create a new signer.
5217
6004
  *
5218
- * @param params - Pagination parameters
5219
- * @returns Async iterator of signers
5220
- */
5221
- list(params?: ListParams): PaginatedIterator<Signer>;
5222
- /**
5223
- * Get a signer by public key.
5224
- *
5225
- * @param publicKey - Signer public key
5226
- * @returns Signer record
6005
+ * @param data - Signer creation data (name, public_key, key_type)
6006
+ * @param options - Request options
6007
+ * @returns Created signer
5227
6008
  */
5228
- getByPublicKey(publicKey: string): Promise<Signer>;
6009
+ create(data: SignerCreateRequest, options?: RequestOptions): Promise<Signer>;
5229
6010
  /**
5230
6011
  * Delete a signer by public key.
5231
6012
  *
@@ -5250,9 +6031,7 @@ declare class ApiKeysResource extends BaseResource {
5250
6031
  * @param data - API key creation data
5251
6032
  * @returns Created API key (includes secret, only shown once)
5252
6033
  */
5253
- create(data: ApiKeyCreateRequest, options?: RequestOptions): Promise<ApiKey & {
5254
- secret: string;
5255
- }>;
6034
+ create(data: ApiKeyCreateRequest, options?: RequestOptions): Promise<ApiKeyResponse>;
5256
6035
  /**
5257
6036
  * List API keys.
5258
6037
  *
@@ -5266,6 +6045,22 @@ declare class ApiKeysResource extends BaseResource {
5266
6045
  * @param apiKeyId - API key ID
5267
6046
  */
5268
6047
  delete(apiKeyId: string): Promise<void>;
6048
+ /**
6049
+ * Delete all API keys.
6050
+ *
6051
+ * Intended for incident response only.
6052
+ */
6053
+ deleteAll(): Promise<void>;
6054
+ /**
6055
+ * Create an API key for a specific client (admin only).
6056
+ *
6057
+ * Requires admin access token.
6058
+ *
6059
+ * @param data - Request data containing `client_id`
6060
+ * @param options - Request options
6061
+ * @returns Created API key response (includes key, only shown once)
6062
+ */
6063
+ createForClient(data: CreateApiKeyForClientRequest, options?: RequestOptions): Promise<ApiKeyResponse>;
5269
6064
  }
5270
6065
 
5271
6066
  /**
@@ -5290,21 +6085,13 @@ declare class UsersResource extends BaseResource {
5290
6085
  * @returns Async iterator of users
5291
6086
  */
5292
6087
  list(params?: ListParams): PaginatedIterator<User>;
5293
- /**
5294
- * Get a user by ID.
5295
- *
5296
- * @param userId - User ID
5297
- * @returns User record
5298
- */
5299
- get(userId: string): Promise<User>;
5300
6088
  /**
5301
6089
  * Update a user.
5302
6090
  *
5303
6091
  * @param userId - User ID
5304
- * @param data - Update data
5305
- * @returns Updated user
6092
+ * @param data - Update data (first_name, last_name, role)
5306
6093
  */
5307
- update(userId: string, data: UserUpdateRequest, options?: RequestOptions): Promise<User>;
6094
+ update(userId: string, data: UserUpdateRequest, options?: RequestOptions): Promise<void>;
5308
6095
  /**
5309
6096
  * Delete a user.
5310
6097
  *
@@ -5357,12 +6144,29 @@ declare class WebhooksResource extends BaseResource {
5357
6144
  */
5358
6145
  deleteTarget(targetId: string): Promise<void>;
5359
6146
  /**
5360
- * List webhook events.
6147
+ * List webhook delivery history.
5361
6148
  *
5362
- * @param params - Pagination parameters
5363
- * @returns Async iterator of webhook events
6149
+ * Note: This endpoint uses cursor-based pagination (`cursor`/`has_more`) instead
6150
+ * of the standard `starting_after`/`has_more_after` format. Because of this,
6151
+ * it returns the raw response rather than a `PaginatedIterator`. Use the `cursor`
6152
+ * field from the response to fetch subsequent pages.
6153
+ *
6154
+ * @param params - Webhook history query parameters
6155
+ * @returns Webhook history response with `data`, `has_more`, and `cursor`
6156
+ *
6157
+ * @example
6158
+ * ```typescript
6159
+ * let cursor: string | undefined;
6160
+ * do {
6161
+ * const page = await client.webhooks.listEvents({ limit: 50, cursor });
6162
+ * for (const event of page.data) {
6163
+ * console.log(event);
6164
+ * }
6165
+ * cursor = page.cursor ?? undefined;
6166
+ * } while (page.has_more);
6167
+ * ```
5364
6168
  */
5365
- listEvents(params?: ListParams): PaginatedIterator<WebhookEvent>;
6169
+ listEvents(params?: WebhookHistoryListParams): Promise<WebhookHistoryResponse>;
5366
6170
  /**
5367
6171
  * Get a webhook event by ID.
5368
6172
  *
@@ -5373,9 +6177,13 @@ declare class WebhooksResource extends BaseResource {
5373
6177
  /**
5374
6178
  * Replay a webhook event.
5375
6179
  *
6180
+ * Re-queues the webhook for delivery to all configured targets.
6181
+ *
5376
6182
  * @param eventId - Webhook event ID
6183
+ * @param options - Request options
6184
+ * @returns Replay response with `webhook_id`, `status`, and `replayed_to_count`
5377
6185
  */
5378
- replayEvent(eventId: string, options?: RequestOptions): Promise<void>;
6186
+ replayEvent(eventId: string, options?: RequestOptions): Promise<WebhookReplayResponse>;
5379
6187
  }
5380
6188
 
5381
6189
  /**
@@ -5520,9 +6328,10 @@ declare class SandboxResource extends BaseResource {
5520
6328
  * Drives KYB, KYC, or applicant account status through a sandbox transition
5521
6329
  * without waiting for real compliance review.
5522
6330
  *
5523
- * **Important:** For full activation, you typically need TWO calls:
5524
- * 1. `kyb_approve` - Approves the KYB application
5525
- * 2. `applicant_activate` - Activates the applicant (triggers provisioning)
6331
+ * **Important:** Use `kyb_approve` to fully approve any customer type (individual or
6332
+ * business). This triggers the complete onboarding flow including endorsement and
6333
+ * recipient creation. The `kyc_*` types only update the individual applicant's KYC
6334
+ * application status without triggering the full onboarding flow.
5526
6335
  *
5527
6336
  * @param data - Simulation request data
5528
6337
  * @returns Simulation response with previous and new state
@@ -5611,6 +6420,105 @@ declare class SandboxResource extends BaseResource {
5611
6420
  listScenarios(params?: ListParams): PaginatedIterator<SandboxScenario>;
5612
6421
  }
5613
6422
 
6423
+ /**
6424
+ * Self-Serve Credits resource for managing prepaid transfer credits.
6425
+ */
6426
+
6427
+ /**
6428
+ * Self-Serve Credits API resource.
6429
+ *
6430
+ * Manage prepaid credits for self-serve transfer capacity.
6431
+ */
6432
+ declare class SelfServeResource extends BaseResource {
6433
+ /**
6434
+ * Purchase self-serve credits.
6435
+ *
6436
+ * Creates a Stripe checkout session for purchasing credits at the specified tier.
6437
+ *
6438
+ * @param data - Purchase request with the tier price
6439
+ * @param options - Optional request options (e.g., idempotency key)
6440
+ * @returns Response containing the Stripe checkout URL
6441
+ *
6442
+ * @example
6443
+ * ```typescript
6444
+ * const { checkout_url } = await client.selfServe.purchaseCredits({
6445
+ * tier_price_cents: 10000,
6446
+ * });
6447
+ * // Redirect user to checkout_url
6448
+ * ```
6449
+ */
6450
+ purchaseCredits(data: SelfServeCreditsPurchaseRequest, options?: RequestOptions): Promise<SelfServeCreditsPurchaseResponse>;
6451
+ /**
6452
+ * Get current credits balance.
6453
+ *
6454
+ * @returns The current balance and transfer capacity in cents
6455
+ *
6456
+ * @example
6457
+ * ```typescript
6458
+ * const balance = await client.selfServe.getBalance();
6459
+ * console.log(`Balance: $${balance.balance_cents / 100}`);
6460
+ * console.log(`Transfer capacity: $${balance.transfer_capacity_cents / 100}`);
6461
+ * ```
6462
+ */
6463
+ getBalance(): Promise<SelfServeCreditsBalanceResponse>;
6464
+ /**
6465
+ * List credits ledger entries.
6466
+ *
6467
+ * Returns a cursor-paginated list of ledger entries (purchases, deductions, refunds).
6468
+ *
6469
+ * @param params - Optional query parameters for filtering and pagination
6470
+ * @returns Ledger response with entries and has_more flag
6471
+ *
6472
+ * @example
6473
+ * ```typescript
6474
+ * // Get recent ledger entries
6475
+ * const ledger = await client.selfServe.listLedger();
6476
+ * for (const entry of ledger.entries) {
6477
+ * console.log(entry.entry_type, entry.amount_cents, entry.description);
6478
+ * }
6479
+ *
6480
+ * // Filter by type with pagination
6481
+ * const purchases = await client.selfServe.listLedger({
6482
+ * type: 'purchase',
6483
+ * limit: 50,
6484
+ * });
6485
+ * ```
6486
+ */
6487
+ listLedger(params?: SelfServeCreditsLedgerParams): Promise<SelfServeCreditsLedgerResponse>;
6488
+ /**
6489
+ * List available credit tiers.
6490
+ *
6491
+ * Returns all available pricing tiers for purchasing credits.
6492
+ *
6493
+ * @returns Response containing the list of available tiers
6494
+ *
6495
+ * @example
6496
+ * ```typescript
6497
+ * const { tiers } = await client.selfServe.listTiers();
6498
+ * for (const tier of tiers) {
6499
+ * console.log(`$${tier.price_cents / 100} → $${tier.transfer_capacity_cents / 100} capacity`);
6500
+ * }
6501
+ * ```
6502
+ */
6503
+ listTiers(): Promise<SelfServeCreditTiersResponse>;
6504
+ /**
6505
+ * Get the self-serve client's pricing config (fee schedule).
6506
+ *
6507
+ * Returns the caller's current `ClientPricingConfig` — transfer/ACH/wire/SEPA/SWIFT/KYC/KYB
6508
+ * fees plus the monthly minimum. Self-serve clients only.
6509
+ *
6510
+ * @returns The current pricing configuration
6511
+ *
6512
+ * @example
6513
+ * ```typescript
6514
+ * const pricing = await client.selfServe.getPricing();
6515
+ * console.log(`ACH fee: ${pricing.achFeeCents} cents`);
6516
+ * console.log(`Wire fee: ${pricing.wireFeeCents} cents`);
6517
+ * ```
6518
+ */
6519
+ getPricing(): Promise<SelfServeCreditsPricingResponse>;
6520
+ }
6521
+
5614
6522
  /**
5615
6523
  * Dakota Platform API Client.
5616
6524
  */
@@ -5678,6 +6586,8 @@ declare class DakotaClient {
5678
6586
  readonly info: InfoResource;
5679
6587
  /** Sandbox API - testing simulations (sandbox only) */
5680
6588
  readonly sandbox: SandboxResource;
6589
+ /** Self-Serve Credits API - manage prepaid transfer credits */
6590
+ readonly selfServe: SelfServeResource;
5681
6591
  /**
5682
6592
  * Create a new Dakota client.
5683
6593
  *
@@ -5763,4 +6673,4 @@ declare class ConfigurationError extends Error {
5763
6673
  constructor(message: string);
5764
6674
  }
5765
6675
 
5766
- export { APIError, type Account, type AccountCreateRequest, type AccountListParams, type AccountUpdateRequest, AccountsResource, type Address, type AdvanceSimulationRequest, type AdvanceSimulationResult, type ApiKey, type ApiKeyCreateRequest, type ApiKeyResponse, ApiKeysResource, type Application, type ApplicationListItem, type ApplicationStatus, type ApplicationSubmissionRequest, ApplicationsResource, type AssociatedIndividual, type AssociatedIndividualRequest, AuthMode, type AutoTransaction, AutoTransactionsResource, type AverageMonthlyRevenue, type BusinessApplicationCreateRequest, type BusinessPurposeOfAccount, type BusinessSourceOfFunds, ConfigurationError, type Country, type CryptoDestination, type CryptoDestinationRequest, type CursorExtractor, type Customer, type CustomerCreateRequest, type CustomerCreateResponse, type CustomerListParams, CustomersResource, DEFAULT_RETRY_POLICY, DakotaClient, type DakotaClientConfig, type Destination, type DestinationRequest, DestinationsResource, type EmploymentStatus, Environment, type Event, type EventListParams, type EventType, EventsResource, type ExpectedMonthlyDeposit, type Family, type FiatUSDestination, type FiatUSDestinationRequest, type IndividualRequest, type IndividualRole, type IndividualTitle, InfoResource, type KSUID, type KybStatus, type LegalStructure, type ListParams, type Logger, type Meta, type Network, type NetworkId, type OfframpAccount, type OfframpAccountCreateRequest, type OneOffTransaction, type OneOffTransactionRequest, type OnrampAccount, type OnrampAccountCreateRequest, type PageFetcher, PaginatedIterator, type PaginatedResponse, type PaginationMeta, type PaginationParams, type PaymentCapability, type PersonName, PoliciesResource, type Policy, type PolicyCreateRequest, type PolicyRule, type PolicyRuleCreateRequest, type Recipient, type RecipientRequest, type RecipientUpdateRequest, RecipientsResource, type RequestOptions, type ResolvedConfig, type RetryPolicy, SandboxResource, type SandboxScenario, type Signer, type SignerCreateRequest, type SignerGroup, type SignerGroupCreateRequest, SignerGroupsResource, SignersResource, type SimulateInboundRequest, type SimulateInboundType, type SimulateOnboardingRequest, type SimulateOnboardingResponse, type SimulateOnboardingType, type SimulationCallbackRecord, type SimulationInspection, type SimulationResponse, type SwapAccount, type SwapAccountCreateRequest, type TransactionListParams, type TransactionStatus, TransactionsResource, TransportError, type User, type UserCreateRequest, type UserUpdateRequest, UsersResource, type Wallet, type WalletBalance, type WalletBalances, type WalletCreateRequest, type WalletTransaction, type WalletTransactionRequest, WalletsResource, type WebhookEvent, type WebhookTarget, type WebhookTargetCreateRequest, type WebhookTargetUpdateRequest, WebhooksResource, consoleLogger, getEnvironmentURL, noopLogger, paginate };
6676
+ export { APIError, type Account, type AccountCreateRequest, type AccountListParams, type AccountUpdateRequest, AccountsResource, type Address, type AdvanceSimulationRequest, type AdvanceSimulationResult, type ApiKey, type ApiKeyCreateRequest, type ApiKeyResponse, ApiKeysResource, type Application, type ApplicationDocumentType, type ApplicationDocumentUploadRequest, type ApplicationDocumentUploadUrlRequest, type ApplicationListItem, type ApplicationStatus, type ApplicationSubmissionRequest, ApplicationsResource, type AssociatedIndividual, type AssociatedIndividualRequest, type AttestationSubmitRequest, type AttestationType, AuthMode, type AutoTransaction, AutoTransactionsResource, type AverageMonthlyRevenue, type BulkImportSumsubTokensRequest, type BulkImportSumsubTokensResponse, type BulkImportSumsubTokensResult, type BusinessApplicationCreateRequest, type BusinessDetailsResponse, type BusinessPurposeOfAccount, type BusinessSourceOfFunds, type ClientPricingConfig, ConfigurationError, type Country, type CreateApiKeyForClientRequest, type CryptoDestination, type CryptoDestinationRequest, type CursorExtractor, type Customer, type CustomerCreateRequest, type CustomerCreateResponse, type CustomerListParams, CustomersResource, DEFAULT_RETRY_POLICY, DakotaClient, type DakotaClientConfig, type Destination, type DestinationRequest, DestinationsResource, type DocumentUploadResponse, type DocumentUploadUrlResponse, type EDDRequest, type EDDWithApplicationID, type EmploymentStatus, Environment, type Event, type EventListParams, type EventType, EventsResource, type ExpectedMonthlyDeposit, type Family, type FiatUSDestination, type FiatUSDestinationRequest, type IndividualDetailsResponse, type IndividualDocumentType, type IndividualDocumentUploadRequest, type IndividualDocumentUploadUrlRequest, type IndividualRequest, type IndividualRole, type IndividualTitle, InfoResource, type KSUID, type KybStatus, type LegalStructure, type ListParams, type Logger, type Meta, type Network, type NetworkId, type OfframpAccount, type OfframpAccountCreateRequest, type OneOffTransaction, type OneOffTransactionRequest, type OnrampAccount, type OnrampAccountCreateRequest, type PageFetcher, PaginatedIterator, type PaginatedResponse, type PaginationMeta, type PaginationParams, type PaymentCapability, type PersonName, PoliciesResource, type Policy, type PolicyCreateRequest, type PolicyRule, type PolicyRuleCreateRequest, type Recipient, type RecipientRequest, type RecipientUpdateRequest, RecipientsResource, type RequestOptions, type ResolvedConfig, type RetryPolicy, SandboxResource, type SandboxScenario, type SelfServeCreditTier, type SelfServeCreditTiersResponse, type SelfServeCreditsBalanceResponse, type SelfServeCreditsLedgerEntry, type SelfServeCreditsLedgerEntryType, type SelfServeCreditsLedgerParams, type SelfServeCreditsLedgerResponse, type SelfServeCreditsPricingResponse, type SelfServeCreditsPurchaseRequest, type SelfServeCreditsPurchaseResponse, SelfServeResource, type Signer, type SignerCreateRequest, type SignerGroup, type SignerGroupCreateRequest, SignerGroupsResource, SignersResource, type SimulateInboundRequest, type SimulateInboundType, type SimulateOnboardingRequest, type SimulateOnboardingResponse, type SimulateOnboardingType, type SimulationCallbackRecord, type SimulationInspection, type SimulationResponse, type SubClientSummary, type SwapAccount, type SwapAccountCreateRequest, type TransactionListParams, type TransactionStatus, TransactionsResource, TransportError, type UpdateCustomerSubClientRequest, type UploadedDocumentMetadata, type User, type UserCreateRequest, type UserUpdateRequest, UsersResource, type Wallet, type WalletBalance, type WalletBalances, type WalletCreateRequest, type WalletTransaction, type WalletTransactionRequest, WalletsResource, type WebhookEvent, type WebhookHistoryList, type WebhookHistoryListParams, type WebhookHistoryResponse, type WebhookReplayResponse, type WebhookTarget, type WebhookTargetCreateRequest, type WebhookTargetUpdateRequest, WebhooksResource, consoleLogger, getEnvironmentURL, noopLogger, paginate };