@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
@@ -0,0 +1,1155 @@
1
+ import * as v from "valibot";
2
+ import { ANDCO_API_ERROR_CODES } from "../api-errors.js";
3
+ import { ErrorExtendable } from "../errors.js";
4
+ /** Every authorization detail type Andco's Resource Server implements. */
5
+ export declare const ANDCO_RAR_TYPES: readonly ["bank_account", "bank_transaction", "bank_transfer", "bank_deposit", "identity", "address", "organization", "profile", "project_users"];
6
+ export type AndcoRarType = (typeof ANDCO_RAR_TYPES)[number];
7
+ /**
8
+ * Types that belong to the model but are not built yet. A detail naming one is rejected with
9
+ * `not_implemented` rather than `invalid_request`, because it is valid and expected to be supported.
10
+ */
11
+ export declare const ANDCO_RESERVED_RAR_TYPES: readonly ["bank_beneficiaries", "identity_documents"];
12
+ export type AndcoReservedRarType = (typeof ANDCO_RESERVED_RAR_TYPES)[number];
13
+ /**
14
+ * One entry of {@link ANDCO_RAR_CATALOG}: the actions a type grants across all its forms, its two
15
+ * valibot schemas and their JSON Schema mirrors.
16
+ */
17
+ export type AndcoRarCatalogEntry = {
18
+ readonly actions: readonly string[];
19
+ readonly grantRequest: v.GenericSchema;
20
+ readonly grant: v.GenericSchema;
21
+ readonly grantRequestJsonSchema: Readonly<Record<string, unknown>>;
22
+ readonly grantJsonSchema: Readonly<Record<string, unknown>>;
23
+ };
24
+ /**
25
+ * The whole Andco authorization detail catalog, keyed by type. The gate's seeds store
26
+ * `grantRequestJsonSchema` as each type's request schema and `actions` as its registered actions;
27
+ * a guard test compares them against this object.
28
+ *
29
+ * @example
30
+ * const { grantRequestJsonSchema, actions } = ANDCO_RAR_CATALOG.bank_transfer;
31
+ */
32
+ export declare const ANDCO_RAR_CATALOG: {
33
+ readonly bank_account: {
34
+ readonly actions: readonly ["read", "read_balance", "create", "close", "approve", "reject"];
35
+ readonly grantRequest: v.UnionSchema<[v.StrictObjectSchema<{
36
+ readonly type: v.LiteralSchema<"bank_account", undefined>;
37
+ readonly actions: v.SchemaWithPipe<readonly [v.ArraySchema<v.PicklistSchema<readonly ["read", "read_balance"], undefined>, undefined>, v.MinLengthAction<("read" | "read_balance")[], 1, undefined>, v.CheckAction<("read" | "read_balance")[], "duplicate_action">]>;
38
+ readonly locations: v.TupleSchema<[v.LiteralSchema<"https://api.andco.com", undefined>], undefined>;
39
+ readonly subject: v.NullishSchema<v.VariantSchema<"type", [v.StrictObjectSchema<{
40
+ readonly type: v.LiteralSchema<"profile", undefined>;
41
+ readonly identifier: v.NullishSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>]>, undefined>;
42
+ }, undefined>, v.StrictObjectSchema<{
43
+ readonly type: v.LiteralSchema<"organization", undefined>;
44
+ readonly identifier: v.NullishSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>, v.CheckAction<string, "identifier_exceeds_organization_id">]>, undefined>;
45
+ readonly editable: v.NullishSchema<v.BooleanSchema<undefined>, undefined>;
46
+ }, undefined>], undefined>, undefined>;
47
+ readonly accounts: v.NullishSchema<v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.ArraySchema<v.UnionSchema<[v.StrictObjectSchema<{
48
+ readonly type: v.NullishSchema<v.LiteralSchema<"alias", undefined>, undefined>;
49
+ readonly pattern: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>]>;
50
+ readonly editable: v.NullishSchema<v.BooleanSchema<undefined>, undefined>;
51
+ readonly selection: v.NullishSchema<v.PicklistSchema<readonly ["single", "multiple"], undefined>, undefined>;
52
+ }, undefined>, v.StrictObjectSchema<{
53
+ readonly type: v.LiteralSchema<"account", undefined>;
54
+ readonly id: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>]>;
55
+ readonly editable: v.NullishSchema<v.BooleanSchema<undefined>, undefined>;
56
+ }, undefined>, v.StrictObjectSchema<{
57
+ readonly type: v.LiteralSchema<"any", undefined>;
58
+ readonly limit: v.LiteralSchema<"own", undefined>;
59
+ readonly editable: v.NullishSchema<v.BooleanSchema<undefined>, undefined>;
60
+ readonly selection: v.NullishSchema<v.PicklistSchema<readonly ["single", "multiple"], undefined>, undefined>;
61
+ }, undefined>], undefined>, undefined>, v.MinLengthAction<({
62
+ type?: "alias" | null | undefined;
63
+ pattern: string;
64
+ editable?: boolean | null | undefined;
65
+ selection?: "single" | "multiple" | null | undefined;
66
+ } | {
67
+ type: "account";
68
+ id: string;
69
+ editable?: boolean | null | undefined;
70
+ } | {
71
+ type: "any";
72
+ limit: "own";
73
+ editable?: boolean | null | undefined;
74
+ selection?: "single" | "multiple" | null | undefined;
75
+ })[], 1, undefined>, v.MaxLengthAction<({
76
+ type?: "alias" | null | undefined;
77
+ pattern: string;
78
+ editable?: boolean | null | undefined;
79
+ selection?: "single" | "multiple" | null | undefined;
80
+ } | {
81
+ type: "account";
82
+ id: string;
83
+ editable?: boolean | null | undefined;
84
+ } | {
85
+ type: "any";
86
+ limit: "own";
87
+ editable?: boolean | null | undefined;
88
+ selection?: "single" | "multiple" | null | undefined;
89
+ })[], 100, undefined>, v.CheckAction<({
90
+ type?: "alias" | null | undefined;
91
+ pattern: string;
92
+ editable?: boolean | null | undefined;
93
+ selection?: "single" | "multiple" | null | undefined;
94
+ } | {
95
+ type: "account";
96
+ id: string;
97
+ editable?: boolean | null | undefined;
98
+ } | {
99
+ type: "any";
100
+ limit: "own";
101
+ editable?: boolean | null | undefined;
102
+ selection?: "single" | "multiple" | null | undefined;
103
+ })[], "duplicate_account_matcher">]>, v.CheckAction<({
104
+ type?: "alias" | null | undefined;
105
+ pattern: string;
106
+ editable?: boolean | null | undefined;
107
+ selection?: "single" | "multiple" | null | undefined;
108
+ } | {
109
+ type: "account";
110
+ id: string;
111
+ editable?: boolean | null | undefined;
112
+ } | {
113
+ type: "any";
114
+ limit: "own";
115
+ editable?: boolean | null | undefined;
116
+ selection?: "single" | "multiple" | null | undefined;
117
+ })[], "account_selection_incoherent">]>, undefined>;
118
+ }, undefined>, v.StrictObjectSchema<{
119
+ readonly type: v.LiteralSchema<"bank_account", undefined>;
120
+ readonly actions: v.SchemaWithPipe<readonly [v.ArraySchema<v.PicklistSchema<readonly ["create", "close"], undefined>, undefined>, v.MinLengthAction<("create" | "close")[], 1, undefined>, v.CheckAction<("create" | "close")[], "duplicate_action">]>;
121
+ readonly locations: v.TupleSchema<[v.LiteralSchema<"https://api.andco.com", undefined>], undefined>;
122
+ readonly subject: v.NullishSchema<v.VariantSchema<"type", [v.StrictObjectSchema<{
123
+ readonly type: v.LiteralSchema<"profile", undefined>;
124
+ readonly identifier: v.NullishSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>]>, undefined>;
125
+ }, undefined>, v.StrictObjectSchema<{
126
+ readonly type: v.LiteralSchema<"organization", undefined>;
127
+ readonly identifier: v.NullishSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>, v.CheckAction<string, "identifier_exceeds_organization_id">]>, undefined>;
128
+ readonly editable: v.NullishSchema<v.BooleanSchema<undefined>, undefined>;
129
+ }, undefined>], undefined>, undefined>;
130
+ readonly accounts: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.ArraySchema<v.StrictObjectSchema<{
131
+ readonly type: v.NullishSchema<v.LiteralSchema<"alias", undefined>, undefined>;
132
+ readonly pattern: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>]>;
133
+ readonly editable: v.NullishSchema<v.BooleanSchema<undefined>, undefined>;
134
+ readonly selection: v.NullishSchema<v.PicklistSchema<readonly ["single", "multiple"], undefined>, undefined>;
135
+ }, undefined>, undefined>, v.MinLengthAction<{
136
+ type?: "alias" | null | undefined;
137
+ pattern: string;
138
+ editable?: boolean | null | undefined;
139
+ selection?: "single" | "multiple" | null | undefined;
140
+ }[], 1, undefined>, v.MaxLengthAction<{
141
+ type?: "alias" | null | undefined;
142
+ pattern: string;
143
+ editable?: boolean | null | undefined;
144
+ selection?: "single" | "multiple" | null | undefined;
145
+ }[], 100, undefined>, v.CheckAction<{
146
+ type?: "alias" | null | undefined;
147
+ pattern: string;
148
+ editable?: boolean | null | undefined;
149
+ selection?: "single" | "multiple" | null | undefined;
150
+ }[], "duplicate_account_matcher">]>, v.CheckAction<{
151
+ type?: "alias" | null | undefined;
152
+ pattern: string;
153
+ editable?: boolean | null | undefined;
154
+ selection?: "single" | "multiple" | null | undefined;
155
+ }[], "account_selection_not_pickable">]>;
156
+ }, undefined>, v.StrictObjectSchema<{
157
+ readonly type: v.LiteralSchema<"bank_account", undefined>;
158
+ readonly actions: v.SchemaWithPipe<readonly [v.ArraySchema<v.PicklistSchema<readonly ["approve", "reject"], undefined>, undefined>, v.MinLengthAction<("approve" | "reject")[], 1, undefined>, v.CheckAction<("approve" | "reject")[], "duplicate_action">]>;
159
+ readonly locations: v.TupleSchema<[v.LiteralSchema<"https://api.andco.com", undefined>], undefined>;
160
+ readonly subject: v.NullishSchema<v.VariantSchema<"type", [v.StrictObjectSchema<{
161
+ readonly type: v.LiteralSchema<"profile", undefined>;
162
+ readonly identifier: v.NullishSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>]>, undefined>;
163
+ }, undefined>, v.StrictObjectSchema<{
164
+ readonly type: v.LiteralSchema<"organization", undefined>;
165
+ readonly identifier: v.NullishSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>, v.CheckAction<string, "identifier_exceeds_organization_id">]>, undefined>;
166
+ readonly editable: v.NullishSchema<v.BooleanSchema<undefined>, undefined>;
167
+ }, undefined>], undefined>, undefined>;
168
+ }, undefined>], undefined>;
169
+ readonly grant: v.UnionSchema<[v.StrictObjectSchema<{
170
+ readonly type: v.LiteralSchema<"bank_account", undefined>;
171
+ readonly actions: v.SchemaWithPipe<readonly [v.ArraySchema<v.PicklistSchema<readonly ["read", "read_balance"], undefined>, undefined>, v.MinLengthAction<("read" | "read_balance")[], 1, undefined>, v.CheckAction<("read" | "read_balance")[], "duplicate_action">]>;
172
+ readonly locations: v.TupleSchema<[v.LiteralSchema<"https://api.andco.com", undefined>], undefined>;
173
+ readonly subject: v.VariantSchema<"type", [v.StrictObjectSchema<{
174
+ readonly type: v.LiteralSchema<"profile", undefined>;
175
+ readonly identifier: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>]>;
176
+ }, undefined>, v.StrictObjectSchema<{
177
+ readonly type: v.LiteralSchema<"organization", undefined>;
178
+ readonly identifier: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>, v.CheckAction<string, "identifier_exceeds_organization_id">]>;
179
+ }, undefined>], undefined>;
180
+ readonly accounts: v.SchemaWithPipe<readonly [v.ArraySchema<v.UnionSchema<[v.StrictObjectSchema<{
181
+ readonly type: v.LiteralSchema<"alias", undefined>;
182
+ readonly pattern: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>]>;
183
+ }, undefined>, v.StrictObjectSchema<{
184
+ readonly type: v.LiteralSchema<"account", undefined>;
185
+ readonly id: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>]>;
186
+ }, undefined>, v.StrictObjectSchema<{
187
+ readonly type: v.LiteralSchema<"any", undefined>;
188
+ readonly limit: v.LiteralSchema<"own", undefined>;
189
+ }, undefined>], undefined>, undefined>, v.MinLengthAction<({
190
+ type: "alias";
191
+ pattern: string;
192
+ } | {
193
+ type: "account";
194
+ id: string;
195
+ } | {
196
+ type: "any";
197
+ limit: "own";
198
+ })[], 1, undefined>, v.MaxLengthAction<({
199
+ type: "alias";
200
+ pattern: string;
201
+ } | {
202
+ type: "account";
203
+ id: string;
204
+ } | {
205
+ type: "any";
206
+ limit: "own";
207
+ })[], 100, undefined>, v.CheckAction<({
208
+ type: "alias";
209
+ pattern: string;
210
+ } | {
211
+ type: "account";
212
+ id: string;
213
+ } | {
214
+ type: "any";
215
+ limit: "own";
216
+ })[], "duplicate_account_matcher">]>;
217
+ }, undefined>, v.StrictObjectSchema<{
218
+ readonly type: v.LiteralSchema<"bank_account", undefined>;
219
+ readonly actions: v.SchemaWithPipe<readonly [v.ArraySchema<v.PicklistSchema<readonly ["create", "close"], undefined>, undefined>, v.MinLengthAction<("create" | "close")[], 1, undefined>, v.CheckAction<("create" | "close")[], "duplicate_action">]>;
220
+ readonly locations: v.TupleSchema<[v.LiteralSchema<"https://api.andco.com", undefined>], undefined>;
221
+ readonly subject: v.VariantSchema<"type", [v.StrictObjectSchema<{
222
+ readonly type: v.LiteralSchema<"profile", undefined>;
223
+ readonly identifier: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>]>;
224
+ }, undefined>, v.StrictObjectSchema<{
225
+ readonly type: v.LiteralSchema<"organization", undefined>;
226
+ readonly identifier: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>, v.CheckAction<string, "identifier_exceeds_organization_id">]>;
227
+ }, undefined>], undefined>;
228
+ readonly accounts: v.SchemaWithPipe<readonly [v.ArraySchema<v.StrictObjectSchema<{
229
+ readonly type: v.LiteralSchema<"alias", undefined>;
230
+ readonly pattern: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>]>;
231
+ }, undefined>, undefined>, v.MinLengthAction<{
232
+ type: "alias";
233
+ pattern: string;
234
+ }[], 1, undefined>, v.MaxLengthAction<{
235
+ type: "alias";
236
+ pattern: string;
237
+ }[], 100, undefined>, v.CheckAction<{
238
+ type: "alias";
239
+ pattern: string;
240
+ }[], "duplicate_account_matcher">]>;
241
+ }, undefined>, v.StrictObjectSchema<{
242
+ readonly type: v.LiteralSchema<"bank_account", undefined>;
243
+ readonly actions: v.SchemaWithPipe<readonly [v.ArraySchema<v.PicklistSchema<readonly ["approve", "reject"], undefined>, undefined>, v.MinLengthAction<("approve" | "reject")[], 1, undefined>, v.CheckAction<("approve" | "reject")[], "duplicate_action">]>;
244
+ readonly locations: v.TupleSchema<[v.LiteralSchema<"https://api.andco.com", undefined>], undefined>;
245
+ readonly subject: v.VariantSchema<"type", [v.StrictObjectSchema<{
246
+ readonly type: v.LiteralSchema<"profile", undefined>;
247
+ readonly identifier: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>]>;
248
+ }, undefined>, v.StrictObjectSchema<{
249
+ readonly type: v.LiteralSchema<"organization", undefined>;
250
+ readonly identifier: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>, v.CheckAction<string, "identifier_exceeds_organization_id">]>;
251
+ }, undefined>], undefined>;
252
+ }, undefined>], undefined>;
253
+ readonly grantRequestJsonSchema: Record<string, unknown>;
254
+ readonly grantJsonSchema: Record<string, unknown>;
255
+ };
256
+ readonly bank_transaction: {
257
+ readonly actions: readonly ["read"];
258
+ readonly grantRequest: v.StrictObjectSchema<{
259
+ readonly type: v.LiteralSchema<"bank_transaction", undefined>;
260
+ readonly actions: v.SchemaWithPipe<readonly [v.ArraySchema<v.PicklistSchema<readonly ["read"], undefined>, undefined>, v.MinLengthAction<"read"[], 1, undefined>, v.CheckAction<"read"[], "duplicate_action">]>;
261
+ readonly locations: v.TupleSchema<[v.LiteralSchema<"https://api.andco.com", undefined>], undefined>;
262
+ readonly subject: v.NullishSchema<v.VariantSchema<"type", [v.StrictObjectSchema<{
263
+ readonly type: v.LiteralSchema<"profile", undefined>;
264
+ readonly identifier: v.NullishSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>]>, undefined>;
265
+ }, undefined>, v.StrictObjectSchema<{
266
+ readonly type: v.LiteralSchema<"organization", undefined>;
267
+ readonly identifier: v.NullishSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>, v.CheckAction<string, "identifier_exceeds_organization_id">]>, undefined>;
268
+ readonly editable: v.NullishSchema<v.BooleanSchema<undefined>, undefined>;
269
+ }, undefined>], undefined>, undefined>;
270
+ readonly accounts: v.NullishSchema<v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.ArraySchema<v.UnionSchema<[v.StrictObjectSchema<{
271
+ readonly type: v.NullishSchema<v.LiteralSchema<"alias", undefined>, undefined>;
272
+ readonly pattern: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>]>;
273
+ readonly editable: v.NullishSchema<v.BooleanSchema<undefined>, undefined>;
274
+ readonly selection: v.NullishSchema<v.PicklistSchema<readonly ["single", "multiple"], undefined>, undefined>;
275
+ }, undefined>, v.StrictObjectSchema<{
276
+ readonly type: v.LiteralSchema<"account", undefined>;
277
+ readonly id: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>]>;
278
+ readonly editable: v.NullishSchema<v.BooleanSchema<undefined>, undefined>;
279
+ }, undefined>, v.StrictObjectSchema<{
280
+ readonly type: v.LiteralSchema<"any", undefined>;
281
+ readonly limit: v.LiteralSchema<"own", undefined>;
282
+ readonly editable: v.NullishSchema<v.BooleanSchema<undefined>, undefined>;
283
+ readonly selection: v.NullishSchema<v.PicklistSchema<readonly ["single", "multiple"], undefined>, undefined>;
284
+ }, undefined>], undefined>, undefined>, v.MinLengthAction<({
285
+ type?: "alias" | null | undefined;
286
+ pattern: string;
287
+ editable?: boolean | null | undefined;
288
+ selection?: "single" | "multiple" | null | undefined;
289
+ } | {
290
+ type: "account";
291
+ id: string;
292
+ editable?: boolean | null | undefined;
293
+ } | {
294
+ type: "any";
295
+ limit: "own";
296
+ editable?: boolean | null | undefined;
297
+ selection?: "single" | "multiple" | null | undefined;
298
+ })[], 1, undefined>, v.MaxLengthAction<({
299
+ type?: "alias" | null | undefined;
300
+ pattern: string;
301
+ editable?: boolean | null | undefined;
302
+ selection?: "single" | "multiple" | null | undefined;
303
+ } | {
304
+ type: "account";
305
+ id: string;
306
+ editable?: boolean | null | undefined;
307
+ } | {
308
+ type: "any";
309
+ limit: "own";
310
+ editable?: boolean | null | undefined;
311
+ selection?: "single" | "multiple" | null | undefined;
312
+ })[], 100, undefined>, v.CheckAction<({
313
+ type?: "alias" | null | undefined;
314
+ pattern: string;
315
+ editable?: boolean | null | undefined;
316
+ selection?: "single" | "multiple" | null | undefined;
317
+ } | {
318
+ type: "account";
319
+ id: string;
320
+ editable?: boolean | null | undefined;
321
+ } | {
322
+ type: "any";
323
+ limit: "own";
324
+ editable?: boolean | null | undefined;
325
+ selection?: "single" | "multiple" | null | undefined;
326
+ })[], "duplicate_account_matcher">]>, v.CheckAction<({
327
+ type?: "alias" | null | undefined;
328
+ pattern: string;
329
+ editable?: boolean | null | undefined;
330
+ selection?: "single" | "multiple" | null | undefined;
331
+ } | {
332
+ type: "account";
333
+ id: string;
334
+ editable?: boolean | null | undefined;
335
+ } | {
336
+ type: "any";
337
+ limit: "own";
338
+ editable?: boolean | null | undefined;
339
+ selection?: "single" | "multiple" | null | undefined;
340
+ })[], "account_selection_incoherent">]>, undefined>;
341
+ }, undefined>;
342
+ readonly grant: v.StrictObjectSchema<{
343
+ readonly type: v.LiteralSchema<"bank_transaction", undefined>;
344
+ readonly actions: v.SchemaWithPipe<readonly [v.ArraySchema<v.PicklistSchema<readonly ["read"], undefined>, undefined>, v.MinLengthAction<"read"[], 1, undefined>, v.CheckAction<"read"[], "duplicate_action">]>;
345
+ readonly locations: v.TupleSchema<[v.LiteralSchema<"https://api.andco.com", undefined>], undefined>;
346
+ readonly subject: v.VariantSchema<"type", [v.StrictObjectSchema<{
347
+ readonly type: v.LiteralSchema<"profile", undefined>;
348
+ readonly identifier: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>]>;
349
+ }, undefined>, v.StrictObjectSchema<{
350
+ readonly type: v.LiteralSchema<"organization", undefined>;
351
+ readonly identifier: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>, v.CheckAction<string, "identifier_exceeds_organization_id">]>;
352
+ }, undefined>], undefined>;
353
+ readonly accounts: v.SchemaWithPipe<readonly [v.ArraySchema<v.UnionSchema<[v.StrictObjectSchema<{
354
+ readonly type: v.LiteralSchema<"alias", undefined>;
355
+ readonly pattern: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>]>;
356
+ }, undefined>, v.StrictObjectSchema<{
357
+ readonly type: v.LiteralSchema<"account", undefined>;
358
+ readonly id: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>]>;
359
+ }, undefined>, v.StrictObjectSchema<{
360
+ readonly type: v.LiteralSchema<"any", undefined>;
361
+ readonly limit: v.LiteralSchema<"own", undefined>;
362
+ }, undefined>], undefined>, undefined>, v.MinLengthAction<({
363
+ type: "alias";
364
+ pattern: string;
365
+ } | {
366
+ type: "account";
367
+ id: string;
368
+ } | {
369
+ type: "any";
370
+ limit: "own";
371
+ })[], 1, undefined>, v.MaxLengthAction<({
372
+ type: "alias";
373
+ pattern: string;
374
+ } | {
375
+ type: "account";
376
+ id: string;
377
+ } | {
378
+ type: "any";
379
+ limit: "own";
380
+ })[], 100, undefined>, v.CheckAction<({
381
+ type: "alias";
382
+ pattern: string;
383
+ } | {
384
+ type: "account";
385
+ id: string;
386
+ } | {
387
+ type: "any";
388
+ limit: "own";
389
+ })[], "duplicate_account_matcher">]>;
390
+ }, undefined>;
391
+ readonly grantRequestJsonSchema: Record<string, unknown>;
392
+ readonly grantJsonSchema: Record<string, unknown>;
393
+ };
394
+ readonly bank_transfer: {
395
+ readonly actions: readonly ["create", "approve", "reject"];
396
+ readonly grantRequest: v.UnionSchema<[v.StrictObjectSchema<{
397
+ readonly type: v.LiteralSchema<"bank_transfer", undefined>;
398
+ readonly actions: v.SchemaWithPipe<readonly [v.ArraySchema<v.PicklistSchema<readonly ["create"], undefined>, undefined>, v.MinLengthAction<"create"[], 1, undefined>, v.CheckAction<"create"[], "duplicate_action">]>;
399
+ readonly locations: v.TupleSchema<[v.LiteralSchema<"https://api.andco.com", undefined>], undefined>;
400
+ readonly subject: v.NullishSchema<v.VariantSchema<"type", [v.StrictObjectSchema<{
401
+ readonly type: v.LiteralSchema<"profile", undefined>;
402
+ readonly identifier: v.NullishSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>]>, undefined>;
403
+ }, undefined>, v.StrictObjectSchema<{
404
+ readonly type: v.LiteralSchema<"organization", undefined>;
405
+ readonly identifier: v.NullishSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>, v.CheckAction<string, "identifier_exceeds_organization_id">]>, undefined>;
406
+ readonly editable: v.NullishSchema<v.BooleanSchema<undefined>, undefined>;
407
+ }, undefined>], undefined>, undefined>;
408
+ readonly sources: v.NullishSchema<v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.ArraySchema<v.UnionSchema<[v.StrictObjectSchema<{
409
+ readonly type: v.NullishSchema<v.LiteralSchema<"alias", undefined>, undefined>;
410
+ readonly pattern: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>]>;
411
+ readonly editable: v.NullishSchema<v.BooleanSchema<undefined>, undefined>;
412
+ readonly selection: v.NullishSchema<v.PicklistSchema<readonly ["single", "multiple"], undefined>, undefined>;
413
+ }, undefined>, v.StrictObjectSchema<{
414
+ readonly type: v.LiteralSchema<"account", undefined>;
415
+ readonly id: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>]>;
416
+ readonly editable: v.NullishSchema<v.BooleanSchema<undefined>, undefined>;
417
+ }, undefined>, v.StrictObjectSchema<{
418
+ readonly type: v.LiteralSchema<"any", undefined>;
419
+ readonly limit: v.LiteralSchema<"own", undefined>;
420
+ readonly editable: v.NullishSchema<v.BooleanSchema<undefined>, undefined>;
421
+ readonly selection: v.NullishSchema<v.PicklistSchema<readonly ["single", "multiple"], undefined>, undefined>;
422
+ }, undefined>], undefined>, undefined>, v.MinLengthAction<({
423
+ type?: "alias" | null | undefined;
424
+ pattern: string;
425
+ editable?: boolean | null | undefined;
426
+ selection?: "single" | "multiple" | null | undefined;
427
+ } | {
428
+ type: "account";
429
+ id: string;
430
+ editable?: boolean | null | undefined;
431
+ } | {
432
+ type: "any";
433
+ limit: "own";
434
+ editable?: boolean | null | undefined;
435
+ selection?: "single" | "multiple" | null | undefined;
436
+ })[], 1, undefined>, v.MaxLengthAction<({
437
+ type?: "alias" | null | undefined;
438
+ pattern: string;
439
+ editable?: boolean | null | undefined;
440
+ selection?: "single" | "multiple" | null | undefined;
441
+ } | {
442
+ type: "account";
443
+ id: string;
444
+ editable?: boolean | null | undefined;
445
+ } | {
446
+ type: "any";
447
+ limit: "own";
448
+ editable?: boolean | null | undefined;
449
+ selection?: "single" | "multiple" | null | undefined;
450
+ })[], 100, undefined>, v.CheckAction<({
451
+ type?: "alias" | null | undefined;
452
+ pattern: string;
453
+ editable?: boolean | null | undefined;
454
+ selection?: "single" | "multiple" | null | undefined;
455
+ } | {
456
+ type: "account";
457
+ id: string;
458
+ editable?: boolean | null | undefined;
459
+ } | {
460
+ type: "any";
461
+ limit: "own";
462
+ editable?: boolean | null | undefined;
463
+ selection?: "single" | "multiple" | null | undefined;
464
+ })[], "duplicate_account_matcher">]>, v.CheckAction<({
465
+ type?: "alias" | null | undefined;
466
+ pattern: string;
467
+ editable?: boolean | null | undefined;
468
+ selection?: "single" | "multiple" | null | undefined;
469
+ } | {
470
+ type: "account";
471
+ id: string;
472
+ editable?: boolean | null | undefined;
473
+ } | {
474
+ type: "any";
475
+ limit: "own";
476
+ editable?: boolean | null | undefined;
477
+ selection?: "single" | "multiple" | null | undefined;
478
+ })[], "account_selection_incoherent">]>, undefined>;
479
+ readonly destinations: v.NullishSchema<v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.ArraySchema<v.UnionSchema<[v.StrictObjectSchema<{
480
+ readonly type: v.NullishSchema<v.LiteralSchema<"alias", undefined>, undefined>;
481
+ readonly pattern: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>]>;
482
+ readonly editable: v.NullishSchema<v.BooleanSchema<undefined>, undefined>;
483
+ readonly selection: v.NullishSchema<v.PicklistSchema<readonly ["single", "multiple"], undefined>, undefined>;
484
+ }, undefined>, v.StrictObjectSchema<{
485
+ readonly type: v.LiteralSchema<"account", undefined>;
486
+ readonly id: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>]>;
487
+ readonly editable: v.NullishSchema<v.BooleanSchema<undefined>, undefined>;
488
+ }, undefined>, v.StrictObjectSchema<{
489
+ readonly type: v.LiteralSchema<"any", undefined>;
490
+ readonly limit: v.LiteralSchema<"own", undefined>;
491
+ readonly editable: v.NullishSchema<v.BooleanSchema<undefined>, undefined>;
492
+ readonly selection: v.NullishSchema<v.PicklistSchema<readonly ["single", "multiple"], undefined>, undefined>;
493
+ }, undefined>, v.StrictObjectSchema<{
494
+ readonly type: v.LiteralSchema<"any", undefined>;
495
+ readonly limit: v.LiteralSchema<"local", undefined>;
496
+ readonly editable: v.NullishSchema<v.BooleanSchema<undefined>, undefined>;
497
+ }, undefined>, v.StrictObjectSchema<{
498
+ readonly type: v.LiteralSchema<"any", undefined>;
499
+ readonly limit: v.LiteralSchema<"all", undefined>;
500
+ }, undefined>, v.StrictObjectSchema<{
501
+ readonly type: v.LiteralSchema<"external", undefined>;
502
+ readonly bank_id: v.NullishSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 128, undefined>, v.RegexAction<string, undefined>]>, undefined>;
503
+ readonly account_type: v.NullishSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 128, undefined>, v.RegexAction<string, undefined>]>, undefined>;
504
+ readonly account_id: v.NullishSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 128, undefined>, v.RegexAction<string, undefined>]>, undefined>;
505
+ readonly holder_id: v.NullishSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 128, undefined>, v.RegexAction<string, undefined>]>, undefined>;
506
+ readonly holder_name: v.NullishSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 128, undefined>, v.RegexAction<string, undefined>]>, undefined>;
507
+ readonly editable: v.NullishSchema<v.BooleanSchema<undefined>, undefined>;
508
+ }, undefined>], undefined>, undefined>, v.MinLengthAction<({
509
+ type?: "alias" | null | undefined;
510
+ pattern: string;
511
+ editable?: boolean | null | undefined;
512
+ selection?: "single" | "multiple" | null | undefined;
513
+ } | {
514
+ type: "account";
515
+ id: string;
516
+ editable?: boolean | null | undefined;
517
+ } | {
518
+ type: "any";
519
+ limit: "own";
520
+ editable?: boolean | null | undefined;
521
+ selection?: "single" | "multiple" | null | undefined;
522
+ } | {
523
+ type: "any";
524
+ limit: "local";
525
+ editable?: boolean | null | undefined;
526
+ } | {
527
+ type: "any";
528
+ limit: "all";
529
+ } | {
530
+ type: "external";
531
+ bank_id?: string | null | undefined;
532
+ account_type?: string | null | undefined;
533
+ account_id?: string | null | undefined;
534
+ holder_id?: string | null | undefined;
535
+ holder_name?: string | null | undefined;
536
+ editable?: boolean | null | undefined;
537
+ })[], 1, undefined>, v.MaxLengthAction<({
538
+ type?: "alias" | null | undefined;
539
+ pattern: string;
540
+ editable?: boolean | null | undefined;
541
+ selection?: "single" | "multiple" | null | undefined;
542
+ } | {
543
+ type: "account";
544
+ id: string;
545
+ editable?: boolean | null | undefined;
546
+ } | {
547
+ type: "any";
548
+ limit: "own";
549
+ editable?: boolean | null | undefined;
550
+ selection?: "single" | "multiple" | null | undefined;
551
+ } | {
552
+ type: "any";
553
+ limit: "local";
554
+ editable?: boolean | null | undefined;
555
+ } | {
556
+ type: "any";
557
+ limit: "all";
558
+ } | {
559
+ type: "external";
560
+ bank_id?: string | null | undefined;
561
+ account_type?: string | null | undefined;
562
+ account_id?: string | null | undefined;
563
+ holder_id?: string | null | undefined;
564
+ holder_name?: string | null | undefined;
565
+ editable?: boolean | null | undefined;
566
+ })[], 100, undefined>, v.CheckAction<({
567
+ type?: "alias" | null | undefined;
568
+ pattern: string;
569
+ editable?: boolean | null | undefined;
570
+ selection?: "single" | "multiple" | null | undefined;
571
+ } | {
572
+ type: "account";
573
+ id: string;
574
+ editable?: boolean | null | undefined;
575
+ } | {
576
+ type: "any";
577
+ limit: "own";
578
+ editable?: boolean | null | undefined;
579
+ selection?: "single" | "multiple" | null | undefined;
580
+ } | {
581
+ type: "any";
582
+ limit: "local";
583
+ editable?: boolean | null | undefined;
584
+ } | {
585
+ type: "any";
586
+ limit: "all";
587
+ } | {
588
+ type: "external";
589
+ bank_id?: string | null | undefined;
590
+ account_type?: string | null | undefined;
591
+ account_id?: string | null | undefined;
592
+ holder_id?: string | null | undefined;
593
+ holder_name?: string | null | undefined;
594
+ editable?: boolean | null | undefined;
595
+ })[], "duplicate_account_matcher">]>, v.CheckAction<({
596
+ type?: "alias" | null | undefined;
597
+ pattern: string;
598
+ editable?: boolean | null | undefined;
599
+ selection?: "single" | "multiple" | null | undefined;
600
+ } | {
601
+ type: "account";
602
+ id: string;
603
+ editable?: boolean | null | undefined;
604
+ } | {
605
+ type: "any";
606
+ limit: "own";
607
+ editable?: boolean | null | undefined;
608
+ selection?: "single" | "multiple" | null | undefined;
609
+ } | {
610
+ type: "any";
611
+ limit: "local";
612
+ editable?: boolean | null | undefined;
613
+ } | {
614
+ type: "any";
615
+ limit: "all";
616
+ } | {
617
+ type: "external";
618
+ bank_id?: string | null | undefined;
619
+ account_type?: string | null | undefined;
620
+ account_id?: string | null | undefined;
621
+ holder_id?: string | null | undefined;
622
+ holder_name?: string | null | undefined;
623
+ editable?: boolean | null | undefined;
624
+ })[], "account_selection_not_pickable">]>, undefined>;
625
+ readonly currency: v.PicklistSchema<readonly ["CLP"], undefined>;
626
+ readonly transactions: v.NullishSchema<v.SchemaWithPipe<readonly [v.StrictObjectSchema<{
627
+ readonly value: v.NullishSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, "amount_below_minimum_or_malformed">]>, undefined>;
628
+ readonly minimum: v.NullishSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, "amount_below_minimum_or_malformed">]>, undefined>;
629
+ readonly maximum: v.NullishSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, "amount_below_minimum_or_malformed">]>, undefined>;
630
+ readonly editable: v.NullishSchema<v.BooleanSchema<undefined>, undefined>;
631
+ }, undefined>, v.CheckAction<{
632
+ value?: string | null | undefined;
633
+ minimum?: string | null | undefined;
634
+ maximum?: string | null | undefined;
635
+ editable?: boolean | null | undefined;
636
+ }, "value_excludes_minimum_and_maximum">, v.CheckAction<{
637
+ value?: string | null | undefined;
638
+ minimum?: string | null | undefined;
639
+ maximum?: string | null | undefined;
640
+ editable?: boolean | null | undefined;
641
+ }, "minimum_above_maximum">]>, undefined>;
642
+ readonly budgets: v.OptionalSchema<v.NullSchema<undefined>, undefined>;
643
+ }, undefined>, v.StrictObjectSchema<{
644
+ readonly type: v.LiteralSchema<"bank_transfer", undefined>;
645
+ readonly actions: v.SchemaWithPipe<readonly [v.ArraySchema<v.PicklistSchema<readonly ["approve", "reject"], undefined>, undefined>, v.MinLengthAction<("approve" | "reject")[], 1, undefined>, v.CheckAction<("approve" | "reject")[], "duplicate_action">]>;
646
+ readonly locations: v.TupleSchema<[v.LiteralSchema<"https://api.andco.com", undefined>], undefined>;
647
+ readonly subject: v.NullishSchema<v.VariantSchema<"type", [v.StrictObjectSchema<{
648
+ readonly type: v.LiteralSchema<"profile", undefined>;
649
+ readonly identifier: v.NullishSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>]>, undefined>;
650
+ }, undefined>, v.StrictObjectSchema<{
651
+ readonly type: v.LiteralSchema<"organization", undefined>;
652
+ readonly identifier: v.NullishSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>, v.CheckAction<string, "identifier_exceeds_organization_id">]>, undefined>;
653
+ readonly editable: v.NullishSchema<v.BooleanSchema<undefined>, undefined>;
654
+ }, undefined>], undefined>, undefined>;
655
+ readonly transactions: v.NullishSchema<v.SchemaWithPipe<readonly [v.StrictObjectSchema<{
656
+ readonly minimum: v.NullishSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, "amount_below_minimum_or_malformed">]>, undefined>;
657
+ readonly maximum: v.NullishSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, "amount_below_minimum_or_malformed">]>, undefined>;
658
+ }, undefined>, v.CheckAction<{
659
+ minimum?: string | null | undefined;
660
+ maximum?: string | null | undefined;
661
+ }, "minimum_above_maximum">]>, undefined>;
662
+ }, undefined>], undefined>;
663
+ readonly grant: v.UnionSchema<[v.StrictObjectSchema<{
664
+ readonly type: v.LiteralSchema<"bank_transfer", undefined>;
665
+ readonly actions: v.SchemaWithPipe<readonly [v.ArraySchema<v.PicklistSchema<readonly ["create"], undefined>, undefined>, v.MinLengthAction<"create"[], 1, undefined>, v.CheckAction<"create"[], "duplicate_action">]>;
666
+ readonly locations: v.TupleSchema<[v.LiteralSchema<"https://api.andco.com", undefined>], undefined>;
667
+ readonly subject: v.VariantSchema<"type", [v.StrictObjectSchema<{
668
+ readonly type: v.LiteralSchema<"profile", undefined>;
669
+ readonly identifier: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>]>;
670
+ }, undefined>, v.StrictObjectSchema<{
671
+ readonly type: v.LiteralSchema<"organization", undefined>;
672
+ readonly identifier: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>, v.CheckAction<string, "identifier_exceeds_organization_id">]>;
673
+ }, undefined>], undefined>;
674
+ readonly sources: v.SchemaWithPipe<readonly [v.ArraySchema<v.UnionSchema<[v.StrictObjectSchema<{
675
+ readonly type: v.LiteralSchema<"alias", undefined>;
676
+ readonly pattern: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>]>;
677
+ }, undefined>, v.StrictObjectSchema<{
678
+ readonly type: v.LiteralSchema<"account", undefined>;
679
+ readonly id: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>]>;
680
+ }, undefined>, v.StrictObjectSchema<{
681
+ readonly type: v.LiteralSchema<"any", undefined>;
682
+ readonly limit: v.LiteralSchema<"own", undefined>;
683
+ }, undefined>], undefined>, undefined>, v.MinLengthAction<({
684
+ type: "alias";
685
+ pattern: string;
686
+ } | {
687
+ type: "account";
688
+ id: string;
689
+ } | {
690
+ type: "any";
691
+ limit: "own";
692
+ })[], 1, undefined>, v.MaxLengthAction<({
693
+ type: "alias";
694
+ pattern: string;
695
+ } | {
696
+ type: "account";
697
+ id: string;
698
+ } | {
699
+ type: "any";
700
+ limit: "own";
701
+ })[], 100, undefined>, v.CheckAction<({
702
+ type: "alias";
703
+ pattern: string;
704
+ } | {
705
+ type: "account";
706
+ id: string;
707
+ } | {
708
+ type: "any";
709
+ limit: "own";
710
+ })[], "duplicate_account_matcher">]>;
711
+ readonly destinations: v.SchemaWithPipe<readonly [v.ArraySchema<v.UnionSchema<[v.StrictObjectSchema<{
712
+ readonly type: v.LiteralSchema<"alias", undefined>;
713
+ readonly pattern: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>]>;
714
+ }, undefined>, v.StrictObjectSchema<{
715
+ readonly type: v.LiteralSchema<"account", undefined>;
716
+ readonly id: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>]>;
717
+ }, undefined>, v.StrictObjectSchema<{
718
+ readonly type: v.LiteralSchema<"any", undefined>;
719
+ readonly limit: v.LiteralSchema<"own", undefined>;
720
+ }, undefined>, v.StrictObjectSchema<{
721
+ readonly type: v.LiteralSchema<"any", undefined>;
722
+ readonly limit: v.LiteralSchema<"local", undefined>;
723
+ }, undefined>, v.StrictObjectSchema<{
724
+ readonly type: v.LiteralSchema<"any", undefined>;
725
+ readonly limit: v.LiteralSchema<"all", undefined>;
726
+ }, undefined>, v.StrictObjectSchema<{
727
+ readonly type: v.LiteralSchema<"external", undefined>;
728
+ readonly bank_id: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 128, undefined>, v.RegexAction<string, undefined>]>, undefined>;
729
+ readonly account_type: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 128, undefined>, v.RegexAction<string, undefined>]>, undefined>;
730
+ readonly account_id: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 128, undefined>, v.RegexAction<string, undefined>]>, undefined>;
731
+ readonly holder_id: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 128, undefined>, v.RegexAction<string, undefined>]>, undefined>;
732
+ readonly holder_name: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.MinLengthAction<string, 1, undefined>, v.MaxLengthAction<string, 128, undefined>, v.RegexAction<string, undefined>]>, undefined>;
733
+ }, undefined>], undefined>, undefined>, v.MinLengthAction<({
734
+ type: "any";
735
+ limit: "all";
736
+ } | {
737
+ type: "alias";
738
+ pattern: string;
739
+ } | {
740
+ type: "account";
741
+ id: string;
742
+ } | {
743
+ type: "any";
744
+ limit: "own";
745
+ } | {
746
+ type: "any";
747
+ limit: "local";
748
+ } | {
749
+ type: "external";
750
+ bank_id?: string | undefined;
751
+ account_type?: string | undefined;
752
+ account_id?: string | undefined;
753
+ holder_id?: string | undefined;
754
+ holder_name?: string | undefined;
755
+ })[], 1, undefined>, v.MaxLengthAction<({
756
+ type: "any";
757
+ limit: "all";
758
+ } | {
759
+ type: "alias";
760
+ pattern: string;
761
+ } | {
762
+ type: "account";
763
+ id: string;
764
+ } | {
765
+ type: "any";
766
+ limit: "own";
767
+ } | {
768
+ type: "any";
769
+ limit: "local";
770
+ } | {
771
+ type: "external";
772
+ bank_id?: string | undefined;
773
+ account_type?: string | undefined;
774
+ account_id?: string | undefined;
775
+ holder_id?: string | undefined;
776
+ holder_name?: string | undefined;
777
+ })[], 100, undefined>, v.CheckAction<({
778
+ type: "any";
779
+ limit: "all";
780
+ } | {
781
+ type: "alias";
782
+ pattern: string;
783
+ } | {
784
+ type: "account";
785
+ id: string;
786
+ } | {
787
+ type: "any";
788
+ limit: "own";
789
+ } | {
790
+ type: "any";
791
+ limit: "local";
792
+ } | {
793
+ type: "external";
794
+ bank_id?: string | undefined;
795
+ account_type?: string | undefined;
796
+ account_id?: string | undefined;
797
+ holder_id?: string | undefined;
798
+ holder_name?: string | undefined;
799
+ })[], "duplicate_account_matcher">]>;
800
+ readonly currency: v.PicklistSchema<readonly ["CLP"], undefined>;
801
+ readonly transactions: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StrictObjectSchema<{
802
+ readonly value: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, "amount_below_minimum_or_malformed">]>, undefined>;
803
+ readonly minimum: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, "amount_below_minimum_or_malformed">]>, undefined>;
804
+ readonly maximum: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, "amount_below_minimum_or_malformed">]>, undefined>;
805
+ }, undefined>, v.CheckAction<{
806
+ value?: string | undefined;
807
+ minimum?: string | undefined;
808
+ maximum?: string | undefined;
809
+ }, "value_excludes_minimum_and_maximum">, v.CheckAction<{
810
+ value?: string | undefined;
811
+ minimum?: string | undefined;
812
+ maximum?: string | undefined;
813
+ }, "minimum_above_maximum">]>, undefined>;
814
+ }, undefined>, v.StrictObjectSchema<{
815
+ readonly type: v.LiteralSchema<"bank_transfer", undefined>;
816
+ readonly actions: v.SchemaWithPipe<readonly [v.ArraySchema<v.PicklistSchema<readonly ["approve", "reject"], undefined>, undefined>, v.MinLengthAction<("approve" | "reject")[], 1, undefined>, v.CheckAction<("approve" | "reject")[], "duplicate_action">]>;
817
+ readonly locations: v.TupleSchema<[v.LiteralSchema<"https://api.andco.com", undefined>], undefined>;
818
+ readonly subject: v.VariantSchema<"type", [v.StrictObjectSchema<{
819
+ readonly type: v.LiteralSchema<"profile", undefined>;
820
+ readonly identifier: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>]>;
821
+ }, undefined>, v.StrictObjectSchema<{
822
+ readonly type: v.LiteralSchema<"organization", undefined>;
823
+ readonly identifier: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>, v.CheckAction<string, "identifier_exceeds_organization_id">]>;
824
+ }, undefined>], undefined>;
825
+ readonly transactions: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StrictObjectSchema<{
826
+ readonly minimum: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, "amount_below_minimum_or_malformed">]>, undefined>;
827
+ readonly maximum: v.OptionalSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, "amount_below_minimum_or_malformed">]>, undefined>;
828
+ }, undefined>, v.CheckAction<{
829
+ minimum?: string | undefined;
830
+ maximum?: string | undefined;
831
+ }, "minimum_above_maximum">]>, undefined>;
832
+ }, undefined>], undefined>;
833
+ readonly grantRequestJsonSchema: Record<string, unknown>;
834
+ readonly grantJsonSchema: Record<string, unknown>;
835
+ };
836
+ readonly bank_deposit: {
837
+ readonly actions: readonly ["create", "read", "close"];
838
+ readonly grantRequest: v.StrictObjectSchema<{
839
+ readonly type: v.LiteralSchema<"bank_deposit", undefined>;
840
+ readonly actions: v.SchemaWithPipe<readonly [v.ArraySchema<v.PicklistSchema<readonly ["create", "read", "close"], undefined>, undefined>, v.MinLengthAction<("read" | "create" | "close")[], 1, undefined>, v.CheckAction<("read" | "create" | "close")[], "duplicate_action">]>;
841
+ readonly locations: v.TupleSchema<[v.LiteralSchema<"https://api.andco.com", undefined>], undefined>;
842
+ readonly subject: v.NullishSchema<v.VariantSchema<"type", [v.StrictObjectSchema<{
843
+ readonly type: v.LiteralSchema<"profile", undefined>;
844
+ readonly identifier: v.NullishSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>]>, undefined>;
845
+ }, undefined>, v.StrictObjectSchema<{
846
+ readonly type: v.LiteralSchema<"organization", undefined>;
847
+ readonly identifier: v.NullishSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>, v.CheckAction<string, "identifier_exceeds_organization_id">]>, undefined>;
848
+ readonly editable: v.NullishSchema<v.BooleanSchema<undefined>, undefined>;
849
+ }, undefined>], undefined>, undefined>;
850
+ readonly destinations: v.SchemaWithPipe<readonly [v.SchemaWithPipe<readonly [v.ArraySchema<v.UnionSchema<[v.StrictObjectSchema<{
851
+ readonly type: v.NullishSchema<v.LiteralSchema<"alias", undefined>, undefined>;
852
+ readonly pattern: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>]>;
853
+ readonly editable: v.NullishSchema<v.BooleanSchema<undefined>, undefined>;
854
+ readonly selection: v.NullishSchema<v.PicklistSchema<readonly ["single", "multiple"], undefined>, undefined>;
855
+ }, undefined>, v.StrictObjectSchema<{
856
+ readonly type: v.LiteralSchema<"account", undefined>;
857
+ readonly id: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>]>;
858
+ readonly editable: v.NullishSchema<v.BooleanSchema<undefined>, undefined>;
859
+ }, undefined>, v.StrictObjectSchema<{
860
+ readonly type: v.LiteralSchema<"any", undefined>;
861
+ readonly limit: v.LiteralSchema<"own", undefined>;
862
+ readonly editable: v.NullishSchema<v.BooleanSchema<undefined>, undefined>;
863
+ readonly selection: v.NullishSchema<v.PicklistSchema<readonly ["single", "multiple"], undefined>, undefined>;
864
+ }, undefined>], undefined>, undefined>, v.MinLengthAction<({
865
+ type?: "alias" | null | undefined;
866
+ pattern: string;
867
+ editable?: boolean | null | undefined;
868
+ selection?: "single" | "multiple" | null | undefined;
869
+ } | {
870
+ type: "account";
871
+ id: string;
872
+ editable?: boolean | null | undefined;
873
+ } | {
874
+ type: "any";
875
+ limit: "own";
876
+ editable?: boolean | null | undefined;
877
+ selection?: "single" | "multiple" | null | undefined;
878
+ })[], 1, undefined>, v.MaxLengthAction<({
879
+ type?: "alias" | null | undefined;
880
+ pattern: string;
881
+ editable?: boolean | null | undefined;
882
+ selection?: "single" | "multiple" | null | undefined;
883
+ } | {
884
+ type: "account";
885
+ id: string;
886
+ editable?: boolean | null | undefined;
887
+ } | {
888
+ type: "any";
889
+ limit: "own";
890
+ editable?: boolean | null | undefined;
891
+ selection?: "single" | "multiple" | null | undefined;
892
+ })[], 100, undefined>, v.CheckAction<({
893
+ type?: "alias" | null | undefined;
894
+ pattern: string;
895
+ editable?: boolean | null | undefined;
896
+ selection?: "single" | "multiple" | null | undefined;
897
+ } | {
898
+ type: "account";
899
+ id: string;
900
+ editable?: boolean | null | undefined;
901
+ } | {
902
+ type: "any";
903
+ limit: "own";
904
+ editable?: boolean | null | undefined;
905
+ selection?: "single" | "multiple" | null | undefined;
906
+ })[], "duplicate_account_matcher">]>, v.CheckAction<({
907
+ type?: "alias" | null | undefined;
908
+ pattern: string;
909
+ editable?: boolean | null | undefined;
910
+ selection?: "single" | "multiple" | null | undefined;
911
+ } | {
912
+ type: "account";
913
+ id: string;
914
+ editable?: boolean | null | undefined;
915
+ } | {
916
+ type: "any";
917
+ limit: "own";
918
+ editable?: boolean | null | undefined;
919
+ selection?: "single" | "multiple" | null | undefined;
920
+ })[], "account_selection_incoherent">]>;
921
+ }, undefined>;
922
+ readonly grant: v.StrictObjectSchema<{
923
+ readonly type: v.LiteralSchema<"bank_deposit", undefined>;
924
+ readonly actions: v.SchemaWithPipe<readonly [v.ArraySchema<v.PicklistSchema<readonly ["create", "read", "close"], undefined>, undefined>, v.MinLengthAction<("read" | "create" | "close")[], 1, undefined>, v.CheckAction<("read" | "create" | "close")[], "duplicate_action">]>;
925
+ readonly locations: v.TupleSchema<[v.LiteralSchema<"https://api.andco.com", undefined>], undefined>;
926
+ readonly subject: v.VariantSchema<"type", [v.StrictObjectSchema<{
927
+ readonly type: v.LiteralSchema<"profile", undefined>;
928
+ readonly identifier: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>]>;
929
+ }, undefined>, v.StrictObjectSchema<{
930
+ readonly type: v.LiteralSchema<"organization", undefined>;
931
+ readonly identifier: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>, v.CheckAction<string, "identifier_exceeds_organization_id">]>;
932
+ }, undefined>], undefined>;
933
+ readonly destinations: v.SchemaWithPipe<readonly [v.ArraySchema<v.UnionSchema<[v.StrictObjectSchema<{
934
+ readonly type: v.LiteralSchema<"alias", undefined>;
935
+ readonly pattern: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>]>;
936
+ }, undefined>, v.StrictObjectSchema<{
937
+ readonly type: v.LiteralSchema<"account", undefined>;
938
+ readonly id: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>]>;
939
+ }, undefined>, v.StrictObjectSchema<{
940
+ readonly type: v.LiteralSchema<"any", undefined>;
941
+ readonly limit: v.LiteralSchema<"own", undefined>;
942
+ }, undefined>], undefined>, undefined>, v.MinLengthAction<({
943
+ type: "alias";
944
+ pattern: string;
945
+ } | {
946
+ type: "account";
947
+ id: string;
948
+ } | {
949
+ type: "any";
950
+ limit: "own";
951
+ })[], 1, undefined>, v.MaxLengthAction<({
952
+ type: "alias";
953
+ pattern: string;
954
+ } | {
955
+ type: "account";
956
+ id: string;
957
+ } | {
958
+ type: "any";
959
+ limit: "own";
960
+ })[], 100, undefined>, v.CheckAction<({
961
+ type: "alias";
962
+ pattern: string;
963
+ } | {
964
+ type: "account";
965
+ id: string;
966
+ } | {
967
+ type: "any";
968
+ limit: "own";
969
+ })[], "duplicate_account_matcher">]>;
970
+ }, undefined>;
971
+ readonly grantRequestJsonSchema: Record<string, unknown>;
972
+ readonly grantJsonSchema: Record<string, unknown>;
973
+ };
974
+ readonly identity: {
975
+ readonly actions: readonly ["read"];
976
+ readonly grantRequest: v.StrictObjectSchema<{
977
+ readonly type: v.LiteralSchema<"identity", undefined>;
978
+ readonly actions: v.SchemaWithPipe<readonly [v.ArraySchema<v.PicklistSchema<readonly ["read"], undefined>, undefined>, v.MinLengthAction<"read"[], 1, undefined>, v.CheckAction<"read"[], "duplicate_action">]>;
979
+ readonly locations: v.TupleSchema<[v.LiteralSchema<"https://api.andco.com", undefined>], undefined>;
980
+ readonly subject: v.NullishSchema<v.VariantSchema<"type", [v.StrictObjectSchema<{
981
+ readonly type: v.LiteralSchema<"profile", undefined>;
982
+ readonly identifier: v.NullishSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>]>, undefined>;
983
+ }, undefined>, v.StrictObjectSchema<{
984
+ readonly type: v.LiteralSchema<"organization", undefined>;
985
+ readonly identifier: v.NullishSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>, v.CheckAction<string, "identifier_exceeds_organization_id">]>, undefined>;
986
+ readonly editable: v.NullishSchema<v.BooleanSchema<undefined>, undefined>;
987
+ }, undefined>], undefined>, undefined>;
988
+ }, undefined>;
989
+ readonly grant: v.StrictObjectSchema<{
990
+ readonly type: v.LiteralSchema<"identity", undefined>;
991
+ readonly actions: v.SchemaWithPipe<readonly [v.ArraySchema<v.PicklistSchema<readonly ["read"], undefined>, undefined>, v.MinLengthAction<"read"[], 1, undefined>, v.CheckAction<"read"[], "duplicate_action">]>;
992
+ readonly locations: v.TupleSchema<[v.LiteralSchema<"https://api.andco.com", undefined>], undefined>;
993
+ readonly subject: v.VariantSchema<"type", [v.StrictObjectSchema<{
994
+ readonly type: v.LiteralSchema<"profile", undefined>;
995
+ readonly identifier: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>]>;
996
+ }, undefined>, v.StrictObjectSchema<{
997
+ readonly type: v.LiteralSchema<"organization", undefined>;
998
+ readonly identifier: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>, v.CheckAction<string, "identifier_exceeds_organization_id">]>;
999
+ }, undefined>], undefined>;
1000
+ }, undefined>;
1001
+ readonly grantRequestJsonSchema: Record<string, unknown>;
1002
+ readonly grantJsonSchema: Record<string, unknown>;
1003
+ };
1004
+ readonly address: {
1005
+ readonly actions: readonly ["read", "create", "update", "delete"];
1006
+ readonly grantRequest: v.StrictObjectSchema<{
1007
+ readonly type: v.LiteralSchema<"address", undefined>;
1008
+ readonly actions: v.SchemaWithPipe<readonly [v.ArraySchema<v.PicklistSchema<readonly ["read", "create", "update", "delete"], undefined>, undefined>, v.MinLengthAction<("read" | "create" | "update" | "delete")[], 1, undefined>, v.CheckAction<("read" | "create" | "update" | "delete")[], "duplicate_action">]>;
1009
+ readonly locations: v.TupleSchema<[v.LiteralSchema<"https://api.andco.com", undefined>], undefined>;
1010
+ readonly subject: v.NullishSchema<v.VariantSchema<"type", [v.StrictObjectSchema<{
1011
+ readonly type: v.LiteralSchema<"profile", undefined>;
1012
+ readonly identifier: v.NullishSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>]>, undefined>;
1013
+ }, undefined>, v.StrictObjectSchema<{
1014
+ readonly type: v.LiteralSchema<"organization", undefined>;
1015
+ readonly identifier: v.NullishSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>, v.CheckAction<string, "identifier_exceeds_organization_id">]>, undefined>;
1016
+ readonly editable: v.NullishSchema<v.BooleanSchema<undefined>, undefined>;
1017
+ }, undefined>], undefined>, undefined>;
1018
+ }, undefined>;
1019
+ readonly grant: v.StrictObjectSchema<{
1020
+ readonly type: v.LiteralSchema<"address", undefined>;
1021
+ readonly actions: v.SchemaWithPipe<readonly [v.ArraySchema<v.PicklistSchema<readonly ["read", "create", "update", "delete"], undefined>, undefined>, v.MinLengthAction<("read" | "create" | "update" | "delete")[], 1, undefined>, v.CheckAction<("read" | "create" | "update" | "delete")[], "duplicate_action">]>;
1022
+ readonly locations: v.TupleSchema<[v.LiteralSchema<"https://api.andco.com", undefined>], undefined>;
1023
+ readonly subject: v.VariantSchema<"type", [v.StrictObjectSchema<{
1024
+ readonly type: v.LiteralSchema<"profile", undefined>;
1025
+ readonly identifier: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>]>;
1026
+ }, undefined>, v.StrictObjectSchema<{
1027
+ readonly type: v.LiteralSchema<"organization", undefined>;
1028
+ readonly identifier: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>, v.CheckAction<string, "identifier_exceeds_organization_id">]>;
1029
+ }, undefined>], undefined>;
1030
+ }, undefined>;
1031
+ readonly grantRequestJsonSchema: Record<string, unknown>;
1032
+ readonly grantJsonSchema: Record<string, unknown>;
1033
+ };
1034
+ readonly organization: {
1035
+ readonly actions: readonly ["list"];
1036
+ readonly grantRequest: v.StrictObjectSchema<{
1037
+ readonly type: v.LiteralSchema<"organization", undefined>;
1038
+ readonly actions: v.SchemaWithPipe<readonly [v.ArraySchema<v.PicklistSchema<readonly ["list"], undefined>, undefined>, v.MinLengthAction<"list"[], 1, undefined>, v.CheckAction<"list"[], "duplicate_action">]>;
1039
+ readonly locations: v.TupleSchema<[v.LiteralSchema<"https://api.andco.com", undefined>], undefined>;
1040
+ readonly subject: v.NullishSchema<v.StrictObjectSchema<{
1041
+ readonly type: v.LiteralSchema<"profile", undefined>;
1042
+ readonly identifier: v.NullishSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>]>, undefined>;
1043
+ }, undefined>, undefined>;
1044
+ }, undefined>;
1045
+ readonly grant: v.StrictObjectSchema<{
1046
+ readonly type: v.LiteralSchema<"organization", undefined>;
1047
+ readonly actions: v.SchemaWithPipe<readonly [v.ArraySchema<v.PicklistSchema<readonly ["list"], undefined>, undefined>, v.MinLengthAction<"list"[], 1, undefined>, v.CheckAction<"list"[], "duplicate_action">]>;
1048
+ readonly locations: v.TupleSchema<[v.LiteralSchema<"https://api.andco.com", undefined>], undefined>;
1049
+ readonly subject: v.StrictObjectSchema<{
1050
+ readonly type: v.LiteralSchema<"profile", undefined>;
1051
+ readonly identifier: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>]>;
1052
+ }, undefined>;
1053
+ }, undefined>;
1054
+ readonly grantRequestJsonSchema: Record<string, unknown>;
1055
+ readonly grantJsonSchema: Record<string, unknown>;
1056
+ };
1057
+ readonly profile: {
1058
+ readonly actions: readonly ["update"];
1059
+ readonly grantRequest: v.StrictObjectSchema<{
1060
+ readonly type: v.LiteralSchema<"profile", undefined>;
1061
+ readonly actions: v.SchemaWithPipe<readonly [v.ArraySchema<v.PicklistSchema<readonly ["update"], undefined>, undefined>, v.MinLengthAction<"update"[], 1, undefined>, v.CheckAction<"update"[], "duplicate_action">]>;
1062
+ readonly locations: v.TupleSchema<[v.LiteralSchema<"https://api.andco.com", undefined>], undefined>;
1063
+ readonly subject: v.NullishSchema<v.StrictObjectSchema<{
1064
+ readonly type: v.LiteralSchema<"profile", undefined>;
1065
+ readonly identifier: v.NullishSchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>]>, undefined>;
1066
+ }, undefined>, undefined>;
1067
+ }, undefined>;
1068
+ readonly grant: v.StrictObjectSchema<{
1069
+ readonly type: v.LiteralSchema<"profile", undefined>;
1070
+ readonly actions: v.SchemaWithPipe<readonly [v.ArraySchema<v.PicklistSchema<readonly ["update"], undefined>, undefined>, v.MinLengthAction<"update"[], 1, undefined>, v.CheckAction<"update"[], "duplicate_action">]>;
1071
+ readonly locations: v.TupleSchema<[v.LiteralSchema<"https://api.andco.com", undefined>], undefined>;
1072
+ readonly subject: v.StrictObjectSchema<{
1073
+ readonly type: v.LiteralSchema<"profile", undefined>;
1074
+ readonly identifier: v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>]>;
1075
+ }, undefined>;
1076
+ }, undefined>;
1077
+ readonly grantRequestJsonSchema: Record<string, unknown>;
1078
+ readonly grantJsonSchema: Record<string, unknown>;
1079
+ };
1080
+ readonly project_users: {
1081
+ readonly actions: readonly ["read"];
1082
+ readonly grantRequest: v.StrictObjectSchema<{
1083
+ readonly type: v.LiteralSchema<"project_users", undefined>;
1084
+ readonly actions: v.SchemaWithPipe<readonly [v.ArraySchema<v.PicklistSchema<readonly ["read"], undefined>, undefined>, v.MinLengthAction<"read"[], 1, undefined>, v.CheckAction<"read"[], "duplicate_action">]>;
1085
+ readonly locations: v.TupleSchema<[v.LiteralSchema<"https://api.andco.com", undefined>], undefined>;
1086
+ readonly project_ids: v.NullishSchema<v.SchemaWithPipe<readonly [v.ArraySchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>]>, undefined>, v.MaxLengthAction<string[], 100, undefined>, v.CheckAction<string[], "duplicate_identifier">]>, undefined>;
1087
+ readonly client_ids: v.NullishSchema<v.SchemaWithPipe<readonly [v.ArraySchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>]>, undefined>, v.MaxLengthAction<string[], 100, undefined>, v.CheckAction<string[], "duplicate_identifier">]>, undefined>;
1088
+ readonly fields: v.NullishSchema<v.SchemaWithPipe<readonly [v.ArraySchema<v.PicklistSchema<readonly ["id", "name", "email", "avatar", "phone", "identities", "addresses"], undefined>, undefined>, v.CheckAction<("email" | "phone" | "id" | "name" | "avatar" | "identities" | "addresses")[], "duplicate_field">]>, undefined>;
1089
+ }, undefined>;
1090
+ readonly grant: v.StrictObjectSchema<{
1091
+ readonly type: v.LiteralSchema<"project_users", undefined>;
1092
+ readonly actions: v.SchemaWithPipe<readonly [v.ArraySchema<v.PicklistSchema<readonly ["read"], undefined>, undefined>, v.MinLengthAction<"read"[], 1, undefined>, v.CheckAction<"read"[], "duplicate_action">]>;
1093
+ readonly locations: v.TupleSchema<[v.LiteralSchema<"https://api.andco.com", undefined>], undefined>;
1094
+ readonly project_ids: v.SchemaWithPipe<readonly [v.ArraySchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>]>, undefined>, v.MaxLengthAction<string[], 100, undefined>, v.CheckAction<string[], "duplicate_identifier">]>;
1095
+ readonly client_ids: v.SchemaWithPipe<readonly [v.ArraySchema<v.SchemaWithPipe<readonly [v.StringSchema<undefined>, v.RegexAction<string, undefined>]>, undefined>, v.MaxLengthAction<string[], 100, undefined>, v.CheckAction<string[], "duplicate_identifier">]>;
1096
+ readonly fields: v.SchemaWithPipe<readonly [v.ArraySchema<v.PicklistSchema<readonly ["id", "name", "email", "avatar", "phone", "identities", "addresses"], undefined>, undefined>, v.CheckAction<("email" | "phone" | "id" | "name" | "avatar" | "identities" | "addresses")[], "duplicate_field">]>;
1097
+ }, undefined>;
1098
+ readonly grantRequestJsonSchema: Record<string, unknown>;
1099
+ readonly grantJsonSchema: Record<string, unknown>;
1100
+ };
1101
+ };
1102
+ /** Any Andco authorization detail in its Grant Request form. */
1103
+ export type AndcoGrantRequest = {
1104
+ [Type in AndcoRarType]: v.InferOutput<(typeof ANDCO_RAR_CATALOG)[Type]["grantRequest"]>;
1105
+ }[AndcoRarType];
1106
+ /** Any Andco authorization detail in its Grant form, as `GET /authorization` returns it. */
1107
+ export type AndcoGrant = {
1108
+ [Type in AndcoRarType]: v.InferOutput<(typeof ANDCO_RAR_CATALOG)[Type]["grant"]>;
1109
+ }[AndcoRarType];
1110
+ /** Codes {@link AndcoRarError} carries: the ones the API answers for the same conditions. */
1111
+ export type AndcoRarErrorCode = typeof ANDCO_API_ERROR_CODES.INVALID_REQUEST | typeof ANDCO_API_ERROR_CODES.NOT_IMPLEMENTED;
1112
+ /**
1113
+ * An authorization detail that cannot be used: `invalid_request` when it breaks the contract,
1114
+ * `not_implemented` when it names a reserved type. The codes are the API's own, so the SDK fails
1115
+ * locally with the error the server would have answered.
1116
+ */
1117
+ export declare class AndcoRarError extends ErrorExtendable {
1118
+ readonly code: AndcoRarErrorCode;
1119
+ readonly type: string | undefined;
1120
+ readonly issues: readonly v.BaseIssue<unknown>[];
1121
+ constructor(code: AndcoRarErrorCode, type: string | undefined, issues?: readonly v.BaseIssue<unknown>[], options?: ErrorOptions);
1122
+ }
1123
+ /** Whether `type` is one of {@link ANDCO_RAR_TYPES}. */
1124
+ export declare function isAndcoRarType(type: unknown): type is AndcoRarType;
1125
+ /** Whether `type` is one of {@link ANDCO_RESERVED_RAR_TYPES}. */
1126
+ export declare function isAndcoReservedRarType(type: unknown): type is AndcoReservedRarType;
1127
+ /**
1128
+ * Validates one Andco authorization detail in its Grant Request form, dispatching on `type`.
1129
+ * Throws {@link AndcoRarError}: `not_implemented` for a reserved type, `invalid_request` otherwise.
1130
+ *
1131
+ * @example
1132
+ * const detail = parseAndcoGrantRequest({
1133
+ * type: "bank_transfer",
1134
+ * actions: ["create"],
1135
+ * locations: ["https://api.andco.com"],
1136
+ * subject: { type: "profile" },
1137
+ * currency: "CLP",
1138
+ * transactions: { value: "25990" },
1139
+ * });
1140
+ */
1141
+ export declare function parseAndcoGrantRequest(detail: unknown): AndcoGrantRequest;
1142
+ /**
1143
+ * Validates one Andco authorization detail in its Grant form, as `GET /authorization` returns it.
1144
+ * Throws {@link AndcoRarError} like {@link parseAndcoGrantRequest}.
1145
+ *
1146
+ * @example
1147
+ * const grant = parseAndcoGrant({
1148
+ * type: "identity",
1149
+ * actions: ["read"],
1150
+ * locations: ["https://api.andco.com"],
1151
+ * subject: { type: "organization", identifier: "42" },
1152
+ * });
1153
+ */
1154
+ export declare function parseAndcoGrant(detail: unknown): AndcoGrant;
1155
+ //# sourceMappingURL=catalog.d.ts.map