@augustusbank/typescript-sdk 0.26.0 → 0.27.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.
Files changed (55) hide show
  1. package/CHANGELOG.md +7 -0
  2. package/client.d.mts +2 -2
  3. package/client.d.mts.map +1 -1
  4. package/client.d.ts +2 -2
  5. package/client.d.ts.map +1 -1
  6. package/client.js.map +1 -1
  7. package/client.mjs.map +1 -1
  8. package/package.json +1 -1
  9. package/resources/account-programs.d.mts +2 -1
  10. package/resources/account-programs.d.mts.map +1 -1
  11. package/resources/account-programs.d.ts +2 -1
  12. package/resources/account-programs.d.ts.map +1 -1
  13. package/resources/accounts.d.mts +2 -1
  14. package/resources/accounts.d.mts.map +1 -1
  15. package/resources/accounts.d.ts +2 -1
  16. package/resources/accounts.d.ts.map +1 -1
  17. package/resources/counterparties.d.mts +4 -185
  18. package/resources/counterparties.d.mts.map +1 -1
  19. package/resources/counterparties.d.ts +4 -185
  20. package/resources/counterparties.d.ts.map +1 -1
  21. package/resources/counterparties.js +0 -14
  22. package/resources/counterparties.js.map +1 -1
  23. package/resources/counterparties.mjs +0 -14
  24. package/resources/counterparties.mjs.map +1 -1
  25. package/resources/index.d.mts +1 -1
  26. package/resources/index.d.mts.map +1 -1
  27. package/resources/index.d.ts +1 -1
  28. package/resources/index.d.ts.map +1 -1
  29. package/resources/index.js.map +1 -1
  30. package/resources/index.mjs.map +1 -1
  31. package/resources/simulations/account-programs.d.mts +3 -3
  32. package/resources/simulations/account-programs.d.mts.map +1 -1
  33. package/resources/simulations/account-programs.d.ts +3 -3
  34. package/resources/simulations/account-programs.d.ts.map +1 -1
  35. package/resources/simulations/accounts.d.mts +3 -3
  36. package/resources/simulations/accounts.d.mts.map +1 -1
  37. package/resources/simulations/accounts.d.ts +3 -3
  38. package/resources/simulations/accounts.d.ts.map +1 -1
  39. package/resources/simulations/deposits.d.mts +3 -3
  40. package/resources/simulations/deposits.d.mts.map +1 -1
  41. package/resources/simulations/deposits.d.ts +3 -3
  42. package/resources/simulations/deposits.d.ts.map +1 -1
  43. package/src/client.ts +0 -2
  44. package/src/resources/account-programs.ts +2 -1
  45. package/src/resources/accounts.ts +2 -1
  46. package/src/resources/counterparties.ts +4 -486
  47. package/src/resources/index.ts +0 -1
  48. package/src/resources/simulations/account-programs.ts +4 -4
  49. package/src/resources/simulations/accounts.ts +4 -4
  50. package/src/resources/simulations/deposits.ts +4 -4
  51. package/src/version.ts +1 -1
  52. package/version.d.mts +1 -1
  53. package/version.d.ts +1 -1
  54. package/version.js +1 -1
  55. package/version.mjs +1 -1
@@ -77,21 +77,6 @@ export class Counterparties extends APIResource {
77
77
  ...options,
78
78
  });
79
79
  }
80
-
81
- /**
82
- * Blocks payments to and from a counterparty owned by the merchant. Blocking an
83
- * already-blocked counterparty succeeds without changing the existing block.
84
- *
85
- * @example
86
- * ```ts
87
- * const response = await client.counterparties.block(
88
- * '182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e',
89
- * );
90
- * ```
91
- */
92
- block(id: string, options?: RequestOptions): APIPromise<CounterpartyBlockResponse> {
93
- return this._client.post(path`/v1/counterparties/${id}/block`, options);
94
- }
95
80
  }
96
81
 
97
82
  export type CounterpartyListResponsesCursorPage = CursorPage<CounterpartyListResponse>;
@@ -1960,480 +1945,14 @@ export namespace CounterpartyListResponse {
1960
1945
  }
1961
1946
  }
1962
1947
 
