dutchman-bridge 1.0.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/README.md +212 -0
- package/dist/client/client.gen.d.ts +2 -0
- package/dist/client/client.gen.js +220 -0
- package/dist/client/index.d.ts +10 -0
- package/dist/client/index.js +17 -0
- package/dist/client/types.gen.d.ts +120 -0
- package/dist/client/types.gen.js +3 -0
- package/dist/client/utils.gen.d.ts +37 -0
- package/dist/client/utils.gen.js +241 -0
- package/dist/client.gen.d.ts +12 -0
- package/dist/client.gen.js +6 -0
- package/dist/core/auth.gen.d.ts +25 -0
- package/dist/core/auth.gen.js +18 -0
- package/dist/core/bodySerializer.gen.d.ts +25 -0
- package/dist/core/bodySerializer.gen.js +60 -0
- package/dist/core/params.gen.d.ts +43 -0
- package/dist/core/params.gen.js +112 -0
- package/dist/core/pathSerializer.gen.d.ts +33 -0
- package/dist/core/pathSerializer.gen.js +115 -0
- package/dist/core/queryKeySerializer.gen.d.ts +18 -0
- package/dist/core/queryKeySerializer.gen.js +98 -0
- package/dist/core/serverSentEvents.gen.d.ts +71 -0
- package/dist/core/serverSentEvents.gen.js +135 -0
- package/dist/core/types.gen.d.ts +83 -0
- package/dist/core/types.gen.js +3 -0
- package/dist/core/utils.gen.d.ts +19 -0
- package/dist/core/utils.gen.js +93 -0
- package/dist/index.d.ts +3 -0
- package/dist/index.js +20 -0
- package/dist/sdk.gen.d.ts +339 -0
- package/dist/sdk.gen.js +794 -0
- package/dist/types.gen.d.ts +1935 -0
- package/dist/types.gen.js +3 -0
- package/package.json +32 -0
- package/src/client/client.gen.ts +277 -0
- package/src/client/index.ts +27 -0
- package/src/client/types.gen.ts +218 -0
- package/src/client/utils.gen.ts +316 -0
- package/src/client.gen.ts +16 -0
- package/src/core/auth.gen.ts +48 -0
- package/src/core/bodySerializer.gen.ts +82 -0
- package/src/core/params.gen.ts +178 -0
- package/src/core/pathSerializer.gen.ts +171 -0
- package/src/core/queryKeySerializer.gen.ts +117 -0
- package/src/core/serverSentEvents.gen.ts +242 -0
- package/src/core/types.gen.ts +110 -0
- package/src/core/utils.gen.ts +140 -0
- package/src/index.ts +5 -0
- package/src/sdk.gen.ts +887 -0
- package/src/types.gen.ts +2178 -0
|
@@ -0,0 +1,339 @@
|
|
|
1
|
+
import { type Client, type ClientMeta, type Options as Options2, type RequestResult, type TDataShape } from './client';
|
|
2
|
+
import type { BankAddAccountData, BankAddAccountResponses, BankBanksData, BankBanksResponses, BankDeleteAccountData, BankDeleteAccountResponses, BankGetAccountsData, BankGetAccountsResponses, BankSetDefaultAccountData, BankSetDefaultAccountResponses, BankVerifyAccountData, BankVerifyAccountResponses, CountriesListData, CountriesListResponses, CustomersFullData, CustomersFullResponses, CustomersGetData, CustomersGetResponses, CustomersRegisterData, CustomersRegisterResponses, FeaturesListData, FeaturesListResponses, GlobalSendCorridorsData, GlobalSendCorridorsResponses, GlobalSendInitiateData, GlobalSendInitiateResponses, GlobalSendQuoteData, GlobalSendQuoteResponses, GlobalSendVerificationStatusData, GlobalSendVerificationStatusResponses, KycDocumentData, KycDocumentResponses, KycReverificationData, KycReverificationResponses, KycSelfieCheckRouteData, KycSelfieCheckRouteResponses, KycStatusData, KycStatusResponses, KycTier1Data, KycTier1Responses, KycTier2Data, KycTier2Responses, KycTier3Data, KycTier3Responses, ProfileChangePasswordData, ProfileChangePasswordResponses, ProfileDeleteAccountData, ProfileDeleteAccountResponses, ProfileGetSettlementModeData, ProfileGetSettlementModeResponses, ProfileProfileData, ProfileProfileResponses, ProfileSetSettlementModeData, ProfileSetSettlementModeResponses, ProfileUpdateProfileData, ProfileUpdateProfileResponses, ProfileWithdrawalsData, ProfileWithdrawalsResponses, RampBuyData, RampBuyQuoteData, RampBuyQuoteResponses, RampBuyResponses, RampRateData, RampRateResponses, RampSellData, RampSellNetworksData, RampSellNetworksResponses, RampSellQuoteData, RampSellQuoteResponses, RampSellResponses, ReceivingActivityData, ReceivingActivityResponses, ReceivingCurrenciesData, ReceivingCurrenciesResponses, ReceivingListData, ReceivingListResponses, ReceivingOpenData, ReceivingOpenResponses, ReceivingRefreshData, ReceivingRefreshResponses, SendNetworksData, SendNetworksResponses, SendQuoteData, SendQuoteResponses, SendSubmitData, SendSubmitResponses, WalletAddressesData, WalletAddressesResponses, WalletBalanceData, WalletBalanceResponses, WalletFundingChargesData, WalletFundingChargesResponses, WalletInitiateFundingChargeData, WalletInitiateFundingChargeResponses, WalletStreamBalanceData, WalletStreamBalanceResponses, WalletTransactionsData, WalletTransactionsResponses, WalletVirtualAccountForData, WalletVirtualAccountForResponses, WalletWithdrawData, WalletWithdrawResponses, WebhookConfigData, WebhookConfigResponses, WebhookDeliveriesData, WebhookDeliveriesResponses, WebhookDeliveryData, WebhookDeliveryResponses, WebhookReplayData, WebhookReplayResponses, WebhookRotateSecretData, WebhookRotateSecretResponses, WebhookSetUrlData, WebhookSetUrlResponses } from './types.gen';
|
|
3
|
+
export type Options<TData extends TDataShape = TDataShape, ThrowOnError extends boolean = boolean, TResponse = unknown> = Options2<TData, ThrowOnError, TResponse> & {
|
|
4
|
+
/**
|
|
5
|
+
* You can provide a client instance returned by `createClient()` instead of
|
|
6
|
+
* individual options. This might be also useful if you want to implement a
|
|
7
|
+
* custom client.
|
|
8
|
+
*/
|
|
9
|
+
client?: Client;
|
|
10
|
+
/**
|
|
11
|
+
* You can pass arbitrary values through the `meta` object. This can be
|
|
12
|
+
* used to access values that aren't defined as part of the SDK function.
|
|
13
|
+
*/
|
|
14
|
+
meta?: keyof ClientMeta extends never ? Record<string, unknown> : ClientMeta;
|
|
15
|
+
};
|
|
16
|
+
declare class HeyApiClient {
|
|
17
|
+
protected client: Client;
|
|
18
|
+
constructor(args?: {
|
|
19
|
+
client?: Client;
|
|
20
|
+
});
|
|
21
|
+
}
|
|
22
|
+
declare class HeyApiRegistry<T> {
|
|
23
|
+
private readonly defaultKey;
|
|
24
|
+
private readonly instances;
|
|
25
|
+
get(key?: string): T;
|
|
26
|
+
set(value: T, key?: string): void;
|
|
27
|
+
}
|
|
28
|
+
export declare class Customers extends HeyApiClient {
|
|
29
|
+
/**
|
|
30
|
+
* Register a customer under your account
|
|
31
|
+
*
|
|
32
|
+
* The customer never authenticates with Dutchman Bridge directly -- that's entirely yours to manage. This just attributes a new customer id to your account so every other Partner API call can reference it.
|
|
33
|
+
*/
|
|
34
|
+
register<ThrowOnError extends boolean = false>(options: Options<CustomersRegisterData, ThrowOnError>): RequestResult<CustomersRegisterResponses, unknown, ThrowOnError>;
|
|
35
|
+
/**
|
|
36
|
+
* Read one of your customer's profile
|
|
37
|
+
*/
|
|
38
|
+
get<ThrowOnError extends boolean = false>(options: Options<CustomersGetData, ThrowOnError>): RequestResult<CustomersGetResponses, unknown, ThrowOnError>;
|
|
39
|
+
/**
|
|
40
|
+
* A customer's full snapshot -- profile, KYC, and wallet -- in one call
|
|
41
|
+
*
|
|
42
|
+
* Replaces separately calling profile/kyc/wallet routes when you just need a customer's current state, e.g. right after registration or to reconcile after a webhook. Not a substitute for the wallet routes' live balance -- fetch this fresh rather than caching it indefinitely, since a crypto deposit or fiat funding event has no webhook of its own yet.
|
|
43
|
+
*/
|
|
44
|
+
full<ThrowOnError extends boolean = false>(options: Options<CustomersFullData, ThrowOnError>): RequestResult<CustomersFullResponses, unknown, ThrowOnError>;
|
|
45
|
+
}
|
|
46
|
+
export declare class Profile extends HeyApiClient {
|
|
47
|
+
/**
|
|
48
|
+
* Delete the customer's account
|
|
49
|
+
*
|
|
50
|
+
* Refused (409) while the customer still holds a balance or has a transfer in flight. Deleting twice is not an error.
|
|
51
|
+
*/
|
|
52
|
+
deleteAccount<ThrowOnError extends boolean = false>(options: Options<ProfileDeleteAccountData, ThrowOnError>): RequestResult<ProfileDeleteAccountResponses, unknown, ThrowOnError>;
|
|
53
|
+
/**
|
|
54
|
+
* The customer's profile
|
|
55
|
+
*/
|
|
56
|
+
profile<ThrowOnError extends boolean = false>(options: Options<ProfileProfileData, ThrowOnError>): RequestResult<ProfileProfileResponses, unknown, ThrowOnError>;
|
|
57
|
+
/**
|
|
58
|
+
* Update the customer's profile
|
|
59
|
+
*
|
|
60
|
+
* Identity fields can be filled in while empty; once KYC is approved they lock, and only an admin re-verification request reopens them.
|
|
61
|
+
*/
|
|
62
|
+
updateProfile<ThrowOnError extends boolean = false>(options: Options<ProfileUpdateProfileData, ThrowOnError>): RequestResult<ProfileUpdateProfileResponses, unknown, ThrowOnError>;
|
|
63
|
+
/**
|
|
64
|
+
* Change the customer's password
|
|
65
|
+
*/
|
|
66
|
+
changePassword<ThrowOnError extends boolean = false>(options: Options<ProfileChangePasswordData, ThrowOnError>): RequestResult<ProfileChangePasswordResponses, unknown, ThrowOnError>;
|
|
67
|
+
/**
|
|
68
|
+
* Read the customer's settlement preference (AUTO to default bank vs MANUAL hold)
|
|
69
|
+
*/
|
|
70
|
+
getSettlementMode<ThrowOnError extends boolean = false>(options: Options<ProfileGetSettlementModeData, ThrowOnError>): RequestResult<ProfileGetSettlementModeResponses, unknown, ThrowOnError>;
|
|
71
|
+
/**
|
|
72
|
+
* Update how the customer's sale proceeds settle
|
|
73
|
+
*/
|
|
74
|
+
setSettlementMode<ThrowOnError extends boolean = false>(options: Options<ProfileSetSettlementModeData, ThrowOnError>): RequestResult<ProfileSetSettlementModeResponses, unknown, ThrowOnError>;
|
|
75
|
+
/**
|
|
76
|
+
* The customer's withdrawal / global payout history, newest first
|
|
77
|
+
*/
|
|
78
|
+
withdrawals<ThrowOnError extends boolean = false>(options: Options<ProfileWithdrawalsData, ThrowOnError>): RequestResult<ProfileWithdrawalsResponses, unknown, ThrowOnError>;
|
|
79
|
+
}
|
|
80
|
+
export declare class Kyc extends HeyApiClient {
|
|
81
|
+
/**
|
|
82
|
+
* A customer's KYC records, newest first
|
|
83
|
+
*/
|
|
84
|
+
status<ThrowOnError extends boolean = false>(options: Options<KycStatusData, ThrowOnError>): RequestResult<KycStatusResponses, unknown, ThrowOnError>;
|
|
85
|
+
/**
|
|
86
|
+
* Any open re-verification request an admin has raised for the customer
|
|
87
|
+
*
|
|
88
|
+
* The items to re-provide plus the message, or null when there is nothing to re-verify.
|
|
89
|
+
*/
|
|
90
|
+
reverification<ThrowOnError extends boolean = false>(options: Options<KycReverificationData, ThrowOnError>): RequestResult<KycReverificationResponses, unknown, ThrowOnError>;
|
|
91
|
+
/**
|
|
92
|
+
* Submit Tier 1 (BVN + NIN)
|
|
93
|
+
*/
|
|
94
|
+
tier1<ThrowOnError extends boolean = false>(options: Options<KycTier1Data, ThrowOnError>): RequestResult<KycTier1Responses, unknown, ThrowOnError>;
|
|
95
|
+
/**
|
|
96
|
+
* Submit Tier 2 (ID document, from a prior /kyc/documents upload)
|
|
97
|
+
*/
|
|
98
|
+
tier2<ThrowOnError extends boolean = false>(options: Options<KycTier2Data, ThrowOnError>): RequestResult<KycTier2Responses, unknown, ThrowOnError>;
|
|
99
|
+
/**
|
|
100
|
+
* Submit Tier 3 (date of birth + address, for cross-border corridors)
|
|
101
|
+
*/
|
|
102
|
+
tier3<ThrowOnError extends boolean = false>(options: Options<KycTier3Data, ThrowOnError>): RequestResult<KycTier3Responses, unknown, ThrowOnError>;
|
|
103
|
+
/**
|
|
104
|
+
* Check a customer's selfie before submitting it
|
|
105
|
+
*
|
|
106
|
+
* Returns what to change -- too dark, blurry, sunglasses, more than one face -- so it can be retaken now rather than rejected by a reviewer days later. Advisory only: a submission is never blocked on this.
|
|
107
|
+
*/
|
|
108
|
+
selfieCheckRoute<ThrowOnError extends boolean = false>(options: Options<KycSelfieCheckRouteData, ThrowOnError>): RequestResult<KycSelfieCheckRouteResponses, unknown, ThrowOnError>;
|
|
109
|
+
/**
|
|
110
|
+
* Upload a customer's ID document or selfie ahead of Tier 2
|
|
111
|
+
*/
|
|
112
|
+
document<ThrowOnError extends boolean = false>(options: Options<KycDocumentData, ThrowOnError>): RequestResult<KycDocumentResponses, unknown, ThrowOnError>;
|
|
113
|
+
}
|
|
114
|
+
export declare class Wallet extends HeyApiClient {
|
|
115
|
+
/**
|
|
116
|
+
* USDT + local fiat balance
|
|
117
|
+
*/
|
|
118
|
+
balance<ThrowOnError extends boolean = false>(options: Options<WalletBalanceData, ThrowOnError>): RequestResult<WalletBalanceResponses, unknown, ThrowOnError>;
|
|
119
|
+
/**
|
|
120
|
+
* Live updates: re-emits the customer's balance on every credit/debit
|
|
121
|
+
*
|
|
122
|
+
* Mirrors Dutchman Bridge's own consumer /user/balance/stream, scoped to the customer instead of the caller's own JWT. Long-lived --keep the connection open rather than reconnecting per update.
|
|
123
|
+
*/
|
|
124
|
+
streamBalance<ThrowOnError extends boolean = false>(options: Options<WalletStreamBalanceData, ThrowOnError>): RequestResult<WalletStreamBalanceResponses, unknown, ThrowOnError>;
|
|
125
|
+
/**
|
|
126
|
+
* Recent balance movements, cursor-paginated
|
|
127
|
+
*/
|
|
128
|
+
transactions<ThrowOnError extends boolean = false>(options: Options<WalletTransactionsData, ThrowOnError>): RequestResult<WalletTransactionsResponses, unknown, ThrowOnError>;
|
|
129
|
+
/**
|
|
130
|
+
* The customer's per-network USDT deposit addresses
|
|
131
|
+
*/
|
|
132
|
+
addresses<ThrowOnError extends boolean = false>(options: Options<WalletAddressesData, ThrowOnError>): RequestResult<WalletAddressesResponses, unknown, ThrowOnError>;
|
|
133
|
+
/**
|
|
134
|
+
* Local-currency virtual account for fiat funding
|
|
135
|
+
*
|
|
136
|
+
* Issued on first read in the customer's own fiat (NGN needs an approved BVN first); the same account is returned on every read after.
|
|
137
|
+
*/
|
|
138
|
+
virtualAccountFor<ThrowOnError extends boolean = false>(options: Options<WalletVirtualAccountForData, ThrowOnError>): RequestResult<WalletVirtualAccountForResponses, unknown, ThrowOnError>;
|
|
139
|
+
/**
|
|
140
|
+
* Pay a held balance out to the customer's default bank account
|
|
141
|
+
*/
|
|
142
|
+
withdraw<ThrowOnError extends boolean = false>(options: Options<WalletWithdrawData, ThrowOnError>): RequestResult<WalletWithdrawResponses, unknown, ThrowOnError>;
|
|
143
|
+
/**
|
|
144
|
+
* Start a fund-by-charge: a one-off bank account (bank_transfer) or a redirect URL to authorise (eft, ZAR)
|
|
145
|
+
*/
|
|
146
|
+
initiateFundingCharge<ThrowOnError extends boolean = false>(options: Options<WalletInitiateFundingChargeData, ThrowOnError>): RequestResult<WalletInitiateFundingChargeResponses, unknown, ThrowOnError>;
|
|
147
|
+
/**
|
|
148
|
+
* The customer's funding charges, newest first
|
|
149
|
+
*/
|
|
150
|
+
fundingCharges<ThrowOnError extends boolean = false>(options: Options<WalletFundingChargesData, ThrowOnError>): RequestResult<WalletFundingChargesResponses, unknown, ThrowOnError>;
|
|
151
|
+
}
|
|
152
|
+
export declare class Send extends HeyApiClient {
|
|
153
|
+
/**
|
|
154
|
+
* Networks the customer can send USDT/USDC on, with fee and minimum
|
|
155
|
+
*/
|
|
156
|
+
networks<ThrowOnError extends boolean = false>(options: Options<SendNetworksData, ThrowOnError>): RequestResult<SendNetworksResponses, unknown, ThrowOnError>;
|
|
157
|
+
/**
|
|
158
|
+
* Quote a send before submitting it
|
|
159
|
+
*/
|
|
160
|
+
quote<ThrowOnError extends boolean = false>(options: Options<SendQuoteData, ThrowOnError>): RequestResult<SendQuoteResponses, unknown, ThrowOnError>;
|
|
161
|
+
/**
|
|
162
|
+
* Send USDT on-chain to the given address
|
|
163
|
+
*/
|
|
164
|
+
submit<ThrowOnError extends boolean = false>(options: Options<SendSubmitData, ThrowOnError>): RequestResult<SendSubmitResponses, unknown, ThrowOnError>;
|
|
165
|
+
}
|
|
166
|
+
export declare class GlobalSend extends HeyApiClient {
|
|
167
|
+
/**
|
|
168
|
+
* Re-check the customer's level 3 verification status with the partner
|
|
169
|
+
*/
|
|
170
|
+
verificationStatus<ThrowOnError extends boolean = false>(options: Options<GlobalSendVerificationStatusData, ThrowOnError>): RequestResult<GlobalSendVerificationStatusResponses, unknown, ThrowOnError>;
|
|
171
|
+
/**
|
|
172
|
+
* Countries the customer can send to, with their currency and rails
|
|
173
|
+
*/
|
|
174
|
+
corridors<ThrowOnError extends boolean = false>(options: Options<GlobalSendCorridorsData, ThrowOnError>): RequestResult<GlobalSendCorridorsResponses, unknown, ThrowOnError>;
|
|
175
|
+
/**
|
|
176
|
+
* Price a cross-border send for the customer
|
|
177
|
+
*/
|
|
178
|
+
quote<ThrowOnError extends boolean = false>(options: Options<GlobalSendQuoteData, ThrowOnError>): RequestResult<GlobalSendQuoteResponses, unknown, ThrowOnError>;
|
|
179
|
+
/**
|
|
180
|
+
* Initiate a cross-border send for the customer
|
|
181
|
+
*/
|
|
182
|
+
initiate<ThrowOnError extends boolean = false>(options: Options<GlobalSendInitiateData, ThrowOnError>): RequestResult<GlobalSendInitiateResponses, unknown, ThrowOnError>;
|
|
183
|
+
}
|
|
184
|
+
export declare class Ramp extends HeyApiClient {
|
|
185
|
+
/**
|
|
186
|
+
* Price a buy (fiat -> USDT) against the customer's fiat balance
|
|
187
|
+
*/
|
|
188
|
+
buyQuote<ThrowOnError extends boolean = false>(options: Options<RampBuyQuoteData, ThrowOnError>): RequestResult<RampBuyQuoteResponses, unknown, ThrowOnError>;
|
|
189
|
+
/**
|
|
190
|
+
* Execute a buy from the customer's fiat balance
|
|
191
|
+
*/
|
|
192
|
+
buy<ThrowOnError extends boolean = false>(options: Options<RampBuyData, ThrowOnError>): RequestResult<RampBuyResponses, unknown, ThrowOnError>;
|
|
193
|
+
/**
|
|
194
|
+
* Networks the customer can sell USDT on
|
|
195
|
+
*/
|
|
196
|
+
sellNetworks<ThrowOnError extends boolean = false>(options: Options<RampSellNetworksData, ThrowOnError>): RequestResult<RampSellNetworksResponses, unknown, ThrowOnError>;
|
|
197
|
+
/**
|
|
198
|
+
* Live USDT rates in the customer's local fiat, for previewing a conversion
|
|
199
|
+
*
|
|
200
|
+
* Does not lock a rate -- checkout still goes through the quote routes.
|
|
201
|
+
*/
|
|
202
|
+
rate<ThrowOnError extends boolean = false>(options: Options<RampRateData, ThrowOnError>): RequestResult<RampRateResponses, unknown, ThrowOnError>;
|
|
203
|
+
/**
|
|
204
|
+
* Price a sell (USDT -> fiat) against the customer's USDT balance
|
|
205
|
+
*/
|
|
206
|
+
sellQuote<ThrowOnError extends boolean = false>(options: Options<RampSellQuoteData, ThrowOnError>): RequestResult<RampSellQuoteResponses, unknown, ThrowOnError>;
|
|
207
|
+
/**
|
|
208
|
+
* Execute a sell from the customer's USDT balance
|
|
209
|
+
*/
|
|
210
|
+
sell<ThrowOnError extends boolean = false>(options: Options<RampSellData, ThrowOnError>): RequestResult<RampSellResponses, unknown, ThrowOnError>;
|
|
211
|
+
}
|
|
212
|
+
export declare class Bank extends HeyApiClient {
|
|
213
|
+
/**
|
|
214
|
+
* Banks for the given (or the customer's own) country/currency
|
|
215
|
+
*/
|
|
216
|
+
banks<ThrowOnError extends boolean = false>(options: Options<BankBanksData, ThrowOnError>): RequestResult<BankBanksResponses, unknown, ThrowOnError>;
|
|
217
|
+
/**
|
|
218
|
+
* Resolve an account number to its account name
|
|
219
|
+
*/
|
|
220
|
+
verifyAccount<ThrowOnError extends boolean = false>(options: Options<BankVerifyAccountData, ThrowOnError>): RequestResult<BankVerifyAccountResponses, unknown, ThrowOnError>;
|
|
221
|
+
/**
|
|
222
|
+
* List the customer's linked payout accounts, default first
|
|
223
|
+
*/
|
|
224
|
+
getAccounts<ThrowOnError extends boolean = false>(options: Options<BankGetAccountsData, ThrowOnError>): RequestResult<BankGetAccountsResponses, unknown, ThrowOnError>;
|
|
225
|
+
/**
|
|
226
|
+
* Link a payout bank account to the customer
|
|
227
|
+
*/
|
|
228
|
+
addAccount<ThrowOnError extends boolean = false>(options: Options<BankAddAccountData, ThrowOnError>): RequestResult<BankAddAccountResponses, unknown, ThrowOnError>;
|
|
229
|
+
/**
|
|
230
|
+
* Make a linked account the customer's default payout destination
|
|
231
|
+
*/
|
|
232
|
+
setDefaultAccount<ThrowOnError extends boolean = false>(options: Options<BankSetDefaultAccountData, ThrowOnError>): RequestResult<BankSetDefaultAccountResponses, unknown, ThrowOnError>;
|
|
233
|
+
/**
|
|
234
|
+
* Remove a customer's linked payout account
|
|
235
|
+
*/
|
|
236
|
+
deleteAccount<ThrowOnError extends boolean = false>(options: Options<BankDeleteAccountData, ThrowOnError>): RequestResult<BankDeleteAccountResponses, unknown, ThrowOnError>;
|
|
237
|
+
}
|
|
238
|
+
export declare class Receiving extends HeyApiClient {
|
|
239
|
+
/**
|
|
240
|
+
* Foreign currencies the customer can be paid in
|
|
241
|
+
*/
|
|
242
|
+
currencies<ThrowOnError extends boolean = false>(options: Options<ReceivingCurrenciesData, ThrowOnError>): RequestResult<ReceivingCurrenciesResponses, unknown, ThrowOnError>;
|
|
243
|
+
/**
|
|
244
|
+
* Every foreign-currency account the customer holds
|
|
245
|
+
*/
|
|
246
|
+
list<ThrowOnError extends boolean = false>(options: Options<ReceivingListData, ThrowOnError>): RequestResult<ReceivingListResponses, unknown, ThrowOnError>;
|
|
247
|
+
/**
|
|
248
|
+
* Payments seen on the customer's receiving accounts, including ones still in flight
|
|
249
|
+
*/
|
|
250
|
+
activity<ThrowOnError extends boolean = false>(options: Options<ReceivingActivityData, ThrowOnError>): RequestResult<ReceivingActivityResponses, unknown, ThrowOnError>;
|
|
251
|
+
/**
|
|
252
|
+
* Open (or return) the customer's account for one currency
|
|
253
|
+
*
|
|
254
|
+
* Idempotent per currency -- calling twice returns the same account rather than opening a second one.
|
|
255
|
+
*/
|
|
256
|
+
open<ThrowOnError extends boolean = false>(options: Options<ReceivingOpenData, ThrowOnError>): RequestResult<ReceivingOpenResponses, unknown, ThrowOnError>;
|
|
257
|
+
/**
|
|
258
|
+
* Re-read one of the customer's accounts from the partner
|
|
259
|
+
*
|
|
260
|
+
* An account is often issued pending and activated shortly after, and nothing pushes a notification for that transition.
|
|
261
|
+
*/
|
|
262
|
+
refresh<ThrowOnError extends boolean = false>(options: Options<ReceivingRefreshData, ThrowOnError>): RequestResult<ReceivingRefreshResponses, unknown, ThrowOnError>;
|
|
263
|
+
}
|
|
264
|
+
export declare class Countries extends HeyApiClient {
|
|
265
|
+
/**
|
|
266
|
+
* Countries currently enabled for onboarding
|
|
267
|
+
*/
|
|
268
|
+
list<ThrowOnError extends boolean = false>(options?: Options<CountriesListData, ThrowOnError>): RequestResult<CountriesListResponses, unknown, ThrowOnError>;
|
|
269
|
+
}
|
|
270
|
+
export declare class Features extends HeyApiClient {
|
|
271
|
+
/**
|
|
272
|
+
* Every switchable capability and its current state
|
|
273
|
+
*/
|
|
274
|
+
list<ThrowOnError extends boolean = false>(options?: Options<FeaturesListData, ThrowOnError>): RequestResult<FeaturesListResponses, unknown, ThrowOnError>;
|
|
275
|
+
}
|
|
276
|
+
export declare class Webhook extends HeyApiClient {
|
|
277
|
+
/**
|
|
278
|
+
* Your current webhook URL and whether a secret is set
|
|
279
|
+
*/
|
|
280
|
+
config<ThrowOnError extends boolean = false>(options?: Options<WebhookConfigData, ThrowOnError>): RequestResult<WebhookConfigResponses, unknown, ThrowOnError>;
|
|
281
|
+
/**
|
|
282
|
+
* Set your webhook URL and receive a new signing secret
|
|
283
|
+
*
|
|
284
|
+
* Validates the URL, mints a fresh secret (the old one stops working), stores it encrypted, and immediately POSTs a signed `webhook.test` event to the URL. The secret is returned here and nowhere else.
|
|
285
|
+
*/
|
|
286
|
+
setUrl<ThrowOnError extends boolean = false>(options: Options<WebhookSetUrlData, ThrowOnError>): RequestResult<WebhookSetUrlResponses, unknown, ThrowOnError>;
|
|
287
|
+
/**
|
|
288
|
+
* Rotate the signing secret
|
|
289
|
+
*
|
|
290
|
+
* The previous secret stops working immediately; queued deliveries are signed with the new one. A `webhook.test` ping is sent, as on PUT.
|
|
291
|
+
*/
|
|
292
|
+
rotateSecret<ThrowOnError extends boolean = false>(options?: Options<WebhookRotateSecretData, ThrowOnError>): RequestResult<WebhookRotateSecretResponses, unknown, ThrowOnError>;
|
|
293
|
+
/**
|
|
294
|
+
* Your delivery log, newest first
|
|
295
|
+
*/
|
|
296
|
+
deliveries<ThrowOnError extends boolean = false>(options?: Options<WebhookDeliveriesData, ThrowOnError>): RequestResult<WebhookDeliveriesResponses, unknown, ThrowOnError>;
|
|
297
|
+
/**
|
|
298
|
+
* One delivery, including the payload that was sent
|
|
299
|
+
*/
|
|
300
|
+
delivery<ThrowOnError extends boolean = false>(options: Options<WebhookDeliveryData, ThrowOnError>): RequestResult<WebhookDeliveryResponses, unknown, ThrowOnError>;
|
|
301
|
+
/**
|
|
302
|
+
* Send a delivery again
|
|
303
|
+
*
|
|
304
|
+
* Queues it for immediate re-delivery with the SAME event id, so your handler can recognise it as a duplicate if the original did land.
|
|
305
|
+
*/
|
|
306
|
+
replay<ThrowOnError extends boolean = false>(options: Options<WebhookReplayData, ThrowOnError>): RequestResult<WebhookReplayResponses, unknown, ThrowOnError>;
|
|
307
|
+
}
|
|
308
|
+
export declare class DutchmanBridge extends HeyApiClient {
|
|
309
|
+
static readonly __registry: HeyApiRegistry<DutchmanBridge>;
|
|
310
|
+
constructor(args?: {
|
|
311
|
+
client?: Client;
|
|
312
|
+
key?: string;
|
|
313
|
+
});
|
|
314
|
+
private _customers?;
|
|
315
|
+
get customers(): Customers;
|
|
316
|
+
private _profile?;
|
|
317
|
+
get profile(): Profile;
|
|
318
|
+
private _kyc?;
|
|
319
|
+
get kyc(): Kyc;
|
|
320
|
+
private _wallet?;
|
|
321
|
+
get wallet(): Wallet;
|
|
322
|
+
private _send?;
|
|
323
|
+
get send(): Send;
|
|
324
|
+
private _globalSend?;
|
|
325
|
+
get globalSend(): GlobalSend;
|
|
326
|
+
private _ramp?;
|
|
327
|
+
get ramp(): Ramp;
|
|
328
|
+
private _bank?;
|
|
329
|
+
get bank(): Bank;
|
|
330
|
+
private _receiving?;
|
|
331
|
+
get receiving(): Receiving;
|
|
332
|
+
private _countries?;
|
|
333
|
+
get countries(): Countries;
|
|
334
|
+
private _features?;
|
|
335
|
+
get features(): Features;
|
|
336
|
+
private _webhook?;
|
|
337
|
+
get webhook(): Webhook;
|
|
338
|
+
}
|
|
339
|
+
export {};
|