@andco/protocol 0.0.3 → 0.0.4

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 (113) hide show
  1. package/LICENSE +1 -1
  2. package/README.md +33 -3
  3. package/dist/api-errors.d.ts +109 -0
  4. package/dist/api-errors.d.ts.map +1 -0
  5. package/dist/api-errors.js +111 -0
  6. package/dist/authorization-preparation.d.ts +52 -543
  7. package/dist/authorization-preparation.d.ts.map +1 -1
  8. package/dist/authorization-preparation.js +19 -42
  9. package/dist/authorization.d.ts +64 -22
  10. package/dist/authorization.d.ts.map +1 -1
  11. package/dist/authorization.js +136 -55
  12. package/dist/consent.d.ts +5 -8
  13. package/dist/consent.d.ts.map +1 -1
  14. package/dist/consent.js +5 -62
  15. package/dist/constants.d.ts +19 -3
  16. package/dist/constants.d.ts.map +1 -1
  17. package/dist/constants.js +19 -3
  18. package/dist/errors.d.ts +156 -58
  19. package/dist/errors.d.ts.map +1 -1
  20. package/dist/errors.js +176 -57
  21. package/dist/index.d.ts +4 -4
  22. package/dist/index.d.ts.map +1 -1
  23. package/dist/index.js +4 -4
  24. package/dist/intent-input.d.ts +1010 -279
  25. package/dist/intent-input.d.ts.map +1 -1
  26. package/dist/intent-input.js +268 -40
  27. package/dist/messages/error.d.ts +1 -2
  28. package/dist/messages/error.d.ts.map +1 -1
  29. package/dist/messages/error.js +5 -2
  30. package/dist/messages/index.d.ts +1 -1
  31. package/dist/native-copy.d.ts +23 -2
  32. package/dist/native-copy.d.ts.map +1 -1
  33. package/dist/native-copy.js +42 -98
  34. package/dist/native-intent.d.ts +126 -75
  35. package/dist/native-intent.d.ts.map +1 -1
  36. package/dist/native-intent.js +140 -48
  37. package/dist/rar/account-matchers.d.ts +579 -0
  38. package/dist/rar/account-matchers.d.ts.map +1 -0
  39. package/dist/rar/account-matchers.js +480 -0
  40. package/dist/rar/bank.d.ts +1549 -0
  41. package/dist/rar/bank.d.ts.map +1 -0
  42. package/dist/rar/bank.js +379 -0
  43. package/dist/rar/catalog.d.ts +1155 -0
  44. package/dist/rar/catalog.d.ts.map +1 -0
  45. package/dist/rar/catalog.js +175 -0
  46. package/dist/rar/detail.d.ts +39 -0
  47. package/dist/rar/detail.d.ts.map +1 -0
  48. package/dist/rar/detail.js +44 -0
  49. package/dist/rar/index.d.ts +9 -0
  50. package/dist/rar/index.d.ts.map +1 -0
  51. package/dist/rar/index.js +8 -0
  52. package/dist/rar/money.d.ts +58 -0
  53. package/dist/rar/money.d.ts.map +1 -0
  54. package/dist/rar/money.js +61 -0
  55. package/dist/rar/project-users.d.ts +43 -0
  56. package/dist/rar/project-users.d.ts.map +1 -0
  57. package/dist/rar/project-users.js +63 -0
  58. package/dist/rar/subject-data.d.ts +170 -0
  59. package/dist/rar/subject-data.d.ts.map +1 -0
  60. package/dist/rar/subject-data.js +127 -0
  61. package/dist/rar/subject.d.ts +166 -0
  62. package/dist/rar/subject.d.ts.map +1 -0
  63. package/dist/rar/subject.js +119 -0
  64. package/dist/scopes.d.ts +5 -30
  65. package/dist/scopes.d.ts.map +1 -1
  66. package/dist/scopes.js +0 -13
  67. package/dist/service-grants.d.ts +44 -0
  68. package/dist/service-grants.d.ts.map +1 -0
  69. package/dist/service-grants.js +45 -0
  70. package/dist/signing.d.ts +56 -0
  71. package/dist/signing.d.ts.map +1 -0
  72. package/dist/signing.js +233 -0
  73. package/dist/transport/financial-events.d.ts +90 -35
  74. package/dist/transport/financial-events.d.ts.map +1 -1
  75. package/dist/transport/financial-events.js +7 -1
  76. package/dist/transport/generated/oauth-api.d.ts +908 -440
  77. package/dist/transport/generated/oauth-api.d.ts.map +1 -1
  78. package/dist/transport/index.d.ts +0 -1
  79. package/dist/transport/index.d.ts.map +1 -1
  80. package/dist/transport/index.js +0 -1
  81. package/dist/transport/intents.d.ts +155 -23
  82. package/dist/transport/intents.d.ts.map +1 -1
  83. package/dist/transport/intents.js +192 -59
  84. package/dist/transport/rest.d.ts +18 -8
  85. package/dist/transport/rest.d.ts.map +1 -1
  86. package/dist/transport/rest.js +1 -1
  87. package/dist/urls.d.ts.map +1 -1
  88. package/dist/urls.js +1 -1
  89. package/dist/userinfo.d.ts +10 -1
  90. package/dist/userinfo.d.ts.map +1 -1
  91. package/dist/userinfo.js +10 -1
  92. package/dist/utils.d.ts +15 -0
  93. package/dist/utils.d.ts.map +1 -1
  94. package/dist/utils.js +31 -0
  95. package/dist/webhooks.d.ts +154 -0
  96. package/dist/webhooks.d.ts.map +1 -0
  97. package/dist/webhooks.js +249 -0
  98. package/package.json +18 -1
  99. package/dist/automatic-charge.d.ts +0 -314
  100. package/dist/automatic-charge.d.ts.map +0 -1
  101. package/dist/automatic-charge.js +0 -126
  102. package/dist/bank-account-authorization.d.ts +0 -6
  103. package/dist/bank-account-authorization.d.ts.map +0 -1
  104. package/dist/bank-account-authorization.js +0 -13
  105. package/dist/transport/webhooks.d.ts +0 -27
  106. package/dist/transport/webhooks.d.ts.map +0 -1
  107. package/dist/transport/webhooks.js +0 -68
  108. package/dist/webhook-input.d.ts +0 -22
  109. package/dist/webhook-input.d.ts.map +0 -1
  110. package/dist/webhook-input.js +0 -11
  111. package/dist/webhook-signature.d.ts +0 -54
  112. package/dist/webhook-signature.d.ts.map +0 -1
  113. package/dist/webhook-signature.js +0 -74
@@ -3,37 +3,75 @@
3
3
  * Do not make direct changes to the file.
4
4
  */