1963
- export interface CounterpartyBlockResponse {
1964
- /**
1965
- * Unique identifier of the counterparty.
1966
- */
1967
- id: string;
1968
-
1969
- /**
1970
- * Whether payments to or from this counterparty are currently blocked.
1971
- */
1972
- blocked: boolean;
1973
-
1974
- /**
1975
- * Date of birth in YYYY-MM-DD format, or null if not recorded.
1976
- */
1977
- date_of_birth: string | null;
1978
-
1979
- /**
1980
- * Whether the counterparty is a business or an individual.
1981
- */
1982
- entity_type: 'business' | 'individual';
1983
-
1984
- /**
1985
- * Financial address of the counterparty.
1986
- */
1987
- financial_address:
1988
- | CounterpartyBlockResponse.IbanFinancialAddress
1989
- | CounterpartyBlockResponse.SortCodeFinancialAddress
1990
- | CounterpartyBlockResponse.AbaFinancialAddress
1991
- | CounterpartyBlockResponse.BicFinancialAddress
1992
- | CounterpartyBlockResponse.CryptoWalletFinancialAddress;
1993
-
1994
- /**
1995
- * Whether the counterparty is self-owned. `false` if the counterparty is not owned
1996
- * by you, `true` if it is.
1997
- */
1998
- is_self_owned: boolean;
1999
-
2000
- /**
2001
- * Set of up to 50 key-value string pairs you can attach to store structured
2002
- * information, such as correlating this resource with an object in your own
2003
- * system. Keys may be up to 40 characters and values up to 500 characters.
2004
- */
2005
- metadata: { [key: string]: string };
2006
-
2007
- /**
2008
- * Name of the counterparty, or null if not recorded.
2009
- */
2010
- name: string | null;
2011
-
2012
- /**
2013
- * Physical address of the counterparty, or null if not recorded.
2014
- */
2015
- physical_address: CounterpartyBlockResponse.PhysicalAddress | null;
2016
-
2017
- /**
2018
- * Resource type discriminator.
2019
- */
2020
- type: 'counterparty';
2021
- }
2022
-
2023
- export namespace CounterpartyBlockResponse {
2024
- export interface IbanFinancialAddress {
2025
- /**
2026
- * Name of the account holder.
2027
- */
2028
- account_holder_name: string;
2029
-
2030
- /**
2031
- * Bank Identifier Code, or null if not provided.
2032
- */
2033
- bic: string | null;
2034
-
2035
- /**
2036
- * International Bank Account Number.
2037
- */
2038
- iban: string;
2039
-
2040
- /**
2041
- * Discriminator for IBAN financial address.
2042
- */
2043
- type: 'iban';
2044
- }
2045
-
2046
- export interface SortCodeFinancialAddress {
2047
- /**
2048
- * Name of the account holder.
2049
- */
2050
- account_holder_name: string;
2051
-
2052
- /**
2053
- * UK account number (8 digits).
2054
- */
2055
- account_number: string;
2056
-
2057
- /**
2058
- * UK sort code (6 digits).
2059
- */
2060
- sort_code: string;
2061
-
2062
- /**
2063
- * Discriminator for UK sort code financial address.
2064
- */
2065
- type: 'sort_code';
2066
- }
2067
-
2068
- export interface AbaFinancialAddress {
2069
- /**
2070
- * Name of the account holder.
2071
- */
2072
- account_holder_name: string;
2073
-
2074
- /**
2075
- * Bank account number.
2076
- */
2077
- account_number: string;
2078
-
2079
- /**
2080
- * ABA routing number (9 digits).
2081
- */
2082
- routing_number: string;
2083
-
2084
- /**
2085
- * Discriminator for ABA wire financial address.
2086
- */
2087
- type: 'aba';
2088
- }
2089
-
2090
- export interface BicFinancialAddress {
2091
- /**
2092
- * Name of the account holder.
2093
- */
2094
- account_holder_name: string;
2095
-
2096
- /**
2097
- * Local-format bank account number.
2098
- */
2099
- account_number: string;
2100
-
2101
- /**
2102
- * ISO 9362 Bank Identifier Code (8 or 11 characters).
2103
- */
2104
- bic: string;
2105
-
2106
- /**
2107
- * Domestic bank or branch code where the destination country uses one (for example
2108
- * the BSB in Australia), or null.
2109
- */
2110
- local_bank_code: string | null;
2111
-
2112
- /**
2113
- * Discriminator for BIC + local account financial address.
2114
- */
2115
- type: 'bic';
2116
- }
2117
-
2118
- export interface CryptoWalletFinancialAddress {
2119
- /**
2120
- * Wallet address on the specified blockchain.
2121
- */
2122
- address: string;
2123
-
2124
- /**
2125
- * Blockchain network for the crypto wallet.
2126
- */
2127
- blockchain:
2128
- | 'bitcoin'
2129
- | 'ethereum'
2130
- | 'solana'
2131
- | 'polygon'
2132
- | 'bitcoin_testnet4'
2133
- | 'ethereum_sepolia'
2134
- | 'solana_devnet'
2135
- | 'polygon_amoy';
2136
-
2137
- /**
2138
- * Discriminator for crypto wallet financial address.
2139
- */
2140
- type: 'crypto_wallet';
2141
- }
2142
-
2143
- /**
2144
- * Physical address of the counterparty, or null if not recorded.
2145
- */
2146
- export interface PhysicalAddress {
2147
- /**
2148
- * City or locality.
2149
- */
2150
- city: string;
2151
-
2152
- /**
2153
- * ISO 3166-1 alpha-2 country code.
2154
- */
2155
- country_code:
2156
- | 'AF'
2157
- | 'AL'
2158
- | 'DZ'
2159
- | 'AS'
2160
- | 'AD'
2161
- | 'AO'
2162
- | 'AI'
2163
- | 'AQ'
2164
- | 'AG'
2165
- | 'AR'
2166
- | 'AM'
2167
- | 'AW'
2168
- | 'AU'
2169
- | 'AT'
2170
- | 'AZ'
2171
- | 'BS'
2172
- | 'BH'
2173
- | 'BD'
2174
- | 'BB'
2175
- | 'BY'
2176
- | 'BE'
2177
- | 'BZ'
2178
- | 'BJ'
2179
- | 'BM'
2180
- | 'BT'
2181
- | 'BO'
2182
- | 'BA'
2183
- | 'BW'
2184
- | 'BV'
2185
- | 'BR'
2186
- | 'IO'
2187
- | 'BN'
2188
- | 'BG'
2189
- | 'BF'
2190
- | 'BI'
2191
- | 'KH'
2192
- | 'CM'
2193
- | 'CA'
2194
- | 'CV'
2195
- | 'KY'
2196
- | 'CF'
2197
- | 'TD'
2198
- | 'CL'
2199
- | 'CN'
2200
- | 'CX'
2201
- | 'CC'
2202
- | 'CO'
2203
- | 'KM'
2204
- | 'CG'
2205
- | 'CD'
2206
- | 'CK'
2207
- | 'CR'
2208
- | 'CI'
2209
- | 'HR'
2210
- | 'CU'
2211
- | 'CY'
2212
- | 'CZ'
2213
- | 'DK'
2214
- | 'DJ'
2215
- | 'DM'
2216
- | 'DO'
2217
- | 'EC'
2218
- | 'EG'
2219
- | 'SV'
2220
- | 'GQ'
2221
- | 'ER'
2222
- | 'EE'
2223
- | 'ET'
2224
- | 'FK'
2225
- | 'FO'
2226
- | 'FJ'
2227
- | 'FI'
2228
- | 'FR'
2229
- | 'GF'
2230
- | 'PF'
2231
- | 'TF'
2232
- | 'GA'
2233
- | 'GM'
2234
- | 'GE'
2235
- | 'DE'
2236
- | 'GH'
2237
- | 'GI'
2238
- | 'GR'
2239
- | 'GL'
2240
- | 'GD'
2241
- | 'GP'
2242
- | 'GU'
2243
- | 'GT'
2244
- | 'GN'
2245
- | 'GW'
2246
- | 'GY'
2247
- | 'HT'
2248
- | 'HM'
2249
- | 'VA'
2250
- | 'HN'
2251
- | 'HK'
2252
- | 'HU'
2253
- | 'IS'
2254
- | 'IN'
2255
- | 'ID'
2256
- | 'IR'
2257
- | 'IQ'
2258
- | 'IE'
2259
- | 'IL'
2260
- | 'IT'
2261
- | 'JM'
2262
- | 'JP'
2263
- | 'JO'
2264
- | 'KZ'
2265
- | 'KE'
2266
- | 'KI'
2267
- | 'KP'
2268
- | 'KR'
2269
- | 'KW'
2270
- | 'KG'
2271
- | 'LA'
2272
- | 'LV'
2273
- | 'LB'
2274
- | 'LS'
2275
- | 'LR'
2276
- | 'LY'
2277
- | 'LI'
2278
- | 'LT'
2279
- | 'LU'
2280
- | 'MO'
2281
- | 'MG'
2282
- | 'MW'
2283
- | 'MY'
2284
- | 'MV'
2285
- | 'ML'
2286
- | 'MT'
2287
- | 'MH'
2288
- | 'MQ'
2289
- | 'MR'
2290
- | 'MU'
2291
- | 'YT'
2292
- | 'MX'
2293
- | 'FM'
2294
- | 'MD'
2295
- | 'MC'
2296
- | 'MN'
2297
- | 'MS'
2298
- | 'MA'
2299
- | 'MZ'
2300
- | 'MM'
2301
- | 'NA'
2302
- | 'NR'
2303
- | 'NP'
2304
- | 'NL'
2305
- | 'NC'
2306
- | 'NZ'
2307
- | 'NI'
2308
- | 'NE'
2309
- | 'NG'
2310
- | 'NU'
2311
- | 'NF'
2312
- | 'MP'
2313
- | 'MK'
2314
- | 'NO'
2315
- | 'OM'
2316
- | 'PK'
2317
- | 'PW'
2318
- | 'PS'
2319
- | 'PA'
2320
- | 'PG'
2321
- | 'PY'
2322
- | 'PE'
2323
- | 'PH'
2324
- | 'PN'
2325
- | 'PL'
2326
- | 'PT'
2327
- | 'PR'
2328
- | 'QA'
2329
- | 'RE'
2330
- | 'RO'
2331
- | 'RU'
2332
- | 'RW'
2333
- | 'SH'
2334
- | 'KN'
2335
- | 'LC'
2336
- | 'PM'
2337
- | 'VC'
2338
- | 'WS'
2339
- | 'SM'
2340
- | 'ST'
2341
- | 'SA'
2342
- | 'SN'
2343
- | 'SC'
2344
- | 'SL'
2345
- | 'SG'
2346
- | 'SK'
2347
- | 'SI'
2348
- | 'SB'
2349
- | 'SO'
2350
- | 'ZA'
2351
- | 'GS'
2352
- | 'ES'
2353
- | 'LK'
2354
- | 'SD'
2355
- | 'SR'
2356
- | 'SJ'
2357
- | 'SZ'
2358
- | 'SE'
2359
- | 'CH'
2360
- | 'SY'
2361
- | 'TW'
2362
- | 'TJ'
2363
- | 'TZ'
2364
- | 'TH'
2365
- | 'TL'
2366
- | 'TG'
2367
- | 'TK'
2368
- | 'TO'
2369
- | 'TT'
2370
- | 'TN'
2371
- | 'TR'
2372
- | 'TM'
2373
- | 'TC'
2374
- | 'TV'
2375
- | 'UG'
2376
- | 'UA'
2377
- | 'AE'
2378
- | 'GB'
2379
- | 'US'
2380
- | 'UM'
2381
- | 'UY'
2382
- | 'UZ'
2383
- | 'VU'
2384
- | 'VE'
2385
- | 'VN'
2386
- | 'VG'
2387
- | 'VI'
2388
- | 'WF'
2389
- | 'EH'
2390
- | 'YE'
2391
- | 'ZM'
2392
- | 'ZW'
2393
- | 'AX'
2394
- | 'BQ'
2395
- | 'CW'
2396
- | 'GG'
2397
- | 'IM'
2398
- | 'JE'
2399
- | 'ME'
2400
- | 'BL'
2401
- | 'MF'
2402
- | 'RS'
2403
- | 'SX'
2404
- | 'SS'
2405
- | 'XK';
2406
-
2407
- /**
2408
- * Primary street address, or null if not recorded.
2409
- */
2410
- line_1: string | null;
2411
-
2412
- /**
2413
- * Secondary street address, or null if not recorded.
2414
- */
2415
- line_2: string | null;
2416
-
2417
- /**
2418
- * Postal or ZIP code, or null if not recorded.
2419
- */
2420
- postal_code: string | null;
2421
-
2422
- /**
2423
- * State, province, or region, or null if not recorded.
2424
- */
2425
- state: string | null;
2426
- }
2427
- }
2428
-
2429
1948
  export interface CounterpartyCreateParams {
2430
1949
  /**
2431
1950
  * Financial address of the counterparty.
2432
1951
  */
2433
1952
  financial_address:
2434
1953
  | CounterpartyCreateParams.IbanFinancialAddressRequest
2435
- | CounterpartyCreateParams.SortCodeFinancialAddress
2436
- | CounterpartyCreateParams.AbaFinancialAddress
1954
+ | CounterpartyCreateParams.SortCodeFinancialAddressRequest
1955
+ | CounterpartyCreateParams.AbaFinancialAddressRequest
2437
1956
  | CounterpartyCreateParams.BicFinancialAddressRequest
2438
1957
  | CounterpartyCreateParams.CryptoWalletFinancialAddress;
2439
1958
 
@@ -2494,7 +2013,7 @@ export namespace CounterpartyCreateParams {
2494
2013
  bic?: string | null;
2495
2014
  }
2496
2015
 
2497
- export interface SortCodeFinancialAddress {
2016
+ export interface SortCodeFinancialAddressRequest {
2498
2017
  /**
2499
2018
  * Name of the account holder.
2500
2019
  */
@@ -2516,7 +2035,7 @@ export namespace CounterpartyCreateParams {
2516
2035
  type: 'sort_code';
2517
2036
  }
2518
2037
 
2519
- export interface AbaFinancialAddress {
2038
+ export interface AbaFinancialAddressRequest {
2520
2039
  /**
2521
2040
  * Name of the account holder.
2522
2041
  */
@@ -3200,7 +2719,6 @@ export declare namespace Counterparties {
3200
2719
  type CounterpartyRetrieveResponse as CounterpartyRetrieveResponse,
3201
2720
  type CounterpartyUpdateResponse as CounterpartyUpdateResponse,
3202
2721
  type CounterpartyListResponse as CounterpartyListResponse,
3203
- type CounterpartyBlockResponse as CounterpartyBlockResponse,
3204
2722
  type CounterpartyListResponsesCursorPage as CounterpartyListResponsesCursorPage,
3205
2723
  type CounterpartyCreateParams as CounterpartyCreateParams,
3206
2724
  type CounterpartyUpdateParams as CounterpartyUpdateParams,
@@ -52,7 +52,6 @@ export {
52
52
  type CounterpartyRetrieveResponse,
53
53
  type CounterpartyUpdateResponse,
54
54
  type CounterpartyListResponse,
55
- type CounterpartyBlockResponse,
56
55
  type CounterpartyCreateParams,
57
56
  type CounterpartyUpdateParams,
58
57
  type CounterpartyListParams,
@@ -202,8 +202,8 @@ export interface AccountProgramDrainParams {
202
202
  */
203
203
  destination:
204
204
  | AccountProgramDrainParams.IbanFinancialAddressRequest
205
- | AccountProgramDrainParams.SortCodeFinancialAddress
206
- | AccountProgramDrainParams.AbaFinancialAddress;
205
+ | AccountProgramDrainParams.SortCodeFinancialAddressRequest
206
+ | AccountProgramDrainParams.AbaFinancialAddressRequest;
207
207
  }
208
208
 
209
209
  export namespace AccountProgramDrainParams {
@@ -229,7 +229,7 @@ export namespace AccountProgramDrainParams {
229
229
  bic?: string | null;
230
230
  }
231
231
 
232
- export interface SortCodeFinancialAddress {
232
+ export interface SortCodeFinancialAddressRequest {
233
233
  /**
234
234
  * Name of the account holder.
235
235
  */
@@ -251,7 +251,7 @@ export namespace AccountProgramDrainParams {
251
251
  type: 'sort_code';
252
252
  }
253
253
 
254
- export interface AbaFinancialAddress {
254
+ export interface AbaFinancialAddressRequest {
255
255
  /**
256
256
  * Name of the account holder.
257
257
  */
@@ -185,8 +185,8 @@ export interface AccountDrainParams {
185
185
  */
186
186
  destination:
187
187
  | AccountDrainParams.IbanFinancialAddressRequest
188
- | AccountDrainParams.SortCodeFinancialAddress
189
- | AccountDrainParams.AbaFinancialAddress;
188
+ | AccountDrainParams.SortCodeFinancialAddressRequest
189
+ | AccountDrainParams.AbaFinancialAddressRequest;
190
190
  }
191
191
 
192
192
  export namespace AccountDrainParams {
@@ -212,7 +212,7 @@ export namespace AccountDrainParams {
212
212
  bic?: string | null;
213
213
  }
214
214
 
215
- export interface SortCodeFinancialAddress {
215
+ export interface SortCodeFinancialAddressRequest {
216
216
  /**
217
217
  * Name of the account holder.
218
218
  */
@@ -234,7 +234,7 @@ export namespace AccountDrainParams {
234
234
  type: 'sort_code';
235
235
  }
236
236
 
237
- export interface AbaFinancialAddress {
237
+ export interface AbaFinancialAddressRequest {
238
238
  /**
239
239
  * Name of the account holder.
240
240
  */
@@ -96,8 +96,8 @@ export namespace DepositCreateParams {
96
96
  */
97
97
  financial_address:
98
98
  | Counterparty.IbanFinancialAddressRequest
99
- | Counterparty.SortCodeFinancialAddress
100
- | Counterparty.AbaFinancialAddress
99
+ | Counterparty.SortCodeFinancialAddressRequest
100
+ | Counterparty.AbaFinancialAddressRequest
101
101
  | Counterparty.BicFinancialAddressRequest
102
102
  | Counterparty.CryptoWalletFinancialAddress;
103
103
 
@@ -130,7 +130,7 @@ export namespace DepositCreateParams {
130
130
  bic?: string | null;
131
131
  }
132
132
 
133
- export interface SortCodeFinancialAddress {
133
+ export interface SortCodeFinancialAddressRequest {
134
134
  /**
135
135
  * Name of the account holder.
136
136
  */
@@ -152,7 +152,7 @@ export namespace DepositCreateParams {
152
152
  type: 'sort_code';
153
153
  }
154
154
 
155
- export interface AbaFinancialAddress {
155
+ export interface AbaFinancialAddressRequest {
156
156
  /**
157
157
  * Name of the account holder.
158
158
  */
package/src/version.ts CHANGED
@@ -1 +1 @@
1
- export const VERSION = '0.26.0'; // x-release-please-version
1
+ export const VERSION = '0.27.0'; // x-release-please-version
package/version.d.mts CHANGED
@@ -1,2 +1,2 @@
1
- export declare const VERSION = "0.26.0";
1
+ export declare const VERSION = "0.27.0";
2
2
  //# sourceMappingURL=version.d.mts.map
package/version.d.ts CHANGED
@@ -1,2 +1,2 @@
1
- export declare const VERSION = "0.26.0";
1
+ export declare const VERSION = "0.27.0";
2
2
  //# sourceMappingURL=version.d.ts.map
package/version.js CHANGED
@@ -1,5 +1,5 @@
1
1
  "use strict";
2
2
  Object.defineProperty(exports, "__esModule", { value: true });
3
3
  exports.VERSION = void 0;
4
- exports.VERSION = '0.26.0'; // x-release-please-version
4
+ exports.VERSION = '0.27.0'; // x-release-please-version
5
5
  //# sourceMappingURL=version.js.map
package/version.mjs CHANGED
@@ -1,2 +1,2 @@
1
- export const VERSION = '0.26.0'; // x-release-please-version
1
+ export const VERSION = '0.27.0'; // x-release-please-version
2
2
  //# sourceMappingURL=version.mjs.map