5
5
  export interface paths {
6
- "/event-subscriptions": {
6
+ "/projects/{project_id}/profiles": {
7
+ parameters: {
8
+ query?: never;
9
+ header?: never;
10
+ path: {
11
+ /** @description The Project whose Profiles are read; it must be one of the Grant's `project_ids`, or any of the Organization's when that list is empty. */
12
+ project_id: components["parameters"]["ProjectId"];
13
+ };
14
+ cookie?: never;
15
+ };
16
+ /**
17
+ * Read the Profiles of the people who use a Project's Clients
18
+ * @description Granted by a `project_users` authorization detail with `read`, held by a Service. Its empty `project_ids`, `client_ids` and `fields` mean all, and the `client_id` and `fields` query parameters can only narrow them. Every field is present in each item; one is null when the person did not disclose it through their consent (`profile` discloses the name and avatar, `email` the email, `phone` the phone, an `identity` or `address` read Grant the identities or addresses) or when the Grant and the request leave it out. Cursor authority is pinned to one exact Grant, Project and filter.
19
+ */
20
+ get: operations["listProjectProfiles"];
21
+ put?: never;
22
+ post?: never;
23
+ delete?: never;
24
+ options?: never;
25
+ head?: never;
26
+ patch?: never;
27
+ trace?: never;
28
+ };
29
+ "/authorization": {
7
30
  parameters: {
8
31
  query?: never;
9
32
  header?: never;
10
33
  path?: never;
11
34
  cookie?: never;
12
35
  };
13
- get?: never;
36
+ /** Get the active Grant carried by the bearer token */
37
+ get: operations["getGrantAuthorization"];
14
38
  put?: never;
39
+ post?: never;
40
+ delete?: never;
41
+ options?: never;
42
+ head?: never;
43
+ patch?: never;
44
+ trace?: never;
45
+ };
46
+ "/catalog/permissions": {
47
+ parameters: {
48
+ query?: never;
49
+ header?: never;
50
+ path?: never;
51
+ cookie?: never;
52
+ };
15
53
  /**
16
- * Register one explicit subject for verified durable backend delivery
17
- * @description Requires the exact live Grant with subject read permission. Replays retained matching facts after ownership verification. The signing secret is a canonical base64url-encoded 32-byte key and is never returned.
54
+ * List the public Permission Catalog
55
+ * @description The reference of the OAuth Scopes and Detailed Authorization types that live providers publish, with their actions, restrictions and request examples. It describes requestable capabilities, never a Profile, Organization or Grant, and is the only resource in this API that requires no authorization.
18
56
  */
19
- post: operations["createWebhookSubscription"];
57
+ get: operations["getPermissionCatalog"];
58
+ put?: never;
59
+ post?: never;
20
60
  delete?: never;
21
61
  options?: never;
22
62
  head?: never;
23
63
  patch?: never;
24
64
  trace?: never;
25
65
  };
26
- "/event-subscriptions/{subscription_id}": {
66
+ "/userinfo": {
27
67
  parameters: {
28
68
  query?: never;
29
69
  header?: never;
30
- path: {
31
- subscription_id: string;
32
- };
70
+ path?: never;
33
71
  cookie?: never;
34
72
  };
35
- /** Inspect verification status under the original exact Grant */
36
- get: operations["getWebhookSubscription"];
73
+ /** Get the authenticated user's standard identity claims */
74
+ get: operations["getUserInfo"];
37
75
  put?: never;
38
76
  post?: never;
39
77
  delete?: never;
@@ -42,17 +80,21 @@ export interface paths {
42
80
  patch?: never;
43
81
  trace?: never;
44
82
  };
45
- "/event-subscriptions/{subscription_id}/deliveries": {
83
+ "/profiles/{profile_id}/identities": {
46
84
  parameters: {
47
85
  query?: never;
48
86
  header?: never;
49
87
  path: {
50
- subscription_id: string;
88
+ /** @description The Profile the Grant's subject names. */
89
+ profile_id: components["parameters"]["ProfileId"];
51
90
  };
52
91
  cookie?: never;
53
92
  };
54
- /** Read retained delivery status in event publication order */
55
- get: operations["getWebhookDeliveries"];
93
+ /**
94
+ * List a Profile's identities
95
+ * @description Granted by an `identity` authorization detail with `read` whose subject is this Profile. A token whose Grant names another subject answers `403`.
96
+ */
97
+ get: operations["listProfileIdentities"];
56
98
  put?: never;
57
99
  post?: never;
58
100
  delete?: never;
@@ -61,55 +103,76 @@ export interface paths {
61
103
  patch?: never;
62
104
  trace?: never;
63
105
  };
64
- "/event-subscriptions/{subscription_id}/deliveries/{delivery_id}/attempts": {
106
+ "/profiles/{profile_id}/addresses": {
65
107
  parameters: {
66
108
  query?: never;
67
109
  header?: never;
68
110
  path: {
69
- subscription_id: string;
70
- delivery_id: string;
111
+ /** @description The Profile the Grant's subject names. */
112
+ profile_id: components["parameters"]["ProfileId"];
71
113
  };
72
114
  cookie?: never;
73
115
  };
74
- /** Read all retained dispatch attempts in attempt order */
75
- get: operations["getWebhookAttempts"];
116
+ /**
117
+ * List a Profile's addresses
118
+ * @description Granted by an `address` authorization detail with `read` whose subject is this Profile.
119
+ */
120
+ get: operations["listProfileAddresses"];
76
121
  put?: never;
77
- post?: never;
122
+ /**
123
+ * Create an address for a Profile
124
+ * @description Granted by an `address` authorization detail with `create` whose subject is this Profile.
125
+ */
126
+ post: operations["createProfileAddress"];
78
127
  delete?: never;
79
128
  options?: never;
80
129
  head?: never;
81
130
  patch?: never;
82
131
  trace?: never;
83
132
  };
84
- "/event-subscriptions/{subscription_id}/deliveries/{delivery_id}/redrive": {
133
+ "/profiles/{profile_id}/addresses/{address_id}": {
85
134
  parameters: {
86
135
  query?: never;
87
136
  header?: never;
88
137
  path: {
89
- subscription_id: string;
90
- delivery_id: string;
138
+ /** @description The Profile the Grant's subject names. */
139
+ profile_id: components["parameters"]["ProfileId"];
140
+ address_id: components["parameters"]["AddressId"];
91
141
  };
92
142
  cookie?: never;
93
143
  };
94
144
  get?: never;
95
145
  put?: never;
96
- /** Queue a failed delivery without changing its immutable event identity */
97
- post: operations["redriveWebhookDelivery"];
98
- delete?: never;
146
+ post?: never;
147
+ /**
148
+ * Soft-delete one of a Profile's addresses
149
+ * @description Granted by an `address` authorization detail with `delete` whose subject is this Profile.
150
+ */
151
+ delete: operations["deleteProfileAddress"];
99
152
  options?: never;
100
153
  head?: never;
101
- patch?: never;
154
+ /**
155
+ * Update one of a Profile's addresses
156
+ * @description Granted by an `address` authorization detail with `update` whose subject is this Profile.
157
+ */
158
+ patch: operations["updateProfileAddress"];
102
159
  trace?: never;
103
160
  };
104
- "/authorization": {
161
+ "/profiles/{profile_id}/organizations": {
105
162
  parameters: {
106
163
  query?: never;
107
164
  header?: never;
108
- path?: never;
165
+ path: {
166
+ /** @description The Profile the Grant's subject names. */
167
+ profile_id: components["parameters"]["ProfileId"];
168
+ };
109
169
  cookie?: never;
110
170
  };
111
- /** Get the active Grant carried by the bearer token */
112
- get: operations["getGrantAuthorization"];
171
+ /**
172
+ * List the Organizations a Profile belongs to
173
+ * @description Granted by an `organization` authorization detail with `list` whose subject is this Profile. It names each Organization and grants no access to its data: ask for an Organization subject to read it.
174
+ */
175
+ get: operations["listProfileOrganizations"];
113
176
  put?: never;
114
177
  post?: never;
115
178
  delete?: never;
@@ -118,15 +181,21 @@ export interface paths {
118
181
  patch?: never;
119
182
  trace?: never;
120
183
  };
121
- "/organization-directory": {
184
+ "/organizations/{organization_id}/identities": {
122
185
  parameters: {
123
186
  query?: never;
124
187
  header?: never;
125
- path?: never;
188
+ path: {
189
+ /** @description The Organization the Grant's subject names. */
190
+ organization_id: components["parameters"]["OrganizationId"];
191
+ };
126
192
  cookie?: never;
127
193
  };
128
- /** List organization IDs and names for personal discovery */
129
- get: operations["getOrganizationDirectory"];
194
+ /**
195
+ * List an Organization's legal identities
196
+ * @description Granted by an `identity` authorization detail with `read` whose subject is this Organization.
197
+ */
198
+ get: operations["listOrganizationIdentities"];
130
199
  put?: never;
131
200
  post?: never;
132
201
  delete?: never;
@@ -135,41 +204,62 @@ export interface paths {
135
204
  patch?: never;
136
205
  trace?: never;
137
206
  };
138
- "/company-identity": {
207
+ "/organizations/{organization_id}/addresses": {
139
208
  parameters: {
140
209
  query?: never;
141
210
  header?: never;
142
- path?: never;
211
+ path: {
212
+ /** @description The Organization the Grant's subject names. */
213
+ organization_id: components["parameters"]["OrganizationId"];
214
+ };
143
215
  cookie?: never;
144
216
  };
145
- /** Get the legal identity selected by a Company data Grant */
146
- get: operations["getCompanyIdentity"];
217
+ /**
218
+ * List an Organization's addresses
219
+ * @description Granted by an `address` authorization detail with `read` whose subject is this Organization.
220
+ */
221
+ get: operations["listOrganizationAddresses"];
147
222
  put?: never;
148
- post?: never;
223
+ /**
224
+ * Create an address for an Organization
225
+ * @description Granted by an `address` authorization detail with `create` whose subject is this Organization.
226
+ */
227
+ post: operations["createOrganizationAddress"];
149
228
  delete?: never;
150
229
  options?: never;
151
230
  head?: never;
152
231
  patch?: never;
153
232
  trace?: never;
154
233
  };
155
- "/company-addresses": {
234
+ "/organizations/{organization_id}/addresses/{address_id}": {
156
235
  parameters: {
157
236
  query?: never;
158
237
  header?: never;
159
- path?: never;
238
+ path: {
239
+ /** @description The Organization the Grant's subject names. */
240
+ organization_id: components["parameters"]["OrganizationId"];
241
+ address_id: components["parameters"]["AddressId"];
242
+ };
160
243
  cookie?: never;
161
244
  };
162
- /** List addresses selected by a Company data Grant */
163
- get: operations["getCompanyAddresses"];
245
+ get?: never;
164
246
  put?: never;
165
247
  post?: never;
166
- delete?: never;
248
+ /**
249
+ * Soft-delete one of an Organization's addresses
250
+ * @description Granted by an `address` authorization detail with `delete` whose subject is this Organization.
251
+ */
252
+ delete: operations["deleteOrganizationAddress"];
167
253
  options?: never;
168
254
  head?: never;
169
- patch?: never;
255
+ /**
256
+ * Update one of an Organization's addresses
257
+ * @description Granted by an `address` authorization detail with `update` whose subject is this Organization.
258
+ */
259
+ patch: operations["updateOrganizationAddress"];
170
260
  trace?: never;
171
261
  };
172
- "/catalog/permissions": {
262
+ "/accounts": {
173
263
  parameters: {
174
264
  query?: never;
175
265
  header?: never;
@@ -177,10 +267,10 @@ export interface paths {
177
267
  cookie?: never;
178
268
  };
179
269
  /**
180
- * List the public Permission Catalog
181
- * @description The reference of the OAuth Scopes and Detailed Authorization types that live providers publish, with their actions, restrictions and request examples. It describes requestable capabilities, never a Profile, Company or Grant, and is the only resource in this API that requires no authorization.
270
+ * List personal bank accounts and balances
271
+ * @description Paginated by cursor, in publication order. `?alias=` switches from walking the collection to addressing one account by the identifier its holder chose: an exact match, not a search, and `after`/`limit` are ignored alongside it.
182
272
  */
183
- get: operations["getPermissionCatalog"];
273
+ get: operations["listAccounts"];
184
274
  put?: never;
185
275
  post?: never;
186
276
  delete?: never;
@@ -189,32 +279,38 @@ export interface paths {
189
279
  patch?: never;
190
280
  trace?: never;
191
281
  };
192
- "/userinfo": {
282
+ "/intents": {
193
283
  parameters: {
194
284
  query?: never;
195
285
  header?: never;
196
286
  path?: never;
197
287
  cookie?: never;
198
288
  };
199
- /** Get the authenticated user's standard identity claims */
200
- get: operations["getUserInfo"];
289
+ get?: never;
201
290
  put?: never;
202
- post?: never;
291
+ /**
292
+ * Create an intent under the exact OAuth Grant
293
+ * @description The same creation has two representations, and the content type picks between them. An `application/json` body is an Intent born waiting for an Approval. An `application/jwt` body is one Signed Instruction, sent as a compact JWS whose verified payload is `SignedTransferIntentClaims`, `SignedAccountOpeningIntentClaims` or `SignedAccountClosureIntentClaims`, and every value the operation uses comes from those claims and none from the envelope carrying them. A signed Intent is born approved when the signing client's Grant holds the family's `approve` action (`bank_transfer` or `bank_account`); otherwise it waits, like a proposal, for the person on the hosted screen or for `POST /intents/{intent_id}/approve` by a Grant that holds it. Opening and closing an account fail synchronously with `403 alias_out_of_grant` when the alias is outside the Grant's `accounts` patterns and with `409 alias_taken` when the alias names an account of the subject (always for a closed one; otherwise unless `upsert`). The new account's number arrives in the `account_opening.succeeded` event as `account: { id, alias, number, name }`.
294
+ */
295
+ post: operations["createIntent"];
203
296
  delete?: never;
204
297
  options?: never;
205
298
  head?: never;
206
299
  patch?: never;
207
300
  trace?: never;
208
301
  };
209
- "/identities": {
302
+ "/events": {
210
303
  parameters: {
211
304
  query?: never;
212
305
  header?: never;
213
306
  path?: never;
214
307
  cookie?: never;
215
308
  };
216
- /** List personal identities */
217
- get: operations["listIdentities"];
309
+ /**
310
+ * Replay every fact the exact Grant covers across the Organization
311
+ * @description One subscription for the whole Organization instead of one per account. Carries the same Intent facts as `/intents/{intent_id}/events` and the same account facts as `/accounts/{bank_account_id}/events`, re-evaluated as the Grant changes, so a Project never opens one subscription per account it may come to hold.
312
+ */
313
+ get: operations["readOrganizationEvents"];
218
314
  put?: never;
219
315
  post?: never;
220
316
  delete?: never;
@@ -223,53 +319,52 @@ export interface paths {
223
319
  patch?: never;
224
320
  trace?: never;
225
321
  };
226
- "/addresses": {
322
+ "/accounts/{bank_account_id}/events": {
227
323
  parameters: {
228
324
  query?: never;
229
325
  header?: never;
230
326
  path?: never;
231
327
  cookie?: never;
232
328
  };
233
- /** List personal addresses */
234
- get: operations["listAddresses"];
329
+ /** Replay bank facts with account transaction read permission */
330
+ get: operations["readAccountEvents"];
235
331
  put?: never;
236
- /** Create a personal address */
237
- post: operations["createAddress"];
332
+ post?: never;
238
333
  delete?: never;
239
334
  options?: never;
240
335
  head?: never;
241
336
  patch?: never;
242
337
  trace?: never;
243
338
  };
244
- "/addresses/{address_id}": {
339
+ "/accounts/{bank_account_id}/transactions": {
245
340
  parameters: {
246
341
  query?: never;
247
342
  header?: never;
248
- path: {
249
- address_id: string;
250
- };
343
+ path?: never;
251
344
  cookie?: never;
252
345
  };
253
- get?: never;
346
+ /**
347
+ * List one account's transactions
348
+ * @description Answers with the same cursor page the account's statement presentation reads, so an integrator sees exactly the transactions a person would see. Granted by a `bank_transaction` authorization detail with `read` whose `accounts` reach this account.
349
+ */
350
+ get: operations["listAccountTransactions"];
254
351
  put?: never;
255
352
  post?: never;
256
- /** Soft-delete one personal address */
257
- delete: operations["deleteAddress"];
353
+ delete?: never;
258
354
  options?: never;
259
355
  head?: never;
260
- /** Update one personal address */
261
- patch: operations["updateAddress"];
356
+ patch?: never;
262
357
  trace?: never;
263
358
  };
264
- "/accounts": {
359
+ "/intents/{intent_id}/events": {
265
360
  parameters: {
266
361
  query?: never;
267
362
  header?: never;
268
363
  path?: never;
269
364
  cookie?: never;
270
365
  };
271
- /** List personal bank accounts and balances */
272
- get: operations["listAccounts"];
366
+ /** Replay durable facts for one authorized Intent */
367
+ get: operations["readIntentEvents"];
273
368
  put?: never;
274
369
  post?: never;
275
370
  delete?: never;
@@ -278,58 +373,70 @@ export interface paths {
278
373
  patch?: never;
279
374
  trace?: never;
280
375
  };
281
- "/intents": {
376
+ "/intents/{intent_id}": {
282
377
  parameters: {
283
378
  query?: never;
284
379
  header?: never;
285
- path?: never;
380
+ path: {
381
+ intent_id: string;
382
+ };
286
383
  cookie?: never;
287
384
  };
288
- get?: never;
385
+ /** Read one intent created under the same exact OAuth Grant */
386
+ get: operations["getIntent"];
289
387
  put?: never;
290
- /** Create an intent under the exact OAuth Grant */
291
- post: operations["createIntent"];
388
+ post?: never;
292
389
  delete?: never;
293
390
  options?: never;
294
391
  head?: never;
295
392
  patch?: never;
296
393
  trace?: never;
297
394
  };
298
- "/accounts/{bank_account_id}/events": {
395
+ "/intents/{intent_id}/close": {
299
396
  parameters: {
300
397
  query?: never;
301
398
  header?: never;
302
- path?: never;
399
+ path: {
400
+ intent_id: string;
401
+ };
303
402
  cookie?: never;
304
403
  };
305
- /** Replay bank facts with account movement read permission */
306
- get: operations["readAccountEvents"];
404
+ get?: never;
307
405
  put?: never;
308
- post?: never;
406
+ /**
407
+ * Close this application's no-target deposit collection with an explicit close Grant action
408
+ * @description Idempotent. Preserves existing terminal outcomes. Does not move funds, cancel accepted bank commands, or grant account transaction access.
409
+ */
410
+ post: operations["closeDeposit"];
309
411
  delete?: never;
310
412
  options?: never;
311
413
  head?: never;
312
414
  patch?: never;
313
415
  trace?: never;
314
416
  };
315
- "/intents/{intent_id}/events": {
417
+ "/intents/{intent_id}/approve": {
316
418
  parameters: {
317
419
  query?: never;
318
420
  header?: never;
319
- path?: never;
421
+ path: {
422
+ intent_id: string;
423
+ };
320
424
  cookie?: never;
321
425
  };
322
- /** Replay durable facts for one authorized Intent */
323
- get: operations["readIntentEvents"];
426
+ get?: never;
324
427
  put?: never;
325
- post?: never;
428
+ /**
429
+ * Approve an Intent with a Grant holding the family's approve action
430
+ * @description Approval by a credential, without a person: the Grant behind the token must hold `approve` on the family that releases this Intent type (`bank_transfer` for a transfer) for the same subject, and within that detail's `transactions.maximum`. Above it the call answers `422 amount_out_of_grant` and the Intent stays pending for another approver. A transfer whose source is still for a person to pick answers `409 interaction_required`. Accepted is not moved: wait for `transfer.succeeded` or `transfer.failed`. Safe to retry.
431
+ */
432
+ post: operations["approveIntent"];
326
433
  delete?: never;
327
434
  options?: never;
328
435
  head?: never;
329
436
  patch?: never;
330
437
  trace?: never;
331
438
  };
332
- "/intents/{intent_id}": {
439
+ "/intents/{intent_id}/reject": {
333
440
  parameters: {
334
441
  query?: never;
335
442
  header?: never;
@@ -338,17 +445,20 @@ export interface paths {
338
445
  };
339
446
  cookie?: never;
340
447
  };
341
- /** Read one intent created under the same exact OAuth Grant */
342
- get: operations["getIntent"];
448
+ get?: never;
343
449
  put?: never;
344
- post?: never;
450
+ /**
451
+ * Reject an Intent with a Grant holding the family's reject action
452
+ * @description An approver declining an Intent, recorded as a Rejection and kept apart from a Cancellation (the creator withdrawing it). The Grant behind the token must hold `reject` on the family that releases this Intent type for the same subject; no maximum applies to a rejection. Answers `409 intent_expired` when the Intent's deadline has passed.
453
+ */
454
+ post: operations["rejectIntent"];
345
455
  delete?: never;
346
456
  options?: never;
347
457
  head?: never;
348
458
  patch?: never;
349
459
  trace?: never;
350
460
  };
351
- "/intents/{intent_id}/close": {
461
+ "/intents/{intent_id}/cancel": {
352
462
  parameters: {
353
463
  query?: never;
354
464
  header?: never;
@@ -360,29 +470,30 @@ export interface paths {
360
470
  get?: never;
361
471
  put?: never;
362
472
  /**
363
- * Close this application's no-target deposit collection with an explicit close Grant action
364
- * @description Idempotent. Preserves existing terminal outcomes. Does not move funds, cancel accepted bank commands, or grant account movement access.
473
+ * Withdraw an Intent the calling client created
474
+ * @description A Cancellation is the creator withdrawing its own request: only the client and Grant that created the Intent may cancel it. An approver declining it uses `reject`, and the audit keeps the two apart. Records why: an Intent that vanished without a reason is an unexplained gap. Answers `409 intent_expired` when the Intent's deadline to be approved and executed has already passed.
365
475
  */
366
- post: operations["closeDeposit"];
476
+ post: operations["cancelIntent"];
367
477
  delete?: never;
368
478
  options?: never;
369
479
  head?: never;
370
480
  patch?: never;
371
481
  trace?: never;
372
482
  };
373
- "/intents/{intent_id}/execute": {
483
+ "/signatures/verify": {
374
484
  parameters: {
375
485
  query?: never;
376
486
  header?: never;
377
- path: {
378
- intent_id: string;
379
- };
487
+ path?: never;
380
488
  cookie?: never;
381
489
  };
382
490
  get?: never;
383
491
  put?: never;
384
- /** Execute a withdrawal when its exact OAuth Grant permits non-interactive execution */
385
- post: operations["executeWithdrawal"];
492
+ /**
493
+ * Verify a Signed Instruction against the OAuth Client's registered keys, without acting on it
494
+ * @description Verifies the assertion's signature, `kid`, algorithm, issuer, audience and expiration against the Signing Keys the presenting OAuth Client has registered, and returns its verified claims untouched. Acts on nothing: this is the smallest surface that exercises signing end to end, so an integrator can confirm that the key it registered, the `kid` its SDK derived and the claims it signs all line up before any of them is submitted to create, execute or approve an Intent. Requires only a valid OAuth bearer token, no scope or authorization detail.
495
+ */
496
+ post: operations["verifySignature"];
386
497
  delete?: never;
387
498
  options?: never;
388
499
  head?: never;
@@ -393,94 +504,53 @@ export interface paths {
393
504
  export type webhooks = Record<string, never>;
394
505
  export interface components {
395
506
  schemas: {
396
- WebhookDelivery: {
397
- /** Format: uuid */
398
- id: string;
399
- /** Format: uuid */
400
- subscription_id: string;
401
- /** Format: uuid */
402
- event_id: string;
403
- event_type: string;
404
- /** Format: date-time */
405
- occurred_at: string;
406
- /** @enum {string} */
407
- status: "pending" | "retrying" | "exhausted" | "succeeded";
408
- attempts: number;
409
- total_attempts: number;
410
- /** Format: date-time */
411
- next_attempt_at: string;
412
- /** Format: date-time */
413
- last_attempt_at: string | null;
414
- /** Format: date-time */
415
- delivered_at: string | null;
416
- last_status_code: number | null;
417
- last_error: string | null;
418
- redrive_count: number;
419
- /** Format: date-time */
420
- redriven_at: string | null;
421
- cursor: string;
422
- };
423
- WebhookDeliveryPage: {
424
- items: components["schemas"]["WebhookDelivery"][];
425
- has_more: boolean;
426
- next_cursor: string;
427
- };
428
- WebhookAttempt: {
507
+ ProjectProfile: {
429
508
  /** Format: uuid */
430
509
  id: string;
431
- /** Format: uuid */
432
- delivery_id: string;
433
- number: number;
434
- /** Format: date-time */
435
- started_at: string;
436
- /** Format: date-time */
437
- finished_at: string | null;
438
- status_code: number | null;
439
- error: string | null;
440
- cursor: string;
441
- };
442
- WebhookAttemptPage: {
443
- items: components["schemas"]["WebhookAttempt"][];
444
- has_more: boolean;
445
- next_cursor: string;
446
- };
447
- WebhookSubscriptionCreate: {
448
- subject: {
449
- /** @enum {string} */
450
- kind: "intent" | "account";
451
- /** Format: uuid */
452
- id: string;
453
- };
510
+ name: string | null;
511
+ email: string | null;
454
512
  /** Format: uri */
455
- url: string;
456
- event_types: string[];
457
- signing_secret: string;
513
+ avatar: string | null;
514
+ phone: string | null;
515
+ identities: components["schemas"]["ProfileIdentity"][] | null;
516
+ addresses: components["schemas"]["Address"][] | null;
458
517
  };
459
- WebhookSubscription: {
460
- /** Format: uuid */
461
- id: string;
462
- /** @enum {string} */
463
- subject_kind: "intent" | "account";
464
- /** Format: uuid */
465
- subject_id: string;
466
- url: string;
467
- event_types: string[];
468
- /** @enum {string} */
469
- verification_status: "pending" | "verified" | "failed" | "disabled";
470
- /** Format: date-time */
471
- created_at: string;
472
- /** Format: date-time */
473
- verified_at: string | null;
474
- verification_attempts: number;
475
- verification_error: string | null;
518
+ ProjectProfilePage: {
519
+ data: components["schemas"]["ProjectProfile"][];
520
+ has_more: boolean;
521
+ next_cursor: string | null;
476
522
  };
477
523
  ApiError: {
478
524
  error: string;
479
525
  required_scope?: string;
526
+ /** @description RAR type the Grant has to cover for this operation, on `insufficient_authorization`. */
527
+ required_type?: string;
480
528
  required_action?: string;
481
529
  code?: string;
482
530
  message?: string;
483
531
  };
532
+ /** @description The verified `kid`, algorithm and claims of a Signed Instruction that verified against the presenting OAuth Client's registered keys. `claims` is the decoded JWT payload as signed -- this operation checks only `exp` and `jti` structurally and otherwise passes every claim through untouched, so it never narrows to one Intent family's claim schema. */
533
+ SignedInstructionVerification: {
534
+ /** @description RFC 7638 JWK Thumbprint of the Signing Key that verified the assertion. */
535
+ key_id: string;
536
+ /** @enum {string} */
537
+ algorithm: "RS256" | "ES256";
538
+ claims: {
539
+ [key: string]: unknown;
540
+ };
541
+ };
542
+ SignedInstructionInvalidError: {
543
+ /** @constant */
544
+ error: "invalid_signed_instruction";
545
+ /**
546
+ * @description One cause, never a generic failure: malformed_assertion, missing_key_id, disallowed_algorithm, unknown_key, revoked_key, unusable_key, invalid_signature, expired_assertion, premature_assertion, missing_expiration, missing_instruction_id, missing_claim, wrong_audience, wrong_issuer, or verification_failed.
547
+ * @enum {string}
548
+ */
549
+ reason: "malformed_assertion" | "missing_key_id" | "disallowed_algorithm" | "unknown_key" | "revoked_key" | "unusable_key" | "invalid_signature" | "expired_assertion" | "premature_assertion" | "missing_expiration" | "missing_instruction_id" | "missing_claim" | "wrong_audience" | "wrong_issuer" | "verification_failed";
550
+ detail: string;
551
+ /** @description The `kid` the assertion declared, when one could be read from it. */
552
+ key_id?: string | null;
553
+ };
484
554
  GrantAuthorization: {
485
555
  /** @constant */
486
556
  active: true;
@@ -488,15 +558,12 @@ export interface components {
488
558
  authorizationDetails: {
489
559
  [key: string]: unknown;
490
560
  }[];
491
- orgId?: string | null;
492
561
  /** Format: uuid */
493
562
  clientId: string;
494
563
  /** Format: uuid */
495
564
  grantId: string;
496
565
  /** Format: uri */
497
566
  resource: string;
498
- /** Format: uuid */
499
- consumerInstallationId: string | null;
500
567
  scopes: string[];
501
568
  subject: components["schemas"]["GrantSubject"];
502
569
  };
@@ -528,15 +595,15 @@ export interface components {
528
595
  name?: string;
529
596
  /** Format: uri */
530
597
  picture?: string;
598
+ /** @description The Profile's phone number, present when the `phone` scope is granted and a number is on file. */
599
+ phone?: string;
600
+ /** @description Present and `true` when the `phone` scope is granted and the number was confirmed. */
601
+ phone_verified?: boolean;
531
602
  };
532
- Identity: {
603
+ ProfileIdentity: {
533
604
  /** Format: uuid */
534
605
  id: string;
535
606
  country: string;
536
- level1: string | null;
537
- level2: string | null;
538
- level3: string | null;
539
- street_address: string | null;
540
607
  nationality: string | null;
541
608
  /** Format: date */
542
609
  born_date: string | null;
@@ -546,9 +613,24 @@ export interface components {
546
613
  document_value: string;
547
614
  given_names: string | null;
548
615
  family_names: string | null;
616
+ business_activity_code: string | null;
617
+ };
618
+ ProfileIdentityPage: {
619
+ data: components["schemas"]["ProfileIdentity"][];
620
+ next_cursor: string | null;
621
+ has_more: boolean;
622
+ };
623
+ OrganizationIdentity: {
624
+ /** Format: uuid */
625
+ id: string;
626
+ legal_name: string;
627
+ country: string;
628
+ /** @constant */
629
+ document_kind: "rut";
630
+ document_value: string;
549
631
  };
550
- IdentityPage: {
551
- data: components["schemas"]["Identity"][];
632
+ OrganizationIdentityPage: {
633
+ data: components["schemas"]["OrganizationIdentity"][];
552
634
  next_cursor: string | null;
553
635
  has_more: boolean;
554
636
  };
@@ -599,21 +681,6 @@ export interface components {
599
681
  /** Format: uuid */
600
682
  id: string;
601
683
  };
602
- CompanyIdentity: {
603
- companyId: string;
604
- legalName: string;
605
- countryCode: string;
606
- legalIdentifier: components["schemas"]["LegalIdentifier"];
607
- };
608
- CompanyAddresses: {
609
- companyId: string;
610
- addresses: components["schemas"]["CompanyAddress"][];
611
- };
612
- LegalIdentifier: {
613
- /** @constant */
614
- kind: "rut";
615
- value: string;
616
- };
617
684
  PermissionCatalogPage: {
618
685
  data: components["schemas"]["PermissionCatalogEntry"][];
619
686
  nextCursor: string | null;
@@ -640,61 +707,141 @@ export interface components {
640
707
  };
641
708
  examples: unknown[];
642
709
  };
643
- CompanyAddress: {
644
- /** Format: uuid */
645
- addressId: string;
646
- countryCode: string;
647
- level1?: string;
648
- level2?: string;
649
- level3?: string;
650
- streetAddress?: string;
651
- /** @enum {string} */
652
- labelKind: "home" | "work" | "other";
653
- labelName?: string;
654
- /** Format: int32 */
655
- priority: number;
656
- };
657
710
  BankAccount: {
658
711
  /** Format: uuid */
659
712
  id: string;
713
+ /** @description The Account Alias its holder chose, or null for an account opened before aliases existed. Exact-match input for `GET /accounts?alias=`. */
714
+ alias: string | null;
715
+ /** @description The account's own name, the one `account_opening.succeeded` announces; the product name only for an account nobody named. */
660
716
  name: string;
661
717
  number: string;
662
718
  type: string;
663
719
  currency: string;
664
720
  balance: string;
665
721
  };
666
- BankAccountReference: {
667
- bank_id: string;
668
- /** @constant */
669
- country: "CL";
670
- account_number: string;
671
- /** @enum {string} */
672
- account_kind: "checking" | "debit" | "savings";
673
- account_holder_id: string;
674
- account_holder_name: string;
722
+ /** @description A cursor page of accounts, in the same opaque-cursor shape as `FinancialEventPage`: `next_cursor` is only ever fed back as `?after=`, never parsed by the caller. */
723
+ AccountPage: {
724
+ data: components["schemas"]["BankAccount"][];
725
+ next_cursor: string;
726
+ has_more: boolean;
675
727
  };
676
- WithdrawalBeneficiary: components["schemas"]["BankAccountReference"] & {
677
- editable?: boolean;
728
+ /** @description One account transaction, newest first. Keys are camelCase because this schema describes the wire shape the server actually sends here, which differs from the snake_case used by the rest of this contract -- the route answers with its existing internal projection rather than a bespoke public representation. */
729
+ BankTransaction: {
730
+ /** Format: uuid */
731
+ id: string;
732
+ transactionId: string | null;
733
+ description: string;
734
+ /** @description Issued by the external bank, not by Andco, and republished exactly as the bank sent it: the server never normalizes it, because normalizing risks inventing a value the issuer never sent, and reconciliation only checks out if this figure matches the bank's own record byte for byte. That is also why it carries none of the digit-count bound that an Andco-defined amount does -- tightening this pattern would turn a reporting quirk from the bank into a hard rejection of a legitimate bank fact. The sign is real: a transaction is an accounting fact with a direction, unlike a requested amount, which is never negative. The pattern's decimal part is accepted by the parser; nothing here asserts the bank actually sends fractional amounts. */
735
+ amount: string;
736
+ type: string;
737
+ origin: string | null;
738
+ /** Format: date-time */
739
+ date: string;
740
+ /** @description Same provenance and the same reason for the unbounded pattern as `amount` above: issued by the external bank and republished exactly, never normalized, so reconciliation can compare it byte for byte against the bank's own record. Real balances do go negative, so the sign is not narrowed away. */
741
+ runningBalance: string | null;
742
+ paymentType: string | null;
743
+ reversed: boolean;
744
+ note: string | null;
678
745
  };
679
- WithdrawalAmount: {
746
+ BankTransactionPage: {
747
+ data: components["schemas"]["BankTransaction"][];
748
+ nextCursor: string | null;
749
+ pageSize: number;
750
+ };
751
+ /** @description The monetary scalar, defined once. It travels as a string because CLP has no minor unit and an exact peso amount does not survive a JSON number. Every envelope carries it as `value`: what a request or a Signed Instruction asks for, what an Intent was asked for, and what a transfer actually moved (`settled.value`). */
752
+ MonetaryValue: string;
753
+ /** @description The Account Alias its holder chose for one of its own accounts: unique per holder and immutable. It is resolved on every operation rather than once, so it travels in the body and never in a path segment. */
754
+ AccountAlias: string;
755
+ /** @description One Andco account of the Grant's subject, named by its Account Alias. */
756
+ IntentAccountAlias: {
680
757
  /** @constant */
681
- currency: "CLP";
682
- suggested: string;
758
+ type: "alias";
759
+ alias: components["schemas"]["AccountAlias"];
760
+ };
761
+ /** @description One Andco account, named by its identifier. */
762
+ IntentAccountId: {
763
+ /** @constant */
764
+ type: "account";
765
+ /** Format: uuid */
766
+ id: string;
767
+ };
768
+ /** @description One account at another Chilean bank, with every field a `bank_transfer` `external` matcher can fix, so the Grant's destinations are asked about exactly this account. */
769
+ IntentAccountExternal: {
770
+ /** @constant */
771
+ type: "external";
772
+ bank_id: string;
773
+ /** @enum {string} */
774
+ account_type: "checking" | "debit" | "savings";
775
+ account_id: string;
776
+ holder_id: string;
777
+ holder_name: string;
778
+ };
779
+ /** @description One Andco account of the Grant's subject, in the account matcher vocabulary: by Account Alias (`{ type: "alias", alias }`) or by identifier (`{ type: "account", id }`). It is where a transfer's money leaves from, where a deposit lands and the account a closure closes. An Alias is answered back as an Alias: it resolves to an account at execution. */
780
+ IntentAccount: components["schemas"]["IntentAccountAlias"] | components["schemas"]["IntentAccountId"];
781
+ /** @description Where a signed transfer's money lands, in the `bank_transfer` matcher vocabulary: an Andco account by Alias or identifier, or an account at another Chilean bank. */
782
+ TransferDestination: components["schemas"]["IntentAccountAlias"] | components["schemas"]["IntentAccountId"] | components["schemas"]["IntentAccountExternal"];
783
+ /** @description Where a proposed transfer's money lands, in the request and in the answered Intent alike. `editable: false` locks it on the confirmation screen. Only an account at another bank can be editable, because an Andco account named by Alias or identifier already denotes exactly one account. Defaults to false in a request; an answered Intent always states it. */
784
+ TransferDestinationProposal: {
785
+ /** @constant */
786
+ type: "alias";
787
+ alias: components["schemas"]["AccountAlias"];
788
+ /** @constant */
789
+ editable?: false;
790
+ } | {
791
+ /** @constant */
792
+ type: "account";
793
+ /** Format: uuid */
794
+ id: string;
795
+ /** @constant */
796
+ editable?: false;
797
+ } | {
798
+ /** @constant */
799
+ type: "external";
800
+ bank_id: string;
801
+ /** @enum {string} */
802
+ account_type: "checking" | "debit" | "savings";
803
+ account_id: string;
804
+ holder_id: string;
805
+ holder_name: string;
806
+ editable?: boolean;
807
+ };
808
+ /** @description The amount a request asks for. `editable: true` lets the person who confirms change it on the screen. It is never what moved: a transfer answers that in `settled`, a deposit in `progress.credited`. */
809
+ IntentAmount: {
810
+ /** @constant */
811
+ currency: "CLP";
812
+ value: components["schemas"]["MonetaryValue"];
813
+ /** @description Defaults to false when omitted. */
683
814
  editable?: boolean;
684
815
  };
685
- WithdrawalAmountResolved: {
816
+ /** @description The amount a Signed Instruction orders: the same `{ currency, value }` as a request, with nothing left for a person to change. */
817
+ SignedAmount: {
818
+ /** @constant */
819
+ currency: "CLP";
820
+ value: components["schemas"]["MonetaryValue"];
821
+ };
822
+ /** @description The amount a transfer orders, as it is answered: the request's `value`, or the person's correction once confirmed when `editable` is true. It is never proof that money moved; read `settled` for that. */
823
+ TransferAmount: {
686
824
  /** @constant */
687
825
  currency: "CLP";
688
- suggested: string;
826
+ value: components["schemas"]["MonetaryValue"];
689
827
  editable: boolean;
690
828
  };
829
+ /** @description The money a transfer actually moved and when it settled. Present only once the transfer `succeeded`; null before, and null for ever when it fails, is rejected, cancelled or expires. */
830
+ TransferSettlement: {
831
+ /** @constant */
832
+ currency: "CLP";
833
+ value: components["schemas"]["MonetaryValue"];
834
+ /** Format: date-time */
835
+ at: string;
836
+ };
837
+ /** @description The amount a deposit asks for. `value` is the request's, `confirmed` the payer's own target when `editable`; what arrived is `progress.credited`, never these. */
691
838
  DepositTarget: {
692
839
  /** @constant */
693
840
  currency: "CLP";
694
- /** @description Immutable application suggestion from the creation request. */
695
- suggested: string;
841
+ /** @description Immutable amount from the creation request. */
842
+ value: components["schemas"]["MonetaryValue"];
696
843
  editable: boolean;
697
- /** @description Explicitly confirmed target; the suggestion applies until confirmation. */
844
+ /** @description Explicitly confirmed target; `value` applies until confirmation. */
698
845
  confirmed: string | null;
699
846
  /**
700
847
  * Format: date-time
@@ -723,13 +870,21 @@ export interface components {
723
870
  /** Format: date-time */
724
871
  server_time: string;
725
872
  };
726
- /** @description Common suggestion; each bank operation freezes its own final note at confirmation. */
873
+ /** @description The bank reference a request asks for. `editable: true` lets the person who confirms change it; each bank operation freezes its own final note at confirmation. */
727
874
  IntentNote: {
728
- /** @description Trimmed bank reference suggestion. An empty reference is allowed. */
729
- suggested: string;
875
+ /** @description Trimmed bank reference. An empty reference is allowed. */
876
+ value: string;
730
877
  /** @description Defaults to false when omitted. */
731
878
  editable?: boolean;
732
879
  };
880
+ /** @description Cancelling names why, because an Intent that vanished without a reason is an unexplained gap. */
881
+ IntentCancellation: {
882
+ reason: string;
883
+ };
884
+ /** @description An approver declining an Intent names why. The audit keeps a Rejection apart from a Cancellation, which is the creator withdrawing its own request. */
885
+ IntentRejection: {
886
+ reason: string;
887
+ };
733
888
  DepositIntentCreate: ({
734
889
  /** @description Positive fixed duration, anchored once when the operation is first created. */
735
890
  expires_in?: string;
@@ -740,15 +895,26 @@ export interface components {
740
895
  expires_at?: string | null;
741
896
  /** @constant */
742
897
  type: "deposit";
743
- amount?: components["schemas"]["WithdrawalAmount"];
898
+ /** @description The account of the Grant's subject the money lands on. Omitted, the Grant's `bank_deposit` destinations must admit exactly one active account, or the request fails with `deposit_destination_ambiguous`; named, it must be one of them, or the request fails with `invalid_destination`. */
899
+ destination?: components["schemas"]["IntentAccount"];
900
+ amount?: components["schemas"]["IntentAmount"];
744
901
  note?: components["schemas"]["IntentNote"];
745
902
  metadata?: {
746
903
  [key: string]: unknown;
747
904
  };
748
905
  } & unknown) & (unknown | unknown);
749
- DepositDestination: components["schemas"]["BankAccountReference"] & {
906
+ /** @description The Andco account a deposit lands on: the `{ type: "account", id }` matcher plus what a payer at another bank types to pay into it. `holder_id` and `holder_name` are masked when the reader may not see them. */
907
+ DepositDestination: {
908
+ /** @constant */
909
+ type: "account";
750
910
  /** Format: uuid */
751
- bank_account_id: string;
911
+ id: string;
912
+ number: string;
913
+ /** @enum {string} */
914
+ account_type: "checking" | "debit" | "savings";
915
+ /** @description Null when the holder has no identity document on file. */
916
+ holder_id: string | null;
917
+ holder_name: string;
752
918
  };
753
919
  DepositProgress: {
754
920
  credited: string;
@@ -771,7 +937,7 @@ export interface components {
771
937
  account_type: "checking" | "debit" | "savings" | null;
772
938
  /** @constant */
773
939
  currency: "CLP";
774
- amount: string;
940
+ amount: components["schemas"]["MonetaryValue"];
775
941
  transaction_id?: string;
776
942
  };
777
943
  DepositCloseResult: {
@@ -839,43 +1005,42 @@ export interface components {
839
1005
  /** Format: uri */
840
1006
  authorization_url: string;
841
1007
  };
842
- WithdrawalIntentCreate: {
1008
+ /** @description The `application/json` half of creating a transfer: an Intent born waiting for an Approval. A null `source` is the confirmation screen, where a person picks the account the money leaves from among the Grant's sources; `editable: false` locks the destination there. The `application/jwt` half is `SignedTransferIntentClaims`, and the two are separate schemas rather than one with optional fields on purpose: when signed and unsigned members share an object, something eventually reads the wrong ones. */
1009
+ TransferIntentCreate: {
843
1010
  /** @description Positive fixed duration, anchored once when the operation is first created. */
844
1011
  expires_in?: string;
845
1012
  /**
846
1013
  * Format: date-time
847
- * @description Absolute deadline with an explicit timezone. Exactly one expiration field is required.
1014
+ * @description Absolute deadline with an explicit timezone. Exactly one expiration field is required, and a transfer may not omit or null it.
848
1015
  */
849
1016
  expires_at?: string;
850
1017
  /** @constant */
851
- type: "withdrawal";
852
- source?: null | {
853
- /** Format: uuid */
854
- bank_account_id: string;
855
- } | components["schemas"]["BankAccountReference"];
856
- beneficiary: components["schemas"]["WithdrawalBeneficiary"] | components["schemas"]["InternalBankAccountReference"];
857
- amount: components["schemas"]["WithdrawalAmount"];
1018
+ type: "transfer";
1019
+ /** @description The Andco account the money leaves. Null leaves that choice to a person on a screen. */
1020
+ source?: null | components["schemas"]["IntentAccount"];
1021
+ destination: components["schemas"]["TransferDestinationProposal"];
1022
+ amount: components["schemas"]["IntentAmount"];
858
1023
  note?: components["schemas"]["IntentNote"];
859
1024
  metadata?: {
860
1025
  [key: string]: unknown;
861
1026
  };
862
1027
  } & (unknown | unknown);
863
- /** @enum {string} */
864
- IntentStatus: "requires_action" | "processing.confirmed" | "processing.settling" | "processing.reversing" | "processing.reconciling" | "succeeded" | "failed" | "failed.insufficient_funds" | "cancelled" | "expired";
865
- WithdrawalIntent: {
1028
+ /** @description Authoritative Project-facing state of a transfer. `source` and `destination` answer in the same matcher vocabulary as the request. `amount` is what the transfer orders and `settled` what it moved: reconciliation reads `settled`, which stays null until the money moved. */
1029
+ TransferIntent: {
866
1030
  /** Format: uuid */
867
1031
  id: string;
868
1032
  /** Format: uri */
869
1033
  resource_server: string;
870
1034
  /** @constant */
871
- type: "withdrawal";
1035
+ type: "transfer";
872
1036
  status: components["schemas"]["IntentStatus"];
873
- source?: {
874
- /** Format: uuid */
875
- bank_account_id: string;
876
- } | components["schemas"]["BankAccountReference"];
877
- beneficiary: components["schemas"]["WithdrawalBeneficiary"];
878
- amount: components["schemas"]["WithdrawalAmountResolved"];
1037
+ /** @description Whether a Signed Instruction created this Intent rather than a plain request. */
1038
+ signed: boolean;
1039
+ /** @description Null while the person has yet to pick where the money leaves from. An Alias is answered back as an Alias, because it stays unresolved until execution. */
1040
+ source: null | components["schemas"]["IntentAccount"];
1041
+ destination: components["schemas"]["TransferDestinationProposal"];
1042
+ amount: components["schemas"]["TransferAmount"];
1043
+ settled: null | components["schemas"]["TransferSettlement"];
879
1044
  fee: {
880
1045
  /** @constant */
881
1046
  currency: "CLP";
@@ -897,53 +1062,66 @@ export interface components {
897
1062
  /** Format: uri */
898
1063
  authorization_url: string;
899
1064
  };
900
- AutomaticChargeIntentCreate: {
901
- /** @description Positive fixed duration, anchored once when the operation is first created. */
902
- expires_in?: string;
1065
+ /** @description The `application/json` half of opening a Cuenta Vista: an Intent born waiting for an Approval. `/accounts` has no `POST` because everything with banking consequence happens through an Intent, and an opening carries no amount, no source and no destination -- only the name the account will answer to. Opening is asynchronous: the answer is the Intent and its status, and the Número de Cuenta arrives on the account's event stream. */
1066
+ AccountOpeningIntentCreate: {
1067
+ /** @constant */
1068
+ type: "account_opening";
1069
+ alias: components["schemas"]["AccountAlias"];
1070
+ /** @description The display label the account opens with. Mutable afterwards, and read by no permission. */
1071
+ name?: string;
903
1072
  /**
904
- * Format: date-time
905
- * @description Absolute deadline with an explicit timezone. Exactly one expiration field is required.
1073
+ * @description Whether naming an Alias that already exists answers with that account instead of failing. It defaults to false, so one name never quietly becomes two accounts.
1074
+ * @default false
906
1075
  */
1076
+ upsert: boolean;
1077
+ expires_in?: string;
1078
+ /** Format: date-time */
907
1079
  expires_at?: string;
908
- /** @constant */
909
- type: "automatic_charge";
910
- source?: null | components["schemas"]["InternalBankAccountReference"];
911
- beneficiary: components["schemas"]["InternalBankAccountReference"];
912
- amount: {
913
- /** @constant */
914
- currency: "CLP";
915
- suggested: string;
916
- /** @constant */
917
- editable?: false;
918
- };
919
1080
  note?: components["schemas"]["IntentNote"];
920
1081
  metadata?: {
921
1082
  [key: string]: unknown;
922
1083
  };
923
1084
  } & (unknown | unknown);
924
- InternalBankAccountReference: {
925
- /** Format: uuid */
926
- bank_account_id: string;
927
- };
928
- AutomaticChargeIntent: {
1085
+ /** @description The verified claims of a Signed Instruction that opens an account. `upsert` lives here and nowhere else: it decides whether naming an Alias that already exists is a refusal or a request for the account already carrying it, which is a difference in what the instruction *orders*. Carried as a transport option, anybody holding the signed instruction could flip it, and what executed would not be what was signed. */
1086
+ SignedAccountOpeningIntentClaims: {
1087
+ iss: string;
1088
+ /** @constant */
1089
+ aud: "https://api.andco.com";
1090
+ /** @description The idempotency key, inside the signature, reused verbatim when retrying. */
1091
+ jti: string;
1092
+ exp: number;
1093
+ iat?: number;
1094
+ nbf?: number;
1095
+ /** @constant */
1096
+ type: "account_opening";
1097
+ alias: components["schemas"]["AccountAlias"];
1098
+ name?: string;
1099
+ /** @default false */
1100
+ upsert: boolean;
1101
+ expires_in?: string;
1102
+ /** Format: date-time */
1103
+ expires_at?: string;
1104
+ metadata?: {
1105
+ [key: string]: unknown;
1106
+ };
1107
+ } & (unknown | unknown);
1108
+ /** @description Authoritative Project-facing state of an account opening. It carries no amount and no fee: an opening moves no money. Opening is asynchronous, so `account.bank_account_id` is absent until the core assigns the Número de Cuenta, which arrives on the account's own event stream rather than in this response. */
1109
+ AccountOpeningIntent: {
929
1110
  /** Format: uuid */
930
1111
  id: string;
931
1112
  /** Format: uri */
932
1113
  resource_server: string;
933
1114
  /** @constant */
934
- type: "automatic_charge";
1115
+ type: "account_opening";
935
1116
  status: components["schemas"]["IntentStatus"];
936
- source?: {
1117
+ /** @description Whether a Signed Instruction created this Intent rather than a plain request. */
1118
+ signed: boolean;
1119
+ account: {
1120
+ alias: components["schemas"]["AccountAlias"];
1121
+ name: string;
1122
+ upsert: boolean;
937
1123
  /** Format: uuid */
938
- bank_account_id: string;
939
- } | components["schemas"]["BankAccountReference"];
940
- beneficiary: components["schemas"]["WithdrawalBeneficiary"];
941
- amount: components["schemas"]["WithdrawalAmountResolved"];
942
- fee: {
943
- /** @constant */
944
- currency: "CLP";
945
- /** @constant */
946
- amount: "0";
1124
+ bank_account_id: string | null;
947
1125
  };
948
1126
  note?: components["schemas"]["IntentNote"];
949
1127
  metadata: {
@@ -960,10 +1138,107 @@ export interface components {
960
1138
  /** Format: uri */
961
1139
  authorization_url: string;
962
1140
  };
963
- DirectoryOrganization: {
1141
+ /** @description The `application/json` half of closing a Cuenta Vista: an Intent born waiting for an Approval. `/accounts` has no `DELETE` because everything with banking consequence happens through an Intent. It carries no amount, no source and no destination -- only a reference to the account it closes. */
1142
+ AccountClosureIntentCreate: {
1143
+ /** @constant */
1144
+ type: "account_closure";
1145
+ account: components["schemas"]["IntentAccount"];
1146
+ expires_in?: string;
1147
+ /** Format: date-time */
1148
+ expires_at?: string;
1149
+ note?: components["schemas"]["IntentNote"];
1150
+ metadata?: {
1151
+ [key: string]: unknown;
1152
+ };
1153
+ } & (unknown | unknown);
1154
+ /** @description The verified claims of a Signed Instruction that closes an account. `account` is required and never editable: an instruction that does not say which account it closes is not signable. */
1155
+ SignedAccountClosureIntentClaims: {
1156
+ iss: string;
1157
+ /** @constant */
1158
+ aud: "https://api.andco.com";
1159
+ /** @description The idempotency key, inside the signature, reused verbatim when retrying. */
1160
+ jti: string;
1161
+ exp: number;
1162
+ iat?: number;
1163
+ nbf?: number;
1164
+ /** @constant */
1165
+ type: "account_closure";
1166
+ account: components["schemas"]["IntentAccount"];
1167
+ expires_in?: string;
1168
+ /** Format: date-time */
1169
+ expires_at?: string;
1170
+ metadata?: {
1171
+ [key: string]: unknown;
1172
+ };
1173
+ } & (unknown | unknown);
1174
+ /** @description Authoritative Project-facing state of an account closure. It carries no amount and no fee. */
1175
+ AccountClosureIntent: {
1176
+ /** Format: uuid */
1177
+ id: string;
1178
+ /** Format: uri */
1179
+ resource_server: string;
1180
+ /** @constant */
1181
+ type: "account_closure";
1182
+ status: components["schemas"]["IntentStatus"];
1183
+ /** @description Whether a Signed Instruction created this Intent rather than a plain request. */
1184
+ signed: boolean;
1185
+ account: components["schemas"]["IntentAccount"];
1186
+ /**
1187
+ * Format: uuid
1188
+ * @description The account the reference resolved to, once resolution has happened, whether or not the closure itself has settled yet.
1189
+ */
1190
+ resolved_account_id: string | null;
1191
+ note?: components["schemas"]["IntentNote"];
1192
+ metadata: {
1193
+ [key: string]: unknown;
1194
+ };
1195
+ /** Format: date-time */
1196
+ server_time: string;
1197
+ /** @description Remaining actionable lifetime at server_time; zero for finite terminal Intents. */
1198
+ expires_in_seconds: number;
1199
+ /** Format: date-time */
1200
+ expires_at: string;
1201
+ /** Format: date-time */
1202
+ created_at: string;
1203
+ /** Format: uri */
1204
+ authorization_url: string;
1205
+ };
1206
+ /** @description The verified claims of a Signed Instruction, sent to the same endpoint as `application/jwt`. Nothing here is optional that the transfer needs and nothing here is editable: an instruction that does not say where the money comes from or where it goes is not signable, so `source` and `destination` are required and the amount carries no `editable`. `note` is a plain reference for the same reason -- there is no screen on this path, so there is nobody to propose it to. When a signature is present, every value the transfer uses comes from these claims and none from the envelope carrying them. `exp` bounds how long the instruction may be submitted; `expires_in` or `expires_at` bounds how long the Intent may be approved and executed. They are different deadlines. */
1207
+ SignedTransferIntentClaims: {
1208
+ /** @description The client_id of the OAuth Client whose Signing Key signed this instruction. */
1209
+ iss: string;
1210
+ /** @constant */
1211
+ aud: "https://api.andco.com";
1212
+ /** @description The idempotency key, inside the signature, reused verbatim when retrying. */
1213
+ jti: string;
1214
+ exp: number;
1215
+ iat?: number;
1216
+ nbf?: number;
1217
+ /** @constant */
1218
+ type: "transfer";
1219
+ source: components["schemas"]["IntentAccount"];
1220
+ destination: components["schemas"]["TransferDestination"];
1221
+ amount: components["schemas"]["SignedAmount"];
1222
+ expires_in?: string;
1223
+ /** Format: date-time */
1224
+ expires_at?: string;
1225
+ /** @description A plain bank reference; a Signed Instruction proposes nothing. */
1226
+ note?: string;
1227
+ metadata?: {
1228
+ [key: string]: unknown;
1229
+ };
1230
+ } & (unknown | unknown);
1231
+ /** @enum {string} */
1232
+ IntentStatus: "requires_action" | "processing.confirmed" | "processing.settling" | "processing.reversing" | "processing.reconciling" | "succeeded" | "failed" | "failed.insufficient_funds" | "cancelled" | "rejected" | "expired";
1233
+ Organization: {
964
1234
  id: string;
965
1235
  name: string;
966
1236
  };
1237
+ OrganizationPage: {
1238
+ data: components["schemas"]["Organization"][];
1239
+ next_cursor: string | null;
1240
+ has_more: boolean;
1241
+ };
967
1242
  };
968
1243
  responses: {
969
1244
  /** @description The OAuth bearer token is missing, invalid, expired, or revoked */
@@ -975,7 +1250,7 @@ export interface components {
975
1250
  "application/json": components["schemas"]["ApiError"];
976
1251
  };
977
1252
  };
978
- /** @description The browser origin is not allowed or the token does not grant the resource's required scope */
1253
+ /** @description The browser origin is not allowed, or the token's Grant lacks the authorization detail the resource requires or names another subject */
979
1254
  Forbidden: {
980
1255
  headers: {
981
1256
  [name: string]: unknown;
@@ -1048,294 +1323,305 @@ export interface components {
1048
1323
  };
1049
1324
  };
1050
1325
  };
1051
- parameters: never;
1326
+ parameters: {
1327
+ /** @description The Profile the Grant's subject names. */
1328
+ ProfileId: string;
1329
+ /** @description The Project whose Profiles are read; it must be one of the Grant's `project_ids`, or any of the Organization's when that list is empty. */
1330
+ ProjectId: string;
1331
+ /** @description The Organization the Grant's subject names. */
1332
+ OrganizationId: string;
1333
+ AddressId: string;
1334
+ After: string;
1335
+ Limit: number;
1336
+ };
1052
1337
  requestBodies: never;
1053
1338
  headers: never;
1054
1339
  pathItems: never;
1055
1340
  }
1056
1341
  export type $defs = Record<string, never>;
1057
1342
  export interface operations {
1058
- createWebhookSubscription: {
1343
+ listProjectProfiles: {
1059
1344
  parameters: {
1060
- query?: never;
1061
- header: {
1062
- "Idempotency-Key": string;
1345
+ query?: {
1346
+ /** @description An eq.UUID or in.(UUID,UUID) filter that narrows the authorized Clients. */
1347
+ client_id?: string;
1348
+ /** @description A comma-separated subset of the fields the Grant allows, for example `name,email`. */
1349
+ fields?: string;
1350
+ after?: string;
1351
+ limit?: number;
1063
1352
  };
1064
- path?: never;
1065
- cookie?: never;
1066
- };
1067
- requestBody: {
1068
- content: {
1069
- "application/json": components["schemas"]["WebhookSubscriptionCreate"];
1353
+ header?: never;
1354
+ path: {
1355
+ /** @description The Project whose Profiles are read; it must be one of the Grant's `project_ids`, or any of the Organization's when that list is empty. */
1356
+ project_id: components["parameters"]["ProjectId"];
1070
1357
  };
1358
+ cookie?: never;
1071
1359
  };
1360
+ requestBody?: never;
1072
1361
  responses: {
1073
- /** @description Registered endpoint awaiting verification, or the existing idempotent registration */
1074
- 201: {
1362
+ /** @description One cursor page of the Project's Profiles */
1363
+ 200: {
1075
1364
  headers: {
1076
1365
  [name: string]: unknown;
1077
1366
  };
1078
1367
  content: {
1079
- "application/json": components["schemas"]["WebhookSubscription"];
1368
+ "application/json": components["schemas"]["ProjectProfilePage"];
1080
1369
  };
1081
1370
  };
1082
1371
  400: components["responses"]["InvalidRequest"];
1083
1372
  401: components["responses"]["InvalidToken"];
1084
1373
  403: components["responses"]["Forbidden"];
1085
- 409: components["responses"]["Conflict"];
1374
+ 404: components["responses"]["UnsupportedVersion"];
1086
1375
  503: components["responses"]["TemporarilyUnavailable"];
1087
1376
  };
1088
1377
  };
1089
- getWebhookSubscription: {
1378
+ getGrantAuthorization: {
1090
1379
  parameters: {
1091
1380
  query?: never;
1092
1381
  header?: never;
1093
- path: {
1094
- subscription_id: string;
1095
- };
1382
+ path?: never;
1096
1383
  cookie?: never;
1097
1384
  };
1098
1385
  requestBody?: never;
1099
1386
  responses: {
1100
- /** @description Safe subscription details without credentials or verification challenge */
1387
+ /** @description Active Grant context for a Resource Server */
1101
1388
  200: {
1102
1389
  headers: {
1103
1390
  [name: string]: unknown;
1104
1391
  };
1105
1392
  content: {
1106
- "application/json": components["schemas"]["WebhookSubscription"];
1393
+ "application/json": components["schemas"]["GrantAuthorization"];
1107
1394
  };
1108
1395
  };
1109
1396
  401: components["responses"]["InvalidToken"];
1110
- 403: components["responses"]["Forbidden"];
1397
+ 404: components["responses"]["UnsupportedVersion"];
1111
1398
  503: components["responses"]["TemporarilyUnavailable"];
1112
1399
  };
1113
1400
  };
1114
- getWebhookDeliveries: {
1401
+ getPermissionCatalog: {
1115
1402
  parameters: {
1116
1403
  query?: {
1117
- after?: string;
1118
1404
  limit?: number;
1405
+ cursor?: string;
1119
1406
  };
1120
1407
  header?: never;
1121
- path: {
1122
- subscription_id: string;
1123
- };
1408
+ path?: never;
1124
1409
  cookie?: never;
1125
1410
  };
1126
1411
  requestBody?: never;
1127
1412
  responses: {
1128
- /** @description Authorized retained delivery information */
1413
+ /** @description One page of the public Permission Catalog */
1129
1414
  200: {
1130
1415
  headers: {
1131
1416
  [name: string]: unknown;
1132
1417
  };
1133
1418
  content: {
1134
- "application/json": components["schemas"]["WebhookDeliveryPage"];
1419
+ "application/json": components["schemas"]["PermissionCatalogPage"];
1135
1420
  };
1136
1421
  };
1137
1422
  400: components["responses"]["InvalidRequest"];
1138
- 401: components["responses"]["InvalidToken"];
1139
- 403: components["responses"]["Forbidden"];
1140
- 409: components["responses"]["Conflict"];
1423
+ 404: components["responses"]["NotFound"];
1141
1424
  503: components["responses"]["TemporarilyUnavailable"];
1142
1425
  };
1143
1426
  };
1144
- getWebhookAttempts: {
1427
+ getUserInfo: {
1145
1428
  parameters: {
1146
- query?: {
1147
- after?: string;
1148
- limit?: number;
1149
- };
1429
+ query?: never;
1150
1430
  header?: never;
1151
- path: {
1152
- subscription_id: string;
1153
- delivery_id: string;
1154
- };
1431
+ path?: never;
1155
1432
  cookie?: never;
1156
1433
  };
1157
1434
  requestBody?: never;
1158
1435
  responses: {
1159
- /** @description Authorized retained delivery information */
1436
+ /** @description Scope-filtered OpenID-style claims */
1160
1437
  200: {
1161
1438
  headers: {
1162
1439
  [name: string]: unknown;
1163
1440
  };
1164
1441
  content: {
1165
- "application/json": components["schemas"]["WebhookAttemptPage"];
1442
+ "application/json": components["schemas"]["UserInfo"];
1166
1443
  };
1167
1444
  };
1168
- 400: components["responses"]["InvalidRequest"];
1169
1445
  401: components["responses"]["InvalidToken"];
1170
1446
  403: components["responses"]["Forbidden"];
1171
- 409: components["responses"]["Conflict"];
1447
+ 404: components["responses"]["UnsupportedVersion"];
1172
1448
  503: components["responses"]["TemporarilyUnavailable"];
1173
1449
  };
1174
1450
  };
1175
- redriveWebhookDelivery: {
1451
+ listProfileIdentities: {
1176
1452
  parameters: {
1177
- query?: never;
1453
+ query?: {
1454
+ after?: components["parameters"]["After"];
1455
+ limit?: components["parameters"]["Limit"];
1456
+ };
1178
1457
  header?: never;
1179
1458
  path: {
1180
- subscription_id: string;
1181
- delivery_id: string;
1459
+ /** @description The Profile the Grant's subject names. */
1460
+ profile_id: components["parameters"]["ProfileId"];
1182
1461
  };
1183
1462
  cookie?: never;
1184
1463
  };
1185
1464
  requestBody?: never;
1186
1465
  responses: {
1187
- /** @description Authorized retained delivery information */
1466
+ /** @description One page of the Profile's active identities */
1188
1467
  200: {
1189
1468
  headers: {
1190
1469
  [name: string]: unknown;
1191
1470
  };
1192
1471
  content: {
1193
- "application/json": components["schemas"]["WebhookDelivery"];
1472
+ "application/json": components["schemas"]["ProfileIdentityPage"];
1194
1473
  };
1195
1474
  };
1196
1475
  400: components["responses"]["InvalidRequest"];
1197
1476
  401: components["responses"]["InvalidToken"];
1198
1477
  403: components["responses"]["Forbidden"];
1199
- 409: components["responses"]["Conflict"];
1478
+ 404: components["responses"]["UnsupportedVersion"];
1200
1479
  503: components["responses"]["TemporarilyUnavailable"];
1201
1480
  };
1202
1481
  };
1203
- getGrantAuthorization: {
1482
+ listProfileAddresses: {
1204
1483
  parameters: {
1205
- query?: never;
1484
+ query?: {
1485
+ after?: components["parameters"]["After"];
1486
+ limit?: components["parameters"]["Limit"];
1487
+ };
1206
1488
  header?: never;
1207
- path?: never;
1489
+ path: {
1490
+ /** @description The Profile the Grant's subject names. */
1491
+ profile_id: components["parameters"]["ProfileId"];
1492
+ };
1208
1493
  cookie?: never;
1209
1494
  };
1210
1495
  requestBody?: never;
1211
1496
  responses: {
1212
- /** @description Active Grant context for a Resource Server */
1497
+ /** @description One page of the Profile's active addresses */
1213
1498
  200: {
1214
1499
  headers: {
1215
1500
  [name: string]: unknown;
1216
1501
  };
1217
1502
  content: {
1218
- "application/json": components["schemas"]["GrantAuthorization"];
1503
+ "application/json": components["schemas"]["AddressPage"];
1219
1504
  };
1220
1505
  };
1506
+ 400: components["responses"]["InvalidRequest"];
1221
1507
  401: components["responses"]["InvalidToken"];
1508
+ 403: components["responses"]["Forbidden"];
1222
1509
  404: components["responses"]["UnsupportedVersion"];
1223
1510
  503: components["responses"]["TemporarilyUnavailable"];
1224
1511
  };
1225
1512
  };
1226
- getOrganizationDirectory: {
1513
+ createProfileAddress: {
1227
1514
  parameters: {
1228
1515
  query?: never;
1229
1516
  header?: never;
1230
- path?: never;
1517
+ path: {
1518
+ /** @description The Profile the Grant's subject names. */
1519
+ profile_id: components["parameters"]["ProfileId"];
1520
+ };
1231
1521
  cookie?: never;
1232
1522
  };
1233
- requestBody?: never;
1523
+ requestBody: {
1524
+ content: {
1525
+ "application/json": components["schemas"]["AddressCreate"];
1526
+ };
1527
+ };
1234
1528
  responses: {
1235
- /** @description Basic discovery data; no business-resource authority */
1236
- 200: {
1529
+ /** @description Address created */
1530
+ 201: {
1237
1531
  headers: {
1238
1532
  [name: string]: unknown;
1239
1533
  };
1240
1534
  content: {
1241
- "application/json": components["schemas"]["DirectoryOrganization"][];
1535
+ "application/json": components["schemas"]["AddressMutationResult"];
1242
1536
  };
1243
1537
  };
1538
+ 400: components["responses"]["InvalidRequest"];
1244
1539
  401: components["responses"]["InvalidToken"];
1245
1540
  403: components["responses"]["Forbidden"];
1541
+ 422: components["responses"]["UnprocessableEntity"];
1246
1542
  503: components["responses"]["TemporarilyUnavailable"];
1247
1543
  };
1248
1544
  };
1249
- getCompanyIdentity: {
1545
+ deleteProfileAddress: {
1250
1546
  parameters: {
1251
1547
  query?: never;
1252
1548
  header?: never;
1253
- path?: never;
1549
+ path: {
1550
+ /** @description The Profile the Grant's subject names. */
1551
+ profile_id: components["parameters"]["ProfileId"];
1552
+ address_id: components["parameters"]["AddressId"];
1553
+ };
1254
1554
  cookie?: never;
1255
1555
  };
1256
1556
  requestBody?: never;
1257
1557
  responses: {
1258
- /** @description Legal identity granted for the selected Company */
1259
- 200: {
1558
+ /** @description Address deleted */
1559
+ 204: {
1260
1560
  headers: {
1261
1561
  [name: string]: unknown;
1262
1562
  };
1263
- content: {
1264
- "application/json": components["schemas"]["CompanyIdentity"];
1265
- };
1563
+ content?: never;
1266
1564
  };
1565
+ 400: components["responses"]["InvalidRequest"];
1267
1566
  401: components["responses"]["InvalidToken"];
1268
1567
  403: components["responses"]["Forbidden"];
1269
1568
  404: components["responses"]["NotFound"];
1270
1569
  503: components["responses"]["TemporarilyUnavailable"];
1271
1570
  };
1272
1571
  };
1273
- getCompanyAddresses: {
1572
+ updateProfileAddress: {
1274
1573
  parameters: {
1275
1574
  query?: never;
1276
1575
  header?: never;
1277
- path?: never;
1278
- cookie?: never;
1279
- };
1280
- requestBody?: never;
1281
- responses: {
1282
- /** @description Addresses granted for the selected Company */
1283
- 200: {
1284
- headers: {
1285
- [name: string]: unknown;
1286
- };
1287
- content: {
1288
- "application/json": components["schemas"]["CompanyAddresses"];
1289
- };
1576
+ path: {
1577
+ /** @description The Profile the Grant's subject names. */
1578
+ profile_id: components["parameters"]["ProfileId"];
1579
+ address_id: components["parameters"]["AddressId"];
1290
1580
  };
1291
- 401: components["responses"]["InvalidToken"];
1292
- 403: components["responses"]["Forbidden"];
1293
- 404: components["responses"]["NotFound"];
1294
- 503: components["responses"]["TemporarilyUnavailable"];
1581
+ cookie?: never;
1295
1582
  };
1296
- };
1297
- getPermissionCatalog: {
1298
- parameters: {
1299
- query?: {
1300
- limit?: number;
1301
- cursor?: string;
1583
+ requestBody: {
1584
+ content: {
1585
+ "application/json": components["schemas"]["AddressUpdate"];
1302
1586
  };
1303
- header?: never;
1304
- path?: never;
1305
- cookie?: never;
1306
1587
  };
1307
- requestBody?: never;
1308
1588
  responses: {
1309
- /** @description One page of the public Permission Catalog */
1589
+ /** @description Address updated */
1310
1590
  200: {
1311
1591
  headers: {
1312
1592
  [name: string]: unknown;
1313
1593
  };
1314
1594
  content: {
1315
- "application/json": components["schemas"]["PermissionCatalogPage"];
1595
+ "application/json": components["schemas"]["AddressMutationResult"];
1316
1596
  };
1317
1597
  };
1318
1598
  400: components["responses"]["InvalidRequest"];
1599
+ 401: components["responses"]["InvalidToken"];
1600
+ 403: components["responses"]["Forbidden"];
1319
1601
  404: components["responses"]["NotFound"];
1602
+ 422: components["responses"]["UnprocessableEntity"];
1320
1603
  503: components["responses"]["TemporarilyUnavailable"];
1321
1604
  };
1322
1605
  };
1323
- getUserInfo: {
1606
+ listProfileOrganizations: {
1324
1607
  parameters: {
1325
1608
  query?: never;
1326
1609
  header?: never;
1327
- path?: never;
1610
+ path: {
1611
+ /** @description The Profile the Grant's subject names. */
1612
+ profile_id: components["parameters"]["ProfileId"];
1613
+ };
1328
1614
  cookie?: never;
1329
1615
  };
1330
1616
  requestBody?: never;
1331
1617
  responses: {
1332
- /** @description Scope-filtered OpenID-style claims */
1618
+ /** @description The Profile's Organizations, by name */
1333
1619
  200: {
1334
1620
  headers: {
1335
1621
  [name: string]: unknown;
1336
1622
  };
1337
1623
  content: {
1338
- "application/json": components["schemas"]["UserInfo"];
1624
+ "application/json": components["schemas"]["OrganizationPage"];
1339
1625
  };
1340
1626
  };
1341
1627
  401: components["responses"]["InvalidToken"];
@@ -1344,47 +1630,49 @@ export interface operations {
1344
1630
  503: components["responses"]["TemporarilyUnavailable"];
1345
1631
  };
1346
1632
  };
1347
- listIdentities: {
1633
+ listOrganizationIdentities: {
1348
1634
  parameters: {
1349
- query?: {
1350
- after?: string;
1351
- limit?: number;
1352
- };
1635
+ query?: never;
1353
1636
  header?: never;
1354
- path?: never;
1637
+ path: {
1638
+ /** @description The Organization the Grant's subject names. */
1639
+ organization_id: components["parameters"]["OrganizationId"];
1640
+ };
1355
1641
  cookie?: never;
1356
1642
  };
1357
1643
  requestBody?: never;
1358
1644
  responses: {
1359
- /** @description One page of active identities granted by identities:read */
1645
+ /** @description The Organization's legal identities */
1360
1646
  200: {
1361
1647
  headers: {
1362
1648
  [name: string]: unknown;
1363
1649
  };
1364
1650
  content: {
1365
- "application/json": components["schemas"]["IdentityPage"];
1651
+ "application/json": components["schemas"]["OrganizationIdentityPage"];
1366
1652
  };
1367
1653
  };
1368
- 400: components["responses"]["InvalidRequest"];
1369
1654
  401: components["responses"]["InvalidToken"];
1370
1655
  403: components["responses"]["Forbidden"];
1371
- 404: components["responses"]["UnsupportedVersion"];
1656
+ 404: components["responses"]["NotFound"];
1372
1657
  503: components["responses"]["TemporarilyUnavailable"];
1373
1658
  };
1374
1659
  };
1375
- listAddresses: {
1660
+ listOrganizationAddresses: {
1376
1661
  parameters: {
1377
1662
  query?: {
1378
- after?: string;
1379
- limit?: number;
1663
+ after?: components["parameters"]["After"];
1664
+ limit?: components["parameters"]["Limit"];
1380
1665
  };
1381
1666
  header?: never;
1382
- path?: never;
1667
+ path: {
1668
+ /** @description The Organization the Grant's subject names. */
1669
+ organization_id: components["parameters"]["OrganizationId"];
1670
+ };
1383
1671
  cookie?: never;
1384
1672
  };
1385
1673
  requestBody?: never;
1386
1674
  responses: {
1387
- /** @description One page of active addresses granted by addresses:read */
1675
+ /** @description One page of the Organization's active addresses */
1388
1676
  200: {
1389
1677
  headers: {
1390
1678
  [name: string]: unknown;
@@ -1396,15 +1684,18 @@ export interface operations {
1396
1684
  400: components["responses"]["InvalidRequest"];
1397
1685
  401: components["responses"]["InvalidToken"];
1398
1686
  403: components["responses"]["Forbidden"];
1399
- 404: components["responses"]["UnsupportedVersion"];
1687
+ 404: components["responses"]["NotFound"];
1400
1688
  503: components["responses"]["TemporarilyUnavailable"];
1401
1689
  };
1402
1690
  };
1403
- createAddress: {
1691
+ createOrganizationAddress: {
1404
1692
  parameters: {
1405
1693
  query?: never;
1406
1694
  header?: never;
1407
- path?: never;
1695
+ path: {
1696
+ /** @description The Organization the Grant's subject names. */
1697
+ organization_id: components["parameters"]["OrganizationId"];
1698
+ };
1408
1699
  cookie?: never;
1409
1700
  };
1410
1701
  requestBody: {
@@ -1413,7 +1704,7 @@ export interface operations {
1413
1704
  };
1414
1705
  };
1415
1706
  responses: {
1416
- /** @description Address created with addresses:write */
1707
+ /** @description Address created */
1417
1708
  201: {
1418
1709
  headers: {
1419
1710
  [name: string]: unknown;
@@ -1429,18 +1720,20 @@ export interface operations {
1429
1720
  503: components["responses"]["TemporarilyUnavailable"];
1430
1721
  };
1431
1722
  };
1432
- deleteAddress: {
1723
+ deleteOrganizationAddress: {
1433
1724
  parameters: {
1434
1725
  query?: never;
1435
1726
  header?: never;
1436
1727
  path: {
1437
- address_id: string;
1728
+ /** @description The Organization the Grant's subject names. */
1729
+ organization_id: components["parameters"]["OrganizationId"];
1730
+ address_id: components["parameters"]["AddressId"];
1438
1731
  };
1439
1732
  cookie?: never;
1440
1733
  };
1441
1734
  requestBody?: never;
1442
1735
  responses: {
1443
- /** @description Address deleted with addresses:write */
1736
+ /** @description Address deleted */
1444
1737
  204: {
1445
1738
  headers: {
1446
1739
  [name: string]: unknown;
@@ -1454,12 +1747,14 @@ export interface operations {
1454
1747
  503: components["responses"]["TemporarilyUnavailable"];
1455
1748
  };
1456
1749
  };
1457
- updateAddress: {
1750
+ updateOrganizationAddress: {
1458
1751
  parameters: {
1459
1752
  query?: never;
1460
1753
  header?: never;
1461
1754
  path: {
1462
- address_id: string;
1755
+ /** @description The Organization the Grant's subject names. */
1756
+ organization_id: components["parameters"]["OrganizationId"];
1757
+ address_id: components["parameters"]["AddressId"];
1463
1758
  };
1464
1759
  cookie?: never;
1465
1760
  };
@@ -1469,7 +1764,7 @@ export interface operations {
1469
1764
  };
1470
1765
  };
1471
1766
  responses: {
1472
- /** @description Address updated with addresses:write */
1767
+ /** @description Address updated */
1473
1768
  200: {
1474
1769
  headers: {
1475
1770
  [name: string]: unknown;
@@ -1488,7 +1783,13 @@ export interface operations {
1488
1783
  };
1489
1784
  listAccounts: {
1490
1785
  parameters: {
1491
- query?: never;
1786
+ query?: {
1787
+ /** @description Opaque cursor from a previous page's `next_cursor`. Omit for the first page. */
1788
+ after?: string;
1789
+ limit?: number;
1790
+ /** @description Exact-match lookup by Account Alias. Not compatible with `after`/`limit` paging. */
1791
+ alias?: string;
1792
+ };
1492
1793
  header?: never;
1493
1794
  path?: never;
1494
1795
  cookie?: never;
@@ -1501,11 +1802,10 @@ export interface operations {
1501
1802
  [name: string]: unknown;
1502
1803
  };
1503
1804
  content: {
1504
- "application/json": {
1505
- data: components["schemas"]["BankAccount"][];
1506
- };
1805
+ "application/json": components["schemas"]["AccountPage"];
1507
1806
  };
1508
1807
  };
1808
+ 400: components["responses"]["InvalidRequest"];
1509
1809
  401: components["responses"]["InvalidToken"];
1510
1810
  403: components["responses"]["Forbidden"];
1511
1811
  404: components["responses"]["UnsupportedVersion"];
@@ -1515,15 +1815,17 @@ export interface operations {
1515
1815
  createIntent: {
1516
1816
  parameters: {
1517
1817
  query?: never;
1518
- header: {
1519
- "Idempotency-Key": string;
1818
+ header?: {
1819
+ /** @description Required with `application/json`, and refused with `application/jwt`, which answers `400 idempotency_key_not_allowed` when it arrives beside a signature: the idempotency key of a Signed Instruction is its own `jti`, and two candidates for one key is exactly the ambiguity that gets read the wrong way round. OpenAPI cannot make a header conditional on the media type, so it is published as optional rather than demanding what the server refuses. */
1820
+ "Idempotency-Key"?: string;
1520
1821
  };
1521
1822
  path?: never;
1522
1823
  cookie?: never;
1523
1824
  };
1524
1825
  requestBody: {
1525
1826
  content: {
1526
- "application/json": components["schemas"]["DepositIntentCreate"] | components["schemas"]["WithdrawalIntentCreate"] | components["schemas"]["AutomaticChargeIntentCreate"];
1827
+ "application/json": components["schemas"]["DepositIntentCreate"] | components["schemas"]["TransferIntentCreate"] | components["schemas"]["AccountOpeningIntentCreate"] | components["schemas"]["AccountClosureIntentCreate"];
1828
+ "application/jwt": string;
1527
1829
  };
1528
1830
  };
1529
1831
  responses: {
@@ -1533,7 +1835,7 @@ export interface operations {
1533
1835
  [name: string]: unknown;
1534
1836
  };
1535
1837
  content: {
1536
- "application/json": components["schemas"]["DepositIntent"] | components["schemas"]["WithdrawalIntent"] | components["schemas"]["AutomaticChargeIntent"];
1838
+ "application/json": components["schemas"]["DepositIntent"] | components["schemas"]["TransferIntent"] | components["schemas"]["AccountOpeningIntent"] | components["schemas"]["AccountClosureIntent"];
1537
1839
  };
1538
1840
  };
1539
1841
  400: components["responses"]["InvalidRequest"];
@@ -1545,6 +1847,32 @@ export interface operations {
1545
1847
  503: components["responses"]["TemporarilyUnavailable"];
1546
1848
  };
1547
1849
  };
1850
+ readOrganizationEvents: {
1851
+ parameters: {
1852
+ query?: {
1853
+ after?: string;
1854
+ limit?: number;
1855
+ };
1856
+ header?: never;
1857
+ path?: never;
1858
+ cookie?: never;
1859
+ };
1860
+ requestBody?: never;
1861
+ responses: {
1862
+ /** @description Authorized event page in publication order */
1863
+ 200: {
1864
+ headers: {
1865
+ [name: string]: unknown;
1866
+ };
1867
+ content: {
1868
+ "application/json": components["schemas"]["FinancialEventPage"];
1869
+ };
1870
+ };
1871
+ 400: components["responses"]["InvalidRequest"];
1872
+ 401: components["responses"]["InvalidToken"];
1873
+ 503: components["responses"]["TemporarilyUnavailable"];
1874
+ };
1875
+ };
1548
1876
  readAccountEvents: {
1549
1877
  parameters: {
1550
1878
  query?: {
@@ -1574,6 +1902,35 @@ export interface operations {
1574
1902
  503: components["responses"]["TemporarilyUnavailable"];
1575
1903
  };
1576
1904
  };
1905
+ listAccountTransactions: {
1906
+ parameters: {
1907
+ query?: {
1908
+ cursor?: string;
1909
+ };
1910
+ header?: never;
1911
+ path: {
1912
+ bank_account_id: string;
1913
+ };
1914
+ cookie?: never;
1915
+ };
1916
+ requestBody?: never;
1917
+ responses: {
1918
+ /** @description Authorized cursor page of account transactions, newest first */
1919
+ 200: {
1920
+ headers: {
1921
+ [name: string]: unknown;
1922
+ };
1923
+ content: {
1924
+ "application/json": components["schemas"]["BankTransactionPage"];
1925
+ };
1926
+ };
1927
+ 400: components["responses"]["InvalidRequest"];
1928
+ 401: components["responses"]["InvalidToken"];
1929
+ 403: components["responses"]["Forbidden"];
1930
+ 404: components["responses"]["NotFound"];
1931
+ 503: components["responses"]["TemporarilyUnavailable"];
1932
+ };
1933
+ };
1577
1934
  readIntentEvents: {
1578
1935
  parameters: {
1579
1936
  query?: {
@@ -1620,7 +1977,7 @@ export interface operations {
1620
1977
  [name: string]: unknown;
1621
1978
  };
1622
1979
  content: {
1623
- "application/json": components["schemas"]["DepositIntent"] | components["schemas"]["WithdrawalIntent"] | components["schemas"]["AutomaticChargeIntent"];
1980
+ "application/json": components["schemas"]["DepositIntent"] | components["schemas"]["TransferIntent"] | components["schemas"]["AccountOpeningIntent"] | components["schemas"]["AccountClosureIntent"];
1624
1981
  };
1625
1982
  };
1626
1983
  401: components["responses"]["InvalidToken"];
@@ -1656,7 +2013,7 @@ export interface operations {
1656
2013
  503: components["responses"]["TemporarilyUnavailable"];
1657
2014
  };
1658
2015
  };
1659
- executeWithdrawal: {
2016
+ approveIntent: {
1660
2017
  parameters: {
1661
2018
  query?: never;
1662
2019
  header?: never;
@@ -1667,13 +2024,49 @@ export interface operations {
1667
2024
  };
1668
2025
  requestBody?: never;
1669
2026
  responses: {
1670
- /** @description Withdrawal execution accepted */
1671
- 202: {
2027
+ /** @description The Intent after its approval */
2028
+ 200: {
1672
2029
  headers: {
1673
2030
  [name: string]: unknown;
1674
2031
  };
1675
- content?: never;
2032
+ content: {
2033
+ "application/json": components["schemas"]["DepositIntent"] | components["schemas"]["TransferIntent"] | components["schemas"]["AccountOpeningIntent"] | components["schemas"]["AccountClosureIntent"];
2034
+ };
2035
+ };
2036
+ 401: components["responses"]["InvalidToken"];
2037
+ 403: components["responses"]["Forbidden"];
2038
+ 404: components["responses"]["NotFound"];
2039
+ 409: components["responses"]["Conflict"];
2040
+ 422: components["responses"]["UnprocessableEntity"];
2041
+ 501: components["responses"]["NotImplemented"];
2042
+ 503: components["responses"]["TemporarilyUnavailable"];
2043
+ };
2044
+ };
2045
+ rejectIntent: {
2046
+ parameters: {
2047
+ query?: never;
2048
+ header?: never;
2049
+ path: {
2050
+ intent_id: string;
2051
+ };
2052
+ cookie?: never;
2053
+ };
2054
+ requestBody: {
2055
+ content: {
2056
+ "application/json": components["schemas"]["IntentRejection"];
1676
2057
  };
2058
+ };
2059
+ responses: {
2060
+ /** @description Rejected Intent */
2061
+ 200: {
2062
+ headers: {
2063
+ [name: string]: unknown;
2064
+ };
2065
+ content: {
2066
+ "application/json": components["schemas"]["DepositIntent"] | components["schemas"]["TransferIntent"] | components["schemas"]["AccountOpeningIntent"] | components["schemas"]["AccountClosureIntent"];
2067
+ };
2068
+ };
2069
+ 400: components["responses"]["InvalidRequest"];
1677
2070
  401: components["responses"]["InvalidToken"];
1678
2071
  403: components["responses"]["Forbidden"];
1679
2072
  404: components["responses"]["NotFound"];
@@ -1681,5 +2074,80 @@ export interface operations {
1681
2074
  503: components["responses"]["TemporarilyUnavailable"];
1682
2075
  };
1683
2076
  };
2077
+ cancelIntent: {
2078
+ parameters: {
2079
+ query?: never;
2080
+ header?: never;
2081
+ path: {
2082
+ intent_id: string;
2083
+ };
2084
+ cookie?: never;
2085
+ };
2086
+ requestBody: {
2087
+ content: {
2088
+ "application/json": components["schemas"]["IntentCancellation"];
2089
+ };
2090
+ };
2091
+ responses: {
2092
+ /** @description Cancelled Intent */
2093
+ 200: {
2094
+ headers: {
2095
+ [name: string]: unknown;
2096
+ };
2097
+ content: {
2098
+ "application/json": components["schemas"]["DepositIntent"] | components["schemas"]["TransferIntent"] | components["schemas"]["AccountOpeningIntent"] | components["schemas"]["AccountClosureIntent"];
2099
+ };
2100
+ };
2101
+ 400: components["responses"]["InvalidRequest"];
2102
+ 401: components["responses"]["InvalidToken"];
2103
+ 404: components["responses"]["NotFound"];
2104
+ 409: components["responses"]["Conflict"];
2105
+ 503: components["responses"]["TemporarilyUnavailable"];
2106
+ };
2107
+ };
2108
+ verifySignature: {
2109
+ parameters: {
2110
+ query?: never;
2111
+ header?: never;
2112
+ path?: never;
2113
+ cookie?: never;
2114
+ };
2115
+ requestBody: {
2116
+ content: {
2117
+ "application/jwt": string;
2118
+ };
2119
+ };
2120
+ responses: {
2121
+ /** @description The assertion verified; its claims as signed */
2122
+ 200: {
2123
+ headers: {
2124
+ [name: string]: unknown;
2125
+ };
2126
+ content: {
2127
+ "application/json": components["schemas"]["SignedInstructionVerification"];
2128
+ };
2129
+ };
2130
+ 401: components["responses"]["InvalidToken"];
2131
+ /** @description The request body is not `application/jwt` */
2132
+ 415: {
2133
+ headers: {
2134
+ [name: string]: unknown;
2135
+ };
2136
+ content: {
2137
+ "application/json": components["schemas"]["ApiError"];
2138
+ };
2139
+ };
2140
+ /** @description The assertion did not verify */
2141
+ 422: {
2142
+ headers: {
2143
+ [name: string]: unknown;
2144
+ };
2145
+ content: {
2146
+ "application/json": components["schemas"]["SignedInstructionInvalidError"];
2147
+ };
2148
+ };
2149
+ 503: components["responses"]["TemporarilyUnavailable"];
2150
+ };
2151
+ };
1684
2152
  }
1685
2153
  //# sourceMappingURL=oauth-api.d.ts.map